Skip to content

Commit 20359c6

Browse files
Changed ivoa.ObsCore to dp02_dc2_catalogs.ObsCore for DP0.2 NBs 02c, 13a, and 18. Also updated some of the text to reflect this change in 2c and 13a.
1 parent 5ecb854 commit 20359c6

3 files changed

Lines changed: 508 additions & 111 deletions

File tree

DP0.2/02c_Image_Queries_with_TAP.ipynb

Lines changed: 7 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -368,58 +368,14 @@
368368
"del query, results"
369369
]
370370
},
371-
{
372-
"cell_type": "markdown",
373-
"id": "8463597f-8c70-479e-8187-9cbd046db21c",
374-
"metadata": {},
375-
"source": [
376-
"### 2.1. The IVOA schema\n",
377-
"\n",
378-
"IVOA stands for [International Virtual Observatory Alliance](https://ivoa.net/), and they work towards defining standards\n",
379-
"for astronomical data storage that enable wide data sharing.\n",
380-
"The LSST Science Pipelines use IVOA standards.\n",
381-
"\n",
382-
"Retrieve all of the tables available in the `ivoa` schema and display them as a pandas table."
383-
]
384-
},
385-
{
386-
"cell_type": "code",
387-
"execution_count": null,
388-
"id": "951f4ae4-c0d4-4064-b10a-e2f1f8add499",
389-
"metadata": {},
390-
"outputs": [],
391-
"source": [
392-
"query = \"SELECT * \" \\\n",
393-
" \"FROM tap_schema.tables \" \\\n",
394-
" \"WHERE tap_schema.tables.schema_name = 'ivoa'\"\n",
395-
"results = service.search(query)\n",
396-
"results.to_table().to_pandas()"
397-
]
398-
},
399-
{
400-
"cell_type": "markdown",
401-
"id": "35361f18-579a-40cc-8caf-af28201869a3",
402-
"metadata": {},
403-
"source": [
404-
"There is only one `ivoa` table available for DP0: `ObsCore`."
405-
]
406-
},
407-
{
408-
"cell_type": "code",
409-
"execution_count": null,
410-
"id": "5738f062-0e63-43a4-a43e-e8032b4e2e59",
411-
"metadata": {},
412-
"outputs": [],
413-
"source": [
414-
"del query, results"
415-
]
416-
},
417371
{
418372
"cell_type": "markdown",
419373
"id": "16d98269-9dba-468f-84dc-8c0548926728",
420374
"metadata": {},
421375
"source": [
422-
"### 2.2. The ObsCore table\n",
376+
"### 2.1. The ObsCore table\n",
377+
"\n",
378+
"The `ObsCore` table schema conforms to the IVOA ([International Virtual Observatory Alliance](https://ivoa.net/)) standards.\n",
423379
"\n",
424380
"The LSST `ObsCore` table is essentially a view into the images\n",
425381
"stored in the LSST's [data butler](https://pipelines.lsst.io/modules/lsst.daf.butler/index.html) registry (e.g., [DMTN-236](https://dmtn-236.lsst.io/)).\n",
@@ -440,7 +396,7 @@
440396
"source": [
441397
"query = \"SELECT column_name, datatype, description, unit \" \\\n",
442398
" \"FROM tap_schema.columns \" \\\n",
443-
" \"WHERE table_name = 'ivoa.ObsCore'\"\n",
399+
" \"WHERE table_name = 'dp02_dc2_catalogs.ObsCore'\"\n",
444400
"results = service.search(query)\n",
445401
"results.to_table().to_pandas()"
446402
]
@@ -483,7 +439,7 @@
483439
"metadata": {},
484440
"outputs": [],
485441
"source": [
486-
"query = \"SELECT * FROM ivoa.ObsCore \"\\\n",
442+
"query = \"SELECT * FROM dp02_dc2_catalogs.ObsCore \"\\\n",
487443
" \"WHERE CONTAINS(POINT('ICRS', \" + target_str_ra + \\\n",
488444
" \", \" + target_str_dec + \"), s_region) = 1\"\n",
489445
"print(query)"
@@ -1196,7 +1152,7 @@
11961152
"metadata": {},
11971153
"outputs": [],
11981154
"source": [
1199-
"query = \"SELECT * FROM ivoa.ObsCore \"\\\n",
1155+
"query = \"SELECT * FROM dp02_dc2_catalogs.ObsCore \"\\\n",
12001156
" \"WHERE CONTAINS(POINT('ICRS', \" + \\\n",
12011157
" target_str_ra + \", \" + target_str_dec + \"), s_region) = 1 \"\\\n",
12021158
" \"AND lsst_band = 'i' \"\\\n",
@@ -1901,7 +1857,7 @@
19011857
"metadata": {},
19021858
"outputs": [],
19031859
"source": [
1904-
"query = \"SELECT * FROM ivoa.ObsCore \"\\\n",
1860+
"query = \"SELECT * FROM dp02_dc2_catalogs.ObsCore \"\\\n",
19051861
" \"WHERE CONTAINS(POINT('ICRS', \" + \\\n",
19061862
" target_str_ra + \", \" + target_str_dec + \"), s_region) = 1 \"\\\n",
19071863
" \"AND lsst_band = 'i' \"\\\n",

DP0.2/13a_Image_Cutout_SciDemo.ipynb

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
"id": "393da88f-7978-4920-aa4a-a9830df6eed9",
3838
"metadata": {},
3939
"source": [
40-
"**LSST Data Products:** Images (deepCoadd, calexp), catalogs (objectTable, diaObject, truthTables, ivoa.ObsCore)."
40+
"**LSST Data Products:** Images (deepCoadd, calexp), catalogs (objectTable, diaObject, truthTables, dp02_dc2_catalogs.ObsCore)."
4141
]
4242
},
4343
{
@@ -411,7 +411,7 @@
411411
"\n",
412412
" query = \"SELECT access_format, access_url, dataproduct_subtype, \" + \\\n",
413413
" \"lsst_visit, lsst_detector, lsst_band \" + \\\n",
414-
" \"FROM ivoa.ObsCore WHERE dataproduct_type = 'image' \" + \\\n",
414+
" \"FROM dp02_dc2_catalogs.ObsCore WHERE dataproduct_type = 'image' \" + \\\n",
415415
" \"AND obs_collection = 'LSST.DP02' \" + \\\n",
416416
" \"AND dataproduct_subtype = 'lsst.calexp' \" + \\\n",
417417
" \"AND lsst_visit = \" + str(dataId[\"visit\"]) + \" \" + \\\n",
@@ -428,7 +428,7 @@
428428
"\n",
429429
" query = \"SELECT access_format, access_url, dataproduct_subtype, \" + \\\n",
430430
" \"lsst_patch, lsst_tract, lsst_band \" + \\\n",
431-
" \"FROM ivoa.ObsCore WHERE dataproduct_type = 'image' \" + \\\n",
431+
" \"FROM dp02_dc2_catalogs.ObsCore WHERE dataproduct_type = 'image' \" + \\\n",
432432
" \"AND obs_collection = 'LSST.DP02' \" + \\\n",
433433
" \"AND dataproduct_subtype = 'lsst.deepCoadd_calexp' \" + \\\n",
434434
" \"AND lsst_tract = \" + str(tract) + \" \" + \\\n",
@@ -584,7 +584,7 @@
584584
"\n",
585585
"### 2.1 Initiate the TAP service, and define sky coordinates for the image cutout\n",
586586
"\n",
587-
"The TAP service is used to query the ivoa.Obscore table for the datalink (a web URL identifying where the data is hosted)."
587+
"The TAP service is used to query the dp02_dc2_catalogs.ObsCore table for the datalink (a web URL identifying where the data is hosted)."
588588
]
589589
},
590590
{
@@ -627,7 +627,7 @@
627627
"id": "551c859a-730a-4f4e-811b-6c2a13c4c30d",
628628
"metadata": {},
629629
"source": [
630-
"The next cell shows the TAP query for the metadata that is associated with the image's remote location in the LSST data archive. The DP0.2 has a schema (table collection) called \"ivoa\", which contains a table called ivoa.ObsCore. The IVOA-defined obscore table contains generic metadata for the DP0.2 datasets. The table is accessible via ADQL queries via a TAP endpoint. The mechanism for locating the images LSST is to use the TAP service to query the ObsCore schema. "
630+
"The next cell shows the TAP query for the metadata that is associated with the image's remote location in the LSST data archive. The DP0.2 has a schema (table collection) called \"dp02_dc2_catalogs\", which contains a table called dp02_dc2_catalogs.ObsCore. The IVOA-defined `ObsCore` table contains generic metadata for the DP0.2 datasets. The table is accessible via ADQL queries via a TAP endpoint. The mechanism for locating the images LSST is to use the TAP service to query the `ObsCore` schema. "
631631
]
632632
},
633633
{
@@ -639,7 +639,7 @@
639639
"source": [
640640
"query = \"SELECT lsst_patch, lsst_tract, s_region, \" + \\\n",
641641
" \"access_format, access_url, dataproduct_subtype \" + \\\n",
642-
" \"FROM ivoa.ObsCore \" + \\\n",
642+
" \"FROM dp02_dc2_catalogs.ObsCore \" + \\\n",
643643
" \"WHERE dataproduct_type = 'image' \" + \\\n",
644644
" \"AND obs_collection = 'LSST.DP02' \" + \\\n",
645645
" \"AND dataproduct_subtype = 'lsst.deepCoadd_calexp' \" + \\\n",

0 commit comments

Comments
 (0)