Skip to content

Commit

Permalink
changing the chunk size
Browse files Browse the repository at this point in the history
- the download speed comes to be in kbs which can be increased by
  increasing the chunk size
  • Loading branch information
manorit2001 committed Feb 28, 2021
1 parent 16954cb commit ec0cf12
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drakrun/drakrun/drakpdb.py
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ def fetch_pdb(pdbname, guidage, destdir='.'):

with tqdm(total=total_size, unit='iB', unit_scale=True) as pbar:
with open(dest, "wb") as f:
for chunk in res.iter_content(chunk_size=1024 * 8):
for chunk in res.iter_content(chunk_size=1024 * 1024 * 8):
if chunk:
f.write(chunk)
pbar.update(len(chunk))
Expand Down

0 comments on commit ec0cf12

Please sign in to comment.