LeiWang1999 commented on PR #18124:
URL: https://github.com/apache/tvm/pull/18124#issuecomment-3051228600

   @vacu9708 My experience differs from yours. I tried uninstalling all Cython 
installations from my system, and when I run `mkdir build; cmake ..; make -j` 
directly, I encounter:
   
   ```
   [100%] Linking CXX shared library libtvm.so
   [100%] Built target tvm
   WARNING:root:git describe: fatal: No names found, cannot describe anything.
   , use 0.21.dev0
   Traceback (most recent call last):
     File 
"/weka-hg/prod/deepseek/permanent/wanglei/pr_workspace/rebase_upstream/3rdparty/tvm/python/setup.py",
 line 146, in config_cython
       from Cython.Build import cythonize
   ModuleNotFoundError: No module named 'Cython'
   
   During handling of the above exception, another exception occurred:
   
   Traceback (most recent call last):
     File 
"/weka-hg/prod/deepseek/permanent/wanglei/pr_workspace/rebase_upstream/3rdparty/tvm/python/setup.py",
 line 266, in <module>
       ext_modules=config_cython(),
     File 
"/weka-hg/prod/deepseek/permanent/wanglei/pr_workspace/rebase_upstream/3rdparty/tvm/python/setup.py",
 line 195, in config_cython
       raise RuntimeError("Cython is not installed, please pip install cython")
   RuntimeError: Cython is not installed, please pip install cython
   make[2]: *** [CMakeFiles/tvm_cython.dir/build.make:70: 
CMakeFiles/tvm_cython] Error 1
   make[1]: *** [CMakeFiles/Makefile2:1291: CMakeFiles/tvm_cython.dir/all] 
Error 2
   make: *** [Makefile:146: all] Error 2
   ```
   
   but works after I reinstalled cython via pip
   ```python
   [lei_py39] (lei) 
wanglei@wanglei-3969141-0:/weka-hg/prod/deepseek/permanent/wanglei/pr_workspace/rebase_upstream/3rdparty/tvm/build$
 pip install cython
   Looking in indexes: http://mirrors.aliyun.com/pypi/simple/
   Collecting cython
     Downloading 
http://mirrors.aliyun.com/pypi/packages/18/90/7dc13bd8621b25caa57d6047938ac5e324c763828fccfe956c2a38b22f90/cython-3.1.2-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
 (3.3 MB)
        ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 3.3/3.3 MB 20.8 MB/s eta 
0:00:00
   Installing collected packages: cython
   Successfully installed cython-3.1.2
   
   [lei_py39] (lei) 
wanglei@wanglei-3969141-0:/weka-hg/prod/deepseek/permanent/wanglei/pr_workspace/rebase_upstream/3rdparty/tvm/build$
 make -j
   [  2%] Built target project_libbacktrace
   [  2%] Built target tvm_libinfo_objs
   [  3%] Built target tvm_ffi_objs
   [ 12%] Built target tvm_runtime_objs
   [ 13%] Built target tvm_ffi_static
   [ 13%] Built target tvm_ffi_shared
   [ 13%] Built target tvm_runtime
   [100%] Built target tvm_objs
   [100%] Built target tvm
   WARNING:root:git describe: fatal: No names found, cannot describe anything.
   , use 0.21.dev0
   Compiling tvm/ffi/cython/core.pyx because it changed.
   [1/1] Cythonizing tvm/ffi/cython/core.pyx
   INFO:root:running build_ext
   INFO:root:building 'tvm.ffi.core' extension
   INFO:root:g++ -pthread -B 
/hf_shared/hfai_envs/wanglei/lei_py39_0/compiler_compat -Wno-unused-result 
-Wsign-compare -DNDEBUG -O2 -Wall -fPIC -O2 -isystem 
/hf_shared/hfai_envs/wanglei/lei_py39_0/include 
-I/hf_shared/hfai_envs/wanglei/lei_py39_0/include -fPIC -O2 -isystem 
/hf_shared/hfai_envs/wanglei/lei_py39_0/include -fPIC -I../ffi/include/ 
-I../ffi/3rdparty/dlpack/include 
-I/hf_shared/hfai_envs/wanglei/lei_py39_0/include/python3.9 -c 
tvm/ffi/cython/core.cpp -o 
build/temp.linux-x86_64-cpython-39/tvm/ffi/cython/core.o -std=c++17 
-DDMLC_USE_LOGGING_LIBRARY=<tvm/runtime/logging.h>
   INFO:root:g++ -pthread -B 
/hf_shared/hfai_envs/wanglei/lei_py39_0/compiler_compat -Wno-unused-result 
-Wsign-compare -DNDEBUG -O2 -Wall -fPIC -O2 -isystem 
/hf_shared/hfai_envs/wanglei/lei_py39_0/include 
-I/hf_shared/hfai_envs/wanglei/lei_py39_0/include -fPIC -O2 -isystem 
/hf_shared/hfai_envs/wanglei/lei_py39_0/include -pthread -B 
/hf_shared/hfai_envs/wanglei/lei_py39_0/compiler_compat -shared 
build/temp.linux-x86_64-cpython-39/tvm/ffi/cython/core.o -o 
build/lib.linux-x86_64-cpython-39/tvm/ffi/core.cpython-39-x86_64-linux-gnu.so
   INFO:root:copying 
build/lib.linux-x86_64-cpython-39/tvm/ffi/core.cpython-39-x86_64-linux-gnu.so 
-> tvm/ffi
   [100%] Built target tvm_cython
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to