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.8.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | a7a9549afed728869535ef09427e61de521c888f546a148412d8e9502c5db8c2 |
|
MD5 | 0e63bd978948e53b27f22bb662d32378 |
|
BLAKE2b-256 | 6e1eed90f613ac68a101d165afefe1e79b70820dd460ab5275ca024b52e2f9bc |
Close
Hashes for mindfoundry.client.horizon-2.13.8-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 508116f68dc920f485bc8697c53029bb2fde99b75165d075384444737f19b63e |
|
MD5 | 5c327d6937f5247407e033870d9f6c90 |
|
BLAKE2b-256 | 664182bb7332000ba2ecc10459cc4efa765d0494a9333cee1500c36d36101008 |