Dimensions of left side are,
$\text{K}=[\text{ML}^2\text{T}^{-2}]$
Dimensions of right side are,
$\text{I}^{\text{a}}=[\text{ML}^2]^{\text{a}},\omega^{\text{b}}=[\text{T}^{-1}]^{\text{b}}$
According to principle of homogeneity of dimension,
$[\text{ML}^2\text{T}^{-2}]=[\text{ML}^2\text{T}^{-2}][\text{T}^{-2}]^{\text{b}}$
Equating the dimension of both sides,
2 = 2a and -2 = -b ⇒ a = 1 and b = 2