# Declare some parameters batch_size = 32 # Define some model-specific parameters elg_first_layer_stride = 1 elg_num_modules = 3 elg_num_feature_maps = 32 # Define training data source from datasources import UnityEyes unityeyes = UnityEyes( session, batch_size=batch_size, data_format='NCHW', unityeyes_path='/home/xiehuan/datasets/UnityEyes_Windows/imgs', min_after_dequeue=1000, generate_heatmaps=True, shuffle=True, staging=True, eye_image_shape=(36, 60), heatmaps_scale=1.0 / elg_first_layer_stride, ) unityeyes.set_augmentation_range('translation', 2.0, 10.0) unityeyes.set_augmentation_range('rotation', 1.0, 10.0) unityeyes.set_augmentation_range('intensity', 0.5, 20.0) unityeyes.set_augmentation_range('blur', 0.1, 1.0) unityeyes.set_augmentation_range('scale', 0.01, 0.1) unityeyes.set_augmentation_range('rescale', 1.0, 0.5) unityeyes.set_augmentation_range('num_line', 0.0, 2.0) unityeyes.set_augmentation_range('heatmap_sigma', 7.5, 2.5) from datasources import HDF5Source
test_losses_or_metrics=['gaze_mse', 'gaze_angular'], # Data sources for training and testing. train_data={ 'real': HDF5Source( session, batch_size, hdf_path='../datasets/MPIIGaze_kaggle_students.h5', keys_to_use=['train'], min_after_dequeue=100, ), 'unity': UnityEyes( session, batch_size, unityeyes_path='../datasets/UnityEyes/', ) }, test_data={ 'real': HDF5Source( session, batch_size, hdf_path='../datasets/MPIIGaze_kaggle_students.h5', keys_to_use=['validation'], testing=True, ), }, beta1=BETA1, beta2=BETA2)