Combine method "median" suddenly stopped working
Added by Matthias Brunner about 14 years ago
Hi there!
In the correction node, median as combine method instead of average suddenly stopped working - I now get the following message:
Cannot acquire dark reference: tuple index out of range
Switching back to average as combine method works, however, I would prefer median to remove bright pixels.
Median has been working for months and now suddenly stopped - without any changes (no python updates etc) - at least none that I am aware of.
Does anyone have an idea where to start looking?
Still Leginon 1.6 here...
Replies (3)
RE: Combine method "median" suddenly stopped working - Added by Anchi Cheng about 14 years ago
The median calculation uses numpy.median(). Has numpy version changed at your installation?
Also, can you give more detailed log before the error message so that we can pin-point the location of the error? Since you are familiar with python, you can also raise that exception in corrector.py instead of print in the logger. As is, it is hard to tell which tuple index is out of range. tuple index out of range is not likely an numpy error message.
RE: Combine method "median" suddenly stopped working - Added by Matthias Brunner over 13 years ago
Finally, I found the cause of this problem:
For another software package, the PYTHONPATH environment variable was set - effectively including other versions of the libraries.
To keep the python environment controlled and clean, always set (or reset, depending on your needs) the PYTHONPATH before starting:
Shell command:
PYTHONPATH= python start-leginon.py
Maybe you could include this into the manual?
RE: Combine method "median" suddenly stopped working - Added by Anchi Cheng over 13 years ago
Thanks for the update, Mathias.
I made the change in Start_Leginon_at_your_main_working_station_remotely