Skip to content

Disable stable_diffusion benchmark for Pixel backend #2653

Disable stable_diffusion benchmark for Pixel backend

Disable stable_diffusion benchmark for Pixel backend #2653

name: Format & lint
on:
push:
branches: [ master, submission-v* ]
pull_request:
types: [ opened, synchronize, reopened ]
merge_group:
types: [ checks_requested ]
jobs:
build-image:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Checkout repository
uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@e468171a9de216ec08956ac3ada2f0791b6bd435 # v3.11.1
- name: Log in to the Container registry
uses: docker/login-action@184bdaa0721073962dff0199f1fb9940f07167d1 # v3.5.0
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Extract metadata (tags, labels) for Docker
id: meta
uses: docker/metadata-action@c1e51972afc2121e065aed6d45c65596fe445f3f # v5.8.0
with:
images: ghcr.io/mlcommons/mobile_app_open-formatter
flavor: latest=true
tags: type=raw,value=${{ github.run_number }}
- name: Build and push Docker image
uses: docker/build-push-action@ca052bb54ab0790a636c9b5f226502c73d547a25 # v5.4.0
with:
context: tools/formatter
file: tools/formatter/Dockerfile
push: true
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
cache-from: type=gha
cache-to: type=gha,mode=max
bazel:
needs: build-image
runs-on: ubuntu-latest
container:
image: ghcr.io/mlcommons/mobile_app_open-formatter:${{ github.run_number }}
timeout-minutes: 10
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: configure Git
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: bazel
run: make lint/bazel
cpp:
name: C++
needs: build-image
runs-on: ubuntu-latest
container:
image: ghcr.io/mlcommons/mobile_app_open-formatter:${{ github.run_number }}
timeout-minutes: 10
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: configure Git
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: clang
run: make lint/clang
dart:
needs: build-image
runs-on: ubuntu-latest
container:
image: ghcr.io/mlcommons/mobile_app_open-formatter:${{ github.run_number }}
timeout-minutes: 10
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: configure Git
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: Cache Flutter packages
uses: actions/cache@0400d5f644dc74513175e3cd8d07132dd4860809 # v4.2.4
with:
path: /home/mlperf/.pub-cache
key: ${{ runner.os }}-pub-cache-${{ hashFiles('**/pubspec.lock') }}
restore-keys: ${{ runner.os }}-pub-cache-
- name: flutter/prepare
run: make flutter/prepare
- name: pub-get
run: make format/dart/pub-get
- name: lint/dart
run: make lint/dart
swift:
needs: build-image
runs-on: ubuntu-latest
container:
image: ghcr.io/mlcommons/mobile_app_open-formatter:${{ github.run_number }}
timeout-minutes: 10
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: configure Git
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: swift
run: make lint/swift
markdown:
needs: build-image
runs-on: ubuntu-latest
container:
image: ghcr.io/mlcommons/mobile_app_open-formatter:${{ github.run_number }}
timeout-minutes: 10
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: configure Git
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: markdown-format
run: make lint/markdown
pbtxt:
needs: build-image
runs-on: ubuntu-latest
container:
image: ghcr.io/mlcommons/mobile_app_open-formatter:${{ github.run_number }}
timeout-minutes: 10
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: configure Git
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: pbtxt
run: make lint/pbtxt
yaml:
needs: build-image
runs-on: ubuntu-latest
container:
image: ghcr.io/mlcommons/mobile_app_open-formatter:${{ github.run_number }}
timeout-minutes: 10
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: configure Git
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: yaml
run: make lint/yaml
ts:
name: TypeScript
needs: build-image
runs-on: ubuntu-latest
container:
image: ghcr.io/mlcommons/mobile_app_open-formatter:${{ github.run_number }}
timeout-minutes: 10
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: configure Git
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: typescripts
run: make lint/ts
misc:
needs: build-image
runs-on: ubuntu-latest
container:
image: ghcr.io/mlcommons/mobile_app_open-formatter:${{ github.run_number }}
timeout-minutes: 10
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3.6.0
- name: configure Git
run: git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: prohibited-extensions
run: make lint/prohibited-extensions
- name: big-files
run: make lint/big-files
- name: line-endings
run: make lint/line-endings