[docs]@staticmethoddefhfunc1_0(obs:torch.Tensor,par:tuple[float])->torch.Tensor:"""first h function, Prob(V1<=v1 | V0=v0)"""rho=par[0]returnpnorm((qnorm(obs[:,[1]])-rho*qnorm(obs[:,[0]]))/sqrt(1.0-rho**2))
[docs]@staticmethoddefhinv1_0(obs:torch.Tensor,par:tuple[float])->torch.Tensor:"""inverse of the first h function, Q(p=v1 | V0=v0)"""rho=par[0]returnpnorm(qnorm(obs[:,[1]])*sqrt(1.0-rho**2)+rho*qnorm(obs[:,[0]]))