Initial commit

This commit is contained in:
aaa
2024-10-16 22:29:18 +08:00
commit fc6b22450d
18 changed files with 1206 additions and 0 deletions
+27
View File
@@ -0,0 +1,27 @@
name: Gitea Actions Challenge Test
run-name: 挑战赛自动评测 Actions 🚀
on: [push]
jobs:
Challenge-Actions:
runs-on: ubuntu-latest
steps:
- name: 检出代码
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: 安装依赖
run: |
python -m venv ./.venv
. ./.venv/bin/activate
curl -s -o pip_cache.tar.gz ${{ vars.BACKEND_URL }}/download/pip_cache.tar.gz
tar -zxf pip_cache.tar.gz
pip install -r requirements.txt -i https://pypi.tuna.tsinghua.edu.cn/simple
rm -rf datingTrainSet2.tsv datingTestSet2.tsv main.py
curl -s -o main.py ${{ vars.BACKEND_URL }}/public/challenge/knn/main.py
curl -s -o datingTrainSet2.tsv ${{ vars.BACKEND_URL }}/public/challenge/knn/datingTrainSet2.tsv
curl -s -o datingTestSet2.tsv ${{ vars.BACKEND_URL }}/public/challenge/knn/datingTestSet2.tsv
- name: 评测结果
run: |
. ./.venv/bin/activate
python main.py