[WIP] impl adafactor optimizer #41
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Format Check | |
| on: | |
| push: | |
| branches: [ main ] | |
| paths: | |
| - "**/*.py" | |
| - "**/*.pyi" | |
| - "**/*.c" | |
| - "**/*.cc" | |
| - "**/*.cpp" | |
| - "**/*.h" | |
| - "**/*.hpp" | |
| - "**/*.json" | |
| - "pyproject.toml" | |
| - "setup.cfg" | |
| - ".clang-format" | |
| - ".clang-format-ignore" | |
| - ".github/workflows/format.yml" | |
| pull_request: | |
| branches: [ main ] | |
| paths: | |
| - "**/*.py" | |
| - "**/*.pyi" | |
| - "**/*.c" | |
| - "**/*.cc" | |
| - "**/*.cpp" | |
| - "**/*.h" | |
| - "**/*.hpp" | |
| - "**/*.json" | |
| - "pyproject.toml" | |
| - "setup.cfg" | |
| - ".clang-format" | |
| - ".clang-format-ignore" | |
| - ".github/workflows/format.yml" | |
| jobs: | |
| format: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.12" | |
| - name: Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install black==25.12.0 clang-format==21.1.8 | |
| - name: Check python | |
| run: black --check . | |
| - name: Check C/C++ | |
| run: | | |
| git ls-files '*.c' '*.cc' '*.cpp' '*.h' '*.hpp' '*.json' \ | |
| | xargs clang-format --Werror --dry-run -i |