Skip to content
Snippets Groups Projects
Commit 76f4053e authored by Wolfgang Ludwig's avatar Wolfgang Ludwig
Browse files

adapting Gt6DreconstructionAlgorithmFactory for sample movements durng scan

parent 4eac6426
No related branches found
No related tags found
No related merge requests found
......@@ -230,7 +230,7 @@ classdef Gt6DReconstructionAlgorithmFactory < handle
if (~isempty(find(parent_pos_shared_bls == shared_blob_pos_inc, 1)))
curr_or = sampler(ii_o_reg).get_reference_grain();
reg_ids(ii_o_reg) = curr_or.id;
reg_ids(ii_o_reg) = curr_or.id(1); % hope this is the right fix...
end
end
reg_ids = reg_ids(reg_ids > 0);
......@@ -763,6 +763,7 @@ classdef Gt6DReconstructionAlgorithmFactory < handle
fprintf('Blob (n.) | Blob w lims | Projs w lims | Padding | n-interp | Size | Blob Int | Scatter Int\n')
fprintf('----------+------------------------+--------------+---------+----------+------+----------+-------------\n')
for ii_b = 1:tot_blobs
try
fprintf('%03d (%03d) | %4d:%4d -> %4d:%4d | %4d:%4d | %2d:%2d | %2d | 1:%2d | %8s | %s [%s %s]\n', ...
ii_b, sel_incl_indx(ii_b), ...
bl(ii_b).bbwim, blobs_w_lims_pad(ii_b, :),...
......@@ -773,6 +774,8 @@ classdef Gt6DReconstructionAlgorithmFactory < handle
sprintf('%3.3g', scatter_ints_avg(ii_b)), ...
sprintf('%3.3g', min(scatter_ints_ors(ii_b, :))), ...
sprintf('%3.3g', max(scatter_ints_ors(ii_b, :))) );
catch
end
end
fprintf('----------+------------------------+--------------+---------+----------+------+----------+-------------\n')
......@@ -1047,6 +1050,8 @@ classdef Gt6DReconstructionAlgorithmFactory < handle
dvec_sam = cat(1, ors_allblobs(:).dvecsam);
rot_w_l2s = cat(3, ors_allblobs(:).srot);
% account for sample shifts relative to rotation axis
[~, shifts_sam] = gtMatchGetSampleShifts([], [ors_allblobs.omega]);
proj_geom = gtGeoProjForReconstruction(...
dvec_sam, rot_w_l2s, ref_gr.center, bb_bls_uv_oi, [], ...
......@@ -1054,7 +1059,7 @@ classdef Gt6DReconstructionAlgorithmFactory < handle
self.parameters.labgeo, ...
self.parameters.samgeo, ...
self.parameters.recgeo(self.det_index), ...
'ASTRA_grain');
'ASTRA_grain', shifts_sam);
if (self.volume_downscaling > 1)
proj_geom(:, 4:12) = proj_geom(:, 4:12) / self.volume_downscaling;
......@@ -1159,7 +1164,8 @@ classdef Gt6DReconstructionAlgorithmFactory < handle
dvec_lab = ors_allblobs(ii_o).dvec(ind_of_blob, :);
dvec_sam = gtGeoLab2Sam(dvec_lab, rot_w_l2s, ...
self.parameters.labgeo, self.parameters.samgeo, true);
% accounting for sample shifts relative to rotation axis
[~, shifts_sam] = gtMatchGetSampleShifts([], [ors_allblobs.omega]);
proj_geom = gtGeoProjForReconstruction(...
dvec_sam, rot_w_l2s, ref_gr.center, ...
bb_bls_uv(ind_of_blob, :), [], ...
......@@ -1167,7 +1173,7 @@ classdef Gt6DReconstructionAlgorithmFactory < handle
self.parameters.labgeo, ...
self.parameters.samgeo, ...
self.parameters.recgeo(self.det_index), ...
'ASTRA_grain');
'ASTRA_grain', shifts_sam);
if (self.volume_downscaling > 1)
proj_geom(:, 4:12) = proj_geom(:, 4:12) / self.volume_downscaling;
......@@ -1262,6 +1268,9 @@ classdef Gt6DReconstructionAlgorithmFactory < handle
dvec_sam = gtGeoLab2Sam(dvec_lab, rot_w_l2s, ...
self.parameters.labgeo, self.parameters.samgeo, true);
% accounting for sample shifts relative to rotation axis
[~, shifts_sam] = gtMatchGetSampleShifts([], [ors_allblobs.omega]);
proj_geom = gtGeoProjForReconstruction(...
dvec_sam, rot_w_l2s, ref_gr.center, ...
bb_bls_uv(ind_of_blob, :), [], ...
......@@ -1269,7 +1278,7 @@ classdef Gt6DReconstructionAlgorithmFactory < handle
self.parameters.labgeo, ...
self.parameters.samgeo, ...
self.parameters.recgeo(self.det_index), ...
'ASTRA_grain');
'ASTRA_grain', shifts_sam);
if (self.volume_downscaling > 1)
proj_geom(:, 4:12) = proj_geom(:, 4:12) / self.volume_downscaling;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment