Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions pointllm/eval/evaluator.py
Original file line number Diff line number Diff line change
Expand Up @@ -399,7 +399,7 @@ def parse_gpt_response_evaluate(self, gpt_response, ground_truth):
# * not valid range
cls_result = -1
except ValueError:
print(f"Error: unale to parse {gpt_response}.")
print(f"Error: unable to parse {gpt_response}.")
cls_result = -1

if cls_result == -1:
Expand Down Expand Up @@ -562,10 +562,10 @@ def print_results(self):
print('-' * 80)
if self.total_predictions - self.invalid_responses == 0:
accuracy = 0 # * no results and get error
clean_accuracy = 0
else:
accuracy = self.correct_predictions / self.total_predictions * 100
clean_accuracy = (self.correct_predictions - self.invalid_correct_predictions) / (self.total_predictions - self.invalid_responses) * 100
accuracy = self.correct_predictions / self.total_predictions * 100
print("Results:")
print(f"Accuracy: {accuracy:.2f}%")
print(f"Clean Accuracy: {clean_accuracy:.2f}%",)
Expand Down Expand Up @@ -638,7 +638,7 @@ def parse_gpt_response_evaluate(self, gpt_response, ground_truth):
# * not valid range
gpt_score = -1
except ValueError:
print(f"Error: unale to parse {gpt_response}.")
print(f"Error: unable to parse {gpt_response}.")
gpt_score = -1

if gpt_score == -1:
Expand Down