{"id":35126039,"url":"https://github.com/advancedphotonsource/xrf-maps","last_synced_at":"2026-05-01T16:01:21.502Z","repository":{"id":17215677,"uuid":"67737537","full_name":"AdvancedPhotonSource/XRF-Maps","owner":"AdvancedPhotonSource","description":"XRF-Maps is a C++ open source software package that implements these functions to provide a tool set for the analysis of XRF data sets","archived":false,"fork":false,"pushed_at":"2026-05-01T13:58:12.000Z","size":5879,"stargazers_count":13,"open_issues_count":0,"forks_count":14,"subscribers_count":6,"default_branch":"master","last_synced_at":"2026-05-01T15:32:11.879Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"C++","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/AdvancedPhotonSource.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":"2016-09-08T20:23:21.000Z","updated_at":"2026-05-01T13:55:20.000Z","dependencies_parsed_at":"2023-11-07T17:50:57.369Z","dependency_job_id":"973125d8-5f77-4525-8279-8a0fd0c0ce44","html_url":"https://github.com/AdvancedPhotonSource/XRF-Maps","commit_stats":null,"previous_names":[],"tags_count":55,"template":false,"template_full_name":null,"purl":"pkg:github/AdvancedPhotonSource/XRF-Maps","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AdvancedPhotonSource%2FXRF-Maps","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AdvancedPhotonSource%2FXRF-Maps/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AdvancedPhotonSource%2FXRF-Maps/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AdvancedPhotonSource%2FXRF-Maps/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AdvancedPhotonSource","download_url":"https://codeload.github.com/AdvancedPhotonSource/XRF-Maps/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AdvancedPhotonSource%2FXRF-Maps/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32503204,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"online","status_checked_at":"2026-05-01T02:00:05.856Z","response_time":64,"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":"2025-12-28T02:40:37.580Z","updated_at":"2026-05-01T16:01:21.492Z","avatar_url":"https://github.com/AdvancedPhotonSource.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![Actions Status](https://github.com/aglowacki/XRF-Maps/workflows/CMake/badge.svg)](https://github.com/aglowacki/XRF-Maps/actions)\n[![Build Status](https://dev.azure.com/aglow/XRF-Maps/_apis/build/status/aglowacki.XRF-Maps?branchName=master)](https://dev.azure.com/aglow/XRF-Maps/_build/latest?definitionId=2\u0026branchName=master)\n\n# XRF-Maps\n\nX-ray fluorescence (XRF) imaging typically involves the creation and analysis of 3D data sets, where at each scan position a full energy dispersive x-ray spectrum is recorded. This allows one to later process the data in a variety of different approaches, e.g., by spectral region of interest (ROI) summation with or without background subtraction, principal component analysis, or fitting. XRF-Maps is a C++ open source software package that implements these functions to provide a tool set for the analysis of XRF data sets. It is based on the MAPS software http://www.aps.anl.gov/Xray_Science_Division/Xray_Microscopy_and_Imaging/Software_and_Tools/maps.html\n\n# Compiling\n\n## Requires\n\nVisual Studio 2015 or greater (Windows build)\nGCC 6.0 or greater (Linux build)\nCmake 3.5 or greater\n\n## Libraries\n\nHDF5 : https://www.hdfgroup.org/downloads/\nNetCDF : http://www.unidata.ucar.edu/downloads/netcdf/index.jsp (Download http://www.unidata.ucar.edu/software/netcdf/docs/winbin.html)\nEigen : http://eigen.tuxfamily.org/index.php?title=Main_Page (submodule in src/support)\n\n## Optional Libraries\n\nQT : https://www.qt.io/download\nZeroMQ : http://zeromq.org/area:download\n\n## Compile Default\n\n1) git clone --recurse-submodules https://github.com/AdvancedPhotonSource/XRF-Maps.git\n2) cd XRF-Maps\n3) mkdir build\n4) cd vcpkg\n5) vcpkg set Linux\n   1) ./bootstrap-vcpkg.sh\n   2) ./vcpkg install hdf5 netcdf-c yaml-cpp cppzmq nlopt jsoncpp\n6) vcpkg setup windows\n   1) .\\bootstrap-vcpkg.bat\n   2) .\\vcpkg install hdf5 netcdf-c yaml-cpp cppzmq nlopt jsoncpp --triplet x64-windows\n7) cd ../build\n8) cmake `-DCMAKE_TOOLCHAIN_FILE=../vcpkg/scripts/buildsystems/vcpkg.cmake -DBUILD_WITH_ZMQ=ON ..`\n9) make\n\n## Building optional features\n\n### QT support\n\n-DBUILD_WITH_QT=ON\n\n### Streaming support with ZeroMQ\n\n-DBUILD_WITH_ZMQ=ON \n\n### Python bindings (NOTE: this may interfere with QT options if QT lib version is different than python qt lib version as with anaconda python)\n\n-DBUILD_WITH_PYBIND11=ON\n-DPYTHON_EXECUTABLE={path to python.exe if not found}\n\n# Data Analysis\n\n## General\nRun from bin directory. The software looks for references one directory up ( ../references ). \n```bash\nHelp:\nUsage: xrf_maps [Options] --dir [dataset directory]\n\nOptions:\n--nthreads : \u003cint\u003e number of threads to use (default is all system threads)\n--quantify-with : \u003cstandard.txt\u003e File to use as quantification standard\n--detectors : \u003cint,..\u003e Detectors to process, Defaults to 0,1,2,3 for 4 detector\n--generate-avg-h5 : Generate .h5 file which is the average of all detectors .h50 - h.53 or range specified.\n--add-v9layout : Generate .h5 file which has v9 layout able to open in IDL MAPS software.\n--add-exchange : Add exchange group into hdf5 file with normalized data.\n--export-csv : Export Integrated spec, fitted, background to csv file.\n--update-theta : \u003ctheta_pv_string\u003e Update the theta dataset value using theta_pv_string as new pv string ref.\n--update-amps \u003cus_amp\u003e,\u003cds_amp\u003e: Updates upstream and downstream amps if they changed inbetween scans.\n--update-quant-amps \u003cus_amp\u003e,\u003cds_amp\u003e: Updates upstream and downstream amps for quantification if they changed inbetween scans.\n--quick-and-dirty : Integrate the detector range into 1 spectra.\n--optimize-fit-override-params : \u003cint\u003e Integrate the 8 largest mda datasets and fit with multiple params.\n  1 = matrix batch fit\n  2 = batch fit without tails\n  3 = batch fit with tails\n  4 = batch fit with free E, everything else fixed\n--optimizer \u003clmfit, mpfit\u003e : Choose which optimizer to use for --optimize-fit-override-params or matrix fit routine\nFitting Routines:\n--fit \u003croutines,\u003e comma seperated\n  roi : element energy region of interest\n  roi_plus : SVD method\n  nnls : Non-Negative Least Squares\n  tails : Fit with multiple parameters\n  matrix : Fit with locked parameters\n\nDataset:\n--dir : Dataset directory\n--files : Dataset files: comma (',') separated if multiple\nNetwork:\n--streamin [source ip] : Accept a ZMQ stream of spectra to process. Source ip defaults to localhost (must compile with -DBUILD_WITH_ZMQ option)\n--streamout : Streams the analysis counts over a ZMQ stream (must compile with -DBUILD_WITH_ZMQ option)\n\nExamples:\n   Perform roi and matrix analysis on the directory /data/dataset1\nxrf_maps --fit roi,matrix --dir /data/dataset1\n   Perform roi and matrix analysis on the directory /data/dataset1 but only process scan1 and scan2\nxrf_maps --fit roi,matrix --dir /data/dataset1 --files scan1.mda,scan2.mda\n   Perform roi, matrix, and nnls  analysis on the directory /data/dataset1, use maps_standard.txt information for quantification\nxrf_maps --fit roi,matrix,nnls --quantify-with maps_standard.txt --dir /data/dataset1\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadvancedphotonsource%2Fxrf-maps","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fadvancedphotonsource%2Fxrf-maps","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fadvancedphotonsource%2Fxrf-maps/lists"}