Last active
November 4, 2024 15:15
-
-
Save shahpnmlab/743155e3bc0a907479fee1148a0a33bb to your computer and use it in GitHub Desktop.
Plot warp picked coords using IMOD
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import starfile | |
XDIM = 378 | |
YDIM = 378 | |
ZDIM = 228 | |
df = starfile.read("gs07_ts_003_8.00Apx_emd_13474_clean.star") | |
xyz_headings = [f'rlnCoordinate{axis}' for axis in 'XYZ'] | |
xyz_headings.append('rlnAutopickFigureOfMerit') | |
coords = df[xyz_headings].to_numpy() | |
coords[:,0] *= XDIM | |
coords[:,1] *= YDIM | |
coords[:,2] *= ZDIM | |
np.savetxt("in.txt", coords, fmt='%.3f', delimiter='\t') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment