Fix support for non local files

This fixes @stof comment at https://github.com/avalanche123/Imagine/pull/311#issuecomment-40057346