Skip to content

Commit 40cdfb4

Browse files
authored
Merge pull request #3566 from bsipocz/DOC_fix_note_boxes
DOC: fix note boxes in euclid docs
2 parents 9af4650 + c9e0c99 commit 40cdfb4

1 file changed

Lines changed: 21 additions & 20 deletions

File tree

docs/esa/euclid/euclid.rst

Lines changed: 21 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -319,21 +319,21 @@ and their sky coverage (in its "fov" field) is queried using ADQL_. Please note:
319319

320320
**Step 2:** The get_product_ method is used to download the fits file(s) listed in the "file_name" field included in the table returned in the previous step. The method returns the local path where the product(s) is saved.
321321

322-
**Notes:**
323-
324-
* Given the size of the Euclid FITS images (~1.4 GB for the MER images and ~7 GB for calibrated VIS images) downloading individual files is time consuming (depending on the internet bandwith).
322+
.. note::
323+
* Given the size of the Euclid FITS images (~1.4 GB for the MER images and ~7 GB for calibrated VIS images) downloading individual files is time consuming (depending on the internet bandwith).
324+
* This step can be skipped if using ESA Datalabs_ (as direct access to the products is possible).
325325

326-
* This step can be skipped if using ESA Datalabs_ (as direct access to the products is possible).
326+
.. Skip testing as the example requires a lot of time to download a huge file
327+
.. doctest-skip::
327328

328329
>>> file_name = res['file_name'][0]
329330
>>> print("Downloading file:", file_name)
330331
Downloading file: EUC_MER_BGSUB-MOSAIC-VIS_TILE102158889-F95D3B_20241025T024806.508980Z_00.00.fits
331-
332-
.. doctest-skip::
333-
.. Skip testing as the example requires a lot of time to download a huge file
334-
332+
>>> file_name = res['file_name'][0]
333+
>>> print("Downloading file:", file_name)
335334
>>> path = Euclid.get_product(file_name=file_name, output_file=file_name)
336335

336+
337337
**Step 3:** Open the FITS file and inspect its content.
338338

339339
.. doctest-skip::
@@ -362,17 +362,17 @@ and their sky coverage (in its "fov" field) is queried using ADQL_. Please note:
362362

363363
It is also possible to download just small portions of the MER (background subtracted) images. The get_cutout_ allows to download image cutouts and store them locally - for reference, downloading a 1'x1'cutout takes less than one second and the downloaded fits file weights ~5.5 MB. In the example below, the results of Step 1 are used to build the file_path of the MER background-subtracted mosaic, which is the only required product input for the get_cutout method. This method now only retrieves cutouts from MER mosaics.
364364

365-
**Notes:**
366-
This method...
365+
.. note::
366+
This method...
367367

368-
* makes use of the `Astroquery cutout service <https://astroquery.readthedocs.io/en/latest/image_cutouts/image_cutouts.html>`_ to extract a cutout from a MER (background-subtracted) mosaic. It only supports MER mosaics. For more advanced use cases please see the Cutouts.ipynb notebook available in the Euclid Datalabs_.
368+
* makes use of `astroquery.image_cutouts` to extract a cutout from a MER (background-subtracted) mosaic. It only supports MER mosaics. For more advanced use cases please see the Cutouts.ipynb notebook available in the Euclid Datalabs_.
369369

370-
* accepts both Astropy SkyCoord_ coordinates and Simbad/VizieR/NED valid names (as string).
370+
* accepts both Astropy SkyCoord_ coordinates and Simbad/VizieR/NED valid names (as string).
371371

372372
Download the cutout...
373373

374-
.. doctest-skip::
375374
.. Skip testing as the example requires a lot of time to download a huge file
375+
.. doctest-skip::
376376

377377
>>> file_path = f"{res['file_path'][0]}/{res['file_name'][0]}"
378378
>>> cutout_out = Euclid.get_cutout(file_path=file_path, coordinate='NGC 6505', radius= 0.1 * u.arcmin, output_file='ngc6505_cutout_mer.fits')
@@ -400,11 +400,12 @@ Download the cutout...
400400
In the Archive the 1D Spectra data is served via the the Datalink_ (a data access protocol compliant with the IVOA_ architecture) service. Programmatically, this product is accessible via the get_spectrum_ method (see the
401401
`Access to spectra <https://s2e2.cosmos.esa.int/www/ek_iscience/Access_to_spectra.html>`_ section in the Archive help for more information about this product).
402402

403-
**Notes:** As it happens when accessing to other Euclid products:
403+
.. note::
404+
As it happens when accessing to other Euclid products:
404405

405-
* a two-step approach as detailed in Sect. 1.6 and 1.7 above is needed.
406+
* a two-step approach as detailed in Sect. 1.6 and 1.7 above is needed.
406407

407-
* downloading of products is not needed when using ESA Datalabs_.
408+
* downloading of products is not needed when using ESA Datalabs_.
408409

409410

410411
**Step 1:** First, a list of sources that have associated spectra must be compiled. This information is available in the spectra_source table, that also includes the FITs file name and other metadata that is relevant if reading the spectra from Datalabs_:
@@ -501,8 +502,8 @@ package will also be available:
501502

502503
There are several ways to log in to the Euclid archive, as detailed below:
503504

504-
.. doctest-skip::
505505
.. Skip testing as the example require authentication
506+
.. doctest-skip::
506507

507508
>>> from astroquery.esa.euclid import Euclid
508509
>>> Euclid.login_gui() # Login via graphic interface (pop-up window)
@@ -517,8 +518,8 @@ There are several ways to log in to the Euclid archive, as detailed below:
517518
All the asynchronous jobs launched by registered users are stored in the user area, which can store up to 10 GB of jobs. Therefore, it is recommended to remove unnecessary jobs to avoid filling up the user quota.
518519
The example below shows how to delete all the jobs in the user area using the list_async_jobs and remove_jobs_ methods.
519520

520-
.. doctest-skip::
521521
.. Skip testing as the example require authentication
522+
.. doctest-skip::
522523

523524
>>> Euclid.login()
524525
>>> job_ids = [job.jobid for job in Euclid.list_async_jobs()]
@@ -529,8 +530,8 @@ It is also possible to take advantage of the job metadata to delete all the jobs
529530

530531
First, use the load_async_job_ method to download the metadata of the async jobs stored in the user space:
531532

532-
.. doctest-skip::
533533
.. Skip testing as the example require authentication
534+
.. doctest-skip::
534535

535536
>>> job_obj = [Euclid.load_async_job(jobid=jobid) for jobid in job_ids]
536537
>>> job_ids = [job.jobid for job in job_obj]
@@ -547,8 +548,8 @@ Second, create a dataframe that contains the jobid and date information:
547548

548549
Finally, extract the job id's included in a given time range (in the example below, all the jobs stored since 2024-10-01 at 7 hours UTC) and delete them:
549550

550-
.. doctest-skip::
551551
.. Skip testing as the example require authentication
552+
.. doctest-skip::
552553

553554
>>> subset = df[(df['date'] == datetime.date(2024,10,1)) & (df['hour_UTC'].isin([7]))]
554555
>>> jobs_to_delete = subset['job_id'].to_list()

0 commit comments

Comments
 (0)