Skip to content

Commit

Permalink
using timeit decorator
Browse files Browse the repository at this point in the history
  • Loading branch information
Maria Rosario Mestre authored and Maria Rosario Mestre committed Jun 11, 2024
1 parent 9f1eb03 commit f011c89
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions evaluations/evaluation_aragog.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
import os
import random
from pathlib import Path
import datetime
from typing import Tuple, List
from openai import BadRequestError

Expand Down Expand Up @@ -158,9 +157,8 @@ def create_args():
parser.add_argument('--sample', type=int, help='The number of questions to sample')
return parser.parse_args()


@timeit
def main():
t1 = datetime.datetime.now()
args = create_args()
questions, answers = read_question_answers()

Expand All @@ -171,9 +169,6 @@ def main():
answers = [answers[id] for id in sampled_ids]

parameter_tuning(questions, answers, args.output_dir)
t2 = datetime.datetime.now()

print(f"Experiment took {t2 - t1}")


if __name__ == '__main__':
Expand Down

0 comments on commit f011c89

Please sign in to comment.