From c3cd7359a004ff28bec1fed6dcad5640f71e4a9f Mon Sep 17 00:00:00 2001 From: vlad-perevezentsev Date: Fri, 4 Dec 2020 05:42:08 -0600 Subject: [PATCH 1/2] add the new dparray class inder dpctl.dptensor.dparray --- MANIFEST.in | 1 - dpctl/__init__.pxd | 2 +- dpctl/dptensor/__init__.py | 1 + dpctl/{ => dptensor}/dparray.py | 0 dpctl/tests/__init__.py | 1 + dpctl/tests/test_dparray.py | 2 +- 6 files changed, 4 insertions(+), 3 deletions(-) create mode 100644 dpctl/dptensor/__init__.py rename dpctl/{ => dptensor}/dparray.py (100%) diff --git a/MANIFEST.in b/MANIFEST.in index fe7b0bebb4..43d8bddba4 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,5 +1,4 @@ include versioneer.py -include dparray.py recursive-include dpctl/include *.h *.hpp include dpctl/*.pxd include dpctl/*DPPL*Interface.* diff --git a/dpctl/__init__.pxd b/dpctl/__init__.pxd index ce55613b23..86b66be9d6 100644 --- a/dpctl/__init__.pxd +++ b/dpctl/__init__.pxd @@ -29,4 +29,4 @@ from dpctl._sycl_core cimport * from dpctl._memory import * -from .dparray import * +from dpctl.dptensor.dparray import * diff --git a/dpctl/dptensor/__init__.py b/dpctl/dptensor/__init__.py new file mode 100644 index 0000000000..5fe6f3ac9b --- /dev/null +++ b/dpctl/dptensor/__init__.py @@ -0,0 +1 @@ +from .dparray import * diff --git a/dpctl/dparray.py b/dpctl/dptensor/dparray.py similarity index 100% rename from dpctl/dparray.py rename to dpctl/dptensor/dparray.py diff --git a/dpctl/tests/__init__.py b/dpctl/tests/__init__.py index a53980d17a..25c4d2f42b 100644 --- a/dpctl/tests/__init__.py +++ b/dpctl/tests/__init__.py @@ -30,3 +30,4 @@ from .test_sycl_queue_manager import * from .test_sycl_queue_memcpy import * from .test_sycl_usm import * +from .test_dparray import * diff --git a/dpctl/tests/test_dparray.py b/dpctl/tests/test_dparray.py index b0192cd987..1dd597b167 100644 --- a/dpctl/tests/test_dparray.py +++ b/dpctl/tests/test_dparray.py @@ -1,5 +1,5 @@ import unittest -from dpctl import dparray +from dpctl.dptensor import dparray import numpy From 359b5dcf22356eb3f6d4ae4e01b981ae232b1f7d Mon Sep 17 00:00:00 2001 From: vlad-perevezentsev Date: Fri, 4 Dec 2020 05:42:08 -0600 Subject: [PATCH 2/2] add the new dparray class inder dpctl.dptensor.dparray --- MANIFEST.in | 1 - dpctl/__init__.pxd | 2 +- dpctl/dptensor/__init__.py | 1 + dpctl/{ => dptensor}/dparray.py | 0 dpctl/tests/__init__.py | 1 + dpctl/tests/test_dparray.py | 2 +- 6 files changed, 4 insertions(+), 3 deletions(-) create mode 100644 dpctl/dptensor/__init__.py rename dpctl/{ => dptensor}/dparray.py (100%) diff --git a/MANIFEST.in b/MANIFEST.in index fe7b0bebb4..43d8bddba4 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -1,5 +1,4 @@ include versioneer.py -include dparray.py recursive-include dpctl/include *.h *.hpp include dpctl/*.pxd include dpctl/*DPPL*Interface.* diff --git a/dpctl/__init__.pxd b/dpctl/__init__.pxd index ce55613b23..86b66be9d6 100644 --- a/dpctl/__init__.pxd +++ b/dpctl/__init__.pxd @@ -29,4 +29,4 @@ from dpctl._sycl_core cimport * from dpctl._memory import * -from .dparray import * +from dpctl.dptensor.dparray import * diff --git a/dpctl/dptensor/__init__.py b/dpctl/dptensor/__init__.py new file mode 100644 index 0000000000..5fe6f3ac9b --- /dev/null +++ b/dpctl/dptensor/__init__.py @@ -0,0 +1 @@ +from .dparray import * diff --git a/dpctl/dparray.py b/dpctl/dptensor/dparray.py similarity index 100% rename from dpctl/dparray.py rename to dpctl/dptensor/dparray.py diff --git a/dpctl/tests/__init__.py b/dpctl/tests/__init__.py index a53980d17a..25c4d2f42b 100644 --- a/dpctl/tests/__init__.py +++ b/dpctl/tests/__init__.py @@ -30,3 +30,4 @@ from .test_sycl_queue_manager import * from .test_sycl_queue_memcpy import * from .test_sycl_usm import * +from .test_dparray import * diff --git a/dpctl/tests/test_dparray.py b/dpctl/tests/test_dparray.py index b0192cd987..1dd597b167 100644 --- a/dpctl/tests/test_dparray.py +++ b/dpctl/tests/test_dparray.py @@ -1,5 +1,5 @@ import unittest -from dpctl import dparray +from dpctl.dptensor import dparray import numpy