class_docstr: Holds data and its respective indices
docstr: Get entity
  
  Args:
      of (str): The entity, either 'row' or 'col'
  Returns:
      numpy.ndarray: Entity matrix (based on the entity_indices filter)
docstr_tok: ["Get","entity","Args",":","of","(","str",")",":","The","entity",",","either","'row","'","or","'col'","Returns",":","numpy.ndarray",":","Entity","matrix","(","based","on","the","entity_indices","filter",")"]
code: def get_entity(self, of="row"):
      """Get entity
  
      Args:
          of (str): The entity, either 'row' or 'col'
      Returns:
          numpy.ndarray: Entity matrix (based on the entity_indices filter)
      """
      idx = 0 if of == "row" else 1
      if self.entity_indices[idx] is None:
          return self.entities[idx]
      return self.entities[idx][self.entity_indices[idx]]
  
imports: import logging
  import pandas
  import numpy
  from scipy.sparse import coo_matrix, isspmatrix_csr
  from sklearn.model_selection import train_test_split
  from sklearn.preprocessing import normalize
  from recommenders.utils.python_utils import binarize
  from .geoimc_utils import length_normalize, reduce_dims
label_desc: Use image node_id 3 for calling the DataPtr obj's underlying member method code with example usage: obj.get_entity(of) and returns: self, self