* Docker env for Arm® Ethos™-U55 Port
* Added Arm® Corstone™-300 Reference System for testing
* Added Arm® Ethos™-U driver stack
* Added installation of Arm® Vela.
Co-authored-by: Manupa Karunaratne <manupa.karunaratne@arm.com>
Change-Id: Ie3cc43943c876d95618a39887aa666da20bcb1e4
* Docker env for Arm® Ethos™-U55 Port
* Removes /opt/arm/cmake/bin from the path
* Parameterizes Arm® Ethos™-U55 driver stack version number
Change-Id: I2162b40f82241fd013643cbfa8847b60d7f4f5a1
* Docker env for Arm® Ethos™-U55 Port
* Adds ethosu as an extra to /python/gen_requirements.py
Change-Id: I2162b40f82241fd013643cbfa8847b60d7f4f5a1
* Docker env for Arm® Ethos™-U55 Port
* Added comment explaining why Vela version needs to be pinned to 2.1.1
Change-Id: I1ade280faa5274cca78899f4dae9e596b16fb5df
* Introduce --interface-api={c,packed} parameter
This introduces structures generated to provide a documented and stable user
friendly interface to a TVM generated model, as can be seen in the AOT
demo application:
```
struct tvmgen_default_inputs inputs = {
.input_1 = input_data,
};
struct tvmgen_default_outputs outputs = {
.output = output_data,
};
int ret_val = tvmgen_default_run(&inputs, &outputs, NULL, NULL);
```
To facilitate this, some other changes are included:
* Removed dependency on `aot_executor.{c,h}` in tests, pending the
discussion in the interface RFC as to whether we keep them.
* Moved creation of test DLTensor's into the AOT test utils, in future this
can be replaced by loading via the Python API or otherwise
* Introduce `parametrize_aot_options` which can be used to test
permutations of AOT which work together - for now this filters C
interface and packed operators
* Updated demo application to generate the header for demonstration
purposes, we should consider porting the demo application to Model
Library Format and using the toolchain in the Zephyr App via CMake
instead?
This patch builds upon the improvements @giuseros made to AOT testing
and name mangling from #8014
* Tweak metadata variable description and MLF target loop
* Remove direct usage of `relay::Var` in meta_data.h
This looks like the only place that could be causing the Windows CI failures, so trying removing the additional header in meta_data.h
* Linting fix
* Post-rebase files fixing
These tests were somehow transmuted in transit, I've updated them to the
most recent variant of the test helpers.
* Strip back interface API to just inputs and outputs
This removes any speculative structures from the generated code and cleans up some of the documentation.
* Add header guards and tweak documentation
* [TOPI][CUDA] Improve the performance of scatter_nd by:
1. Split into 2 kernels, one does the "Init" and another does the "Update".
Thus they can have different Grid/Block configurations to better utilize
SMs.
2. Use atomic_add instead of direct assignment, which could avoid the race
condtion when multiple indices point to the same location of the output
tensor. With this moidification, it's safe now to use more CUDA threads
to gain more parallelism.
* Fix python code format.
* FIX: [TOPI][CUDA] Improve the performance of scatter_nd #8479
- Split ScatterND kernel into 2 sub-kernels using ib.new_scope()
- Replace ib.for_range() with blockIdx.y
- Using atomic_add when mode == "add"
- Keep threadIdx.x less than max_threads of GPU
* Comment added
* Add fallback implementation when "mode=add" meets int64
- Atomic_add from CUDA doesn't support int64 data type
- Change "ind{i}" to "ind%d"%i, where names of relay.var could correctly display
* Python format
* Fix line too long
* CI pass
* Empty, for CI pass
* Empty, for CI pass
* Empty, for CI pass
* Empty, for CI pass
* Empty, for CI pass
* Exchange blockIdx.x and blockIdx.y
* check for Vulkan or metal
* Fallback to previous algorithm when mode==update
* Update python/tvm/topi/cuda/scatter.py
Co-authored-by: Tristan Konolige <tristan.konolige@gmail.com>
* Assign TODO
* Swapping then and else block
Co-authored-by: wenxizhu <wenxizhu@tencent.com>
Co-authored-by: CaptainDuke <captainduke328@gmail.com>
Co-authored-by: Tristan Konolige <tristan.konolige@gmail.com>
* hotfix check_grad perf regression: lift compile out of hot loop
* hoist interpreter creation out of python closure, fix weird conv2d bug on arm cpu
* lint
* try one more fix
* Remove all attr::storage_scope usage
* pyformat
* fixed VTA tests
* Update TIR text printer to print storage_scope on allocate
* print storage scope in AllocateNode ReprPrinter
* Fixed accidently removed scope tag check
* remove unused function
Co-authored-by: masa <masa@pop-os.localdomain>
* Add basic support for batch matmul transpose
* Update
* Lint fix & add tf convert support
* Update
Lint fix
* Bug fix for qnn.batch_matmul
* Bug fix for tensorflow test
* Add grad support for batch_matmul
* Lint fix
Re-triggle CI
Bug fix
Re-triggle CI
Re-triggle CI
Re-triggle CI
* Fix issue in 'vectorize' function for 1D and 3D tensors
* Add pooling tests for channel last layouts
* Add support for more general layouts in "poolnd" implementation
* Reformat with 'black'
* Fix lint issues
* [Contrib] Added default non-verbose to download_testdata(), pass to download().
Minor cleanup as well, while in the file
- Using tempfile.TemporaryDirectory instead of explicit cleanup.
- Pass through verbose/retries arguments if replacing a corrupted
copy.
* [Contrib] Switched download.py from print statements to logging
* [Contrib] Added shutil.copy2 fallback after downloading file.
Initial implementation using tempfile.TemporaryDirectory assumed that
the tempdir and output location were on the same drive, and could be
renamed. This update falls back to copying from the temporary
directory, in case the tempdir is on a different drive.
Co-authored-by: Eric Lunderberg <elunderberg@octoml.ai>
In TFLite 2.4, the builtin code value can be either in
"deprecated_builtin_code" field or "builtin_code" field (as long
as the value is less than 127) and similarly to the TFLite's
reader, we should use the higher value of the two.
Change-Id: I0d738f9257187903b4c5b4cc5a8733a451ddc02e
* [UnitTests][Topi] Updated test_topi_conv2d_nchw.py to have parametrized tests.
- Better error messages, displays which workloads/targets failed and why.
- Fixed bug in topi.nn.conv2d._get_workload exposed by the
parametrized tests. Incorrect padding if the "SAME" parameter is
used with dilation>1.
- Fixed bug in tvm.topi.x86.group_conv2d._get_default_config, missing
dilation parameter in call to _get_conv2d_workload.
* [UnitTests][Topi] Parametrized the tests in test_topi_depthwise_conv2d.py
In preparation for parametrizing to test on float16 as well.
- Single test_conv2d test with parameters for layout/input sizes.
- Extended the support for NCHWc layouts, so that they could be
included in the parametrization. (Implemented
topi.testing.depthwise_conv2d_python_nchwc and
topi.nn.scale_shift_nchwc, added layout argument to
topi.nn.depthwise_conv2d._get_workload).
Co-authored-by: Eric Lunderberg <elunderberg@octoml.ai>
* [Relay to Onnx]
* Added support for resize2d op
* Added unit test
* [Relay to Onnx][Resize]
* Fixed formatting errors
* [Relay to Onnx][Resize]
* Fixed issue in resize conversion: round maps to round_preferc_ceil
* Updated resize unit test to test for coordinate transform mode and
round
* Known issue: Does not match for (NN, align_corners) and Cubic
* * Fixed formatting errors
* * Fixed some more formatting errors
* lstm layer conversion to relay from pytorch model (TorchScript) was supported
* bidirectional LSTM layer was supported for pytorch API
* lstm tests were implemented. fixes in pytorch lstm
* fix pytorch bidirectional lstm. update test comment
* black format and some small fixes
* LSTM with projection was supported for pytorch frontend. test was updated by new combination of LSTM types
* lint fixes
* add bias switcher for LSTM types test. fix LSTM implementation in pytorch frontend for case without biases. exception in the test for conversion LSTM with projection from pytorch to ONNX
* transfer test_lstms to pytest format
* onnx model saving was implemented through io.BytesIO. creating/removing tmp dir was removed. remove unneccessary comments
* gpu target was added to the test
Co-authored-by: Valery Chernov <valery.chernov@deelvin.com>
* add failing onnx tets
* point jenkins at new docker
* support convtranspose opset 11 autopadding
* Don't force output shape for conv transpose tests, add 1D and 3D cases
* disable test until CI update complete
* try updating docker images again
* skip a test until update complete
* next try at docker images
* manage TF memory use in TF1 tests
* support explicit padding for NCHW TF padding test
* Update to tagged tlcpack images
Thanks, Andrew!
Co-authored-by: Andrew Reusch <areusch@gmail.com>
Co-authored-by: Andrew Reusch <areusch@gmail.com>
* Update _nn.py
add a few missing shape functions
* Update _nn.py
Updated conv_transpose shape function to accomodate conv1d_transpose
* added tests for new functions
* fixed a lint error
* fixed shape func error
* attempt fixing cuda error
* fix for strided_slice when begin > end in case of shrinkaxis_mask
* fix for name_hint missing error for concat_v2 op
* removing a local fix
* adding more testing capability to concat_v2