{"id":45756109,"url":"https://github.com/darktable-org/darktable-ai","last_synced_at":"2026-04-12T18:01:46.665Z","repository":{"id":340026081,"uuid":"1163977212","full_name":"darktable-org/darktable-ai","owner":"darktable-org","description":"Repository storing the Darktable models for the AI support","archived":false,"fork":false,"pushed_at":"2026-02-22T20:30:07.000Z","size":42000,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-02-25T21:34:16.860Z","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":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/darktable-org.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-02-22T13:00:36.000Z","updated_at":"2026-02-23T10:29:20.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/darktable-org/darktable-ai","commit_stats":null,"previous_names":["darktable-org/darktable-ai"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/darktable-org/darktable-ai","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darktable-org%2Fdarktable-ai","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darktable-org%2Fdarktable-ai/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darktable-org%2Fdarktable-ai/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darktable-org%2Fdarktable-ai/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/darktable-org","download_url":"https://codeload.github.com/darktable-org/darktable-ai/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/darktable-org%2Fdarktable-ai/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29872667,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-26T18:42:30.764Z","status":"ssl_error","status_checked_at":"2026-02-26T18:41:47.936Z","response_time":89,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":"2026-02-25T20:34:06.851Z","updated_at":"2026-02-26T21:01:03.735Z","avatar_url":"https://github.com/darktable-org.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Darktable AI Models\r\n\r\nONNX models and conversion scripts for [darktable](https://www.darktable.org/) - an open-source photography workflow application and raw developer ([GitHub](https://github.com/darktable-org/darktable)).\r\n\r\n## Models\r\n\r\n| Model                                                                           | Task    | Description                                   |\r\n|---------------------------------------------------------------------------------|---------|-----------------------------------------------|\r\n| [`denoise-nafnet`](models/denoise-nafnet/README.md)                             | denoise | NAFNet denoiser trained on SIDD dataset       |\r\n| [`denoise-nind`](models/denoise-nind/README.md)                                 | denoise | UNet denoiser trained on NIND dataset         |\r\n| [`mask-object-segnext-b2hq`](models/mask-object-segnext-b2hq/README.md)         | mask    | SegNext ViT-B SAx2 HQ for masking             |\r\n\r\n## Repository structure\r\n\r\n```\r\nrun.sh                Run pipeline for a model (supports subcommands)\r\nrun_all.sh            Run full pipeline for all models\r\nimages/               Sample images for demos\r\noutput/               Build output: ONNX models + generated config.json (gitignored)\r\ntemp/                 Downloaded checkpoints before conversion (gitignored)\r\nmodels/\r\n  common.sh           Shared shell functions (setup, convert, validate, demo, clean)\r\n  validate.py         Validate ONNX output (load models, check config, print I/O shapes)\r\n  \u003cmodel\u003e/\r\n    model.conf        Model metadata, configuration, conversion, and demo functions\r\n    requirements.txt  Python dependencies\r\n    convert.py        Model-specific conversion script\r\n    demo.py           Demo inference script\r\n    README.md         Model documentation and ONNX tensor specs\r\n    .skip             If present, skip this model in run_all.sh and CI\r\n```\r\n\r\n## Usage\r\n\r\nRun the full pipeline (setup, convert, validate, demo, clean) for a single model:\r\n\r\n```bash\r\n./run.sh \u003cmodel_id\u003e\r\n```\r\n\r\nRun the pipeline for all models:\r\n\r\n```bash\r\n./run_all.sh\r\n```\r\n\r\nOr run each step individually:\r\n\r\n```bash\r\n./run.sh \u003cmodel_id\u003e setup     # Create venv, clone repo, download checkpoint\r\n./run.sh \u003cmodel_id\u003e convert   # Convert to ONNX + generate config.json\r\n./run.sh \u003cmodel_id\u003e validate  # Load ONNX, verify config, print I/O shapes\r\n./run.sh \u003cmodel_id\u003e package   # Create .dtmodel package (zip archive)\r\n./run.sh \u003cmodel_id\u003e demo      # Run demo on sample images\r\n./run.sh \u003cmodel_id\u003e clean     # Remove venv and cloned repo\r\n```\r\n\r\n## Demos\r\n\r\nEach model includes a `demo.py` script that runs inference on the sample images\r\nin `images/`. Models that require per-image input (e.g. point prompts for object\r\nsegmentation) define a `demo_args()` function in their `model.conf`.\r\n\r\nOutput images are saved to `models/\u003cmodel\u003e/output/`.\r\n\r\n## Model selection criteria\r\n\r\nDarktable is free software licensed under [GPL-3.0](https://www.gnu.org/licenses/gpl-3.0.html). All AI models included in this repository are selected with the following principles in mind.\r\n\r\n### Open source compliance\r\n\r\nEach model card documents the following and must meet the stated requirements:\r\n\r\n- **GPL-3.0-compatible license.** Model weights must be released under a license compatible with GPL-3.0 (e.g. Apache-2.0, MIT, BSD, GPL-3.0). Proprietary or non-commercial-only models are not accepted.\r\n- **[OSAID v1.0](https://opensource.org/ai/open-source-ai-definition) classification.** Open Source AI, Open Weights, or Open Model.\r\n- **[MOF](https://isitopen.ai/) classification.** Class I (Open Science), Class II (Open Tooling), or Class III (Open Model).\r\n- **Training data license.** Specific license(s) for each training dataset.\r\n- **Training data provenance.** Where data came from and how it was collected. Models trained on undisclosed or scraped personal data without consent are not accepted.\r\n- **Training code availability.** Link to public training code under an open-source license.\r\n- **Known limitations.** What cannot be audited or verified (e.g. non-releasable pre-training data, non-OSI training data licenses).\r\n\r\n### Published research\r\n\r\n- **Peer-reviewed or public report.** Models should have an accompanying peer-reviewed paper or public technical report describing the architecture and training methodology.\r\n\r\n### Responsible use\r\n\r\n- **Privacy by design.** All inference runs locally on the user's machine. No data is sent to external services. No telemetry, no cloud dependencies.\r\n- **Purpose-limited scope.** Models are selected for photo editing tasks: denoising, masking, depth estimation, and object removal (inpainting), etc. We do not include models designed for generating, manipulating, or synthesizing human likenesses.\r\n- **Reproducibility.** Conversion scripts, model configurations, and source references are fully documented so that any user can verify and rebuild the ONNX models from the original checkpoints.\r\n\r\n## Adding a new model\r\n\r\n1. Create `models/\u003cmodel\u003e/model.conf` with model metadata (`MODEL_ID`, `MODEL_NAME`, `MODEL_DESCRIPTION`, `MODEL_TASK`), repo/checkpoint URLs, `run_convert()`, and optional `demo_args()`\r\n2. Create `models/\u003cmodel\u003e/requirements.txt` with Python dependencies (must include `onnxruntime`)\r\n3. Create `models/\u003cmodel\u003e/convert.py` with model-specific conversion logic\r\n4. Create `models/\u003cmodel\u003e/demo.py` with inference script\r\n5. Run `./run.sh \u003cmodel\u003e convert` to build ONNX output and generate `config.json`\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdarktable-org%2Fdarktable-ai","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdarktable-org%2Fdarktable-ai","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdarktable-org%2Fdarktable-ai/lists"}