class_docstr: Construct a DeepNPTS estimator. This is a tunable extension of NPTS
  where the sampling probabilities are learned from the data. This is a
  global-model unlike NPTS.
  
  Currently two variants of the model are implemented:
  (i) `DeepNPTSNetworkDiscrete`: the forecast distribution is a discrete
  distribution similar to NPTS and the forecasts are sampled from the
  observations in the context window.
  (ii) `DeepNPTSNetworkSmooth`: the forecast distribution is a smoothed
  mixture distribution where the components of the mixture are Gaussians
  centered around the observations in the context window. The mixing
  probabilities and the width of the Gaussians are learned. Here the
  forecast can contain values not observed in the context window.
  
  Parameters
  ----------
  freq
      Frequency of the data to train on and predict
  prediction_length
      Length of the prediction horizon
  context_length
      Number of steps to unroll the RNN for before computing predictions
      (default: None, in which case context_length = prediction_length)
  num_hidden_nodes
      A list containing the number of nodes in each hidden layer
  batch_norm
      Flag to indicate if batch normalization should be applied at every
      layer
  use_feat_static_cat
      Whether to use the ``feat_static_cat`` field from the data
      (default: False)
  num_feat_static_real
      Number of static real features in the data set
  num_feat_dynamic_real
      Number of dynamic features in the data set. These features are added
      to the time series features that are automatically created based on
      the frequency
  cardinality
      Number of values of each categorical feature
      This must be set if ``use_feat_static_cat == True`` (default: None)
  embedding_dimension
      Dimension of the embeddings for categorical features
      (default: [min(50, (cat+1)//2) for cat in cardinality])
  input_scaling
      The scaling to be applied to the target values.
      Available options: "min_max_scaling" and "standard_normal_scaling"
      (default: no scaling)
  dropout_rate
      Dropout regularization parameter (default: no dropout)
  network_type
      The network to be used: either the discrete version
      `DeepNPTSNetworkDiscrete` or the smoothed version
      `DeepNPTSNetworkSmooth` (default: DeepNPTSNetworkDiscrete)
code: def get_predictor(
      self, net: torch.nn.Module, device="cpu"
  ) -> PyTorchPredictor:
      pred_net_multi_step = DeepNPTSMultiStepNetwork(
          net=net, prediction_length=self.prediction_length
      )
  
      return PyTorchPredictor(
          prediction_net=pred_net_multi_step,
          prediction_length=self.prediction_length,
          input_names=self.features_fields
          + self.prediction_features_field,
          batch_size=self.batch_size,
          input_transform=self.input_transform()
          + self.instance_splitter(TestSplitSampler(), is_train=False),
          device=device,
      )
  
imports: from copy import deepcopy
  from typing import Dict, List, Optional, Callable, Union
  from functools import partial
  import torch
  from gluonts.core.component import validated
  from gluonts.dataset.common import Dataset
  from gluonts.dataset.field_names import FieldName
  from gluonts.dataset.loader import DataLoader, TrainDataLoader
  from gluonts.itertools import Cached
  from gluonts.model.estimator import Estimator
  from gluonts.time_feature import time_features_from_frequency_str
  from gluonts.torch.batchify import batchify
  from gluonts.torch.model.predictor import PyTorchPredictor
  from gluonts.transform import Chain, AddAgeFeature, AddObservedValuesIndicator, AddTimeFeatures, AsNumpyArray, InstanceSplitter, ExpectedNumInstanceSampler, RemoveFields, SelectFields, SetField, TestSplitSampler, Transformation, TransformedDataset, VstackFeatures
  from ._network import DeepNPTSNetwork, DeepNPTSNetworkDiscrete, DeepNPTSMultiStepNetwork
  from .scaling import min_max_scaling, standard_normal_scaling
label_desc: Use image node_id 6 for calling the DeepNPTSEstimator obj's underlying member method code with example usage: obj.get_predictor(net, device) and returns: PyTorchPredictor