Skip to main content
App version: 3.4.11

Neptune API

The Neptune API consists of two Python packages:

Setup

For installation instructions, see Get started.

Usage

To import Neptune in your model-training code:

from neptune_scale import Run

You can then work with Run objects to create or resume experiments:

run = Run(...)
caution

Neptune's worker process creation method requires the standard Python "main guard":

if __name__ == "__main__":
# your Neptune code
run = Run(...)

For details, see the Python documentation.

FAQ

How does the Neptune client handle errors?

In case of metadata inconsistencies or other failures, you can control what happens by configuring the NEPTUNE_LOG_FAILURE_ACTION environment variable.

For more information, see Neptune API error handling.

Can we filter out Neptune warnings from our logs?

Yes, you can define a filter callback for Neptune-related warnings. For instructions, see Filter out Neptune warnings from logs.

How can we migrate our code from legacy Neptune?

See the Neptune Python client 1.x migration guide.