Skip to content
Snippets Groups Projects
Commit 7f85a75c authored by Olivier BICHLER's avatar Olivier BICHLER
Browse files

Fixed bug with dropLast

parent 5b2d9b4b
No related branches found
No related tags found
No related merge requests found
......@@ -42,8 +42,8 @@ Aidge::DataProvider::DataProvider(const Aidge::Database& database, const std::si
// Compute the number of bacthes depending on mDropLast boolean
mNbBatch = (mDropLast) ?
static_cast<std::size_t>(std::floor(mNbItems / mBatchSize)) :
static_cast<std::size_t>(std::ceil(mNbItems / mBatchSize));
(mNbItems / mBatchSize) :
static_cast<std::size_t>(std::ceil(mNbItems / static_cast<float>(mBatchSize)));
}
std::vector<std::shared_ptr<Aidge::Tensor>> Aidge::DataProvider::readBatch() const
......
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