Saransh Chopra

Results 106 issues of Saransh Chopra

Originally posted by **acampove** September 22, 2025 in #640 This is the MWE ```python import vector from vector import MomentumObject3D def _fun(vec : MomentumObject3D) -> None: print(vec) vec = vector.obj(pt=1.0,...

bug

Python 3.8 has already been EOL for a while now and 3.9 will reach EOL this year. Moreover, I contributed a vector-numba (#600) functionality upstream to numba, but we cannot...

cleanup

Vector has a custom Numba implementation of `numpy.nan_to_num` - https://github.com/scikit-hep/vector/blob/6ba5a60ac90e5afa047f53681257b93ffa158cb5/src/vector/backends/_numba_object.py#L54-L55 which should ideally by in Numba. The feature request was raised by Jim in https://github.com/numba/numba/issues/6857 and the function was partially...

cleanup

#595 adds a workaround for #593's original CuPy issue - https://github.com/cupy/cupy/issues/9143. The workaround includes using `where` instead of `nan_to_num` in specific compute functions. Using `where` is okay for numerical backends,...

cleanup

#581 raises the question of structural (`x == y`) v/s symbolic (`simplify(x - y) == 0` or `Eq(x, y)`) equality. Even though symbolic equality would be easier to maintain in...

tests

Given that the task uses `P_big` and `Q_big` of shapes `[x, 80]` at the very end to compare speed, the docstrings should reflect that the functions should generalise over any...