Download scripts/_tmp_counts.py from m-rui001/physics-typst-corpus: direct link, hf CLI and curl.
- Browser
- Download file 248 Bytes
-
https://huggingface.co/datasets/m-rui001/physics-typst-corpus/resolve/main/scripts/_tmp_counts.py
- Command line
-
hf download hf://datasets/m-rui001/physics-typst-corpus/scripts/_tmp_counts.py
-
curl -L -o _tmp_counts.py https://huggingface.co/datasets/m-rui001/physics-typst-corpus/resolve/main/scripts/_tmp_counts.py
248 Bytes
| import re | |
| s = open(r"E:\phys\papers\2203.02139\main.typ", encoding="utf-8").read().split("\n") | |
| for i in (25, 29, 33, 53, 55, 59, 111, 116, 118): | |
| l = s[i-1] | |
| print(i, "@count", len(re.findall(r"@[A-Za-z]", l)), "holes", l.count("#text([])")) | |