class_docstr: NCP (Nearly-Constant Position) dynamic model. May be subclassed, e.g., with
  CWNV (Continuous White Noise Velocity) or DWNV (Discrete White Noise
  Velocity).
  
  :param dimension: native state dimension.
  :param sv2: variance of velocity. Usually chosen so that the standard
        deviation is roughly half of the max velocity one would ever expect
        to observe.
class_docstr_tok: ["NCP","(","Nearly-Constant","Position",")","dynamic","model",".","May","be","subclassed",",","e.g.",",","with","CWNV","(","Continuous","White","Noise","Velocity",")","or","DWNV","(","Discrete","White","Noise","Velocity",")",".",":","param","dimension",":","native","state","dimension",".",":","param","sv2",":","variance","of","velocity",".","Usually","chosen","so","that","the","standard","deviation","is","roughly","half","of","the","max","velocity","one","would","ever","expect","to","observe","."]
docstr: Compute and return PV covariance from native covariance. Useful for
  combining state estimates of different types in IMM (Interacting
  Multiple Model) filtering.
  
  :param P: native state estimate covariance.
  :return: PV state estimate covariance.
docstr_tok: ["Compute","and","return","PV","covariance","from","native","covariance",".","Useful","for","combining","state","estimates","of","different","types","in","IMM","(","Interacting","Multiple","Model",")","filtering",".",":","param","P",":","native","state","estimate","covariance",".",":","return",":","PV","state","estimate","covariance","."]
code: def cov2pv(self, P):
      """
      Compute and return PV covariance from native covariance. Useful for
      combining state estimates of different types in IMM (Interacting
      Multiple Model) filtering.
  
      :param P: native state estimate covariance.
      :return: PV state estimate covariance.
      """
      d = 2 * self._dimension
      with torch.no_grad():
          P_pv = torch.zeros(d, d, dtype=P.dtype, device=P.device)
          P_pv[: self._dimension, : self._dimension] = P
      return P_pv
  
imports: from abc import ABCMeta, abstractmethod
  import torch
  from torch import nn
  from torch.nn import Parameter
  import pyro.distributions
  from pyro.distributions.util import eye_like
label_desc: Use image node_id 4 for calling the Ncp obj's underlying member method code with example usage: obj.cov2pv(P) and returns: P_pv