Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
72 commits
Select commit Hold shift + click to select a range
fec2e82
init
JoschD Sep 8, 2025
d513b6b
restructure
JoschD Sep 17, 2025
5f385c6
removed pychache
JoschD Sep 17, 2025
8b9570f
correctors as index
JoschD Sep 18, 2025
aa331c1
rename
JoschD Sep 18, 2025
45fa486
doc and a bit order
JoschD Sep 23, 2025
74b754f
updates
JoschD Oct 9, 2025
f22811e
Nice Plots
JoschD Oct 10, 2025
5163adc
clean up
JoschD Oct 10, 2025
106ed9e
extended example + doc
JoschD Oct 13, 2025
57a7863
doc
JoschD Oct 13, 2025
aafe18f
doc
JoschD Oct 13, 2025
3128043
started with 2018
JoschD Oct 13, 2025
bb2b872
added phd ref
JoschD Oct 13, 2025
eb55fa0
detuning cleanup and paper
JoschD Oct 14, 2025
b368915
restructure
JoschD Oct 14, 2025
801842b
example 2018
JoschD Oct 14, 2025
e5069bd
corrector labels
JoschD Oct 14, 2025
671325b
removed function
JoschD Oct 14, 2025
74256ae
working on examples
JoschD Nov 10, 2025
7cbe3fe
all examples
JoschD Nov 11, 2025
bb5ff9c
ruff
JoschD Nov 11, 2025
48b5373
leftover imports
JoschD Nov 11, 2025
cca1958
removed original script
JoschD Nov 11, 2025
71eed46
less importance on IPs, readme
JoschD Nov 11, 2025
6271728
doc
JoschD Nov 12, 2025
a90d854
example tests
JoschD Nov 12, 2025
2b049cb
link updates and workflows
JoschD Nov 12, 2025
8028702
Merge branch 'save_rewrite' into first_version
JoschD Nov 12, 2025
d896f6b
updated dependency
JoschD Nov 12, 2025
44c66fc
change model handling
JoschD Nov 12, 2025
26daaa9
better cloning
JoschD Nov 12, 2025
e343dbe
temporarily deactivated base tests
JoschD Nov 12, 2025
8ac5445
actually deactivate all tests for now
JoschD Nov 12, 2025
ba6ae3d
len test
JoschD Nov 12, 2025
a30f323
missing f in fstring
JoschD Nov 12, 2025
7d89efb
fixing tests
JoschD Nov 13, 2025
78c4f8e
test
JoschD Nov 13, 2025
64104e5
some tests
JoschD Nov 14, 2025
3ac9499
fixing tests
JoschD Nov 17, 2025
f8c7b6e
more tests
JoschD Nov 17, 2025
90edf7f
merge crossterm
JoschD Nov 17, 2025
43fea5c
test_lhc_detuning
JoschD Nov 18, 2025
db0acf9
test lhc sim
JoschD Nov 20, 2025
4d2a423
readme warnings correct
JoschD Nov 20, 2025
b926a4c
test results loader
JoschD Nov 20, 2025
b6feb00
ruff
JoschD Nov 20, 2025
bef85a9
mock called twice in test
JoschD Nov 24, 2025
c00e6fb
tests
JoschD Nov 25, 2025
e5869fc
tests
JoschD Nov 25, 2025
7c09d96
rename test file
JoschD Nov 26, 2025
2f7be5b
common tests
JoschD Nov 26, 2025
5131cb5
test common and correctors
JoschD Nov 26, 2025
f566016
logging tests
JoschD Nov 26, 2025
2fbe976
ruff
JoschD Nov 26, 2025
14ae5a0
tests latex
JoschD Nov 26, 2025
a4dda82
ruff
JoschD Nov 26, 2025
7fa1d9a
fixing not giving IPs
JoschD Nov 27, 2025
89ba2d4
test measurement_analysis
JoschD Nov 28, 2025
0a3bf4d
ruff
JoschD Nov 28, 2025
894ad6f
fix test
JoschD Dec 1, 2025
60389a2
better comment
JoschD Dec 1, 2025
9beb144
test plot correctors
JoschD Dec 1, 2025
5be178b
actually add file
JoschD Dec 1, 2025
58439d3
plotting detuning
JoschD Dec 1, 2025
24f173b
full tests
JoschD Dec 1, 2025
0d7aa2a
ruff
JoschD Dec 1, 2025
503f91d
reactivate tests
JoschD Dec 2, 2025
e7392fb
fixing Self
JoschD Dec 2, 2025
ac54022
test fix
JoschD Dec 2, 2025
3fc250e
agg on win
JoschD Dec 3, 2025
f5f76f3
workflow rework
JoschD Dec 4, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
# https://docs.github.com/en/repositories/managing-your-repositorys-settings-and-features/customizing-your-repository/about-code-owners

# GLOBAL CODEOWNERS ---
# These owners will be the default owners for everything in
# the repo. Unless a later match takes precedence,
# they will be requested for review when someone opens a pull request.
* @pylhc/approved-reviewers
28 changes: 28 additions & 0 deletions .github/workflows/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Continous Integration Workflows

This package implements different workflows for CI, based on our organisation's common workflows.
They are organised as follows.

### Documentation

The `documentation` workflow triggers on any push to master, builds the documentation and pushes it to the `gh-pages` branch (if the build is successful).

### Testing Suite

Tests are ensured in the `tests` workflow, which triggers on all pushes.
It runs on a matrix of all supported operating systems for all supported Python versions.

### Test Coverage

Test coverage is calculated in the `coverage` wokflow, which triggers on pushes to `master` and any push to a `pull request`.
It reports the coverage results of the test suite to `CodeClimate`.

### Regular Testing

A `cron` workflow triggers every Monday at 3am (UTC time) and runs the full testing suite, on all available operating systems and supported Python versions.
It also runs on `Python 3.x` so that newly released Python versions that would break tests are automatically included.

### Publishing

Publishing to `PyPI` is done through the `publish` workflow, which triggers anytime a `release` is made of the GitHub repository.
It builds a `wheel`, checks it, and pushes to `PyPI` if checks are successful.
16 changes: 16 additions & 0 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Runs all tests and creates a coverage report
name: Coverage

on: # Runs on all push events to master branch and any push related to a pull request
push:
branches:
- master
pull_request: # Check requried coverage before able to merge

jobs:
coverage:
uses: pylhc/.github/.github/workflows/coverage.yml@master
with:
src-dir: ir_amplitude_detuning
pytest-options: --cov=examples
secrets: inherit
11 changes: 11 additions & 0 deletions .github/workflows/cron.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Runs all tests on master on Mondays at 3 am (UTC time)
name: Cron Testing


on:
schedule:
- cron: '* 3 * * mon'

jobs:
tests:
uses: pylhc/.github/.github/workflows/cron.yml@master
14 changes: 14 additions & 0 deletions .github/workflows/documentation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# Build documentation
# The build is uploaded as artifact if the triggering event is a push for a pull request
# The build is published to github pages if the triggering event is a push to the master branch (PR merge)
name: Build and upload documentation

on: # Runs on any push event in a PR or any push event to master
pull_request:
push:
branches:
- 'master'

jobs:
documentation:
uses: pylhc/.github/.github/workflows/documentation.yml@master
11 changes: 11 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Publishes to PyPI upon creation of a release
name: Upload Package to PyPI

on: # Runs everytime a release is added to the repository
release:
types: [created]

jobs:
deploy:
uses: pylhc/.github/.github/workflows/publish.yml@master
secrets: inherit
24 changes: 24 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Runs all unit-tests.
# The examples are run as part of the coverage workflow.
name: Tests

defaults:
run:
shell: bash

on: # Runs on any push event to any branch except master (the coverage workflow takes care of that)
push:
branches-ignore:
- 'master'

jobs:
tests:
uses: pylhc/.github/.github/workflows/tests.yml@master
with:
pytest-options: -m "not example"

# examples:
# needs: tests
# uses: pylhc/.github/.github/workflows/tests.yml@master
# with:
# pytest-options: -m "example"
210 changes: 210 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,210 @@
# Originally created by .ignore support plugin (hsz.mobi)

### Python template
# Byte-compiled / optimized / DLL files
__pycache__/
*pycache*
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
pip-wheel-metadata/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.nox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
.hypothesis/
.pytest_cache/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx build directory and sphinx-gallery generated documents
docs/_build/
doc/_build/
doc_build/
.doc_build
.doc_build/
.docs/gallery
.docs/gallery/
.docs/gen_modules
.docs/gen_modules/

# PyBuilder
target/

# Jupyter Notebook
.ipynb_checkpoints/

# IPython
profile_default/
ipython_config.py

# pyenv
.python-version


# celery beat schedule file
celerybeat-schedule

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
site/

# mypy
.mypy_cache/
.dmypy.json
dmypy.json

# Pyre type checker
.pyre/

### JetBrains template
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio and WebStorm
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839

# User-specific stuff

# *.iml
# *.ipr

# CMake
cmake-build-*/

# File-based project format
*.iws

# IntelliJ
.idea/
out/
.idea_modules/

# JIRA plugin
atlassian-ide-plugin.xml

# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties
fabric.properties

### macOS template
# General
.DS_Store
.AppleDouble
.LSOverride

# Icon must end with two \r
Icon

# Thumbnails
._*

# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent

# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk

### JupyterNotebooks template
# gitignore template for Jupyter Notebooks
# website: http://jupyter.org/

.ipynb_checkpoints
*/.ipynb_checkpoints/*

# Remove previous ipynb_checkpoints
# git rm -r .ipynb_checkpoints/
#

# VSCode
.vscode
.vscode/

# Neovim
.nvimlog
*.swap

### OMC Users
# files for testing things (jdilly convention)
tst_*
15 changes: 15 additions & 0 deletions .zenodo.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
{
"creators": [
{
"name": "OMC-Team",
"affiliation": "CERN"
},
{
"name": "Joschua Dilly",
"affiliation": "CERN",
"orcid": "0000-0001-7864-5448"
}
],
"title": "ir_amplitude_detuning",
"description": "Python tools to correct amplitude detuning in the insertion regions of a particle accelerator.."
}
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Changelog

#### v1.0.0 - 2025-12-XX

- Initial release
- Examples: `2018_md3311`, `2022_commissioning` and `2022_md6863`
21 changes: 21 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
MIT License

Copyright (c) 2025 pylhc/OMC-Team

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Loading