-
Notifications
You must be signed in to change notification settings - Fork 0
shift_fidfilemarkers.py
shift_fidfilemarkers.py shifts markers in IMOD fiducial file generated by ETspec.
Using IMOD tools this script reads in an IMOD .fid file to obtain markers. The script then shifts these markers by values set in --xshift and --yshift writing the results to another IMOD .fid file. It is assumed the input file is a binary IMOD file and the IMOD command model2point is used to convert the file to an ascii format that is parsed. After shift_fidfilemarkers.py shifts the markers they are saved back as an IMOD binary .fid file using point2model
This example takes this 2Dmarkers_all.fid file and shifts the marker positions in the x by 100.
View of (2d markers file here) before shifting
View of output of shift_fidfilemarkers.py (100shift.fid) after shifting
Command to run:
NOTE: To run this IMOD must be installed and the IMOD commands model2point and point2model must be in your path.
Before running please download ((2d markers file here) and then run the command below in the same directory 2Dmarkers_all.fid is located.
shift_fidfilemarkers.py --xshift 100 --yshift 0 2Dmarkers_all.fid 100shift.fid