From 0d13447c5468de9d4058c82c0f07986529f56402 Mon Sep 17 00:00:00 2001 From: gac-S_Changer Date: Wed, 14 Sep 2016 15:48:20 +0200 Subject: [PATCH] Script execution --- script/imgtest.py | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 script/imgtest.py diff --git a/script/imgtest.py b/script/imgtest.py new file mode 100644 index 0000000..f2236a9 --- /dev/null +++ b/script/imgtest.py @@ -0,0 +1,33 @@ +################################################################################################### +# Example of using ImageJ functionalities through ijutils. +################################################################################################### + +from ijutils import * +import java.awt.Color as Color + +#Image Loading +ip = load_image("{images}/test.png", title="Image") + +aux = ip.duplicate() +aux.show() +grayscale(aux) +#gaussian_blur(aux); aux.repaintWindow() +invert(aux); aux.repaintWindow() +#smooth(aux); aux.repaintWindow() +#sharpen(aux); aux.repaintWindow() + + + +#Histogram +plot(get_histogram(aux)) + + + + +auto_threshold(aux) +#binary_fill_holes(aux) +#aux.show() +(results,output_img)=analyse_particles(aux, 100,5000, + fill_holes = True, exclude_edges = True,print_table=True) +output_img.show() +