tenstorrent / tt-metal

:metal: TT-NN operator library, and TT-Metalium low level kernel programming model.
Apache License 2.0
422 stars 54 forks source link

Implement ttnn yolov4 with new conv API #10270

Closed punithsekar closed 3 weeks ago

punithsekar commented 2 months ago

Implement ttnn yolov4 and demo for yolov4 with new conv API(ttnn.conv2d).

punithsekar commented 2 months ago

10068 contains the implementation of ttnn yolov4 with new conv API.

Currently, In neck sub-module we are using torch max_pool as these configurations are making issues #7746 and we are facing low pcc for two outputs of the neck sub-module(0.94 & 0.96) when we use leakyrelu as activation. If we keep relu then the pcc's are >0.99.

In head sub-module, we are using torch conv in three places as out_channels=255 is not working fine(#10256).

While running yolov4 module we are facing OOM issue in DS5 sub_module first conv itself, But while running DS5 separately works fine.

Also in DS1 to DS5 we are using relu instead mish activation due to following issue in ttnn.mish(#9877).

punithsekar commented 2 months ago

All the sub-modules and yolov4 model works fine, the YOLOv4 model produces three outputs, and their PCC are greater than 0.95, 0.96, and 0.98, respectively.

Conv issue : 10256 maxpool : 7746 Mish issue : 9877

Currently three fallback conv is used and three maxpool operations are used in the pipeline.

punithsekar commented 2 months ago

Issue #10256 has been closed, The latest perf sheets have been updated in the PR #10068.

keerthana-r-mcw commented 3 weeks ago

Closing this issue, since yolov4 is implemented using new conv-api and merged to main.