wormpose.machine_learning.eval_data_generator¶
Generates evaluation data: random real processed images with labels and save them to a Tfrecord file
- wormpose.machine_learning.eval_data_generator.generate(dataset: wormpose.dataset.loader.Dataset, num_samples: int, theta_dims: int, file_pattern: str) int [source]¶
Generates evaluation dataset composed of processed real images, saved to a .TFrecord
- Parameters
dataset – WormPose Dataset
num_samples – How many images to generate
theta_dims – Dimensions of theta for the labels
file_pattern – Path of the output files with “index” variable example: “path_to_out/eval_{index}.tfrecord”
- Returns
How many samples where actually generated (if there is less data than the requested num_samples)