Created
July 3, 2017 18:49
-
-
Save annanay25/4d5126b63b39b0bf2dd5e424b29b87e9 to your computer and use it in GitHub Desktop.
Pseudo code for Conv kernel.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Input = IMG: M x N X P KERNEL: X x Y x P <- Z such kernels. | |
| for (a = Z) | |
| for (i = M) | |
| for (j = N) | |
| for (k = X) | |
| for (l = Y) | |
| for (r = P) | |
| sum += IMG[ i -X/2 + k , j - Y/2 + l , r ] * KERNEL [ k , l , r ] | |
| ConvOutput[ i , j , a ] = sum | |
| Output = ConvOutput Matrix |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment