1 Star 2 Fork 1

Jason / philferriere-cocoapi

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
BSD-2-Clause

此Repo来源于 https://github.com/philferriere/cocoapi

This repo is a copy of https://github.com/philferriere/cocoapi

Clone of COCO API - http://cocodataset.org/

Original README:

COCO is a large image dataset designed for object detection, segmentation, person keypoints detection, stuff segmentation, and caption generation. This package provides Matlab, Python, and Lua APIs that assists in loading, parsing, and visualizing the annotations in COCO. Please visit http://cocodataset.org/ for more information on COCO, including for the data, paper, and tutorials. The exact format of the annotations is also described on the COCO website. The Matlab and Python APIs are complete, the Lua API provides only basic functionality.

In addition to this API, please download both the COCO images and annotations in order to run the demos and use the API. Both are available on the project website.

Please download, unzip, and place the images in: coco/images/

Please download and place the annotations in: coco/annotations/

For substantially more details on the API please see http://cocodataset.org/#download.

This clone's README:

To support Windows build and python3 we had to make minor changes to:

  • PythonAPI/setup.py
  • PythonAPI/pycocotools/coco.py

To install this package, use pip as follows:

(dlwin36coco) Phil@SERVERP E:\repos
$ pip install git+https://github.com/philferriere/cocoapi.git#subdirectory=PythonAPI
Collecting git+https://github.com/philferriere/cocoapi.git#subdirectory=PythonAPI
  Cloning https://github.com/philferriere/cocoapi.git to c:\users\phil\appdata\local\temp\pip-req-build-jn698z8p
Building wheels for collected packages: pycocotools
  Running setup.py bdist_wheel for pycocotools ... done
  Stored in directory: C:\Users\Phil\AppData\Local\Temp\pip-ephem-wheel-cache-rde3oevt\wheels\69\2b\12\2fa959e49f73d26cff202c2f4e5079096c9c57c8a8509fd75c
Successfully built pycocotools
Installing collected packages: pycocotools
Successfully installed pycocotools-2.0

On Windows, you must have the Visual C++ 2015 build tools on your path. If you don't, make sure to install them from here:

Then, run visualcppbuildtools_full.exe and select default options:

Why have the demo notebooks been moved into their own directory?

If you clone/fork the original repo, you may hit the following error when running the demo notebooks:

It happens because there is a pycocotools directory in the same folder as the notebooks. The python code being imported then is the local implementation of pycocotools, not the one installed with pip. To fix this issue, the demo notebooks have been moved to their own directory.

why am I getting a ModuleNotFoundError: No module named 'pycocotools._mask' error in my code?

If you get this error, it is because the COCO library you are calling is NOT our version of the library. Instead, you are (inadvertently) referencing a local copy of the library. So, if you get this error, search the tree of import in your code for a reference to a local pycocotools library. Then, move or delete the local version.

Copyright (c) 2014, Piotr Dollar and Tsung-Yi Lin All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. The views and conclusions contained in the software and documentation are those of the authors and should not be interpreted as representing official policies, either expressed or implied, of the FreeBSD Project.

简介

此repo来源于https://github.com/philferriere/cocoapi 由于国内访问github速度较慢,因此在gitee上拷贝一份 展开 收起
Python
BSD-2-Clause
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
Python
1
https://gitee.com/jiangjiajun/philferriere-cocoapi.git
git@gitee.com:jiangjiajun/philferriere-cocoapi.git
jiangjiajun
philferriere-cocoapi
philferriere-cocoapi
master

搜索帮助