Make Predictions

Large helper method for driving all AI-related tasks.

Handles running:

  1. Building Models
  2. Compiling Models
  3. Creating Datasets for Train, Test, and Predictions
  4. Fitting Models
  5. Evaluating Models
  6. Cross Validating Models
  7. Merging Predictions with Original Records

Here is the file on GitHub in case the automodule failed to process:

make_predictions.py

antinex_utils.make_predictions.build_regression_dnn(num_features, compile_data, label='', model_json=None, model_desc=None)[source]
Parameters:
  • num_features – input_dim for the number of features in the data
  • compile_data – dictionary of compile options
  • label – log label for tracking this method
  • model_json – keras model json to build the model
  • model_desc – optional dictionary for model
antinex_utils.make_predictions.build_classification_dnn(num_features, compile_data, label='', model_json=None, model_desc=None)[source]
Parameters:
  • num_features – input_dim for the number of features in the data
  • compile_data – dictionary of compile options
  • label – log label for tracking this method
  • model_json – keras model json to build the model
  • model_desc – optional dictionary for model
antinex_utils.make_predictions.check_request(req)[source]
Parameters:req – dictionary to check values
antinex_utils.make_predictions.save_prediction_image(label='not-set', history=None, histories=[], image_file=None)[source]
Parameters:
  • history – model prediction history
  • histories – histories to generate in the image
  • image_file – save to file
antinex_utils.make_predictions.make_predictions(req)[source]
Parameters:req – dictionary for making predictions