added the start state and other templates

This commit is contained in:
Talhadeveloperr
2026-09-09 17:38:49 +05:00
parent 1c5b8f38c8
commit 3840d2104c
52 changed files with 15 additions and 3 deletions

View File

@@ -8,6 +8,7 @@ Run:
"""
import os
import shutil
import sys
APP_DIR = os.path.dirname(os.path.abspath(__file__))
@@ -34,10 +35,21 @@ from student_wise_template import generate_student_wise_templates # noqa: E402
from teacher_wise_template import generate_teacher_wise_templates # noqa: E402
RESULT_DIR = os.path.join(ROOT_DIR, "result", "templates")
VIEW_NAMES = ["batch-wise", "department-wise", "room-wise", "student-wise", "teacher-wise"]
def clear_result_dir():
"""Removes every previous run's output so stale files never linger."""
for view_name in VIEW_NAMES:
output_dir = os.path.join(RESULT_DIR, view_name)
if os.path.exists(output_dir):
shutil.rmtree(output_dir)
os.makedirs(output_dir, exist_ok=True)
def main():
reset_log()
clear_result_dir()
data_csv_marker = os.path.join(ROOT_DIR, "data", "dummy", "blocks", "rooms.csv")
if not os.path.exists(data_csv_marker):

View File

@@ -1,4 +1,4 @@
Timetable generation log - started 2026-09-09T17:06:29.991568
Timetable generation log - started 2026-09-09T17:07:54.250382
================================================================================
[17:06:29] INFO: Running conflict checks (student/batch and teacher)...
[17:06:29] INFO: No conflicts found — schedule is clash-free for students and teachers.
[17:07:54] INFO: Running conflict checks (student/batch and teacher)...
[17:07:54] INFO: No conflicts found — schedule is clash-free for students and teachers.