From 8da84e29e7d88894ea2a0e02cf30b57bdcb36047 Mon Sep 17 00:00:00 2001 From: SylviaWhittle Date: Fri, 20 Dec 2024 11:49:48 +0000 Subject: [PATCH] Add: image grain crops to topostats object and fix process scan both regtest --- ...test_processing.test_process_scan_both.out | 10 +++++----- ...cess_scan_topostats_file_regtest.topostats | Bin 335700 -> 274920 bytes topostats/processing.py | 2 ++ 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/tests/_regtest_outputs/test_processing.test_process_scan_both.out b/tests/_regtest_outputs/test_processing.test_process_scan_both.out index 79aff8a940..7f5d4b2ca5 100644 --- a/tests/_regtest_outputs/test_processing.test_process_scan_both.out +++ b/tests/_regtest_outputs/test_processing.test_process_scan_both.out @@ -1,8 +1,8 @@ image_size_x_m image_size_y_m image_area_m2 image_size_x_px image_size_y_px image_area_px2 grains_number_above grains_per_m2_above grains_number_below grains_per_m2_below rms_roughness image minicircle_small 1.2646e-07 1.2646e-07 1.5993e-14 64 64 4096 3 1.8758e+14 1 6.2526e+13 6.8208e-10 - centre_x centre_y grain_number radius_min radius_max radius_mean radius_median height_min height_max height_median height_mean volume area area_cartesian_bbox smallest_bounding_width smallest_bounding_length smallest_bounding_area aspect_ratio threshold max_feret min_feret image grain_endpoints grain_junctions total_branch_lengths grain_width_mean total_contour_length average_end_to_end_distance -0 7.5100e-08 4.7559e-08 0 3.9431e-09 2.5631e-08 1.6016e-08 1.6680e-08 9.1991e-10 2.6422e-09 1.5338e-09 1.5341e-09 1.0543e-24 6.8721e-16 1.3198e-15 2.0539e-08 5.0379e-08 1.0347e-15 4.0769e-01 above 5.0379e-08 2.0539e-08 minicircle_small 1.0000e+00 1.0000e+00 8.4571e-08 8.2685e-09 6.5881e-08 8.8370e-09 -1 8.0241e-08 7.8677e-08 1 6.8951e-09 2.7188e-08 1.6272e-08 1.6263e-08 9.0630e-10 2.4586e-09 1.6144e-09 1.6264e-09 1.0352e-24 6.3645e-16 1.5931e-15 2.0174e-08 5.1212e-08 1.0332e-15 3.9394e-01 above 5.1262e-08 2.0174e-08 minicircle_small 0.0000e+00 0.0000e+00 7.3054e-08 7.6154e-09 5.8272e-08 0.0000e+00 -2 4.0012e-08 7.5644e-08 2 9.9461e-09 2.3654e-08 1.7561e-08 1.8364e-08 9.0641e-10 2.1066e-09 1.5939e-09 1.5493e-09 1.1192e-24 7.2236e-16 1.5462e-15 3.3592e-08 4.1496e-08 1.3940e-15 8.0952e-01 above 4.4405e-08 3.2528e-08 minicircle_small 0.0000e+00 0.0000e+00 1.0447e-07 7.8033e-09 8.7183e-08 0.0000e+00 -3 3.2366e-08 1.4036e-08 0 7.7690e-10 1.2272e-08 6.4301e-09 6.4170e-09 -3.7937e-10 -2.1207e-10 -2.4477e-10 -2.6816e-10 -3.0364e-26 1.1323e-16 3.0066e-16 7.0841e-09 2.1505e-08 1.5234e-16 3.2941e-01 below 2.2092e-08 7.0841e-09 minicircle_small NaN NaN NaN NaN NaN NaN + class_number subgrain_number grain_number centre_x centre_y radius_min radius_max radius_mean radius_median height_min height_max height_median height_mean volume area area_cartesian_bbox smallest_bounding_width smallest_bounding_length smallest_bounding_area aspect_ratio threshold max_feret min_feret image grain_endpoints grain_junctions total_branch_lengths grain_width_mean total_contour_length average_end_to_end_distance +0 1 0 0 3.7555e-08 8.9055e-08 3.9431e-09 2.5631e-08 1.6016e-08 1.6680e-08 9.1991e-10 2.6422e-09 1.5338e-09 1.5341e-09 1.0543e-24 6.8721e-16 1.3198e-15 2.0539e-08 5.0379e-08 1.0347e-15 4.0769e-01 above 5.0379e-08 2.0539e-08 minicircle_small 1.0000e+00 1.0000e+00 8.5729e-08 9.5493e-09 6.7087e-08 9.4020e-09 +1 1 0 1 7.4313e-08 8.8557e-08 6.8951e-09 2.7188e-08 1.6272e-08 1.6263e-08 9.0630e-10 2.4586e-09 1.6144e-09 1.6264e-09 1.0352e-24 6.3645e-16 1.5931e-15 2.0174e-08 5.1212e-08 1.0332e-15 3.9394e-01 above 5.1262e-08 2.0174e-08 minicircle_small 0.0000e+00 0.0000e+00 7.3054e-08 7.6878e-09 5.7989e-08 0.0000e+00 +2 1 0 2 7.9532e-08 4.0076e-08 9.9461e-09 2.3654e-08 1.7561e-08 1.8364e-08 9.0641e-10 2.1066e-09 1.5939e-09 1.5493e-09 1.1192e-24 7.2236e-16 1.5462e-15 3.3592e-08 4.1496e-08 1.3940e-15 8.0952e-01 above 4.4405e-08 3.2528e-08 minicircle_small 0.0000e+00 0.0000e+00 1.0331e-07 7.8754e-09 8.5725e-08 0.0000e+00 +3 1 0 0 2.0510e-08 2.9845e-08 7.7690e-10 1.2272e-08 6.4301e-09 6.4170e-09 -3.7937e-10 -2.1207e-10 -2.4477e-10 -2.6816e-10 -3.0364e-26 1.1323e-16 3.0066e-16 7.0841e-09 2.1505e-08 1.5234e-16 3.2941e-01 below 2.2092e-08 7.0841e-09 minicircle_small NaN NaN NaN NaN NaN NaN diff --git a/tests/resources/process_scan_topostats_file_regtest.topostats b/tests/resources/process_scan_topostats_file_regtest.topostats index 43a4380fb4e37d4f80ff3960db834945796860b5..9f06e06d6c9f6bd869ebbabc164aff37850b6ef0 100644 GIT binary patch delta 19151 zcmeHvX?Rpc)^Oh?q|*t|f$U*vAV32FI;;UA_rkD5)DRS**+L_t86^;9izCo+fyn^I zbgoj-5e%{zV1xvs35z7bFb3H!phHv!TSW~h7)A#XQNB90bl(oiyfZ((?|q;5`RnR3~YZDf4p)O-vCw zh9<{~B+D5u(hNPGW;Avb(f6;*3->-NrO6h38LgNz+*8vdHi&WQ%wQJ=M|f&J)(R{^ zTA?KppeP6!L_jiL;1{E%fMjaLVNu$nA+6nj8S+V?kDL{fOydI+up$DDMLf+&IBJBz zp5w7N0XWMsBykU7pclAf06Tc}zoX)Bq#Td#CfO@%BQ@oS8CCTXTBA5!3fHVhtjMNI zt+oE4ZBbQkAy{iP2WgHFs}X72M&ON;Mzu*HQQEZ7Fu|mGEb(Rf0Kpwgr7+nT9LV5s z2ARO7jtn<5IG8~jgH{Y(BPc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`m0sm%)3-aAT3{72*k3bqNGyi1SI&P0a;+}2GI(9~R@0Zo96VRe_6 zUBK^#>SrU%KVk8uAzEB5*>erxtWtK7?Wr(*sD!2yrgV40Z7COlL&$e}9b6uPLunli z95T@GuRYfJl<&25e*Ps^PolMTx|ewVz-3tHm)Gilhvrx7afYNnj|xeGD&v-nNsN&HKlUv-IUr^EtD!HOsP^HffNh4pK&9(Q3@k1^Y?*A2)yS}g1-+w9IDSi2YjJD7M+`XTwP!HnXpnl z;YzLK7DfuL^FxG{rU!E?RR=Sv^&y&-4upEKQd9`HQYo(>)O2IuvQkZekNblcQZlmRMHvX#c;b8sesQybaZ(JONo;B?~thcN^ cx1J?jvtC>WH|y!YBG#i1a!g<8>4TjA0cPw)_W%F@ diff --git a/topostats/processing.py b/topostats/processing.py index d2dd8d3948..b5f048c84d 100644 --- a/topostats/processing.py +++ b/topostats/processing.py @@ -1103,6 +1103,8 @@ def process_scan( grains_config=grains_config, ) + topostats_object["grain_crops"] = image_grain_crops + if image_grain_crops.above is not None or image_grain_crops.below is not None: # Grainstats : grainstats_df, height_profiles = run_grainstats(