Skip to content
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

[issue] trying to convert grd into imzml #7

Closed
inesboxexa opened this issue Apr 1, 2021 · 2 comments
Closed

[issue] trying to convert grd into imzml #7

inesboxexa opened this issue Apr 1, 2021 · 2 comments

Comments

@inesboxexa
Copy link

Hi Alan,

I was trying to use this converter to go from grd to imzml using the code below:

C:\Users\tm6\Documents\GitHub\jimzMLConverter\target>java -jar jimzMLConverter-2.1.0.jar imzML -p "X:\Teresa\BEIS biofilms project sims data\Biofilm 1\ToF\GRD ToF\biofilm 1 tof negative1.properties.txt" "X:\Teresa\BEIS biofilms project sims data\Biofilm 1\ToF\GRD ToF\biofilm 1 tof negative1.itm.grd"

But I got the following error:

Mar 31, 2021 1:43:32 PM com.alanmrace.jimzmlconverter.MainCommand convert
INFO: Converting file X:\Teresa\BEIS biofilms project sims data\Biofilm 1\ToF\GRD ToF\biofilm 1 tof negative1.itm.grd
Mar 31, 2021 1:43:32 PM com.alanmrace.jimzmlconverter.MainCommand convert
INFO: Detected ION-TOF GRD file
Mar 31, 2021 1:43:32 PM com.alanmrace.jimzmlparser.obo.OBOTerm parse
INFO: Unknown value-type encountered 'value-type:xsd:dateTime "The allowed value-type for this CV term."' @ MS:1000747
Mar 31, 2021 1:43:32 PM com.alanmrace.jimzmlparser.obo.OBOTerm parse
INFO: Unknown value-type encountered 'value-type:xsd:dateTime "The allowed value-type for this CV term."' @ MS:1002435
Exception in thread "main" java.lang.NullPointerException: Cannot invoke "com.alanmrace.jimzmlconverter.IONTOF.IONTOFProperty.getIntegerValue()" because "xDimension" is null
at com.alanmrace.jimzmlconverter.GRDToImzMLConverter.setPropertiesFile(GRDToImzMLConverter.java:98)
at com.alanmrace.jimzmlconverter.MainCommand.convert(MainCommand.java:287)
at com.alanmrace.jimzmlconverter.MainCommand.main(MainCommand.java:186)

Do you know what this means? Does it give us a clue on what is wrong with the grd file?

Thank you,
Teresa

@AlanRace
Copy link
Owner

AlanRace commented Apr 1, 2021

Hi Teresa,
Yes that definitely helps. The problem is that the converter/parser expects certain properties in the .properties.txt file to contain:

Registration.Raster.StageRaster.TotalResolution.X
Registration.Raster.StageRaster.TotalResolution.Y

It seems like the properties file that you supplied doesn't contain these properties any more, and instead there are now:

Acquisition.#1.Raster.TotalResolution.X	256	256	256
Acquisition.#1.Raster.TotalResolution.Y	256	256	256

To get things moving, I'd suggest adding two new lines to the properties.txt file:

Registration.Raster.StageRaster.TotalResolution.X	256	256	256
Registration.Raster.StageRaster.TotalResolution.Y	256	256	256

Replace 256 with however many pixels are in the X and Y direction in the image.

Hope that helps,

Alan

@inesboxexa
Copy link
Author

Hi Alan,

Thank you very much - this has solved it.

Best,
Teresa

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants