parameters: (self, key, value)
docstring: x.__setitem__(i, y) <=> x[i]=y
  
          Sets value to self[key]. This functions supports advanced indexing defined in the following reference with
          some restrictions.
  
          https://docs.scipy.org/doc/numpy-1.13.0/reference/arrays.indexing.html#combining-advanced-and-basic-indexing
  
          - If key is a list type, only a list of integers is supported, e.g. key=[1, 2] is supported,
            while not for key=[[1, 2]].
          - Ellipsis (...) and np.newaxis are not supported.
          - Boolean array indexing is not supported.
  
          Parameters
          ----------
          key : int, slice, list, np.ndarray, NDArray, or tuple of all previous types
              The indexing key.
          value : scalar or array-like object that can be broadcast to the shape of self[key]
              The value to set.
  
          Examples
          --------
          >>> x = mx.nd.zeros((2,3))
          >>> x[:] = 1
          >>> x.asnumpy()
          array([[ 1.,  1.,  1.],
                 [ 1.,  1.,  1.]], dtype=float32)
          >>> x.asnumpy()
          array([[ 1.,  1.,  1.],
                 [ 1.,  1.,  1.]], dtype=float32)
          >>> x[:,1:2] = 2
          >>> x.asnumpy()
          array([[ 1.,  2.,  1.],
                 [ 1.,  2.,  1.]], dtype=float32)
          >>> x[1:2,1:] = 3
          >>> x.asnumpy()
          array([[ 1.,  2.,  1.],
                 [ 1.,  3.,  3.]], dtype=float32)
          >>> x[1:,0:2] = mx.nd.zeros((1,2))
          >>> x.asnumpy()
          array([[ 1.,  2.,  1.],
                 [ 0.,  0.,  3.]], dtype=float32)
          >>> x[1,2] = 4
          >>> x.asnumpy()
          array([[ 1.,  2.,  1.],
                 [ 0.,  0.,  4.]], dtype=float32)
          >>> x[[0], [1, 2]] = 5
          >>> x.asnumpy()
          array([[ 1.,  5.,  5.],
                 [ 0.,  0.,  4.]], dtype=float32)
          >>> x[::-1, 0:2:2] = [6]
          >>> x.asnumpy()
          array([[ 6.,  5.,  5.],
                 [ 6.,  0.,  4.]], dtype=float32)
docstring_summary: x.__setitem__(i, y) <=> x[i]=y
docstring_tokens: x . __setitem__ ( i y ) < = > x [ i ] = y
function: def __setitem__(self, key, value):
          """x.__setitem__(i, y) <=> x[i]=y
  
          Sets value to self[key]. This functions supports advanced indexing defined in the following reference with
          some restrictions.
  
          https://docs.scipy.org/doc/numpy-1.13.0/reference/arrays.indexing.html#combining-advanced-and-basic-indexing
  
          - If key is a list type, only a list of integers is supported, e.g. key=[1, 2] is supported,
            while not for key=[[1, 2]].
          - Ellipsis (...) and np.newaxis are not supported.
          - Boolean array indexing is not supported.
  
          Parameters
          ----------
          key : int, slice, list, np.ndarray, NDArray, or tuple of all previous types
              The indexing key.
          value : scalar or array-like object that can be broadcast to the shape of self[key]
              The value to set.
  
          Examples
          --------
          >>> x = mx.nd.zeros((2,3))
          >>> x[:] = 1
          >>> x.asnumpy()
          array([[ 1.,  1.,  1.],
                 [ 1.,  1.,  1.]], dtype=float32)
          >>> x.asnumpy()
          array([[ 1.,  1.,  1.],
                 [ 1.,  1.,  1.]], dtype=float32)
          >>> x[:,1:2] = 2
          >>> x.asnumpy()
          array([[ 1.,  2.,  1.],
                 [ 1.,  2.,  1.]], dtype=float32)
          >>> x[1:2,1:] = 3
          >>> x.asnumpy()
          array([[ 1.,  2.,  1.],
                 [ 1.,  3.,  3.]], dtype=float32)
          >>> x[1:,0:2] = mx.nd.zeros((1,2))
          >>> x.asnumpy()
          array([[ 1.,  2.,  1.],
                 [ 0.,  0.,  3.]], dtype=float32)
          >>> x[1,2] = 4
          >>> x.asnumpy()
          array([[ 1.,  2.,  1.],
                 [ 0.,  0.,  4.]], dtype=float32)
          >>> x[[0], [1, 2]] = 5
          >>> x.asnumpy()
          array([[ 1.,  5.,  5.],
                 [ 0.,  0.,  4.]], dtype=float32)
          >>> x[::-1, 0:2:2] = [6]
          >>> x.asnumpy()
          array([[ 6.,  5.,  5.],
                 [ 6.,  0.,  4.]], dtype=float32)
          """
          indexing_dispatch_code = _get_indexing_dispatch_code(key)
          if indexing_dispatch_code == _NDARRAY_BASIC_INDEXING:
              self._set_nd_basic_indexing(key, value)
          elif indexing_dispatch_code == _NDARRAY_ADVANCED_INDEXING:
              self._set_nd_advanced_indexing(key, value)
          else:
              raise ValueError('Indexing NDArray with index=%s and type=%s is not supported'
                               % (str(key), str(type(key))))
function_tokens: def __setitem__ ( self , key , value ) : indexing_dispatch_code = _get_indexing_dispatch_code ( key ) if indexing_dispatch_code == _NDARRAY_BASIC_INDEXING : self . _set_nd_basic_indexing ( key , value ) elif indexing_dispatch_code == _NDARRAY_ADVANCED_INDEXING : self . _set_nd_advanced_indexing ( key , value ) else : raise ValueError ( 'Indexing NDArray with index=%s and type=%s is not supported' % ( str ( key ) , str ( type ( key ) ) ) )