Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

issue with running code on colab #32

Open
sparshgarg23 opened this issue Dec 8, 2023 · 0 comments
Open

issue with running code on colab #32

sparshgarg23 opened this issue Dec 8, 2023 · 0 comments

Comments

@sparshgarg23
Copy link

While executing the code on colab,i came across the following errors
1.Installing the requirements mentioned causes pip to break giving the error

[Error pip install with exit code: 1 (subprocess-exited-with-error)](https://stackoverflow.com/questions/76139548/error-pip-install-with-exit-code-1-subprocess-exited-with-error)

The error is resolved when updated versions of mmcv,mmsegmentation and tokenizers is used.As such if I use the recent versions of mmcv,mmsegmentation and tokenizer,will it cause problems later on.

Secondly,when executing the make file mentioned in refer subdirectory,the following error is encountered.

!python setup.py build_ext --inplace
!rm -rf build
error when running the above command or make file

Compiling external/_mask.pyx because it changed.
[1/1] Cythonizing external/_mask.pyx
/usr/local/lib/python3.10/dist-packages/Cython/Compiler/Main.py:381: FutureWarning: Cython directive 'language_level' not set, using '3str' for now (Py3). This has changed from earlier releases! File: /content/LAVT-RIS/refer/external/_mask.pyx
  tree = Parsing.p_module(s, pxd, full_module_name)

Error compiling Cython file:
------------------------------------------------------------
...
    cdef np.ndarray[np.double_t, ndim=1] np_poly
    n = len(poly)
    Rs = RLEs(n)
    for i, p in enumerate(poly):
        np_poly = np.array(p, dtype=np.double, order='F')
        rleFrPoly( <RLE*>&Rs._R[i], <const double*> np_poly.data, len(np_poly)/2, h, w )
                                                                              ^
------------------------------------------------------------

external/_mask.pyx:258:78: Cannot assign type 'double' to 'siz'
Traceback (most recent call last):
  File "/content/LAVT-RIS/refer/setup.py", line 20, in <module>
    ext_modules=cythonize(ext_modules)
  File "/usr/local/lib/python3.10/dist-packages/Cython/Build/Dependencies.py", line 1154, in cythonize
    cythonize_one(*args)
  File "/usr/local/lib/python3.10/dist-packages/Cython/Build/Dependencies.py", line 1321, in cythonize_one
    raise CompileError(None, pyx_file)
Cython.Compiler.Errors.CompileError: external/_mask.pyx

Any reason why this is occuring

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant