JOnas Becker commited on
Commit
7a10530
·
1 Parent(s): f6e4ea6

initial commit

Browse files
Files changed (4) hide show
  1. .gitattributes +1 -0
  2. data.parquet +3 -0
  3. mat2json.ipynb +474 -0
  4. mill.mat +3 -0
.gitattributes CHANGED
@@ -56,3 +56,4 @@ saved_model/**/* filter=lfs diff=lfs merge=lfs -text
56
  # Video files - compressed
57
  *.mp4 filter=lfs diff=lfs merge=lfs -text
58
  *.webm filter=lfs diff=lfs merge=lfs -text
 
 
56
  # Video files - compressed
57
  *.mp4 filter=lfs diff=lfs merge=lfs -text
58
  *.webm filter=lfs diff=lfs merge=lfs -text
59
+ *.mat filter=lfs diff=lfs merge=lfs -text
data.parquet ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:04819835e2747b9951a0d4415f5d0ce9d339ae6a0985ba3d6098c0b69116b1be
3
+ size 13773426
mat2json.ipynb ADDED
@@ -0,0 +1,474 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "cells": [
3
+ {
4
+ "cell_type": "code",
5
+ "execution_count": 1,
6
+ "metadata": {},
7
+ "outputs": [],
8
+ "source": [
9
+ "import scipy.io as sio\n",
10
+ "import pandas as pd\n",
11
+ "import numpy as np\n",
12
+ "# Load the .mat file\n",
13
+ "mat_contents = sio.loadmat('mill.mat')"
14
+ ]
15
+ },
16
+ {
17
+ "cell_type": "code",
18
+ "execution_count": 13,
19
+ "metadata": {},
20
+ "outputs": [
21
+ {
22
+ "data": {
23
+ "text/plain": [
24
+ "array([[1]], dtype=uint8)"
25
+ ]
26
+ },
27
+ "execution_count": 13,
28
+ "metadata": {},
29
+ "output_type": "execute_result"
30
+ }
31
+ ],
32
+ "source": [
33
+ "idx = 0\n",
34
+ "np.assdata[0][idx][1]"
35
+ ]
36
+ },
37
+ {
38
+ "cell_type": "code",
39
+ "execution_count": 21,
40
+ "metadata": {},
41
+ "outputs": [
42
+ {
43
+ "name": "stdout",
44
+ "output_type": "stream",
45
+ "text": [
46
+ "<class 'numpy.ndarray'>\n",
47
+ "(1, 167)\n"
48
+ ]
49
+ },
50
+ {
51
+ "data": {
52
+ "text/html": [
53
+ "<div>\n",
54
+ "<style scoped>\n",
55
+ " .dataframe tbody tr th:only-of-type {\n",
56
+ " vertical-align: middle;\n",
57
+ " }\n",
58
+ "\n",
59
+ " .dataframe tbody tr th {\n",
60
+ " vertical-align: top;\n",
61
+ " }\n",
62
+ "\n",
63
+ " .dataframe thead th {\n",
64
+ " text-align: right;\n",
65
+ " }\n",
66
+ "</style>\n",
67
+ "<table border=\"1\" class=\"dataframe\">\n",
68
+ " <thead>\n",
69
+ " <tr style=\"text-align: right;\">\n",
70
+ " <th></th>\n",
71
+ " <th>case</th>\n",
72
+ " <th>run</th>\n",
73
+ " <th>VB</th>\n",
74
+ " <th>time</th>\n",
75
+ " <th>DOC</th>\n",
76
+ " <th>feed</th>\n",
77
+ " <th>material</th>\n",
78
+ " <th>smcAC</th>\n",
79
+ " <th>smcDC</th>\n",
80
+ " <th>vib_table</th>\n",
81
+ " <th>vib_spindle</th>\n",
82
+ " <th>AE_table</th>\n",
83
+ " <th>AE_spindle</th>\n",
84
+ " </tr>\n",
85
+ " </thead>\n",
86
+ " <tbody>\n",
87
+ " <tr>\n",
88
+ " <th>0</th>\n",
89
+ " <td>1</td>\n",
90
+ " <td>1</td>\n",
91
+ " <td>0.00</td>\n",
92
+ " <td>2</td>\n",
93
+ " <td>1.5</td>\n",
94
+ " <td>0.5</td>\n",
95
+ " <td>1</td>\n",
96
+ " <td>[-0.01708984375, 0.263671875, 0.20751953125, 0...</td>\n",
97
+ " <td>[0.625, 0.810546875, 0.78125, 0.849609375, 1.0...</td>\n",
98
+ " <td>[0.078125, 0.08544921875, 0.078125, 0.07324218...</td>\n",
99
+ " <td>[0.31494140625, 0.301513671875, 0.303955078125...</td>\n",
100
+ " <td>[0.0872802734375, 0.0982666015625, 0.092163085...</td>\n",
101
+ " <td>[0.103759765625, 0.123291015625, 0.10498046875...</td>\n",
102
+ " </tr>\n",
103
+ " <tr>\n",
104
+ " <th>1</th>\n",
105
+ " <td>1</td>\n",
106
+ " <td>2</td>\n",
107
+ " <td>NaN</td>\n",
108
+ " <td>4</td>\n",
109
+ " <td>1.5</td>\n",
110
+ " <td>0.5</td>\n",
111
+ " <td>1</td>\n",
112
+ " <td>[0.3076171875, 0.3125, 0.1953125, 0.1879882812...</td>\n",
113
+ " <td>[0.6689453125, 0.6787109375, 0.859375, 1.12304...</td>\n",
114
+ " <td>[0.07568359375, 0.08056640625, 0.078125, 0.080...</td>\n",
115
+ " <td>[0.301513671875, 0.308837890625, 0.29907226562...</td>\n",
116
+ " <td>[0.086669921875, 0.0897216796875, 0.0946044921...</td>\n",
117
+ " <td>[0.0994873046875, 0.103759765625, 0.1080322265...</td>\n",
118
+ " </tr>\n",
119
+ " <tr>\n",
120
+ " <th>2</th>\n",
121
+ " <td>1</td>\n",
122
+ " <td>3</td>\n",
123
+ " <td>NaN</td>\n",
124
+ " <td>6</td>\n",
125
+ " <td>1.5</td>\n",
126
+ " <td>0.5</td>\n",
127
+ " <td>1</td>\n",
128
+ " <td>[-0.72509765625, -0.71533203125, -0.5297851562...</td>\n",
129
+ " <td>[0.9130859375, 0.8349609375, 0.908203125, 1.15...</td>\n",
130
+ " <td>[0.0830078125, 0.078125, 0.09033203125, 0.0805...</td>\n",
131
+ " <td>[0.29541015625, 0.296630859375, 0.29296875, 0....</td>\n",
132
+ " <td>[0.0927734375, 0.1007080078125, 0.093383789062...</td>\n",
133
+ " <td>[0.10498046875, 0.1190185546875, 0.10986328125...</td>\n",
134
+ " </tr>\n",
135
+ " <tr>\n",
136
+ " <th>3</th>\n",
137
+ " <td>1</td>\n",
138
+ " <td>4</td>\n",
139
+ " <td>0.11</td>\n",
140
+ " <td>7</td>\n",
141
+ " <td>1.5</td>\n",
142
+ " <td>0.5</td>\n",
143
+ " <td>1</td>\n",
144
+ " <td>[0.1123046875, 0.009765625, -0.1513671875, -0....</td>\n",
145
+ " <td>[0.1318359375, 0.3955078125, 0.7568359375, 0.8...</td>\n",
146
+ " <td>[0.0830078125, 0.07568359375, 0.06591796875, 0...</td>\n",
147
+ " <td>[0.316162109375, 0.311279296875, 0.302734375, ...</td>\n",
148
+ " <td>[0.1129150390625, 0.0994873046875, 0.104980468...</td>\n",
149
+ " <td>[0.1397705078125, 0.1214599609375, 0.124511718...</td>\n",
150
+ " </tr>\n",
151
+ " <tr>\n",
152
+ " <th>4</th>\n",
153
+ " <td>1</td>\n",
154
+ " <td>5</td>\n",
155
+ " <td>NaN</td>\n",
156
+ " <td>11</td>\n",
157
+ " <td>1.5</td>\n",
158
+ " <td>0.5</td>\n",
159
+ " <td>1</td>\n",
160
+ " <td>[-0.1220703125, -0.16357421875, -0.36865234375...</td>\n",
161
+ " <td>[0.44921875, 0.6640625, 0.6689453125, 0.747070...</td>\n",
162
+ " <td>[0.107421875, 0.107421875, 0.1025390625, 0.100...</td>\n",
163
+ " <td>[0.284423828125, 0.289306640625, 0.28442382812...</td>\n",
164
+ " <td>[0.0958251953125, 0.09765625, 0.09765625, 0.09...</td>\n",
165
+ " <td>[0.1104736328125, 0.113525390625, 0.1098632812...</td>\n",
166
+ " </tr>\n",
167
+ " <tr>\n",
168
+ " <th>...</th>\n",
169
+ " <td>...</td>\n",
170
+ " <td>...</td>\n",
171
+ " <td>...</td>\n",
172
+ " <td>...</td>\n",
173
+ " <td>...</td>\n",
174
+ " <td>...</td>\n",
175
+ " <td>...</td>\n",
176
+ " <td>...</td>\n",
177
+ " <td>...</td>\n",
178
+ " <td>...</td>\n",
179
+ " <td>...</td>\n",
180
+ " <td>...</td>\n",
181
+ " <td>...</td>\n",
182
+ " </tr>\n",
183
+ " <tr>\n",
184
+ " <th>162</th>\n",
185
+ " <td>16</td>\n",
186
+ " <td>2</td>\n",
187
+ " <td>NaN</td>\n",
188
+ " <td>2</td>\n",
189
+ " <td>1.5</td>\n",
190
+ " <td>0.5</td>\n",
191
+ " <td>2</td>\n",
192
+ " <td>[-0.58349609375, -0.5810546875, -0.51513671875...</td>\n",
193
+ " <td>[1.30859375, 1.318359375, 1.3330078125, 1.3427...</td>\n",
194
+ " <td>[0.0634765625, 0.0732421875, 0.06591796875, 0....</td>\n",
195
+ " <td>[0.330810546875, 0.299072265625, 0.3173828125,...</td>\n",
196
+ " <td>[0.093994140625, 0.0897216796875, 0.0982666015...</td>\n",
197
+ " <td>[0.1092529296875, 0.1025390625, 0.116577148437...</td>\n",
198
+ " </tr>\n",
199
+ " <tr>\n",
200
+ " <th>163</th>\n",
201
+ " <td>16</td>\n",
202
+ " <td>3</td>\n",
203
+ " <td>0.24</td>\n",
204
+ " <td>3</td>\n",
205
+ " <td>1.5</td>\n",
206
+ " <td>0.5</td>\n",
207
+ " <td>2</td>\n",
208
+ " <td>[-0.2001953125, -0.009765625, 0.0830078125, 0....</td>\n",
209
+ " <td>[1.40625, 1.4013671875, 1.396484375, 1.3867187...</td>\n",
210
+ " <td>[0.06591796875, 0.07080078125, 0.0634765625, 0...</td>\n",
211
+ " <td>[0.279541015625, 0.284423828125, 0.30151367187...</td>\n",
212
+ " <td>[0.11474609375, 0.09521484375, 0.1019287109375...</td>\n",
213
+ " <td>[0.1397705078125, 0.1123046875, 0.120239257812...</td>\n",
214
+ " </tr>\n",
215
+ " <tr>\n",
216
+ " <th>164</th>\n",
217
+ " <td>16</td>\n",
218
+ " <td>4</td>\n",
219
+ " <td>NaN</td>\n",
220
+ " <td>4</td>\n",
221
+ " <td>1.5</td>\n",
222
+ " <td>0.5</td>\n",
223
+ " <td>2</td>\n",
224
+ " <td>[0.244140625, 0.244140625, 0.205078125, 0.1562...</td>\n",
225
+ " <td>[1.328125, 1.3330078125, 1.3330078125, 1.33300...</td>\n",
226
+ " <td>[0.0634765625, 0.05859375, 0.05859375, 0.06347...</td>\n",
227
+ " <td>[0.29052734375, 0.279541015625, 0.28564453125,...</td>\n",
228
+ " <td>[0.101318359375, 0.1214599609375, 0.1220703125...</td>\n",
229
+ " <td>[0.1177978515625, 0.140380859375, 0.1428222656...</td>\n",
230
+ " </tr>\n",
231
+ " <tr>\n",
232
+ " <th>165</th>\n",
233
+ " <td>16</td>\n",
234
+ " <td>5</td>\n",
235
+ " <td>0.40</td>\n",
236
+ " <td>6</td>\n",
237
+ " <td>1.5</td>\n",
238
+ " <td>0.5</td>\n",
239
+ " <td>2</td>\n",
240
+ " <td>[-0.205078125, -0.2392578125, -0.15625, 0.1269...</td>\n",
241
+ " <td>[1.3818359375, 1.38671875, 1.38671875, 1.38183...</td>\n",
242
+ " <td>[0.068359375, 0.05859375, 0.07080078125, 0.065...</td>\n",
243
+ " <td>[0.289306640625, 0.30029296875, 0.291748046875...</td>\n",
244
+ " <td>[0.098876953125, 0.096435546875, 0.08972167968...</td>\n",
245
+ " <td>[0.11474609375, 0.1123046875, 0.1068115234375,...</td>\n",
246
+ " </tr>\n",
247
+ " <tr>\n",
248
+ " <th>166</th>\n",
249
+ " <td>16</td>\n",
250
+ " <td>6</td>\n",
251
+ " <td>0.62</td>\n",
252
+ " <td>9</td>\n",
253
+ " <td>1.5</td>\n",
254
+ " <td>0.5</td>\n",
255
+ " <td>2</td>\n",
256
+ " <td>[-0.380859375, -0.244140625, -0.13671875, -0.0...</td>\n",
257
+ " <td>[1.3818359375, 1.3916015625, 1.396484375, 1.39...</td>\n",
258
+ " <td>[0.04150390625, 0.04150390625, 0.04150390625, ...</td>\n",
259
+ " <td>[0.29296875, 0.30517578125, 0.28564453125, 0.3...</td>\n",
260
+ " <td>[0.07568359375, 0.087890625, 0.0750732421875, ...</td>\n",
261
+ " <td>[0.0830078125, 0.096435546875, 0.0762939453125...</td>\n",
262
+ " </tr>\n",
263
+ " </tbody>\n",
264
+ "</table>\n",
265
+ "<p>167 rows × 13 columns</p>\n",
266
+ "</div>"
267
+ ],
268
+ "text/plain": [
269
+ " case run VB time DOC feed material \\\n",
270
+ "0 1 1 0.00 2 1.5 0.5 1 \n",
271
+ "1 1 2 NaN 4 1.5 0.5 1 \n",
272
+ "2 1 3 NaN 6 1.5 0.5 1 \n",
273
+ "3 1 4 0.11 7 1.5 0.5 1 \n",
274
+ "4 1 5 NaN 11 1.5 0.5 1 \n",
275
+ ".. ... ... ... ... ... ... ... \n",
276
+ "162 16 2 NaN 2 1.5 0.5 2 \n",
277
+ "163 16 3 0.24 3 1.5 0.5 2 \n",
278
+ "164 16 4 NaN 4 1.5 0.5 2 \n",
279
+ "165 16 5 0.40 6 1.5 0.5 2 \n",
280
+ "166 16 6 0.62 9 1.5 0.5 2 \n",
281
+ "\n",
282
+ " smcAC \\\n",
283
+ "0 [-0.01708984375, 0.263671875, 0.20751953125, 0... \n",
284
+ "1 [0.3076171875, 0.3125, 0.1953125, 0.1879882812... \n",
285
+ "2 [-0.72509765625, -0.71533203125, -0.5297851562... \n",
286
+ "3 [0.1123046875, 0.009765625, -0.1513671875, -0.... \n",
287
+ "4 [-0.1220703125, -0.16357421875, -0.36865234375... \n",
288
+ ".. ... \n",
289
+ "162 [-0.58349609375, -0.5810546875, -0.51513671875... \n",
290
+ "163 [-0.2001953125, -0.009765625, 0.0830078125, 0.... \n",
291
+ "164 [0.244140625, 0.244140625, 0.205078125, 0.1562... \n",
292
+ "165 [-0.205078125, -0.2392578125, -0.15625, 0.1269... \n",
293
+ "166 [-0.380859375, -0.244140625, -0.13671875, -0.0... \n",
294
+ "\n",
295
+ " smcDC \\\n",
296
+ "0 [0.625, 0.810546875, 0.78125, 0.849609375, 1.0... \n",
297
+ "1 [0.6689453125, 0.6787109375, 0.859375, 1.12304... \n",
298
+ "2 [0.9130859375, 0.8349609375, 0.908203125, 1.15... \n",
299
+ "3 [0.1318359375, 0.3955078125, 0.7568359375, 0.8... \n",
300
+ "4 [0.44921875, 0.6640625, 0.6689453125, 0.747070... \n",
301
+ ".. ... \n",
302
+ "162 [1.30859375, 1.318359375, 1.3330078125, 1.3427... \n",
303
+ "163 [1.40625, 1.4013671875, 1.396484375, 1.3867187... \n",
304
+ "164 [1.328125, 1.3330078125, 1.3330078125, 1.33300... \n",
305
+ "165 [1.3818359375, 1.38671875, 1.38671875, 1.38183... \n",
306
+ "166 [1.3818359375, 1.3916015625, 1.396484375, 1.39... \n",
307
+ "\n",
308
+ " vib_table \\\n",
309
+ "0 [0.078125, 0.08544921875, 0.078125, 0.07324218... \n",
310
+ "1 [0.07568359375, 0.08056640625, 0.078125, 0.080... \n",
311
+ "2 [0.0830078125, 0.078125, 0.09033203125, 0.0805... \n",
312
+ "3 [0.0830078125, 0.07568359375, 0.06591796875, 0... \n",
313
+ "4 [0.107421875, 0.107421875, 0.1025390625, 0.100... \n",
314
+ ".. ... \n",
315
+ "162 [0.0634765625, 0.0732421875, 0.06591796875, 0.... \n",
316
+ "163 [0.06591796875, 0.07080078125, 0.0634765625, 0... \n",
317
+ "164 [0.0634765625, 0.05859375, 0.05859375, 0.06347... \n",
318
+ "165 [0.068359375, 0.05859375, 0.07080078125, 0.065... \n",
319
+ "166 [0.04150390625, 0.04150390625, 0.04150390625, ... \n",
320
+ "\n",
321
+ " vib_spindle \\\n",
322
+ "0 [0.31494140625, 0.301513671875, 0.303955078125... \n",
323
+ "1 [0.301513671875, 0.308837890625, 0.29907226562... \n",
324
+ "2 [0.29541015625, 0.296630859375, 0.29296875, 0.... \n",
325
+ "3 [0.316162109375, 0.311279296875, 0.302734375, ... \n",
326
+ "4 [0.284423828125, 0.289306640625, 0.28442382812... \n",
327
+ ".. ... \n",
328
+ "162 [0.330810546875, 0.299072265625, 0.3173828125,... \n",
329
+ "163 [0.279541015625, 0.284423828125, 0.30151367187... \n",
330
+ "164 [0.29052734375, 0.279541015625, 0.28564453125,... \n",
331
+ "165 [0.289306640625, 0.30029296875, 0.291748046875... \n",
332
+ "166 [0.29296875, 0.30517578125, 0.28564453125, 0.3... \n",
333
+ "\n",
334
+ " AE_table \\\n",
335
+ "0 [0.0872802734375, 0.0982666015625, 0.092163085... \n",
336
+ "1 [0.086669921875, 0.0897216796875, 0.0946044921... \n",
337
+ "2 [0.0927734375, 0.1007080078125, 0.093383789062... \n",
338
+ "3 [0.1129150390625, 0.0994873046875, 0.104980468... \n",
339
+ "4 [0.0958251953125, 0.09765625, 0.09765625, 0.09... \n",
340
+ ".. ... \n",
341
+ "162 [0.093994140625, 0.0897216796875, 0.0982666015... \n",
342
+ "163 [0.11474609375, 0.09521484375, 0.1019287109375... \n",
343
+ "164 [0.101318359375, 0.1214599609375, 0.1220703125... \n",
344
+ "165 [0.098876953125, 0.096435546875, 0.08972167968... \n",
345
+ "166 [0.07568359375, 0.087890625, 0.0750732421875, ... \n",
346
+ "\n",
347
+ " AE_spindle \n",
348
+ "0 [0.103759765625, 0.123291015625, 0.10498046875... \n",
349
+ "1 [0.0994873046875, 0.103759765625, 0.1080322265... \n",
350
+ "2 [0.10498046875, 0.1190185546875, 0.10986328125... \n",
351
+ "3 [0.1397705078125, 0.1214599609375, 0.124511718... \n",
352
+ "4 [0.1104736328125, 0.113525390625, 0.1098632812... \n",
353
+ ".. ... \n",
354
+ "162 [0.1092529296875, 0.1025390625, 0.116577148437... \n",
355
+ "163 [0.1397705078125, 0.1123046875, 0.120239257812... \n",
356
+ "164 [0.1177978515625, 0.140380859375, 0.1428222656... \n",
357
+ "165 [0.11474609375, 0.1123046875, 0.1068115234375,... \n",
358
+ "166 [0.0830078125, 0.096435546875, 0.0762939453125... \n",
359
+ "\n",
360
+ "[167 rows x 13 columns]"
361
+ ]
362
+ },
363
+ "execution_count": 21,
364
+ "metadata": {},
365
+ "output_type": "execute_result"
366
+ }
367
+ ],
368
+ "source": [
369
+ "mat_contents.keys()\n",
370
+ "data=mat_contents['mill']\n",
371
+ "print(type(data))\n",
372
+ "print(data.shape)\n",
373
+ "df= pd.DataFrame(data[0])\n",
374
+ "\n",
375
+ "for c in [\"case\",\"run\",\"VB\",\"time\",\"DOC\",\"feed\",\"material\"]:\n",
376
+ " df[c] = df[c].apply(lambda x: x.item())\n",
377
+ "\n",
378
+ "for c in [\"smcAC\",\"smcDC\",\"vib_table\",\"vib_spindle\",\"AE_table\",\"AE_spindle\"]:\n",
379
+ " df[c] = df[c].apply(lambda x: np.squeeze(x,1))\n",
380
+ "\n",
381
+ "df"
382
+ ]
383
+ },
384
+ {
385
+ "cell_type": "code",
386
+ "execution_count": 19,
387
+ "metadata": {},
388
+ "outputs": [
389
+ {
390
+ "data": {
391
+ "text/plain": [
392
+ "0 1\n",
393
+ "1 1\n",
394
+ "2 1\n",
395
+ "3 1\n",
396
+ "4 1\n",
397
+ " ..\n",
398
+ "162 16\n",
399
+ "163 16\n",
400
+ "164 16\n",
401
+ "165 16\n",
402
+ "166 16\n",
403
+ "Name: case, Length: 167, dtype: int64"
404
+ ]
405
+ },
406
+ "execution_count": 19,
407
+ "metadata": {},
408
+ "output_type": "execute_result"
409
+ }
410
+ ],
411
+ "source": [
412
+ "df.to_parquet(\"data.parquet\")"
413
+ ]
414
+ },
415
+ {
416
+ "cell_type": "code",
417
+ "execution_count": null,
418
+ "metadata": {},
419
+ "outputs": [],
420
+ "source": [
421
+ "# Export:\n",
422
+ "df.to_json('mill/data.jsonl', orient='records', lines=True)"
423
+ ]
424
+ },
425
+ {
426
+ "cell_type": "code",
427
+ "execution_count": 58,
428
+ "metadata": {},
429
+ "outputs": [
430
+ {
431
+ "name": "stdout",
432
+ "output_type": "stream",
433
+ "text": [
434
+ "NpzFile 'mill/data.npz' with keys: arr_0\n"
435
+ ]
436
+ }
437
+ ],
438
+ "source": [
439
+ "# reading data from npz file \n",
440
+ "data = np.load(\"mill/data.npz\")\n",
441
+ "with np.load('mill/data.npz') as data:\n",
442
+ "\tprint(data)"
443
+ ]
444
+ },
445
+ {
446
+ "cell_type": "code",
447
+ "execution_count": null,
448
+ "metadata": {},
449
+ "outputs": [],
450
+ "source": []
451
+ }
452
+ ],
453
+ "metadata": {
454
+ "kernelspec": {
455
+ "display_name": "base",
456
+ "language": "python",
457
+ "name": "python3"
458
+ },
459
+ "language_info": {
460
+ "codemirror_mode": {
461
+ "name": "ipython",
462
+ "version": 3
463
+ },
464
+ "file_extension": ".py",
465
+ "mimetype": "text/x-python",
466
+ "name": "python",
467
+ "nbconvert_exporter": "python",
468
+ "pygments_lexer": "ipython3",
469
+ "version": "3.11.0"
470
+ }
471
+ },
472
+ "nbformat": 4,
473
+ "nbformat_minor": 2
474
+ }
mill.mat ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:71486a857939d1416c86c7cf0c469d5e69c7c30495e01ec8a0e13aafd2a313cb
3
+ size 72575144