Implementing a deep learning library in c++

Hey there, I was trying to implement a deep learning library in c++. I had only implemented fully connected layers and was stuck at implementing gradients for convolution layers before my high school final exams started. Now, that I am done with my exams, I have decided to give it another try. Here’s the link to the project =>
If anyone here is familiar with implementing convolutions and their gradients please help me out.
I cannot derive the formula for de-convolution.
And if you are an experienced c++ developer, please look at the code and suggest some ways to make my code more readable and maintainable.