parameters: (self, filename, model_name='p_wt')
docstring: :Description: loads from disk the topic model saved by ARTM.save()
  
          :param str filename: the name of file containing model
          :param str model_name: the name of matrix to be saved, 'p_wt' or 'n_wt'
  
          :Note:
            * Loaded model will overwrite ARTM.topic_names, class_ids and transaction_typenames fields.
            * All transaction_typenames (class_ids) weights will be set to 1.0, you need to specify them by\
              hand if it's necessary.
            * The method call will empty ARTM.score_tracker.
            * All regularizers and scores will be forgotten.
            * etc.
            * We strongly recommend you to reset all important parameters of the ARTM\
              model, used earlier.
docstring_summary: :Description: loads from disk the topic model saved by ARTM.save()
docstring_tokens: : Description : loads from disk the topic model saved by ARTM . save ()
function: def load(self, filename, model_name='p_wt'):
          """
          :Description: loads from disk the topic model saved by ARTM.save()
  
          :param str filename: the name of file containing model
          :param str model_name: the name of matrix to be saved, 'p_wt' or 'n_wt'
  
          :Note:
            * Loaded model will overwrite ARTM.topic_names, class_ids and transaction_typenames fields.
            * All transaction_typenames (class_ids) weights will be set to 1.0, you need to specify them by\
              hand if it's necessary.
            * The method call will empty ARTM.score_tracker.
            * All regularizers and scores will be forgotten.
            * etc.
            * We strongly recommend you to reset all important parameters of the ARTM\
              model, used earlier.
          """
          _model_name = None
          if model_name == 'p_wt':
              _model_name = self.model_pwt
          elif model_name == 'n_wt':
              _model_name = self.model_nwt
  
          self.master.import_model(_model_name, filename)
          self._initialized = True
  
          config = self._lib.ArtmRequestMasterModelConfig(self.master.master_id)
          self._topic_names = list(config.topic_name)
  
          class_ids = {}
          for class_id in config.class_id:
              class_ids[class_id] = 1.0
          self._class_ids = class_ids
  
          if hasattr(config, 'transaction_typename'):
              transaction_typenames = {}
              for transaction_typename in config.transaction_typename:
                  transaction_typenames[transaction_typename] = 1.0
              self._transaction_typenames = transaction_typenames
  
          # Remove all info about previous iterations
          self._score_tracker = {}
          self._synchronizations_processed = 0
          self._num_online_processed_batches = 0
          self._phi_cached = None
function_tokens: def load ( self , filename , model_name = 'p_wt' ) : _model_name = None if model_name == 'p_wt' : _model_name = self . model_pwt elif model_name == 'n_wt' : _model_name = self . model_nwt self . master . import_model ( _model_name , filename ) self . _initialized = True config = self . _lib . ArtmRequestMasterModelConfig ( self . master . master_id ) self . _topic_names = list ( config . topic_name ) class_ids = { } for class_id in config . class_id : class_ids [ class_id ] = 1.0 self . _class_ids = class_ids if hasattr ( config , 'transaction_typename' ) : transaction_typenames = { } for transaction_typename in config . transaction_typename : transaction_typenames [ transaction_typename ] = 1.0 self . _transaction_typenames = transaction_typenames # Remove all info about previous iterations self . _score_tracker = { } self . _synchronizations_processed = 0 self . _num_online_processed_batches = 0 self . _phi_cached = None