A method for encoding transform kernel candidates selected for blocks of a video frame, the method comprising: selecting one of a plurality of transform kernel candidates for transforming a residual block of a current block of the video frame, the selected transform kernel candidate including a vertical transform type associated with a vertical motion of the current block and a horizontal transform type associated with a horizontal motion of the current block; transforming the residual block according to the selected transform kernel candidate to produce a transform block including transform coefficients; quantizing the transform coefficients; responsive to determining that at least one of the quantized transform coefficients is a non-zero coefficient, identifying a probability model for encoding the selected transform kernel candidate, the probability model identified based on a first transform kernel candidate selected for an above neighbour transform block of the transform block and a second transform kernel candidate selected for a left neighbour transform block of the transform block, wherein the above neighbour transform block and the left neighbour transform block are transform blocks transformed from residual blocks of the current block of the video frame, wherein identifying the probability model for encoding the selected transform kernel candidate comprises: determining a vertical context based on a first vertical transform type of the first transform kernel candidate and a second vertical transform type of the second transform kernel candidate; determining a horizontal context based on a first horizontal transform type of the first transform kernel candidate and a second horizontal transform type of the second transform kernel candidate; and identifying the probability model using the vertical context and the horizontal context; wherein the probability model is associated with a context value calculated based upon the vertical context and the horizontal context; and encoding the selected transform kernel candidate using the identified probability model, wherein a first index corresponds to the vertical transform type of the encoded transform kernel candidate and a second index corresponds to the horizontal transform type of the encoded transform kernel candidate. selecting one of a plurality of transform kernel candidates for transforming a residual block of a current block of the video frame, the selected transform kernel candidate including a vertical transform type associated with a vertical motion of the current block and a horizontal transform type associated with a horizontal motion of the current block; transforming the residual block according to the selected transform kernel candidate to produce a transform block including transform coefficients; quantizing the transform coefficients; responsive to determining that at least one of the quantized transform coefficients is a non-zero coefficient, identifying a probability model for encoding the selected transform kernel candidate, the probability model identified based on a first transform kernel candidate selected for an above neighbour transform block of the transform block and a second transform kernel candidate selected for a left neighbour transform block of the transform block, wherein the above neighbour transform block and the left neighbour transform block are transform blocks transformed from residual blocks of the current block of the video frame, wherein identifying the probability model for encoding the selected transform kernel candidate comprises: determining a vertical context based on a first vertical transform type of the first transform kernel candidate and a second vertical transform type of the second transform kernel candidate; determining a horizontal context based on a first horizontal transform type of the first transform kernel candidate and a second horizontal transform type of the second transform kernel candidate; and identifying the probability model using the vertical context and the horizontal context; wherein the probability model is associated with a context value calculated based upon the vertical context and the horizontal context; and determining a vertical context based on a first vertical transform type of the first transform kernel candidate and a second vertical transform type of the second transform kernel candidate; determining a horizontal context based on a first horizontal transform type of the first transform kernel candidate and a second horizontal transform type of the second transform kernel candidate; and identifying the probability model using the vertical context and the horizontal context; wherein the probability model is associated with a context value calculated based upon the vertical context and the horizontal context; and encoding the selected transform kernel candidate using the identified probability model, wherein a first index corresponds to the vertical transform type of the encoded transform kernel candidate and a second index corresponds to the horizontal transform type of the encoded transform kernel candidate.