Skip to content

Commit 6b6fbb4

Browse files
Merge pull request #4 from hamzaqureshi5/ds0
refactor: named changes
2 parents 4252144 + 28aedae commit 6b6fbb4

File tree

1,147 files changed

+169426
-13785
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,147 files changed

+169426
-13785
lines changed

conftest.py

Lines changed: 0 additions & 87 deletions
This file was deleted.
File renamed without changes.
Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -21,38 +21,38 @@
2121
import os
2222

2323
# top-level alias
24-
# datagen._ffi
24+
# gsm_data_generator._ffi
2525
from .base import DATAGENError, __version__#, #_RUNTIME_ONLY
2626

2727
# from .ffi import register_object, register_func, get_global_func
2828

2929
# # top-level alias
30-
# # datagen.runtime
30+
# # gsm_data_generator.runtime
3131
# from .runtime.object import Object
3232
# from .runtime.ndarray import device, cpu, cuda, opencl, vulkan, metal
3333
# from .runtime.ndarray import vpi, rocm, ext_dev, hexagon
3434
# from .runtime import ndarray as nd, DataType, DataTypeCode
3535

36-
# datagen.error
36+
# gsm_data_generator.error
3737
from . import error
3838

39-
# datagen.ir
39+
# gsm_gsm_datagen.ir
4040
# from .ir import IRModule
4141
# from .ir import transform
4242
# from .ir import instrument
4343
# from .ir import container
4444
# from . import ir
4545

46-
# # datagen.tir
46+
# # gsm_gsm_datagen.tir
4747
# from . import tir
4848

49-
# # datagen.target
49+
# # gsm_gsm_datagen.target
5050
# from . import target
5151

52-
# # datagen.te
52+
# # gsm_gsm_datagen.te
5353
# from . import te
5454

55-
# # datagen.driver
55+
# # gsm_data_generator.driver
5656
# from .driver import build, compile
5757

5858
# # others
@@ -76,19 +76,19 @@
7676

7777
def _should_print_backtrace():
7878
in_pytest = "PYTEST_CURRENT_TEST" in os.environ
79-
datagen_backtrace = os.environ.get("DATAGEN_BACKTRACE", "0")
79+
gsm_datagen_backtrace = os.environ.get("DATAGEN_BACKTRACE", "0")
8080

8181
try:
82-
datagen_backtrace = bool(int(datagen_backtrace))
82+
gsm_datagen_backtrace = bool(int(gsm_datagen_backtrace))
8383
except ValueError:
8484
raise ValueError(
85-
"invalid value for DATAGEN_BACKTRACE {}, please set to 0 or 1.".format(datagen_backtrace)
85+
"invalid value for DATAGEN_BACKTRACE {}, please set to 0 or 1.".format(gsm_datagen_backtrace)
8686
)
8787

88-
return in_pytest or datagen_backtrace
88+
return in_pytest or gsm_datagen_backtrace
8989

9090

91-
def datagen_wrap_excepthook(exception_hook):
91+
def gsm_datagen_wrap_excepthook(exception_hook):
9292
"""Wrap given excepthook with DATAGEN additional work."""
9393

9494
def wrapper(exctype, value, trbk):
@@ -107,4 +107,4 @@ def wrapper(exctype, value, trbk):
107107
return wrapper
108108

109109

110-
sys.excepthook = datagen_wrap_excepthook(sys.excepthook)
110+
sys.excepthook = gsm_datagen_wrap_excepthook(sys.excepthook)
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
"""FFI APIs for tvm.arith"""
18+
import gsm_data_generator.ffi
19+
20+
21+
gsm_data_generator.ffi._init_api("arith", __name__)

0 commit comments

Comments
 (0)