Linked Questions

0 votes
1 answer
866 views

parallel for loop to independently modify a dictionary in Python

I am working on a problem which requires me to independently change the value of a dictionary in python. The code is like below g = 1 # a variable for j in lst1: dictionary = fo_1(j) # a ...
Vision's user avatar
  • 568
0 votes
1 answer
641 views

web scraper too slow (what can i do to speed up my scraper?)

here is my code ..it is very slow I am not scraping a lot of data. My file size is 188 KB..i think the problem is i am getting all the internal url links from a website and scraping each one to find ...
Code Ninja's user avatar
0 votes
1 answer
1k views

Assign a thread to each section in an ini file

I am using this toolkit: https://github.com/Fire30/Fifa14Client in python 2.7 from Fifa14Client import LoginManager from Fifa14Client import WebAppFunctioner import ConfigParser from extra import ...
user3785989's user avatar
2 votes
1 answer
573 views

Problems getting QTimer to start when using QThread

I'm trying to implement a webcam using PyQt5 from an example I found (here, but not really relevant). Getting the example to work wasn't an issue, but I wanted to modify some things and I am stuck on ...
Freya W's user avatar
  • 519
2 votes
2 answers
421 views

Getting the count of every word in a file using threads

Im currently trying to use threads to get the count of every word in a file in a parallel manner, but at the current time my code gets slower when i add even just an extra thread. I feel like it ...
Damion Monroe's user avatar
1 vote
1 answer
402 views

Differences between python parallel threads & processes

Based on my current understanding, a process is a collection of instructions along with all the resources it uses while it is running. This includes the code, input/output, resources, memory, file ...
AlanSTACK's user avatar
  • 5,750
1 vote
2 answers
500 views

"bucketsort" with pythons multiprocessing

I have a data series with a uniform distribution. I wish to exploit the distribution to sort the data in parallel. For N CPUs, I essentially define N buckets and sort the buckets in parallel. My ...
user3805817's user avatar
1 vote
1 answer
376 views

Why is my multithreading program only actually using a single thread?

I have realized that my multithreading program isn't doing what I think its doing. The following is a MWE of my strategy. In essence I'm creating nThreads threads but only actually using one of them. ...
CiaranWelsh's user avatar
  • 7,352
0 votes
1 answer
763 views

Python2.7 Only Using 25% of CPU MacBook Pro

I'm running a MacBook Pro: I'm running an installation of python2.7 via Anaconda. Last login: Wed Nov 11 21:41:33 on ttys002 Matthews-MacBook-Pro:~ matthewdunn$ python Python 2.7.10 |Anaconda 2.4.0 (...
mattyd2's user avatar
  • 158
1 vote
1 answer
565 views

Parallelize the export from BigQuery to local JSON file in Python

We have a table in BigQuery that we need to export into a local newline-delimited JSON file. Using BigQuery's export to GCS functionality is problematic as it converts integer types to strings, see ...
Canovice's user avatar
  • 9,662
0 votes
1 answer
539 views

Falcon API CPU intensive tasks

I'm trying to build a REST API using Falcon. I will have a post endpoint where i'll receive a json (sometimes with hundreds of keys) and i will attempt to process this data: sanitize text data ...
Mike's user avatar
  • 486
1 vote
1 answer
324 views

Multi-threading and Single-threading performance issues in CPU-bound task

The two following single-threading and multi-threading scripts are taking the same time when I give as input a big number like 555550000 single thread import threading, time a=[] def print_factors(x)...
Aws Al-Masri's user avatar
0 votes
0 answers
655 views

Python - lock class accessed by multiple threads

I have a little threading / locking dilema. I am trying to achieve something like this: import threading import time class A: def __init__(self): self.lock = threading.Lock() def ...
matousc's user avatar
  • 3,848
0 votes
1 answer
499 views

Python multiprocessing image compression - only one CPU at 100%

I had a python script that would: Loop through rosbags in a given directory Each non image message is directly copied to the new bag and each image message would be compressed and added to the new ...
user3220901's user avatar
0 votes
1 answer
555 views

Why does not multithreading speed up my program?

I have a big text file that needs to be processed. I first read all text into a list and then use ThreadPoolExecutor to start multiple threads to process it. The two functions called in process_text() ...
marlon's user avatar
  • 6,827

15 30 50 per page
1
3 4
5
6 7
10