Skip to content
Draft
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion src/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def apply_preprocessors(self, file_path, in_omr, template):
in_omr = pre_processor.apply_filter(in_omr, file_path)
return in_omr

def read_omr_response(self, template, image, name, save_dir=None):
def read_omr_response(self, template, image, name, save_dir=None, colored_image=None):
config = self.tuning_config
auto_align = config.alignment_params.auto_align
try:
Expand Down
5 changes: 4 additions & 1 deletion src/entry.py
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,10 @@ def process_files(
files_counter += 1
file_name = file_path.name

in_omr = cv2.imread(str(file_path), cv2.IMREAD_GRAYSCALE)
# Load original colored image
in_omr_color = cv2.imread(str(file_path))
# Create grayscale copy for processing
in_omr = cv2.cvtColor(in_omr_color, cv2.COLOR_BGR2GRAY)

logger.info("")
logger.info(
Expand Down