ݺߣ

ݺߣShare a Scribd company logo
Calorie Application
김현우 서유정
박세환 오현주
김선주 교수님
김경민 조교님
based on Faster-RCNN
Team HEPC
Quick Recap
Korean food image recognition
SOCIAL DIETthrough objective calorie intake assessment
밥
생선구이
무생채
소세지
Our goal
생선구이: 190 kcal
소시지: 110 kcal
무생채: 20 kcal
밥: 120 kcal
Total 440 kcal
Faster R-CNN!
AWS
Elastic
Beanstalk
Client
Ruby
+
Python
Websocket
Caffe
Architecture
Training Outline
300 training images per class
100 test images per class
40 classes
• Batch size: 128
• Iteration: 140,000
• Pre trained CNN model
○ VGG16 on Imagenet
• Hardware:
○ NVIDIA GTX 1080
• Software: Caffe
Sample result
30,000 iteration
8 classes
Test result
mAP : mean Average Precision
0
0.2
0.4
0.6
0.8
1
1.2
10000 20000 30000 40000 50000 60000 70000 80000 90000 100000 110000 120000 130000 140000
Iteration
mAP for each class
쌀밥 가츠동 자장면 냉면 라면 불고기 제육볶음 닭볶음탕 멸치볶음 배추김치
탕수육 만두 떡볶이 순대 콩나물무침 계란말이 돈까스 깍두기 후라이드치킨 갈비찜
갈비탕 김치전 김치찌개 깻잎무침 동그랑땡 된장찌개 미역국 비빔국수 비빔밥 삼계탕
스팸 육개장 잡채 콩나물국 새우튀김 샐러드 우동 채소튀김 장조림 보쌈
Test result
mAP : mean Average Precision
0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
10000 20000 30000 40000 50000 60000 70000 80000 90000 100000 110000 120000 130000 140000
OverallmAP
Iteration
Overall mAP
Issues
Test result
mAP : mean Average Precision
0
0.2
0.4
0.6
0.8
1
1.2
10000 20000 30000 40000 50000 60000 70000 80000 90000 100000 110000 120000 130000 140000
Iteration
mAP for each class
쌀밥 가츠동 자장면 냉면 라면 불고기 제육볶음 닭볶음탕 멸치볶음 배추김치
탕수육 만두 떡볶이 순대 콩나물무침 계란말이 돈까스 깍두기 후라이드치킨 갈비찜
갈비탕 김치전 김치찌개 깻잎무침 동그랑땡 된장찌개 미역국 비빔국수 비빔밥 삼계탕
스팸 육개장 잡채 콩나물국 새우튀김 샐러드 우동 채소튀김 장조림 보쌈
Too low mAP for Cooked Rice
11%
Why is it Cooked Rice?
Cropper
Model
What actually happened…
What actually happened…
What actually happened…
Hey…
wait a minute..
I think I know
that one too..!
What actually happened…
??????
??????
What actually happened…
Hey…
wait a minute..
I think I know
that one too..!
??????
??????
What actually happened…
콩나물국쌀밥 닭볶음탕 동그랑땡
Re-evaluation
Test Class_x just with Class_x test set
Not with the whole test set
Test result
0
0.1
0.2
0.3
0.4
0.5
0.6
0.7
0.8
0.9
1
쌀밥
가츠동
자장면
냉면
라면
불고기
제육볶음
닭볶음탕
멸치볶음
배추김치
탕수육
만두
떡볶이
순대
콩나물무침
계란말이
돈까스
깍두기
후라이드치킨
갈비찜
갈비탕
김치전
김치찌개
깻잎무침
동그랑땡
된장찌개
미역국
비빔국수
비빔밥
삼계탕
스팸
육개장
잡채
콩나물국
새우튀김
샐러드
우동
채소튀김
장조림
보쌈
Estimated mean Average Precision
Different test approach : tested menus separately
mAP : 0.81 !!
Problems in
practical use
Foods have hierarchy
friedEgg 0.913
bibimbap 0.876
Some foods are on top of others as ingredients
Foods can be confusing
yukgaejang 0.861
kimchiStew 0.783
Similar looking foods are hard to discriminate
Post-processing layer
For practical application use
Post-processing layer
1.Hierarchy problem
- Select the larger box
Post-processing layer
2. Confusion problem
If IoU > 0.7 :
Merge 2 boxes
Select class with larger p(x) in a greedy way
𝐼𝑜𝑈 =	
𝐴	 ∩ 	𝐵
𝐴	 ∪ 	𝐵
Intersection	over	Union
Result Examples
Results
Results
Results
Results
Results
LIVE DEMO.
Web Application
DEMO
DEMO
DEMO
DEMO
DEMO
DEMO
DEMO
DEMO
Discussion
1. Faster-RCNN’s nature:
• Learns multiple classes simultaneously
• Needs high quality data set that has every class labeled in the image
Discussion
2. Discovered Faster-RCNN’s downside:
• Even though it uses CNN,
it does not consider the detected object’s visual context
○ Architectural trade-off
• Vanilla CNN is better for catching context
• Even naïve bayes would help: the combination of foods
Thank you

More Related Content

Capstone Design(1) 최종 발표