Skip to content

Commit

Permalink
prior value now double, fixes #1290
Browse files Browse the repository at this point in the history
  • Loading branch information
evgueni-ovtchinnikov committed Sep 3, 2024
1 parent 1e2c5c1 commit 66b7578
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/xSTIR/cSTIR/cstir.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1329,8 +1329,8 @@ cSTIR_priorValue(void* ptr_p, void* ptr_i)
objectFromHandle<xSTIR_GeneralisedPrior3DF>(ptr_p);
STIRImageData& id = objectFromHandle<STIRImageData>(ptr_i);
Image3DF& image = id.data();
float v = (float)prior.compute_value(image);
return dataHandle<float>(v);
double v = prior.compute_value(image);
return dataHandle<double>(v);
}
CATCH;
}
Expand Down
2 changes: 1 addition & 1 deletion src/xSTIR/pSTIR/STIR.py
Original file line number Diff line number Diff line change
Expand Up @@ -2320,7 +2320,7 @@ def get_value(self, image):
assert_validity(image, ImageData)
handle = pystir.cSTIR_priorValue(self.handle, image.handle)
check_status(handle)
v = pyiutil.floatDataFromHandle(handle)
v = pyiutil.doubleDataFromHandle(handle)
pyiutil.deleteDataHandle(handle)
return v

Expand Down

0 comments on commit 66b7578

Please sign in to comment.