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

Kernel keeps dying on jupyter notebook #89

Open
Hanychei opened this issue Sep 5, 2022 · 15 comments
Open

Kernel keeps dying on jupyter notebook #89

Hanychei opened this issue Sep 5, 2022 · 15 comments

Comments

@Hanychei
Copy link

Hanychei commented Sep 5, 2022

Hello all,
Am trying to accelerate yolov4 on pynq z1 board everything is working fine but am stuck at the end of the tutorial on jupyter at this particular line

outputs = tcu.run(inputs)

Thank you

@arif-pens77
Copy link

I got the same problem but at a little bit further line.
interpreter.invoke()

@LotfiT
Copy link

LotfiT commented Sep 27, 2022

@Hanychei I encountered this issue before, it was a memory problem on jupyter notebook, try to connect your board through ssh (PuTTY for example)

@LotfiT
Copy link

LotfiT commented Sep 27, 2022

I got the same problem but at a little bit further line. interpreter.invoke()

@arif-pens77 which version of tflite runtime are you using?

@arif-pens77
Copy link

tflite-runtime 2.10.0 on PYNQ 2.7 (Pynq-Z1 board)

I got the same problem but at a little bit further line. interpreter.invoke()

@arif-pens77 which version of tflite runtime are you using?

tflite-runtime 2.10.0 on PYNQ 2.7 (Pynq-Z1 board)

@LotfiT
Copy link

LotfiT commented Sep 28, 2022

I used tflite_runtime-2.11.0-cp37-cp37m-linux_armv7l I think you need to downgrade python to 3.7

@arif-pens77
Copy link

I used tflite_runtime-2.11.0-cp37-cp37m-linux_armv7l I think you need to downgrade python to 3.7

Are you also using Pynq-Z1 board with PYNQ 2.7? I think that python 3.8 is the default version for PYNQ 2.7

@LotfiT
Copy link

LotfiT commented Sep 28, 2022

Yes I am using the same board and 2.7.
Yes, but with python 3.8 you will get "Illegal instruction (core dumped) ' error

@arif-pens77
Copy link

Yes I am using the same board and 2.7. Yes, but with python 3.8 you will get "Illegal instruction (core dumped) ' error

I try to downgrade the python version to 3.7 using this method:
sudo add-apt-repository ppa:deadsnakes/ppa
sudo apt-get update
sudo apt install python3.7

But, its not working on the first step "sudo add-apt-repository ppa:deadsnakes/ppa
" Traceback (most recent call last):
File "/usr/bin/add-apt-repository", line 107, in
sp = SoftwareProperties(options=options)
File "/usr/lib/python3/dist-packages/softwareproperties/SoftwareProperties.py", line 118, in init
self.reload_sourceslist()
File "/usr/lib/python3/dist-packages/softwareproperties/SoftwareProperties.py", line 613, in reload_sourceslist
self.distro.get_sources(self.sourceslist)
File "/usr/lib/python3/dist-packages/aptsources/distro.py", line 91, in get_sources
raise NoDistroTemplateException(
aptsources.distro.NoDistroTemplateException: Error: could not find a distribution template for Pynqlinux/Austin"

Do you have any suggestion?

@LotfiT
Copy link

LotfiT commented Sep 28, 2022

Try this

wget https://www.python.org/ftp/python/3.7.5/Python-3.7.5.tgz

tar -xf Python-3.7.5.tgz

go to Python-3.7.5 directory

./configure --enable-optimizations

then sudo make altinstall to install a second instance and finally sudo make install

Hope this will help

@arif-pens77
Copy link

linux_armv7l

Unfortunately, It is not working.
at the end, I got this report ...

Requirement already up-to-date: setuptools in /usr/local/lib/python3.7/site-packages (41.2.0)
Requirement already up-to-date: pip in /usr/local/lib/python3.7/site-packages (19.2.3)
make: 'python' is up to date.
make: *** No rule to make target '3.7'. Stop.

And the python version is still 3.8

@LotfiT
Copy link

LotfiT commented Sep 29, 2022

Have you tried python3.7 --version ?

@arif-pens77
Copy link

Have you tried python3.7 --version ?

Yes, but It's only working on local folder. and its not linked to the existing Jupyter.

@tdb-alcorn
Copy link
Contributor

Can you share logs or a stack trace of what you're seeing in the jupyter logs?

@arif-pens77
Copy link

I successfully install Python 3.7 in new virtual environment by following the instruction here
: https://discuss.pynq.io/t/testing-pytorch-1-8-in-zybo-z7-running-pynq-2-7/4181

However, i still have problem when running "interpreter.invoke()"

Could you share your tflite_runtime whl file?

@arif-pens77
Copy link

I used tflite_runtime-2.11.0-cp37-cp37m-linux_armv7l I think you need to downgrade python to 3.7

Could you share your tflite_runtime-2.11.0-cp37-cp37m-linux_armv7l.whl file?

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

No branches or pull requests

4 participants