Skip to content

SimplicialLDLT Error on Windows #449

@chnce

Description

@chnce

SimplicialLDLT gives an error on windows (installed from conda-forge)

I created a fresh environment and installed eigenpy.

micromamba install eigenpy -n eigenpy -c conda-forge

Name                   Version       Build                  Channel
---------------------------------------------------------------------------
  bzip2                  1.0.8         hcfcfb64_5             conda-forge
  ca-certificates        2024.2.2      h56e8100_0             conda-forge
  eigen                  3.4.0         h91493d7_0             conda-forge
  eigenpy                3.4.0         py312h0bfd76e_0        conda-forge
  intel-openmp           2024.0.0      h57928b3_49841         conda-forge
  libblas                3.9.0         21_win64_mkl           conda-forge
  libboost               1.82.0        h65993cd_6             conda-forge
  libboost-devel         1.82.0        h91493d7_6             conda-forge
  libboost-headers       1.82.0        h57928b3_6             conda-forge
  libboost-python        1.82.0        py312h4f1204c_6        conda-forge
  libboost-python-devel  1.82.0        py312hd42ba9a_6        conda-forge
  libcblas               3.9.0         21_win64_mkl           conda-forge
  libexpat               2.6.2         h63175ca_0             conda-forge
  libffi                 3.4.2         h8ffe710_5             conda-forge
  libhwloc               2.9.3         default_haede6df_1009  conda-forge
  libiconv               1.17          hcfcfb64_2             conda-forge
  liblapack              3.9.0         21_win64_mkl           conda-forge
  libsqlite              3.45.2        hcfcfb64_0             conda-forge
  libxml2                2.12.6        hc3477c8_0             conda-forge
  libzlib                1.2.13        hcfcfb64_5             conda-forge
  mkl                    2024.0.0      h66d3029_49657         conda-forge
  numpy                  1.26.4        py312h8753938_0        conda-forge
  openssl                3.2.1         hcfcfb64_0             conda-forge
  pip                    24.0          pyhd8ed1ab_0           conda-forge
  pthreads-win32         2.9.1         hfa6e2cd_3             conda-forge
  python                 3.12.2        h2628c8c_0_cpython     conda-forge
  python_abi             3.12          4_cp312                conda-forge
  scipy                  1.12.0        py312h8753938_2        conda-forge
  setuptools             69.2.0        pyhd8ed1ab_0           conda-forge
  tbb                    2021.11.0     h91493d7_1             conda-forge
  tk                     8.6.13        h5226925_1             conda-forge
  tzdata                 2024a         h0c530f3_0             conda-forge
  ucrt                   10.0.22621.0  h57928b3_0             conda-forge
  vc                     14.3          hcf57466_18            conda-forge
  vc14_runtime           14.38.33130   h82b7239_18            conda-forge
  vs2015_runtime         14.38.33130   hcb4865c_18            conda-forge
  wheel                  0.42.0        pyhd8ed1ab_0           conda-forge
  xz                     5.2.6         h8d14728_0             conda-forge
  zstd                   1.5.5         h12be248_0             conda-forge

Then I tried to run the unittest for SimplicialLDLT

import numpy as np
from scipy.sparse import csc_matrix

import eigenpy

dim = 100
rng = np.random.default_rng()

A = rng.random((dim, dim))
A = (A + A.T) * 0.5 + np.diag(10.0 + rng.random(dim))

A = csc_matrix(A)

ldlt = eigenpy.SimplicialLDLT(A)

which resulted in the following error:
TypeError: No registered converter was able to produce a C++ rvalue of type class Eigen::Matrix<int,-1,1,0,-1,1> from this Python object of type numpy.ndarray

The issue seems to be only present on Windows.
On my macbook (osx-arm64) everything works as expected.

Metadata

Metadata

Assignees

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