[RELAY][BYOC] Fix the creation of tuple of tuples in PartitionGraph (#5616)
authormanupa-arm <61496855+manupa-arm@users.noreply.github.com>
Wed, 20 May 2020 15:27:54 +0000 (16:27 +0100)
committerGitHub <noreply@github.com>
Wed, 20 May 2020 15:27:54 +0000 (08:27 -0700)
commitc286b2dff061f32a7bc6d43f99921954ade4deb3
treee706f66da8411528c738fbe914bb470c57b3c165
parentd8b185c674f56a71479cee3381c0655f1633d1d8
[RELAY][BYOC] Fix the creation of tuple of tuples in PartitionGraph (#5616)

* [RELAY][BYOC] Fix the creation of tuple of tuples in PartitionGraph

If the annotated compiler region contains multiple outputs where
some of the outputs are tuple output, the current PartitionGraph will
create tuple of tuples. This will not be handled by the runtime.
This commit flattens the such tuples and re-create them after the
call site of the partitioned function.

Change-Id: I4e7ccbda73c129a9f4ae8705d5c9f2af6ab99ef6

* [RELAY][BYOC] Fix the creation of tuple of tuples in PartitionGraph

    *code refactor : extracted the passes as a sequential

Change-Id: If4bc00b00a96fa244358d602fc1a361498342f46

* [RELAY][BYOC] Fix the creation of tuple of tuples in PartitionGraph
   *further refactor

Change-Id: I69ddd0e835e88ef97da8a3a3b949be3f7b619c02

* [RELAY][BYOC] Fix the creation of tuple of tuples in PartitionGraph
    *class description comment amended

Change-Id: I55720bf0467c96e979e1ab56c40d9d209e0f9456
src/relay/transforms/partition_graph.cc
tests/python/relay/test_pass_partition_graph.py