def download_files_in_parallel(urls, cache=False, show_progress=True, timeout=None):
 from .console import ProgressBar
 if (timeout is None):
  timeout = conf.remote_timeout
 if show_progress:
  progress = sys.stdout
 else:
  progress = io.BytesIO()
 if (timeout is None):
  timeout = REMOTE_TIMEOUT()
 combined_urls = list(set(urls))
 combined_paths = ProgressBar.map(_do_download_files_in_parallel, [(x, cache) for x in combined_urls], file=progress, multiprocess=True)
 paths = []
 for url in urls:
  paths.append(combined_paths[combined_urls.index(url)])
 return paths

def download_files_in_parallel ( urls , cache = False , show_progress = True , timeout = None ) : from . console import ProgressBar if ( timeout is None ) : timeout = conf . remote_timeout if show_progress : progress = sys . stdout else : progress = io . BytesIO ( ) if ( timeout is None ) : timeout = REMOTE_TIMEOUT ( ) combined_urls = list ( set ( urls ) ) combined_paths = ProgressBar . map ( _do_download_files_in_parallel , [ ( x , cache ) for x in combined_urls ] , file = progress , multiprocess = True ) paths = [ ] for url in urls : paths . append ( combined_paths [ combined_urls . index ( url ) ] ) return paths
downloads multiple files in parallel from the given urls .