oreilly-japan / deep-learning-from-scratch-3

『ゼロから作る Deep Learning ❸』(O'Reilly Japan, 2020)
MIT License
735 stars 291 forks source link

Implementation ideas of backpropagation of concat operator #39

Open owenliang opened 10 months ago

owenliang commented 10 months ago

This book is the best deep learning book I have ever seen. With your help, I also wrote a framework with personal characteristics.

At the end of the study of the whole book, I have one more technical detail that I would like to ask you about, which is the frequently used "concat" operator. Its backpropagation involves the reverse splitting of gradient, which I really can't figure out. , can you provide some ideas or add this method to dezero, thank you.

koki0702 commented 10 months ago

Thank you for reading this book. I would love to think about that question ("concat"), but I'm busy writing my next book right now.

I would like to take some time when I finish writing my next book. Or maybe someone else can help you (I announced it on Twitter).

laksjdjf commented 10 months ago

I implemented it like this. https://github.com/laksjdjf/dezero-diffusion/blob/a223c7e2bb06e149ff0a8b0714fcc88fb38b08b7/modules/unet.py#L10-L40

owenliang commented 10 months ago

I implemented it like this. https://github.com/laksjdjf/dezero-diffusion/blob/a223c7e2bb06e149ff0a8b0714fcc88fb38b08b7/modules/unet.py#L10-L40

3Q,slice helps a lot! Wish this issue also helps others.