Larger boxes ; avoid feedback on confusing letters
parent
b0d814af4b
commit
f247a975d8
|
|
@ -8,8 +8,8 @@ import img2pdf
|
||||||
from reportlab.pdfgen import canvas
|
from reportlab.pdfgen import canvas
|
||||||
|
|
||||||
# Fix for Matplotlib in threads: Set backend to non-interactive 'Agg'
|
# Fix for Matplotlib in threads: Set backend to non-interactive 'Agg'
|
||||||
import matplotlib
|
# import matplotlib
|
||||||
matplotlib.use('Agg')
|
# matplotlib.use('Agg')
|
||||||
|
|
||||||
from PIL import Image, ImageDraw, ImageFont
|
from PIL import Image, ImageDraw, ImageFont
|
||||||
import annotating
|
import annotating
|
||||||
|
|
@ -19,7 +19,7 @@ from annotating import MARGIN_LEFT, ANNOT_WIDTH
|
||||||
LATEX_LOCK = threading.Lock()
|
LATEX_LOCK = threading.Lock()
|
||||||
DPI = 100
|
DPI = 100
|
||||||
BOX_SIZE = 30
|
BOX_SIZE = 30
|
||||||
SCORE_BOX_SIZE = 30
|
SCORE_BOX_SIZE = 40
|
||||||
SCORES = [x * 0.5 for x in range(9)] # 0.0 to 4.0
|
SCORES = [x * 0.5 for x in range(9)] # 0.0 to 4.0
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
|
@ -60,12 +60,13 @@ class CheckboxRenderer:
|
||||||
# Draw score boxes
|
# Draw score boxes
|
||||||
start_x = pos['w'] + 20
|
start_x = pos['w'] + 20
|
||||||
for val in SCORES:
|
for val in SCORES:
|
||||||
box = draw_checkbox(draw, start_x, pos['y'] + 25, BOX_SIZE, str(val))
|
box = draw_checkbox(draw, start_x, pos['y'] + 25,
|
||||||
|
SCORE_BOX_SIZE, str(val))
|
||||||
self.checkboxes.append({
|
self.checkboxes.append({
|
||||||
"type": "score", "label": self.label, "value": val,
|
"type": "score", "label": self.label, "value": val,
|
||||||
"rel_box": box # Will be adjusted for global Y later
|
"rel_box": box # Will be adjusted for global Y later
|
||||||
})
|
})
|
||||||
start_x += BOX_SIZE + 60
|
start_x += SCORE_BOX_SIZE + 60
|
||||||
elif meta.get("type") == "global_fb":
|
elif meta.get("type") == "global_fb":
|
||||||
# Draw delete box for global feedback
|
# Draw delete box for global feedback
|
||||||
bx = pos['w'] - BOX_SIZE - 5
|
bx = pos['w'] - BOX_SIZE - 5
|
||||||
|
|
|
||||||
|
|
@ -71,6 +71,10 @@ isn't, provide the coordinates where the word «continuous» is. If a
|
||||||
calculation went wrong, gives the coordinates of the step where it
|
calculation went wrong, gives the coordinates of the step where it
|
||||||
goes wrong, and as feedback, what went wrong.
|
goes wrong, and as feedback, what went wrong.
|
||||||
|
|
||||||
|
Avoid giving feedback about confusing letters `n` with `m`, `x` with
|
||||||
|
`n` or `h` with `k`. If it looks wrong, assume you read it wrong,
|
||||||
|
unless the distinction is very important.
|
||||||
|
|
||||||
You should also give me a measure of confidence, from 0 to 1 that you
|
You should also give me a measure of confidence, from 0 to 1 that you
|
||||||
were able to correctly understand the answer. A score below 0.5 means
|
were able to correctly understand the answer. A score below 0.5 means
|
||||||
that you think it is likely that you couldn't understand an important
|
that you think it is likely that you couldn't understand an important
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue