Closed apuignav closed 5 years ago
It looks good to me, @apuignav (modulo our discussion on whether GenParticle
could be a better name).
About the mass, we could include it if fixed, and otherwise something like "not fixed" or similar. It may helps debugging if a mass was set wrong. Otherwise looks good to me
Not a bad idea. Let me try.
Mass info has been added, but I had to add a _mass_value
member to Particle
in order to avoid the transformation to a tensor. However, if a tensor is passed this will fail
@mayou36 how would you deal with this?
To me, the mass in __repr__
is a nice to have information. If it is a number, fine. If not, not. If a Tensor, it's a Tensor (and it can be fixed or variable in principle).
So I would not guess. We could in __str__
add a sess call to the Tensor, but it's more trouble I guess (side-effects? expensive calls?).
Looks good to me, is what I would have thought.
And I would change the name once we change to GenParticle
OK, then let's marge and do the move to GenParticle
in a separate PR.
Address an issue raised in #22.
@eduardo-rodrigues @mayou36 What do you think about this repr?