{ "info": { "author": "Guilherme Polo", "author_email": "gp@instaprint.me", "bugtrack_url": null, "classifiers": [ "Intended Audience :: Developers", "Programming Language :: Python :: 2", "Programming Language :: Python :: Implementation :: CPython", "Topic :: Software Development :: Libraries" ], "description": "## Build\n\nClone both `ccv` and `py-ccv`:\n\n```\nmkdir ccv_build\ncd ccv_build\ngit clone https://github.com/liuliu/ccv\ngit clone https://github.com/gpip/py-ccv\n```\n\nPatch `ccv` so it can be compiled as a dynamic lib, and compile it:\n\n```\ncd ccv/lib\npatch -p2 < ../../py-ccv/dynlib.patch\n./configure\nmake libccv.so\n```\n\nBuild and install the Python wrapper (`ARCHFLAGS` was used on a OSX build, adjust for your platform):\n\n```\ncd ../../py-ccv\nARCHFLAGS='-arch x86_64' INCDIR=../ccv/lib LIBDIR=../ccv/lib python setup.py install\n```\n\n## Build only this wrapper\n\nIf you already have `libccv.so` then you might want to install directly via pip:\n\n```\nLDFLAGS=\"-L$(pwd)/ccv/lib\" CFLAGS=\"-I$(pwd)/ccv/lib\" pip install ccv\n```\n\nRemember to adjust the paths according to where `libccv.so` and `ccv.h` are installed in your system.\n\n\n## Face Detection Usage\n\n(`DYLD_LIBRARY_PATH` was used on OSX, adjust it for your platform)\n\n##### Face detection using SCD\n\n```\n$ DYLD_LIBRARY_PATH=../ccv/lib python -m ccv.face_detect -c ../ccv/samples/face.sqlite3 img/lena.png\nimg/lena.png Feature(x1=229, y1=216, x2=381, y2=368, confidence=5.014610767364502)\n```\n\n##### Face detection using BBF\n\n```\n$ DYLD_LIBRARY_PATH=../ccv/lib python -m ccv.face_detect --bbf -c ../ccv/samples/face img/lena.png\nimg/lena.png Feature(x1=230, y1=211, x2=384, y2=365, confidence=0.4947386682033539)\n```\n\n##### Help\n\n```\n$ DYLD_LIBRARY_PATH=../ccv/lib python -m ccv.face_detect.py --help\nUsage: face_detect.py [options] filename...\n\nOptions:\n -h, --help show this help message and exit\n --bbf Use BBF detector\n --scd Use SCD detector\n -c CASCADE, --cascade=CASCADE\n Path to cascade to read\n --quiet\n```\n\n##### Using face_detect as a library\n\n```\nfrom ccv import face_detect\n\nnames = ['img/lena.png']\nresult = face_detect.main('scd', '../ccv/samples/face.sqlite3', False, *names)\n\n# face_detect.main is a generator which yields tuples of\n# (, [])\nfor name, rects in result:\n print name, rects\n```\n\n\n##### Visualization\n\nThis wrapper does not include an utility to draw the resulting rectangles, so the following example uses ImageMagick:\n\n```\n$ convert img/lena.png -fill none -stroke blue -strokewidth 3 -draw \"rectangle 229,216 381,368\" result.png\n```\n\n![](http://i.imgur.com/yzcxwqk.png)\n\n\n## Using the library\n\n```\nimport sys\nfrom ccv import ccv_read, ccv_write, sobel, lib\n\n# Read file passed.\ninp = ccv_read(sys.argv[1])\n# Apply Sobel.\nres = sobel(inp, lib.CCV_8U)\n# Save the result as \"sobel.jpg\"\nccv_write(res, \"sobel.jpg\")\n```\n\nPointers returned by the higher level wrapper, `ccv`, are automatically freed.", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/gpip/py-ccv", "keywords": null, "license": "UNKNOWN", "maintainer": null, "maintainer_email": null, "name": "ccv", "package_url": "https://pypi.org/project/ccv/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/ccv/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/gpip/py-ccv" }, "release_url": "https://pypi.org/project/ccv/0.0.5/", "requires_dist": null, "requires_python": null, "summary": "FFI bindings to libccv", "version": "0.0.5" }, "last_serial": 2056225, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "12aec282f430ca7157c51c96b81517da", "sha256": "6341dde722fe1c078c9d2e3e6e04866ff83d6d4afac828c76c68d6fdd83e5b19" }, "downloads": -1, "filename": "ccv-0.0.1-cp27-cp27m-macosx_10_11_intel.whl", "has_sig": false, "md5_digest": "12aec282f430ca7157c51c96b81517da", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 14975, "upload_time": "2016-04-08T21:05:54", "url": "https://files.pythonhosted.org/packages/a6/de/899976717666f1fb50fc1866ff0d5baae73c78e46ebd4544d5e8555ecddb/ccv-0.0.1-cp27-cp27m-macosx_10_11_intel.whl" }, { "comment_text": "", "digests": { "md5": "206baf222eef757e7df7207f029328c1", "sha256": "de09e45c4da4d6f4ed9ca9bc35d7bfbcfbb1cbd52b3370ef4ab5a6cc4481d1ab" }, "downloads": -1, "filename": "ccv-0.0.1.tar.gz", "has_sig": false, "md5_digest": "206baf222eef757e7df7207f029328c1", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6306, "upload_time": "2016-04-08T21:04:20", "url": "https://files.pythonhosted.org/packages/af/ea/ce829560d2213ba15f4bc3c505719fd1ec9f759077ece7d7c09b5d90589e/ccv-0.0.1.tar.gz" } ], "0.0.2": [ { "comment_text": "", "digests": { "md5": "c0c63a02634984852842826faf118abe", "sha256": "7f6995a9a593846d5638e4b2be3ee93ac549c30a2a3e643644462470450dcdd3" }, "downloads": -1, "filename": "ccv-0.0.2-cp27-cp27m-macosx_10_11_intel.whl", "has_sig": false, "md5_digest": "c0c63a02634984852842826faf118abe", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 15319, "upload_time": "2016-04-09T16:34:53", "url": "https://files.pythonhosted.org/packages/c8/bf/48629ffba2c797da4b769783ff8ac8bfe8c030d842705217027dd3aa0a82/ccv-0.0.2-cp27-cp27m-macosx_10_11_intel.whl" }, { "comment_text": "", "digests": { "md5": "31fd3b89c42819d1021767be2ef009d6", "sha256": "ce4e12aa46a90b5b7f61d810ff380da21ec0bcae6f183d01aeac32059db82d0f" }, "downloads": -1, "filename": "ccv-0.0.2.tar.gz", "has_sig": false, "md5_digest": "31fd3b89c42819d1021767be2ef009d6", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 6545, "upload_time": "2016-04-09T16:36:03", "url": "https://files.pythonhosted.org/packages/5e/17/69407e304010ebb06d48a2d5f9713ea1a2cf9bae85a5195371dfa33af823/ccv-0.0.2.tar.gz" } ], "0.0.5": [ { "comment_text": "", "digests": { "md5": "da9c549a252a880ef8a5f8f9af5dda8e", "sha256": "3f6b0dd81d1d7ebc7ec5e4736e207c1bfae638560f3ab077731ec2a335ea17e1" }, "downloads": -1, "filename": "ccv-0.0.5-cp27-cp27m-macosx_10_11_intel.whl", "has_sig": false, "md5_digest": "da9c549a252a880ef8a5f8f9af5dda8e", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 16283, "upload_time": "2016-04-10T13:33:22", "url": "https://files.pythonhosted.org/packages/80/29/5279624fa16311e4ca1f73b870542080082212af2225ee17ca69ed912de5/ccv-0.0.5-cp27-cp27m-macosx_10_11_intel.whl" }, { "comment_text": "", "digests": { "md5": "06792ac7c58573991176a13169b9183f", "sha256": "090212882c4227053dc4054053e5c8b635b49b1a9fbaaa2b7be3c64baf563131" }, "downloads": -1, "filename": "ccv-0.0.5.tar.gz", "has_sig": false, "md5_digest": "06792ac7c58573991176a13169b9183f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7032, "upload_time": "2016-04-10T13:33:34", "url": "https://files.pythonhosted.org/packages/c1/9a/96e5a56a07053effcb86490742b9788f9d5ce1d34da1f174c360d3b63e50/ccv-0.0.5.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "da9c549a252a880ef8a5f8f9af5dda8e", "sha256": "3f6b0dd81d1d7ebc7ec5e4736e207c1bfae638560f3ab077731ec2a335ea17e1" }, "downloads": -1, "filename": "ccv-0.0.5-cp27-cp27m-macosx_10_11_intel.whl", "has_sig": false, "md5_digest": "da9c549a252a880ef8a5f8f9af5dda8e", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 16283, "upload_time": "2016-04-10T13:33:22", "url": "https://files.pythonhosted.org/packages/80/29/5279624fa16311e4ca1f73b870542080082212af2225ee17ca69ed912de5/ccv-0.0.5-cp27-cp27m-macosx_10_11_intel.whl" }, { "comment_text": "", "digests": { "md5": "06792ac7c58573991176a13169b9183f", "sha256": "090212882c4227053dc4054053e5c8b635b49b1a9fbaaa2b7be3c64baf563131" }, "downloads": -1, "filename": "ccv-0.0.5.tar.gz", "has_sig": false, "md5_digest": "06792ac7c58573991176a13169b9183f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7032, "upload_time": "2016-04-10T13:33:34", "url": "https://files.pythonhosted.org/packages/c1/9a/96e5a56a07053effcb86490742b9788f9d5ce1d34da1f174c360d3b63e50/ccv-0.0.5.tar.gz" } ] }