Managing forecasts

A forecast is a set of predictions for combinations of units and targets. See Data Model for detail on the structure of predictions. Following are the forecast operations you can do from within Zoltar.

Note: Operations on forecasts, like many Zoltar activities, can be done either through the zoltardata.com web interface or programmatically using the Zoltar libraries.

Upload a forecast

Here we show how to upload forecast data into Zoltar. It is important to know that Zoltar enqueues long operations like forecast uploading, which keeps the site responsive but makes uploading a little more complicated. Rather than having the upload feature block until the upload is done, you instead get a quick response in the form of an upload file job detail page that shows the status of your upload. This page is described in Check an upload's status below.

Forecasts are uploaded to a particular model for a particular time zero. To upload one:

  1. Go to the model detail page of the one you want to upload into.
  2. Find the time zero that the forecast is associated with.
  3. If the time zero already has a forecast then delete it (see Delete a forecast below). You can tell if a time zero has an uploaded forecast in two ways: the text in the "Data Source" column is a link instead of the words "(No data)" and the icon in the "Action" column is a red trash can and not a green upload icon.
  4. Click the "Browse..." button in the time zero's "Action" column.
  5. In the dialog that appears, select a Forecast data format JSON file
  6. Click the green upload button.
  7. If the file is OK then you will be taken to an upload file job detail page that shows the status of your upload, with the message "Queued the forecast file for uploading.", where is your file's name. See Check an upload's status below for this page's details.
  8. Once the upload is successful (you can refresh the upload file job page to check) then you will see it next to the selected time zero on the model detail page.
  9. If there was a problem uploading then you will see the upload's status as FAILED. The Failure section will provide some information to help debug the problem.

Download a forecast

To download a forecast:

  1. Go to the model detail page where the forecast resides.
  2. Click the link in the "Data Source" column to go to the forecast detail page.
  3. Click the "Download JSON" button and save the file in the JSON format documented at Forecast data format for details.

Delete a forecast

Delete a forecast via these steps:

  1. Go to the model detail page where the forecast resides.
  2. Click the red trash can button in the "Action" column.
  3. Click "Delete" in the confirmation dialog that appears. Note that this cannot be undone!

Check an upload's status

As described above, uploading a file enqueues the actual uploading of the data for handling by a Zoltar worker process, rather than processing the upload immediately. The upload file job detail page is where you can check the status of an upload. (Note that how long it takes for a file to be processed depends on how busy the site is.) Here's an example upload file job detail page for one whose status is QUEUED:

Upload file job detail page

You can see that it has the following fields:

  • User: User who uploaded the file.
  • Status: The upload's status, which is one of the following:
    • PENDING: The state an upload starts in.
    • CLOUD_FILE_UPLOADED: The uploaded file was successfully saved to temporary cloud storage.
    • QUEUED: The upload file job was successfully enqueued for processing.
    • CLOUD_FILE_DOWNLOADED: The uploaded file was successfully retrieved from temporary cloud storage
    • SUCCESS: The job was successfully completed.
    • FAILED: The job failed.
  • File Name: The uploaded file's name that was given to Zoltar.
  • Failure: The failure message if status is FAILED, or "None" otherwise. This section will provide some information to help debug the problem.
  • ΔT: How much time the upload took to process. This is formatted as "::.", For example, "0:00:01.155223" means the job took zero hours, zero minutes, one second, and 155223 microseconds.
  • Created: Date and time the file was uploaded at.
  • Updated: The last time the upload's status was changed.
  • JSON In: The JSON information passed internally to the upload. You can ignore this.
  • JSON Out: "" returned internally by the upload. ""

Note that you must refresh this page to get the latest status (it does not update dynamically).

You can see all of your upload file jobs in the Upload File Jobs section on your user profile page.

For reference, here are two other jobs in different states. This one's state is SUCCESS:

Upload file job success

And this one FAILED:

Upload file job failed