Skip to content

Commit

Permalink
Merge pull request #85 from phonghnguyen/fix_radius_WP
Browse files Browse the repository at this point in the history
  • Loading branch information
pbeaucage authored Apr 18, 2023
2 parents 4b22761 + 77cc0af commit b7b336d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/PyHyperScattering/WPIntegrator.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,9 +112,9 @@ def integrateSingleImage(self,img):
pass

if self.MACHINE_HAS_CUDA:
TwoD = self.warp_polar_gpu(img_to_integ,center=(center_x,center_y), radius = np.nanmax(img_to_integ.shape))
TwoD = self.warp_polar_gpu(img_to_integ,center=(center_x,center_y), radius = np.sqrt((img_to_integ.shape[0] - center_x)**2 + (img_to_integ.shape[1] - center_y)**2))
else:
TwoD = skimage.transform.warp_polar(img_to_integ,center=(center_x,center_y), radius = np.nanmax(img_to_integ.shape))
TwoD = skimage.transform.warp_polar(img_to_integ,center=(center_x,center_y), radius = np.sqrt((img_to_integ.shape[0] - center_x)**2 + (img_to_integ.shape[1] - center_y)**2))


qx = img.qx
Expand Down

0 comments on commit b7b336d

Please sign in to comment.