original_string: protected function load_classifier($outputdir) {
          $modelfilepath = $this->get_model_filepath($outputdir);
  
          if (!file_exists($modelfilepath)) {
              throw new \moodle_exception('errorcantloadmodel', 'mlbackend_php', '', $modelfilepath);
          }
  
          $modelmanager = new ModelManager();
          return $modelmanager->restoreFromFile($modelfilepath);
      }
code: protected function load_classifier($outputdir) {
          $modelfilepath = $this->get_model_filepath($outputdir);
  
          if (!file_exists($modelfilepath)) {
              throw new \moodle_exception('errorcantloadmodel', 'mlbackend_php', '', $modelfilepath);
          }
  
          $modelmanager = new ModelManager();
          return $modelmanager->restoreFromFile($modelfilepath);
      }
code_tokens: protected function load_classifier ( $ outputdir ) { $ modelfilepath = $ this -> get_model_filepath ( $ outputdir ) ; if ( ! file_exists ( $ modelfilepath ) ) { throw new \ moodle_exception ( 'errorcantloadmodel' , 'mlbackend_php' , '' , $ modelfilepath ) ; } $ modelmanager = new ModelManager ( ) ; return $ modelmanager -> restoreFromFile ( $ modelfilepath ) ; }
docstring: Loads the pre-trained classifier.
  
  @throws \moodle_exception
  @param string $outputdir
  @return \Phpml\Classification\Linear\LogisticRegression
docstring_tokens: Loads the pre - trained classifier .