Skip to content

Commit

Permalink
TVB-2750. Avoid incompatibility between Postgres and numpy.bool type.
Browse files Browse the repository at this point in the history
  • Loading branch information
popaula937 committed Jul 22, 2020
1 parent 3a36fe8 commit dc2eeba
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions framework_tvb/tvb/core/entities/model/model_datatype.py
Original file line number Diff line number Diff line change
Expand Up @@ -248,8 +248,8 @@ def fill_from_has_traits(self, datatype):

if hasattr(datatype, "array_data"):
self.array_data_min, self.array_data_max, self.array_data_mean = from_ndarray(datatype.array_data)
self.array_is_finite = numpy.isfinite(datatype.array_data).all()
self.array_has_complex = numpy.iscomplex(datatype.array_data).any()
self.array_is_finite = numpy.isfinite(datatype.array_data).all().item()
self.array_has_complex = numpy.iscomplex(datatype.array_data).any().item()
self.shape = json.dumps(datatype.array_data.shape)
self.ndim = len(datatype.array_data.shape)

Expand Down

0 comments on commit dc2eeba

Please sign in to comment.