{ "info": { "author": "Spiros Denaxas", "author_email": "s.denaxas@gmail.com", "bugtrack_url": null, "classifiers": [ "Operating System :: OS Independent", "Programming Language :: Python :: 3" ], "description": "[![Build Status](https://travis-ci.org/spiros/discrete_frechet.svg?branch=master)](https://travis-ci.org/spiros/discrete_frechet)\n\n[![DOI](https://zenodo.org/badge/118257492.svg)](https://zenodo.org/badge/latestdoi/118257492)\n\nDiscrete Fr\u00e9chet distance\n=========================\n\nComputes the discrete Fr\u00e9chet distance between\ntwo curves. The Fr\u00e9chet distance between two curves in a\nmetric space is a measure of the similarity between the curves.\nThe discrete Fr\u00e9chet distance may be used for approximately computing\nthe Fr\u00e9chet distance between two arbitrary curves, \nas an alternative to using the exact Fr\u00e9chet distance between a polygonal\napproximation of the curves or an approximation of this value.\n\nThis is a Python 3.* implementation of the algorithm produced\nin *Eiter, T. and Mannila, H., 1994. [Computing discrete Fr\u00e9chet distance](http://www.kr.tuwien.ac.at/staff/eiter/et-archive/cdtr9464.pdf). Tech. \nReport CD-TR 94/64, Information Systems Department, Technical University \nof Vienna.*\n\n\n```\nFunction dF(P, Q): real;\n input: polygonal curves P = (u1, . . . , up) and Q = (v1, . . . , vq).\n return: \u03b4dF (P, Q)\n ca : array [1..p, 1..q] of real;\n function c(i, j): real;\n begin\n if ca(i, j) > \u22121 then return ca(i, j)\n elsif i = 1 and j = 1 then ca(i, j) := d(u1, v1)\n elsif i > 1 and j = 1 then ca(i, j) := max{ c(i \u2212 1, 1), d(ui, v1) }\n elsif i = 1 and j > 1 then ca(i, j) := max{ c(1, j \u2212 1), d(u1, vj ) }\n elsif i > 1 and j > 1 then ca(i, j) :=\n max{ min(c(i \u2212 1, j), c(i \u2212 1, j \u2212 1), c(i, j \u2212 1)), d(ui, vj ) }\n else ca(i, j) = \u221e\n return ca(i, j);\n end; /* function c */\n\n begin\n for i = 1 to p do for j = 1 to q do ca(i, j) := \u22121.0;\n return c(p, q);\n end.\n```\n\nParameters\n----------\n P : Input curve - two dimensional array of points\n Q : Input curve - two dimensional array of points\n\nReturns\n-------\n dist: float64\n The discrete Frechet distance between curves `P` and `Q`.\n\nExamples\n--------\n```\n>>> from frechetdist import frdist\n>>> P=[[1,1], [2,1], [2,2]]\n>>> Q=[[2,2], [0,1], [2,4]]\n>>> frdist(P,Q)\n>>> 2.0\n>>> P=[[1,1], [2,1], [2,2]]\n>>> Q=[[1,1], [2,1], [2,2]]\n>>> frdist(P,Q)\n>>> 0\n```\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/spiros/discrete_frechet", "keywords": "", "license": "Apache License 2.0", "maintainer": "", "maintainer_email": "", "name": "frechetdist", "package_url": "https://pypi.org/project/frechetdist/", "platform": "", "project_url": "https://pypi.org/project/frechetdist/", "project_urls": { "Homepage": "https://github.com/spiros/discrete_frechet" }, "release_url": "https://pypi.org/project/frechetdist/0.6/", "requires_dist": [ "numpy (>1.0)" ], "requires_python": "", "summary": "Calculate discrete Frechet distance", "version": "0.6" }, "last_serial": 5666027, "releases": { "0.6": [ { "comment_text": "", "digests": { "md5": "d208830d86dc33ac6d6cb26405c5801b", "sha256": "c451619f1de6739d57c13981c34725a603c1068953d099b8cb07fa08d64f1072" }, "downloads": -1, "filename": "frechetdist-0.6-py3-none-any.whl", "has_sig": false, "md5_digest": "d208830d86dc33ac6d6cb26405c5801b", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 7626, "upload_time": "2019-08-12T12:23:40", "url": "https://files.pythonhosted.org/packages/5a/f8/fdd0d7ca48066152f4a80cd645a4f65e909350ee9b2f6026c6d917d73b62/frechetdist-0.6-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "f21745f987010da4c3a24fac3ba6ef7f", "sha256": "ab1d2592932cfa37e36a29e6df903592a366b86a91e395aa5866ad1cb53ad162" }, "downloads": -1, "filename": "frechetdist-0.6.tar.gz", "has_sig": false, "md5_digest": "f21745f987010da4c3a24fac3ba6ef7f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2815, "upload_time": "2019-08-12T12:23:41", "url": "https://files.pythonhosted.org/packages/eb/bd/6b3ddd08ec7fc63d082215b924127f8fffc6f9743ccd0f2d3c05aad28544/frechetdist-0.6.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "d208830d86dc33ac6d6cb26405c5801b", "sha256": "c451619f1de6739d57c13981c34725a603c1068953d099b8cb07fa08d64f1072" }, "downloads": -1, "filename": "frechetdist-0.6-py3-none-any.whl", "has_sig": false, "md5_digest": "d208830d86dc33ac6d6cb26405c5801b", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 7626, "upload_time": "2019-08-12T12:23:40", "url": "https://files.pythonhosted.org/packages/5a/f8/fdd0d7ca48066152f4a80cd645a4f65e909350ee9b2f6026c6d917d73b62/frechetdist-0.6-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "f21745f987010da4c3a24fac3ba6ef7f", "sha256": "ab1d2592932cfa37e36a29e6df903592a366b86a91e395aa5866ad1cb53ad162" }, "downloads": -1, "filename": "frechetdist-0.6.tar.gz", "has_sig": false, "md5_digest": "f21745f987010da4c3a24fac3ba6ef7f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2815, "upload_time": "2019-08-12T12:23:41", "url": "https://files.pythonhosted.org/packages/eb/bd/6b3ddd08ec7fc63d082215b924127f8fffc6f9743ccd0f2d3c05aad28544/frechetdist-0.6.tar.gz" } ] }