-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tof #390
Tof #390
Conversation
…. Would need TOF bin selection. appears to already be in cstir.cpp cSTIR_getAcquisitionsDimensions needs to get number of TOF bins from STIR
thanks. Ideally, you modify the travis.yml to use the SuperBuild with appropriate |
…MR/SIRF into tof_pull_master
why closed? |
This was accidental, sorry. I wanted to use the name TOF for a more up to date branch and didn't realise it was the one used for this pull request. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I might have found a problem since my STIR commit UCL/STIR@3f4c94d. Possibly my choice for get_num_sinograms
to now include TOF bins wasn't all that great...
|
||
dim[0] = sptr_ad->get_num_tangential_poss(); | ||
dim[1] = sptr_ad->get_num_views(); | ||
dim[2] = sptr_ad->get_num_sinograms(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dim[2] = sptr_ad->get_num_sinograms(); | |
dim[2] = sptr_ad->get_num_non_tof_sinograms(); |
@@ -33,26 +33,33 @@ using namespace sirf; | |||
std::string PETAcquisitionData::_storage_scheme; | |||
shared_ptr<PETAcquisitionData> PETAcquisitionData::_template; | |||
|
|||
float | |||
PETAcquisitionData::norm() const | |||
float PETAcquisitionData::norm() const |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revert
|
||
for (seg_iter = seg.begin_all(); seg_iter != seg.end_all();) | ||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revert. no code clean-up in a "new feature PR"
|
||
if (s != 0) | ||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revert
|
||
for (seg_iter = seg.begin_all(); seg_iter != seg.end_all();) | ||
{ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revert
double r = *seg_iter++; | ||
t += r*r; | ||
} | ||
} | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
revert
|
||
#if ns >= 16: | ||
#tiles = (4, 4) | ||
#else: | ||
#tiles = None | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure why you did this, but I'd rather not do a surprising change in this PR
#err = show_3D_array(data[0,:,:,:], \ | ||
# index = sino[f : t], tile_shape = tiles, \ | ||
# label = 'sinogram', \ | ||
# xlabel = 'tang.pos', ylabel = 'view', \ | ||
# suptitle = title, show = (t == ns)) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why commented out?
def set_MAP_model(self, model): | ||
parms.set_char_par\ | ||
(self.handle, self.name, 'MAP_model', model) | ||
def set_maximum_relative_change(self, value): | ||
parms.set_float_par\ | ||
(self.handle, self.name, 'set_maximum_relative_change', value) | ||
def set_minimum_relative_change(self, value): | ||
parms.set_float_par\ | ||
(self.handle, self.name, 'set_minimum_relative_change', value) | ||
def get_objective_function(self): | ||
obj_fun = PoissonLogLikelihoodWithLinearModelForMean() | ||
obj_fun.handle = pystir.cSTIR_parameter\ | ||
(self.handle, self.name, 'objective_function') | ||
check_status(obj_fun.handle) | ||
return obj_fun |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not sure why this is here, maybe it needs another merge from master?
if (boost::iequals(name, "set_maximum_relative_change")) | ||
recon.set_maximum_relative_change(dataFromHandle<double>((void*)hv)); | ||
if (boost::iequals(name, "set_minimum_relative_change")) | ||
recon.set_minimum_relative_change(dataFromHandle<double>((void*)hv)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
seems a good addition, but shouldn't be a in a TOF PR
Partially addresses #315