Skip to content

Commit

Permalink
ThinCurr: Fix incorrect size check in save_scalar(), introduced in 7…
Browse files Browse the repository at this point in the history
  • Loading branch information
hansec committed Sep 5, 2024
1 parent 66f38de commit d3b5787
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/python/OpenFUSIONToolkit/ThinCurr/_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ def save_scalar(self,field,tag):
@param field Pointwise data to save
@param tag Name of field in plot files
'''
if field.shape[0] >= self.np:
if field.shape[0] != self.np:
raise ValueError('Incorrect shape of "field", should be [np]')
field = numpy.ascontiguousarray(field, dtype=numpy.float64)
ctag = c_char_p(tag.encode())
Expand Down

0 comments on commit d3b5787

Please sign in to comment.