Skip to content

Commit ec756f9

Browse files
authoredJul 9, 2024
fix ruff workflow (#105)
* fix ruff workflow * add formatting error * add lint error * revert errors
1 parent cbfd3d4 commit ec756f9

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed
 

‎.github/workflows/ruff.yml

+4-2
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,7 @@ jobs:
44
ruff:
55
runs-on: ubuntu-latest
66
steps:
7-
- uses: actions/checkout@v4
8-
- uses: chartboost/ruff-action@v1
7+
- uses: actions/checkout@v4
8+
- run: pip install --user ruff
9+
- run: ruff check --output-format=github .
10+
- run: ruff format --diff .

‎mokuro/manga_page_ocr.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def __init__(
3737

3838
if not self.disable_ocr:
3939
cuda = torch.cuda.is_available()
40-
device = 'cuda' if cuda and not force_cpu else 'cpu'
40+
device = "cuda" if cuda and not force_cpu else "cpu"
4141
logger.info(f"Initializing text detector, using device {device}")
4242
self.text_detector = TextDetector(
4343
model_path=cache.comic_text_detector, input_size=detector_input_size, device=device, act="leaky"

0 commit comments

Comments
 (0)