refactored image directory