{"id":13708872,"url":"https://github.com/gramian/hapod","last_synced_at":"2025-05-06T15:31:21.535Z","repository":{"id":69872654,"uuid":"92739347","full_name":"gramian/hapod","owner":"gramian","description":"HAPOD - Hierarchical Approximate Proper Orthogonal Decomposition","archived":true,"fork":false,"pushed_at":"2021-08-23T09:29:54.000Z","size":27,"stargazers_count":14,"open_issues_count":0,"forks_count":4,"subscribers_count":4,"default_branch":"main","last_synced_at":"2024-05-18T21:47:16.121Z","etag":null,"topics":["data-driven","data-reduction","data-science","datascience","dimension-reduction","distributed-memory","high-performance-computing","hpc","limited-memory","mapreduce","mapreduce-algorithm","model-order-reduction","model-reduction","pca","pod","proper-orthogonal-decomposition","svd","unsupervised-learning"],"latest_commit_sha":null,"homepage":"https://git.io/hapod","language":"MATLAB","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-2-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/gramian.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":"CITATION","codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2017-05-29T12:48:14.000Z","updated_at":"2024-02-21T01:46:53.000Z","dependencies_parsed_at":"2023-03-11T07:28:24.117Z","dependency_job_id":null,"html_url":"https://github.com/gramian/hapod","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gramian%2Fhapod","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gramian%2Fhapod/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gramian%2Fhapod/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/gramian%2Fhapod/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/gramian","download_url":"https://codeload.github.com/gramian/hapod/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224513125,"owners_count":17323750,"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","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":["data-driven","data-reduction","data-science","datascience","dimension-reduction","distributed-memory","high-performance-computing","hpc","limited-memory","mapreduce","mapreduce-algorithm","model-order-reduction","model-reduction","pca","pod","proper-orthogonal-decomposition","svd","unsupervised-learning"],"created_at":"2024-08-02T23:00:33.654Z","updated_at":"2024-11-13T19:30:30.958Z","avatar_url":"https://github.com/gramian.png","language":"MATLAB","readme":"HAPOD - Hierarchical Approximate Proper Orthogonal Decomposition\n================================================================\n\n* HAPOD - Hierarchical Approximate POD\n* version: 3.2 (2021-05-05)\n* by: C. Himpe (0000-0003-2194-6754), S. Rave (0000-0003-0439-7212)\n* under: BSD 2-Clause License (opensource.org/licenses/BSD-2-Clause)\n* summary: Fast distributed or incremental POD computation.\n\n## About\n\nThe HAPOD is an algorithm to compute the POD (left singular vectors, and\nsingular values of a matrix) hierarchically for (column-wise partitioned)\nlarge-scale matrices, allowing to balance accuracy with performance. As a\nPOD-of-PODs method, the HAPOD can be parallelized and further accelerated by\nuser supplied SVD implementations.\n\n## Scope\n\n* Proper Orthogonal Decomposition (POD)\n* Singular Value Decomposition (SVD)\n* Principal Axis Transformation (PAT)\n* Principal Component Analysis (PCA)\n* Empirical Orthogonal Functions (EOF)\n* Empirical Eigenfunctions (EEF)\n* Karhunen-Loeve Transformation (KLT)\n\n## Applications\n\n* Dimension Reduction\n* Model Reduction\n* Low-Rank Approximation\n* Data Compression\n* Unsupervised Learning\n\n## Features\n\n* Error-driven\n* Rigorous bounds\n* Single pass (each data vector is needed only once)\n* Column-wise data partitions (inducing parallelizability)\n* Custom SVD backends\n\n## Functionality\n\n* Standard POD\n* Incremental HAPOD -\u003e for memory-limited environments, e.g. single-board-computers\n* Distributed HAPOD -\u003e for distributd memory environments, e.g. super-computers\n* Distributed-of-Incremental HAPOD\n\n## Algorithm\n\nC. Himpe, T. Leibner, S. Rave:\n\"[Hierarchical Approximate Proper Orthogonal Decomposition](http://hdl.handle.net/21.11116/0000-0002-5342-6)\";\nSIAM Journal on Scientific Computing, 40(5): A3267--A3292, 2018.\n\n## Compatibility\n\n* GNU Octave \u003e= 4.0\n* Mathworks MATLAB \u003e= 2013b\n\n## Basic Usage\n\n```\n[svec,sval,meta] = hapod(data,bound,topo,relax,meta,depth,mysvd)\n```\n\n## Arguments\n\n* `data`   {cell}  - snapshot data set, partitioned by column (blocks)\n* `bound` {scalar} - mean L_2 projection error bound\n* `topo`  {string} - tree topology (see **Topology**)\n* `relax` {scalar} - relaxation parameter in (0,1) (see **Relaxation**)\n* `depth` {scalar} - total number of levels in tree (only required for `incr_1`)\n* `meta`  {struct} - meta information structure (see **Meta-Information**)\n* `mysvd` {handle} - custom SVD backend (see **Custom SVD**) \n\n## Return Values\n\n* `svec` {matrix} POD modes (column vectors)\n* `sval` {vector} Singular values (column vector)\n* `meta` {struct} Meta-information structure\n\n## Topology\n\nThe HAPOD is computed based on a tree topology `topo`, with the data partitions\nat the tree's leafs. The following topologies are available:\n\n* `'none'`   Standard POD\n* `'incr'`   Incremental HAPOD (Complete)\n* `'incr_1'` Incremental HAPOD (Child nodes)\n* `'incr_r'` Incremental HAPOD (Root node)\n* `'dist'`   Distributed HAPOD (Complete)\n* `'dist_1'` Distributed HAPOD (Child nodes)\n* `'dist_r'` Distributed HAPOD (Root node)\n\nIf all data partitions can be passed as the data argument, the types: `none` \n(standard POD), `incr`(emental) HAPOD or `dist`(ributed) HAPOD are applicable.\nIn case only a single partition is passed at a time, the types: `incr_1` and\n`dist_1` should be used for the child nodes of the associated HAPOD tree, while\nthe types: `incr_r` and `dist_r` should be used for the root nodes. The returned\nmeta-information structure (or a cell-array thereof) has to be passed to the\nparent node in the associated HAPOD tree. \n\n## Relaxation\n\nThe relaxation parameter `w` (`0 \u003c w \u003c 1`) balances accuracy versus speed.\nLarger `w` near one means be more accurate, while `w` near zero means faster\ncomputation. The default value is `w = 0.5`.\n\n## Meta-Information\n\nThe `meta` structure contains the following meta-information of the completed\nsub-tree:\n\n* `nSnapshots` - Number of data columns passed to this HAPOD and its children.\n* `nModes`     - Number of intermediate modes.\n* `tNode`      - Computational time at this HAPOD's branch.\n\nThe argument `meta` only needs to be passed for topology types `incr_r`,\n`dist_r` and `incr_1`, unless it is first leaf. Especially, this means the user\nnever has to create such a structure, since if it is required it is given as a\nprevious HAPOD's return value.\n\n## Custom SVD\n\nVia the `mysvd` argument a custom SVD function can be provided via a function\nhandle with the following signature:\n\n```\n[U,d] = mysvd(X)\n```\n\nfor a data matrix `X`, and returning left singular vectors in matrix `U` and\nsingular values in column vector `d`. By default (or `mysvd` = `eco`) a standard\nrank-revealing SVD is used. Additionally, by `mysvd` = `mos` the method of\nsnapshots can be selected.\n\n## Getting Started\n\nRun the sample code:\n\n```\nRUNME()\n```\n\nwhich demonstrates the different implemented HAPOD variants and can be used\nas a template.\n\n### MapReduce\n\nThe distributed HAPOD is well suited for the [MapReduce](https://en.wikipedia.org/wiki/MapReduce)\nbig data processing model. A basic MapReduce wrapper using the MATLAB (\u003e=2020b)\n[mapreduce](https://www.mathworks.com/help/matlab/ref/mapreduce.html) function\nis provided by:\n\n```\nMAPRED()\n```\n\n## Cite As\n\nC. Himpe, T. Leibner and S. Rave:\n\"[Hierarchical Approximate Proper Orthogonal Decomposition](https://doi.org/10.1137/16M1085413)\";\nSIAM Journal on Scientific Computing, 40(5): A3267--A3292, 2018.\n\n## Used In\n\n* P. Benner, C. Himpe:\n\"[Cross-Gramian-Based Dominant Subspaces](https://doi.org/10.1007/s10444-019-09724-7)\";\nAdvances in Computational Mathematics, 45(5): 2533--2553, 2019.\n\n* B.J. Beach:\n\"[An Implementation-Based Exploration of HAPOD: Hierarchical Approximate Proper Orthogonal Decomposition](http://hdl.handle.net/10919/81938)\";\nVirgina Tech, Master Thesis, 2018.\n\n* C. Himpe, T. Leibner, S. Rave, J. Saak:\n\"[Fast Low-Rank Empirical Cross Gramians](https://doi.org/10.1002/pamm.201710388)\";\nProceedings in Applied Mathematics and Mechanics, 17: 841--842, 2017.\n\n## See Also\n\n* C. Himpe, T. Leibner, S. Rave:\n\"[HAPOD - Fast, Simple and Reliable Distributed POD Computation](https://doi.org/10.11128/arep.55.a55283)\";\nARGESIM Report 55 (MATHMOD 2018 Volume): 119--120, 2018.\n\n* C. Himpe, T. Leibner, S. Rave:\n\"[Comprehensive Memory-Bound Simulations on Single Board Computers](https://doi.org/10.5281/zenodo.814497)\";\nExtended Abstract, 2nd Conference on Power Aware Computing (PACO), 2017.\n\n* C. Himpe and S. Rave.\n\"[HAPOD - Hierarchical Approximate POD](https://himpe.science/poster/rave16_morml.pdf)\".\nData-Driven Model Order Reduction and Machine Learning (MORML), 2016.\n\n","funding_links":[],"categories":["Model Reduction"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgramian%2Fhapod","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgramian%2Fhapod","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgramian%2Fhapod/lists"}