{"id":18027605,"url":"https://github.com/cheind/polyline-icp","last_synced_at":"2025-08-08T04:34:45.320Z","repository":{"id":260160843,"uuid":"878910108","full_name":"cheind/polyline-icp","owner":"cheind","description":" A vectorized n-dimensional ICP implementation for registering two point clouds or a point cloud with a polyline.","archived":false,"fork":false,"pushed_at":"2024-10-30T19:43:20.000Z","size":2065,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-04T20:18:56.060Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cheind.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-10-26T12:54:16.000Z","updated_at":"2024-11-01T14:02:00.000Z","dependencies_parsed_at":"2024-11-04T08:45:39.462Z","dependency_job_id":"8d400387-5f7e-4fcd-8c65-5709f7fdfe2f","html_url":"https://github.com/cheind/polyline-icp","commit_stats":null,"previous_names":["cheind/polyline-icp"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/cheind/polyline-icp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cheind%2Fpolyline-icp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cheind%2Fpolyline-icp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cheind%2Fpolyline-icp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cheind%2Fpolyline-icp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cheind","download_url":"https://codeload.github.com/cheind/polyline-icp/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cheind%2Fpolyline-icp/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":269365546,"owners_count":24405229,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-08T02:00:09.200Z","response_time":72,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-30T08:11:59.269Z","updated_at":"2025-08-08T04:34:45.292Z","avatar_url":"https://github.com/cheind.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![DOI](https://zenodo.org/badge/878910108.svg)](https://doi.org/10.5281/zenodo.14014753)\n\n# polyline-icp\nA vectorized n-dimensional Iterative Closest Point (ICP) for line-like data.\n\nWhen matching line-like data (e.g. trajectories or signals), point-to-point matching is feasible only if the underlying signals are densly sampled at the same timesteps. If this is assumption is not met, one can istead match the samples of one signal to the closest interpolated point on the second signal. This is illustrated below\n\n![](etc/icp.gif)\n\n## Features\n - A ridig/similarity motion ICP implementation with weighted pairing functions for point-to-point and point-to-(closed)-line. \n - A polyline class in n-dimensions that supports vectorized [linear referencing](https://en.wikipedia.org/wiki/Linear_referencing).\n - A weighted rigid/similarity motion estimation from correspondences in n-dimensions.\n\n## Usage\n\nInstall via\n```shell\npip install git+https://github.com/cheind/polyline-icp.git\n```\n\nThen run a minimal example\n\n```python\nimport numpy as np\n\nfrom polyicp.icp import icp\n\n# Setup a random problem\nx = np.random.randn(10, 2)\ny = x + np.random.randn(1,2)*1e-2\npidx = np.random.permutation(np.arange(10))\n\n# Perform ICP\nr = icp(x[pidx], y, with_scale=False, pairing_fn=\"polyline\")\nprint(r.x_hat) # final points\nprint(r.history) # transform history as (s,R,t) tuples\n                 # more fields available\n```\n\n## Polyline projections\n\nThis library comes with a polyline utility to compute the closest points on `L` polylines in `D` dimensions to a set of `M` query points in `D` dimensions. The class computes closest points and additional information that is useful in linear referencing. Due to its vectorized nature, it is actually quite performant for moderate sizes of `L` and `M`.\n\n![](etc/closest_on_polyline.gif)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcheind%2Fpolyline-icp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcheind%2Fpolyline-icp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcheind%2Fpolyline-icp/lists"}