-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hi, I have a script (from somebody else) to download the image of the day from the NASA. I have modified the script quite a bit to download a range of days, even years of them. One key function is failing on today's picture. This is the relevant section of the script: +++...................... function get_page { echo "Downloading page to find image" #wget http://apod.nasa.gov/apod/ --quiet -O /tmp/apod.html wget https://apod.nasa.gov/apod/ap${SHORT_TODAY}.html --quiet -O /tmp/apod.html grep -m 1 jpg /tmp/apod.html | sed -e 's/<//' -e 's/>//' -e 's/.*=//' -e 's/"//g' -e 's/^/http:\/\/apod.nasa.gov\/apod\//' > /tmp/pic_url } get_page # Got the link to the image PICURL=`/bin/cat /tmp/pic_url` if [ -z $PICURL ]; then echo "Not found picture.jpg for $TODAY. Trying .png" try_png PICURL=`/bin/cat /tmp/pic_url` if [ -z $PICURL ]; then echo "Not found picture.png for $TODAY. html file saved" cp /tmp/apod.html $PICTURES_DIR/$TODAY.html return fi fi NAME=`basename $PICURL` PICTURE_NAME=${TODAY}_${NAME} ......................++- The script sets up variable SHORT_TODAY to 230427, so "get_page" downloads <https://apod.nasa.gov/apod/ap230426.html>. It is coughing up this error: Do 20230427 Downloading page to find image /home/cer/bin/NASA Picture-Of-The-Day Wallpaper Script, mine, loop: line 98: [: too many arguments basename: extra operand ‘Tarantula</a>’ Try 'basename --help' for more information. The problem is here: cer@Isengard:~> grep -m 1 jpg /tmp/apod.html | sed -e 's/<//' -e 's/>//' -e 's/.*=//' -e 's/"//g' -e 's/^/http:\/\/apod.nasa.gov\/apod\//' http://apod.nasa.gov/apod/image/1602/Tarantula-HST-ESO-annotated1800.jpgArou... the Tarantula</a> cer@Isengard:~> The source html goes like this: <a href="image/1602/Tarantula-HST-ESO-annotated1800.jpg">Around the Tarantula</a> are other star forming regions with young star clusters, filaments, and blown-out <a href="ap080327.html">bubble-shaped</a> clouds. On the day before, it goes like this (here the script works as expected): 2023 April 26 <br> <a href="image/2304/MoonArc_zanarello_1365.jpg"> <IMG SRC="image/2304/MoonArc_zanarello_960.jpg" alt="A nearly full Moon is seen through the famous Arc de Triomphi with trees and cars lining the foreground. Please see the explanation for more detailed information." style="max-width:100%"></a> </center> where the function generates this text: cer@Isengard:~> echo '<a href="image/2304/MoonArc_zanarello_1365.jpg">' | grep -m 1 jpg | sed -e 's/<//' -e 's/>//' -e 's/.*=//' -e 's/"//g' -e 's/^/http:\/\/apod.nasa.gov\/apod\//' http://apod.nasa.gov/apod/image/2304/MoonArc_zanarello_1365.jpg cer@Isengard:~> My problem is, I don't talk sed O:-) So, I ask here if someone knows how to change that sed command so that it works ;-) (the full script I modified is: https://paste.opensuse.org/7f484bb7c807) - -- Cheers Carlos E. R. (from 15.4 x86_64 at Telcontar) -----BEGIN PGP SIGNATURE----- iHoEARECADoWIQQZEb51mJKK1KpcU/W1MxgcbY1H1QUCZErjCRwccm9iaW4ubGlz dGFzQHRlbGVmb25pY2EubmV0AAoJELUzGBxtjUfV7RYAnR1jKw8AXonj2E837r7L cY3g08VvAJ418VFrG/lGU3gad7PPUwFceZIfIg== =KHba -----END PGP SIGNATURE-----
Hi, On 27/04/2023 22:03, Carlos E. R. wrote:
Hi,
....
The problem is here:
cer@Isengard:~> grep -m 1 jpg /tmp/apod.html | sed -e 's/<//' -e 's/>//' -e 's/.*=//' -e 's/"//g' -e 's/^/http:\/\/apod.nasa.gov\/apod\//'
The problem is above is a combination of two things -- it's grabbing the first line from the HTML file that contains "jpg", but the sed code doesn't account for the chance that the label text could be on the same line. If you replace the sed command with: sed -e 's/.*="//' -e 's/">.*//' -e 's/^/http:\/\/apod.nasa.gov\/apod\//' That will work in both cases. The first bit (the first value for the "-e" parameter) s/.*="// gets rid of everything on the line up to and including the first occurance of the characters =" (in the href or SRC attribute, depending on whether the <IMG> or the <a> tag comes first). The second bit s/">.*// gets rid of everything after the first occurance of "> in the remaining bit of the string. The last bit adds the http://.../ stuff to the beginning of the URL. Brendan
-- Cheers
Carlos E. R. (from 15.4 x86_64 at Telcontar)
On 2023-04-27 23:46, Brendan McKenna wrote:
Hi,
On 27/04/2023 22:03, Carlos E. R. wrote:
Hi,
....
The problem is here:
cer@Isengard:~> grep -m 1 jpg /tmp/apod.html | sed -e 's/<//' -e 's/>//' -e 's/.*=//' -e 's/"//g' -e 's/^/http:\/\/apod.nasa.gov\/apod\//'
The problem is above is a combination of two things -- it's grabbing the first line from the HTML file that contains "jpg", but the sed code doesn't account for the chance that the label text could be on the same line.
Right.
If you replace the sed command with:
sed -e 's/.*="//' -e 's/">.*//' -e 's/^/http:\/\/apod.nasa.gov\/apod\//'
That will work in both cases. The first bit (the first value for the "-e" parameter) s/.*="// gets rid of everything on the line up to and including the first occurance of the characters =" (in the href or SRC attribute, depending on whether the <IMG> or the <a> tag comes first). The second bit s/">.*// gets rid of everything after the first occurance of "> in the remaining bit of the string. The last bit adds the http://.../ stuff to the beginning of the URL.
Thanks :-) -- Cheers / Saludos, Carlos E. R. (from 15.4 x86_64 at Telcontar)
On Thu, 27 Apr 2023 23:03:05 +0200 (CEST), "Carlos E. R." <robin.listas@telefonica.net> wrote:
I have a script (from somebody else) to download the image of the day from the NASA. I have modified the script quite a bit to download a range of days, even years of them.
One key function is failing on today's picture. This is the relevant section of the script:
+++...................... function get_page { echo "Downloading page to find image" #wget http://apod.nasa.gov/apod/ --quiet -O /tmp/apod.html wget https://apod.nasa.gov/apod/ap${SHORT_TODAY}.html --quiet -O /tmp/apod.html
grep -m 1 jpg /tmp/apod.html | sed -e 's/<//' -e 's/>//' -e 's/.*=//' -e 's/"//g' -e 's/^/http:\/\/apod.nasa.gov\/apod\//' > /tmp/pic_url }
get_page
# Got the link to the image PICURL=`/bin/cat /tmp/pic_url` if [ -z $PICURL ]; then echo "Not found picture.jpg for $TODAY. Trying .png" try_png PICURL=`/bin/cat /tmp/pic_url` if [ -z $PICURL ]; then echo "Not found picture.png for $TODAY. html file saved" cp /tmp/apod.html $PICTURES_DIR/$TODAY.html return fi fi
NAME=`basename $PICURL` PICTURE_NAME=${TODAY}_${NAME} ......................++-
The script sets up variable SHORT_TODAY to 230427, so "get_page" downloads <https://apod.nasa.gov/apod/ap230426.html>. It is coughing up this error:
You mean "<https://apod.nasa.gov/apod/ap230427.html>". ap230426.html is "the day before" you mention later below.
Do 20230427 Downloading page to find image /home/cer/bin/NASA Picture-Of-The-Day Wallpaper Script, mine, loop: line 98: [: too many arguments basename: extra operand ‘Tarantula</a>’ Try 'basename --help' for more information.
The problem is here:
cer@Isengard:~> grep -m 1 jpg /tmp/apod.html | sed -e 's/<//' -e 's/>//' -e 's/.*=//' -e 's/"//g' -e 's/^/http:\/\/apod.nasa.gov\/apod\//' http://apod.nasa.gov/apod/image/1602/Tarantula-HST-ESO-annotated1800.jpgArou... the Tarantula</a> cer@Isengard:~>
The source html goes like this:
<a href="image/1602/Tarantula-HST-ESO-annotated1800.jpg">Around the Tarantula</a> are other star forming regions with young star clusters, filaments, and blown-out <a href="ap080327.html">bubble-shaped</a> clouds.
As Brendan pointed out, one of the problems is that the grep command gets the first line that contains "jpg". That isn't even the line with the picture-of-the-day link, on this ap230427.html page, because the A.P.O.D. is a PNG instead. It is from the description. The correct link is from here: 2023 April 27 <br> <a href="image/2304/SuperBIT_tarantula.png"> <IMG SRC="image/2304/SuperBIT_tarantula_1024.png" alt="See Explanation. Clicking on the picture will download the highest resolution version available." style="max-width:100%"></a> You need to grab not just a link *to* an image, but one that *is* an inline image also. The file suffix doesn't matter. So, the following can replace the grep and sed line, and the PICURL code. -------------------- # Given an A.P.O.D. HTML page, this skips the lines down through the # page title heading. Then it extracts the HREF contents of the first # link that contains an IMG tag. # Requires GNU sed for the 'I' flag (ignore regex case) which is used. # Line-by-line description of ${HREF_EXTRACT_SCRIPT}: # # On each line, remove leading space. # Skip lines through the A.P.O.D. heading. # Skip blank lines. # If IMG tag, goto :img # Save this line to the Hold Space. # Next input line. (and go to the beginning of the script) # :img # Get (the previous line) from the Hold Space. # If not an 'A' tag with HREF, next input line. # Extract the HREF contents. # Print it. # Quit after the first print. HREF_EXTRACT_SCRIPT=' s/^ *// 1,/^<h1> *Astronomy Picture of the Day/Id /^$/d /^<img *src="/Ib img x b :img x /^<a href="\([^<>"]\+\)">.*$/I!b s//\1/ p q ' [...] wget -O /tmp/apod.html ... PIC_HREF="$(sed -n -e "$HREF_EXTRACT_SCRIPT" /tmp/apod.html)" if [ -z "$PIC_HREF" ] ;then printf '%s' "Not found picture.xxx for $TODAY... " cp -T /tmp/apod.html $PICTURES_DIR/$TODAY.html \ && echo " html file saved" return 1 else PICURL="http://apod.nasa.gov/apod/${PIC_HREF}" # printf '%s\n' "$PICURL" > /tmp/pic_url fi NAME="$(basename "$PIC_HREF")" [...] --------------------
On the day before, it goes like this (here the script works as expected):
2023 April 26 <br> <a href="image/2304/MoonArc_zanarello_1365.jpg"> <IMG SRC="image/2304/MoonArc_zanarello_960.jpg" alt="A nearly full Moon is seen through the famous Arc de Triomphi with trees and cars lining the foreground. Please see the explanation for more detailed information." style="max-width:100%"></a> </center>
where the function generates this text:
cer@Isengard:~> echo '<a href="image/2304/MoonArc_zanarello_1365.jpg">' | grep -m 1 jpg | sed -e 's/<//' -e 's/>//' -e 's/.*=//' -e 's/"//g' -e 's/^/http:\/\/apod.nasa.gov\/apod\//' http://apod.nasa.gov/apod/image/2304/MoonArc_zanarello_1365.jpg cer@Isengard:~>
My problem is, I don't talk sed O:-) So, I ask here if someone knows how to change that sed command so that it works ;-) (the full script I modified is: https://paste.opensuse.org/7f484bb7c807)
-- Robert Webb
Robert Webb via openSUSE Users wrote:
As Brendan pointed out, one of the problems is that the grep command gets the first line that contains "jpg". That isn't even the line with the picture-of-the-day link, on this ap230427.html page, because the A.P.O.D. is a PNG instead.
The jpg has a higher resolution at 1800px, but is also dated 2016, whereas the png is 1024px, but dated 2023 :-) It does seem to suggest the png is the "actual" p-o-d, just resized from an older original. -- Per Jessen, Zürich (12.0°C) Member, openSUSE Heroes (2016 - present) We're hiring - https://en.opensuse.org/openSUSE:Heroes
On 2023-04-28 10:08, Per Jessen wrote:
Robert Webb via openSUSE Users wrote:
As Brendan pointed out, one of the problems is that the grep command gets the first line that contains "jpg". That isn't even the line with the picture-of-the-day link, on this ap230427.html page, because the A.P.O.D. is a PNG instead.
The jpg has a higher resolution at 1800px, but is also dated 2016, whereas the png is 1024px, but dated 2023 :-)
It does seem to suggest the png is the "actual" p-o-d, just resized from an older original.
In this case, I think I really want the jpg. -- Cheers / Saludos, Carlos E. R. (from 15.4 x86_64 at Telcontar)
On 2023-04-28 09:33, Robert Webb via openSUSE Users wrote:
On Thu, 27 Apr 2023 23:03:05 +0200 (CEST), "Carlos E. R." <robin.listas@telefonica.net> wrote:
I have a script (from somebody else) to download the image of the day from the NASA. I have modified the script quite a bit to download a range of days, even years of them.
One key function is failing on today's picture. This is the relevant section of the script:
+++...................... function get_page { echo "Downloading page to find image" #wget http://apod.nasa.gov/apod/ --quiet -O /tmp/apod.html wget https://apod.nasa.gov/apod/ap${SHORT_TODAY}.html --quiet -O /tmp/apod.html
grep -m 1 jpg /tmp/apod.html | sed -e 's/<//' -e 's/>//' -e 's/.*=//' -e 's/"//g' -e 's/^/http:\/\/apod.nasa.gov\/apod\//' > /tmp/pic_url }
get_page
# Got the link to the image PICURL=`/bin/cat /tmp/pic_url` if [ -z $PICURL ]; then echo "Not found picture.jpg for $TODAY. Trying .png" try_png PICURL=`/bin/cat /tmp/pic_url` if [ -z $PICURL ]; then echo "Not found picture.png for $TODAY. html file saved" cp /tmp/apod.html $PICTURES_DIR/$TODAY.html return fi fi
NAME=`basename $PICURL` PICTURE_NAME=${TODAY}_${NAME} ......................++-
The script sets up variable SHORT_TODAY to 230427, so "get_page" downloads <https://apod.nasa.gov/apod/ap230426.html>. It is coughing up this error:
You mean "<https://apod.nasa.gov/apod/ap230427.html>". ap230426.html is "the day before" you mention later below.
No, I wrote on the 27 ;-)
Do 20230427 Downloading page to find image /home/cer/bin/NASA Picture-Of-The-Day Wallpaper Script, mine, loop: line 98: [: too many arguments basename: extra operand ‘Tarantula</a>’ Try 'basename --help' for more information.
The problem is here:
cer@Isengard:~> grep -m 1 jpg /tmp/apod.html | sed -e 's/<//' -e 's/>//' -e 's/.*=//' -e 's/"//g' -e 's/^/http:\/\/apod.nasa.gov\/apod\//' http://apod.nasa.gov/apod/image/1602/Tarantula-HST-ESO-annotated1800.jpgArou... the Tarantula</a> cer@Isengard:~>
The source html goes like this:
<a href="image/1602/Tarantula-HST-ESO-annotated1800.jpg">Around the Tarantula</a> are other star forming regions with young star clusters, filaments, and blown-out <a href="ap080327.html">bubble-shaped</a> clouds.
As Brendan pointed out, one of the problems is that the grep command gets the first line that contains "jpg".
Right.
That isn't even the line with the picture-of-the-day link, on this ap230427.html page, because the A.P.O.D. is a PNG instead. It is from the description. The correct link is from here:
When the jpg is not found, I do a second call asking for png instead: you can see it in the susepaste. And some are a youtube video, those I do not really want (it is for a screensaver).
2023 April 27 <br>
<a href="image/2304/SuperBIT_tarantula.png"> <IMG SRC="image/2304/SuperBIT_tarantula_1024.png" alt="See Explanation. Clicking on the picture will download the highest resolution version available." style="max-width:100%"></a>
You need to grab not just a link *to* an image, but one that *is* an inline image also. The file suffix doesn't matter. So, the following can replace the grep and sed line, and the PICURL code.
-------------------- # Given an A.P.O.D. HTML page, this skips the lines down through the # page title heading. Then it extracts the HREF contents of the first # link that contains an IMG tag.
# Requires GNU sed for the 'I' flag (ignore regex case) which is used.
# Line-by-line description of ${HREF_EXTRACT_SCRIPT}: # # On each line, remove leading space. # Skip lines through the A.P.O.D. heading. # Skip blank lines. # If IMG tag, goto :img # Save this line to the Hold Space. # Next input line. (and go to the beginning of the script) # :img # Get (the previous line) from the Hold Space. # If not an 'A' tag with HREF, next input line. # Extract the HREF contents. # Print it. # Quit after the first print.
HREF_EXTRACT_SCRIPT=' s/^ *// 1,/^<h1> *Astronomy Picture of the Day/Id /^$/d /^<img *src="/Ib img x b :img x /^<a href="\([^<>"]\+\)">.*$/I!b s//\1/ p q '
[...] wget -O /tmp/apod.html ... PIC_HREF="$(sed -n -e "$HREF_EXTRACT_SCRIPT" /tmp/apod.html)"
if [ -z "$PIC_HREF" ] ;then printf '%s' "Not found picture.xxx for $TODAY... " cp -T /tmp/apod.html $PICTURES_DIR/$TODAY.html \ && echo " html file saved" return 1 else PICURL="http://apod.nasa.gov/apod/${PIC_HREF}" # printf '%s\n' "$PICURL" > /tmp/pic_url fi
NAME="$(basename "$PIC_HREF")" [...] --------------------
:-o Thanks. -- Cheers / Saludos, Carlos E. R. (from 15.4 x86_64 at Telcontar)
Carlos E. R. wrote:
The problem is here:
cer@Isengard:~> grep -m 1 jpg /tmp/apod.html | sed -e 's/<//' -e 's/>//' -e 's/.*=//' -e 's/"//g' -e 's/^/http:\/\/apod.nasa.gov\/apod\//' http://apod.nasa.gov/apod/image/1602/Tarantula-HST-ESO-annotated1800.jpgArou... the Tarantula</a> cer@Isengard:~>
That sed "script" is an abomination. Try this: grep -m1 href.*jpg /tmp/apod.html |\ sed -e 's@^.*href="\([^"]\+\)".*$@http://apod.nasa.gov/apod/\1@' For non-sed-speakers: Given the one line of <a href="image/1602/Tarantula-HST-ESO-annotated1800.jpg">Around the Tarantula</a the translation is roughly - grab the text enclosed in double quotes and prepend the base url. Combine it all into a one-liner (ignore the folding): grep -m1 href.*jpg /tmp/apod.html |\ sed -e 's@^.*href="\([^"]\+\)".*$@http://apod.nasa.gov/apod/\1@' |\ wget -i - -- Per Jessen, Zürich (13.8°C) Member, openSUSE Heroes (2016 - present) We're hiring - https://en.opensuse.org/openSUSE:Heroes
On 2023-04-28 09:42, Per Jessen wrote:
Carlos E. R. wrote:
The problem is here:
cer@Isengard:~> grep -m 1 jpg /tmp/apod.html | sed -e 's/<//' -e 's/>//' -e 's/.*=//' -e 's/"//g' -e 's/^/http:\/\/apod.nasa.gov\/apod\//' http://apod.nasa.gov/apod/image/1602/Tarantula-HST-ESO-annotated1800.jpgArou... the Tarantula</a> cer@Isengard:~>
That sed "script" is an abomination.
:-D
Try this:
grep -m1 href.*jpg /tmp/apod.html |\ sed -e 's@^.*href="\([^"]\+\)".*$@http://apod.nasa.gov/apod/\1@'
For non-sed-speakers:
Given the one line of
<a href="image/1602/Tarantula-HST-ESO-annotated1800.jpg">Around the Tarantula</a
the translation is roughly - grab the text enclosed in double quotes and prepend the base url.
Yes, that is the intention, what I would want to do.
Combine it all into a one-liner (ignore the folding):
grep -m1 href.*jpg /tmp/apod.html |\ sed -e 's@^.*href="\([^"]\+\)".*$@http://apod.nasa.gov/apod/\1@' |\ wget -i -
Thanks :-) -- Cheers / Saludos, Carlos E. R. (from 15.4 x86_64 at Telcontar)
On 2023-04-27 23:03, Carlos E. R. wrote:
Hi,
I have a script (from somebody else) to download the image of the day from the NASA. I have modified the script quite a bit to download a range of days, even years of them.
...
(the full script I modified is: https://paste.opensuse.org/7f484bb7c807)
I just modified it further, because besides png, there are some gif. And some JPG, PNG, and GIF. And I just discovered that there are fotos down to 19950616. My code suffers from year 2000 effect, LOL :-D (I think I know how to solve that, but now it is busy downloading this century photos) -- Cheers / Saludos, Carlos E. R. (from 15.4 x86_64 at Telcontar)
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Content-ID: <5543bfeb-83d9-69f8-14ea-6fc31c7120d5@Telcontar.valinor> El 2023-04-28 a las 14:25 +0200, Carlos E. R. escribió:
On 2023-04-27 23:03, Carlos E. R. wrote:
Hi,
I have a script (from somebody else) to download the image of the day from the NASA. I have modified the script quite a bit to download a range of days, even years of them.
...
(the full script I modified is: https://paste.opensuse.org/7f484bb7c807)
I just modified it further, because besides png, there are some gif. And some JPG, PNG, and GIF.
And I just discovered that there are fotos down to 19950616. My code suffers from year 2000 effect, LOL :-D
(I think I know how to solve that, but now it is busy downloading this century photos)
Just downloading the photos from year 2000 to year 2023 is still running at 19 hours. Year 2020 currently. [...] Took 6 hours to do. cer@Isengard:~/APOD> ls *jpg | wc -l 7876 cer@Isengard:~/APOD> ls *JPG | wc -l ls: cannot access '*JPG': No such file or directory 0 cer@Isengard:~/APOD> ls *png | wc -l 80 cer@Isengard:~/APOD> ls *PNG | wc -l ls: cannot access '*PNG': No such file or directory 0 cer@Isengard:~/APOD> ls *gif | wc -l 336 cer@Isengard:~/APOD> ls *GIF | wc -l ls: cannot access '*GIF': No such file or directory 0 cer@Isengard:~/APOD> No uppercases? I saw some in the failed htmls previously. Ah, I see I missed a "-i" in the grep for jpg. 174 youtube videos were skipped. 75 were skipped for other reasons. Example skipped file: 2001 April 18 <br> <applet code=HyprCube.class width=400 height=458> <param name=speed value=10> <param name=projection value=0> <img src="image/0104/hyprcube.gif" width=400 height=456 alt="See Explanation. Clicking on the picture will download the highest resolution version available."> </applet> </center> 29 had the string "Clicking on the picture will download" 2021 December 10 <br>. <a href="image/2112/Eclipseclock-final2.JPG"> <IMG SRC="image/2112/Eclipseclock-final2_1024c.JPG" alt="See Explanation. Clicking on the picture will download the highest resolution version available." style="max-width:100%"></a> But it is a JPG, was missed for uppercase. There are still 46 files skipped for several reasons. 2001 June 28 <br> <img src="image/0106/marstopography_mola.jpg" ALT="Please click on a specific area to see a zoom in of that area" ismap usemap="#map1" border=0> <map name="map1" nohref > <area coords="58,112,583,141" href="http://ltpwww.gsfc.nasa.gov/tharsis/Mars_topography_from_MOLA/M_-180_180_70_90.html"> <area coords="58,141,73,155" href="http://ltpwww.gsfc.nasa.gov/tharsis/Mars_topography_from_MOLA/M_-180_-170_60_70.html"> <area coords="73,141,88,155" href="http://ltpwww.gsfc.nasa.gov/tharsis/Mars_topography_from_MOLA/M_-170_-160_60_70.html"> <area coords="88,141,102,155" href="http://ltpwww.gsfc.nasa.gov/tharsis/Mars_topography_from_MOLA/M_-160_-150_60_70.html"> 2002 May 22 <br> <a href="#".. onMouseOver="if (document.images) document.imagename1.src= 'image/0205/Eiffeltower2_lagault.jpg';" onMouseOut="if (document.images) document.imagename1.src= 'image/0205/Eiffeltower1_lagault.jpg';" ONCLICK="return false;"> <IMG SRC="image/0205/Eiffeltower1_lagault.jpg" name=imagename1. alt="See Explanation. Rolling mouse over image will bring up. an annotated version. No higher. resolution version is available today."></a> </center> 2002 July 4 <br> <a href="#".. onMouseOver="if (document.images) document.imagename1.src='image/0207/ngc4365-15b-02sm.jpg';" onMouseOut="if (document.images) document.imagename1.src='image/0207/ngc4365-15a-02sm.jpg';" ONCLICK="return false;"> <IMG SRC="image/0207/ngc4365-15a-02sm.jpg" name=imagename1. alt="See Explanation. Rolling mouse over image will bring up. an annotated version. No higher. resolution version is available today."></a> 2007 May 22.. <br> <embed src="image/0705/flvplayer.swf" width="584" height="428". type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer". flashvars="file=http://www.astro.physik.uni-goettingen.de/outreach/APOD/cont.flv&displayheight=428&image=image/0705/cont000.jpg&allowfullscreen=true" /> ... Still, I have 10,191,955 KiB in 16597 files (half of them are the tex description files), which is a lot of photos for slides used by my screensaver :-) - -- Cheers, Carlos E. R. (from openSUSE 15.4 x86_64 at Telcontar) -----BEGIN PGP SIGNATURE----- iHoEARECADoWIQQZEb51mJKK1KpcU/W1MxgcbY1H1QUCZEwiqxwccm9iaW4ubGlz dGFzQHRlbGVmb25pY2EubmV0AAoJELUzGBxtjUfVXa8AniLd/iTefCIfjR8/FGiE +KNmzXgaAJsFRe7e9RKCm45gQi2yanbmOZmlhg== =Oz7a -----END PGP SIGNATURE-----
On Thu, 27 Apr 2023 23:03:05 +0200 (CEST) "Carlos E. R." <robin.listas@telefonica.net> wrote:
I have a script (from somebody else) to download the image of the day from the NASA. I have modified the script quite a bit to download a range of days, even years of them.
It may be worth noting that [some of] the images are copyright, so displaying them on your monitor other than in a browser as designed and implicitly permitted is probably not a good plan.
On 4/28/23 14:40, Dave Howorth wrote:
On Thu, 27 Apr 2023 23:03:05 +0200 (CEST) "Carlos E. R." <robin.listas@telefonica.net> wrote:
I have a script (from somebody else) to download the image of the day from the NASA. I have modified the script quite a bit to download a range of days, even years of them.
It may be worth noting that [some of] the images are copyright, so displaying them on your monitor other than in a browser as designed and implicitly permitted is probably not a good plan.
Granted, NASA may display works by a private individual capable of copyright, as for the government images themselves -- they are public domain. Even in the case of display of a private image under license, it would be a difficult hurdle for an holder to prove unlawful copying of an image displayed on Carlos's living room wall -- after having provide valid ownership of the copyright. See e.g., Feist Publications, Inc. v. Rural Tel. Serv. Co. https://supreme.justia.com/cases/federal/us/499/340/ All would depend on the license between the holder and government -- if one sufficiently detailed exists.... but possible... Probably have better odds winning a lottery though. -- David C. Rankin, J.D.,P.E.
On 2023-04-28 22:11, David C. Rankin wrote:
On 4/28/23 14:40, Dave Howorth wrote:
On Thu, 27 Apr 2023 23:03:05 +0200 (CEST) "Carlos E. R." <robin.listas@telefonica.net> wrote:
I have a script (from somebody else) to download the image of the day from the NASA. I have modified the script quite a bit to download a range of days, even years of them.
It may be worth noting that [some of] the images are copyright, so displaying them on your monitor other than in a browser as designed and implicitly permitted is probably not a good plan.
Granted, NASA may display works by a private individual capable of copyright, as for the government images themselves -- they are public domain. Even in the case of display of a private image under license, it would be a difficult hurdle for an holder to prove unlawful copying of an image displayed on Carlos's living room wall -- after having provide valid ownership of the copyright.
See e.g., Feist Publications, Inc. v. Rural Tel. Serv. Co. https://supreme.justia.com/cases/federal/us/499/340/
All would depend on the license between the holder and government -- if one sufficiently detailed exists.... but possible... Probably have better odds winning a lottery though.
<https://apod.nasa.gov/apod/ap_faq.html> Q6: Can I use an APOD picture for my computer-screen background? A6: For personal, non-commercial, non-public fair use, yes. -- Cheers / Saludos, Carlos E. R. (from 15.4 x86_64 at Telcontar)
participants (6)
-
Brendan McKenna
-
Carlos E. R.
-
Dave Howorth
-
David C. Rankin
-
Per Jessen
-
Robert Webb