fixed type alias
This commit is contained in:
+2
-2
@@ -3,12 +3,12 @@ from typing import TypeAlias
|
|||||||
USE_CUDA = 1
|
USE_CUDA = 1
|
||||||
if USE_CUDA:
|
if USE_CUDA:
|
||||||
import cupy as np
|
import cupy as np
|
||||||
Mat: TypeAlias = np.array
|
Mat: TypeAlias = np.ndarray
|
||||||
def convert(src: Mat):
|
def convert(src: Mat):
|
||||||
return np.asnumpy(src)
|
return np.asnumpy(src)
|
||||||
else:
|
else:
|
||||||
import numpy as np
|
import numpy as np
|
||||||
Mat: TypeAlias = np.array
|
Mat: TypeAlias = np.ndarray
|
||||||
def convert(src: Mat):
|
def convert(src: Mat):
|
||||||
return src
|
return src
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user