Mind Foundry Horizon Client
Project description
Mind Foundry Horizon Client
This package contains a python client that can be used to interact with an instance of Mind Foundry Horizon. The client exposes a familiar interface that allows you to tackle forecasting problems with ease.
from mindfoundry.client.horizon import Connection
from mindfoundry.client.horizon.models import HorizonForecaster
# Generate an API key in the Horizon dashboard
connection = Connection(
base_url="your Horizon instance",
api_key="your api key",
)
# Create a new forecasting model. See the complete documentation
# for a more in-depth explanation of each argument.
model = HorizonForecaster(
connection=connection,
name="My Forecaster",
targets=["target1", "target2", ...],
horizons=[1, 2, 3],
refinement=False,
)
# Train a model on some training data (a pandas dataframe)
model.fit(training_data)
# Make a prediction on new data
prediction = model.predict(new_data)
print(prediction.as_df().head())
# Save the model for later use
model.save("/path/to/model/file")
# Re-load the model
model = HorizonForecaster.load("/path/to/model/file", connection=connection)
# The model can be updated with new data in the same format
model.update(new_data_2)
new_prediction = model.predict()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for mindfoundry.client.horizon-2.13.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2f32d39219cf2e433524eb48ddb8386b4eb58efe74655c63b5f3f0e44d0fcc9d |
|
MD5 | 39f4ccd7eae94272bff2049415715fdb |
|
BLAKE2b-256 | f5ac3674e723f53f68a40349d1c1258a020b2b0c17cfa4f3169fa846c8f1b5c3 |
Close
Hashes for mindfoundry.client.horizon-2.13.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2cdb9ae7bf694fe51a3e0e590d979c95bb111f4d29a4479674b881efab4afbae |
|
MD5 | 34d3b3fd3822c0848223eefb7a0e0c3b |
|
BLAKE2b-256 | e841da4cb35c3a27a1133d6c20a744c8ca7376b82e5387923c83228da9932dc9 |