import random import os from PIL import Image import base64 from io import BytesIO from collections import deque import os def generate_layers(images, index=0): if len(images) == 0: return '' return f''' ''' def generate_captcha_html(images): html = '' html_prelude = '''