semvec/pypi-packages huggingface dataset:
MicroscPSF-Py 0.2
Gibson-Lanni PSF calculation code.
License: MIT
Keywords: PSF,microscopy

## MicroscPSF-Py ##

This is a Python implementation of the fast microscope PSF generation tool (using the Gibson-Lanni model).
Technical details can be found [here](http://www.ee.cuhk.edu.hk/~jzli/MicroscPSF/).

[![Linux Build Status](https://travis-ci.org/MicroscPSF/MicroscPSF-Py.svg?branch=master)](https://travis-ci.org/MicroscPSF/MicroscPSF-Py)
[![PyPI version](https://badge.fury.io/py/MicroscPSF-Py.svg)](https://badge.fury.io/py/MicroscPSF-Py)

### Install ###

#### PyPI ####

```
$ python -m pip install MicroscPSF-Py
````

#### Source ####

```
$ git clone https://github.com/MicroscPSF/MicroscPSF-Py.git
$ cd MicroscPSF-Py
$ python setup.py install
```

### Usage ###

Please see the [examples.ipynb](https://github.com/MicroscPSF/MicroscPSF-Py/blob/master/examples.ipynb) Jupyter notebook.

### Acknowledgements ###

- Original algorithm Li, J., Xue, F., & Blu, T. (2017). Fast and accurate three-dimensional point spread function computation for fluorescence microscopy. JOSA A, 34(6), 1029-1034. [link](https://doi.org/10.1364/JOSAA.34.001029).

- Python implementation by Kyle Douglass and Hazen Babcock.
consoleimages 1.0.0
Reads image formats and prints ascii colour text to console
License: MIT

## consoleimages
### Reads image formats and prints ascii colour text to console
Create an instance of the `image` class passing the path of a image as an argument.
Instance arguments:
	- `width` (of `astext` string)
	- `height` (of `astext` string)
	- `aspect_ratio` (`width`/`height`)
	- `astext` (string that gets printed to the console)
	- `name` (the name of the image file)
	- `display()` (pass a file to write to, otherwise sys.stdout)

---
Example:
```python
from os import get_terminal_size, listdir
from os.path import isfile, join
from time import sleep

from consoleimages import image

def clear():
	from os import system
	from sys import platform
	system("cls" if platform == "win32" else "clear") # clears the console

images = {}

while True:
	for imagename in [f for f in listdir("images/") if isfile(join("images/", f))]: # open the 'images/' directory and get all the file names inside.
		clear() # clear console

		images[imagename] = image("images/" + imagename, get_terminal_size()[1] - 4) # create instance of image class

		print(images[imagename].name) # print the name of the image in that instance
		images[imagename].display() # print the image
		print(images[imagename].width, images[imagename].height, sep=" x ", end=" (" + str(images[imagename].aspect_ratio) + ")\n") # print the width, height and aspect ratio
		sleep(2) # wait 2 seconds
```
consoleimage 1.0.0
Reads image formats and prints ascii colour text to console
License: MIT

## consoleimage
### Reads image formats and prints ascii colour text to console
Create an instance of the `image` class passing the path of a image as an argument.
Instance arguments:
	- `width` (of `astext` string)
	- `height` (of `astext` string)
	- `aspect_ratio` (`width`/`height`)
	- `astext` (string that gets printed to the console)
	- `name` (the name of the image file)
	- `display()` (pass a file to write to, otherwise sys.stdout)

---
Example:
```python
from os import get_terminal_size, listdir
from os.path import isfile, join
from time import sleep

from image import image # image.py is made all by me

def clear():
	from os import system
	from sys import platform
	system("cls" if platform == "win32" else "clear") # clears the console

images = {}

while True:
	for imagename in [f for f in listdir("images/") if isfile(join("images/", f))]: # open the 'images/' directory and get all the file names inside.
		clear() # clear console

		images[imagename] = image("images/" + imagename, get_terminal_size()[1] - 4) # create instance of image class

		print(images[imagename].name) # print the name of the image in that instance
		images[imagename].display() # print the image
		print(images[imagename].width, images[imagename].height, sep=" x ", end=" (" + str(images[imagename].aspect_ratio) + ")\n") # print the width, height and aspect ratio
		sleep(2) # wait 2 seconds
```