Spaces:
Runtime error
Runtime error
ajitrajasekharan
commited on
Commit
•
f7fc919
1
Parent(s):
0d4b491
Update aggregate_server_json.py
Browse files- aggregate_server_json.py +2 -1
aggregate_server_json.py
CHANGED
@@ -208,9 +208,10 @@ class AggregateNER:
|
|
208 |
variance = sum_deviation/len(dist)
|
209 |
std_dev = math.sqrt(variance)
|
210 |
threshold = mean_score - std_dev*self.threshold #default is 1 standard deviation from mean
|
211 |
-
#threshold = mean_score
|
212 |
pick_count = 1
|
213 |
for node in dist:
|
|
|
214 |
if (node["confidence"] >= threshold):
|
215 |
ret_arr.append({"e":node["e"],"conf":node["confidence"]})
|
216 |
pick_count += 1
|
|
|
208 |
variance = sum_deviation/len(dist)
|
209 |
std_dev = math.sqrt(variance)
|
210 |
threshold = mean_score - std_dev*self.threshold #default is 1 standard deviation from mean
|
211 |
+
#threshold = mean_score
|
212 |
pick_count = 1
|
213 |
for node in dist:
|
214 |
+
print("conf:",node["confidence"],"threshold:",threshold)
|
215 |
if (node["confidence"] >= threshold):
|
216 |
ret_arr.append({"e":node["e"],"conf":node["confidence"]})
|
217 |
pick_count += 1
|