code: def test_gpvar_proj():
      # test that gp proj gives expected shapes
      batch = 1
      hidden_size = 3
      dim = 4
      rank = 2
  
      states = mx.ndarray.ones(shape=(batch, dim, hidden_size))
  
      gp_proj = GPArgProj(rank=rank)
      gp_proj.initialize()
  
      distr_args = gp_proj(states)
  
      mu, D, W = distr_args
  
      assert mu.shape == (batch, dim)
      assert D.shape == (batch, dim)
      assert W.shape == (batch, dim, rank)
  
      distr = LowrankMultivariateGaussian(dim, rank, *distr_args)
  
      assert distr.mean.shape == (batch, dim)
  
file_path: gluonts/test/mx/model/gpvar/test_gpvar.py
imports: import mxnet
  import pytest
  from flaky import flaky
  from gluonts.dataset.artificial import constant_dataset
  from gluonts.dataset.common import TrainDatasets
  from gluonts.dataset.multivariate_grouper import MultivariateGrouper
  from gluonts.evaluation import backtest_metrics, MultivariateEvaluator
  from gluonts.mx.model.gpvar import GPVAREstimator
  from gluonts.mx.distribution import LowrankMultivariateGaussian
  from gluonts.mx.distribution.lowrank_gp import GPArgProj, LowrankGPOutput
  from gluonts.mx.trainer import Trainer
label_desc: Use image node_id 3 for calling a global function with example usage: test_gpvar_proj() without return types