-
Notifications
You must be signed in to change notification settings - Fork 0
rotate_3dmarkers.py
Chris Churas edited this page Oct 21, 2016
·
8 revisions
rotate_3dmarkers.py rotates 3Dmarkers.txt file generated by ET-SPEC.
The 3Dmarkers.txt is an ascii file containing the position (x,y,z or slice) of simulated particles in the sample. These positions are generated by ET-SPEC. Rotation performed by rotate_3dmarkers.py is done on x and y keeping the z coordinate or slice the same.
Format of 3Dmarkers.txt file:
<index> <x position> <y position> <slice aka z position>
Note: All the fields above are left padded with spaces. The <index> column is left padded with 5 spaces.
Example:
1 633.000000 638.000000 12.000000
2 485.000000 628.000000 12.000000
3 532.000000 582.000000 12.000000
4 689.000000 677.000000 12.000000
Example invocation:
This command will rotate the markers by 45 degrees counter clockwise using 400x300 as the center point of rotation (0.5 x width and 0.5 x height). The output will be written to 3Dmarkers_rotated45.txt
rotate_3dmarkers.py 3Dmarkers.txt --angle 45 --outfile 3Dmarkers_rotated45.txt --width 800 --height 600