catch_warnings blocks more robust

Explicitely calling clean_warning_registry before with block.
Fix for #3494 
Although the note "to remove once we support numpy 1.7" therefore no longer applies