nion-software / nionswift

Nion Swift is open source scientific image processing software integrating hardware control, data acquisition, visualization, processing, and analysis using Python. Nion Swift is easily extended using Python. It runs on Windows, Linux, and macOS.
http://nion.com/swift
GNU General Public License v3.0
44 stars 33 forks source link

Provide an API to load projects without launching the UI #539

Open cmeyer opened 3 years ago

cmeyer commented 3 years ago

This is useful for 3rd party readers that want to access a Swift project in a sanctioned manner. See HyperSpy Swift Library as an example.

The user should pass a file and the API should automatically determine the type of project (an indexed project or a folder project), load it, and give access to the items inside.

The API should also allow the caller to load older versions of libraries in a read-only state.

The API should allow the user to do basic read-only operations with the minimum functionality being to access data and metadata of data items.

The API should strive to adhere to the existing Swift API as much as possible.

Future extensions possibilities include higher level project operations such as copying, renaming, or upgrading projects; read/modify/write capabilities for manipulating projects; and perhaps explicit control of the computation machinery to compute new data items and otherwise control the state of the project.

### Tasks
- [ ] Split nion.swift.model into its own project?
- [ ] A dedicated reader library? (no need for computations, etc.)
cmeyer commented 3 years ago

References:

https://github.com/hyperspy/hyperspy_swift_library/issues/3

@ltizei