Get_amda_tao_datasets.ipynb
3.69 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
{
"cells": [
{
"cell_type": "code",
"execution_count": 1,
"id": "52949b59-f206-410f-92fa-265bb161aaf2",
"metadata": {},
"outputs": [],
"source": [
"from speasy import amda"
]
},
{
"cell_type": "code",
"execution_count": 2,
"id": "8506952c-8f5d-47b1-97e8-f0c3450b0b34",
"metadata": {},
"outputs": [],
"source": [
"\n",
"start_date = '20221201'\n",
"stop_date = '20221215'\n",
"# tao_mercury_sw_dataset = amda.get_dataset('tao-mercury-sw', start_date, stop_date)\n",
"# so_pas_momgr1_sw_dataset = amda.get_dataset('so-pas-momgr1', start_date, stop_date)\n",
"tao_mars_dsc_dataset = amda.get_dataset('tao-mars-dsc', start_date, stop_date)\n",
"\n",
"\n",
"\n"
]
},
{
"cell_type": "code",
"execution_count": 10,
"id": "0fc5f3a7-c5be-4c72-a2ad-512126b42e30",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"<class 'speasy.products.dataset.Dataset'>\n",
" mars_dsc_n\n",
"2022-12-01 00:00:00 2.79690\n",
"2022-12-01 01:00:00 2.29837\n",
"2022-12-01 02:00:00 2.12798\n",
"2022-12-01 03:00:00 2.20450\n",
"2022-12-01 04:00:00 2.62385\n",
"... ...\n",
"2022-12-14 19:00:00 3.03795\n",
"2022-12-14 20:00:00 4.44247\n",
"2022-12-14 21:00:00 4.67082\n",
"2022-12-14 22:00:00 4.38174\n",
"2022-12-14 23:00:00 3.85952\n",
"\n",
"[336 rows x 1 columns]\n"
]
}
],
"source": [
"print(type(tao_mars_dsc_dataset))\n",
"tao_mars_dsc_density = tao_mars_dsc_dataset['density']\n",
"print(tao_mars_dsc_density.to_dataframe())\n",
"# for v in tao_mars_dsc_dataset.variables.keys():\n",
"# print(type(v))\n"
]
},
{
"cell_type": "code",
"execution_count": 4,
"id": "63cda766-930e-4014-94fb-a23ca527c5b1",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"density\n",
"velocity\n",
"temperature\n",
"dynamic pressure\n",
"b tangential\n",
"b radial\n",
"angle Mars-Sun-Earth\n"
]
}
],
"source": [
"for k in tao_mars_dsc_dataset.variables.keys():\n",
" print(k)\n",
"# print(so_pas_momgr1_sw_dataset.variables)"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "61f3aed2-abd1-46a1-a86b-31e0ed5498d0",
"metadata": {},
"outputs": [],
"source": []
},
{
"cell_type": "code",
"execution_count": 5,
"id": "382151f8-4d73-43df-a855-02a8a0f7b5ab",
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
" pas_mom_n\n",
"2023-02-01 00:00:03.421999872 NaN\n",
"2023-02-01 00:00:07.421999872 NaN\n",
"2023-02-01 00:00:11.421999872 NaN\n",
"2023-02-01 00:00:15.421999872 5.6\n",
"2023-02-01 00:00:19.421999872 5.7\n"
]
}
],
"source": [
"print(my_df.head())"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "7b3ebc65-a98a-4100-ae67-8925f34e7ca1",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.10.12"
}
},
"nbformat": 4,
"nbformat_minor": 5
}