bugfixes

add missing import of logging
fix image parameter handling