Comments (8)
I've investigated YAD2K and didn't find calculations for mAP. But you can write down code for mAP in test_yolo.py. I tried this one but mAP is too low, I think I made mistake. Briefly, you have to take score threshold and check if score for that lable is bigger than your threshold you can check IOU and then define is it True Positive or False Positve. Also if there is no bounding box for ground truth label - it should be False Negative. Have to increment score threshold, so do this calculations in loop while Recall begins zero. Then for every class you have Precision and Recall values ( different values for corresponding score thresholds) use it to calculate average precision(https://sanchom.wordpress.com/tag/average-precision/). And after that summarize average precision and divide it by number of classes.
from yad2k.
It will be better to do it using tensorflow. But you can do this just using python, not pretty solution, but quick.
from yad2k.
https://github.com/allanzelener/YAD2K/issues/40
There you can find answer.
from yad2k.
thanx,
i am working on f1 score will share once i test it
from yad2k.
do you have any news about the map score you get? thx
from yad2k.
https://github.com/Pankajchandan/My-Machine-Learning-Rep/blob/master/f1_score.ipynb
this is an implementation for calculating F1 score for multiclass object detection. This can be extended for Map without much hassle.
from yad2k.
@Pankajchandan Did you tested on yad2k? If yes, which accuracy did you get?
from yad2k.
@Firyuza no i have not done that yet. This can be done by calling pred_info(y_true, y_pred) for every image/frame in yad2k. Here y_true is the ground truth in the default format used by yad2k i.e. "class_num x_min y_min x_max y_max" and y_pred is the prediction for that frame/image in the same format. Calling pred_info each time will return a dataframe having classes as indices and "count", "fp", "fn", "tp" and "dnd as columns, You need to keep adding this result somewhere in your code. When all the predictions in you test set are done, you just need to call cal_f1(pred_info) just once to get a data frame having all the classes as indices and "precision", "recall" and "f1 score" as the columns. Here the argument pred_info in cal_f1 is the result of the addition of all the results from the function pred_info.
from yad2k.
Related Issues (20)
- weird error
- when trying'./yad2k.py yolo.cfg yolo.weights model_data/yolo.h5', has problem HOT 2
- retrain_yolo image size/shape (416,416 vs 416,416,3)
- Difference between yad2k.py and yad2k/models/keras_yolo.py?
- Replace session.run() with keras Model
- ValueError: Cannot feed value of shape (1, 416, 416) for Tensor 'input_1:0', which has shape '(?, 416, 416, 3)' HOT 2
- The bounding box shifts
- The bounding box shifts right or left from the target.
- I try to generate yolo.h5 and use this command: python yad2k.py yolo.cfg yolo.weights model_data/yolo.h5 HOT 4
- when I run the code "yolo_model = load_model("model_data/yolov2.h5")" always raise an error HOT 1
- Using darknet19 as a simple classifier
- AttributeError: Module 'tensorflow' has no attribute 'space_to_depth" HOT 4
- issue with model last layer
- Generate yolo.h5 file HOT 1
- detects only 10 objects on max
- wget yolo cfg doesn't work HOT 1
- ReLu Activation Function HOT 1
- convert yolo9000.weights error
- Attempting to use uninitialized value FeatureExtractor/MobilenetV2/expanded_conv_3/depthwise/BatchNorm/beta [[{{node _retval_FeatureExtractor/MobilenetV2/expanded_conv_3/depthwise/BatchNorm/beta_0_179}}]] HOT 1
- issues with config_path weights_path output_path
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from yad2k.