maxframe 1.1.1__cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl → 1.3.0__cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of maxframe might be problematic. Click here for more details.
- maxframe/__init__.py +1 -1
- maxframe/_utils.cpython-311-aarch64-linux-gnu.so +0 -0
- maxframe/_utils.pxd +1 -1
- maxframe/_utils.pyx +1 -1
- maxframe/codegen.py +83 -27
- maxframe/config/__init__.py +1 -1
- maxframe/config/config.py +16 -1
- maxframe/config/tests/__init__.py +1 -1
- maxframe/config/tests/test_config.py +1 -1
- maxframe/config/tests/test_validators.py +1 -1
- maxframe/config/validators.py +1 -1
- maxframe/conftest.py +1 -1
- maxframe/core/__init__.py +2 -1
- maxframe/core/accessor.py +45 -0
- maxframe/core/base.py +1 -1
- maxframe/core/entity/__init__.py +1 -1
- maxframe/core/entity/core.py +1 -1
- maxframe/core/entity/executable.py +1 -1
- maxframe/core/entity/objects.py +1 -1
- maxframe/core/entity/output_types.py +1 -1
- maxframe/core/entity/tests/__init__.py +1 -1
- maxframe/core/entity/tests/test_objects.py +1 -1
- maxframe/core/entity/tileables.py +1 -1
- maxframe/core/entity/utils.py +1 -1
- maxframe/core/graph/__init__.py +1 -1
- maxframe/core/graph/builder/__init__.py +1 -1
- maxframe/core/graph/builder/base.py +1 -1
- maxframe/core/graph/builder/tileable.py +1 -1
- maxframe/core/graph/builder/utils.py +1 -1
- maxframe/core/graph/core.cpython-311-aarch64-linux-gnu.so +0 -0
- maxframe/core/graph/core.pyx +1 -1
- maxframe/core/graph/entity.py +1 -1
- maxframe/core/graph/tests/__init__.py +1 -1
- maxframe/core/graph/tests/test_graph.py +1 -1
- maxframe/core/mode.py +1 -1
- maxframe/core/operator/__init__.py +1 -1
- maxframe/core/operator/base.py +1 -1
- maxframe/core/operator/core.py +1 -1
- maxframe/core/operator/fetch.py +1 -1
- maxframe/core/operator/objects.py +1 -1
- maxframe/core/operator/shuffle.py +1 -1
- maxframe/core/operator/tests/__init__.py +1 -1
- maxframe/core/operator/tests/test_core.py +1 -1
- maxframe/core/operator/utils.py +1 -1
- maxframe/core/tests/__init__.py +1 -1
- maxframe/core/tests/test_mode.py +1 -1
- maxframe/dataframe/__init__.py +3 -3
- maxframe/dataframe/accessors/__init__.py +15 -0
- maxframe/dataframe/accessors/datetime_/__init__.py +32 -0
- maxframe/dataframe/accessors/datetime_/accessor.py +67 -0
- maxframe/dataframe/{misc/datetimes.py → accessors/datetime_/core.py} +9 -9
- maxframe/dataframe/{plotting → accessors/datetime_}/tests/__init__.py +1 -1
- maxframe/dataframe/accessors/datetime_/tests/test_datetime_accessor.py +41 -0
- maxframe/dataframe/accessors/dict_/__init__.py +43 -0
- maxframe/dataframe/accessors/dict_/accessor.py +39 -0
- maxframe/dataframe/accessors/dict_/contains.py +81 -0
- maxframe/dataframe/accessors/dict_/getitem.py +144 -0
- maxframe/dataframe/accessors/dict_/length.py +73 -0
- maxframe/dataframe/accessors/dict_/remove.py +87 -0
- maxframe/dataframe/accessors/dict_/setitem.py +89 -0
- maxframe/dataframe/accessors/dict_/tests/__init__.py +13 -0
- maxframe/dataframe/accessors/dict_/tests/test_dict_accessor.py +128 -0
- maxframe/dataframe/accessors/list_/__init__.py +37 -0
- maxframe/dataframe/accessors/list_/accessor.py +39 -0
- maxframe/dataframe/accessors/list_/getitem.py +135 -0
- maxframe/dataframe/accessors/list_/length.py +73 -0
- maxframe/dataframe/accessors/list_/tests/__init__.py +13 -0
- maxframe/dataframe/accessors/list_/tests/test_list_accessor.py +79 -0
- maxframe/dataframe/{plotting → accessors/plotting}/__init__.py +4 -4
- maxframe/dataframe/{plotting → accessors/plotting}/core.py +3 -3
- maxframe/dataframe/accessors/plotting/tests/__init__.py +13 -0
- maxframe/dataframe/{plotting/tests/test_plotting.py → accessors/plotting/tests/test_plotting_accessor.py} +6 -6
- maxframe/dataframe/accessors/string_/__init__.py +33 -0
- maxframe/dataframe/{misc → accessors/string_}/accessor.py +4 -65
- maxframe/dataframe/{misc/string_.py → accessors/string_/core.py} +20 -20
- maxframe/dataframe/accessors/string_/tests/__init__.py +13 -0
- maxframe/dataframe/accessors/string_/tests/test_string_accessor.py +73 -0
- maxframe/dataframe/arithmetic/__init__.py +1 -1
- maxframe/dataframe/arithmetic/abs.py +1 -1
- maxframe/dataframe/arithmetic/add.py +1 -1
- maxframe/dataframe/arithmetic/arccos.py +1 -1
- maxframe/dataframe/arithmetic/arccosh.py +1 -1
- maxframe/dataframe/arithmetic/arcsin.py +1 -1
- maxframe/dataframe/arithmetic/arcsinh.py +1 -1
- maxframe/dataframe/arithmetic/arctan.py +1 -1
- maxframe/dataframe/arithmetic/arctanh.py +1 -1
- maxframe/dataframe/arithmetic/around.py +1 -1
- maxframe/dataframe/arithmetic/bitwise_and.py +1 -1
- maxframe/dataframe/arithmetic/bitwise_or.py +1 -1
- maxframe/dataframe/arithmetic/bitwise_xor.py +1 -1
- maxframe/dataframe/arithmetic/ceil.py +1 -1
- maxframe/dataframe/arithmetic/core.py +1 -1
- maxframe/dataframe/arithmetic/cos.py +1 -1
- maxframe/dataframe/arithmetic/cosh.py +1 -1
- maxframe/dataframe/arithmetic/degrees.py +1 -1
- maxframe/dataframe/arithmetic/docstring.py +1 -1
- maxframe/dataframe/arithmetic/equal.py +1 -1
- maxframe/dataframe/arithmetic/exp.py +1 -1
- maxframe/dataframe/arithmetic/exp2.py +1 -1
- maxframe/dataframe/arithmetic/expm1.py +1 -1
- maxframe/dataframe/arithmetic/floor.py +1 -1
- maxframe/dataframe/arithmetic/floordiv.py +1 -1
- maxframe/dataframe/arithmetic/greater.py +1 -1
- maxframe/dataframe/arithmetic/greater_equal.py +1 -1
- maxframe/dataframe/arithmetic/invert.py +1 -1
- maxframe/dataframe/arithmetic/is_ufuncs.py +1 -1
- maxframe/dataframe/arithmetic/less.py +1 -1
- maxframe/dataframe/arithmetic/less_equal.py +1 -1
- maxframe/dataframe/arithmetic/log.py +1 -1
- maxframe/dataframe/arithmetic/log10.py +1 -1
- maxframe/dataframe/arithmetic/log2.py +1 -1
- maxframe/dataframe/arithmetic/mod.py +1 -1
- maxframe/dataframe/arithmetic/multiply.py +1 -1
- maxframe/dataframe/arithmetic/negative.py +1 -1
- maxframe/dataframe/arithmetic/not_equal.py +1 -1
- maxframe/dataframe/arithmetic/power.py +1 -1
- maxframe/dataframe/arithmetic/radians.py +1 -1
- maxframe/dataframe/arithmetic/sin.py +1 -1
- maxframe/dataframe/arithmetic/sinh.py +1 -1
- maxframe/dataframe/arithmetic/sqrt.py +1 -1
- maxframe/dataframe/arithmetic/subtract.py +1 -1
- maxframe/dataframe/arithmetic/tan.py +1 -1
- maxframe/dataframe/arithmetic/tanh.py +1 -1
- maxframe/dataframe/arithmetic/tests/__init__.py +1 -1
- maxframe/dataframe/arithmetic/tests/test_arithmetic.py +1 -1
- maxframe/dataframe/arithmetic/truediv.py +1 -1
- maxframe/dataframe/arithmetic/trunc.py +1 -1
- maxframe/dataframe/arrays.py +1 -1
- maxframe/dataframe/core.py +1 -1
- maxframe/dataframe/datasource/__init__.py +1 -1
- maxframe/dataframe/datasource/core.py +1 -1
- maxframe/dataframe/datasource/dataframe.py +1 -1
- maxframe/dataframe/datasource/date_range.py +1 -1
- maxframe/dataframe/datasource/from_index.py +1 -1
- maxframe/dataframe/datasource/from_records.py +1 -1
- maxframe/dataframe/datasource/from_tensor.py +1 -1
- maxframe/dataframe/datasource/index.py +1 -1
- maxframe/dataframe/datasource/read_csv.py +1 -1
- maxframe/dataframe/datasource/read_odps_query.py +46 -17
- maxframe/dataframe/datasource/read_odps_table.py +1 -1
- maxframe/dataframe/datasource/read_parquet.py +1 -1
- maxframe/dataframe/datasource/series.py +1 -1
- maxframe/dataframe/datasource/tests/__init__.py +1 -1
- maxframe/dataframe/datasource/tests/test_datasource.py +59 -8
- maxframe/dataframe/datastore/__init__.py +1 -1
- maxframe/dataframe/datastore/core.py +1 -1
- maxframe/dataframe/datastore/tests/__init__.py +1 -1
- maxframe/dataframe/datastore/tests/test_to_odps.py +1 -1
- maxframe/dataframe/datastore/to_csv.py +1 -1
- maxframe/dataframe/datastore/to_odps.py +7 -1
- maxframe/dataframe/extensions/__init__.py +2 -2
- maxframe/dataframe/extensions/accessor.py +6 -21
- maxframe/dataframe/extensions/apply_chunk.py +120 -22
- maxframe/dataframe/extensions/flatjson.py +1 -1
- maxframe/dataframe/extensions/flatmap.py +9 -2
- maxframe/dataframe/extensions/reshuffle.py +1 -1
- maxframe/dataframe/extensions/tests/__init__.py +1 -1
- maxframe/dataframe/extensions/tests/test_apply_chunk.py +3 -2
- maxframe/dataframe/extensions/tests/test_extensions.py +2 -1
- maxframe/dataframe/fetch/__init__.py +1 -1
- maxframe/dataframe/fetch/core.py +1 -1
- maxframe/dataframe/groupby/__init__.py +1 -1
- maxframe/dataframe/groupby/aggregation.py +1 -1
- maxframe/dataframe/groupby/apply.py +1 -1
- maxframe/dataframe/groupby/core.py +1 -1
- maxframe/dataframe/groupby/cum.py +1 -1
- maxframe/dataframe/groupby/fill.py +1 -1
- maxframe/dataframe/groupby/getitem.py +1 -1
- maxframe/dataframe/groupby/head.py +1 -1
- maxframe/dataframe/groupby/sample.py +1 -1
- maxframe/dataframe/groupby/tests/__init__.py +1 -1
- maxframe/dataframe/groupby/tests/test_groupby.py +1 -1
- maxframe/dataframe/groupby/transform.py +1 -1
- maxframe/dataframe/indexing/__init__.py +1 -1
- maxframe/dataframe/indexing/add_prefix_suffix.py +1 -1
- maxframe/dataframe/indexing/align.py +1 -1
- maxframe/dataframe/indexing/at.py +1 -1
- maxframe/dataframe/indexing/getitem.py +1 -1
- maxframe/dataframe/indexing/iat.py +1 -1
- maxframe/dataframe/indexing/iloc.py +1 -1
- maxframe/dataframe/indexing/insert.py +1 -1
- maxframe/dataframe/indexing/loc.py +1 -1
- maxframe/dataframe/indexing/reindex.py +1 -1
- maxframe/dataframe/indexing/rename.py +1 -1
- maxframe/dataframe/indexing/rename_axis.py +1 -1
- maxframe/dataframe/indexing/reset_index.py +1 -1
- maxframe/dataframe/indexing/sample.py +1 -1
- maxframe/dataframe/indexing/set_axis.py +1 -1
- maxframe/dataframe/indexing/set_index.py +1 -1
- maxframe/dataframe/indexing/setitem.py +1 -1
- maxframe/dataframe/indexing/tests/__init__.py +1 -1
- maxframe/dataframe/indexing/tests/test_indexing.py +1 -1
- maxframe/dataframe/indexing/where.py +1 -1
- maxframe/dataframe/initializer.py +1 -1
- maxframe/dataframe/merge/__init__.py +1 -1
- maxframe/dataframe/merge/append.py +1 -1
- maxframe/dataframe/merge/concat.py +8 -5
- maxframe/dataframe/merge/merge.py +2 -1
- maxframe/dataframe/merge/tests/__init__.py +1 -1
- maxframe/dataframe/merge/tests/test_merge.py +98 -48
- maxframe/dataframe/misc/__init__.py +1 -16
- maxframe/dataframe/misc/_duplicate.py +1 -1
- maxframe/dataframe/misc/apply.py +74 -1
- maxframe/dataframe/misc/astype.py +1 -1
- maxframe/dataframe/misc/case_when.py +1 -1
- maxframe/dataframe/misc/check_monotonic.py +1 -1
- maxframe/dataframe/misc/cut.py +6 -4
- maxframe/dataframe/misc/describe.py +1 -1
- maxframe/dataframe/misc/diff.py +1 -1
- maxframe/dataframe/misc/drop.py +1 -1
- maxframe/dataframe/misc/drop_duplicates.py +7 -4
- maxframe/dataframe/misc/duplicated.py +1 -1
- maxframe/dataframe/misc/eval.py +1 -1
- maxframe/dataframe/misc/explode.py +1 -1
- maxframe/dataframe/misc/get_dummies.py +1 -1
- maxframe/dataframe/misc/isin.py +1 -1
- maxframe/dataframe/misc/map.py +1 -1
- maxframe/dataframe/misc/melt.py +1 -1
- maxframe/dataframe/misc/memory_usage.py +1 -1
- maxframe/dataframe/misc/pct_change.py +1 -1
- maxframe/dataframe/misc/pivot_table.py +1 -1
- maxframe/dataframe/misc/qcut.py +1 -1
- maxframe/dataframe/misc/select_dtypes.py +1 -1
- maxframe/dataframe/misc/shift.py +1 -1
- maxframe/dataframe/misc/stack.py +1 -1
- maxframe/dataframe/misc/tests/__init__.py +1 -1
- maxframe/dataframe/misc/tests/test_misc.py +1 -76
- maxframe/dataframe/misc/to_numeric.py +1 -1
- maxframe/dataframe/misc/transform.py +1 -1
- maxframe/dataframe/misc/transpose.py +1 -1
- maxframe/dataframe/misc/value_counts.py +1 -1
- maxframe/dataframe/missing/__init__.py +1 -1
- maxframe/dataframe/missing/checkna.py +1 -1
- maxframe/dataframe/missing/dropna.py +1 -1
- maxframe/dataframe/missing/fillna.py +1 -1
- maxframe/dataframe/missing/replace.py +1 -1
- maxframe/dataframe/missing/tests/__init__.py +1 -1
- maxframe/dataframe/missing/tests/test_missing.py +2 -1
- maxframe/dataframe/operators.py +1 -1
- maxframe/dataframe/reduction/__init__.py +1 -1
- maxframe/dataframe/reduction/aggregation.py +1 -1
- maxframe/dataframe/reduction/all.py +1 -1
- maxframe/dataframe/reduction/any.py +1 -1
- maxframe/dataframe/reduction/core.py +1 -1
- maxframe/dataframe/reduction/count.py +1 -1
- maxframe/dataframe/reduction/cummax.py +1 -1
- maxframe/dataframe/reduction/cummin.py +1 -1
- maxframe/dataframe/reduction/cumprod.py +1 -1
- maxframe/dataframe/reduction/cumsum.py +1 -1
- maxframe/dataframe/reduction/custom_reduction.py +1 -1
- maxframe/dataframe/reduction/kurtosis.py +1 -1
- maxframe/dataframe/reduction/max.py +1 -1
- maxframe/dataframe/reduction/mean.py +1 -1
- maxframe/dataframe/reduction/median.py +1 -1
- maxframe/dataframe/reduction/min.py +1 -1
- maxframe/dataframe/reduction/nunique.py +1 -1
- maxframe/dataframe/reduction/prod.py +1 -1
- maxframe/dataframe/reduction/reduction_size.py +1 -1
- maxframe/dataframe/reduction/sem.py +1 -1
- maxframe/dataframe/reduction/skew.py +1 -1
- maxframe/dataframe/reduction/std.py +1 -1
- maxframe/dataframe/reduction/str_concat.py +1 -1
- maxframe/dataframe/reduction/sum.py +1 -1
- maxframe/dataframe/reduction/tests/__init__.py +1 -1
- maxframe/dataframe/reduction/tests/test_reduction.py +1 -1
- maxframe/dataframe/reduction/unique.py +1 -1
- maxframe/dataframe/reduction/var.py +1 -1
- maxframe/dataframe/sort/__init__.py +1 -1
- maxframe/dataframe/sort/core.py +1 -1
- maxframe/dataframe/sort/sort_index.py +1 -1
- maxframe/dataframe/sort/sort_values.py +1 -1
- maxframe/dataframe/sort/tests/__init__.py +1 -1
- maxframe/dataframe/sort/tests/test_sort.py +1 -1
- maxframe/dataframe/statistics/__init__.py +1 -1
- maxframe/dataframe/statistics/corr.py +1 -1
- maxframe/dataframe/statistics/quantile.py +1 -1
- maxframe/dataframe/statistics/tests/__init__.py +1 -1
- maxframe/dataframe/statistics/tests/test_statistics.py +1 -1
- maxframe/dataframe/tests/__init__.py +1 -1
- maxframe/dataframe/tests/test_initializer.py +1 -1
- maxframe/dataframe/tests/test_utils.py +43 -2
- maxframe/dataframe/tseries/__init__.py +1 -1
- maxframe/dataframe/tseries/tests/__init__.py +1 -1
- maxframe/dataframe/tseries/tests/test_tseries.py +1 -1
- maxframe/dataframe/tseries/to_datetime.py +1 -1
- maxframe/dataframe/ufunc/__init__.py +1 -1
- maxframe/dataframe/ufunc/tensor.py +1 -1
- maxframe/dataframe/ufunc/ufunc.py +2 -1
- maxframe/dataframe/utils.py +25 -2
- maxframe/dataframe/window/__init__.py +1 -1
- maxframe/dataframe/window/aggregation.py +1 -1
- maxframe/dataframe/window/core.py +1 -1
- maxframe/dataframe/window/ewm.py +1 -1
- maxframe/dataframe/window/expanding.py +1 -1
- maxframe/dataframe/window/rolling.py +1 -1
- maxframe/dataframe/window/tests/__init__.py +1 -1
- maxframe/dataframe/window/tests/test_ewm.py +1 -1
- maxframe/dataframe/window/tests/test_expanding.py +1 -1
- maxframe/dataframe/window/tests/test_rolling.py +1 -1
- maxframe/env.py +1 -1
- maxframe/errors.py +5 -1
- maxframe/extension.py +5 -2
- maxframe/io/__init__.py +1 -1
- maxframe/io/objects/__init__.py +1 -1
- maxframe/io/objects/core.py +1 -1
- maxframe/io/objects/tensor.py +1 -1
- maxframe/io/objects/tests/__init__.py +1 -1
- maxframe/io/objects/tests/test_object_io.py +1 -1
- maxframe/io/odpsio/__init__.py +1 -1
- maxframe/io/odpsio/arrow.py +8 -4
- maxframe/io/odpsio/schema.py +76 -3
- maxframe/io/odpsio/tableio.py +10 -4
- maxframe/io/odpsio/tests/__init__.py +1 -1
- maxframe/io/odpsio/tests/test_arrow.py +46 -1
- maxframe/io/odpsio/tests/test_schema.py +19 -1
- maxframe/io/odpsio/tests/test_tableio.py +1 -1
- maxframe/io/odpsio/tests/test_volumeio.py +1 -1
- maxframe/io/odpsio/volumeio.py +1 -1
- maxframe/learn/__init__.py +1 -1
- maxframe/learn/contrib/__init__.py +3 -5
- maxframe/learn/contrib/graph/__init__.py +1 -1
- maxframe/learn/contrib/graph/connected_components.py +1 -1
- maxframe/learn/contrib/graph/tests/__init__.py +1 -1
- maxframe/learn/contrib/graph/tests/test_connected_components.py +1 -1
- maxframe/learn/contrib/llm/__init__.py +2 -1
- maxframe/learn/contrib/llm/core.py +32 -11
- maxframe/learn/contrib/llm/models/__init__.py +2 -1
- maxframe/learn/contrib/llm/models/dashscope.py +5 -4
- maxframe/learn/contrib/llm/models/managed.py +39 -0
- maxframe/learn/contrib/llm/multi_modal.py +2 -1
- maxframe/learn/contrib/llm/text.py +253 -9
- maxframe/learn/contrib/models.py +77 -0
- maxframe/learn/contrib/pytorch/__init__.py +1 -1
- maxframe/learn/contrib/pytorch/run_function.py +1 -1
- maxframe/learn/contrib/pytorch/run_script.py +1 -1
- maxframe/learn/contrib/pytorch/tests/__init__.py +1 -1
- maxframe/learn/contrib/pytorch/tests/test_pytorch.py +1 -1
- maxframe/learn/contrib/utils.py +2 -1
- maxframe/learn/contrib/xgboost/__init__.py +9 -2
- maxframe/learn/contrib/xgboost/classifier.py +16 -5
- maxframe/learn/contrib/xgboost/core.py +109 -2
- maxframe/learn/contrib/xgboost/dmatrix.py +5 -2
- maxframe/learn/contrib/xgboost/predict.py +9 -4
- maxframe/learn/contrib/xgboost/regressor.py +16 -2
- maxframe/learn/contrib/xgboost/tests/__init__.py +1 -1
- maxframe/learn/contrib/xgboost/tests/test_core.py +1 -1
- maxframe/learn/contrib/xgboost/train.py +6 -5
- maxframe/learn/core.py +1 -1
- maxframe/learn/utils/__init__.py +1 -1
- maxframe/learn/utils/core.py +1 -1
- maxframe/lib/__init__.py +1 -1
- maxframe/lib/aio/__init__.py +1 -1
- maxframe/lib/aio/_runners.py +1 -1
- maxframe/lib/aio/_threads.py +1 -1
- maxframe/lib/aio/base.py +1 -1
- maxframe/lib/aio/file.py +1 -1
- maxframe/lib/aio/isolation.py +1 -1
- maxframe/lib/aio/lru.py +1 -1
- maxframe/lib/aio/parallelism.py +1 -1
- maxframe/lib/aio/tests/__init__.py +1 -1
- maxframe/lib/aio/tests/test_aio_file.py +1 -1
- maxframe/lib/compression.py +1 -1
- maxframe/lib/cython/__init__.py +1 -1
- maxframe/lib/cython/libcpp.pxd +1 -1
- maxframe/lib/dtypes_extension/__init__.py +15 -0
- maxframe/lib/dtypes_extension/dtypes.py +66 -0
- maxframe/lib/dtypes_extension/tests/__init__.py +13 -0
- maxframe/lib/dtypes_extension/tests/test_dtypes.py +48 -0
- maxframe/lib/filesystem/__init__.py +1 -1
- maxframe/lib/filesystem/_glob.py +1 -1
- maxframe/lib/filesystem/_oss_lib/__init__.py +1 -1
- maxframe/lib/filesystem/_oss_lib/common.py +1 -1
- maxframe/lib/filesystem/_oss_lib/glob.py +1 -1
- maxframe/lib/filesystem/_oss_lib/handle.py +1 -1
- maxframe/lib/filesystem/arrow.py +1 -1
- maxframe/lib/filesystem/base.py +1 -1
- maxframe/lib/filesystem/core.py +1 -1
- maxframe/lib/filesystem/fsmap.py +1 -1
- maxframe/lib/filesystem/hdfs.py +1 -1
- maxframe/lib/filesystem/local.py +1 -1
- maxframe/lib/filesystem/oss.py +1 -1
- maxframe/lib/filesystem/tests/__init__.py +1 -1
- maxframe/lib/filesystem/tests/test_filesystem.py +6 -4
- maxframe/lib/filesystem/tests/test_oss.py +1 -1
- maxframe/lib/functools_compat.py +1 -1
- maxframe/lib/mmh3.pyi +1 -1
- maxframe/lib/sparse/__init__.py +1 -1
- maxframe/lib/sparse/array.py +1 -1
- maxframe/lib/sparse/core.py +1 -1
- maxframe/lib/sparse/matrix.py +1 -1
- maxframe/lib/sparse/tests/__init__.py +1 -1
- maxframe/lib/sparse/tests/test_sparse.py +1 -1
- maxframe/lib/sparse/vector.py +1 -1
- maxframe/lib/tests/__init__.py +1 -1
- maxframe/lib/tests/test_wrapped_pickle.py +1 -1
- maxframe/lib/version.py +1 -1
- maxframe/lib/wrapped_pickle.py +1 -1
- maxframe/mixin.py +1 -1
- maxframe/opcodes.py +25 -1
- maxframe/protocol.py +1 -1
- maxframe/remote/__init__.py +1 -1
- maxframe/remote/core.py +1 -1
- maxframe/remote/run_script.py +1 -1
- maxframe/serialization/__init__.py +2 -1
- maxframe/serialization/arrow.py +1 -1
- maxframe/serialization/core.cpython-311-aarch64-linux-gnu.so +0 -0
- maxframe/serialization/core.pxd +1 -1
- maxframe/serialization/core.pyi +1 -1
- maxframe/serialization/core.pyx +21 -7
- maxframe/serialization/exception.py +1 -1
- maxframe/serialization/maxframe_objects.py +1 -1
- maxframe/serialization/numpy.py +13 -5
- maxframe/serialization/pandas.py +1 -1
- maxframe/serialization/scipy.py +1 -1
- maxframe/serialization/serializables/__init__.py +1 -1
- maxframe/serialization/serializables/core.py +95 -90
- maxframe/serialization/serializables/field.py +1 -1
- maxframe/serialization/serializables/field_type.py +1 -1
- maxframe/serialization/serializables/tests/__init__.py +1 -1
- maxframe/serialization/serializables/tests/test_field_type.py +1 -1
- maxframe/serialization/serializables/tests/test_serializable.py +14 -3
- maxframe/serialization/tests/__init__.py +1 -1
- maxframe/serialization/tests/test_serial.py +23 -3
- maxframe/session.py +1 -1
- maxframe/tensor/__init__.py +1 -1
- maxframe/tensor/arithmetic/__init__.py +1 -1
- maxframe/tensor/arithmetic/abs.py +1 -1
- maxframe/tensor/arithmetic/absolute.py +1 -1
- maxframe/tensor/arithmetic/add.py +1 -1
- maxframe/tensor/arithmetic/angle.py +1 -1
- maxframe/tensor/arithmetic/arccos.py +1 -1
- maxframe/tensor/arithmetic/arccosh.py +1 -1
- maxframe/tensor/arithmetic/arcsin.py +1 -1
- maxframe/tensor/arithmetic/arcsinh.py +1 -1
- maxframe/tensor/arithmetic/arctan.py +1 -1
- maxframe/tensor/arithmetic/arctan2.py +1 -1
- maxframe/tensor/arithmetic/arctanh.py +1 -1
- maxframe/tensor/arithmetic/around.py +1 -1
- maxframe/tensor/arithmetic/bitand.py +1 -1
- maxframe/tensor/arithmetic/bitor.py +1 -1
- maxframe/tensor/arithmetic/bitxor.py +1 -1
- maxframe/tensor/arithmetic/cbrt.py +1 -1
- maxframe/tensor/arithmetic/ceil.py +1 -1
- maxframe/tensor/arithmetic/clip.py +1 -1
- maxframe/tensor/arithmetic/conj.py +1 -1
- maxframe/tensor/arithmetic/copysign.py +1 -1
- maxframe/tensor/arithmetic/core.py +1 -1
- maxframe/tensor/arithmetic/cos.py +1 -1
- maxframe/tensor/arithmetic/cosh.py +1 -1
- maxframe/tensor/arithmetic/deg2rad.py +1 -1
- maxframe/tensor/arithmetic/degrees.py +1 -1
- maxframe/tensor/arithmetic/divide.py +1 -1
- maxframe/tensor/arithmetic/equal.py +1 -1
- maxframe/tensor/arithmetic/exp.py +1 -1
- maxframe/tensor/arithmetic/exp2.py +1 -1
- maxframe/tensor/arithmetic/expm1.py +1 -1
- maxframe/tensor/arithmetic/fabs.py +1 -1
- maxframe/tensor/arithmetic/fix.py +1 -1
- maxframe/tensor/arithmetic/float_power.py +1 -1
- maxframe/tensor/arithmetic/floor.py +1 -1
- maxframe/tensor/arithmetic/floordiv.py +1 -1
- maxframe/tensor/arithmetic/fmax.py +1 -1
- maxframe/tensor/arithmetic/fmin.py +1 -1
- maxframe/tensor/arithmetic/fmod.py +1 -1
- maxframe/tensor/arithmetic/frexp.py +1 -1
- maxframe/tensor/arithmetic/greater.py +1 -1
- maxframe/tensor/arithmetic/greater_equal.py +1 -1
- maxframe/tensor/arithmetic/hypot.py +1 -1
- maxframe/tensor/arithmetic/i0.py +1 -1
- maxframe/tensor/arithmetic/imag.py +1 -1
- maxframe/tensor/arithmetic/invert.py +1 -1
- maxframe/tensor/arithmetic/isclose.py +1 -1
- maxframe/tensor/arithmetic/iscomplex.py +1 -1
- maxframe/tensor/arithmetic/isfinite.py +1 -1
- maxframe/tensor/arithmetic/isinf.py +1 -1
- maxframe/tensor/arithmetic/isnan.py +1 -1
- maxframe/tensor/arithmetic/isreal.py +1 -1
- maxframe/tensor/arithmetic/ldexp.py +1 -1
- maxframe/tensor/arithmetic/less.py +1 -1
- maxframe/tensor/arithmetic/less_equal.py +1 -1
- maxframe/tensor/arithmetic/log.py +1 -1
- maxframe/tensor/arithmetic/log10.py +1 -1
- maxframe/tensor/arithmetic/log1p.py +1 -1
- maxframe/tensor/arithmetic/log2.py +1 -1
- maxframe/tensor/arithmetic/logaddexp.py +1 -1
- maxframe/tensor/arithmetic/logaddexp2.py +1 -1
- maxframe/tensor/arithmetic/logical_and.py +1 -1
- maxframe/tensor/arithmetic/logical_not.py +1 -1
- maxframe/tensor/arithmetic/logical_or.py +1 -1
- maxframe/tensor/arithmetic/logical_xor.py +1 -1
- maxframe/tensor/arithmetic/lshift.py +1 -1
- maxframe/tensor/arithmetic/maximum.py +1 -1
- maxframe/tensor/arithmetic/minimum.py +1 -1
- maxframe/tensor/arithmetic/mod.py +1 -1
- maxframe/tensor/arithmetic/modf.py +1 -1
- maxframe/tensor/arithmetic/multiply.py +1 -1
- maxframe/tensor/arithmetic/nan_to_num.py +1 -1
- maxframe/tensor/arithmetic/negative.py +1 -1
- maxframe/tensor/arithmetic/nextafter.py +1 -1
- maxframe/tensor/arithmetic/not_equal.py +1 -1
- maxframe/tensor/arithmetic/positive.py +1 -1
- maxframe/tensor/arithmetic/power.py +1 -1
- maxframe/tensor/arithmetic/rad2deg.py +1 -1
- maxframe/tensor/arithmetic/radians.py +1 -1
- maxframe/tensor/arithmetic/real.py +1 -1
- maxframe/tensor/arithmetic/reciprocal.py +1 -1
- maxframe/tensor/arithmetic/rint.py +1 -1
- maxframe/tensor/arithmetic/rshift.py +1 -1
- maxframe/tensor/arithmetic/setimag.py +1 -1
- maxframe/tensor/arithmetic/setreal.py +1 -1
- maxframe/tensor/arithmetic/sign.py +1 -1
- maxframe/tensor/arithmetic/signbit.py +1 -1
- maxframe/tensor/arithmetic/sin.py +1 -1
- maxframe/tensor/arithmetic/sinc.py +1 -1
- maxframe/tensor/arithmetic/sinh.py +1 -1
- maxframe/tensor/arithmetic/spacing.py +1 -1
- maxframe/tensor/arithmetic/sqrt.py +1 -1
- maxframe/tensor/arithmetic/square.py +1 -1
- maxframe/tensor/arithmetic/subtract.py +1 -1
- maxframe/tensor/arithmetic/tan.py +1 -1
- maxframe/tensor/arithmetic/tanh.py +1 -1
- maxframe/tensor/arithmetic/tests/__init__.py +1 -1
- maxframe/tensor/arithmetic/tests/test_arithmetic.py +1 -1
- maxframe/tensor/arithmetic/truediv.py +1 -1
- maxframe/tensor/arithmetic/trunc.py +1 -1
- maxframe/tensor/arithmetic/utils.py +1 -1
- maxframe/tensor/array_utils.py +1 -1
- maxframe/tensor/core.py +1 -1
- maxframe/tensor/datasource/__init__.py +1 -1
- maxframe/tensor/datasource/arange.py +1 -1
- maxframe/tensor/datasource/array.py +1 -1
- maxframe/tensor/datasource/core.py +1 -1
- maxframe/tensor/datasource/empty.py +1 -1
- maxframe/tensor/datasource/from_dataframe.py +1 -1
- maxframe/tensor/datasource/from_dense.py +1 -1
- maxframe/tensor/datasource/from_sparse.py +1 -1
- maxframe/tensor/datasource/full.py +1 -1
- maxframe/tensor/datasource/ones.py +1 -1
- maxframe/tensor/datasource/scalar.py +1 -1
- maxframe/tensor/datasource/tests/__init__.py +1 -1
- maxframe/tensor/datasource/tests/test_datasource.py +1 -1
- maxframe/tensor/datasource/zeros.py +1 -1
- maxframe/tensor/fetch/__init__.py +1 -1
- maxframe/tensor/fetch/core.py +1 -1
- maxframe/tensor/indexing/__init__.py +1 -1
- maxframe/tensor/indexing/choose.py +1 -1
- maxframe/tensor/indexing/compress.py +1 -1
- maxframe/tensor/indexing/core.py +1 -1
- maxframe/tensor/indexing/extract.py +1 -1
- maxframe/tensor/indexing/fill_diagonal.py +1 -1
- maxframe/tensor/indexing/flatnonzero.py +1 -1
- maxframe/tensor/indexing/getitem.py +1 -1
- maxframe/tensor/indexing/nonzero.py +1 -1
- maxframe/tensor/indexing/setitem.py +1 -1
- maxframe/tensor/indexing/slice.py +1 -1
- maxframe/tensor/indexing/take.py +1 -1
- maxframe/tensor/indexing/tests/__init__.py +1 -1
- maxframe/tensor/indexing/tests/test_indexing.py +1 -1
- maxframe/tensor/indexing/unravel_index.py +1 -1
- maxframe/tensor/merge/__init__.py +1 -1
- maxframe/tensor/merge/concatenate.py +2 -1
- maxframe/tensor/merge/stack.py +1 -1
- maxframe/tensor/merge/tests/__init__.py +1 -1
- maxframe/tensor/merge/tests/test_merge.py +1 -1
- maxframe/tensor/merge/vstack.py +1 -1
- maxframe/tensor/misc/__init__.py +1 -1
- maxframe/tensor/misc/astype.py +1 -1
- maxframe/tensor/misc/atleast_1d.py +1 -1
- maxframe/tensor/misc/atleast_2d.py +1 -1
- maxframe/tensor/misc/atleast_3d.py +1 -1
- maxframe/tensor/misc/broadcast_to.py +1 -1
- maxframe/tensor/misc/ravel.py +1 -1
- maxframe/tensor/misc/tests/__init__.py +1 -1
- maxframe/tensor/misc/tests/test_misc.py +1 -1
- maxframe/tensor/misc/transpose.py +1 -1
- maxframe/tensor/misc/unique.py +12 -11
- maxframe/tensor/misc/where.py +1 -1
- maxframe/tensor/operators.py +1 -1
- maxframe/tensor/random/__init__.py +1 -1
- maxframe/tensor/random/beta.py +1 -1
- maxframe/tensor/random/binomial.py +1 -1
- maxframe/tensor/random/bytes.py +1 -1
- maxframe/tensor/random/chisquare.py +1 -1
- maxframe/tensor/random/choice.py +1 -1
- maxframe/tensor/random/core.py +1 -1
- maxframe/tensor/random/dirichlet.py +1 -1
- maxframe/tensor/random/exponential.py +1 -1
- maxframe/tensor/random/f.py +1 -1
- maxframe/tensor/random/gamma.py +1 -1
- maxframe/tensor/random/geometric.py +1 -1
- maxframe/tensor/random/gumbel.py +1 -1
- maxframe/tensor/random/hypergeometric.py +1 -1
- maxframe/tensor/random/laplace.py +1 -1
- maxframe/tensor/random/logistic.py +1 -1
- maxframe/tensor/random/lognormal.py +1 -1
- maxframe/tensor/random/logseries.py +1 -1
- maxframe/tensor/random/multinomial.py +1 -1
- maxframe/tensor/random/multivariate_normal.py +1 -1
- maxframe/tensor/random/negative_binomial.py +1 -1
- maxframe/tensor/random/noncentral_chisquare.py +1 -1
- maxframe/tensor/random/noncentral_f.py +1 -1
- maxframe/tensor/random/normal.py +1 -1
- maxframe/tensor/random/pareto.py +1 -1
- maxframe/tensor/random/permutation.py +1 -1
- maxframe/tensor/random/poisson.py +1 -1
- maxframe/tensor/random/power.py +1 -1
- maxframe/tensor/random/rand.py +1 -1
- maxframe/tensor/random/randint.py +1 -1
- maxframe/tensor/random/randn.py +1 -1
- maxframe/tensor/random/random_integers.py +1 -1
- maxframe/tensor/random/random_sample.py +1 -1
- maxframe/tensor/random/rayleigh.py +1 -1
- maxframe/tensor/random/shuffle.py +1 -1
- maxframe/tensor/random/standard_cauchy.py +1 -1
- maxframe/tensor/random/standard_exponential.py +1 -1
- maxframe/tensor/random/standard_gamma.py +1 -1
- maxframe/tensor/random/standard_normal.py +1 -1
- maxframe/tensor/random/standard_t.py +1 -1
- maxframe/tensor/random/tests/__init__.py +1 -1
- maxframe/tensor/random/tests/test_random.py +1 -1
- maxframe/tensor/random/triangular.py +1 -1
- maxframe/tensor/random/uniform.py +1 -1
- maxframe/tensor/random/vonmises.py +1 -1
- maxframe/tensor/random/wald.py +1 -1
- maxframe/tensor/random/weibull.py +1 -1
- maxframe/tensor/random/zipf.py +1 -1
- maxframe/tensor/rechunk/__init__.py +1 -1
- maxframe/tensor/rechunk/rechunk.py +1 -1
- maxframe/tensor/reduction/__init__.py +1 -1
- maxframe/tensor/reduction/all.py +1 -1
- maxframe/tensor/reduction/allclose.py +1 -1
- maxframe/tensor/reduction/any.py +1 -1
- maxframe/tensor/reduction/argmax.py +1 -1
- maxframe/tensor/reduction/argmin.py +1 -1
- maxframe/tensor/reduction/array_equal.py +1 -1
- maxframe/tensor/reduction/core.py +1 -1
- maxframe/tensor/reduction/count_nonzero.py +1 -1
- maxframe/tensor/reduction/cumprod.py +1 -1
- maxframe/tensor/reduction/cumsum.py +1 -1
- maxframe/tensor/reduction/max.py +1 -1
- maxframe/tensor/reduction/mean.py +1 -1
- maxframe/tensor/reduction/min.py +1 -1
- maxframe/tensor/reduction/nanargmax.py +1 -1
- maxframe/tensor/reduction/nanargmin.py +1 -1
- maxframe/tensor/reduction/nancumprod.py +1 -1
- maxframe/tensor/reduction/nancumsum.py +1 -1
- maxframe/tensor/reduction/nanmax.py +1 -1
- maxframe/tensor/reduction/nanmean.py +1 -1
- maxframe/tensor/reduction/nanmin.py +1 -1
- maxframe/tensor/reduction/nanprod.py +1 -1
- maxframe/tensor/reduction/nanstd.py +1 -1
- maxframe/tensor/reduction/nansum.py +1 -1
- maxframe/tensor/reduction/nanvar.py +1 -1
- maxframe/tensor/reduction/prod.py +1 -1
- maxframe/tensor/reduction/std.py +1 -1
- maxframe/tensor/reduction/sum.py +1 -1
- maxframe/tensor/reduction/tests/__init__.py +1 -1
- maxframe/tensor/reduction/tests/test_reduction.py +1 -1
- maxframe/tensor/reduction/var.py +1 -1
- maxframe/tensor/reshape/__init__.py +1 -1
- maxframe/tensor/reshape/reshape.py +5 -2
- maxframe/tensor/reshape/tests/__init__.py +1 -1
- maxframe/tensor/reshape/tests/test_reshape.py +1 -1
- maxframe/tensor/statistics/__init__.py +1 -1
- maxframe/tensor/statistics/percentile.py +1 -1
- maxframe/tensor/statistics/quantile.py +1 -1
- maxframe/tensor/ufunc/__init__.py +1 -1
- maxframe/tensor/ufunc/ufunc.py +1 -1
- maxframe/tensor/utils.py +1 -1
- maxframe/tests/__init__.py +1 -1
- maxframe/tests/test_codegen.py +1 -1
- maxframe/tests/test_protocol.py +1 -1
- maxframe/tests/test_utils.py +1 -1
- maxframe/tests/utils.py +1 -1
- maxframe/typing_.py +1 -1
- maxframe/udf.py +6 -1
- maxframe/utils.py +12 -1
- {maxframe-1.1.1.dist-info → maxframe-1.3.0.dist-info}/METADATA +3 -2
- maxframe-1.3.0.dist-info/RECORD +705 -0
- {maxframe-1.1.1.dist-info → maxframe-1.3.0.dist-info}/WHEEL +1 -1
- maxframe_client/__init__.py +1 -1
- maxframe_client/clients/__init__.py +1 -1
- maxframe_client/clients/framedriver.py +1 -1
- maxframe_client/conftest.py +1 -1
- maxframe_client/fetcher.py +1 -1
- maxframe_client/session/__init__.py +1 -1
- maxframe_client/session/consts.py +1 -1
- maxframe_client/session/graph.py +1 -1
- maxframe_client/session/odps.py +5 -1
- maxframe_client/session/task.py +1 -1
- maxframe_client/session/tests/__init__.py +1 -1
- maxframe_client/session/tests/test_task.py +2 -1
- maxframe_client/tests/__init__.py +1 -1
- maxframe_client/tests/test_fetcher.py +1 -1
- maxframe_client/tests/test_session.py +1 -1
- maxframe-1.1.1.dist-info/RECORD +0 -675
- {maxframe-1.1.1.dist-info → maxframe-1.3.0.dist-info}/top_level.txt +0 -0
maxframe/__init__.py
CHANGED
|
Binary file
|
maxframe/_utils.pxd
CHANGED
maxframe/_utils.pyx
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
# distutils: language = c++
|
|
2
|
-
# Copyright 1999-
|
|
2
|
+
# Copyright 1999-2025 Alibaba Group Holding Ltd.
|
|
3
3
|
#
|
|
4
4
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
5
|
# you may not use this file except in compliance with the License.
|
maxframe/codegen.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright 1999-
|
|
1
|
+
# Copyright 1999-2025 Alibaba Group Holding Ltd.
|
|
2
2
|
#
|
|
3
3
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
4
|
# you may not use this file except in compliance with the License.
|
|
@@ -24,7 +24,7 @@ from odps.types import OdpsSchema
|
|
|
24
24
|
from odps.utils import camel_to_underline
|
|
25
25
|
|
|
26
26
|
from .core import OperatorType, Tileable, TileableGraph
|
|
27
|
-
from .core.operator import Fetch
|
|
27
|
+
from .core.operator import Fetch, Operator
|
|
28
28
|
from .extension import iter_extensions
|
|
29
29
|
from .io.odpsio import build_dataframe_table_meta
|
|
30
30
|
from .io.odpsio.schema import pandas_to_odps_schema
|
|
@@ -211,13 +211,26 @@ class BigDagCodeContext(metaclass=abc.ABCMeta):
|
|
|
211
211
|
def get_udfs(self) -> List[AbstractUDF]:
|
|
212
212
|
return list(self._udfs.values())
|
|
213
213
|
|
|
214
|
-
def
|
|
214
|
+
def get_input_tileable_variable(self, tileable: Tileable) -> str:
|
|
215
|
+
"""
|
|
216
|
+
Get or create the variable name for an input tileable. It should be used on the
|
|
217
|
+
RIGHT side of the assignment.
|
|
218
|
+
"""
|
|
219
|
+
return self._get_tileable_variable(tileable)
|
|
220
|
+
|
|
221
|
+
def get_output_tileable_variable(self, tileable: Tileable) -> str:
|
|
222
|
+
"""
|
|
223
|
+
Get or create the variable name for an output tileable. It should be used on the
|
|
224
|
+
LEFT side of the assignment.
|
|
225
|
+
"""
|
|
226
|
+
return self._get_tileable_variable(tileable)
|
|
227
|
+
|
|
228
|
+
def _get_tileable_variable(self, tileable: Tileable) -> str:
|
|
215
229
|
try:
|
|
216
230
|
return self._tileable_key_to_variables[tileable.key]
|
|
217
231
|
except KeyError:
|
|
218
|
-
var_name = self.
|
|
219
|
-
|
|
220
|
-
] = self.next_var_name()
|
|
232
|
+
var_name = self.next_var_name()
|
|
233
|
+
self._tileable_key_to_variables[tileable.key] = var_name
|
|
221
234
|
return var_name
|
|
222
235
|
|
|
223
236
|
def next_var_name(self) -> str:
|
|
@@ -281,11 +294,20 @@ class EngineAcceptance(Enum):
|
|
|
281
294
|
DENY: The operator is not accepted by the current engine.
|
|
282
295
|
ACCEPT: The operator is accepted by the current engine, and doesn't break from here.
|
|
283
296
|
BREAK: The operator is accepted by the current engine, but should break from here.
|
|
297
|
+
PREDECESSOR: The acceptance of the operator is decided by engines of its
|
|
298
|
+
predecessors. If acceptance of all predecessors are SUCCESSOR, the acceptance
|
|
299
|
+
of current operator is SUCCESSOR. Otherwise the engine selected in predecessors
|
|
300
|
+
with highest priority is used.
|
|
301
|
+
SUCCESSOR: The acceptance of the operator is decided by engines of its successors.
|
|
302
|
+
If the operator has no successors, the acceptance will be treated as ACCEPT.
|
|
303
|
+
Otherwise the engine selected in successors with highest priority is used.
|
|
284
304
|
"""
|
|
285
305
|
|
|
286
306
|
DENY = 0
|
|
287
307
|
ACCEPT = 1
|
|
288
308
|
BREAK = 2
|
|
309
|
+
PREDECESSOR = 3
|
|
310
|
+
SUCCESSOR = 4
|
|
289
311
|
|
|
290
312
|
@classmethod
|
|
291
313
|
def _missing_(cls, pred: bool) -> "EngineAcceptance":
|
|
@@ -307,7 +329,7 @@ class EngineAcceptance(Enum):
|
|
|
307
329
|
|
|
308
330
|
class BigDagOperatorAdapter(metaclass=abc.ABCMeta):
|
|
309
331
|
# todo handle refcount issue when generated code is being executed
|
|
310
|
-
def accepts(self, op:
|
|
332
|
+
def accepts(self, op: Operator) -> EngineAcceptance:
|
|
311
333
|
return EngineAcceptance.ACCEPT
|
|
312
334
|
|
|
313
335
|
@abc.abstractmethod
|
|
@@ -322,7 +344,7 @@ class BigDagOperatorAdapter(metaclass=abc.ABCMeta):
|
|
|
322
344
|
|
|
323
345
|
Parameters
|
|
324
346
|
----------
|
|
325
|
-
op :
|
|
347
|
+
op : Operator
|
|
326
348
|
The operator instance.
|
|
327
349
|
context : BigDagCodeContext
|
|
328
350
|
The BigDagCodeContext instance.
|
|
@@ -334,6 +356,48 @@ class BigDagOperatorAdapter(metaclass=abc.ABCMeta):
|
|
|
334
356
|
"""
|
|
335
357
|
return list()
|
|
336
358
|
|
|
359
|
+
def generate_pre_op_code(
|
|
360
|
+
self, op: Operator, context: BigDagCodeContext
|
|
361
|
+
) -> List[str]:
|
|
362
|
+
"""
|
|
363
|
+
Generate the codes before actually handling the operator.
|
|
364
|
+
This method is usually implemented in the base class of each engine.
|
|
365
|
+
|
|
366
|
+
Parameters
|
|
367
|
+
----------
|
|
368
|
+
op : Operator
|
|
369
|
+
The operator instance.
|
|
370
|
+
context : BigDagCodeContext
|
|
371
|
+
The BigDagCodeContext instance.
|
|
372
|
+
|
|
373
|
+
Returns
|
|
374
|
+
-------
|
|
375
|
+
result: List[str]
|
|
376
|
+
The codes generated before one operator actually handled, one per line.
|
|
377
|
+
"""
|
|
378
|
+
return list()
|
|
379
|
+
|
|
380
|
+
def generate_post_op_code(
|
|
381
|
+
self, op: Operator, context: BigDagCodeContext
|
|
382
|
+
) -> List[str]:
|
|
383
|
+
"""
|
|
384
|
+
Generate the codes after actually handling the operator.
|
|
385
|
+
This method is usually implemented in the base class of each engine.
|
|
386
|
+
|
|
387
|
+
Parameters
|
|
388
|
+
----------
|
|
389
|
+
op : Operator
|
|
390
|
+
The operator instance.
|
|
391
|
+
context : BigDagCodeContext
|
|
392
|
+
The BigDagCodeContext instance.
|
|
393
|
+
|
|
394
|
+
Returns
|
|
395
|
+
-------
|
|
396
|
+
result: List[str]
|
|
397
|
+
The codes generated after one operator actually handled, one per line.
|
|
398
|
+
"""
|
|
399
|
+
return list()
|
|
400
|
+
|
|
337
401
|
|
|
338
402
|
_engine_to_codegen: Dict[str, Type["BigDagCodeGenerator"]] = dict()
|
|
339
403
|
|
|
@@ -346,9 +410,6 @@ def register_engine_codegen(type_: Type["BigDagCodeGenerator"]):
|
|
|
346
410
|
BUILTIN_ENGINE_SPE = "SPE"
|
|
347
411
|
BUILTIN_ENGINE_MCSQL = "MCSQL"
|
|
348
412
|
|
|
349
|
-
FAST_RANGE_INDEX_ENABLED = "codegen.fast_range_index_enabled"
|
|
350
|
-
ROW_NUMBER_WINDOW_INDEX_ENABLED = "codegen.row_number_window_index_enabled"
|
|
351
|
-
|
|
352
413
|
|
|
353
414
|
class BigDagCodeGenerator(metaclass=abc.ABCMeta):
|
|
354
415
|
_context: BigDagCodeContext
|
|
@@ -356,11 +417,13 @@ class BigDagCodeGenerator(metaclass=abc.ABCMeta):
|
|
|
356
417
|
engine_type: Optional[str] = None
|
|
357
418
|
engine_priority: int = 0
|
|
358
419
|
_extension_loaded = False
|
|
420
|
+
_generate_comments_enabled: bool = True
|
|
359
421
|
|
|
360
422
|
def __init__(self, session_id: str, subdag_id: str = None):
|
|
361
423
|
self._session_id = session_id
|
|
362
424
|
self._subdag_id = subdag_id
|
|
363
425
|
self._context = self._init_context(session_id, subdag_id)
|
|
426
|
+
self._generate_comments_enabled = True
|
|
364
427
|
|
|
365
428
|
@classmethod
|
|
366
429
|
def _load_engine_extensions(cls):
|
|
@@ -393,14 +456,6 @@ class BigDagCodeGenerator(metaclass=abc.ABCMeta):
|
|
|
393
456
|
def _init_context(self, session_id: str, subdag_id: str) -> BigDagCodeContext:
|
|
394
457
|
raise NotImplementedError
|
|
395
458
|
|
|
396
|
-
def _generate_comments(
|
|
397
|
-
self, op: OperatorType, adapter: BigDagOperatorAdapter
|
|
398
|
-
) -> List[str]:
|
|
399
|
-
return adapter.generate_comment(op, self._context)
|
|
400
|
-
|
|
401
|
-
def _generate_pre_op_code(self, op: OperatorType) -> List[str]:
|
|
402
|
-
return []
|
|
403
|
-
|
|
404
459
|
def _generate_delete_code(self, var_name: str) -> List[str]:
|
|
405
460
|
return []
|
|
406
461
|
|
|
@@ -430,9 +485,11 @@ class BigDagCodeGenerator(metaclass=abc.ABCMeta):
|
|
|
430
485
|
visited_op_key.add(op.key)
|
|
431
486
|
|
|
432
487
|
adapter = self.get_op_adapter(type(op))()
|
|
433
|
-
code_lines.extend(
|
|
434
|
-
|
|
488
|
+
code_lines.extend(adapter.generate_pre_op_code(op, self._context))
|
|
489
|
+
if self._generate_comments_enabled:
|
|
490
|
+
code_lines.extend(adapter.generate_comment(op, self._context))
|
|
435
491
|
code_lines.extend(adapter.generate_code(op, self._context))
|
|
492
|
+
code_lines.extend(adapter.generate_post_op_code(op, self._context))
|
|
436
493
|
code_lines.append("") # Append an empty line to separate operators
|
|
437
494
|
|
|
438
495
|
# record refcounts
|
|
@@ -441,7 +498,7 @@ class BigDagCodeGenerator(metaclass=abc.ABCMeta):
|
|
|
441
498
|
continue
|
|
442
499
|
if dag.count_successors(out_t) == 0:
|
|
443
500
|
delete_code = self._generate_delete_code(
|
|
444
|
-
self._context.
|
|
501
|
+
self._context.get_input_tileable_variable(out_t)
|
|
445
502
|
)
|
|
446
503
|
code_lines.extend(delete_code)
|
|
447
504
|
else:
|
|
@@ -454,7 +511,7 @@ class BigDagCodeGenerator(metaclass=abc.ABCMeta):
|
|
|
454
511
|
out_refcounts[inp_t.key] -= 1
|
|
455
512
|
if out_refcounts[inp_t.key] == 0:
|
|
456
513
|
delete_code = self._generate_delete_code(
|
|
457
|
-
self._context.
|
|
514
|
+
self._context.get_input_tileable_variable(inp_t)
|
|
458
515
|
)
|
|
459
516
|
code_lines.extend(delete_code)
|
|
460
517
|
out_refcounts.pop(inp_t.key)
|
|
@@ -467,12 +524,11 @@ class BigDagCodeGenerator(metaclass=abc.ABCMeta):
|
|
|
467
524
|
for tileable in dag.topological_iter():
|
|
468
525
|
op: OperatorType = tileable.op
|
|
469
526
|
if isinstance(op, Fetch):
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
] = self._context.get_tileable_variable(tileable)
|
|
527
|
+
fetch_tileable = self._context.get_input_tileable_variable(tileable)
|
|
528
|
+
input_key_to_vars[op.outputs[0].key] = fetch_tileable
|
|
473
529
|
|
|
474
530
|
result_variables = {
|
|
475
|
-
t.key: self._context.
|
|
531
|
+
t.key: self._context.get_input_tileable_variable(t) for t in dag.results
|
|
476
532
|
}
|
|
477
533
|
|
|
478
534
|
return CodeGenResult(
|
maxframe/config/__init__.py
CHANGED
maxframe/config/config.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright 1999-
|
|
1
|
+
# Copyright 1999-2025 Alibaba Group Holding Ltd.
|
|
2
2
|
#
|
|
3
3
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
4
|
# you may not use this file except in compliance with the License.
|
|
@@ -325,6 +325,9 @@ default_options.register_option(
|
|
|
325
325
|
"execution_mode", "trigger", validator=is_in(["trigger", "eager"])
|
|
326
326
|
)
|
|
327
327
|
default_options.register_option("use_common_table", False, validator=is_bool)
|
|
328
|
+
default_options.register_option(
|
|
329
|
+
"tunnel_quota_name", None, validator=is_string | is_null
|
|
330
|
+
)
|
|
328
331
|
default_options.register_option(
|
|
329
332
|
"python_tag", get_python_tag(), validator=is_string, remote=True
|
|
330
333
|
)
|
|
@@ -404,6 +407,18 @@ default_options.register_option(
|
|
|
404
407
|
validator=is_integer,
|
|
405
408
|
remote=True,
|
|
406
409
|
)
|
|
410
|
+
default_options.register_option(
|
|
411
|
+
"session.temp_table_properties",
|
|
412
|
+
None,
|
|
413
|
+
validator=is_null | is_dict,
|
|
414
|
+
remote=True,
|
|
415
|
+
)
|
|
416
|
+
default_options.register_option(
|
|
417
|
+
"session.auto_purge_temp_tables",
|
|
418
|
+
False,
|
|
419
|
+
validator=is_bool,
|
|
420
|
+
remote=True,
|
|
421
|
+
)
|
|
407
422
|
default_options.register_option(
|
|
408
423
|
"session.subinstance_priority",
|
|
409
424
|
None,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/env python
|
|
2
2
|
# -*- coding: utf-8 -*-
|
|
3
|
-
# Copyright 1999-
|
|
3
|
+
# Copyright 1999-2025 Alibaba Group Holding Ltd.
|
|
4
4
|
#
|
|
5
5
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
6
6
|
# you may not use this file except in compliance with the License.
|
maxframe/config/validators.py
CHANGED
maxframe/conftest.py
CHANGED
maxframe/core/__init__.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright 1999-
|
|
1
|
+
# Copyright 1999-2025 Alibaba Group Holding Ltd.
|
|
2
2
|
#
|
|
3
3
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
4
|
# you may not use this file except in compliance with the License.
|
|
@@ -14,6 +14,7 @@
|
|
|
14
14
|
|
|
15
15
|
# noinspection PyUnresolvedReferences
|
|
16
16
|
from ..typing_ import ChunkType, EntityType, OperatorType, TileableType
|
|
17
|
+
from .accessor import BaseMaxFrameAccessor, CachedAccessor
|
|
17
18
|
from .base import Base, ExecutionError
|
|
18
19
|
from .entity import (
|
|
19
20
|
ENTITY_TYPE,
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
# Copyright 1999-2025 Alibaba Group Holding Ltd.
|
|
2
|
+
#
|
|
3
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
|
+
# you may not use this file except in compliance with the License.
|
|
5
|
+
# You may obtain a copy of the License at
|
|
6
|
+
#
|
|
7
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
8
|
+
#
|
|
9
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
10
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
11
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
12
|
+
# See the License for the specific language governing permissions and
|
|
13
|
+
# limitations under the License.
|
|
14
|
+
|
|
15
|
+
import functools
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
class BaseMaxFrameAccessor:
|
|
19
|
+
def __init__(self, obj):
|
|
20
|
+
self.obj = obj
|
|
21
|
+
|
|
22
|
+
@classmethod
|
|
23
|
+
def _register(cls, name, func):
|
|
24
|
+
@functools.wraps(func)
|
|
25
|
+
def wrapped(self, *args, **kw):
|
|
26
|
+
return func(self.obj, *args, **kw)
|
|
27
|
+
|
|
28
|
+
wrapped.__name__ = name
|
|
29
|
+
setattr(cls, name, wrapped)
|
|
30
|
+
if hasattr(cls, "_api_count"): # pragma: no branch
|
|
31
|
+
cls._api_count += 1
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
class CachedAccessor:
|
|
35
|
+
def __init__(self, name: str, accessor) -> None:
|
|
36
|
+
self._name = name
|
|
37
|
+
self._accessor = accessor
|
|
38
|
+
|
|
39
|
+
def __get__(self, obj, cls):
|
|
40
|
+
if obj is None:
|
|
41
|
+
# we're accessing the attribute of the class, i.e., Dataset.geo
|
|
42
|
+
return self._accessor
|
|
43
|
+
if self._name not in obj._accessors:
|
|
44
|
+
obj._accessors[self._name] = self._accessor(obj)
|
|
45
|
+
return obj._accessors[self._name]
|
maxframe/core/base.py
CHANGED
maxframe/core/entity/__init__.py
CHANGED
maxframe/core/entity/core.py
CHANGED
maxframe/core/entity/objects.py
CHANGED
maxframe/core/entity/utils.py
CHANGED
maxframe/core/graph/__init__.py
CHANGED
|
Binary file
|
maxframe/core/graph/core.pyx
CHANGED
maxframe/core/graph/entity.py
CHANGED
maxframe/core/mode.py
CHANGED
maxframe/core/operator/base.py
CHANGED
maxframe/core/operator/core.py
CHANGED
maxframe/core/operator/fetch.py
CHANGED
maxframe/core/operator/utils.py
CHANGED
maxframe/core/tests/__init__.py
CHANGED
maxframe/core/tests/test_mode.py
CHANGED
maxframe/dataframe/__init__.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# Copyright 1999-
|
|
1
|
+
# Copyright 1999-2025 Alibaba Group Holding Ltd.
|
|
2
2
|
#
|
|
3
3
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
4
4
|
# you may not use this file except in compliance with the License.
|
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
# limitations under the License.
|
|
14
14
|
|
|
15
15
|
from . import (
|
|
16
|
+
accessors,
|
|
16
17
|
arithmetic,
|
|
17
18
|
datasource,
|
|
18
19
|
datastore,
|
|
@@ -22,7 +23,6 @@ from . import (
|
|
|
22
23
|
indexing,
|
|
23
24
|
misc,
|
|
24
25
|
missing,
|
|
25
|
-
plotting,
|
|
26
26
|
reduction,
|
|
27
27
|
sort,
|
|
28
28
|
statistics,
|
|
@@ -64,6 +64,7 @@ except ImportError: # pragma: no cover
|
|
|
64
64
|
pass
|
|
65
65
|
|
|
66
66
|
del (
|
|
67
|
+
accessors,
|
|
67
68
|
arithmetic,
|
|
68
69
|
datasource,
|
|
69
70
|
datastore,
|
|
@@ -71,7 +72,6 @@ del (
|
|
|
71
72
|
fetch,
|
|
72
73
|
groupby,
|
|
73
74
|
indexing,
|
|
74
|
-
plotting,
|
|
75
75
|
reduction,
|
|
76
76
|
sort,
|
|
77
77
|
tseries,
|