Commit 1205af52 authored by remi cresson's avatar remi cresson
Browse files

FIX: last dimension of input tensor can be 1..N

parent c51f8e1c
...@@ -261,7 +261,7 @@ TensorflowMultisourceModelFilter<TInputImage, TOutputImage> ...@@ -261,7 +261,7 @@ TensorflowMultisourceModelFilter<TInputImage, TOutputImage>
// The number of components per pixel is the last dimension of the tensor // The number of components per pixel is the last dimension of the tensor
int dim_size = protoShape.dim_size(); int dim_size = protoShape.dim_size();
unsigned int nComponents = 1; unsigned int nComponents = 1;
if (1 < dim_size && dim_size <= 4) if (0 < dim_size && dim_size <= 4)
{ {
nComponents = protoShape.dim(dim_size-1).size(); nComponents = protoShape.dim(dim_size-1).size();
} }
......
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