Skip to content

NumPy does not properly support sub-interpreters #27192

Closed as not planned
Closed as not planned

Description

@alissonrodrigo

Steps to reproduce:

I use the GeoPandas library which in turn uses NumPy but when I upload it to the server I get an error message. I've tried a few approaches but without success. Can anyone help me how to get around this?

Error message:

/site-packages/geopandas/geoseries.py:8: UserWarning: NumPy was imported from a Python sub-interpreter but NumPy does not properly support sub-interpreters. This will likely work for most users but might cause hard to track down issues or subtle bugs. A common user of the rare sub-interpreter feature is wsgi which also allows single-interpreter mode.
[Mon Aug 12 08:23:44.378265 2024] [wsgi:error] [pid 3774222:tid 140048613742336] Improvements in the case of bugs are welcome, but is not on the NumPy roadmap, and full support may require significant effort to achieve.
[Mon Aug 12 08:23:44.378274 2024] [wsgi:error] [pid 3774222:tid 140048613742336]   import numpy as np

Additional information:

No response

Activity

  1. ngoldbaum commented on Aug 12, 2024

    @ngoldbaum
    Member

    We don't support subinterpreters and currently do not plan to do so. My understanding is that doing so would require a substantial rewrite of significant portions of the low-level C code in NumPy to update our Python extension types from static types to heap types.

    See #665 for the issue we usually cite for this.

    Maybe look at gunicorn as a wsgi alternative that works without subinterpreters?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    32 - InstallationProblems installing or compiling NumPy

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions