Development#

The development mode of a project helps you as you iterate on your models and datasets. You will use the methods described on this page to add models and datasets to your development project,

To use these methods, you must have:

  1. Authenticated, using openlayer.OpenlayerClient

  2. Created a project, using openlayer.OpenlayerClient.create_project

Related guide: How to upload datasets and models for development.

Staging area#

The upload of models and datasets to a project on Openlayer follows a similar flow to the one for uploading files to a version control system like Git.

The add_* methods, add models and datasets to the local staging area. As you add resources to the staging area, you can check its status using the status method.

Finally, the resources on the staging area are committed and pushed to the Openlayer platform using the commit and push methods.

Datasets#

Datasets stored as Pandas dataframes or csv files can be easily added to a project’s staging area with the methods below.

Project.add_dataset(*args, **kwargs)

Adds a dataset (csv file) to a project's staging area.

Project.add_dataframe(*args, **kwargs)

Adds a dataset (Pandas dataframe) to a project's staging area.

Models#

Models are added to the staging area using the add_model method.

Project.add_model(*args, **kwargs)

Adds a model to a project's staging area.

Committing and pushing#

After adding resources to the staging area, you can commit and push them to Openlayer.

Project.commit(*args, **kwargs)

Adds a commit message to staged resources.

Project.push(*args, **kwargs)

Pushes the commited resources to the platform.

Other methods to interact with the staging area#

Additional methods used to interact with the staging area.

Project.status(*args, **kwargs)

Shows the state of the staging area.

Project.restore(*args, **kwargs)

Removes the resources specified from the staging area.

Project.export(*args, **kwargs)

Exports the commit bundle as a tarfile to the location specified by destination_dir.

Checking a project version’s goal statuses#

To programatically check the status of a project version’s goals, use the ProjectVersion object, which can be obtained using the load_project_version method.

ProjectVersion(json, client)

An object containing information about a project version on the Openlayer platform.

OpenlayerClient.load_project_version(version_id)

Loads an existing project version from the Openlayer platform.