Module AmpliVision.src.phaseA

Functions

def display_grid(image_scan, Grid_DS, contours)
def display_img(image, t=100, title='image')
def get_image_scan(image: numpy.ndarray, is_pre_scanned: bool, idx: int, path_to_imgs: str, scanned_path: str, white_balance: bool) ‑> tuple

Create Image object from loaded image. The Image object is used to store the image and the steps of the image processing.

def phaseA1(path_to_imgs: str, scanned_path: str, display: bool = False, is_pre_scanned: bool = False, do_white_balance: bool = False) ‑> list

Phase A1

Loads and scans the images.

Args:

path_to_imgs: path to images to be loaded

Returns:

scanned_images : The images scanned

def phaseA2(scanned_images: dict, display: bool = False) ‑> dict

Phase A2

Finds the blocks in the image and creates the virtual representation of grids.

Args:

scanned_images: the scanned images

Returns:

Grids: Grid object with the blocks and pins

def phaseA3(Grids, display: bool = False)

Phase A2

Generates graph like structures of the tests, aka what is the sequence of blocks being used.

Args:

Grids: Grid object with the blocks and pins

Returns:

graphs: Position Graph representing the configuration of the test blocks. Eg. Sample -> Test Block 1 -> etc.

def seen_file(idx: int, scanned_path: str) ‑> bool