{"id":15687189,"url":"https://github.com/adonath/snakemake-workflow-fermi-lat","last_synced_at":"2025-11-17T13:58:10.064Z","repository":{"id":68491731,"uuid":"600248979","full_name":"adonath/snakemake-workflow-fermi-lat","owner":"adonath","description":"A Snakemake workflow for Fermi-LAT data reduction","archived":false,"fork":false,"pushed_at":"2025-08-12T14:26:53.000Z","size":93,"stargazers_count":12,"open_issues_count":5,"forks_count":1,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-09-05T00:24:45.936Z","etag":null,"topics":["data-reduction","fermi-lat","fermitools","gammapy","snakemake"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/adonath.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":"CITATION.cff","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":"2023-02-10T23:24:06.000Z","updated_at":"2025-08-12T14:26:57.000Z","dependencies_parsed_at":"2023-12-31T00:13:20.944Z","dependency_job_id":"5cd59a95-8baf-4f6d-b6fe-8a50b9fbf084","html_url":"https://github.com/adonath/snakemake-workflow-fermi-lat","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/adonath/snakemake-workflow-fermi-lat","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adonath%2Fsnakemake-workflow-fermi-lat","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adonath%2Fsnakemake-workflow-fermi-lat/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adonath%2Fsnakemake-workflow-fermi-lat/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adonath%2Fsnakemake-workflow-fermi-lat/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/adonath","download_url":"https://codeload.github.com/adonath/snakemake-workflow-fermi-lat/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/adonath%2Fsnakemake-workflow-fermi-lat/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":284893575,"owners_count":27080531,"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-11-17T02:00:06.431Z","response_time":55,"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":["data-reduction","fermi-lat","fermitools","gammapy","snakemake"],"created_at":"2024-10-03T17:44:54.818Z","updated_at":"2025-11-17T13:58:10.058Z","avatar_url":"https://github.com/adonath.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![DOI](https://zenodo.org/badge/600248979.svg)](https://doi.org/10.5281/zenodo.16813358)\n\n# Snakemake Workflow for Fermi-LAT Data Reduction\n\nThis is an example snakemake workflow for data reduction of Fermi-LAT data. \nThe workflow will run the standard `fermitools` for a given configuration\nand produce FITS files in a format that Gammapy can read.\nThereby it will handle the reduction of counts, exposure and point\nspread function (PSF) for multiple PSF classes.\n\n## Getting Started\n\n### Use as Snakemake Module (recommended)\n\nIf you would like use this as Snakmake module you should add e.g. the following to your `Snakefile`:\n\n```python3\nmodule fermi_lat_data_workflow:\n    snakefile:\n        # here, plain paths, URLs and the special markers for code hosting providers (see below) are possible.\n        github(\"adonath/snakemake-workflow-fermi-lat\", path=\"workflow/Snakefile\", branch=\"main\")\n    config: config[\"fermi-lat-data\"]\n\nuse rule * from fermi_lat_data_workflow as fermi_lat_data_*\n```\n\n### Use as Repository\nAlternatively you could also just clone this repository to your local machine:\n```bash\ngit clone https://github.com/adonath/snakemake-workflow-fermi-lat.git\n```\n\nIf you havn't done yet, please install [conda](https://www.anaconda.com/products/distribution)\nor [mamba](https://mamba.readthedocs.io/en/latest/installation.html).\n\nNow change to the directory of the repository:\n```bash\ncd snakemake-workflow-fermi-lat/\n```\n\nAnd create the conda environment using:\n```bash\nmamba env create -f environment.yaml\n```\n\nOnce the process is done you can activate the environment:\n\n```bash\nconda activate snakemake-workflow-fermi-lat\n```\n\n### Download Data\n\nGo to https://fermi.gsfc.nasa.gov/cgi-bin/ssc/LAT/LATDataQuery.cgi and download the data \nyou are interested in. The data should be downloaded to the `./data` folder.\n\n### Configure and Run the Workflow\nNow you should adapt the configuration in [config/config.yaml](config/config.yaml)\nto match your data. \n\nThen you are ready to run the workflow, like:\n```bash\nsnakemake --cores 8\n```\n\nYou can also create a report to see previews of the counts, exposure and PSF images:\n```bash\nsnakemake --report report.html\nopen report.html\n```\n\nFinally you can read and print the datasets as well as models using Gammapy:\n```python3\n\nfrom gammapy.datasets import Datasets\nfrom gammapy.modeling.models import Models\n\ndatasets = Datasets.read(\"results/\u003cmy-config\u003e/datasets/\u003cmy-config\u003e-datasets-all.yaml\")\nmodels = Models.read(\"results/\u003cmy-config\u003e/model/\u003cmy-config\u003e-model.yaml\")\n\nprint(datasets)\nprint(models)\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadonath%2Fsnakemake-workflow-fermi-lat","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fadonath%2Fsnakemake-workflow-fermi-lat","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadonath%2Fsnakemake-workflow-fermi-lat/lists"}