docs: public INDArray params(boolean backwardOnly) {
          if (backwardOnly)
              return params();
  
          List<INDArray> params = new ArrayList<>();
          for (Layer layer : getLayers()) {
              INDArray layerParams = layer.params();
              if (layerParams != null)
                  params.add(layerParams); //may be null: subsampling etc layers
          }
  
          return Nd4j.toFlattened('f', params);
      }