Skip to content

Commit

Permalink
Flatten arrays for set_values.
Browse files Browse the repository at this point in the history
  • Loading branch information
mcflugen committed Nov 13, 2015
1 parent b09300a commit 1bb3c97
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions cmt/framework/bmi_bridge.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,7 @@ def wrap(self, name, val):
val : array_like
Values to set.
"""
if not isinstance(val, np.ndarray):
val = np.array(val)
val = np.asarray(val).reshape((-1, ))
return val_or_raise(func, (self._base, name, val))
wrap.__name__ = func.__name__
return wrap
Expand Down

0 comments on commit 1bb3c97

Please sign in to comment.