Skip to content
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

PyTorch RTCC simulations can't use field kicks #33

Open
lothian opened this issue May 24, 2022 · 0 comments
Open

PyTorch RTCC simulations can't use field kicks #33

lothian opened this issue May 24, 2022 · 0 comments

Comments

@lothian
Copy link
Member

lothian commented May 24, 2022

pycc/pycc/rt/rtcc.py

Lines 74 to 82 in 34f928d

if kick:
s_to_i = {"x":0, "y":1, "z":2}
self.mu_tot = self.mu[s_to_i[kick.lower()]]
else:
self.mu_tot = sum(self.mu)/np.sqrt(3.0) # isotropic field
if isinstance(self.ccwfn.t1, torch.Tensor):
self.mu = torch.tensor(self.mu, dtype=torch.complex128, device=self.ccwfn.device1)
self.mu_tot = sum(self.mu) / (torch.sqrt(torch.tensor(3.0)).item())

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant