Skip to content

python setup.py build_ext --inplace #1219

Closed

Description

@leeshinbi

Compiling darkflow/cython_utils/nms.pyx because it changed.
Compiling darkflow/cython_utils/cy_yolo2_findboxes.pyx because it changed.
Compiling darkflow/cython_utils/cy_yolo_findboxes.pyx because it changed.
[1/3] Cythonizing darkflow/cython_utils/cy_yolo2_findboxes.pyx
C:\Users\82103.conda\envs\DarkflowTest\lib\site-packages\Cython\Compiler\Main.py:384: FutureWarning: Cython directive 'language_level' not set, using '3str' for now (Py3). This has changed from earlier releases! File: C:\Users\82103.conda\envs\DarkflowTest\darkflow\darkflow\cython_utils\cy_yolo2_findboxes.pyx
tree = Parsing.p_module(s, pxd, full_module_name)

Error compiling Cython file:

...
cimport numpy as np
cimport cython
ctypedef np.float_t DTYPE_t
from libc.math cimport exp
from ..utils.box import BoundBox
from nms cimport NMS
^

darkflow\cython_utils\cy_yolo2_findboxes.pyx:7:0: 'nms.pxd' not found

Error compiling Cython file:

...
cimport numpy as np
cimport cython
ctypedef np.float_t DTYPE_t
from libc.math cimport exp
from ..utils.box import BoundBox
from nms cimport NMS
^

darkflow\cython_utils\cy_yolo2_findboxes.pyx:7:0: 'nms\NMS.pxd' not found

Error compiling Cython file:

...
if(tempc > threshold):
probs[row, col, box_loop, class_loop] = tempc

#NMS
return NMS(np.ascontiguousarray(probs).reshape(H*W*B,C), np.ascontiguousarray(Bbox_pred).reshape(H*B*W,5))
       ^

darkflow\cython_utils\cy_yolo2_findboxes.pyx:97:11: 'NMS' is not a constant, variable or function identifier
Traceback (most recent call last):
File "setup.py", line 73, in
ext_modules = cythonize(ext_modules)
File "C:\Users\82103.conda\envs\DarkflowTest\lib\site-packages\Cython\Build\Dependencies.py", line 1134, in cythonize
cythonize_one(*args)
File "C:\Users\82103.conda\envs\DarkflowTest\lib\site-packages\Cython\Build\Dependencies.py", line 1301, in cythonize_one
raise CompileError(None, pyx_file)
Cython.Compiler.Errors.CompileError: darkflow/cython_utils/cy_yolo2_findboxes.pyx

Activity

  1. ferozkhanabbasi commented on Oct 17, 2023

    @ferozkhanabbasi

    Same issue

  2. akbaig commented on Oct 23, 2023

    @akbaig

    Please refer to #1221

  3. prsntmaurya commented on Jan 17, 2024

    @prsntmaurya

    Copying the files "nms.pxd" & "nms.pyx" to directory where setup.py is located, worked for me on python 3.6

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

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions