Skip to content

Commit 28e94f3

Browse files
committed
use union instead of pipe
1 parent 7e07504 commit 28e94f3

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

toploc/poly.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
from typing import Union
12
import base64
23
from toploc.C.csrc.ndd import compute_newton_coefficients, evaluate_polynomial
34
import torch
@@ -30,7 +31,7 @@ def null(cls, length: int) -> "ProofPoly":
3031

3132
@classmethod
3233
def from_points(
33-
cls, x: list[int] | torch.Tensor, y: list[int] | torch.Tensor
34+
cls, x: Union[list[int], torch.Tensor], y: Union[list[int], torch.Tensor]
3435
) -> "ProofPoly":
3536
if isinstance(x, torch.Tensor):
3637
x = x.tolist()

0 commit comments

Comments
 (0)