docs: public INDArray params(boolean backwardOnly) {
          if (backwardOnly)
              return flattenedParams;
  
          List<INDArray> list = new ArrayList<>(layers.length);
          for (int i = 0; i < topologicalOrder.length; i++) {
              if (!vertices[topologicalOrder[i]].hasLayer())
                  continue;
  
              Layer l = vertices[topologicalOrder[i]].getLayer();
              INDArray layerParams = l.params();
              if (layerParams != null)
                  list.add(layerParams); //may be null: subsampling etc layers
          }
  
          return Nd4j.toFlattened('f', list);
      }