beruic
Posts: 28
Joined: Sun Jan 29, 2012 1:37 pm

Re: Python is barely usable on Raspbian

Fri Jan 15, 2016 2:10 pm

My results are:

Raspberry Pi B+

Code: Select all

$ time pip -h
[...truncated...]
real	0m4.635s
user	0m4.200s
sys	0m0.390s

$ time pip3 -h
[...truncated...]
real	0m7.200s
user	0m6.860s
sys	0m0.290s

Shuttle SP35P2 Pro (Core2 duo E6320, 6GB RAM, SSD)

Code: Select all

$ time pip -h
[...truncated...]
real	0m0.383s
user	0m0.296s
sys	0m0.060s

$ time pip3 -h
[...truncated...]
real	0m0.981s
user	0m0.900s
sys	0m0.048s
I ran each a few times to make sure caching was not a problem.

Navyscourge
Posts: 258
Joined: Sat Oct 24, 2015 1:50 pm

Re: Python is barely usable on Raspbian

Fri Jan 15, 2016 2:35 pm

You have a Pi B+. The Pi 2 has more memory and a quad core processor. If you want decent performance you should get a Pi 2; browsing and LibreOffice use are acceptable on the Pi 2, but not so much on the Pi B+. I don't know about Python programs.

beruic
Posts: 28
Joined: Sun Jan 29, 2012 1:37 pm

Re: Python is barely usable on Raspbian

Fri Jan 15, 2016 5:07 pm

Navyscourge wrote:You have a Pi B+. The Pi 2 has more memory and a quad core processor. If you want decent performance you should get a Pi 2; browsing and LibreOffice use are acceptable on the Pi 2, but not so much on the Pi B+. I don't know about Python programs.
I'm trying to hunt a bug here, and I'm not gonne buy a Pi2 just for that. The B+ is fine for my hobby needs. Therefore I would like to get som results from one that has a Pi2.

I should also mention btw that I run Jessi Lite on mine, so preferably I would like results from Jessie on a Pi2. I'll communicate them on to the bug report I made, if they show to be useful.

Navyscourge
Posts: 258
Joined: Sat Oct 24, 2015 1:50 pm

Re: Python is barely usable on Raspbian

Fri Jan 15, 2016 8:28 pm

so, on a Pi2, with full Jessie, repeated 5 times...

Code: Select all

$ time pip -h
[...truncated...]
real   0m2.308s  0m1.677s  0m1.673s  0m1.667s  0m1.664s
user   0m1.600s  0m1.440s  0m1.440s  0m1.440s  0m1.480s
sys    0m0.190s  0m0.210s  0m0.220s  0m0.210s  0m0.170s

$ time pip3 -h
[...truncated...]
real   0m2.937s  0m2.374s  0m2.384s  0m2.389s  0m2.362s
user   0m2.240s  0m2.260s  0m2.230s  0m2.290s  0m2.190s
sys    0m0.250s  0m0.110s  0m0.150s  0m0.090s  0m0.160s
Does this help?

The first run was without top running, if that makes a difference. Run as 2 SSH sessions to the Pi

beruic
Posts: 28
Joined: Sun Jan 29, 2012 1:37 pm

Re: Python is barely usable on Raspbian

Sat Jan 16, 2016 12:02 am

Great!
The first run is always expected to be a bit slower (because things get cached here) , but I'm unsure if top makes any difference.
Does it make any significant difference with only one ssh session and no top?

jahboater
Posts: 4939
Joined: Wed Feb 04, 2015 6:38 pm

Re: Python is barely usable on Raspbian

Sat Jan 16, 2016 12:22 am

if you have Python 3, and post the times from both machines?
Real times
4GHz Core i7-3770k 16GB SSD Intel PC
pip -h 0.182
pip3 -h 0.301

Pi2 (Jessie Lite)
pip -h 1.225
pip3 -h 1.791
Does it make any significant difference with only one ssh session and no top?
Adding another ssh session with top running made no real difference to the pip times - as expected with a quad core Pi2. Its probably network limited.
"We are in the beginning of a mass extinction, and all you can talk
about is money and fairy tales of eternal economic growth."
- Greta Thunberg

beruic
Posts: 28
Joined: Sun Jan 29, 2012 1:37 pm

Re: Python is barely usable on Raspbian

Sat Jan 16, 2016 9:12 pm

jahboater wrote:...Its probably network limited.
I agree. I've suspected for some time that network activity happens always, even though there is no need.

Return to “Troubleshooting”