int labelCount_; // How many classes of labels exist? (e.g. 10 in CIFAR-10) public bool HasUninitialized() { // exists X in dataset. forall i. X(i) == 0 for (int i = 0; i < data_.Count(); i++) { double[] datum = data_.Get(i); bool allzero = true; for (int j = 0; j < datum.Length; j++) { if (datum[j] != 0.0) { allzero = false; break; } } if (allzero) { return(true); } } return(false); }
public int GetLabel(int i) { return(labels_.Get(i)); }