-
Notifications
You must be signed in to change notification settings - Fork 202
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
MotionCor error with TIFFOpen to many files lead to broken frame #819
Comments
As the message suggests, Movies/FoilHole_10311198_Data_10288223_10288225_20210911_135024_EER.eer is probably broken. Remove this from your movie STAR file and continue the job. (I am not sure what is going on with |
We cannot change this at the moment, in order to remain compatible with earlier compiler versions. But we will take note of this. Thanks. |
I did continue without removing it and it finished fine. I thought since its exactly the same file as the TIFFOpen that the TIFFOpen error maybe "corrupted" it in a sense that led to the broken Frame error. And since continue without removing it worked i guess it may be the case? |
I don't know. My colleagues have processed thousands of EER movies without this error. If there are file handle leaks, they should have seen this error. Since I cannot reproduce this issue and you managed to process your dataset, I will close this issue. If you encounter the same issue again, please reopen. |
I can't add anything helpful to this, but I have seen this problem both with 3.1.2 and 4.0-beta. It typically happens with a few thousand EER files. We also see the "TiffOpen: Too many open files" error before a broken frame is reported. The file reported as being broken is fine - if it's removed a different file is reported as being broken. I've found that upping the number of MPI processes can get rid of the error, presumably because fewer files are opened per process and the 'too may files' limit isn't hit. |
I don't know how to fix this. We do close TIFF files in https://github.com/3dem/relion/blob/ver4.0/src/renderEER.cpp#L264. |
Could it be something similar to this problem here? https://stackoverflow.com/questions/15262542/tiffopen-too-many-open-files Since as far as i understand the code your function is also called read? |
That is an interesting case but our code should be OK. Ours is C++'s member function. The function name is mangled https://en.wikipedia.org/wiki/Name_mangling#Complex_example. |
I put some diagnostic printfs in renderEER.cpp and something odd appears to be happening:
Looking at test_0192.eer, for example, there are:
I don't understand the code yet, but it seems that the first TIFFOpen doesn't have an associated TIFFClose. The second TIFFOpen does. The modified code was:
|
I've made a little more progress. MotioncorrRunner::executeOwnMotionCorrection calls EERRenderer::Read, which calls TIFFOpen. It later calls EERRenderer::renderFrames, which calls EERRenderer::lazyReadFrames, which calls TIFFClose. This is fine. However, at some point before this Microgaph::SetMovie is called. This also calls EERRenderer::Read, which results in a call to TIFFOpen. There is no corresponding call to TIFFClose. |
@mokca Thank you very much for great investigation! |
I repaired this problem in the commit 505e422 for both 3.1 (the Thank you very much for your report and investigation. |
A MotionCor job with relions own version failed after around 3k out of 4k processed eer files. Continuing the job works fine and finishes though normally.
Environment:
Dataset:
Job options:
note.txt
in the job directory):P.S. a little off topic and not breaking
When installing with intel 2021.4 you get following warning
The text was updated successfully, but these errors were encountered: