Skip to content

Commit

Permalink
ENH: update web ui deps & remove deprecated numpy.compat (#835)
Browse files Browse the repository at this point in the history
  • Loading branch information
luweizheng authored Dec 16, 2024
1 parent 68a434a commit 607c3b9
Show file tree
Hide file tree
Showing 5 changed files with 3,693 additions and 6,084 deletions.
2 changes: 1 addition & 1 deletion CI/test_basic_execution.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
def test_basic_cases():
with warnings.catch_warnings():
# "error" help us find the deprecated APIs
warnings.simplefilter("ignore")
warnings.simplefilter("error")
import xorbits
import xorbits.pandas as pd
import xorbits.numpy as np
Expand Down
8 changes: 3 additions & 5 deletions python/xorbits/_mars/tensor/einsum/einsumfunc.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@

import itertools

from numpy.compat import basestring

from ..datasource.array import tensor as astensor

__all__ = ["parse_einsum_input", "einsum_path"]
Expand Down Expand Up @@ -577,7 +575,7 @@ def parse_einsum_input(operands):
if len(operands) == 0:
raise ValueError("No input operands")

if isinstance(operands[0], basestring):
if isinstance(operands[0], str):
subscripts = operands[0].replace(" ", "")
operands = [astensor(v) for v in operands[1:]]

Expand Down Expand Up @@ -855,7 +853,7 @@ def einsum_path(*operands, **kwargs):
memory_limit = None

# No optimization or a named path algorithm
if (path_type is False) or isinstance(path_type, basestring):
if (path_type is False) or isinstance(path_type, str):
pass

# Given an explicit path
Expand All @@ -865,7 +863,7 @@ def einsum_path(*operands, **kwargs):
# Path tuple with memory limit
elif (
(len(path_type) == 2)
and isinstance(path_type[0], basestring)
and isinstance(path_type[0], str)
and isinstance(path_type[1], (int, float))
): # pragma: no cover
memory_limit = int(path_type[1])
Expand Down
Loading

0 comments on commit 607c3b9

Please sign in to comment.