class_docstr: Training set contains preference matrix
  
  Parameters
  ----------
  num_users: int, required
      Number of users.
  
  num_items: int, required
      Number of items.
  
  uid_map: :obj:`OrderDict`, required
      The dictionary containing mapping from user original ids to mapped integer indices.
  
  iid_map: :obj:`OrderDict`, required
      The dictionary containing mapping from item original ids to mapped integer indices.
  
  uir_tuple: tuple, required
      Tuple of 3 numpy arrays (user_indices, item_indices, rating_values).
  
  timestamps: numpy.array, optional, default: None
      Array of timestamps corresponding to observations in `uir_tuple`.
  
  seed: int, optional, default: None
      Random seed for reproducing data sampling.
  
  Attributes
  ----------
  num_ratings: int
      Number of rating observations in the dataset.
  
  max_rating: float
      Maximum value among the rating observations.
  
  min_rating: float
      Minimum value among the rating observations.
  
  global_mean: float
      Average value over the rating observations.
  
  uir_tuple: tuple
      Tuple three numpy arrays (user_indices, item_indices, rating_values).
  
  timestamps: numpy.array
      Numpy array of timestamps corresponding to feedback in `uir_tuple`.
      This is only available when input data is in `UIRT` format.
class_docstr_tok: ["Training","set","contains","preference","matrix","Parameters","--","--","--","--","--","num_users",":","int",",","required","Number","of","users",".","num_items",":","int",",","required","Number","of","items",".","uid_map",":",":","obj",":","`","OrderDict","`",",","required","The","dictionary","containing","mapping","from","user","original","ids","to","mapped","integer","indices",".","iid_map",":",":","obj",":","`","OrderDict","`",",","required","The","dictionary","containing","mapping","from","item","original","ids","to","mapped","integer","indices",".","uir_tuple",":","tuple",",","required","Tuple","of","3","numpy","arrays","(","user_indices",",","item_indices",",","rating_values",")",".","timestamps",":","numpy.array",",","optional",",","default",":","None","Array","of","timestamps","corresponding","to","observations","in","`","uir_tuple","`",".","seed",":","int",",","optional",",","default",":","None","Random","seed","for","reproducing","data","sampling",".","Attributes","--","--","--","--","--","num_ratings",":","int","Number","of","rating","observations","in","the","dataset",".","max_rating",":","float","Maximum","value","among","the","rating","observations",".","min_rating",":","float","Minimum","value","among","the","rating","observations",".","global_mean",":","float","Average","value","over","the","rating","observations",".","uir_tuple",":","tuple","Tuple","three","numpy","arrays","(","user_indices",",","item_indices",",","rating_values",")",".","timestamps",":","numpy.array","Numpy","array","of","timestamps","corresponding","to","feedback","in","`","uir_tuple","`",".","This","is","only","available","when","input","data","is","in","`","UIRT","`","format","."]
docstr: Create an iterator over user indices
  
  Parameters
  ----------
  batch_size : int, optional, default = 1
  
  shuffle : bool, optional
      If True, orders of triplets will be randomized. If False, default orders kept
  
  Returns
  -------
  iterator : batch of user indices (array of 'int')
docstr_tok: ["Create","an","iterator","over","user","indices","Parameters","--","--","--","--","--","batch_size",":","int",",","optional",",","default","=","1","shuffle",":","bool",",","optional","If","True",",","orders","of","triplets","will","be","randomized",".","If","False",",","default","orders","kept","Returns","--","--","--","-","iterator",":","batch","of","user","indices","(","array","of","'int","'",")"]
code: def user_iter(self, batch_size=1, shuffle=False):
      """Create an iterator over user indices
  
      Parameters
      ----------
      batch_size : int, optional, default = 1
  
      shuffle : bool, optional
          If True, orders of triplets will be randomized. If False, default orders kept
  
      Returns
      -------
      iterator : batch of user indices (array of 'int')
      """
      user_indices = np.fromiter(set(self.uir_tuple[0]), dtype="int")
      for batch_ids in self.idx_iter(
          len(user_indices), batch_size, shuffle
      ):
          yield user_indices[batch_ids]
  
imports: import copy
  import os
  import pickle
  import warnings
  from collections import Counter, OrderedDict, defaultdict
  import numpy
  from scipy.sparse import csc_matrix, csr_matrix, dok_matrix
  from ..utils import estimate_batches, get_rng, validate_format
label_desc: Use image node_id 22 for calling the Dataset obj's underlying member method code with example usage: obj.user_iter(batch_size, shuffle) without return types