-
Notifications
You must be signed in to change notification settings - Fork 80
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
downsample
can't process star
file with particles in multiple folders.
#386
Comments
Hey, thanks for the heads up, we are hoping to refactor this part of the code to make it easier to support In this case, without the
and
So a somewhat less hacky fix might be to add better logic in |
Were you able to get it to work using We may have changed this behavior after refactoring to Alternatively, assuming your .mrcs filename are all unique, you can symlink them all to a new directory that you can then provide to
|
I wasn't able to get it to work without modifying the code. I don't think it appends the starfile path to the datadir (see 1 and 2). Since That solution seems reasonable, however the 10028 starfile provided in the cryodrgn_empiar repo doesn't have unique filenames. |
For the upcoming v3.4.0 release, I have ended up doing a small refactor of the I have tried an early version of the v3.4.0 release on the same 80S case you described above. When running using v3.3.3, it produces the following error as expected, with and without
However, now with v3.4.0, we can use In the codebase, we have consolidated the
This in some part recapitulates (and now replaces) the logic in the old
I would much rather explicitly write out the cases where we want to use You can access this early version ( Please let us know if this works for you, and if you spot any other problems! I may still make some minor tweaks to this code over the next few days as I finalize testing for the v3.4.0 release, so stay tuned! * note the use of single-quotes when specifying the cryoDRGN version, which is necessary in most bash environments! |
Describe the bug
If a
star
file has particles in multiple folders (e.g. EMPIAR 10028) thenStarfileSource
is unable to load the data. This is due to appending only the particle paths'basename
to thedatadir
. In the case of EMPIAR 10028 the parent folder name is needed as well as there are duplicate basenames.To Reproduce
Here is the file structure:
Here is the command:
cryodrgn downsample Particles/shiny_2sets.star -D 256 -o particles.256.mrcs
Expected behavior
The command is expected to not error. Instead there is an (expected)
FileNotFoundError
.Additional context
It is impossible to use
--datadir
to fix this as suggested in theREADME
. The issue arises from the fact that forStarfileSource
the_MRCDataFrameSource
constructor is called with adatadir
argument (even if none is provided through the command line) which always triggers this branch. A hacky way to fix this is to set up the file structure as shown above and uncomment the aforementioned branch.The text was updated successfully, but these errors were encountered: