       for(int i = 0; i < 4; ++i)
         dims2[i] = dims1[permute[i]];
 
-      int inIndex = inShape.bindex(dims2);
+      int inIndex = inShape.index(dims2);
 
       out[index] = in[inIndex];
     }

        dims[axis] -= lengths[i++];

      inShape.set(axis, lengths[i]);
      int inIndex = inShape.bindex(dims);

      const float* in = ins[i];
      out[index] = in[inIndex];

        dims[axis] -= lengths[i++];

      outShape.set(axis, lengths[i]);
      int outIndex = outShape.index(dims);

      float* out = outs[i];
      out[outIndex] = in[index];
