Skip to content

Commit

Permalink
Fixing issue apache#16655 reshape() error message
Browse files Browse the repository at this point in the history
  • Loading branch information
Ubuntu committed May 7, 2020
1 parent 6774474 commit 29ddefe
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python/mxnet/numpy/multiarray.py
Original file line number Diff line number Diff line change
Expand Up @@ -1435,8 +1435,8 @@ def reshape(self, *args, **kwargs): # pylint: disable=arguments-differ
raise TypeError('function takes at most 1 keyword argument')
if len(kwargs) == 1:
if 'order' not in kwargs:
raise TypeError('{} is an invalid keyword argument for this function'
.format(list(kwargs.keys())[0])) # python3.6 - TypeError: 'dict_keys' object does not support indexing
raise TypeError("'{}' is an invalid keyword argument for this function"
.format(list(kwargs.keys())[0]))
order = kwargs.pop('order', 'C')
if order != 'C':
raise NotImplementedError('only supports C-order,'
Expand Down

0 comments on commit 29ddefe

Please sign in to comment.