I wonder if it's possible to spawn the multiple processes using subprocess module to run a function or a method defined in a same script (without a need to import it). So the main script is not waiting for execution to be completed. Like so (the code is wrong but it illustrate the concept):
def printMe(arg):
print arg
myList=['One','Two','Three','Four','Five']
for word in myList:
printMe(word)
proc = subprocess.Popen(printMe(word), stdout=subprocess.PIPE, stderr=subprocess.PIPE)
EDITED:
Thanks for the comments! Apparently multiprocessing module needs to be used when there is a need to spawn an internal method or function. It appears the multiprocessing module method pool.map() behaves quite differently from a "standard" function when it is used to send an argument variable to a called by it function.
Example
import os, sys
from multiprocessing import Pool
def printMe(arg):
arg+="_Completed"
return arg
myList=['One','Two','Three']
pool = Pool(processes=10)
results = pool.map(printMe, myList)
print results, type(results), len(results)
# Results to ['One_Completed', 'Two_Completed', 'Three_Completed'] <type 'list'> 3
SingleWord="Once_Upon_A_Time"
pool = Pool(processes=10)
results = pool.map(printMe, SingleWord)
# Results to: ['O_Completed', 'n_Completed', 'c_Completed', 'e_Completed', `'__Completed', 'U_Completed', 'p_Completed', 'o_Completed', 'n_Completed', '__Completed', 'A_Completed', '__Completed', 'T_Completed', 'i_Completed', 'm_Completed', 'e_Completed'] <type 'list'> 16`