Skip to content
This repository was archived by the owner on Apr 28, 2025. It is now read-only.

Commit 5859547

Browse files
committed
Clear outputs.
2 parents 62d8f0c + a1e2f02 commit 5859547

1 file changed

Lines changed: 28 additions & 36 deletions

File tree

06_Comparing_Object_and_Truth_Tables.ipynb

Lines changed: 28 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"cells": [
33
{
44
"cell_type": "markdown",
5-
"id": "1639560d",
5+
"id": "8b4ba1a8",
66
"metadata": {},
77
"source": [
88
"<img align=\"left\" src = https://project.lsst.org/sites/default/files/Rubin-O-Logo_0.png width=250 style=\"padding: 10px\"> \n",
@@ -27,7 +27,7 @@
2727
{
2828
"cell_type": "code",
2929
"execution_count": null,
30-
"id": "9f70ee7e",
30+
"id": "d8ba8735",
3131
"metadata": {},
3232
"outputs": [],
3333
"source": [
@@ -38,7 +38,7 @@
3838
},
3939
{
4040
"cell_type": "markdown",
41-
"id": "e0958755",
41+
"id": "bfbea2b1",
4242
"metadata": {},
4343
"source": [
4444
"### 1. Import Common Python Libraries\n",
@@ -49,7 +49,7 @@
4949
{
5050
"cell_type": "code",
5151
"execution_count": null,
52-
"id": "f84b5be8",
52+
"id": "f8be85b1",
5353
"metadata": {},
5454
"outputs": [],
5555
"source": [
@@ -63,7 +63,7 @@
6363
},
6464
{
6565
"cell_type": "markdown",
66-
"id": "af316a4c",
66+
"id": "ada21dc8",
6767
"metadata": {},
6868
"source": [
6969
"To access tables, we will use the TAP service in a similar manner to what we showed in the [Intro to DP0 notebook](https://github.com/rubin-dp0/tutorial-notebooks/blob/main/01_Intro_to_DP0_Notebooks.ipynb), and explored further in THE TAP TUTORIAL NOTEBOOK. See those notebooks for more details."
@@ -72,7 +72,7 @@
7272
{
7373
"cell_type": "code",
7474
"execution_count": null,
75-
"id": "55838b7b",
75+
"id": "077b6c0f",
7676
"metadata": {},
7777
"outputs": [],
7878
"source": [
@@ -91,7 +91,7 @@
9191
},
9292
{
9393
"cell_type": "markdown",
94-
"id": "637ece9a",
94+
"id": "52a897dd",
9595
"metadata": {},
9696
"source": [
9797
"### 2. Loading tables with TAP\n",
@@ -102,7 +102,7 @@
102102
{
103103
"cell_type": "code",
104104
"execution_count": null,
105-
"id": "6778c472",
105+
"id": "4e140287",
106106
"metadata": {},
107107
"outputs": [],
108108
"source": [
@@ -112,7 +112,7 @@
112112
},
113113
{
114114
"cell_type": "markdown",
115-
"id": "86e92b98",
115+
"id": "e45aad05",
116116
"metadata": {},
117117
"source": [
118118
"For our analysis, let's choose the Object table, `dp01_dc2_catalogs.object`, and then we will compare the measurements from this table to the \"truth\" values from `dp01_dc2_catalogs.truth_match`.\n",
@@ -123,7 +123,7 @@
123123
{
124124
"cell_type": "code",
125125
"execution_count": null,
126-
"id": "fd7df864",
126+
"id": "d39962d2",
127127
"metadata": {},
128128
"outputs": [],
129129
"source": [
@@ -137,7 +137,7 @@
137137
{
138138
"cell_type": "code",
139139
"execution_count": null,
140-
"id": "920c6af0",
140+
"id": "eb67af10",
141141
"metadata": {},
142142
"outputs": [],
143143
"source": [
@@ -150,7 +150,7 @@
150150
},
151151
{
152152
"cell_type": "markdown",
153-
"id": "3fd9bde3",
153+
"id": "d5eba28e",
154154
"metadata": {},
155155
"source": [
156156
"For this exploration, we will select a small region of sky around a random RA, Dec position. The following two cells read data centered on (RA, Dec) = (62.0, -37.0) degrees, within a radius of 0.1 degrees, for first the Object table, then the Truth-Match table. Note that we are selecting only a subset of the columns seen in the schema above. You can add or remove columns as you wish.\n",
@@ -161,7 +161,7 @@
161161
{
162162
"cell_type": "code",
163163
"execution_count": null,
164-
"id": "81d2d6ea",
164+
"id": "b6e109cd",
165165
"metadata": {},
166166
"outputs": [],
167167
"source": [
@@ -176,7 +176,7 @@
176176
{
177177
"cell_type": "code",
178178
"execution_count": null,
179-
"id": "ba06fc28",
179+
"id": "e0ac2149",
180180
"metadata": {},
181181
"outputs": [],
182182
"source": [
@@ -186,12 +186,12 @@
186186
" \"FROM dp01_dc2_catalogs.truth_match \"\\\n",
187187
" \"WHERE CONTAINS(POINT('ICRS', ra, dec), CIRCLE('ICRS', 62.0, -37.0, 0.1)) = 1 \"\\\n",
188188
" \"AND match_objectId >= 0 AND is_good_match = 1\")\n",
189-
"#results.to_table().show_in_notebook() # To print the table to the screen.\n"
189+
"#results.to_table().show_in_notebook() # To print the table to the screen."
190190
]
191191
},
192192
{
193193
"cell_type": "markdown",
194-
"id": "92f3612b",
194+
"id": "d846a2be",
195195
"metadata": {},
196196
"source": [
197197
"These tables will be much easier to work with as `pandas` \"dataframes\". The query results have convenient methods that we can use to convert them."
@@ -200,7 +200,7 @@
200200
{
201201
"cell_type": "code",
202202
"execution_count": null,
203-
"id": "81dcac78",
203+
"id": "08fa4117",
204204
"metadata": {},
205205
"outputs": [],
206206
"source": [
@@ -210,7 +210,7 @@
210210
},
211211
{
212212
"cell_type": "markdown",
213-
"id": "a70d7da4",
213+
"id": "d149c002",
214214
"metadata": {},
215215
"source": [
216216
"### 3. Merge the two tables and compare measurements to truth values\n",
@@ -221,7 +221,7 @@
221221
{
222222
"cell_type": "code",
223223
"execution_count": null,
224-
"id": "93807913",
224+
"id": "3afe80b2",
225225
"metadata": {},
226226
"outputs": [],
227227
"source": [
@@ -238,7 +238,7 @@
238238
{
239239
"cell_type": "code",
240240
"execution_count": null,
241-
"id": "46cf18e0",
241+
"id": "c287ea01",
242242
"metadata": {},
243243
"outputs": [],
244244
"source": [
@@ -248,7 +248,7 @@
248248
{
249249
"cell_type": "code",
250250
"execution_count": null,
251-
"id": "33de260e",
251+
"id": "300a15fb",
252252
"metadata": {},
253253
"outputs": [],
254254
"source": [
@@ -283,7 +283,7 @@
283283
},
284284
{
285285
"cell_type": "markdown",
286-
"id": "4deec9c5",
286+
"id": "9a674e5e",
287287
"metadata": {},
288288
"source": [
289289
"#### Compare the measurements from the Object table to the \"true\" values for some objects.\n",
@@ -296,7 +296,7 @@
296296
{
297297
"cell_type": "code",
298298
"execution_count": null,
299-
"id": "42621d73",
299+
"id": "6672ad9f",
300300
"metadata": {},
301301
"outputs": [],
302302
"source": [
@@ -306,7 +306,7 @@
306306
},
307307
{
308308
"cell_type": "markdown",
309-
"id": "2b939113",
309+
"id": "44f961d0",
310310
"metadata": {},
311311
"source": [
312312
"Just to confirm that things look like we expect, let's plot a color-magnitude (g vs. g-i) and color-color (r-i vs. g-r) diagram."
@@ -315,7 +315,7 @@
315315
{
316316
"cell_type": "code",
317317
"execution_count": null,
318-
"id": "9dad2659",
318+
"id": "921ad2bf",
319319
"metadata": {},
320320
"outputs": [],
321321
"source": [
@@ -349,7 +349,7 @@
349349
},
350350
{
351351
"cell_type": "markdown",
352-
"id": "1d04fffb",
352+
"id": "b4b6ddac",
353353
"metadata": {},
354354
"source": [
355355
"Looks pretty normal - the stellar locus in color-color space is right where one expects it to be, and the galaxies dominate at the faint end of the CMD. \n",
@@ -360,7 +360,7 @@
360360
{
361361
"cell_type": "code",
362362
"execution_count": null,
363-
"id": "a45ebbcc",
363+
"id": "ca928751",
364364
"metadata": {},
365365
"outputs": [],
366366
"source": [
@@ -379,21 +379,13 @@
379379
},
380380
{
381381
"cell_type": "markdown",
382-
"id": "773441aa",
382+
"id": "d2182885",
383383
"metadata": {},
384384
"source": [
385385
"Well, that looks good -- the ratio of measured to true fluxes is centered on 1.0. It seems like the fluxes are recovered pretty well, on average.\n",
386386
"\n",
387387
"Congratulations! You have now learned how to compare measurements in the DP0.1 catalogs to the \"true\" simulated properties of objects. Have fun exploring more properties!"
388388
]
389-
},
390-
{
391-
"cell_type": "code",
392-
"execution_count": null,
393-
"id": "fd42e4de",
394-
"metadata": {},
395-
"outputs": [],
396-
"source": []
397389
}
398390
],
399391
"metadata": {

0 commit comments

Comments
 (0)