Questions about handedness

117 views
Skip to first unread message

黄振

unread,
Aug 20, 2022, 10:23:06 PM8/20/22
to EMAN2
Dear EMAN2 Community,

I have been processing the tutorial data(CTEM_tomo, EMPIAR 10064). However, after following the tutorial and comparing my result with the reference structure(EMD-3418), I just find that the handedness of my result is incorrect.

There is no doubt that the process of refinement would not change the handedness.
So I use e2spt_tomoctf.py to check the handedness of the tomogram. It turns out that the handedness of all the three tomograms seem to be correct.

And here are my questions:

1) Why is the handedness of my result incorrect even if I follow the tutorial? Have I missed some steps?

2) I figure out that the e2tomogram.py has the --flip option. Does this mean that I ought to flip the tomogram when reconstructing it? Or flip it elsewhere?

3) Why does the handedness seem to be correct when running e2spt_tomoctf.py? Shouldn't it show the handedness is wrong?

4) Are there corresponding functions to change the handedness of the particles in EMAN2? Flipping the structure(or particles) directly is better.

Best wishes,
Zhen Huang
ZheJiang University


------Details------
EMAN2 Version:
EMAN 2.99 ( GITHUB: 2022-08-02 21:05 - commit: 8a24bb112b5837b69fa6c0696c7ae1b88262a637 )
Your EMAN2 is running on: Linux-3.10.0-693.el7.x86_64-x86_64-with-glibc2.17 3.10.0-693.el7.x86_64
Your Python version is: 3.9.13


e2spt_tomoctf.py:
Processing 3 tilt series in sequence..
running:  e2spt_tomoctf.py tiltseries/CTEM_tomo1.hdf --nolog --verbose 0 --dfrange=2.0,7.0,0.02 --psrange=10,15,5 --tilesize=256 --voltage=300 --cs=2.7 --nref=15 --stepx=20 --stepy=40 --checkhand --ppid=-2
Reading tilt series tiltseries/CTEM_tomo1.hdf...
Checking handedness of the tomogram. Will NOT write metadata output...
Current tilt axis rotation -355.60
Comparing current hand vs flipped hand..
ID 30, angle 1.4, defocus 3.4 vs 3.4, score 3.687 vs 3.680
ID 31, angle 2.0, defocus 3.4 vs 3.4, score 3.585 vs 3.520
ID 29, angle -2.8, defocus 3.5 vs 3.5, score 3.416 vs 3.408
ID 32, angle 4.4, defocus 3.5 vs 3.5, score 3.272 vs 3.250
ID 28, angle -4.6, defocus 3.5 vs 3.5, score 3.926 vs 3.908
ID 33, angle 5.6, defocus 3.5 vs 3.5, score 3.337 vs 3.312
ID 27, angle -7.1, defocus 3.4 vs 3.5, score 3.903 vs 3.716
ID 34, angle 7.8, defocus 3.5 vs 3.5, score 3.263 vs 3.224
ID 26, angle -9.0, defocus 3.5 vs 3.5, score 3.891 vs 3.762
ID 35, angle 9.7, defocus 3.5 vs 3.5, score 3.438 vs 3.145
ID 25, angle -10.5, defocus 3.4 vs 3.4, score 4.267 vs 4.023
ID 36, angle 11.6, defocus 3.5 vs 3.5, score 1.950 vs 1.767
ID 24, angle -11.8, defocus 3.4 vs 3.4, score 4.013 vs 3.606
ID 37, angle 13.9, defocus 3.5 vs 3.5, score 3.375 vs 2.845
ID 23, angle -14.1, defocus 3.4 vs 3.4, score 3.974 vs 3.466
ID 22, angle -16.1, defocus 3.4 vs 3.4, score 4.383 vs 3.572
ID 38, angle 16.2, defocus 3.5 vs 3.4, score 2.991 vs 2.400
ID 39, angle 17.6, defocus 3.6 vs 3.5, score 3.112 vs 2.548
ID 21, angle -18.1, defocus 3.4 vs 3.4, score 4.117 vs 3.542
ID 40, angle 19.9, defocus 3.5 vs 3.5, score 2.926 vs 2.114
ID 20, angle -20.1, defocus 3.4 vs 3.4, score 4.257 vs 3.252
ID 41, angle 21.8, defocus 3.6 vs 3.6, score 3.072 vs 2.221
ID 19, angle -22.3, defocus 3.3 vs 3.4, score 1.559 vs 1.246
ID 42, angle 23.6, defocus 3.6 vs 3.5, score 2.863 vs 1.967
ID 18, angle -24.7, defocus 3.4 vs 3.4, score 1.935 vs 1.233
ID 43, angle 25.4, defocus 3.6 vs 3.4, score 3.037 vs 2.149
ID 17, angle -26.2, defocus 3.5 vs 3.2, score 1.441 vs 1.173
ID 44, angle 27.5, defocus 3.7 vs 3.5, score 2.868 vs 1.943
ID 16, angle -28.2, defocus 3.5 vs 3.3, score 1.707 vs 1.254
ID 45, angle 29.6, defocus 3.6 vs 3.6, score 2.887 vs 1.631
ID 15, angle -30.1, defocus 3.4 vs 3.2, score 1.605 vs 0.927
ID 46, angle 31.6, defocus 3.7 vs 3.5, score 2.638 vs 1.527
ID 14, angle -32.4, defocus 3.4 vs 3.4, score 2.210 vs 1.149
ID 47, angle 33.8, defocus 3.7 vs 3.4, score 2.833 vs 1.546
ID 13, angle -34.3, defocus 3.4 vs 3.4, score 2.213 vs 0.966
ID 48, angle 35.7, defocus 3.7 vs 3.4, score 2.893 vs 1.495
ID 12, angle -36.2, defocus 3.4 vs 3.2, score 1.967 vs 0.988
ID 49, angle 37.8, defocus 3.7 vs 3.7, score 2.840 vs 1.301
ID 11, angle -38.3, defocus 3.4 vs 3.2, score 2.395 vs 1.184
ID 50, angle 39.9, defocus 3.5 vs 3.6, score 2.855 vs 1.200
ID 10, angle -40.0, defocus 3.4 vs 3.3, score 2.372 vs 1.137
ID 51, angle 41.8, defocus 3.6 vs 3.2, score 2.881 vs 1.160
ID 9, angle -42.0, defocus 3.3 vs 2.7, score 2.209 vs 0.806
ID 52, angle 43.9, defocus 3.6 vs 3.4, score 2.672 vs 0.986
ID 8, angle -44.0, defocus 3.3 vs 3.0, score 2.262 vs 0.663
ID 53, angle 45.8, defocus 3.4 vs 2.9, score 2.816 vs 0.957
ID 7, angle -46.2, defocus 3.3 vs 3.4, score 2.445 vs 0.747
ID 54, angle 47.8, defocus 3.5 vs 2.8, score 2.780 vs 1.050
ID 6, angle -48.0, defocus 3.3 vs 2.6, score 2.423 vs 0.624
ID 55, angle 49.8, defocus 3.4 vs 3.1, score 2.695 vs 0.712
ID 5, angle -50.0, defocus 3.2 vs 3.0, score 2.207 vs 0.601
ID 56, angle 51.8, defocus 3.4 vs 2.8, score 2.758 vs 0.762
ID 4, angle -52.2, defocus 3.1 vs 2.8, score 2.566 vs 0.585
ID 57, angle 53.9, defocus 4.0 vs 3.3, score 2.635 vs 0.740
ID 3, angle -54.1, defocus 3.0 vs 3.2, score 2.554 vs 0.430
ID 58, angle 55.9, defocus 3.4 vs 2.6, score 2.817 vs 0.703
ID 2, angle -56.1, defocus 3.2 vs 2.7, score 2.457 vs 0.576
ID 59, angle 58.1, defocus 3.1 vs 2.7, score 2.743 vs 0.395
ID 1, angle -58.1, defocus 3.3 vs 2.7, score 2.463 vs 0.404
ID 60, angle 59.9, defocus 3.1 vs 2.9, score 2.725 vs 0.348
ID 0, angle -60.1, defocus 2.7 vs 2.8, score 2.575 vs 0.256
Average score: Current hand - 2.868, flipped hand - 1.800
Defocus std: Current hand - 0.188, flipped hand - 0.288
Current hand is better than the flipped hand in 100.0% tilt images
The handedness (--tltax=-355.6) seems to be correct. Rerun CTF estimation without the checkhand option to finish the process.
running:  e2spt_tomoctf.py tiltseries/CTEM_tomo2.hdf --nolog --verbose 0 --dfrange=2.0,7.0,0.02 --psrange=10,15,5 --tilesize=256 --voltage=300 --cs=2.7 --nref=15 --stepx=20 --stepy=40 --checkhand --ppid=-2
Reading tilt series tiltseries/CTEM_tomo2.hdf...
Checking handedness of the tomogram. Will NOT write metadata output...
Current tilt axis rotation -355.67
Comparing current hand vs flipped hand..
ID 31, angle 0.1, defocus 3.4 vs 3.4, score 4.110 vs 4.110
ID 30, angle -1.1, defocus 3.4 vs 3.4, score 3.946 vs 3.951
ID 29, angle -2.8, defocus 3.4 vs 3.4, score 4.054 vs 4.153
ID 32, angle 2.9, defocus 3.3 vs 3.4, score 3.636 vs 3.486
ID 28, angle -3.3, defocus 3.4 vs 3.4, score 3.987 vs 4.006
ID 33, angle 4.9, defocus 3.5 vs 3.5, score 3.882 vs 3.793
ID 27, angle -5.7, defocus 3.3 vs 3.4, score 4.636 vs 4.619
ID 26, angle -7.1, defocus 3.4 vs 3.4, score 4.335 vs 4.246
ID 34, angle 7.3, defocus 3.4 vs 3.4, score 3.933 vs 3.754
ID 25, angle -8.4, defocus 3.3 vs 3.3, score 4.751 vs 4.462
ID 35, angle 9.8, defocus 3.4 vs 3.4, score 3.731 vs 3.349
ID 24, angle -10.9, defocus 3.3 vs 3.3, score 4.674 vs 4.273
ID 36, angle 11.4, defocus 3.4 vs 3.3, score 3.845 vs 3.391
ID 23, angle -13.2, defocus 3.3 vs 3.4, score 4.848 vs 4.161
ID 37, angle 13.9, defocus 3.3 vs 3.3, score 3.830 vs 3.238
ID 22, angle -15.5, defocus 3.2 vs 3.3, score 4.660 vs 4.086
ID 38, angle 15.7, defocus 3.4 vs 3.4, score 3.578 vs 2.957
ID 39, angle 17.6, defocus 3.3 vs 3.4, score 4.015 vs 3.169
ID 21, angle -17.7, defocus 3.3 vs 3.3, score 4.845 vs 3.972
ID 20, angle -19.6, defocus 3.4 vs 3.4, score 4.701 vs 3.716
ID 40, angle 19.8, defocus 3.3 vs 3.2, score 3.473 vs 2.615
ID 19, angle -21.8, defocus 3.5 vs 3.6, score 2.763 vs 1.888
ID 41, angle 21.9, defocus 3.3 vs 3.2, score 3.157 vs 2.193
ID 42, angle 24.1, defocus 3.2 vs 3.1, score 3.475 vs 2.335
ID 18, angle -24.1, defocus 3.6 vs 3.5, score 2.315 vs 1.665
ID 17, angle -26.0, defocus 3.6 vs 3.4, score 2.416 vs 1.599
ID 43, angle 26.1, defocus 3.2 vs 3.1, score 3.138 vs 1.802
ID 16, angle -27.9, defocus 3.6 vs 3.6, score 2.327 vs 1.403
ID 44, angle 28.0, defocus 3.2 vs 3.2, score 3.275 vs 2.088
ID 15, angle -30.1, defocus 3.6 vs 3.4, score 2.655 vs 1.298
ID 45, angle 30.2, defocus 3.1 vs 3.0, score 3.497 vs 1.768
ID 46, angle 32.1, defocus 3.1 vs 3.0, score 3.322 vs 1.726
ID 14, angle -32.2, defocus 3.7 vs 3.5, score 2.418 vs 1.168
ID 13, angle -34.2, defocus 3.7 vs 3.5, score 2.572 vs 1.222
ID 47, angle 34.2, defocus 3.1 vs 3.0, score 3.296 vs 1.471
ID 48, angle 36.0, defocus 2.9 vs 2.6, score 3.192 vs 1.382
ID 12, angle -36.0, defocus 3.6 vs 3.6, score 2.724 vs 1.061
ID 49, angle 38.0, defocus 3.0 vs 2.7, score 3.158 vs 1.389
ID 11, angle -38.1, defocus 3.6 vs 3.4, score 2.633 vs 1.234
ID 10, angle -40.0, defocus 3.6 vs 3.7, score 2.530 vs 1.079
ID 50, angle 40.2, defocus 3.0 vs 2.7, score 3.352 vs 1.184
ID 9, angle -42.0, defocus 3.6 vs 3.6, score 2.869 vs 1.008
ID 51, angle 42.1, defocus 3.1 vs 2.6, score 3.497 vs 1.351
ID 8, angle -44.0, defocus 3.5 vs 3.5, score 2.674 vs 1.094
ID 52, angle 44.1, defocus 3.1 vs 2.7, score 2.934 vs 1.131
ID 7, angle -45.9, defocus 3.5 vs 3.5, score 2.370 vs 0.895
ID 53, angle 46.2, defocus 3.1 vs 2.6, score 3.313 vs 1.041
ID 6, angle -48.0, defocus 3.5 vs 3.1, score 2.661 vs 0.901
ID 54, angle 48.1, defocus 3.1 vs 2.6, score 3.228 vs 0.842
ID 5, angle -50.0, defocus 3.5 vs 3.7, score 2.781 vs 0.750
ID 55, angle 50.2, defocus 3.1 vs 2.9, score 3.295 vs 0.947
ID 4, angle -52.0, defocus 3.4 vs 3.0, score 2.968 vs 0.671
ID 56, angle 52.2, defocus 3.1 vs 2.7, score 3.287 vs 0.985
ID 3, angle -54.0, defocus 3.4 vs 3.1, score 2.990 vs 0.628
ID 57, angle 54.2, defocus 3.1 vs 2.9, score 3.436 vs 0.584
ID 2, angle -56.0, defocus 3.4 vs 3.5, score 2.891 vs 0.593
ID 58, angle 56.1, defocus 3.2 vs 2.9, score 3.245 vs 0.569
ID 1, angle -58.0, defocus 2.6 vs 2.9, score 3.003 vs 0.410
ID 59, angle 58.2, defocus 3.2 vs 3.1, score 3.438 vs 0.444
ID 0, angle -60.1, defocus 2.6 vs 2.6, score 2.763 vs 0.331
ID 60, angle 60.2, defocus 3.1 vs 3.0, score 3.435 vs 0.444
Average score: Current hand - 3.390, flipped hand - 2.067
Defocus std: Current hand - 0.225, flipped hand - 0.309
Current hand is better than the flipped hand in 93.4% tilt images
The handedness (--tltax=-355.7) seems to be correct. Rerun CTF estimation without the checkhand option to finish the process.
running:  e2spt_tomoctf.py tiltseries/CTEM_tomo3.hdf --nolog --verbose 0 --dfrange=2.0,7.0,0.02 --psrange=10,15,5 --tilesize=256 --voltage=300 --cs=2.7 --nref=15 --stepx=20 --stepy=40 --checkhand --ppid=-2
Reading tilt series tiltseries/CTEM_tomo3.hdf...
Checking handedness of the tomogram. Will NOT write metadata output...
Current tilt axis rotation -355.45
Comparing current hand vs flipped hand..
ID 30, angle -0.3, defocus 3.2 vs 3.2, score 3.992 vs 3.992
ID 29, angle -1.5, defocus 3.4 vs 3.5, score 4.413 vs 4.392
ID 28, angle -2.6, defocus 3.5 vs 3.5, score 4.028 vs 4.076
ID 31, angle 2.9, defocus 3.3 vs 3.3, score 3.302 vs 3.303
ID 27, angle -3.4, defocus 3.5 vs 3.5, score 4.644 vs 4.605
ID 32, angle 4.6, defocus 3.4 vs 3.4, score 3.335 vs 3.328
ID 26, angle -5.0, defocus 3.5 vs 3.4, score 3.959 vs 3.915
ID 33, angle 7.1, defocus 3.5 vs 3.5, score 3.338 vs 3.318
ID 25, angle -7.4, defocus 3.5 vs 3.5, score 3.957 vs 3.816
ID 24, angle -9.5, defocus 3.4 vs 3.5, score 3.750 vs 3.485
ID 34, angle 9.6, defocus 3.4 vs 3.5, score 3.398 vs 3.146
ID 23, angle -11.8, defocus 3.4 vs 3.4, score 3.603 vs 3.147
ID 35, angle 12.1, defocus 3.4 vs 3.4, score 3.311 vs 3.098
ID 22, angle -13.6, defocus 3.4 vs 3.4, score 3.604 vs 2.967
ID 36, angle 14.0, defocus 3.4 vs 3.4, score 3.456 vs 3.189
ID 21, angle -15.7, defocus 3.4 vs 3.4, score 3.563 vs 2.770
ID 37, angle 16.1, defocus 3.3 vs 3.4, score 3.203 vs 2.430
ID 20, angle -17.8, defocus 3.4 vs 3.4, score 3.317 vs 2.582
ID 38, angle 18.1, defocus 3.3 vs 3.3, score 3.468 vs 2.716
ID 39, angle 19.9, defocus 3.4 vs 3.4, score 3.291 vs 2.419
ID 19, angle -20.2, defocus 3.3 vs 3.3, score 2.313 vs 1.565
ID 40, angle 21.8, defocus 3.3 vs 3.2, score 2.913 vs 1.908
ID 18, angle -22.2, defocus 3.4 vs 3.4, score 2.250 vs 1.346
ID 41, angle 23.9, defocus 3.3 vs 3.4, score 3.073 vs 1.866
ID 17, angle -24.1, defocus 3.4 vs 3.3, score 2.099 vs 1.347
ID 42, angle 25.9, defocus 3.3 vs 3.2, score 3.218 vs 1.807
ID 16, angle -26.0, defocus 3.4 vs 3.4, score 2.195 vs 1.530
ID 43, angle 27.9, defocus 3.2 vs 3.3, score 3.022 vs 1.746
ID 15, angle -28.1, defocus 3.4 vs 3.4, score 2.354 vs 1.380
ID 44, angle 29.9, defocus 3.3 vs 3.2, score 3.164 vs 1.802
ID 14, angle -30.2, defocus 3.4 vs 3.3, score 2.446 vs 1.125
ID 45, angle 31.9, defocus 3.2 vs 3.1, score 3.062 vs 1.336
ID 13, angle -31.9, defocus 3.4 vs 3.2, score 2.267 vs 1.224
ID 46, angle 33.9, defocus 3.2 vs 3.0, score 2.904 vs 1.358
ID 12, angle -33.9, defocus 3.5 vs 3.2, score 2.452 vs 1.198
ID 47, angle 35.9, defocus 3.2 vs 2.9, score 2.997 vs 1.185
ID 11, angle -36.1, defocus 3.5 vs 3.2, score 2.423 vs 1.292
ID 48, angle 37.8, defocus 3.1 vs 3.3, score 3.166 vs 1.001
ID 10, angle -38.0, defocus 3.5 vs 3.3, score 2.502 vs 1.212
ID 49, angle 39.8, defocus 3.1 vs 2.6, score 2.928 vs 0.914
ID 9, angle -39.9, defocus 3.3 vs 2.9, score 2.508 vs 1.015
ID 50, angle 41.8, defocus 3.1 vs 2.6, score 3.195 vs 0.915
ID 8, angle -41.9, defocus 3.5 vs 2.8, score 2.347 vs 0.841
ID 7, angle -43.8, defocus 3.4 vs 2.9, score 2.510 vs 0.951
ID 51, angle 43.9, defocus 3.1 vs 2.7, score 2.935 vs 1.171
ID 52, angle 45.9, defocus 3.0 vs 2.7, score 3.183 vs 0.844
ID 6, angle -45.9, defocus 3.4 vs 2.8, score 2.558 vs 0.873
ID 53, angle 48.0, defocus 3.0 vs 2.4, score 3.192 vs 0.777
ID 5, angle -48.1, defocus 3.3 vs 3.4, score 2.504 vs 0.729
ID 54, angle 49.9, defocus 3.0 vs 2.6, score 2.749 vs 0.714
ID 4, angle -49.9, defocus 3.3 vs 2.5, score 2.900 vs 0.704
ID 55, angle 51.8, defocus 3.0 vs 2.3, score 3.229 vs 0.541
ID 3, angle -51.9, defocus 3.3 vs 3.9, score 2.886 vs 0.512
ID 2, angle -53.9, defocus 3.2 vs 2.5, score 3.167 vs 0.525
ID 56, angle 54.0, defocus 3.0 vs 2.7, score 3.258 vs 0.720
ID 57, angle 55.9, defocus 2.9 vs 2.6, score 3.233 vs 0.524
ID 1, angle -55.9, defocus 3.2 vs 2.6, score 2.728 vs 0.456
ID 0, angle -57.9, defocus 3.0 vs 3.7, score 3.068 vs 0.321
ID 58, angle 57.9, defocus 2.9 vs 2.7, score 3.291 vs 0.481
ID 59, angle 59.9, defocus 2.9 vs 3.1, score 3.357 vs 0.466
ID 60, angle 61.9, defocus 2.9 vs 4.0, score 3.244 vs 0.416
Average score: Current hand - 3.094, flipped hand - 1.792
Defocus std: Current hand - 0.176, flipped hand - 0.369
Current hand is better than the flipped hand in 95.1% tilt images
The handedness (--tltax=-355.5) seems to be correct. Rerun CTF estimation without the checkhand option to finish the process.
All threads complete


e2tomogram.py:
e2tomogram.py tiltseries/CTEM_tomo3.hdf --alltiltseries --zeroid=-1 --tiltstep=2.0 --npk=20 --tiltkeep=0.9 --outsize=1k --niter=2,1,1,1 --bytile --pkkeep=0.9 --compressbits=8 --clipz=96 --bxsz=32 --correctrot --filterres=40.0 --rmbeadthr=-1.0 --threads=20 --patchtrack=-1

results: (left: EMD-3418, right: my result after 3drefinement)
10341660998444_.pic_hd.jpg

Muyuan Chen

unread,
Aug 21, 2022, 3:14:49 AM8/21/22
to em...@googlegroups.com
This is indeed quite odd. Yes, there are cases where the check handedness from tomoctf.py does not work. It looks at the geometry of the tilt axis and tilt angle, and decide which side of image is closer to focal plane. However, in some situation the data collection software can flip the images along the y axis, then there is no way the program can detect it. Even in this types of situations, it is better to use the handedness reported by the program, so the defocus estimation is more accurate. Just flip the maps later. 
Saying that, I don't think this should happen in the tutorial dataset. Are you using the one from EMAN2 website or from EMPIAR? I thought they would be the same but I haven't tested for a long time. It is possible something strange happened when you import tilt series I guess? Again, even if that is the case, just use the handedness from e2spt_tomoctf and flip the final structure. It shouldn't affect the resolution in theory. 
The --flip option from e2tomogram should be used only when e2spt_tomoctf tells you the handedness is wrong. Otherwise it leads to worse defocus estimation. 
Muyuan

--
--
----------------------------------------------------------------------------------------------
You received this message because you are subscribed to the Google
Groups "EMAN2" group.
To post to this group, send email to em...@googlegroups.com
To unsubscribe from this group, send email to eman2+un...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/eman2

---
You received this message because you are subscribed to the Google Groups "EMAN2" group.
To unsubscribe from this group and stop receiving emails from it, send an email to eman2+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/eman2/c43cf7d1-57cf-4ab3-b89b-572e6d67731an%40googlegroups.com.

黄振

unread,
Aug 21, 2022, 7:37:26 AM8/21/22
to EMAN2
Hi Muyuan,

Thanks for your prompt reply!

I did use the data from EMAN2 tutorial(EMPIAR 10064). I have always followed the tutorial but the handedness of all the results is incorrect. Actually I have no idea about what has happened when processing that data, too.

Yet I still have one problem: Does EMAN2 have the function to flip particle structures directly? If so, how to use that command then?

Best,
Zhen Huang
ZheJiang University


Muyuan Chen

unread,
Aug 21, 2022, 1:38:01 PM8/21/22
to em...@googlegroups.com
e2proc3d.py a.hdf b.hdf —process xform.flip:axis=z

On Aug 21, 2022, at 4:37 AM, 黄振 <zhenhu...@gmail.com> wrote:

Hi Muyuan,
Reply all
Reply to author
Forward
0 new messages