Skip to content

Reading an EELS spectrum image from a tiff file #54

Answered by CSSFrancis
HamishGBrown asked this question in Q&A
Discussion options

You must be logged in to vote

@HamishGBrown it looks like the data is 28,30|2048 channels? Is that correct. Tiffs only support 3 dimension stacks with 2 of the dimensions for each "image" so likely the data is saved transposed which is why it is loaded in as a signal 2D or 2048|30,28.

Try this:

gfp = hs.load("/home/hbrown/Mount/F30data/Hamish/20240603_GFP_BSA_comparison/{0}/{1}_EELS Spectrum Image.tif".format('1_5mgmlGFP','AF'))

gfp = gfp.T #the signal is now a Signal1D
gfp.set_signal_type("EELSSpectrum") 

You might need to manually adjust the axes manager based on the header and set things like gfp.axes_manager.signal_axes[0].scale

Let me know if you need more help and if you share the data I can look at it further…

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
1 reply
@ericpre
Comment options

Answer selected by ericpre
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants
Converted from issue

This discussion was converted from issue #53 on June 04, 2024 07:52.