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.client 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.9.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | e20e5795881f23c57d31745ec7a8791aeb193b329a0eee21423d92bae577a8a8 |
|
MD5 | b7bc07c9ca6e42d40b5e8cd84fdeed8d |
|
BLAKE2b-256 | 853582f802340bfbcd6b23f6ee3a555243a6907fcfcff7f03c4ef459ea0599db |
Close
Hashes for mindfoundry.client.horizon-2.13.9-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 54f93bdf30e28b53f44005cd69289573b327412585b0abab0777f840ced958f6 |
|
MD5 | f256330d21cc428930b82d6b2c8b6912 |
|
BLAKE2b-256 | f54e3616da20bf9c16f41bc4e51c630423682793a7197b87ba6fa42a2032f4cd |