Startup
This commit is contained in:
23
script/SampleDetection.py
Normal file
23
script/SampleDetection.py
Normal file
@@ -0,0 +1,23 @@
|
||||
###################################################################################################
|
||||
# Example of using ImageJ functionalities through ijutils.
|
||||
###################################################################################################
|
||||
|
||||
from ijutils import *
|
||||
import java.awt.Color as Color
|
||||
|
||||
#Image Loading
|
||||
ip = load_image("{images}/test2.png", title="Image")
|
||||
|
||||
aux = grayscale(ip, in_place=False)
|
||||
aux.show()
|
||||
|
||||
invert(aux); aux.repaintWindow()
|
||||
#gaussian_blur(aux); aux.repaintWindow()
|
||||
subtract_background(aux); aux.repaintWindow()
|
||||
auto_threshold(aux); aux.repaintWindow()
|
||||
binary_open(aux); aux.repaintWindow()
|
||||
#binary_fill_holes(aux); aux.repaintWindow()
|
||||
(results,output_img)=analyse_particles(aux, 250,1000,
|
||||
fill_holes = False, exclude_edges = True,print_table=True,
|
||||
output_image = "outlines", minCirc = 0.7, maxCirc = 1.0)
|
||||
output_img.show()
|
||||
Reference in New Issue
Block a user