Datasets:
mickylan2367
commited on
Commit
•
97e6ae0
1
Parent(s):
19df756
Delete delve
Browse files- delve.ipynb +0 -97
delve.ipynb
DELETED
@@ -1,97 +0,0 @@
|
|
1 |
-
{
|
2 |
-
"cells": [
|
3 |
-
{
|
4 |
-
"cell_type": "code",
|
5 |
-
"execution_count": 2,
|
6 |
-
"metadata": {},
|
7 |
-
"outputs": [],
|
8 |
-
"source": [
|
9 |
-
"import os\n",
|
10 |
-
"import pathlib\n",
|
11 |
-
"import glob"
|
12 |
-
]
|
13 |
-
},
|
14 |
-
{
|
15 |
-
"cell_type": "code",
|
16 |
-
"execution_count": 3,
|
17 |
-
"metadata": {},
|
18 |
-
"outputs": [],
|
19 |
-
"source": [
|
20 |
-
"path = glob.glob(\"./train/*.png\")"
|
21 |
-
]
|
22 |
-
},
|
23 |
-
{
|
24 |
-
"cell_type": "code",
|
25 |
-
"execution_count": 4,
|
26 |
-
"metadata": {},
|
27 |
-
"outputs": [
|
28 |
-
{
|
29 |
-
"data": {
|
30 |
-
"text/plain": [
|
31 |
-
"485"
|
32 |
-
]
|
33 |
-
},
|
34 |
-
"execution_count": 4,
|
35 |
-
"metadata": {},
|
36 |
-
"output_type": "execute_result"
|
37 |
-
}
|
38 |
-
],
|
39 |
-
"source": [
|
40 |
-
"len(path)"
|
41 |
-
]
|
42 |
-
},
|
43 |
-
{
|
44 |
-
"cell_type": "code",
|
45 |
-
"execution_count": 7,
|
46 |
-
"metadata": {},
|
47 |
-
"outputs": [
|
48 |
-
{
|
49 |
-
"name": "stdout",
|
50 |
-
"output_type": "stream",
|
51 |
-
"text": [
|
52 |
-
"485\n"
|
53 |
-
]
|
54 |
-
}
|
55 |
-
],
|
56 |
-
"source": [
|
57 |
-
"import json\n",
|
58 |
-
"caption = []\n",
|
59 |
-
"with open(\"./train/metadata.jsonl\", \"r\") as f:\n",
|
60 |
-
" data = f.read()\n",
|
61 |
-
" for l in data.split(\"\\n\"):\n",
|
62 |
-
" caption.append(l)\n",
|
63 |
-
"\n",
|
64 |
-
"print(len(caption))"
|
65 |
-
]
|
66 |
-
},
|
67 |
-
{
|
68 |
-
"cell_type": "code",
|
69 |
-
"execution_count": null,
|
70 |
-
"metadata": {},
|
71 |
-
"outputs": [],
|
72 |
-
"source": []
|
73 |
-
}
|
74 |
-
],
|
75 |
-
"metadata": {
|
76 |
-
"kernelspec": {
|
77 |
-
"display_name": "base",
|
78 |
-
"language": "python",
|
79 |
-
"name": "python3"
|
80 |
-
},
|
81 |
-
"language_info": {
|
82 |
-
"codemirror_mode": {
|
83 |
-
"name": "ipython",
|
84 |
-
"version": 3
|
85 |
-
},
|
86 |
-
"file_extension": ".py",
|
87 |
-
"mimetype": "text/x-python",
|
88 |
-
"name": "python",
|
89 |
-
"nbconvert_exporter": "python",
|
90 |
-
"pygments_lexer": "ipython3",
|
91 |
-
"version": "3.9.12"
|
92 |
-
},
|
93 |
-
"orig_nbformat": 4
|
94 |
-
},
|
95 |
-
"nbformat": 4,
|
96 |
-
"nbformat_minor": 2
|
97 |
-
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|