The file s2-gap-12dates.csv, does it contain labels from 1 to num_classes or from 0 to num_class -1?
Cross Entropy loss asumes target from 0 to num_class -1 ?
And the error Assertion cur_targer >= 0 && cur_target < n_classes failed that means there is some problems with your labels, and this is the most probable mistake