import os

def rename_files(folder_path):
    # Get a list of all the files in the folder
    files = os.listdir(folder_path)
    # Iterate over the files and rename them
    for i, filename in enumerate(files):
        # Construct the new filename
        new_filename = filename.replace(" ", "_")
        # Rename the file
        os.rename(os.path.join(folder_path, filename), os.path.join(folder_path, new_filename))

rename_files(
    folder_path="/mnt/ssd1T/hoanglv/Projects/KIE/DATA/dev_model/Receipt/intermediate/sbt/images",
)