from PIL import Image, ImageDraw, ImageFont
# Load template (replace with a real DL image)
template = Image.open("dl_template.png")
draw = ImageDraw.Draw(template)
# Load a font (Arial Bold works for most US DLs)
font = ImageFont.truetype("arialbd.ttf", 24)
# Write name (adjust position to match real DL)
draw.text((50, 100), "JOHN DOE", fill="black", font=font)
# Save the result
template.save("fake_dl.png")