Skip to content

using MultivariateNormal raises Lapack Error in potrf #696

@fehiepsi

Description

@fehiepsi

In some cases, using MultivariateNormal distribution will throw errors RuntimeError: Lapack Error in potrf : the leading minor of order ... is not positive definite at ....

Here is a simple script to replicate the problem

import torch
from torch.autograd import Variable

import pyro
import pyro.distributions as dist

K = Variable(torch.rand((1000, 1000))).double()
K = K @ K.t()

y = Variable(torch.zeros(1000)).double()

z = pyro.sample("z", dist.MultivariateNormal(y, K))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions