abacusai.algorithm
==================

.. py:module:: abacusai.algorithm


Classes
-------

.. autoapisummary::

   abacusai.algorithm.CodeSource
   abacusai.algorithm.AbstractApiClass
   abacusai.algorithm.Algorithm


Module Contents
---------------

.. py:class:: CodeSource(client, sourceType=None, sourceCode=None, applicationConnectorId=None, applicationConnectorInfo=None, packageRequirements=None, status=None, error=None, publishingMsg=None, moduleDependencies=None)

   Bases: :py:obj:`abacusai.return_class.AbstractApiClass`


   Code source for python-based custom feature groups and models

   :param client: An authenticated API Client instance
   :type client: ApiClient
   :param sourceType: The type of the source, one of TEXT, PYTHON, FILE_UPLOAD, or APPLICATION_CONNECTOR
   :type sourceType: str
   :param sourceCode: If the type of the source is TEXT, the raw text of the function
   :type sourceCode: str
   :param applicationConnectorId: The Application Connector to fetch the code from
   :type applicationConnectorId: str
   :param applicationConnectorInfo: Args passed to the application connector to fetch the code
   :type applicationConnectorInfo: str
   :param packageRequirements: The pip package dependencies required to run the code
   :type packageRequirements: list
   :param status: The status of the code and validations
   :type status: str
   :param error: If the status is failed, an error message describing what went wrong
   :type error: str
   :param publishingMsg: Warnings in the source code
   :type publishingMsg: dict
   :param moduleDependencies: The list of internal modules dependencies required to run the code
   :type moduleDependencies: list


   .. py:method:: __repr__()

      Return repr(self).



   .. py:method:: to_dict()

      Get a dict representation of the parameters in this class

      :returns: The dict value representation of the class parameters
      :rtype: dict



   .. py:method:: import_as_cell()

      Adds the source code as an unexecuted cell in the notebook.



.. py:class:: AbstractApiClass(client, id)

   .. py:method:: __eq__(other)

      Return self==value.



   .. py:method:: _get_attribute_as_dict(attribute)


.. py:class:: Algorithm(client, name=None, problemType=None, createdAt=None, updatedAt=None, isDefaultEnabled=None, trainingInputMappings=None, trainFunctionName=None, predictFunctionName=None, predictManyFunctionName=None, initializeFunctionName=None, configOptions=None, algorithmId=None, useGpu=None, algorithmTrainingConfig=None, onlyOfflineDeployable=None, codeSource={})

   Bases: :py:obj:`abacusai.return_class.AbstractApiClass`


   Customer created algorithm

   :param client: An authenticated API Client instance
   :type client: ApiClient
   :param name: The name of the algorithm
   :type name: str
   :param problemType: The type of the problem this algorithm will work on
   :type problemType: str
   :param createdAt: When the algorithm was created
   :type createdAt: str
   :param updatedAt: When the algorithm was last updated
   :type updatedAt: str
   :param isDefaultEnabled: Whether train with the algorithm by default
   :type isDefaultEnabled: bool
   :param trainingInputMappings: The mappings for train function parameters' names, e.g. names for training data, name for training config
   :type trainingInputMappings: dict
   :param trainFunctionName: Name of the function found in the source code that will be executed to train the model. It is not executed when this function is run.
   :type trainFunctionName: str
   :param predictFunctionName: Name of the function found in the source code that will be executed run predictions through model. It is not executed when this function is run.
   :type predictFunctionName: str
   :param predictManyFunctionName: Name of the function found in the source code that will be executed for batch prediction of the model. It is not executed when this function is run.
   :type predictManyFunctionName: str
   :param initializeFunctionName: Name of the function found in the source code to initialize the trained model before using it to make predictions using the model
   :type initializeFunctionName: str
   :param configOptions: Map dataset types and configs to train function parameter names
   :type configOptions: dict
   :param algorithmId: The unique identifier of the algorithm
   :type algorithmId: str
   :param useGpu: Whether to use gpu for model training
   :type useGpu: bool
   :param algorithmTrainingConfig: The algorithm specific training config
   :type algorithmTrainingConfig: dict
   :param onlyOfflineDeployable: Whether or not the algorithm is only allowed to be deployed offline
   :type onlyOfflineDeployable: bool
   :param codeSource: Info about the source code of the algorithm
   :type codeSource: CodeSource


   .. py:method:: __repr__()

      Return repr(self).



   .. py:method:: to_dict()

      Get a dict representation of the parameters in this class

      :returns: The dict value representation of the class parameters
      :rtype: dict



