Generalize decodeDim to handle arrays of specific dimensions <> 1.
Merge pull request #155 from pjonsson/fix-decodedim

Generalize decodeDim to handle arrays of specific dimensions <> 1.