title: Python multiprocess library: NameError on using imported packages
body: <p>The following code works perfectly:</p>
  
  <pre class="lang-py prettyprint-override"><code>from multiprocessing import Pool
  import time
  
  values = list(range(10))
  
  def print_time_and_value(value):
      print(time.time(), value)
  
  if __name__ == '__main__':
  
      p = Pool(4)
      p.map(print_time_and_value, values)
  </code></pre>
  
  <p>but when I change the "multiprocessing" import to the <a href="https://pypi.org/project/multiprocess/" rel="nofollow noreferrer">"multiprocess"</a> library:</p>
  
  <pre><code>from multiprocess import Pool
  </code></pre>
  
  <p>it raises the following error during execution:</p>
  
  <pre><code>Traceback (most recent call last):
    File "test.py", line 13, in &lt;module&gt;
      p.map(print_time_and_value, values)
    File "C:\Users\User\Anaconda3_64bits\lib\site-packages\multiprocess\pool.py", line 268, in map
      return self._map_async(func, iterable, mapstar, chunksize).get()
    File "C:\Users\User\Anaconda3_64bits\lib\site-packages\multiprocess\pool.py", line 657, in get
      raise self._value
  NameError: name 'time' is not defined
  </code></pre>
  
  <p>I can't use multiprocessing since I have to use unpicklable objects later on my main application, so I have to use multiprocess, which has dill serialization.</p>
  
  <p>I have noticed that putting the "time" import inside the "print_time_and_value" function instead of the global scope solves this issue, but this behavior is a bit weird. As it is a fork of multiprocessing, I had guessed it would work the same way.</p>
  
  <p>I'm using Python 3.7.0, multiprocess module is version 0.70.7; running on 64 bits Anaconda environment, Windows 10.</p>