# file: nedc_eeg_resnet_train/nedc_eeg_resnet_train.txt
#
# A parameter file that defines key paramters for training ResNet18 for EEG.
# 
#
# revision history:
#
# 20210424 (VK): initial version
#

# set version information
#
version = param_v1.0.0

#------------------------------------------------------------------------------

EEG_RESNET {

    # sample_frequency is measured in Hz (50 Hz).
    # frame_duration is the duration of a frame in secs (256 samples @ 50 Hz).
    # transform_crop is the amount of time we away (32 samples @ 50 Hz).
    #    The combination of frame_duration and transform_crop were based on
    #    what was used for the ImageNet competitions.
    # The transform order is frame_duration_in_samples - transform_crop.
    #
    sample_frequency = 50.000
    frame_duration = 5.1200
    transform_crop = 32

    # batch size
    #
    # bat_size = 8
    bat_size = 200

    # channels property:
    #
    channel_order = "['FP1-F7', 'F7-T3', 'T3-T5', 'T5-O1', 'FP2-F8', 'F8-T4', 'T4-T6', 'T6-O2', 'T3-C3', 'C3-CZ', 'CZ-C4', 'C4-T4', 'FP1-F3', 'F3-C3', 'C3-P3', 'P3-O1', 'FP2-F4', 'F4-C4', 'C4-P4', 'P4-O2']"
    
    # number of epochs
    #
    num_epochs = 16

    # boolean value set to true if you want to save the model created after
    # every epoch or false to just save the best model
    #
    save_model_every_epoch = false

    # number of workers to load data into memory
    #
    num_workers = 8

    # select a CPU or GPU device:
    #  decoding does not run significantly faster on a GPU, so we use
    #  CPUs for decoding since we have a lot of available CPUs.
    #
    # device = 'cuda:2'
    device = 'cuda:0'

    #  The first set of numbers for transforms.Normalize are RGB means,
    #  while the second set of numbers are the standard deviations of
    #  pixel values for the ImageNet database.
    #
    # Notes:
    #  Using Imagenet data is common practice when using images in deep
    #  learning. This is because of the large database that ImageNet
    #  boasts (over 1 million classified images). More information
    #  about ImageNet can be found here:
    #   https://www.image-net.org/about.php
    #
    #  transforms.Resize resizes the image to a specified length and width
    #  transforms.CenterCrop crops the image to a specified length and width
    #  transforms.ToTensor converts the PIL image to tensor format and scales
    #    the pixel values between 0.0 and 1.0
    #  transforms.Normalize normalizes (smooths) the image by applying the
    #    formula: out = (in - mean) / standard deviation, the first list
    #    contains mean values for the red, blue and green channels.
    #
    train_transforms = 'transforms.Compose([transforms.RandomResizedCrop(transform_order), transforms.RandomHorizontalFlip(),transforms.ToTensor(),transforms.Normalize([0.485, 0.456, 0.406], [0.229, 0.224, 0.225])])'
    dev_transforms = 'transforms.Compose([transforms.Resize(frmsize), transforms.CenterCrop(transform_order), transforms.ToTensor(), transforms.Normalize([0.485, 0.456, 0.406], [0.229, 0.224, 0.225])])'
    
}

#------------------------------------------------------------------------------
#
# end of file
#
#------------------------------------------------------------------------------
