Skip to content
Permalink
Browse files

Don't pass multiprocess object on pickle (#261)

  • Loading branch information...
lbfs authored and iperov committed May 14, 2019
1 parent d6e8dde commit ba4e377d13722ed250cfb3e4e71b25647d5a186a
Showing with 5 additions and 0 deletions.
  1. +5 −0 utils/iter_utils.py
@@ -48,6 +48,11 @@ def process_func(self, user_param):
def __iter__(self):
return self

def __getstate__(self):
self_dict = self.__dict__.copy()
del self_dict['p']
return self_dict

def __next__(self):
if self.p == None:
user_param = self.user_param

0 comments on commit ba4e377

Please sign in to comment.
You can’t perform that action at this time.