Skip to content
Snippets Groups Projects
Commit acaea155 authored by Robert K's avatar Robert K
Browse files

[cleanup][Python] numpy.float_ --> numpy.float64. Use of float_ will lead to...

[cleanup][Python] numpy.float_ --> numpy.float64. Use of float_ will lead to AttributeError with numpy-2.0.
parent cd9b8809
No related branches found
No related tags found
1 merge request!1375[cleanup][Python] numpy.float_ --> numpy.float64.
Pipeline #70648 passed
Pipeline: Dune Nightly Test

#70651

    ......@@ -18,7 +18,7 @@ def cppType(arg):
    t, i = "long", []
    elif isinstance(arg,numpy.intp):
    t, i = "std::size_t", []
    elif isinstance(arg, float) or isinstance(arg,numpy.float_):
    elif isinstance(arg, float) or isinstance(arg,numpy.float64):
    t, i = "double", []
    elif isinstance(arg, numpy.ndarray):
    dtype = None
    ......@@ -28,7 +28,7 @@ def cppType(arg):
    dtype="long"
    elif arg.dtype.type == numpy.intp:
    dtype="std::size_t"
    elif arg.dtype.type == numpy.float_:
    elif arg.dtype.type == numpy.float64:
    dtype="double"
    if dtype is None:
    t, i = "pybind11::array", ["dune/python/pybind11/numpy.h"]
    ......
    0% Loading or .
    You are about to add 0 people to the discussion. Proceed with caution.
    Please register or to comment