python - reading large pandas datastructure via multiprocessing Process -


i trying read in large file pandas datastructure process using multiprocessing module. in code have attached below, done read_file function because "2" gets printed out. python command window gets stuck @ p1.join() "3" never gets printed.

i read multiprocessing process has size limit it, if reason file isn't getting thru, can suggest alternative reading large panda structure separate process?

in end, hope read 2 large panda structures simultaneously , concatenate them in main function halve script time.

import pandas pd multiprocessing import process, queue  def read_file(numbers,retrns):     product_master_xlsx = pd.read_excel(r'g:\product master.xlsx',sheetname='table')     retrns.put(product_master_xlsx)     print "2"  if __name__ == "__main__":     arr = [1]     queue1 = queue()     p1 = process(target=read_file, args=(arr,queue1))     p1.start()     print "1"     p1.join()     print "3"     print queue1.get() 


Comments

Popular posts from this blog

angular - Ionic slides - dynamically add slides before and after -

minify - Minimizing css files -

Add a dynamic header in angular 2 http provider -