hydrusvideodeduplicator / hydrus-video-deduplicator

Video Deduplicator for the Hydrus Network
https://hydrusvideodeduplicator.github.io/hydrus-video-deduplicator/
MIT License
41 stars 7 forks source link

unexpected keyword argument 'return_as' #32

Closed b1n4ryj4n closed 1 year ago

b1n4ryj4n commented 1 year ago

I recently get always this error: TypeError: Parallel.init() got an unexpected keyword argument 'return_as'

│ deduplicate                                                                                      │
│                                                                                                  │
│   116 │   │   │   print("[yellow] Skipping perceptual hashing")                                  │
│   117 │   │   else:                                                                              │
│   118 │   │   │   video_hashes = list(self.retrieve_video_hashes(search_tags))                   │
│ ❱ 119 │   │   │   self.add_perceptual_hashes_to_db(overwrite=overwrite, video_hashes=video_has   │
│   120 │   │                                                                                      │
│   121 │   │   self._find_potential_duplicates()

/home/b1n4ry/.local/lib/python3.10/site-packages/hydrusvideodeduplicator/dedup.py:209 in         │
│ add_perceptual_hashes_to_db                                                                      │
│                                                                                                  │
│   206 │   │   │   │                                                                              │
│   207 │   │   │   │   with tqdm(total=len(new_video_hashes), dynamic_ncols=True, unit="video",   │
│   208 │   │   │   │   │   # Change to return_as='unordered_generator' when joblib supports it!   │
│ ❱ 209 │   │   │   │   │   with Parallel(n_jobs=self.job_count, return_as='generator') as paral   │
│   210 │   │   │   │   │   │   result_generator = parallel(                                       │
│   211 │   │   │   │   │   │   │   delayed(self.fetch_and_hash_file)(video_hash) for video_hash   │
│   212 │   │   │   │   │   │   )
b1n4ryj4n commented 1 year ago

ah found the problem i needed to upgrade the joblib package