-
Notifications
You must be signed in to change notification settings - Fork 18
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
Handle missing pickle file references in expt list #185
Conversation
Hm, to me if a file is missing then I want the program to stop execution. Missing a hot pixel mask is a serious error and I'd expect my integration results to be impacted. I could imaging wanting to override the error, but I'd think that should need an extra phil parameter to whatever program I'm running. |
@phyy-nx issue here is that if you are missing this file you can't use the experiments as reference geometry, which is a show stopper when supporting users. Current advice is for them to edit the files which is simply dumb. Not suggesting that processing without the mask subsequently is OK, but there is useful information in there Passing a phil parameter umpteen layers down is also probably close to a non-starter as well, as I think this is happening before phil parameters are parsed... |
Reference geometry makes sense, but shouldn't it be loaded with check_format=False in that case? See https://github.com/dials/dials/blob/master/command_line/stills_process.py#L319 |
I think I have to agree with @phyy-nx that I'm concerned about (almost) silently ignoring errors such as missing mask files when their absence could have a big impact on data processing in some cases. Users don't read log files at the best of times, and this is especially so in the context of automated pipeline. It's certainly much more of a gorilla than a true fix for dials/dials#1238, and is likely to come back to bite us at some point. Regarding passing as reference geometry - I'm pretty certain that with
|
In fact, with this change, I don't see any error in the output of
|
I'd prefer check_format to go away, so that you can import the file just fine for reference geometry etc, but a failure occurs later on at any point when you try to read a value from the mask. Same true for image data in general |
I like @dagewa's suggestion, and I note that #187 addresses that. I've found a fix for the immediate user support problem that prompted this (an implicit |
When importing an experiment list from file with
check_format=True
, don't give up with aFileNotFoundError
if a pickle file reference like the imageset hot pixel mask is broken. Instead, log a warning and continue.Depends on dials/data-files#19 and, once that is merged, a corresponding PR in dials/data.
This is one possible approach to dials/dials#1238. Whether you regard it as a fix or a workaround depends on your point of view.