Predictions

Once you have your project, you can train it and run predictions on it. For the training, the project has the .launch_train() and .stop_train() methods, as well as the .train_status property, which can be used like so:

my_project = wg.project_from_id("<Your Project ID>")

my_project.train_status
False

my_project.lauch_train()
my_project.train_status
True

my_project.stop_train()
my_project.train_status
False

Once the train is complete, you can run predictions on the case IDs you want in your project:

my_project = wg.project_from_id("<Your Project ID>")
my_project.train_status # we can make sure the training is finished
False

case_list = ["<Case ID 1>", "<Case ID 2>", "<Case ID 3>"]
prediction_data = my_project.prediction(case_list)