- 17 Oct, 2022 1 commit
-
-
Ted Themistokleous authored
- Handle checks for each IF output - add const to inputs of all_but_last_dims_equal - add std::equal instead of using equal - Use .back() for vectors in getting last value - Use input().front() instead of prev(prev()) when replacing the last value.
-
- 15 Oct, 2022 1 commit
-
-
Ted Themistokleous authored
-
- 14 Oct, 2022 4 commits
-
-
Ted Themistokleous authored
-
Ted Themistokleous authored
Check which shape is larger and adjust the check using equals so we never have the option of going out of range with different sizes outside of the smaller vector.
-
Ted Themistokleous authored
- rename then/else_shapes -> then/else_lens - change assert for shape size to reusing throw() - return lengths in handle_empty_branch - use handle_empty_branch return value for lens update - use std::prev() instead of predecriment operator for modifying nodes
-
Ted Themistokleous authored
Outline of an empty branch is correct typically seen if we parse in an empty constant for the other side of the if then/else onnx logic. Need to do this to match shape even though the other branch is just empty.
-
- 13 Oct, 2022 3 commits
-
-
Ted Themistokleous authored
Just clean up the logic on this so we're not 5 levels deep on ifs.
-
Ted Themistokleous authored
- use empty() instead of size() == 0 for checking each condition - Make each branch a lambda instead of repeating code.
-
Ted Themistokleous authored
Fixes cases for trailing one testcases
-
- 12 Oct, 2022 2 commits
-
-
Ted Themistokleous authored
This makes sure we're getting the correct output value of the branch if an empty shape is given as a parameter to the IF operand.
-
Ted Themistokleous authored
-
- 08 Oct, 2022 1 commit
-
-
Ted Themistokleous authored
- Gets past to the split section of the resnext model - adding outline seems to solve if issues but verify calls broken - Referencing wrong element now instead of output of correct if block? - Need to determine proper output through verify tests. - Modified protobuf to handle case of extra 1 to "vectorize" scalar - Modified verify/tests to get things to "work", may need to be revised further.
-
- 07 Oct, 2022 1 commit
-
-
Ted Themistokleous authored
- Update if_then/else_empty test protobuff and cases - Need to update rand() vector used - Make y empty instead of x for if_else_empty_test.onnx - Regenerate protobufs with updates - Add changes to handle empty/scalar input branch size to if operator. - Add case where if both branches empty throw an error. - Update verify tests with gold vectors and new shapes for empty input vec which we handle like a scalar before broadcasting
-
- 04 Oct, 2022 10 commits
-
-
Ted Themistokleous authored
Still busted work in prgoress. Keep running into terminate called after throwing an instance of 'migraphx::version_1::exception' what(): /code/AMDMIGraphX/src/normalize_attributes.cpp:91: tune_attribute: TUNE_VECTOR: value out of range! Aborted (core dumped)
-
Ted Themistokleous authored
-
Ted Themistokleous authored
-
Ted Themistokleous authored
Comming back to this once I've fixed parse_constant, looks like unallocated empty literals break this right now.
-
Ted Themistokleous authored
Need to have this to force the output to be a compatible to both the else/then cases Still a work in progress
-
Ted Themistokleous authored
Need to handle static shapes explicitly since onnx says we should be able to just output a compatible output type.
-
Ted Themistokleous authored
-
Ted Themistokleous authored
-
Ted Themistokleous authored
-
Ted Themistokleous authored
The onnx spec mentions that the output shape of the resulting then/else branches must share the same type, but not the same shape. The only requirement is that the first dimension is compatible should one of the inputs have rank of one. Without this we prematurely assert when an if is requred on the following case int64, {1234, 1} (this is a 1 rank tensor) int64, {1234} (this result is scalar)
-
- 27 Jul, 2022 1 commit
-
-
Ted Themistokleous authored
Gives better clarity to which argument is throwing an error, especially in cases with nested IF statements in the network.
-
- 22 Jun, 2022 1 commit
-
-
Ted Themistokleous authored
Updated each source file in the repo with the existing license.
-
- 27 Jun, 2021 1 commit
-
-
Shucai Xiao authored
* Add definitions for all pointwise operators * Formatting * Add cpp generator class * Formatting * Move compilation to core * Formatting * Add clock to tmp name * Add dynamic loader * Formatting * Add tests for code gen * Formatting * Add test for literals * Formatting * Use with_char * Add missing header * Fix mismerge * Ignore tidy warning * Fxx gcc 5 errors * Apply fixits * Skip signed bitwise of status * Remove unused parameters * Explicitly add c++14 flag * Fix tidy warning * unify the compute function signature * clang format * make another change * unify the compute function * clang format * remove unnecessary code * more refinement about the operator compute funciton * clang format * add an overload function * clang format * add support for axes inputs for sequeeze/unsqueeze/reduce_sum * clang format * fix build problems * backup code changes * clang format * Add tuple type to shape class * Formatting * fix a bug in parsing quantizelinear operator * clang format * fix a cppcheck error * disable different versions of unit tests for different onnx version * clang format * upgrade onnx to 1.8 * update onnx to 1.8.1 * disable two more real models * clang format * Make data member private * Formatting * Add sub arguments * Formatting * Trun clang format off * Disable clang-format * fix review comments * fix the function of assign axes in parsing the squeeze operator * add unit tests and fix a bug * clang format * fix review comments * clang format * fix a build error * backup code changes * clang format * add more unit tests and add parsing opset version * clang format * Improve visiting tuples * Formatting * fix cppcheck error * adding installing the onnx package * resolve no protobuf compiler * add an inline subgraph pass * clang format * Add more argument tests * Formatting * Handle tuple in load * Formatting * code backup * clang format * Remove .o files * Add tuple type to api * Formatting * fix build errors * clang format * code backup * code backup * add unit tests for the inline subgraph * clang format * refine the inline subgraph and parse if operator * clang format * fix cppcheck issue * clang format * add unit test for inline subgraph pass * clang format * fix format issue * remove the context from the if operator * clang format * simplify the compute functions * Fix tidy warnings * fix cppcheck error * clang format * fix cppcheck error * Fix tidy warnings * fix a cppcheck error * clang format * Add a test for share method * Formatting * Add a test cpp_type * add unit tests for more code coverage * clang format * add unit tests to have more code coverage * clang format * try a comment in jenkins build * include the install onnnx line * code backup * reorder the dependenciesd installed * refine dockerfile * fix review comments * clang format * remove unnecessary overload function * fix cppcheck error * change back the argument test * Suppress tidy warning * add the operator get_tuple_elem * clang format * add get_tuple_elem to operator include file * chang if to support multiple operation outputs * clang format * optimize inline subgraph * clang format * code backup * clang format * fix bug * refine unit tests for tuple output of the if operator * clang format * refine a instruction replacement code * add a unit test and sort all the unit tests alphabetically * fix cppcheck error * add more unit tests for multiple op outputs * clang format * fix cppcheck error * Update pass manager to get modules after every pass * more unit test to cover more scenarios * clang format * fixed a bug in a unit test * add more tests * clang format * add more unit tests to have more code coverage * fix a bug in a unit test * Add program overload for module * Formatting * Hash modules for quicker lookup of modules * Bump file version * Add methods to remove modules * Formatting * add the tuple type to the support list * Eliminate unused modules * Formatting * Fix test errors * Foramtting * Fix tidy issues * fix problem related to inline subgraph * clang format * fix review comments * fix review comments * fix review comments * fix review comments * clang format * fix a unit test * one more code change * remove an optimization related to the if operator * clang format * fix review comments Co-authored-by:
Paul <pfultz2@yahoo.com> Co-authored-by:
mvermeulen <5479696+mvermeulen@users.noreply.github.com>
-
- 05 Apr, 2021 1 commit
-
-
Shucai Xiao authored
* code cleanup * clang format * backup code * clang format * remove unnecessary code * clang format * add module print function * code backup * refine the module::print function * refine the module:to_value() function * code backup * backup code changes * code backup * remove to_value and from_value function from the module class * rename a function * rename the if operator * refine the if operator * refine the print function of module and program * code backup * code backup * fix a build warning * fix overload of compute_shape function * code backup * fix unit test error * fix cppcheck error * fix the issue related to the overload of compute_shape * fix review comments * fix cppcheck error * change the return name of if_op to be if * clang format * fix two unit tests * clang format * rename variables * clang format * remove the unused compute_op function * clang format * add lowering of if operator and compute_op function * clang format * add parsing if operator in onnx file * clang format * fix clang tidy format * clang format * add the gpu implementation of the if operator * enhance the validate function and uncomment a unit test * clang format * remove unnecessary code * add sub_module processing in ref passes * clang format * clang format * fix a hang issue related to the valid function * fix an issue in replace_refs * clang format * fix review comments * clang format * fix cppcheck error * clang format * add a unit test for more code coverage * clang format * fix review comments and add test for more code coverage * clang format * fix cppcheck error * clang format * fix cppcheck error * fix a cppcheck error * clang format * backup code * clang format * fix cppcheck error * clang format * some code refinement * clang format * code backup to handle submodules in module compilation * clang format * code backup * clang format * code backup * clang format * fix a bug related to literal id * fix a bug in gpu execution * change the way of compiling a graph * clang format * backup more changes * clang format * refine pass log information * remove unnecessary code * clang format * temp changes backup * clang format * add module name prefix to scratch memory id in hip_memory_allocation * clang format * change to copy the cond input by inserting a copy instruction * clang format * change to use the if output argument as the submodule output so can remove a gpu_copy * clang format * consider submodule in some compile passes * clang format * fix review comments * clang format * fix issues related to scratch memory * clang format * remove unnecessary code * fix cppcheck error * clang format * reslove the implicit dependencies issue related to submodule * clang format * fix cppcheck error * clang format * backup temp changes * clang format * fixed an bug in the has_instruction function * clang format * fix the return value of the gpu implementation of the if operator * fix a bug in the compute_shape function in the gpu implementation * add an if onnx unit test * clang format * add more unit tests * clang format * tmp code backup * clang format * fix a sync problem related to copy cond argument from gpu to cpu * clang format * change the compile offload copy flag setting * clang format * enable copy from cpu to be able to do synchronous copy * clang format * add more unit tests * add more unit tests * add more ref unit tests * clang format * fixed a bug error * tmp code backup * clang format * fixed an onnx verify unit test * add more unit tests * clang format * reverse a change * fix cppcheck error * fix cppcheck error * fix to print all instructions in program execution * clang format * fix bugs related to memory coloring and offload copy to be true * clang format * remove unnecessary include header file * sort test cases in ref_cpu_ops alphabetically * clang format * add a flag to disable cpu target in verification test * change the way to disable some tests * clang format * disable verify unit test of the if operators * add a function call to have more code coverage * fix a build error * fix review comments * fix review comments * clang format * add a api gpu unit test for more code coverage * clang format * change to use instruction.size() as node index * move the calc_implicit_deps function to module class as a member function * clang format * move the offload_copy flag setting to lowering * clang format * assign the module_eval lambda function to a variable to simplify code * clang format * move the compute function from ref/gpu implementation to the main if operator * clang format * fix cpp check error * add a unit test for more code coverage * clang format * add unit test to calculate implicit deps * add a python unit test * clang format * refine a unit test to have more code coverage * clang format * chang the way of wrap up arguments for sub modules * clang format * fix some build errors * code cleanup * refine unit tests to have more code coverage * clang format * refine unit test to have more code coverage * code backup * clang format * add memory coloring test * refine memory coloring unit test * clang format * remove an unnecessary line * remove an unused line * remove an unnecessary parameter in the lambda function * clang format * refine a unit test * remove an unnecessary line * refine unit tests to have more code coverage * clang format * combine two lines * add one more unit test for more code coverage * clang format * add one more unit test * clang format * fix review comments * refine a print out information * fix review comments * clang format * change the sync copy to using a gpu device sync * clang format * remove unnecessary code Co-authored-by:mvermeulen <5479696+mvermeulen@users.noreply.github.com>
-
- 26 Feb, 2021 1 commit
-
-
Shucai Xiao authored
* if operator support with constant condition input * clang format * add a missing file * clang format * add an onnx verifcation unit test for the if operator * clang format' * fix review comments * temp version to try jenkin build * remove unnecessary changes * unit tests refinement for more code coverage * clang format * try a mutex to fix possible race condition in onnxruntime tests * tmp changes to try jenkins build * remove unnecessary code * fix review comments Co-authored-by:mvermeulen <5479696+mvermeulen@users.noreply.github.com>
-