{"id":34085711,"url":"https://github.com/henriasv/lammps-logfile","last_synced_at":"2026-01-06T16:22:47.895Z","repository":{"id":42991343,"uuid":"148289958","full_name":"henriasv/lammps-logfile","owner":"henriasv","description":" Tool to read a logfile produced by LAMMPS into a simple python data structure with a get()-function providing the log data.","archived":false,"fork":false,"pushed_at":"2025-03-19T09:04:27.000Z","size":9395,"stargazers_count":64,"open_issues_count":4,"forks_count":8,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-09-23T02:39:32.088Z","etag":null,"topics":["lammps"],"latest_commit_sha":null,"homepage":"https://henriasv.github.io/lammps-logfile","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/henriasv.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}},"created_at":"2018-09-11T09:04:24.000Z","updated_at":"2025-09-19T20:27:50.000Z","dependencies_parsed_at":"2024-12-11T11:28:47.456Z","dependency_job_id":"ecee80c5-764d-41aa-9e5c-2d18a48fb43f","html_url":"https://github.com/henriasv/lammps-logfile","commit_stats":{"total_commits":36,"total_committers":2,"mean_commits":18.0,"dds":0.02777777777777779,"last_synced_commit":"b7e87d7803028c08566150b8a179f3e3d46ec54a"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/henriasv/lammps-logfile","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/henriasv%2Flammps-logfile","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/henriasv%2Flammps-logfile/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/henriasv%2Flammps-logfile/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/henriasv%2Flammps-logfile/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/henriasv","download_url":"https://codeload.github.com/henriasv/lammps-logfile/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/henriasv%2Flammps-logfile/sbom","scorecard":{"id":461403,"data":{"date":"2025-08-11","repo":{"name":"github.com/henriasv/lammps-logfile","commit":"d31b1fb0ae9896507c00877dfca48b05bfdc534e"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.5,"checks":[{"name":"Code-Review","score":1,"reason":"Found 3/25 approved changesets -- score normalized to 1","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/main.yml:1","Warn: no topLevel permission defined: .github/workflows/pythonpackage.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/main.yml:11: update your workflow using https://app.stepsecurity.io/secureworkflow/henriasv/lammps-logfile/main.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/main.yml:14: update your workflow using https://app.stepsecurity.io/secureworkflow/henriasv/lammps-logfile/main.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/main.yml:27: update your workflow using https://app.stepsecurity.io/secureworkflow/henriasv/lammps-logfile/main.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/main.yml:43: update your workflow using https://app.stepsecurity.io/secureworkflow/henriasv/lammps-logfile/main.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pythonpackage.yml:15: update your workflow using https://app.stepsecurity.io/secureworkflow/henriasv/lammps-logfile/pythonpackage.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/pythonpackage.yml:17: update your workflow using https://app.stepsecurity.io/secureworkflow/henriasv/lammps-logfile/pythonpackage.yml/master?enable=pin","Warn: pipCommand not pinned by hash: .github/workflows/main.yml:21","Warn: pipCommand not pinned by hash: .github/workflows/main.yml:35","Warn: pipCommand not pinned by hash: .github/workflows/main.yml:36","Warn: pipCommand not pinned by hash: .github/workflows/pythonpackage.yml:22","Warn: pipCommand not pinned by hash: .github/workflows/pythonpackage.yml:26","Warn: pipCommand not pinned by hash: .github/workflows/pythonpackage.yml:29","Info:   0 out of   5 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 third-party GitHubAction dependencies pinned","Info:   0 out of   6 pipCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: GNU General Public License v3.0: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}},{"name":"SAST","score":0,"reason":"SAST tool is not run on all commits -- score normalized to 0","details":["Warn: 0 commits out of 8 are checked with a SAST tool"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}}]},"last_synced_at":"2025-08-19T11:13:11.152Z","repository_id":42991343,"created_at":"2025-08-19T11:13:11.152Z","updated_at":"2025-08-19T11:13:11.152Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":27728911,"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-12-14T02:00:11.348Z","response_time":56,"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":["lammps"],"created_at":"2025-12-14T13:11:25.561Z","updated_at":"2026-01-06T16:22:47.890Z","avatar_url":"https://github.com/henriasv.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"![](https://github.com/henriasv/lammps-logfile/workflows/Install%20and%20tests/badge.svg)\n# LAMMPS logfile reader\nTool to read a logfile produced by [LAMMPS](https://lammps.sandia.gov) into a python data structure.\n\n## Installation\nFrom pypi (preferred/stable)\n```\npip install lammps-logfile\n```\nDepending on your python installation, you may have to use `pip3` instead of `pip`. This is usualy the case if you need to run `python3` rather than `python` to run python version 3. \n\nInstall using pip directly from github to get the latest (possibly unstable) version:\n```\npip install git+https://github.com/henriasv/lammps-logfile.git\n```\nOr by cloning the repository:\n```\ngit clone https://github.com/henriasv/lammps-logfile.git\ncd lammps-logfile\npip3 install .\n```\n\n## Usage (Recommended)\nThe recommended way to read log files is using the `read_log` function, which returns a pandas DataFrame containing all thermodynamic data from all runs in the log file.\n\n```python\nfrom lammps_logfile import read_log\nimport matplotlib.pyplot as plt\n\n# Read the log file into a DataFrame\n# This example uses the 'crack_log.lammps' file found in 'examples/logfiles/'\ndf = read_log(\"crack_log.lammps\")\n\n# The DataFrame contains data from all runs, with a 'run_num' column distinguishing them\nprint(df.head())\n\n# Plot Temperature vs Step\nplt.figure(figsize=(10, 6))\nplt.plot(df['Step'], df['Temp'])\nplt.xlabel('Step')\nplt.ylabel('Temperature')\nplt.show()\n```\n\n![Example Plot](docs/readme_example.png)\n\n## Benchmarks\n\nThe following benchmarks demonstrate the performance of `read_log` on various log files (including those with mixed `thermo_style` outputs). The benchmarks were run on the provided examples.\n\n| Simulation                              |   Runs |   Steps |   Memory (MB) |   Time (s) |\n|:----------------------------------------|-------:|--------:|--------------:|-----------:|\n| 01_fcc_thermo_multi/out/log.lammps      |      3 |      29 |          0.10 |     0.02   |\n| 02_bcc_custom_thermo/out/log.lammps     |      4 |     108 |          0.15 |     0.03   |\n| 03_fcc_custom_longlog/out/log.lammps    |      4 |   30004 |         21.77 |     0.37   |\n| 04_bcc_multi_then_custom/out/log.lammps |      5 |      62 |          0.17 |     0.04   |\n\n## Legacy Interface\nThe `File` class interface is kept for backward compatibility but is considered legacy.\n\n```python\nimport lammps_logfile\n\nlog = lammps_logfile.File(\"path/to/logfile\")\n\nx = log.get(\"Time\")\ny = log.get(\"Temp\")\n\nimport matplotlib.pyplot as plt\nplt.plot(x, y)\nplt.show()\n```\nThis will give the concatenated log entries of all the runs where the style of the thermo output didn't change with respect to the last run. I.e. if the entries in the `thermo_style` was not changed between runs it will contain the log data for all the timesteps. If the `thermo_style` *was* changed, `x` and `y` will contain the data from all the timesteps after the `thermo_style` was changed for the last time. \n \n### Multiple runs in the same log file (Legacy)\nIf multiple run statements have been made in a simulation, these can be retrieved bu supplying the `run_num` keyword to the `get()`-function\n\n```python\nimport lammps_logfile\n\nlog = lammps_logfile.File(\"path/to/logfile\")\n\nx = log.get(\"Time\", run_num=N)\ny = log.get(\"Temp\", run_num=N)\n\nimport matplotlib.pyplot as plt\nplt.plot(x, y)\nplt.show()\n```\nIn this case, `x` and `y` will contain the log data from the `N`'th `run` command in LAMMPS, counting from 0.\n\nAny invalid call to the `get()`-function will result in the function returning `None`. This happes if the user asks for a thermo propery that does not exist in the log file, or if the user asks for a `run_num` larger than the number of runs in the logfile. \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhenriasv%2Flammps-logfile","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhenriasv%2Flammps-logfile","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhenriasv%2Flammps-logfile/lists"}