2019-07-22 OPENCV python 训练和推理框架和应用使能

from imageai.Detection import ObjectDetection

import os

execution_path = os.getcwd()

detector = ObjectDetection()

detector.setModelTypeAsRetinaNet()

detector.setModelPath(os.path.join(execution_path,"resnet50_coco_best_v2.0.1.h5"))

detector.loadModel()

detections = detector.detectObjectsFromImage(input_image=os.path.join(execution_path , "11.jpg"), output_image_path=os.path.join(execution_path , "11new.jpg"))

for eachObject in detections:

    print(eachObject["name"] + " : " + eachObject["percentage_probability"] )


runfile('C:/OPENCv/untitled2.py', wdir='C:/OPENCv')

cup : 79.31604385375977

cup : 66.11060500144958

cup : 83.2493543624878

cup : 92.63944625854492

person : 99.34452772140503

person : 92.91112422943115

person : 86.39482855796814

person : 98.52168560028076

laptop : 83.08642506599426

person : 86.49797439575195


参考来源:

https://baijiahao.baidu.com/s?id=1627406244873238742&wfr=spider&for=pc

https://www.jianshu.com/p/94d5edfaddd5

https://blog.csdn.net/gravitylink/article/details/82739690

https://github.com/OlafenwaMoses/ImageAI

http://baijiahao.baidu.com/s?id=1604852765149468838&wfr=spider&for=pc

https://mbd.baidu.com/newspage/data/landingsuper?context=%7B%22nid%22%3A%22news_9611327155578036794%22%7D&n_type=1&p_from=4

http://baijiahao.baidu.com/s?id=1604247631540063337&wfr=spider&for=pc

https://baijiahao.baidu.com/s?id=1637822659435117454&wfr=spider&for=pc

https://blog.csdn.net/tcy23456/article/details/88551116

http://baijiahao.baidu.com/s?id=1639481539248220870&wfr=spider&for=pc

https://blog.csdn.net/devopscsdn/article/details/78889879

https://cloud.tencent.com/info/3928ee0e266bfb42fe779f21dca750d5.html

http://newgame.duowan.com/1811/406132030586.html

https://baijiahao.baidu.com/s?id=1637939971968161368&wfr=spider&for=pc

https://tech.qq.com/a/20181107/012040.htm

©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容

  • 目标检测必须要OpenCV?10行Python代码也能实现,亲测好用! 大数据文摘 发布时间:18-07-0212...
    锋_71dc阅读 623评论 0 0
  • 1.艾灸养生 艾灸养生不仅是直接艾灸就可以了,掌握了以下这几点你就是高手 https://baijiahao.ba...
    亦凡yifan阅读 1,667评论 0 0
  • 【新闻原链接】 中美就经贸问题达成共识 停止相互加征新的关税 https://baijiahao.baidu.co...
    产品思享汇阅读 221评论 0 0
  • 自由写作第二个月第12篇。 北京开往上海的高铁,经过我的家乡,停车两分。每次高铁从那里通过,看着熟悉的站名,或者厂...
    守望智慧阅读 164评论 3 3
  • 可我自小是不怎么喜欢他的,他是一个严肃的人,不苟言笑,总是板着一张脸。 如今我在外求学,回家的时间越来越少。 爸爸...
    糖点什么阅读 326评论 0 0