Commit da09d9a8 authored by Cresson Remi's avatar Cresson Remi
Browse files

ENH: fix bug with nodata

parent 7c3b028b
......@@ -163,8 +163,6 @@ TensorflowSampler<TInputImage, TVectorData>
labelIndex[0] = 0;
PixelType labelPix;
labelPix.SetSize(1);
std::cout << "REJECT is " << m_RejectPatchesWithNodata << std::endl;
std::cout << "NODATAVAL is " << m_NodataValue << std::endl;
while (!itVector.IsAtEnd())
{
if (!itVector.Get()->IsRoot() && !itVector.Get()->IsDocument() && !itVector.Get()->IsFolder())
......@@ -199,12 +197,11 @@ TensorflowSampler<TInputImage, TVectorData>
for (it.GoToBegin(); !it.IsAtEnd(); ++it)
{
PixelType pix = it.Get();
std::cout << pix << std::endl;
for (int i; i<pix.Size(); i++)
if (pix[i] == m_NodataValue)
{
std::cout << "[0]: pix[" << i << "]=" << pix[i] << std::endl;
hasBeenSampled = false;
std::cout << "break" << std::endl;
break;
}
if (!hasBeenSampled)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment