Skip to content

Commit

Permalink
Merge pull request #8 from okayamayu8/convolver
Browse files Browse the repository at this point in the history
debug: beam_cut.py
  • Loading branch information
yusuke-takase authored Jul 8, 2024
2 parents 87c1e86 + 58f19e3 commit 5607840
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions grasp2alm/beam_cut.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,14 +115,14 @@ def to_polar(self, copol_axis="x"):
assert copol_axis in ["x", "y"], "Error in BeamCut.to_polar: copol_axis must be 'x' or 'y'"

nphi = int(2 * self.ncut)
ntheta = int(self.vnum // 2)
ntheta = int(self.vnum // 2)+1
theta_rad_min = 0.0
theta_rad_max = np.deg2rad(np.abs(self.vini))
beam_polar = BeamPolar(nphi, ntheta, theta_rad_min, theta_rad_max, self.filename)
amp_tmp = np.zeros((2, nphi, ntheta), dtype=complex)

for i in range(self.ncut):
amp_tmp[:, i, :] = self.amp[:, ntheta:self.vnum-1, i]
amp_tmp[:, i, :] = self.amp[:, ntheta-1:self.vnum+1, i]
amp_tmp[:, self.ncut + i, :] = self.amp[:, ntheta-1::-1, i]

if copol_axis == "x":
Expand Down

0 comments on commit 5607840

Please sign in to comment.