Skip to content

Commit

Permalink
fix 'Conversion of an array with ndim > 0 to a scalar' deprecation
Browse files Browse the repository at this point in the history
  • Loading branch information
rieder committed Jul 6, 2023
1 parent ff45783 commit d91e5c4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/amuse/datamodel/incode_storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -1134,7 +1134,7 @@ def get_values_in_store(self, indices, attributes):
elif len(array_of_indices[0].shape) == 0:
value = returned_value[0]
else:
if len(returned_value)!=numpy.product(array_of_indices[0].shape):
if len(returned_value)!=numpy.prod(array_of_indices[0].shape):
raise Exception("unexpected mismatch of array shapes")
if isinstance(returned_value,list):
returned_value=numpy.asarray(returned_value)
Expand Down

0 comments on commit d91e5c4

Please sign in to comment.