Conversation
Co-authored-by: Jan Kaiser <jan.kaiser.email@googlemail.com>
Co-authored-by: Copilot <copilot@github.com>
…nces Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
Co-authored-by: Copilot <copilot@github.com>
|
I just discovered a fairly significant issue with the implementation as is: Cheetah assumes that there can be any number of vector dimensions, and how many there are is unknown. However, as it stands, the Cloud-in-Cell implementation assumes exactly one vector dimensions, and, I believe, relies on Tensor's number of dimensions to determine how many histogram dimensions are needed. This is fundamentally incompatible with how Cheetah does it. Instead, the Cloud-in-Cell implementation should follow the interface of |
|
Are you sure about this? We've been doing arbitrary batch dimensions for gpsr using similar code. |
|
Well ... I just started checking how we might fix this. And I think it might actually be vector-dimension-agnostic, but the docstring and argument verification just say otherwise. |
| :param positions: List or tuple of particle position tensors, each of shape | ||
| `(..., N)`, leading with optional vector dimension. `N` is the number of | ||
| particles. The length `d` of `positions` determines the dimensionality | ||
| (1D, 2D or 3D). |
There was a problem hiding this comment.
I think this doesn't actually match what the function really does.
There was a problem hiding this comment.
Wait, let me look at it a little more in detail
There was a problem hiding this comment.
Wait, let me look at it a little more in detail
There was a problem hiding this comment.
I changed it now to something that I believe reflects much better how it works (or should work). Interestingly, this is exactly backwards from what np.histogramdd does. I don't know if that's bad or irrelevant. I find the way we do it now intuitive as well.
Co-authored-by: Copilot <copilot@github.com>
Description
cloud-in-cellmethod for Screen, that is differentiable and faster than the kde method.Fixes #433
Also partially addresses #543
This PR merges @roussel-ryan 's fork https://github.com/roussel-ryan/cheetah/tree/diag0 into the master.
Motivation and Context
Types of changes
Checklist
flake8(required).pytesttests pass (required).pyteston a machine with a CUDA GPU and made sure all tests pass (required).Note: We are using a maximum length of 88 characters per line.