class_docstr: Base class for a recommender model supporting Approximate Nearest Neighbor (ANN) search.
  
  Parameters
  ----------------
  model: object: :obj:`cornac.models.Recommender`, required
      Trained recommender model which to get user/item vectors from.
  
  name: str, required
      Name of the recommender model.
  
  verbose: boolean, optional, default: False
      When True, running logs are displayed.
class_docstr_tok: ["Base","class","for","a","recommender","model","supporting","Approximate","Nearest","Neighbor","(","ANN",")","search",".","Parameters","--","--","--","--","--","--","--","--","model",":","object",":",":","obj",":","`","cornac.models.Recommender","`",",","required","Trained","recommender","model","which","to","get","user\/item","vectors","from",".","name",":","str",",","required","Name","of","the","recommender","model",".","verbose",":","boolean",",","optional",",","default",":","False","When","True",",","running","logs","are","displayed","."]
code: def __init__(self, model, name="BaseANN", verbose=False):
      super().__init__(name=name, verbose=verbose, trainable=False)
  
      if not is_ann_supported(model):
          raise ValueError(f"{model.name} doesn't support ANN search")
  
      self.model = model
  
      self.ignored_attrs.append(
          "model"
      )  # not to save the base model with ANN
  
      if model.is_fitted:
          Recommender.fit(self, model.train_set, model.val_set)
  
file_path: cornac/cornac/models/ann/recom_ann_base.py
imports: import copy
  import warnings
  import numpy
  from ..recommender import Recommender
  from ..recommender import is_ann_supported
  from ..recommender import MEASURE_DOT, MEASURE_COSINE
label_desc: Use image node_id 1 to create a new BaseANN object from inherited base classes: Recommender with example: obj = BaseANN(model, name, verbose)