tmoreau89 commented on issue #4318: [Relay][TOPI]Fix meaning of 
conv2d_transpose output_padding parameter
URL: https://github.com/apache/incubator-tvm/pull/4318#issuecomment-557766083
 
 
   @abergeron: I have good new and bad news. The *good news* is that I was able 
to find the root cause of the observed bug. By changing the 
`conv2d_transpose_nchw` function signature by adding the `output_padding` 
argument, we are essentially changing the TOPHUB schedule lookup convention for 
that operator. In other words, AutoTVM fails to find the schedule for the 
conv2dtranspose operator because the argument list of the operator doesn't 
match. Due to this, the schedule defaults to an illegal one for VTA which 
triggers the error we're seeing in the CI.
   
   In order to circumvent the error the fix will be straightforward on your 
end: just change `v0.06` to `v0.07` here: 
https://github.com/apache/incubator-tvm/blob/master/python/tvm/autotvm/tophub.py#L59
   
   I've updated the schedule for VTA with this commit: 
https://github.com/uwsampl/tvm-distro/commits?author=tmoreau89
   
   Essentially I changed the DCGAN schedules from 
   `["conv2d_transpose_nchw", [1, 64, 4, 4, 1, 16, "int8"], [32, 64, 4, 4, 16, 
16, "int8"], [2, 2], [1, 1], "int32"]` 
   to 
   `["conv2d_transpose_nchw", [1, 64, 4, 4, 1, 16, "int8"], [32, 64, 4, 4, 16, 
16, "int8"], [2, 2], [1, 1], "int32", [0, 0]]`
   
   The *bad news* is that this will need to be modified for all hardware 
targets under tophub. For instance the CUDA schedule will need to change: 
https://github.com/uwsampl/tvm-distro/blob/master/tophub/cuda_v0.06.log#L690 
among other targets. 
   
   In order to do so, I recommend first creating new schedule files under a new 
"package version" and then switching the package version in your PR in 
`tophub.py` in order not to break other unit tests. The reason why this is not 
causing an error is that CPUs and GPUs schedules default to valid, albeit slow 
ones (VTA is just unstable and not all schedules will lead to correct 
execution, we need a better defaulting mechanism).
   
   Finally, I also created a branch that will fix some scripts under VTA that 
will be affected from your change. If you could cherry pick my commits into 
your branch that would be great: https://github.com/tmoreau89/tvm/tree/4318_fix

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to