How to save an image locally using Python in which we already know the URL address

0 votes

Can anyone explain how to save an image locally using Python in which we already know the URL address?

Jun 26, 2020 in Python by Roshni
• 10,480 points
1,903 views

1 answer to this question.

0 votes

Hi, @Roshni,

The following code is used to save the image locally from the URL address which you know.:

import urllib.request

urllib.request.urlretrieve("URL", "local-filename.jpg")
answered Jun 26, 2020 by Gitika
• 65,770 points

Related Questions In Python

0 votes
1 answer

How to output the rows which are affected using SQLAlchemy in Python?

Hi, good question. This is actually not ...READ MORE

answered Feb 15, 2019 in Python by Nymeria
• 3,560 points
3,381 views
+2 votes
3 answers

How can I play an audio file in the background using Python?

down voteacceptedFor windows: you could use  winsound.SND_ASYNC to play them ...READ MORE

answered Apr 4, 2018 in Python by charlie_brown
• 7,720 points
13,544 views
0 votes
1 answer
0 votes
2 answers
+1 vote
2 answers

how can i count the items in a list?

Syntax :            list. count(value) Code: colors = ['red', 'green', ...READ MORE

answered Jul 7, 2019 in Python by Neha
• 330 points

edited Jul 8, 2019 by Kalgi 4,434 views
0 votes
1 answer
+5 votes
6 answers

Lowercase in Python

You can simply the built-in function in ...READ MORE

answered Apr 11, 2018 in Python by hemant
• 5,790 points
4,070 views
0 votes
1 answer

I want to download a file from the website by web scraping. Can anyone explain how to do this in jupyter lab (python) with an example?

Hey, Web scraping is a technique to automatically ...READ MORE

answered Apr 7, 2020 in Python by Gitika
• 65,770 points
2,388 views
+1 vote
1 answer

Want to know how to write paragraph on image using pillow python?

Hi, @Shantanu, You can make use of the ...READ MORE

answered Apr 14, 2020 in Python by Gitika
• 65,770 points
2,303 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP