Skip to content
Snippets Groups Projects
Commit d4cb2523 authored by siranipour's avatar siranipour
Browse files

Adding check to see if either tr or val mask is empty

We need this if we have an experiment mixed with pure training and mixed training datasets
parent 907608d9
No related branches found
No related tags found
1 merge request!920Writing pseudodata to file
......@@ -540,8 +540,13 @@ void TrainValidSplit(NNPDFSettings const& settings,
std::sort(valMaskset.begin(), valMaskset.end());
trMasks.push_back(trMaskset);
valMasks.push_back(valMaskset);
// If either of the training or validation mask sets
// are empty then don't insert them into the vector
// of masks
if (trMaskset.size() != 0)
trMasks.push_back(trMaskset);
if (valMaskset.size() != 0)
valMasks.push_back(valMaskset);
if (settings.IsThUncertainties())
{
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment