Working state

This commit is contained in:
2026-03-10 14:21:35 +01:00
parent cb7c358a93
commit 95f20eb8b7
5 changed files with 13 additions and 7 deletions
+5 -1
View File
@@ -8,7 +8,7 @@ from PIL import Image, ImageDraw, ImageFont
# Configuration constants
ODS_PATH = "/home/sebastien/Rust/gestion_classe/Staging/simple_eval.ods"
OUTPUT_DIR = Path("/home/sebastien/Rust/Server/assets/static/copies")
OUTPUT_DIR = Path("/home/sebastien/Rust/Server/copies")
FONT_PATH = "/usr/share/fonts/truetype/dejavu/DejaVuSans-Bold.ttf" # Standard Linux font path
def get_rounded_score(score):
@@ -100,5 +100,9 @@ if __name__ == "__main__":
parser = argparse.ArgumentParser(description="Stamp scores on exam copies.")
parser.add_argument("dir", type=Path, help="Root directory containing 'A Rendre' folder")
args = parser.parse_args()
OUTPUT_DIR = OUTPUT_DIR / args.dir
OUTPUT_DIR.mkdir(parents=True, exist_ok=True)
process_images(args.dir)