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

Changed some numpy calls following the numpy 2.0 migration guide #2406

Merged
merged 4 commits into from Oct 21, 2023

Conversation

Tobychev
Copy link
Contributor

I grepped ctapipe for calls to the functions mentioned in the the numpy 2.0 migration guide, and changed the few instances I found according to the reccomendations in the guide. This closes #2404.

For completness, these are the functions listed in the guide:

np.in1d
np.row_stack
np.trapz
np.add_docstring
np.add_newdoc
np.add_newdoc_ufunc
np.asfarray
np.byte_bounds
np.cast
np.cfloat
np.clongfloat
np.compat
np.complex_
np.DataSource
np.deprecate
np.deprecate_with_doc
np.disp
np.fastCopyAndTranspose
np.find_common_type
np.get_array_wrap
np.float_
np.geterrobj
np.Inf
np.Infinity
np.infty
np.issctype
np.issubclass_
np.issubsctype
np.mat
np.maximum_sctype
np.NaN
np.nbytes
np.NINF
np.NZERO
np.longcomplex
np.longfloat
np.lookfor
np.obj2sctype
np.PINF
np.PZERO
np.recfromcsv
np.recfromtxt
np.round_
np.safe_eval
np.sctype2char
np.sctypes
np.seterrobj
np.set_numeric_ops
np.set_string_function
np.singlecomplex
np.string_
np.source
np.tracemalloc_domain
np.unicode_
np.who

maxnoe
maxnoe previously approved these changes Sep 27, 2023
@maxnoe maxnoe merged commit a987cc8 into main Oct 21, 2023
12 checks passed
@maxnoe maxnoe deleted the numpy_2_compat branch October 21, 2023 13:10
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

Successfully merging this pull request may close these issues.

Check numpy 2.0 migration guide
4 participants