官术网_书友最值得收藏!

Dealing with data using OpenCV and Python

Although raw data can come from a variety of sources and in a wide range of formats, it will help us to think of all data fundamentally as arrays of numbers. For example, images can be thought of as simply 2D arrays of numbers representing pixel brightness across an area. Sound clips can be thought of 1D arrays of intensity over time. For this reason, efficient storage and manipulation of numerical arrays is absolutely fundamental to machine learning.

If you have mostly been using OpenCV's C++ application programming interface (API) and plan on continuing to do so, you might find that dealing with data in C++ can be a bit of a pain. Not only will you have to deal with the syntactic overhead of the C++ language, but you will also have to wrestle with different data types and cross-platform compatibility issues.

This process is radically simplified if you use OpenCV's Python API because you automatically get access to a large number of open-source packages from the Scientific Python (SciPy) community. Case in point is the Numerical Python (NumPy) package, around which most scientific computing tools are built.

主站蜘蛛池模板: 宜宾县| 西畴县| 江陵县| 莎车县| 舞钢市| 许昌县| 于都县| 清徐县| 乳源| 涪陵区| 宜丰县| 左云县| 石屏县| 彭泽县| 库伦旗| 玛沁县| 滨州市| 故城县| 富宁县| 盐山县| 云南省| 清流县| 荔波县| 鞍山市| 平阳县| 集贤县| 中方县| 新化县| 台湾省| 嘉兴市| 乐昌市| 紫阳县| 天津市| 双牌县| 谢通门县| 开平市| 湘西| 台东县| 汽车| 湄潭县| 榆树市|