Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Raise error if imageloader finds nothing #30

Merged
merged 1 commit into from
Jul 13, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Raise error if imageloader finds nothing
  • Loading branch information
robertdstein committed Jul 13, 2022

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
commit ca930e0349ad8117c399f78cbd4b8698eaeabbde
5 changes: 5 additions & 0 deletions winterdrp/processors/utils/image_loader.py
Original file line number Diff line number Diff line change
@@ -75,6 +75,11 @@ def _apply_to_images(

logger.info(f"Loading from {input_dir}, with {len(img_list)} images")

if len(img_list) < 1:
err = f"No images found in {input_dir}. Please check path is correct!"
logger.error(err)
raise FileNotFoundError(err)

new_images = []
new_headers = []