Add checks to build cleaner model cards
# What does this PR do?

To avoid model cards being rejected by the metadata validation on the Hub, this PR cleans up a few things:
- removing None values from lists so that a [None] passed for a field is ignored (this fixes #13528 )
- ignoring results that don't have the three keys task, datasat and metrics since those three are mandatory.

