Visisipy: accessible vision simulations in Python
Visisipy (pronounced /ˌvɪsəˈsɪpi/, like Mississippi but with a V) is a Python library for optical simulations of the eye.
It provides an easy-to-use interface to define and build eye models, and to perform common ophthalmic analyses on these models.
Goals
- Provide a uniform interface to define, build and analyze various types of eye models, using abstractions that are relevant in a clinical context.
- Provide a collection of ready-to-use eye models, such as the Navarro model1, that can be customized as needed.
- Provide an accessible interface to clinically relevant analyses on these models, such as off-axis refraction calculations.
- Modular design with support for multiple backends, both open-source and commercial.
Contributing
Visisipy aims to be a community-driven project and warmly accepts contributions. If you want to contribute, please email us (visisipy@mreye.nl) or open a new discussion.
Installation
Visisipy can be installed through pip:
pip install visisipy
Visisipy is also available on Conda Forge:
conda install -c conda-forge visisipy
Example
import matplotlib.pyplot as plt
import seaborn as sns
import visisipy
# Uncomment the following line to use the open-source Optiland backend instead of OpticStudio
# visisipy.set_backend("optiland")
# Initialize the default Navarro model
model = visisipy.EyeModel()
model.geometry.pupil.thickness = 2.0
# Build the model in OpticStudio
model.build()
# Perform a raytrace analysis
coordinates = [(0, 0), (0, 10), (0, 20), (0, 30), (0, 40)]
raytrace = visisipy.analysis.raytrace(coordinates=coordinates)
# Alternatively, the model can be built and analyzed in one go:
# raytrace = visisipy.analysis.raytrace(model, coordinates=zip([0] * 5, range(0, 60, 10)))
# Visualize the model
fig, ax = plt.subplots()
visisipy.plots.plot_eye(ax, model.geometry, lens_edge_thickness=0.5)
sns.lineplot(raytrace, x="z", y="y", hue="field", ax=ax)
plt.show()
Documentation
Read the full documentation at visisipy.readthedocs.io.
Metadata
Release files for visisipy 0.5.0
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 | Actions |
|---|---|---|---|---|
| visisipy-0.5.0.tar.gz | 8.0 MB | Without provenance | Details for visisipy-0.5.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| visisipy-0.5.0-py3-none-any.whl | Python 3 | none | any | Details for visisipy-0.5.0-py3-none-any.whl |
Total release size: 8.2 MB
Release files / visisipy-0.5.0.tar.gz
| Download URL | visisipy-0.5.0.tar.gz |
|---|---|
| Size | 8.0 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1fa269bf167de4707d2b415d31a6d183911cb68a698f451dc9a6e89babc9632d
|
|
BLAKE2b-256 checksum How to use checksums |
43f6c33a69771dfb538ed9d471f7ffc62989ff98d9a58fd91fcfc062b794b407
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.13.3 {"installer":{"name":"uv","version":"0.13.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Release files / visisipy-0.5.0-py3-none-any.whl
| Download URL | visisipy-0.5.0-py3-none-any.whl |
|---|---|
| Size | 130.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
2468c41e901bb1f6a20890d2a270b5a809fc671d531e12565467212b8ffe0b81
|
|
BLAKE2b-256 checksum How to use checksums |
f315bce66f07eed346ae2caa2ac6b743e5dc801f7da272a7501a78389dc44156
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
uv/0.13.3 {"installer":{"name":"uv","version":"0.13.3","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
|
Security for visisipy 0.5.0
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.