Spaces:
Sleeping
Sleeping
Upload 3 files
Browse files- ag4masses-public.ipynb +48 -268
- download.sh +5 -3
- problems.txt +44 -0
ag4masses-public.ipynb
CHANGED
@@ -1,218 +1,5 @@
|
|
1 |
{
|
2 |
"cells": [
|
3 |
-
{
|
4 |
-
"cell_type": "code",
|
5 |
-
"execution_count": 10,
|
6 |
-
"metadata": {
|
7 |
-
"executionInfo": {
|
8 |
-
"elapsed": 611,
|
9 |
-
"status": "ok",
|
10 |
-
"timestamp": 1733595497864,
|
11 |
-
"user": {
|
12 |
-
"displayName": "Tong Peng",
|
13 |
-
"userId": "14680520704856526492"
|
14 |
-
},
|
15 |
-
"user_tz": 300
|
16 |
-
},
|
17 |
-
"id": "-IHoHd-t5sLP"
|
18 |
-
},
|
19 |
-
"outputs": [],
|
20 |
-
"source": [
|
21 |
-
"import sys, os\n",
|
22 |
-
"\n",
|
23 |
-
"AG4MDIR='/home/user/app/aglib/ag4masses'\n",
|
24 |
-
"AGLIB=f'/home/user/app/aglib/'\n",
|
25 |
-
"AGDIR=f\"{AG4MDIR}/alphageometry\"\n",
|
26 |
-
"MELIAD_PATH=f\"{AGLIB}/meliad\"\n",
|
27 |
-
"DATA=f\"{AGLIB}/ag_ckpt_vocab\"\n",
|
28 |
-
"TESTDIR=f\"/data/ag4mtest\""
|
29 |
-
]
|
30 |
-
},
|
31 |
-
{
|
32 |
-
"cell_type": "markdown",
|
33 |
-
"metadata": {
|
34 |
-
"id": "ASgGFu0NYHUH"
|
35 |
-
},
|
36 |
-
"source": [
|
37 |
-
"# Download Files"
|
38 |
-
]
|
39 |
-
},
|
40 |
-
{
|
41 |
-
"cell_type": "code",
|
42 |
-
"execution_count": null,
|
43 |
-
"metadata": {},
|
44 |
-
"outputs": [],
|
45 |
-
"source": [
|
46 |
-
"# Run this cell to refresh code and get the latest versions\n",
|
47 |
-
"# AG4MDIR and MELIAD_PATH are in /kaggle/working and will be saved as outputs of the Notebook\n",
|
48 |
-
"# !rm -fr {AG4MDIR} {MELIAD_PATH}"
|
49 |
-
]
|
50 |
-
},
|
51 |
-
{
|
52 |
-
"cell_type": "code",
|
53 |
-
"execution_count": null,
|
54 |
-
"metadata": {
|
55 |
-
"executionInfo": {
|
56 |
-
"elapsed": 5,
|
57 |
-
"status": "ok",
|
58 |
-
"timestamp": 1733594216384,
|
59 |
-
"user": {
|
60 |
-
"displayName": "Tong Peng",
|
61 |
-
"userId": "14680520704856526492"
|
62 |
-
},
|
63 |
-
"user_tz": 300
|
64 |
-
},
|
65 |
-
"id": "GgR_vO8XX9Vr"
|
66 |
-
},
|
67 |
-
"outputs": [],
|
68 |
-
"source": [
|
69 |
-
"if not os.path.exists(MELIAD_PATH):\n",
|
70 |
-
" !git clone https://github.com/google-research/meliad.git {MELIAD_PATH}\n",
|
71 |
-
"\n",
|
72 |
-
"if not os.path.exists(AG4MDIR):\n",
|
73 |
-
" !git clone https://github.com/tpgh24/ag4masses.git {AG4MDIR}\n",
|
74 |
-
"\n",
|
75 |
-
"# Temporarily modified files, upload into dataset tmpfiles\n",
|
76 |
-
"# !cp /kaggle/input/tmpfiles/numericals.py {AGDIR}\n",
|
77 |
-
"# !cp /kaggle/input/tmpfiles/alphageometry.py {AGDIR}\n",
|
78 |
-
"\n",
|
79 |
-
"if not os.path.exists(TESTDIR):\n",
|
80 |
-
" !mkdir {TESTDIR}"
|
81 |
-
]
|
82 |
-
},
|
83 |
-
{
|
84 |
-
"cell_type": "code",
|
85 |
-
"execution_count": null,
|
86 |
-
"metadata": {
|
87 |
-
"executionInfo": {
|
88 |
-
"elapsed": 40247,
|
89 |
-
"status": "ok",
|
90 |
-
"timestamp": 1733594312243,
|
91 |
-
"user": {
|
92 |
-
"displayName": "Tong Peng",
|
93 |
-
"userId": "14680520704856526492"
|
94 |
-
},
|
95 |
-
"user_tz": 300
|
96 |
-
},
|
97 |
-
"id": "gP4zAZh2MHcv",
|
98 |
-
"outputId": "4796397b-8952-411e-bd33-8fd813865735"
|
99 |
-
},
|
100 |
-
"outputs": [],
|
101 |
-
"source": [
|
102 |
-
"if not os.path.exists(DATA):\n",
|
103 |
-
" # download data: vocabulary, trained model\n",
|
104 |
-
" !mkdir {DATA}\n",
|
105 |
-
"\n",
|
106 |
-
" ### Convoluted process. This does no work, seems due to Google Drive restrictions\n",
|
107 |
-
" # !gdown --folder https://bit.ly/alphageometry/\n",
|
108 |
-
" #\n",
|
109 |
-
" ### First got file links from Google Drive web UI, under Share menu. It will download HTML files with download button. Extract URL from the file.\n",
|
110 |
-
" ### For checkpoint_10999999, because the file is big, there is an additional step asking for confirmation, got the final URL from the 2nd HTML,\n",
|
111 |
-
" ### Link constructed using AI from HTML form.\n",
|
112 |
-
" # !gdown https://drive.google.com/file/d/1mRd6J0UkeWoFUjeVB7BQi5lVNLvPBe31/view?usp=drive_link -O {AGLIB}/ag_ckpt_vocab/geometry.757.vocab\n",
|
113 |
-
" # !gdown https://drive.google.com/file/d/1t-r3KfU8aDbS1UHpdyM3LH21rwSCIXTz/view?usp=drive_link -O {AGLIB}/ag_ckpt_vocab/geometry.757.model\n",
|
114 |
-
" # !gdown https://drive.google.com/file/d/1qXkmmgoJ8oTYJdFV1xw0xGPpQj6SyOYA/view?usp=drive_link -O {AGLIB}/ag_ckpt_vocab/checkpoint_10999999\n",
|
115 |
-
"\n",
|
116 |
-
" !wget -O {DATA}/geometry.757.vocab \"https://drive.usercontent.google.com/uc?id=1mRd6J0UkeWoFUjeVB7BQi5lVNLvPBe31&export=download\"\n",
|
117 |
-
" !wget -O {DATA}/geometry.757.model \"https://drive.usercontent.google.com/uc?id=1t-r3KfU8aDbS1UHpdyM3LH21rwSCIXTz&export=download\"\n",
|
118 |
-
" !wget -O {DATA}/checkpoint_10999999 \"https://drive.usercontent.google.com/download?id=1qXkmmgoJ8oTYJdFV1xw0xGPpQj6SyOYA&export=download&confirm=t&uuid=ae22f4de-cb77-4145-af5f-8cfbb59e867e\"\n",
|
119 |
-
"\n",
|
120 |
-
"!ls -l {DATA}"
|
121 |
-
]
|
122 |
-
},
|
123 |
-
{
|
124 |
-
"cell_type": "markdown",
|
125 |
-
"metadata": {},
|
126 |
-
"source": [
|
127 |
-
"# Setup Env"
|
128 |
-
]
|
129 |
-
},
|
130 |
-
{
|
131 |
-
"cell_type": "code",
|
132 |
-
"execution_count": null,
|
133 |
-
"metadata": {
|
134 |
-
"executionInfo": {
|
135 |
-
"elapsed": 14190,
|
136 |
-
"status": "ok",
|
137 |
-
"timestamp": 1733594230570,
|
138 |
-
"user": {
|
139 |
-
"displayName": "Tong Peng",
|
140 |
-
"userId": "14680520704856526492"
|
141 |
-
},
|
142 |
-
"user_tz": 300
|
143 |
-
},
|
144 |
-
"id": "X8Aj3G0neT6K",
|
145 |
-
"outputId": "9538ceba-8065-44d6-a32f-35127e5f2575"
|
146 |
-
},
|
147 |
-
"outputs": [],
|
148 |
-
"source": [
|
149 |
-
"# Python packages for AlphaGeometry\n",
|
150 |
-
"!pip cache purge\n",
|
151 |
-
"!pip install --upgrade pip\n",
|
152 |
-
"!pip install --upgrade packaging setuptools setuptools_scm wheel \n",
|
153 |
-
"!pip install --require-hashes --no-deps -r {AG4MDIR}/alphageometry/requirements.txt"
|
154 |
-
]
|
155 |
-
},
|
156 |
-
{
|
157 |
-
"cell_type": "code",
|
158 |
-
"execution_count": null,
|
159 |
-
"metadata": {
|
160 |
-
"executionInfo": {
|
161 |
-
"elapsed": 15694,
|
162 |
-
"status": "ok",
|
163 |
-
"timestamp": 1733594246256,
|
164 |
-
"user": {
|
165 |
-
"displayName": "Tong Peng",
|
166 |
-
"userId": "14680520704856526492"
|
167 |
-
},
|
168 |
-
"user_tz": 300
|
169 |
-
},
|
170 |
-
"id": "u9fuBSr2qEwN",
|
171 |
-
"outputId": "97bbce78-8b49-4d3b-a831-d188a4a9e536"
|
172 |
-
},
|
173 |
-
"outputs": [],
|
174 |
-
"source": [
|
175 |
-
"# Python packages for Nvidia gpu.\n",
|
176 |
-
"# The versions of Python packages used by AlphaGeometry seem to only work with Cuda 11, not 12\n",
|
177 |
-
"!pip install -U \"jax==0.4.6\" \"jaxlib[cuda11_cudnn86]==0.4.6\" -f https://storage.googleapis.com/jax-releases/jax_cuda_releases.html\n",
|
178 |
-
"!pip install nvidia-cuda-runtime-cu11\n",
|
179 |
-
"!pip install nvidia-pyindex\n",
|
180 |
-
"# !pip list"
|
181 |
-
]
|
182 |
-
},
|
183 |
-
{
|
184 |
-
"cell_type": "code",
|
185 |
-
"execution_count": null,
|
186 |
-
"metadata": {},
|
187 |
-
"outputs": [],
|
188 |
-
"source": [
|
189 |
-
"# Linux packages for Nvidia gpu.\n",
|
190 |
-
"# The versions of Python packages used by AlphaGeometry seem to only work with Cuda 11, not 12\n",
|
191 |
-
"!apt-get update\n",
|
192 |
-
"!DEBIAN_FRONTEND=noninteractive apt install -y cuda-11-8\n",
|
193 |
-
"# !apt list|grep cuda"
|
194 |
-
]
|
195 |
-
},
|
196 |
-
{
|
197 |
-
"cell_type": "code",
|
198 |
-
"execution_count": null,
|
199 |
-
"metadata": {
|
200 |
-
"id": "fChy49CNhf01"
|
201 |
-
},
|
202 |
-
"outputs": [],
|
203 |
-
"source": [
|
204 |
-
"# Information about Nvidia drivers\n",
|
205 |
-
"!nvcc --version\n",
|
206 |
-
"!nvidia-smi"
|
207 |
-
]
|
208 |
-
},
|
209 |
-
{
|
210 |
-
"cell_type": "code",
|
211 |
-
"execution_count": null,
|
212 |
-
"metadata": {},
|
213 |
-
"outputs": [],
|
214 |
-
"source": []
|
215 |
-
},
|
216 |
{
|
217 |
"cell_type": "markdown",
|
218 |
"metadata": {},
|
@@ -243,7 +30,7 @@
|
|
243 |
},
|
244 |
{
|
245 |
"cell_type": "code",
|
246 |
-
"execution_count":
|
247 |
"metadata": {},
|
248 |
"outputs": [],
|
249 |
"source": [
|
@@ -251,6 +38,34 @@
|
|
251 |
"PROB='imo-2024-q4'\n"
|
252 |
]
|
253 |
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
254 |
{
|
255 |
"cell_type": "markdown",
|
256 |
"metadata": {
|
@@ -262,7 +77,7 @@
|
|
262 |
},
|
263 |
{
|
264 |
"cell_type": "code",
|
265 |
-
"execution_count":
|
266 |
"metadata": {},
|
267 |
"outputs": [],
|
268 |
"source": [
|
@@ -337,21 +152,25 @@
|
|
337 |
"cd $AG4MDIR\n",
|
338 |
"python -m alphageometry \\\n",
|
339 |
"--alsologtostderr \\\n",
|
340 |
-
"--problems_file=$
|
341 |
"--problem_name=$PROB \\\n",
|
342 |
"--mode=$MODEL \\\n",
|
343 |
"\"${DDAR_ARGS[@]}\" \\\n",
|
344 |
"\"${SEARCH_ARGS[@]}\" \\\n",
|
345 |
"\"${LM_ARGS[@]}\" \\\n",
|
346 |
"--out_file=$OUTFILE \\\n",
|
347 |
-
"--n_workers=$NWORKERS
|
|
|
|
|
|
|
|
|
348 |
"\n",
|
349 |
"'''"
|
350 |
]
|
351 |
},
|
352 |
{
|
353 |
"cell_type": "code",
|
354 |
-
"execution_count":
|
355 |
"metadata": {},
|
356 |
"outputs": [
|
357 |
{
|
@@ -362,6 +181,16 @@
|
|
362 |
"+ ERRFILE=/data/ag4mtest/imo-2024-q4.log\n",
|
363 |
"+ exec\n"
|
364 |
]
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
365 |
}
|
366 |
],
|
367 |
"source": [
|
@@ -405,61 +234,12 @@
|
|
405 |
"\n"
|
406 |
]
|
407 |
},
|
408 |
-
{
|
409 |
-
"cell_type": "code",
|
410 |
-
"execution_count": 6,
|
411 |
-
"metadata": {},
|
412 |
-
"outputs": [],
|
413 |
-
"source": [
|
414 |
-
"#!cat /kaggle/input/tmpfiles/test-problems.txt"
|
415 |
-
]
|
416 |
-
},
|
417 |
{
|
418 |
"cell_type": "code",
|
419 |
"execution_count": null,
|
420 |
"metadata": {},
|
421 |
"outputs": [],
|
422 |
-
"source": [
|
423 |
-
"# In an interactive Kaggle session, run this to see the log file. We can cancel this cell's execution\n",
|
424 |
-
"# to do other things in the Notebook\n",
|
425 |
-
"if os.environ[\"KAGGLE_KERNEL_RUN_TYPE\"] != \"Batch\":\n",
|
426 |
-
" !tail -f {TESTDIR}/{PROB}.log"
|
427 |
-
]
|
428 |
-
},
|
429 |
-
{
|
430 |
-
"cell_type": "code",
|
431 |
-
"execution_count": null,
|
432 |
-
"metadata": {},
|
433 |
-
"outputs": [],
|
434 |
-
"source": [
|
435 |
-
"# Command to kill the background job in an interactive session\n",
|
436 |
-
"# !pkill -P `ps -ef|grep -- '-m alphageometry'|grep -v grep|awk '{printf \"%d,%d\", $2, $3}'`\n",
|
437 |
-
"\n",
|
438 |
-
"# Command to check processes\n",
|
439 |
-
"### |cat to show full commandline\n",
|
440 |
-
"# !ps -eo pid,ppid,pgid,%cpu,cmd |cat\n",
|
441 |
-
"# !ps -ef|cat"
|
442 |
-
]
|
443 |
-
},
|
444 |
-
{
|
445 |
-
"cell_type": "code",
|
446 |
-
"execution_count": null,
|
447 |
-
"metadata": {},
|
448 |
-
"outputs": [],
|
449 |
-
"source": [
|
450 |
-
"# Command to check progress of a running job in an interactive session\n",
|
451 |
-
"# !bash {AG4MDIR}/utils/checkprog.sh {TESTDIR}/{PROB}.log"
|
452 |
-
]
|
453 |
-
},
|
454 |
-
{
|
455 |
-
"cell_type": "code",
|
456 |
-
"execution_count": null,
|
457 |
-
"metadata": {},
|
458 |
-
"outputs": [],
|
459 |
-
"source": [
|
460 |
-
"# In Batch run, after the job completes, list output files\n",
|
461 |
-
"!ls -ltr {TESTDIR}"
|
462 |
-
]
|
463 |
}
|
464 |
],
|
465 |
"metadata": {
|
|
|
1 |
{
|
2 |
"cells": [
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
{
|
4 |
"cell_type": "markdown",
|
5 |
"metadata": {},
|
|
|
30 |
},
|
31 |
{
|
32 |
"cell_type": "code",
|
33 |
+
"execution_count": 1,
|
34 |
"metadata": {},
|
35 |
"outputs": [],
|
36 |
"source": [
|
|
|
38 |
"PROB='imo-2024-q4'\n"
|
39 |
]
|
40 |
},
|
41 |
+
{
|
42 |
+
"cell_type": "code",
|
43 |
+
"execution_count": 2,
|
44 |
+
"metadata": {
|
45 |
+
"executionInfo": {
|
46 |
+
"elapsed": 611,
|
47 |
+
"status": "ok",
|
48 |
+
"timestamp": 1733595497864,
|
49 |
+
"user": {
|
50 |
+
"displayName": "Tong Peng",
|
51 |
+
"userId": "14680520704856526492"
|
52 |
+
},
|
53 |
+
"user_tz": 300
|
54 |
+
},
|
55 |
+
"id": "-IHoHd-t5sLP"
|
56 |
+
},
|
57 |
+
"outputs": [],
|
58 |
+
"source": [
|
59 |
+
"import sys, os\n",
|
60 |
+
"\n",
|
61 |
+
"AG4MDIR='/home/user/app/aglib/ag4masses'\n",
|
62 |
+
"AGLIB=f'/home/user/app/aglib/'\n",
|
63 |
+
"AGDIR=f\"{AG4MDIR}/alphageometry\"\n",
|
64 |
+
"MELIAD_PATH=f\"{AGLIB}/meliad\"\n",
|
65 |
+
"DATA=f\"{AGLIB}/ag_ckpt_vocab\"\n",
|
66 |
+
"TESTDIR=f\"/data/ag4mtest\""
|
67 |
+
]
|
68 |
+
},
|
69 |
{
|
70 |
"cell_type": "markdown",
|
71 |
"metadata": {
|
|
|
77 |
},
|
78 |
{
|
79 |
"cell_type": "code",
|
80 |
+
"execution_count": 6,
|
81 |
"metadata": {},
|
82 |
"outputs": [],
|
83 |
"source": [
|
|
|
152 |
"cd $AG4MDIR\n",
|
153 |
"python -m alphageometry \\\n",
|
154 |
"--alsologtostderr \\\n",
|
155 |
+
"--problems_file=$PROBFILE \\\n",
|
156 |
"--problem_name=$PROB \\\n",
|
157 |
"--mode=$MODEL \\\n",
|
158 |
"\"${DDAR_ARGS[@]}\" \\\n",
|
159 |
"\"${SEARCH_ARGS[@]}\" \\\n",
|
160 |
"\"${LM_ARGS[@]}\" \\\n",
|
161 |
"--out_file=$OUTFILE \\\n",
|
162 |
+
"--n_workers=$NWORKERS 2>&1\n",
|
163 |
+
"\n",
|
164 |
+
"echo =======================================\n",
|
165 |
+
"echo Task Done.\n",
|
166 |
+
"echo See ag4mtest/$PROB.out and ag4mtest/$PROB.log for more information\n",
|
167 |
"\n",
|
168 |
"'''"
|
169 |
]
|
170 |
},
|
171 |
{
|
172 |
"cell_type": "code",
|
173 |
+
"execution_count": 7,
|
174 |
"metadata": {},
|
175 |
"outputs": [
|
176 |
{
|
|
|
181 |
"+ ERRFILE=/data/ag4mtest/imo-2024-q4.log\n",
|
182 |
"+ exec\n"
|
183 |
]
|
184 |
+
},
|
185 |
+
{
|
186 |
+
"data": {
|
187 |
+
"text/plain": [
|
188 |
+
"256"
|
189 |
+
]
|
190 |
+
},
|
191 |
+
"execution_count": 7,
|
192 |
+
"metadata": {},
|
193 |
+
"output_type": "execute_result"
|
194 |
}
|
195 |
],
|
196 |
"source": [
|
|
|
234 |
"\n"
|
235 |
]
|
236 |
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
237 |
{
|
238 |
"cell_type": "code",
|
239 |
"execution_count": null,
|
240 |
"metadata": {},
|
241 |
"outputs": [],
|
242 |
+
"source": []
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
243 |
}
|
244 |
],
|
245 |
"metadata": {
|
download.sh
CHANGED
@@ -22,6 +22,8 @@ export DATA=ag_ckpt_vocab
|
|
22 |
|
23 |
cd /home/user/app
|
24 |
# some patch for cpu
|
25 |
-
cp models.py /home/user/app/aglib/ag4masses/alphageometry/models.py
|
26 |
-
cp lm_inference.py /home/user/app/aglib/ag4masses/alphageometry/lm_inference.py
|
27 |
-
cp ag4masses-public.ipynb /data/ag4masses-public.ipynb
|
|
|
|
|
|
22 |
|
23 |
cd /home/user/app
|
24 |
# some patch for cpu
|
25 |
+
# cp models.py /home/user/app/aglib/ag4masses/alphageometry/models.py
|
26 |
+
# cp lm_inference.py /home/user/app/aglib/ag4masses/alphageometry/lm_inference.py
|
27 |
+
cp ag4masses-public.ipynb /data/ag4masses-public.ipynb
|
28 |
+
cp problems.txt /data/problems.txt
|
29 |
+
mkdir /data/ag4mtest
|
problems.txt
ADDED
@@ -0,0 +1,44 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
angbisec_bline_cyclic
|
2 |
+
a b c = triangle; f = on_bline f b c, angle_bisector f b a c ? cyclic a b c f
|
3 |
+
9point_part1
|
4 |
+
a b c = triangle a b c; d = foot d a b c; e = midpoint e b a; f = midpoint f c b; g = midpoint g a c ? cyclic d g e f
|
5 |
+
9point_part2
|
6 |
+
a b c = triangle a b c; o = orthocenter o a b c; e = midpoint e b a; f = midpoint f c b; g = midpoint g a c; h = midpoint h a o ? cyclic e f g h
|
7 |
+
castillon_4p
|
8 |
+
a b c d = quadrangle; o z = segment; x = on_line a z, on_circle o z; u = on_circum z b x, on_line a b; y = on_line d z, on_circle o z; v = on_circum z c y, on_line c d; w = on_line a b, on_line c d; p = on_circum w u v, on_circle o z; q = on_line p a, on_circle o z; s = on_line p d, on_circle o z; r = on_line q b, on_line s c ? cong o z o r
|
9 |
+
castillon_lemma_ddar_ok
|
10 |
+
a c = segment; b = on_circle b a c; d = on_line a c, lc_tangent d b a; e = foot e b a c; f = on_circle f a c; g = on_tline g d a c, lc_tangent g f a; h = on_line d g, on_line e f; i = on_circle a c; j = on_circle a c, on_line i g; k = on_circle a c, on_line i h ? coll e j k
|
11 |
+
napoleon_ddar_ok
|
12 |
+
a1 a2 a3 = triangle; b3 = on_circle a1 a2, s_angle a1 a2 b3 60; b1 = on_circle a2 a3, s_angle a2 a3 b1 60; b2 = on_circle a3 a1, s_angle a3 a1 b2 60; c1 = circumcenter b1 a2 a3; c2 = circumcenter b2 a3 a1; c3 = circumcenter b3 a1 a2 ? cong c1 c2 c1 c3
|
13 |
+
napoleon2
|
14 |
+
a1 a2 a3 = triangle; c3 = s_angle a1 a2 c3 30, s_angle a2 a1 c3 150; c1 = s_angle a2 a3 c1 30, s_angle a3 a2 c1 150; c2 = s_angle a3 a1 c2 30, s_angle a1 a3 c2 150 ? cong c1 c2 c1 c3
|
15 |
+
ceva
|
16 |
+
a b c = triangle; d = free; e = on_line b c, on_line a d; f = on_line c a, on_line b d; g = on_line a b, on_line c d; h = on_line c a, on_pline h b e f ? eqratio f h f a g b g a
|
17 |
+
ceva_hint_ddar_ok
|
18 |
+
a b c = triangle; d = free; e = on_line b c, on_line a d; f = on_line c a, on_line b d; g = on_line a b, on_line c d; h = on_line c a, on_pline h b e f; i = on_line b d, on_pline i a b c; j = on_line a i, on_line c d ? eqratio f h f a g b g a
|
19 |
+
ceva_menelaus_hint_ddar_ok
|
20 |
+
a b c = triangle; d = free; e = on_line b c, on_line a d; f = on_line c a, on_line b d; g = on_line a b, on_line c d; h = on_line c a, on_pline h b e f; i = on_line c d, on_pline i e a b; j = on_line b f, on_pline j e a c ? eqratio f h f a g b g a
|
21 |
+
square_angle15
|
22 |
+
a b c d = isquare a b c d; e = s_angle c d e 15, s_angle d c e -15 ? cong e a a b
|
23 |
+
5circles_ddar_ok
|
24 |
+
p1 p2 p3 p4 p5 = pentagon; q1 = on_line p2 p5, on_line p1 p3; q2 = on_line p1 p3, on_line p2 p4; q3 = on_line p2 p4, on_line p3 p5; q4 = on_line p3 p5, on_line p4 p1; q5 = on_line p4 p1, on_line p2 p5; o1 = circumcenter p1 q1 q5; o2 = circumcenter p2 q1 q2; o3 = circumcenter p3 q2 q3; o4 = circumcenter p4 q3 q4; o5 = circumcenter p5 q4 q5; m1 = on_circle o1 q1, on_circle o2 q1; m2 = on_circle o2 q2, on_circle o3 q2; m3 = on_circle o3 q3, on_circle o4 q3; m4 = on_circle o4 q4, on_circle o5 q4; m5 = on_circle o5 q5, on_circle o1 q5 ? cyclic m1 m2 m3 m5
|
25 |
+
butterfly
|
26 |
+
a = free; b = free; c = on_circle a b; d = midpoint b c; e = on_circle a b; f = on_line d e, on_circle a b; g = on_circle a b; h = on_line d g, on_circle a b; i = on_line b c, on_line f g; j = on_line b c, on_line e h ? cong d i d j
|
27 |
+
gaolian100-6-lemma_ddar_ok
|
28 |
+
a = free; b = free; c = on_circle a b; d = on_circle a b; e = lc_tangent c a, lc_tangent d a; f = midpoint c d; g = on_line e b, on_circle a b ? eqangle f d f g f b f d
|
29 |
+
gaolian100-6
|
30 |
+
a = free; b = free; c = on_circle a b; d = on_circle a b; e = lc_tangent c a, lc_tangent d a; f = foot d a b; g = on_line d f, on_line e b; h = on_line d f, on_line c b ? cong d g g h
|
31 |
+
gaolian100-12
|
32 |
+
a = free; b = free; c = midpoint a b; d = on_circle c a; e = on_circle c a; f = on_tline f b b a, on_line d e; g = on_line a e, on_line c f; h = on_line a d, on_line c f ? cong c g c h
|
33 |
+
gaolian100-26
|
34 |
+
a b c = triangle a b c; d = angle_bisector d b a c, on_circum d a b c; e = circumcenter e a b c; f = on_line f a b, on_pline f e b d; g = on_line g a c, on_pline g e c d; h = orthocenter h a b c; i = on_line i b c, on_pline i h a d ? cong f b f i
|
35 |
+
gaolian100-26-hint_ddar_ok
|
36 |
+
a b c = triangle a b c; d = angle_bisector d b a c, on_circum d a b c; e = circumcenter e a b c; f = on_line f a b, on_pline f e b d; g = on_line g a c, on_pline g e c d; h = orthocenter h a b c; i = on_line i b c, on_pline i h a d; j = on_line e c, eqdistance j e e c ? cong f b f i
|
37 |
+
gaolian100-98
|
38 |
+
a b c d = quadrangle; e = on_line b c; f = on_line c d, on_aline f a d b a e; g = on_line b f, on_line d e ? eqangle a e a c a g a f
|
39 |
+
pascal
|
40 |
+
a = free; b = free; c = on_circle a b; d = on_circle a b; e = on_circle a b; f = on_circle a b; g = on_circle a b; h = intersection_ll b c e f; i = intersection_ll c d f g; j = intersection_ll d e g b ? coll h i j
|
41 |
+
pascal_3p
|
42 |
+
a = free; b = free; c = on_circle a b; d = on_circle a b; e = lc_tangent b a, on_line c d; f = lc_tangent c a, on_line d b; g = lc_tangent d a, on_line b c ? coll e f g
|
43 |
+
imo-2024-q4
|
44 |
+
a b c = triangle; i = incenter a b c; f = foot i a c; g = foot i a b; m = on_line i f, on_circle i f; n = on_line i g, on_circle i g; x = on_line b c, on_pline x m a c; y = on_line b c, on_pline y n a b; k = midpoint a c; l = midpoint a b; p = on_line a i, on_circum a b c ? eqangle p y p x i l i k
|