-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathAnalysisResult.py
36 lines (30 loc) · 1.15 KB
/
AnalysisResult.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
from models.Disease import Disease
from models.Analysis import Analysis
class AnalysisResult:
"""An AnalysisResult object contains the result of an executed analysis.
Attributes:
id Identification number of this object
analysis Analysis object that gave this result
disease Disease object that was predicted by the Analysis classifier
score Score of result certainty
frame peace of image that went submited to prediction
"""
def __init__(self,
id=0,
analysis=Analysis(),
disease=Disease(),
score=0,
frame='0,0,0,0'):
"""AnalisysResult model constructor
args:
id: Integer ID number
analysis: Analysis object that gave this result
disease: Disease object that was predicted by the Analysis classifier
score: Score of result certainty
frame: peace of image that went submited to prediction
"""
self.id = id
self.analysis = analysis
self.disease = disease
self.score = score
self.frame = frame