Skip to content

Solving deprecation warnings #7

@ogourgue

Description

@ogourgue
  • When running python test_ca2tel.py:
/Users/ogourgue/Applications/Repositories/demeter/ca2tel_voronoi_coverage.py:130: DeprecationWarning: Conversion of an array with ndim > 0 to a scalar is deprecated, and will error in future. Ensure you extract a single element from your array before performing this operation. (Deprecated NumPy 1.25.)
  tri_loc[j, k] = int(np.argwhere(tri_glo[j, k] ==
/Users/ogourgue/Applications/Repositories/demeter/ca2tel_voronoi_coverage.py:150: DeprecationWarning: Conversion of an array with ndim > 0 to a scalar is deprecated, and will error in future. Ensure you extract a single element from your array before performing this operation. (Deprecated NumPy 1.25.)
  try:imin = int(np.argwhere(X <= xmin)[-1])
/Users/ogourgue/Applications/Repositories/demeter/ca2tel_voronoi_coverage.py:152: DeprecationWarning: Conversion of an array with ndim > 0 to a scalar is deprecated, and will error in future. Ensure you extract a single element from your array before performing this operation. (Deprecated NumPy 1.25.)
  try:imax = int(np.argwhere(X >= xmax)[0])
/Users/ogourgue/Applications/Repositories/demeter/ca2tel_voronoi_coverage.py:154: DeprecationWarning: Conversion of an array with ndim > 0 to a scalar is deprecated, and will error in future. Ensure you extract a single element from your array before performing this operation. (Deprecated NumPy 1.25.)
  try:jmin = int(np.argwhere(Y <= ymin)[-1])
/Users/ogourgue/Applications/Repositories/demeter/ca2tel_voronoi_coverage.py:156: DeprecationWarning: Conversion of an array with ndim > 0 to a scalar is deprecated, and will error in future. Ensure you extract a single element from your array before performing this operation. (Deprecated NumPy 1.25.)
  try:jmax = int(np.argwhere(Y >= ymax)[0])
  • When running python test_non_rectangle.py:
/Users/ogourgue/Applications/Repositories/demeter/tel2ca_interpolation.py:177: DeprecationWarning: Conversion of an array with ndim > 0 to a scalar is deprecated, and will error in future. Ensure you extract a single element from your array before performing this operation. (Deprecated NumPy 1.25.)
  tri_loc[j, k] = int(np.argwhere(tri_glo[j, k] == nod_glo))
/Users/ogourgue/Applications/Repositories/demeter/ca2tel_voronoi_coverage.py:130: DeprecationWarning: Conversion of an array with ndim > 0 to a scalar is deprecated, and will error in future. Ensure you extract a single element from your array before performing this operation. (Deprecated NumPy 1.25.)
  tri_loc[j, k] = int(np.argwhere(tri_glo[j, k] ==
/Users/ogourgue/Applications/Repositories/demeter/ca2tel_voronoi_coverage.py:152: DeprecationWarning: Conversion of an array with ndim > 0 to a scalar is deprecated, and will error in future. Ensure you extract a single element from your array before performing this operation. (Deprecated NumPy 1.25.)
  try:imax = int(np.argwhere(X >= xmax)[0])
/Users/ogourgue/Applications/Repositories/demeter/ca2tel_voronoi_coverage.py:156: DeprecationWarning: Conversion of an array with ndim > 0 to a scalar is deprecated, and will error in future. Ensure you extract a single element from your array before performing this operation. (Deprecated NumPy 1.25.)
  try:jmax = int(np.argwhere(Y >= ymax)[0])
/Users/ogourgue/Applications/Repositories/demeter/ca2tel_voronoi_coverage.py:154: DeprecationWarning: Conversion of an array with ndim > 0 to a scalar is deprecated, and will error in future. Ensure you extract a single element from your array before performing this operation. (Deprecated NumPy 1.25.)
  try:jmin = int(np.argwhere(Y <= ymin)[-1])
/Users/ogourgue/Applications/Repositories/demeter/ca2tel_voronoi_coverage.py:150: DeprecationWarning: Conversion of an array with ndim > 0 to a scalar is deprecated, and will error in future. Ensure you extract a single element from your array before performing this operation. (Deprecated NumPy 1.25.)
  try:imin = int(np.argwhere(X <= xmin)[-1])

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions