Skip to content

Commit f3c8be8

Browse files
committed
...
1 parent 778290e commit f3c8be8

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

tests/__init__.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@
1717
import numpy as np
1818
import torch
1919

20-
from pytorch_lightning.utilities import _TORCH_LOWER_EQUAL_1_4, _TORCH_QUANTIZE_AVAILABLE
20+
logging.basicConfig(level=logging.ERROR)
21+
22+
from pytorch_lightning.utilities import _TORCH_LOWER_EQUAL_1_4, _TORCH_QUANTIZE_AVAILABLE # noqa: E402
2123

2224
_TEST_ROOT = os.path.dirname(__file__)
2325
_PROJECT_ROOT = os.path.dirname(_TEST_ROOT)
@@ -36,10 +38,7 @@
3638
if not os.path.isdir(_TEMP_PATH):
3739
os.mkdir(_TEMP_PATH)
3840

39-
logging.basicConfig(level=logging.ERROR)
40-
4141
_MISS_QUANT_DEFAULT = 'fbgemm' not in torch.backends.quantized.supported_engines
42-
4342
_SKIPIF_ARGS_PT_LE_1_4 = dict(condition=_TORCH_LOWER_EQUAL_1_4, reason="test pytorch > 1.4")
4443
_SKIPIF_ARGS_NO_GPU = dict(condition=not torch.cuda.is_available(), reason="test requires single-GPU machine")
4544
_SKIPIF_ARGS_NO_GPUS = dict(condition=torch.cuda.device_count() < 2, reason="test requires multi-GPU machine")

0 commit comments

Comments
 (0)