ramjet.trial¶
Boilerplate code for running trials.
Module Contents¶
Functions¶
infer(model: tf.keras.Model, dataset: tf.data.Dataset, infer_results_path: Path, number_of_top_predictions_to_keep: int = None) |
Performs inference of a model on a dataset saving the results to a file. |
save_results(predictions_data_frame: pd.DataFrame, infer_results_path: Path, number_of_top_predictions_to_keep: int = None) |
Saves a predictions data frame to a file. |
-
infer(model: tf.keras.Model, dataset: tf.data.Dataset, infer_results_path: Path, number_of_top_predictions_to_keep: int = None)[source]¶ Performs inference of a model on a dataset saving the results to a file.
Parameters: - model – The model to infer with.
- dataset – The dataset to infer on.
- infer_results_path – The path to save the resulting predictions to.
- number_of_top_predictions_to_keep – The number of top results to keep. None will save all results.
-
save_results(predictions_data_frame: pd.DataFrame, infer_results_path: Path, number_of_top_predictions_to_keep: int = None)[source]¶ Saves a predictions data frame to a file.
Parameters: - predictions_data_frame – The data frame of predictions to save.
- infer_results_path – The path to save the resulting predictions to.
- number_of_top_predictions_to_keep – The number of top results to keep. None will save all results.
Returns: