mirror of
https://github.com/house-of-vanity/fesmoo_perdoliq.git
synced 2025-08-21 16:17:15 +00:00
Accuracy now works
This commit is contained in:
@@ -30,11 +30,7 @@ List it with `list` command
|
|||||||
example:
|
example:
|
||||||
resolve 4 1''')
|
resolve 4 1''')
|
||||||
return 1
|
return 1
|
||||||
# print("Resolving %s, %s" % (
|
app.resolve(int(q[1]), int(q[2]), accuracy)
|
||||||
# app.subjects[q[1]],
|
|
||||||
# app.subjects[q[1]][q[2]])
|
|
||||||
# )
|
|
||||||
app.resolve(int(q[1]), int(q[2]))
|
|
||||||
|
|
||||||
def list_all():
|
def list_all():
|
||||||
i = 0
|
i = 0
|
||||||
|
5
main.py
5
main.py
@@ -203,8 +203,11 @@ class Main:
|
|||||||
logging.info("Send correct answer for %s. It's %s" % (q_number,
|
logging.info("Send correct answer for %s. It's %s" % (q_number,
|
||||||
answers))
|
answers))
|
||||||
|
|
||||||
def resolve(self, subj, test):
|
def resolve(self, subj, test, accuracy):
|
||||||
q_count = self.start_test(subj, test)
|
q_count = self.start_test(subj, test)
|
||||||
|
# applying accuracy here
|
||||||
|
# spoil_count = q_count - q_count * (accuracy / 100)
|
||||||
|
q_count = int(q_count * (int(accuracy) / 100))
|
||||||
for i in range(1, q_count + 1):
|
for i in range(1, q_count + 1):
|
||||||
prediction = self.predict(i)
|
prediction = self.predict(i)
|
||||||
self.answer(i, prediction)
|
self.answer(i, prediction)
|
Reference in New Issue
Block a user