-
Notifications
You must be signed in to change notification settings - Fork 3
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
nup84 2D EM map in PGM format can't be read by Python Image Library #33
Comments
Unfortunately the code in IMP to handle 2D EM maps only works with ASCII PGM format, so we can't change the file in the repository. It has to reflect what was actually done in the modeling. Fortunately the file format is very simple and the parser is correspondingly simple. You can certainly steal Dina's code to parse it. |
I think the best solution is to not replace the PGM map but simply add another copy to the repository in a format that we encourage people to use and reference that copy from the IHM file. I know the format is trivial to read but the Python image library does not read it, and no one in 10 years of Chimera use by virtually the whole single particle EM field has requested using ascii pgm — so it is hard for me to justify spending a day making a patch to the Python image library that will be incorporated in some future release. I’d suggest converting the PGM to MRC format which is the most commonly used EM image format, but also TIF or PNG would be fine.
… On May 5, 2017, at 2:52 PM, Ben Webb ***@***.***> wrote:
Unfortunately the code in IMP to handle 2D EM maps only works with ASCII PGM format, so we can't change the file in the repository. It has to reflect what was actually done in the modeling.
Fortunately the file format is very simple and the parser is correspondingly simple. You can certainly steal Dina's code <https://github.com/salilab/imp/blob/develop/modules/em2d/include/internal/Image2D.h#L141> to parse it.
|
benmwebb
added a commit
to integrativemodeling/nup84
that referenced
this issue
May 11, 2017
Binary PGM is much better supported by external tools and libraries than text PGM. Relates ihmwg/IHMCIF#33.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The 2D EM map in the nup84.cif example is in ASCII PGM format which is not supported by the Python Image Library (Pillow 4.0.0, latest available). Binary PGM is supported. This is such an obscure format it is not worth adding support in ChimeraX to read it. Better to convert to a commonly used format like MRC or CCP4 or PNG or TIFF to make the example represent best practice.
The text was updated successfully, but these errors were encountered: