torchscript_consistency_cuda_test.py 718 Bytes
Newer Older
1
2
3
import torch

from . import common_utils
4
from .torchscript_consistency_impl import Functional, Transforms
5
6


7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
@common_utils.skipIfNoCuda
class TestFunctionalFloat32(Functional, common_utils.TestCase):
    dtype = torch.float32
    device = torch.device('cuda')


@common_utils.skipIfNoCuda
class TestFunctionalFloat64(Functional, common_utils.TestCase):
    dtype = torch.float64
    device = torch.device('cuda')


@common_utils.skipIfNoCuda
class TestTransformsFloat32(Transforms, common_utils.TestCase):
    dtype = torch.float32
    device = torch.device('cuda')


@common_utils.skipIfNoCuda
class TestTransformsFloat64(Transforms, common_utils.TestCase):
    dtype = torch.float64
    device = torch.device('cuda')