Closed jstitlow closed 5 years ago
Yes, the code was broken. Your conda environment looks okay. My apologies and thank you for reporting. I have fixed the source code (v0.71). Could you reinstall Chromagnon? Binary releases for linux are still broken, but I am going to release a newer version soon (v0.80), so I will combine this fix into the next release.
Awesome! The code works.
FYI, several errors are thrown at initialisation and for deprecation:
(chromagnon) bioc1301@mprocessor1:~/src/Chromagnon$ chromagnon ~/tmp/chromagnon/aligned/20190517_MB077c_myrSNAP_CamKIIYFP_YFP647n_JF549_viol_1h_p1lMB.tif -R ~/tmp/chromagnon/cal/20190517_MB077c_myrSNAP_CamKIIYFP_YFP647n_JF549_viol_1h_p1lMB_cal.tif -E dv
arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
canvas[slc] = img
/usr/people/bioc1301/src/Chromagnon/Chromagnon/PriCommon/imgFilters.py:555: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
edges[0] = arr[slc].reshape(smooth_shape)
/usr/people/bioc1301/src/Chromagnon/Chromagnon/PriCommon/imgFilters.py:559: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
edges[1] = arr[slc].reshape(smooth_shape)
/usr/people/bioc1301/src/Chromagnon/Chromagnon/PriCommon/imgFilters.py:574: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
edgeArr = edges[s].reshape(arr[slc].shape)
/usr/people/bioc1301/src/Chromagnon/Chromagnon/PriCommon/imgFilters.py:576: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
arr[slc] = arr[slc] + edgeArr * (smooth - f) # casting rule
/usr/people/bioc1301/src/Chromagnon/Chromagnon/PriCommon/imgFit.py:511: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
irs = irs[slc]
/usr/people/bioc1301/src/Chromagnon/Chromagnon/Priithon/fftfuncs.py:15: ComplexWarning: Casting complex values to real discards the imaginary part
return N.fromfunction(f,s).astype(t)
/usr/people/bioc1301/src/Chromagnon/Chromagnon/PriCommon/imgFilters.py:373: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
canvas = arr[slc]
/usr/people/bioc1301/src/Chromagnon/Chromagnon/PriCommon/xcorr.py:275: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
cc[slc] = c[slc]
/usr/people/bioc1301/src/Chromagnon/Chromagnon/PriCommon/imgFit.py:83: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
return _fitGaussianND(img[slices], inds, zyx, sigma, mean_max)
calculating shifts for time 0 channel 0
max_shift_pxl 99.99999850988391
in iteration, initial geuss is [-0.655935 0. 0. 1. 1. ]
/usr/people/bioc1301/src/Chromagnon/Chromagnon/alignfuncs.py:359: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
b = b[slc]
/usr/people/bioc1301/src/Chromagnon/Chromagnon/alignfuncs.py:360: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
c = ref[slc]
0 [-0.47579592 -1.5141594 0.01539027 1.0007918 0.9962891 ]
1 [-0.41610363 -1.6797029 0.03410653 1.0013769 0.9958165 ]
2 [-0.37446296 -1.7281314 0.04174636 1.001767 0.99560857]
3 [-0.3478168 -1.7460408 0.04497666 1.0020258 0.99547523]
4 [-0.32643136 -1.7462691 0.04340621 1.0021842 0.9953498 ]
5 [-0.31438527 -1.7447903 0.04296636 1.002292 0.99527353]
6 [-0.30653042 -1.7437115 0.04285695 1.0023651 0.9952233 ]
7 [-0.30144313 -1.7433281 0.04278843 1.0024146 0.9951937 ]
8 [-0.29805195 -1.7431935 0.04274633 1.002448 0.99517626]
max_shift_pxl 99.99999850988391
in iteration, initial geuss is [-0.655935 -0.10818224 0. 1. 1. ]
0 [-0.25619993 -0.12712073 0.07709513 1.0014585 1.0006111 ]
1 [-0.13874698 -0.18642828 0.09701782 1.002539 1.0009738 ]
2 [-0.06554615 -0.20656332 0.09892514 1.0032572 1.001206 ]
3 [-0.02465764 -0.2040002 0.09734711 1.0037364 1.0013527 ]
4 [ 0.00189168 -0.1980614 0.09543274 1.004055 1.0014489 ]
5 [ 0.01963554 -0.19272645 0.09385806 1.004267 1.0015134 ]
6 [ 0.03110931 -0.18886998 0.0926885 1.004408 1.0015563 ]
7 [ 0.03846591 -0.18607073 0.0918119 1.0045007 1.0015849 ]
8 [ 0.04318278 -0.18408868 0.09117529 1.0045615 1.0016038 ]
9 [ 0.04623429 -0.1826908 0.09076802 1.0046011 1.0016165 ]
10 [ 0.04824604 -0.18177964 0.09051798 1.0046271 1.0016248 ]
11 [ 0.04962585 -0.18119632 0.09035168 1.0046444 1.0016304 ]
12 [ 0.05052469 -0.18082242 0.09024388 1.0046557 1.0016341 ]
13 [ 0.05111329 -0.1805816 0.09017472 1.0046632 1.0016366 ]
14 [ 0.05150394 -0.18043035 0.09012899 1.0046681 1.0016383 ]
time: 0, wave: 0, tx:-0.180, ty:0.052, tz:-1.743, r:0.090, mx:1.002, my:1.005, mz:0.995
making an initial guess for channel 2
calculating shifts for time 0 channel 2
max_shift_pxl 99.99999850988391
in iteration, initial geuss is [-0.6611322 0. 0. 1. 1. ]
0 [-0.48961884 -1.5025438 0.0093678 1.000747 0.9960256 ]
1 [-0.42488322 -1.6619251 0.02766771 1.0013418 0.9951216 ]
2 [-0.3788788 -1.705754 0.03418181 1.0017457 0.99463654]
3 [-0.35023412 -1.7187606 0.03608891 1.0020195 0.9943516 ]
4 [-0.33395806 -1.7131476 0.03025071 1.002159 0.99402505]
5 [-0.32387456 -1.7062966 0.02846622 1.0022558 0.99383897]
6 [-0.31744274 -1.7026821 0.02789135 1.0023224 0.99372375]
7 [-0.31272024 -1.7010705 0.02768012 1.0023682 0.9936553 ]
8 [-0.30951983 -1.7003895 0.02762345 1.0023993 0.9936156 ]
9 [-0.30734703 -1.7001152 0.02761789 1.0024205 0.9935926 ]
max_shift_pxl 99.99999850988391
in iteration, initial geuss is [-0.6611322 -0.11054116 0. 1. 1. ]
0 [-0.2844795 -0.12733977 0.07559638 1.0014066 1.000583 ]
1 [-0.16994168 -0.1879344 0.09574796 1.002428 1.0009375 ]
2 [-0.09768029 -0.20567106 0.0986205 1.0031345 1.0011747 ]
3 [-0.05485167 -0.20407115 0.0975136 1.0036118 1.0013262 ]
4 [-0.02783814 -0.1989002 0.09577332 1.0039306 1.0014238 ]
5 [-0.00980865 -0.19266884 0.09368856 1.0041366 1.00149 ]
6 [ 0.00100487 -0.18853658 0.09232555 1.0042722 1.0015328 ]
7 [ 0.00791441 -0.1871778 0.09201682 1.0043672 1.0015591 ]
8 [ 0.01305894 -0.18610348 0.09168039 1.0044307 1.0015763 ]
9 [ 0.01652606 -0.18523055 0.09137753 1.0044729 1.001587 ]
10 [ 0.01882446 -0.1846313 0.09117977 1.0045006 1.001594 ]
11 [ 0.02043936 -0.18429866 0.09103564 1.0045191 1.0015985 ]
12 [ 0.0214922 -0.18404445 0.09093867 1.0045313 1.0016015 ]
13 [ 0.02217207 -0.18386093 0.09087646 1.0045393 1.0016034 ]
14 [ 0.02261624 -0.18374333 0.09083719 1.0045445 1.0016046 ]
time: 0, wave: 2, tx:-0.184, ty:0.023, tz:-1.700, r:0.091, mx:1.002, my:1.005, mz:0.994
making an initial guess for channel 3
calculating shifts for time 0 channel 3
max_shift_pxl 99.99999850988391
in iteration, initial geuss is [-0.4755958 0. 0. 1. 1. ]
0 [-0.37728533 -0.6777616 0.0072792 1.0005596 0.9983531 ]
1 [-0.32848233 -0.77950746 0.01395683 1.0009515 0.9977409 ]
2 [-0.30006027 -0.8028838 0.0165473 1.0011945 0.99730676]
3 [-0.28248042 -0.8072908 0.01745976 1.0013449 0.9970056 ]
4 [-0.27075174 -0.8078026 0.01770524 1.0014406 0.9968208 ]
5 [-0.26343468 -0.80740845 0.01775133 1.0014989 0.9967092 ]
6 [-0.2587832 -0.8068548 0.0177551 1.0015357 0.9966397]
7 [-0.25599366 -0.806479 0.01771453 1.001559 0.99659836]
8 [-0.25453517 -0.80635476 0.01764404 1.0015749 0.996576 ]
9 [-0.2533493 -0.8062635 0.01764829 1.0015851 0.99656373]
max_shift_pxl 99.99999850988391
in iteration, initial geuss is [-0.4755958 -0.08890915 0. 1. 1. ]
0 [-0.2567926 -0.09689839 0.04118715 1.0007735 1.0003728 ]
1 [-0.18926744 -0.13321388 0.05170985 1.0013582 1.0006067 ]
2 [-0.14987747 -0.13993171 0.05317309 1.0017614 1.0007565 ]
3 [-0.1254161 -0.13792345 0.0523279 1.0020322 1.0008541 ]
4 [-0.11531007 -0.13386936 0.04939884 1.0021995 1.0009255 ]
5 [-0.1066874 -0.12899506 0.04780095 1.0023059 1.0009729 ]
6 [-0.10089891 -0.12593442 0.04686897 1.0023746 1.0010054 ]
7 [-0.09721287 -0.12394731 0.04628264 1.0024189 1.0010273 ]
8 [-0.09493086 -0.12264851 0.04587989 1.0024471 1.0010424 ]
9 [-0.09342189 -0.12176588 0.0456178 1.0024656 1.0010525 ]
10 [-0.09245347 -0.12110858 0.04542723 1.0024775 1.0010597 ]
11 [-0.09181359 -0.12069863 0.04531708 1.0024853 1.0010645 ]
12 [-0.09142694 -0.12041454 0.04523368 1.0024903 1.0010679 ]
13 [-0.0911418 -0.12023004 0.0451786 1.0024936 1.0010701 ]
time: 0, wave: 3, tx:-0.120, ty:-0.091, tz:-0.806, r:0.045, mx:1.001, my:1.002, mz:0.997
/usr/people/bioc1301/src/Chromagnon/Chromagnon/aligner.py:910: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
arr = arr[self.cropSlice]
3D phase correlation for time 0 channel 0 iter 0
the result of the last correlation [ 0.14869345 0.11723474 -0.10499239]
3D phase correlation for time 0 channel 0 iter 1
the result of the last correlation [ 0.01381493 0.00032259 -0.00223159]
3D phase correlation for time 0 channel 2 iter 0
the result of the last correlation [ 0.14371539 0.12686965 -0.11065219]
3D phase correlation for time 0 channel 2 iter 1
the result of the last correlation [ 0.01439123 0.00110986 -0.00239325]
3D phase correlation for time 0 channel 3 iter 0
the result of the last correlation [ 0.00523197 0.04077604 -0.02991628]
3D phase correlation for time 0 channel 3 iter 1
the result of the last correlation [ 0.00063768 0.00077122 -0.00069238]
Finding affine parameters done!
loading /usr/people/bioc1301/tmp/chromagnon/cal/20190517_MB077c_myrSNAP_CamKIIYFP_YFP647n_JF549_viol_1h_p1lMB_cal.tif.chromagnon.csv
tif
Applying affine transformation to the target image, t: 0, w: 0
Copying reference image, t: 0, w: 1
/usr/people/bioc1301/src/Chromagnon/Chromagnon/aligner.py:1011: FutureWarning: Using a non-tuple sequence for multidimensional indexing is deprecated; use arr[tuple(seq)]
instead of arr[seq]
. In the future this will be interpreted as an array index, arr[np.array(seq)]
, which will result either in an error or a different result.
arr = arr[self.cropSlice]
Applying affine transformation to the target image, t: 0, w: 2
Applying affine transformation to the target image, t: 0, w: 3
done
Hello, Just upgraded to v0.70 and I get the following error when attempting to run on Linux system:
Exception in thread Thread-1: Traceback (most recent call last): File "/usr/people/bioc1301/miniconda3/envs/chromagnon/lib/python2.7/threading.py", line 801, in __bootstrap_inner self.run() File "/usr/people/bioc1301/miniconda3/envs/chromagnon/lib/python2.7/site-packages/Chromagnon/threads.py", line 127, in run max_shift = parms[10] IndexError: list index out of range
Was testing in a conda environment that worked with v0.69 (here is the conda_spec file).
Any ideas? Thanks Atsushi!