finesse-virgo
Finesse 3.0 Virgo models, tools, and data. This package is an optional extra to the finesse package which must be installed to use this package.
Quick Plots
These plots have been generated using the current configuration of the model (see scripts/build_plots.py).
Installation
From PyPI
If you just want to use the tools and models provided you can use pip install finesse-virgo to install the latest tagged commit.
From Source
If you want to have the latest changes you can instead install from source:
git clone https://gitlab.com/ifosim/finesse/finesse-virgo.git
cd finesse-virgo
pip install -e .
Periodically running git pull will then retrieve any changes.
Documentation
Documentation explaining the parameters used in the model can be found at https://finesse.ifosim.org/docs/finesse-virgo/latest/ (HTML) and https://finesse.ifosim.org/docs/finesse-virgo/pdf/latest/ (PDF).
Alternatively, the documentation can be built from the source, found at https://git.ligo.org/finesse/finesse-virgo-docs/ .
Usage
This package includes top-level tools and models for simulating Virgo in Finesse 3. Individual simulations that you perform should be stored elsewhere, such as the finesse_playground repository. Your scripts should just import this package.
The Virgo pre-tuning tool can be used to create an AdV+ model and pre-tune it to an operating point.
Start by creating a Virgo model:
# create a new Virgo model
virgo = finesse.virgo.Virgo()
This will create a Virgo model using the current state of the common file.
Alternatively, an existing configuration can be provided as a starting point:
# create a Virgo model using a custom input file
virgo = finesse.virgo.Virgo('custom_file.kat')
This will parse the necessary files into a Finesse 3 model and prepare the model for tuning. See examples/creating_virgo.ipynb for additional examples.
With the Virgo model created, we can then begin to step through the pre-tuning process:
# step 1: adjust the cavity lengths
virgo.adjust_PRC_length()
virgo.adjust_SRC_length()
# step 2: pretune
virgo.pretune()
# step 3: optimize demodulation phases
virgo.optimize_demodulation_phase()
# step 4: optimize lock gains
virgo.optimize_lock_gains()
# step 5: run RF locks
virgo.model.run(RunLocks(method="newton"))
# step 6: switch DARM to DC lock with an offset
virgo.model.run(DARM_RF_to_DC())
Alternatively, the previous steps can be combined by simply using make():
# completes all steps at once
virgo.make()
See examples/general_usage.ipynb for additional examples.
Printing
Various printing functions are available to display information about the current state of the model.
For example, it may be useful to display important lengths and frequencies:
# display lengths and
virgo.print_lengths()
┌─────────────────────────────────────────────────┐
│- Arm lengths [m]: │
│ LN = 2999.8180 LW = 2999.7880 │
├─────────────────────────────────────────────────┤
│- Michelson and recycling lengths [m]: │
│ ln = 6.0152 lw = 5.7851 │
│ lpr = 6.0513 lsr = 6.0509 │
│ lMI = 5.9001 lSchnupp = 0.2301 │
│ lPRC = 11.9515 lSRC = 11.9511 │
├─────────────────────────────────────────────────┤
│- Associated cavity frequencies [Hz]: │
│ fsrN = 49968.44 fsrW = 49968.94 │
│ fsrPRC = 12542050.98 fsrSRC = 12542480.59 │
│ │
│- Modulation sideband frequencies [MHz]: │
│ f6 = 6.270777 f8 = 8.361036 │
│ f56 = 56.436993 │
├─────────────────────────────────────────────────┤
│- Check frequency match [MHz]: │
│ 125.5*fsrN-300 = 6.270739 │
│ 0.5*fsrPRC = 6.271025 │
│ 0.5*fsrSRC = 6.271240 │
│ 9*f6 = 56.436993 │
└─────────────────────────────────────────────────┘
Or display the carrier power at key nodes throughout the interferometer:
# display carrier power at key nodes
virgo.print_powers()
┌────────────────────────────────────────┐
│ Detector Power [W] Pow. ratio │
├────────────────────────────────────────┤
│ CAR_AMP_PRin : 40 1 │
│ CAR_AMP_N : 2.482e+05 6205 │
│ CAR_AMP_W : 2.454e+05 6134 │
│ CAR_AMP_BS : 1748 43.69 │
│ CAR_AMP_AS : 0.0182 0.000455 │
└────────────────────────────────────────┘
See examples/printing.ipynb for more printing examples.
Plotting
The quantum-noise limited sensitivity curve is a good way to determine if we are at an operating point:
virgo.plot_QNLS()
Similarly, the DARM transfer function can also be plotted:
virgo.plot_DARM()
See examples/plotting.ipynb for additional plotting examples.
Contributing
If you want to contribute any changes or code to this project then it must be done via a merge request. Merge requests must pass all tests before being merged.
The pipeline will fail if pre-commit has not been run. After cloning the git repository please run pip install pre-commit; pre-commit install. This will ensure that formatting and simple code errors are fixed using black and flake8.
Documentation for functions should be in the numpydoc format: https://numpydoc.readthedocs.io/en/latest/format.html
Adding new katscript
New KatScript elements and commands must be registered with the FINESSE parser. This is done in the top level __init__.py which registers each of the objects required.
Support
Please post an issue if you are experiencing any bugs, problems, or feature requests. https://chat.ligo.org/ligo/channels/finesse can also be used for broader discussion on Finesse and modelling Virgo with it.
License
All code here is distributed under GPL v3.
Packaging
The finesse-virgo is automatically uploaded to pypi when new tags are pushed to main. Tags must be annotated and be in the semantic versioning form MAJOR.MINOR.PATCH:
- MAJOR version when you make incompatible API changes,
- MINOR version when you add functionality in a backwards compatible manner, and
- PATCH version when you make backwards compatible bug fixes.
Only maintainers can push tags to the main branch.
Metadata
Release files for finesse-virgo 1.0.9
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| finesse_virgo-1.0.9.tar.gz | 1.0 MB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| finesse_virgo-1.0.9-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 1.1 MB
Release files / finesse_virgo-1.0.9.tar.gz
| Download URL | finesse_virgo-1.0.9.tar.gz |
|---|---|
| Size | 1.0 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0e8caa88420d9ee74857f1d9eec47ee1db45e526b3055794775d3c104ac9662d
|
|
BLAKE2b-256 checksum How to use checksums |
495532909f902fde9175ddb5aed5eb1cb5ad2e7a4e67aa6738947ae6b8c4c927
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.0 CPython/3.10.14
|
Release files / finesse_virgo-1.0.9-py3-none-any.whl
| Download URL | finesse_virgo-1.0.9-py3-none-any.whl |
|---|---|
| Size | 45.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a780a290f0a3ca8949f12bbccc75e9bdbc09b5b828ead894eca5411771d8d40e
|
|
BLAKE2b-256 checksum How to use checksums |
4816242e5d8a84a80f96e5cba24454c36f059d57028af754a58d3d50cfb1b58f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.0 CPython/3.10.14
|
Security for finesse-virgo 1.0.9
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.