{"id":20841036,"url":"https://github.com/benchopt/benchmark_tv_2d","last_synced_at":"2025-05-08T22:06:39.102Z","repository":{"id":38301666,"uuid":"493163823","full_name":"benchopt/benchmark_tv_2d","owner":"benchopt","description":"TV-regularized problem in 2D","archived":false,"fork":false,"pushed_at":"2024-11-05T20:06:57.000Z","size":66,"stargazers_count":2,"open_issues_count":5,"forks_count":4,"subscribers_count":4,"default_branch":"main","last_synced_at":"2025-05-08T22:06:32.808Z","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":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/benchopt.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2022-05-17T08:32:56.000Z","updated_at":"2024-11-05T20:07:01.000Z","dependencies_parsed_at":"2024-07-17T10:48:08.137Z","dependency_job_id":"76d34792-9bda-4b25-93e5-de5be7bec89e","html_url":"https://github.com/benchopt/benchmark_tv_2d","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":"benchopt/template_benchmark","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benchopt%2Fbenchmark_tv_2d","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benchopt%2Fbenchmark_tv_2d/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benchopt%2Fbenchmark_tv_2d/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/benchopt%2Fbenchmark_tv_2d/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/benchopt","download_url":"https://codeload.github.com/benchopt/benchmark_tv_2d/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253154974,"owners_count":21862622,"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":[],"created_at":"2024-11-18T01:18:36.696Z","updated_at":"2025-05-08T22:06:39.070Z","avatar_url":"https://github.com/benchopt.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"2-dimensional Total Variation (TV) Benchmark\n============================================\n|Build Status| |Python 3.6+|\n\nThis benchmark is dedicated to solver of TV-2D regularised regression problem:\n\n$$\\\\boldsymbol{u} \\\\in \\\\underset{\\\\boldsymbol{u} \\\\in \\\\mathbb{R}^{n \\\\times m}}{\\\\mathrm{argmin}} f(\\\\boldsymbol{y}, A \\\\boldsymbol{u}) + g(\\\\boldsymbol{u})$$\n\n\n- $\\\\boldsymbol{y} \\\\in \\\\mathbb{R}^{n \\\\times m}$ is a vector of observations or targets.\n- $A \\\\in \\\\mathbb{R}^{n \\\\times n}$ is a design matrix or forward operator.\n- $\\\\lambda \u003e 0$ is a regularization hyperparameter.\n- the datafit is $f(\\\\boldsymbol{y},A\\\\boldsymbol{u})=\\\\sum\\_{k=1}^{n}\\\\sum\\_{l=1}^{m} l(y\\_{k,l}, (A\\\\boldsymbol{u}))_{k,l}$, where $l$ can either be the quadratic loss $l(y, x) = \\\\frac{1}{2} \\\\vert y - x \\\\vert_2^2$, or the Huber loss $l(y, x) = h\\_{\\\\delta} (y - x)$ defined by\n\n\n$$\nh\\_{\\\\delta}(t) = \\\\begin{cases} \\\\frac{1}{2} t^2 \u0026 \\\\mathrm{ if } \\\\vert t \\\\vert \\\\le \\\\delta \\\\\\\\ \\\\delta \\\\vert t \\\\vert - \\\\frac{1}{2} \\\\delta^2 \u0026 \\\\mathrm{ otherwise} \\\\end{cases}\n$$\n\n\n- $D_1 \\\\in \\\\mathbb{R}^{(n-1) \\\\times n}$ and $D_2 \\\\in \\\\mathbb{R}^{(m-1) \\\\times m}$ are finite difference operators, such that the regularised TV-2D term $g(\\\\boldsymbol{u}) = \\\\lambda \\\\| \\\\boldsymbol{u} \\\\|\\_{TV}$ expressed as follows.\n\n\nIn isotropic cases:\n\n\n$$\ng(\\\\boldsymbol{u}) = \\\\lambda \\\\| \\\\sqrt{ (D\\_1 \\\\boldsymbol{u})^2 + (\\\\boldsymbol{u} D\\_2^{\\\\top})^2 } \\\\|\\_{1} = \\\\lambda \\\\sum\\\\limits\\_{k = 1}^{n-1} \\\\sum\\\\limits\\_{l = 1}^{m-1} \\\\sqrt{\\\\vert u\\_{k+1,l} - u\\_{k,l} \\\\vert^2 + \\\\vert u\\_{k,l+1} - u\\_{k,l} \\\\vert^2}\n$$\n\n\nIn anisotropic cases:\n\n\n$$\ng(\\\\boldsymbol{u}) = \\\\lambda \\\\| D_1 \\\\boldsymbol{u} \\\\|_{1} + \\\\| \\\\boldsymbol{u} D_2^{\\\\top} \\\\|\\_{1} = \\\\lambda \\\\sum\\\\limits\\_{k = 1}^{n-1} \\\\sum\\\\limits\\_{l = 1}^{m-1} (\\\\vert u\\_{k+1,l} - u\\_{k,l} \\\\vert + \\\\vert u\\_{k,l+1} - u\\_{k,l} \\\\vert)\n$$\n\n\nwhere n (or `height`) and m (or `width`) are the dimensions of the image.\n\nThe type of loss is controlled by the ``data_fit`` attribute of the Objective.\n\nInstall\n--------\n\nA simple version of this benchmark can be run using the following commands:\n\n.. code-block::\n\n   $ pip install -U benchopt\n   $ git clone https://github.com/benchopt/benchmark_tv_2d\n   $ cd benchmark_tv_2d\n   $ benchopt install --config example_config.yml\n   $ benchopt run --config example_config.yml\n\nTo run the benchmark on a limited subset of Objectives, Solvers or Datasets, visit https://benchopt.github.io/api.html or use the command ```benchopt run -h``.\n\n.. |Build Status| image:: https://github.com/benchopt/benchmark_tv_2d/workflows/Tests/badge.svg\n   :target: https://github.com/benchopt/benchmark_tv_2d/actions\n.. |Python 3.6+| image:: https://img.shields.io/badge/python-3.6%2B-blue\n   :target: https://www.python.org/downloads/release/python-360/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbenchopt%2Fbenchmark_tv_2d","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbenchopt%2Fbenchmark_tv_2d","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbenchopt%2Fbenchmark_tv_2d/lists"}