PyScanPatterns
Parametric scan patterns for imaging applications.
Galvo drive signals, line camera/PMT exposure triggers, and frame/digitizer triggers are generated given a scan type and parameters. The exposure pulse is defined by the samples_on and samples_off parameters and this period (samples_on + samples_off) is used to create a pattern with a fixed number of exposures for a given max_line_rate.
Used for an SD-OCT imaging system, but should work for ultrasound and laser scanning microscopy applications.
Installation
pip install scanpatterns
Features
The following patterns are possible:
- Raster scan
- Line scan
- Raster scan with repeated A-lines
- Raster scan with repeated B-lines
- Bidirectional raster scan
- Circle scans
- Figure-8 scan (modified lissajous)
- Rhodonea rose scan with odd number of petals
Patterns are created by calling the generate method of any LineScanPattern instance or by passing
the arguments of generate to the constructor.
The resultant scan signals can be accessed via the x, y, line_trigger and frame_trigger properties.
Other properties of a pattern such as pattern_rate, frame_rate, and the arguments used to create the pattern
are also available.
Gallery
RasterScanPattern(16, 16, 76000, samples_on=1, samples_off=10)
RasterScanPattern(16, 16, 76000, samples_on=1, samples_off=10, fast_axis_step=True, slow_axis_step=True)
RasterScanPattern(16, 16, 76000, samples_on=1, samples_off=10, bline_repeat=2)
RasterScanPattern(16, 16, 76000, fov=[1.5, 4.5], samples_on=1, samples_off=10, fast_axis_step=True, slow_axis_step=True)
RasterScanPattern(16, 16, 76000, samples_on=1, samples_off=10, fast_axis_step=True, slow_axis_step=True, rotation_rad=np.pi/4)
RasterScanPattern(15, 15, 76000, samples_on=1, samples_off=10, bidirectional=True, slow_axis_step=True)
RasterScanPattern(15, 1, 76000, samples_on=1, samples_off=10)
RasterScanPattern(15, 1, 76000, samples_on=1, samples_off=10, bidirectional=True, rotation_rad=np.pi/8)
CircleScanPattern(64, 1.0, 76000, samples_on=1)
Figure8ScanPattern(1.0, 16, 76000)
RoseScanPattern(3, 1, 16, 76000, samples_on=1, samples_off=10)
RoseScanPattern(5, 1, 16, 76000, samples_on=1, samples_off=10)
Metadata
Release files for scanpatterns 0.2.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 |
|---|---|---|---|---|
| scanpatterns-0.2.0.tar.gz | 11.2 kB | Without provenance | Details for scanpatterns-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| scanpatterns-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for scanpatterns-0.2.0-py3-none-any.whl |
Total release size: 21.1 kB
Release files / scanpatterns-0.2.0.tar.gz
| Download URL | scanpatterns-0.2.0.tar.gz |
|---|---|
| Size | 11.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9850f47b755b1561c62bcd6e5d6ff9112c63a16454898fa6ab5e69e1c86cc5d5
|
|
BLAKE2b-256 checksum How to use checksums |
d76ec07b160949178e56dd088c12c0d07aff0df897fcc29981a58b9cee7d2dd2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.64.0 importlib-metadata/4.8.3 keyring/23.4.1 rfc3986/1.5.0 colorama/0.4.4 CPython/3.6.15
|
Release files / scanpatterns-0.2.0-py3-none-any.whl
| Download URL | scanpatterns-0.2.0-py3-none-any.whl |
|---|---|
| Size | 9.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
34e429587d8278e1bac07df6932957a256eb0d57b01b16606281a74c5c051499
|
|
BLAKE2b-256 checksum How to use checksums |
28361182df3f1bc79139c296d980e2c301aea59d97ce6dc2db7be23f5b829f45
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.64.0 importlib-metadata/4.8.3 keyring/23.4.1 rfc3986/1.5.0 colorama/0.4.4 CPython/3.6.15
|
Security for scanpatterns 0.2.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.