Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[bin] Fix all the scripts that had errors #1995

Merged
merged 2 commits into from
May 10, 2023
Merged

Conversation

cbentejac
Copy link
Contributor

Description

This PR fixes errors on different Meshroom scripts that thus could not be run, or crashed when some specific arguments were set. More specifically, it targets:

  • meshroom_submit:
    • The input argument containing the path of the project file to submit was never used to call the core.graph's "submit" method;
    • Instead, two invalid arguments were used;
  • meshroom_status: The --toNode option caused errors when retrieving the list of nodes up to toNode;
  • meshroom_statistics:
    • The script was still performing Python 2-imports;
    • It relied on a method in the core.stats module that was broken: when reading the statistics file, the computer and process statistics where initialized to empty dictionaries instead of ComputerStatistics and ProcStatistics objects, meaning the file was read but its content was never stored;
    • It used an outdated version of the Matplotlib API.

Features list

  • Properly initialize the ComputerStatistics and ProcStatistics objects when reading a statistics file;
  • Fix all the errors when running meshroom_submit, meshroom_status and meshroom_statistics.

…tats

When reading the `ComputerStatistics` and `ProcStatistics` from a file
(and thus from a dictionary), the `computer` and `process` objects need
to be correctly initialized as `ComputerStatistics` and `ProcStatistics`
objects. Otherwise, they cannot access their `fromDict` method and will
remain empty dictionaries.
- `meshroom_submit`: the submission to the render farm is now effective
(the script did not work at all).
- `meshroom_status`: the `--toNode` option did not work and caused errors.
- `meshroom_statistics`: some adjustments needed to be made for the script
to run with Python3 instead of Python2, an issue in the core/stats.py file
led the `statistics` file to never being read correctly, and the calls
to the Matplotlib API were outdated.
@cbentejac cbentejac self-assigned this Apr 24, 2023
@cbentejac cbentejac added this to the Meshroom 2023.2.0 milestone Apr 26, 2023
@fabiencastan fabiencastan merged commit b1c4c96 into develop May 10, 2023
@fabiencastan fabiencastan deleted the fix/binCmdLine branch May 10, 2023 11:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants