Skip to content
Snippets Groups Projects
Commit 8e0fcc28 authored by Ammar Nejati's avatar Ammar Nejati
Browse files

[a.fixBA_plot] Remove global variables from ba_plot (912)

Merging branch 'a.fixBA_plot'  into 'main'.

* The implicit parsing of commandline arguments is eliminated from the `ba_plot` module;
therefore, importing `ba_plot` will have no side-effects.
Originally, the implicit parsing of commandline arguments during importing led to crashes when
the module was imported in a different environment, like a Jupyter notebook.

* All global variables are removed from the `ba_plot.py` module and plot arguments are made explicit to avoid unexpected problems
due to corruption of global variables. In the originall scheme, storing the plot arguments as global variable would lead to strange
behaviour if two examples were run sequentially, since the global plot arguments would persist in the global scope from one example
to the other.

Related to #912

See merge request !2525
parents 092b75b3 9dc0a4b2
No related branches found
No related tags found
1 merge request!2525Remove global variables from ba_plot
Pipeline #140961 passed
Showing
with 181 additions and 146 deletions
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment