code: public INDArray array() {
          List<INDArray> retList = new ArrayList<>(list.size());
          for(X x : list) {
              INDArray arr = x.array();
              retList.add(arr.reshape(1, arr.length()));
          }
  
          return Nd4j.concat(0,retList.toArray(new INDArray[retList.size()]));
      }
docs: Get a view of the underlying array
  relative to the size of the actual array.
  (Sometimes there are overflows in the internals
  but you want to use the internal INDArray for computing something
  directly, this gives you the relevant subset that reflects the content of the list)
  @return the view of the underlying ndarray relative to the collection's real size