Skip to content

Commit e9ba749

Browse files
authored
Merge branch 'main' into fbp2dastra
2 parents 8a7aa34 + 6ea8f1e commit e9ba749

13 files changed

+57
-39
lines changed

httomo_backends/methods_database/packages/backends/httomolibgpu/httomolibgpu.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ recon:
154154
memory_gpu:
155155
multiplier: None
156156
method: module
157-
FBP:
157+
FBP3d_tomobar:
158158
pattern: sinogram
159159
output_dims_change: True
160160
implementation: gpu_cupy
@@ -163,7 +163,7 @@ recon:
163163
memory_gpu:
164164
multiplier: None
165165
method: module
166-
SIRT:
166+
SIRT3d_tomobar:
167167
pattern: sinogram
168168
output_dims_change: True
169169
implementation: gpu_cupy
@@ -172,7 +172,7 @@ recon:
172172
memory_gpu:
173173
multiplier: None
174174
method: module
175-
CGLS:
175+
CGLS3d_tomobar:
176176
pattern: sinogram
177177
output_dims_change: True
178178
implementation: gpu_cupy

httomo_backends/methods_database/packages/backends/httomolibgpu/supporting_funcs/recon/algorithm.py

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,13 @@
2727

2828
__all__ = [
2929
"_calc_memory_bytes_FBP2d_astra",
30-
"_calc_memory_bytes_FBP",
31-
"_calc_memory_bytes_SIRT",
32-
"_calc_memory_bytes_CGLS",
33-
"_calc_output_dim_FBP2d_astra",
34-
"_calc_output_dim_FBP",
35-
"_calc_output_dim_SIRT",
36-
"_calc_output_dim_CGLS",
30+
"_calc_memory_bytes_FBP3d_tomobar",
31+
"_calc_memory_bytes_SIRT3d_tomobar",
32+
"_calc_memory_bytes_CGLS3d_tomobar",
33+
"_calc_output_dim_FBP2d_astra",
34+
"_calc_output_dim_FBP3d_tomobar",
35+
"_calc_output_dim_SIRT3d_tomobar",
36+
"_calc_output_dim_CGLS3d_tomobar",
3737
]
3838

3939

@@ -55,15 +55,15 @@ def _calc_output_dim_FBP2d_astra(non_slice_dims_shape, **kwargs):
5555
return __calc_output_dim_recon(non_slice_dims_shape, **kwargs)
5656

5757

58-
def _calc_output_dim_FBP(non_slice_dims_shape, **kwargs):
58+
def _calc_output_dim_FBP3d_tomobar(non_slice_dims_shape, **kwargs):
5959
return __calc_output_dim_recon(non_slice_dims_shape, **kwargs)
6060

6161

62-
def _calc_output_dim_SIRT(non_slice_dims_shape, **kwargs):
62+
def _calc_output_dim_SIRT3d_tomobar(non_slice_dims_shape, **kwargs):
6363
return __calc_output_dim_recon(non_slice_dims_shape, **kwargs)
6464

6565

66-
def _calc_output_dim_CGLS(non_slice_dims_shape, **kwargs):
66+
def _calc_output_dim_CGLS3d_tomobar(non_slice_dims_shape, **kwargs):
6767
return __calc_output_dim_recon(non_slice_dims_shape, **kwargs)
6868

6969

@@ -76,7 +76,7 @@ def _calc_memory_bytes_FBP2d_astra(
7676
return (1, 0)
7777

7878

79-
def _calc_memory_bytes_FBP(
79+
def _calc_memory_bytes_FBP3d_tomobar(
8080
non_slice_dims_shape: Tuple[int, int],
8181
dtype: np.dtype,
8282
**kwargs,
@@ -133,7 +133,7 @@ def _calc_memory_bytes_FBP(
133133

134134
# 7. astra backprojection will generate an output array
135135
# https://github.com/dkazanc/ToMoBAR/blob/54137829b6326406e09f6ef9c95eb35c213838a7/tomobar/astra_wrappers/astra_base.py#L524
136-
output_dims = _calc_output_dim_FBP(non_slice_dims_shape, **kwargs)
136+
output_dims = _calc_output_dim_FBP3d_tomobar(non_slice_dims_shape, **kwargs)
137137
recon_output_size = np.prod(output_dims) * np.float32().itemsize
138138

139139
# 7. astra backprojection makes a copy of the input
@@ -163,14 +163,14 @@ def _calc_memory_bytes_FBP(
163163
return (tot_memory_bytes, fixed_amount)
164164

165165

166-
def _calc_memory_bytes_SIRT(
166+
def _calc_memory_bytes_SIRT3d_tomobar(
167167
non_slice_dims_shape: Tuple[int, int],
168168
dtype: np.dtype,
169169
**kwargs,
170170
) -> Tuple[int, int]:
171171
DetectorsLengthH = non_slice_dims_shape[1]
172172
# calculate the output shape
173-
output_dims = _calc_output_dim_SIRT(non_slice_dims_shape, **kwargs)
173+
output_dims = _calc_output_dim_SIRT3d_tomobar(non_slice_dims_shape, **kwargs)
174174

175175
in_data_size = np.prod(non_slice_dims_shape) * dtype.itemsize
176176
out_data_size = np.prod(output_dims) * dtype.itemsize
@@ -181,14 +181,14 @@ def _calc_memory_bytes_SIRT(
181181
return (tot_memory_bytes, 0)
182182

183183

184-
def _calc_memory_bytes_CGLS(
184+
def _calc_memory_bytes_CGLS3d_tomobar(
185185
non_slice_dims_shape: Tuple[int, int],
186186
dtype: np.dtype,
187187
**kwargs,
188188
) -> Tuple[int, int]:
189189
DetectorsLengthH = non_slice_dims_shape[1]
190190
# calculate the output shape
191-
output_dims = _calc_output_dim_CGLS(non_slice_dims_shape, **kwargs)
191+
output_dims = _calc_output_dim_CGLS3d_tomobar(non_slice_dims_shape, **kwargs)
192192

193193
in_data_size = np.prod(non_slice_dims_shape) * dtype.itemsize
194194
out_data_size = np.prod(output_dims) * dtype.itemsize

httomo_backends/pipelines_full/gpu_360_distortion_FBP_directive.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
module_path: httomolibgpu.misc.morph
1111
- method: remove_stripe_based_sorting
1212
module_path: httomolibgpu.prep.stripe
13-
- method: FBP
13+
- method: FBP3d_tomobar
1414
module_path: httomolibgpu.recon.algorithm
1515
- method: calculate_stats
1616
module_path: httomo.methods

httomo_backends/pipelines_full/gpu_360_paganin_FBP_directive.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@
66
module_path: httomolibgpu.recon.rotation
77
- method: sino_360_to_180
88
module_path: httomolibgpu.misc.morph
9-
- method: paganin_filter_tomopy
10-
module_path: httomolibgpu.prep.phase
119
- method: remove_stripe_based_sorting
1210
module_path: httomolibgpu.prep.stripe
13-
- method: FBP
11+
- method: paganin_filter_tomopy
12+
module_path: httomolibgpu.prep.phase
13+
- method: FBP3d_tomobar
1414
module_path: httomolibgpu.recon.algorithm
1515
- method: calculate_stats
1616
module_path: httomo.methods

httomo_backends/pipelines_full/gpu_diad_FBP_directive.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
module_path: httomolibgpu.prep.normalize
99
- method: remove_stripe_based_sorting
1010
module_path: httomolibgpu.prep.stripe
11-
- method: FBP
11+
- method: FBP3d_tomobar
1212
module_path: httomolibgpu.recon.algorithm
1313
- method: calculate_stats
1414
module_path: httomo.methods

httomo_backends/pipelines_full/gpu_diad_FBP_noimagesaving_directive.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@
88
module_path: httomolibgpu.prep.normalize
99
- method: remove_stripe_based_sorting
1010
module_path: httomolibgpu.prep.stripe
11-
- method: FBP
11+
- method: FBP3d_tomobar
1212
module_path: httomolibgpu.recon.algorithm
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
- method: standard_tomo
2+
module_path: httomo.data.hdf.loaders
3+
- method: find_center_vo
4+
module_path: httomolibgpu.recon.rotation
5+
- method: normalize
6+
module_path: httomolibgpu.prep.normalize
7+
- method: FBP2d_astra
8+
module_path: httomolibgpu.recon.algorithm
9+

httomo_backends/pipelines_full/gpu_pipelineFBP_denoising_directive.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
module_path: httomolibgpu.prep.normalize
99
- method: remove_all_stripe
1010
module_path: httomolibgpu.prep.stripe
11-
- method: FBP
11+
- method: FBP3d_tomobar
1212
module_path: httomolibgpu.recon.algorithm
1313
- method: total_variation_PD
1414
module_path: httomolibgpu.misc.denoise

httomo_backends/pipelines_full/gpu_pipelineFBP_directive.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
module_path: httomolibgpu.prep.normalize
99
- method: remove_all_stripe
1010
module_path: httomolibgpu.prep.stripe
11-
- method: FBP
11+
- method: FBP3d_tomobar
1212
module_path: httomolibgpu.recon.algorithm
1313
- method: calculate_stats
1414
module_path: httomo.methods
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
- method: standard_tomo
2+
module_path: httomo.data.hdf.loaders
3+
- method: find_center_vo
4+
module_path: httomolibgpu.recon.rotation
5+
- method: normalize
6+
module_path: httomolibgpu.prep.normalize
7+
- method: LPRec3d_tomobar
8+
module_path: httomolibgpu.recon.algorithm
9+

0 commit comments

Comments
 (0)