[3dem] Way to read raw pixel size from .eer?
Ludtke, Steven J.
sludtke at bcm.edu
Fri Jul 21 06:22:53 PDT 2023
conda activate eman2
e2iminfo.py file.eer --header
0.
EER.acquisition_id: 20230523.193352.415
EER.camera_name: BM-Falcon
EER.commercial_name: Falcon 4
EER.compression: 65001
EER.eer_gain_reference: ImagesForProcessing/BM-Falcon/200kV/20230518_180445_EER_GainReference.gain
EER.exposure_time: 0.99720799999999998
EER.mean_dose_rate: 7.4649417694525013
EER.number_of_frames: 238
EER.sensor_image_height: 4096
EER.sensor_image_width: 4096
EER.sensor_pixel_size.height: 7.39449266e-11
EER.sensor_pixel_size.width: 7.39449266e-11
EER.serial_number: 20-35-A0X-XST
EER.timestamp: 2023-05-23T19:33:52.915710-05:00
EER.total_dose: 7.384066590322254
HostEndian: little
ImageEndian: little
apix_x: 1.0
apix_y: 1.0
apix_z: 1.0
changecount: 0
datatype: 7
is_complex: 0
is_complex_ri: 1
is_complex_x: 0
nx: 4096
ny: 4096
nz: 1
source_n: 0
source_path: Supervisor_20230523_190932_81_PRAFrac1_ultraufoil/Images-Disc1/GridSquare_23254874/Data/FoilHole_24224148_Data_24223466_24223468_20230523_193352_EER.eer
Should work for any CryoEM file format to get header information. For most formats the A/pix information would wind up in apix_x, but it looks like this hasn't been implemented in EER at the moment. Will have to fix that...
For programmatic work from Python:
python
from EMAN2 import *
img=EMData("file.eer",0) # 0 is the first image in the stack
print(img["EER.sensor_pixel_size.height"])
--------------------------------------------------------------------------------------
Steven Ludtke, Ph.D. <sludtke at bcm.edu> Baylor College of Medicine
Charles C. Bell Jr., Professor of Structural Biology Dept. of Biochemistry
Deputy Director, Advanced Technology Cores and Molecular Pharmacology
Academic Director, CryoEM Core
Co-Director CIBR Center
On Jul 21, 2023, at 8:08 AM, Takanori Nakane <tnakane.protein at OSAKA-U.AC.JP> wrote:
Hi,
> Running 'strings xxx.eer | less | grep sensor' actually contains the
> field below:
>
> item name="sensorPixelSize.width" unit="m">8.85268664e-11
>
> which seems to display the correct pixel size for the acquisition. I
Great! My files contained 0.000, perhaps because they were from
a test version of the detector software.
> et = ET.XML(f.eer_metadata)
This is also great. I didn't know the tifffile package understands
non-standard TIFF tags.
Best regards,
Takanori Nakane
On 2023/07/21 22:03, Ioannis Skalidis wrote:
Thanks Takanori!
Running 'strings xxx.eer | less | grep sensor' actually contains the field below:
item name="sensorPixelSize.width" unit="m">8.85268664e-11
which seems to display the correct pixel size for the acquisition. I cross-validated it with data from multiple acquisitions and it always changes accordingly.
On 21.07.23 14:54, Takanori Nakane wrote:
Hi,
EER files contain some metadata in TFS-specific
extended TIFF tags (e.g. IFD 65001).
You have to write a script to read it but a dirty way is to just run
strings XXX.eer | less
and go to the bottom.
There is a "sensorPixelSize.height" field.
But I guess this is a physical pixel size of the detector
independent of the magnification.
I don't know if EER contains the pixel size at the sample.
Best regards,
Takanori Nakane
On 2023/07/21 21:46, Ioannis Skalidis wrote:
Dear all,
I was looking for the raw pixel size of some acquired data and realized that when I use the 'header' command from the 3dmod package with the -eer modifier to read the header of an .eer file, it always returns a pixel spacing of 1 Å. Of course, I can read the header of the corresponding .mrc files that are generated, but I was thinking if there is a way in unix/macos environments to read the .eer metadata directly. Does anybody have a way to do this?
Thanks,
Ioannis.
_______________________________________________
3dem mailing list
3dem at ncmir.ucsd.edu
https://urldefense.proofpoint.com/v2/url?u=https-3A__mail.ncmir.ucsd.edu_mailman_listinfo_3dem&d=DwIGaQ&c=ZQs-KZ8oxEw0p81sqgiaRA&r=GWA2IF6nkq8sZMXHpp1Xpg&m=rxtdu7D3A6BywvITZh9e7qh6oq-3JafFCL2q0Q09gwcRBkTcXpelmVi-KD5-_b3q&s=vSi-ytSF5fK8xg29ti9DV30-1Ay1m94Nlg4Y_IVlWwo&e=
_______________________________________________
3dem mailing list
3dem at ncmir.ucsd.edu<mailto:3dem at ncmir.ucsd.edu>
https://urldefense.proofpoint.com/v2/url?u=https-3A__mail.ncmir.ucsd.edu_mailman_listinfo_3dem&d=DwIGaQ&c=ZQs-KZ8oxEw0p81sqgiaRA&r=GWA2IF6nkq8sZMXHpp1Xpg&m=rxtdu7D3A6BywvITZh9e7qh6oq-3JafFCL2q0Q09gwcRBkTcXpelmVi-KD5-_b3q&s=vSi-ytSF5fK8xg29ti9DV30-1Ay1m94Nlg4Y_IVlWwo&e=
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.ncmir.ucsd.edu/pipermail/3dem/attachments/20230721/aa371e4f/attachment-0001.html>
More information about the 3dem
mailing list