It fails if ```width``` or ```height``` is only set for some formats. E.g. in YoutubeIE for some video's width and height is known but audio files have no width and height.
In this case ```Int``` and ```NoneType``` are compared, which leads to an ```TypeError```.