| 40 | { |
| 41 | public: |
| 42 | MNISTBatchStream(int batchSize, int maxBatches, const std::string& dataFile, const std::string& labelsFile, |
| 43 | const std::vector<std::string>& directories) |
| 44 | : mBatchSize{batchSize} |
| 45 | , mMaxBatches{maxBatches} |
| 46 | , mDims{3, {1, 28, 28}} //!< We already know the dimensions of MNIST images. |
| 47 | { |
| 48 | readDataFile(locateFile(dataFile, directories)); |
| 49 | readLabelsFile(locateFile(labelsFile, directories)); |
| 50 | } |
| 51 | |
| 52 | void reset(int firstBatch) override |
| 53 | { |
nothing calls this directly
no test coverage detected