Skip to content

Commit

Permalink
install Pillow font for gh actions (#34)
Browse files Browse the repository at this point in the history
* try to fix

* undo skip for gh actions

* remove gh action check
  • Loading branch information
tlpss committed Oct 25, 2023
1 parent 15648f7 commit bc570d0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/pytest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@ jobs:
runs-on: "ubuntu-latest"
steps:
- uses: actions/checkout@v2
- name: install fonts for Pillow
run: |
sudo apt-get install fonts-freefont-ttf
- name: install conda env with micromamba
uses: mamba-org/provision-with-micromamba@main
with:
Expand Down
5 changes: 0 additions & 5 deletions test/test_detector.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import os
import unittest

import pytest
import torch
from pytorch_lightning.loggers import WandbLogger
from torch import nn
Expand Down Expand Up @@ -101,10 +100,6 @@ def test_model_init_heatmaps(self):
self.assertTrue(torch.mean(heatmap).item() < 0.1)
self.assertTrue(torch.var(heatmap).item() < 0.1)

# TODO: chcek if we can run it on gh actions as well.
IN_GITHUB_ACTIONS = os.getenv("GITHUB_ACTIONS") == "true"

@pytest.mark.skipif(IN_GITHUB_ACTIONS, reason="Test doesn't work in Github Actions atm")
def test_checkpoint_loading(self):
wandb_logger = WandbLogger(dir=get_wandb_log_dir_path(), mode="offline")

Expand Down

0 comments on commit bc570d0

Please sign in to comment.