forked from OpenHUTB/nn
-
Notifications
You must be signed in to change notification settings - Fork 0
32 lines (28 loc) · 1.2 KB
/
python_test.yml
File metadata and controls
32 lines (28 loc) · 1.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# 参考:https://github.com/Tiryoh/actions-mkdocs
name: Testing
on: [repository_dispatch]
jobs:
build:
name: Test Python script
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
# 任务名称:设置Python环境
- name: Set up Python
# This is the version of the action for setting up Python, not the Python version.
uses: actions/setup-python@v5
with:
python-version: '3.9' # 指定python版本
# Optional - x64 or x86 architecture, defaults to x64
architecture: 'x64'
- name: Install Python dependencies
run: python -m pip install -r requirements.txt
- name: Python script testing
# working-directory: ./src
run: |
cd src/chap01_warmup && python numpy_tutorial.py && cd ../..
cd src/chap02_linear_regression && python exercise-linear_regression.py && cd ../..
cd src/chap02_linear_regression && python linear_regression-tf2.0.py && cd ../..
cd src/chap03_softmax_regression && python logistic_regression-exercise.py && cd ../..
cd src/chap03_softmax_regression && python softmax_regression-exercise.py && cd ../..