class_docstr: A trained model using C++ implementation that is ready to use for classification or export to
  CoreML.
  
  This model should not be constructed directly.
class_docstr_tok: ["A","trained","model","using","C++","implementation","that","is","ready","to","use","for","classification","or","export","to","CoreML",".","This","model","should","not","be","constructed","directly","."]
docstr: Return predictions for ``dataset``, using the trained activity classifier.
  Predictions can be generated as class labels, or as a probability
  vector with probabilities for each class.
  
  The activity classifier generates a single prediction for each
  ``prediction_window`` rows in ``dataset``, per ``session_id``. The number
  of these predictions is smaller than the length of ``dataset``. By default,
  when ``output_frequency='per_row'``, each prediction is repeated ``prediction_window`` to return
  a prediction for each row of ``dataset``. Use ``output_frequency=per_window`` to
  get the unreplicated predictions.
  
  Parameters
  ----------
  dataset : SFrame
      Dataset of new observations. Must include columns with the same
      names as the features used for model training, but does not require
      a target column. Additional columns are ignored.
  
  output_type : {'class', 'probability_vector'}, optional
      Form of each prediction which is one of:
  
      - 'probability_vector': Prediction probability associated with each
        class as a vector. The probability of the first class (sorted
        alphanumerically by name of the class in the training set) is in
        position 0 of the vector, the second in position 1 and so on.
      - 'class': Class prediction. This returns the class with maximum
        probability.
  
  output_frequency : {'per_row', 'per_window'}, optional
      The frequency of the predictions which is one of:
  
      - 'per_window': Return a single prediction for each
        ``prediction_window`` rows in ``dataset`` per ``session_id``.
      - 'per_row': Convenience option to make sure the number of
        predictions match the number of rows in the dataset. Each
        prediction from the model is repeated ``prediction_window``
        times during that window.
  
  Returns
  -------
  out : SArray | SFrame
      If ``output_frequency`` is 'per_row' return an SArray with predictions
      for each row in ``dataset``.
      If ``output_frequency`` is 'per_window' return an SFrame with
      predictions for ``prediction_window`` rows in ``dataset``.
  
  See Also
  ----------
  create, evaluate, classify
  
  Examples
  --------
  
  .. sourcecode:: python
  
      # One prediction per row
      >>> probability_predictions = model.predict(
      ...     data, output_type='probability_vector', output_frequency='per_row')[:4]
      >>> probability_predictions
  
      dtype: array
      Rows: 4
      [array('d', [0.01857384294271469, 0.0348394550383091, 0.026018327102065086]),
       array('d', [0.01857384294271469, 0.0348394550383091, 0.026018327102065086]),
       array('d', [0.01857384294271469, 0.0348394550383091, 0.026018327102065086]),
       array('d', [0.01857384294271469, 0.0348394550383091, 0.026018327102065086])]
  
      # One prediction per window
      >>> class_predictions = model.predict(
      ...     data, output_type='class', output_frequency='per_window')
      >>> class_predictions
  
      +---------------+------------+-----+
      | prediction_id | session_id |class|
      +---------------+------------+-----+
      |       0       |     3      |  5  |
      |       1       |     3      |  5  |
      |       2       |     3      |  5  |
      |       3       |     3      |  5  |
      |       4       |     3      |  5  |
      |       5       |     3      |  5  |
      |       6       |     3      |  5  |
      |       7       |     3      |  4  |
      |       8       |     3      |  4  |
      |       9       |     3      |  4  |
      |      ...      |    ...     | ... |
      +---------------+------------+-----+
docstr_tok: ["Return","predictions","for","``","dataset","``",",","using","the","trained","activity","classifier",".","Predictions","can","be","generated","as","class","labels",",","or","as","a","probability","vector","with","probabilities","for","each","class",".","The","activity","classifier","generates","a","single","prediction","for","each","``","prediction_window","``","rows","in","``","dataset","``",",","per","``","session_id","``",".","The","number","of","these","predictions","is","smaller","than","the","length","of","``","dataset","``",".","By","default",",","when","``","output_frequency='per_row","'","``",",","each","prediction","is","repeated","``","prediction_window","``","to","return","a","prediction","for","each","row","of","``","dataset","``",".","Use","``","output_frequency=per_window","``","to","get","the","unreplicated","predictions",".","Parameters","--","--","--","--","--","dataset",":","SFrame","Dataset","of","new","observations",".","Must","include","columns","with","the","same","names","as","the","features","used","for","model","training",",","but","does","not","require","a","target","column",".","Additional","columns","are","ignored",".","output_type",":","{","'class","'",",","'probability_vector","'","}",",","optional","Form","of","each","prediction","which","is","one","of",":","-","'probability_vector","'",":","Prediction","probability","associated","with","each","class","as","a","vector",".","The","probability","of","the","first","class","(","sorted","alphanumerically","by","name","of","the","class","in","the","training","set",")","is","in","position","0","of","the","vector",",","the","second","in","position","1","and","so","on",".","-","'class","'",":","Class","prediction",".","This","returns","the","class","with","maximum","probability",".","output_frequency",":","{","'per_row","'",",","'per_window","'","}",",","optional","The","frequency","of","the","predictions","which","is","one","of",":","-","'per_window","'",":","Return","a","single","prediction","for","each","``","prediction_window","``","rows","in","``","dataset","``","per","``","session_id","``",".","-","'per_row","'",":","Convenience","option","to","make","sure","the","number","of","predictions","match","the","number","of","rows","in","the","dataset",".","Each","prediction","from","the","model","is","repeated","``","prediction_window","``","times","during","that","window",".","Returns","--","--","--","-","out",":","SArray","|","SFrame","If","``","output_frequency","``","is","'per_row","'","return","an","SArray","with","predictions","for","each","row","in","``","dataset","``",".","If","``","output_frequency","``","is","'per_window","'","return","an","SFrame","with","predictions","for","``","prediction_window","``","rows","in","``","dataset","``",".","See","Also","--","--","--","--","--","create",",","evaluate",",","classify","Examples","--","--","--","--","..","sourcecode",":",":","python","#","One","prediction","per","row",">",">",">","probability_predictions","=","model.predict","(","...","data",",","output_type='probability_vector","'",",","output_frequency='per_row","'",")","[",":4","]",">",">",">","probability_predictions","dtype",":","array","Rows",":","4","[","array","(","'d","'",",","[","0.01857384294271469",",","0.0348394550383091",",","0.026018327102065086","]",")",",","array","(","'d","'",",","[","0.01857384294271469",",","0.0348394550383091",",","0.026018327102065086","]",")",",","array","(","'d","'",",","[","0.01857384294271469",",","0.0348394550383091",",","0.026018327102065086","]",")",",","array","(","'d","'",",","[","0.01857384294271469",",","0.0348394550383091",",","0.026018327102065086","]",")","]","#","One","prediction","per","window",">",">",">","class_predictions","=","model.predict","(","...","data",",","output_type='class","'",",","output_frequency='per_window","'",")",">",">",">","class_predictions","+","--","--","--","--","--","--","--","-+","--","--","--","--","--","--","+","--","--","-+","|","prediction_id","|","session_id","|class|","+","--","--","--","--","--","--","--","-+","--","--","--","--","--","--","+","--","--","-+","|","0","|","3","|","5","|","|","1","|","3","|","5","|","|","2","|","3","|","5","|","|","3","|","3","|","5","|","|","4","|","3","|","5","|","|","5","|","3","|","5","|","|","6","|","3","|","5","|","|","7","|","3","|","4","|","|","8","|","3","|","4","|","|","9","|","3","|","4","|","|","...","|","...","|","...","|","+","--","--","--","--","--","--","--","-+","--","--","--","--","--","--","+","--","--","-+"]
code: def predict(
      self, dataset, output_type="class", output_frequency="per_row"
  ):
      """
      Return predictions for ``dataset``, using the trained activity classifier.
      Predictions can be generated as class labels, or as a probability
      vector with probabilities for each class.
  
      The activity classifier generates a single prediction for each
      ``prediction_window`` rows in ``dataset``, per ``session_id``. The number
      of these predictions is smaller than the length of ``dataset``. By default,
      when ``output_frequency='per_row'``, each prediction is repeated ``prediction_window`` to return
      a prediction for each row of ``dataset``. Use ``output_frequency=per_window`` to
      get the unreplicated predictions.
  
      Parameters
      ----------
      dataset : SFrame
          Dataset of new observations. Must include columns with the same
          names as the features used for model training, but does not require
          a target column. Additional columns are ignored.
  
      output_type : {'class', 'probability_vector'}, optional
          Form of each prediction which is one of:
  
          - 'probability_vector': Prediction probability associated with each
            class as a vector. The probability of the first class (sorted
            alphanumerically by name of the class in the training set) is in
            position 0 of the vector, the second in position 1 and so on.
          - 'class': Class prediction. This returns the class with maximum
            probability.
  
      output_frequency : {'per_row', 'per_window'}, optional
          The frequency of the predictions which is one of:
  
          - 'per_window': Return a single prediction for each
            ``prediction_window`` rows in ``dataset`` per ``session_id``.
          - 'per_row': Convenience option to make sure the number of
            predictions match the number of rows in the dataset. Each
            prediction from the model is repeated ``prediction_window``
            times during that window.
  
      Returns
      -------
      out : SArray | SFrame
          If ``output_frequency`` is 'per_row' return an SArray with predictions
          for each row in ``dataset``.
          If ``output_frequency`` is 'per_window' return an SFrame with
          predictions for ``prediction_window`` rows in ``dataset``.
  
      See Also
      ----------
      create, evaluate, classify
  
      Examples
      --------
  
      .. sourcecode:: python
  
          # One prediction per row
          >>> probability_predictions = model.predict(
          ...     data, output_type='probability_vector', output_frequency='per_row')[:4]
          >>> probability_predictions
  
          dtype: array
          Rows: 4
          [array('d', [0.01857384294271469, 0.0348394550383091, 0.026018327102065086]),
           array('d', [0.01857384294271469, 0.0348394550383091, 0.026018327102065086]),
           array('d', [0.01857384294271469, 0.0348394550383091, 0.026018327102065086]),
           array('d', [0.01857384294271469, 0.0348394550383091, 0.026018327102065086])]
  
          # One prediction per window
          >>> class_predictions = model.predict(
          ...     data, output_type='class', output_frequency='per_window')
          >>> class_predictions
  
          +---------------+------------+-----+
          | prediction_id | session_id |class|
          +---------------+------------+-----+
          |       0       |     3      |  5  |
          |       1       |     3      |  5  |
          |       2       |     3      |  5  |
          |       3       |     3      |  5  |
          |       4       |     3      |  5  |
          |       5       |     3      |  5  |
          |       6       |     3      |  5  |
          |       7       |     3      |  4  |
          |       8       |     3      |  4  |
          |       9       |     3      |  4  |
          |      ...      |    ...     | ... |
          +---------------+------------+-----+
      """
      _tkutl._check_categorical_option_type(
          "output_frequency",
          output_frequency,
          ["per_window", "per_row"],
      )
      if output_frequency == "per_row":
          return self.__proxy__.predict(dataset, output_type)
      elif output_frequency == "per_window":
          return self.__proxy__.predict_per_window(dataset, output_type)
  
imports: from __future__ import absolute_import
  from __future__ import print_function
  from __future__ import division
  import time
  import six
  from turicreate import SFrame
  import turicreate.toolkits._internal_utils
  from turicreate.toolkits import _coreml_utils
  import turicreate.toolkits._feature_engineering._internal_utils
  from turicreate.toolkits._main import ToolkitError
  from turicreate._deps.minimal_package import _minimal_package_import_check
  from turicreate.toolkits._model import Model
label_desc: Use image node_id 7 for calling the ActivityClassifier obj's underlying member method code with example usage: obj.predict(dataset, output_type, output_frequency) and returns: self, self