-
Notifications
You must be signed in to change notification settings - Fork 200
Expand file tree
/
Copy pathfile.pyi
More file actions
66 lines (60 loc) · 1.76 KB
/
Copy pathfile.pyi
File metadata and controls
66 lines (60 loc) · 1.76 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
# SPDX-License-Identifier: Apache-2.0
# SPDX-FileCopyrightText: Copyright the Vortex contributors
from typing import final
import polars as pl
import pyarrow as pa
from typing_extensions import override
from vortex.type_aliases import IntoProjection
from . import CosStore, HfStore
from .arrays import Array
from .dataset import VortexDataset
from .dtype import DType
from .expr import Expr
from .iter import ArrayIterator
from .scan import RepeatedScan
from .store import ObjectStore
@final
class VortexFile:
def __len__(self) -> int: ...
@property
def dtype(self) -> DType: ...
@property
def path(self) -> str: ...
@override
def __reduce__(self) -> tuple[object, tuple[str, bool]]: ...
def scan(
self,
projection: IntoProjection = None,
*,
expr: Expr | None = None,
limit: int | None = None,
indices: Array | None = None,
batch_size: int | None = None,
) -> ArrayIterator: ...
def prepare(
self,
projection: IntoProjection = None,
*,
expr: Expr | None = None,
limit: int | None = None,
indices: Array | None = None,
batch_size: int | None = None,
) -> RepeatedScan: ...
def to_arrow(
self,
projection: IntoProjection = None,
*,
expr: Expr | None = None,
limit: int | None = None,
batch_size: int | None = None,
schema: pa.Schema | None = None,
) -> pa.RecordBatchReader: ...
def to_dataset(self) -> VortexDataset: ...
def to_polars(self) -> pl.LazyFrame: ...
def splits(self) -> list[tuple[int, int]]: ...
def open(
path: str,
*,
store: ObjectStore | CosStore | HfStore | None = None,
without_segment_cache: bool = False,
) -> VortexFile: ...