https://github.com/danporter/complex_array_viewer
Simple tkinterface for viewing 3D complex numpy arrays.
https://github.com/danporter/complex_array_viewer
Last synced: 12 months ago
JSON representation
Simple tkinterface for viewing 3D complex numpy arrays.
- Host: GitHub
- URL: https://github.com/danporter/complex_array_viewer
- Owner: DanPorter
- Created: 2023-10-31T07:12:36.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2023-11-01T11:51:54.000Z (over 2 years ago)
- Last Synced: 2025-04-02T19:14:17.809Z (about 1 year ago)
- Language: Python
- Size: 194 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# complex_array_viewer
Simple tk interface for viewing 3D complex numpy arrays.

**Version 0.2**
| By Dan Porter |
| --- |
| Diamond Light Source |
| 2023 |
#### To run viewer:
```commandline
$ python -m complex_array_viewer 'file.npy'
```
or in python:
```python
from complex_array_viewer import ComplexArrayViewer
ComplexArrayViewer('file.npy', figure_dpi=80)
from complex_array_viewer import MultiAngleViewer
MultiAngleViewer([f'file{n}.npy' for n in range(6)], figure_dpi=80, ncols=3)
```
#### Requires:
*numpy, matplotlib, tkinter*
#### Usage:
Start by clicking "Load" to load a complex 3D .npy file.
The magnitudes and phases will be displayed with a slider to scroll through the slices.
The axis of slicing can be choosen, and various options can be altered, including:
- Mask the data below amplitudes of a value
- View the log of the amplitudes
- View the phases in Degrees (rather than phases)
- View the absolute phases (|phase < 0|)
- View the sin of the phases
- View the differential
- Colormap (cyclic colormaps are twilight and hsv)
- Colormap limits