From 30171d20e70aaf10ca12c1c0d65b32e4750e248c Mon Sep 17 00:00:00 2001 From: Rehan Durrani Date: Tue, 15 Nov 2022 13:00:35 -0800 Subject: [PATCH] Add list constructor Signed-off-by: Rehan Durrani --- modin/numpy/arr.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/modin/numpy/arr.py b/modin/numpy/arr.py index aa0a5125f40..00f115b22f1 100644 --- a/modin/numpy/arr.py +++ b/modin/numpy/arr.py @@ -5,6 +5,10 @@ class array(object): def __init__(self, object=None, dtype=None, *, copy=True, order='K', subok=False, ndmin=0, like=None, query_compiler=None): if query_compiler is not None: self._query_compiler = query_compiler + elif isinstance(object, list): + import modin.pandas as pd + qc = pd.DataFrame(object)._query_compiler + self._query_compiler = qc else: arr = numpy.array(object, dtype=dtype, copy=copy, order=order, subok=subok, ndmin=ndmin, like=like) pass