Closedown
This commit is contained in:
@@ -14,4 +14,4 @@ def detect_samples(ip):
|
||||
output_image = "outlines", minCirc = 0.9, maxCirc = 1.0)
|
||||
|
||||
ip = load_array(img.getData().getMatrix())
|
||||
detect_sample()
|
||||
detect_samples(ip)
|
||||
@@ -1,17 +1,24 @@
|
||||
from ijutils import *
|
||||
import java.awt.Color as Color
|
||||
|
||||
|
||||
#ip = load_array(img.getData().getMatrix())
|
||||
#ip = load_array(img.getOutput())
|
||||
ip = load_image("{images}/test3.png", title="Image")
|
||||
|
||||
|
||||
def detect_samples(ip):
|
||||
aux = grayscale(ip, in_place=False)
|
||||
invert(aux)
|
||||
subtract_background(aux)
|
||||
auto_threshold(aux)
|
||||
binary_open(aux)
|
||||
return analyse_particles(aux, 250,1000,
|
||||
aux = grayscale(ip, in_place=False)
|
||||
aux.show()
|
||||
|
||||
convolve(aux, KERNEL_SOBEL); aux.repaintWindow()
|
||||
|
||||
invert(aux); aux.repaintWindow()
|
||||
subtract_background(aux); aux.repaintWindow()
|
||||
auto_threshold(aux); aux.repaintWindow()
|
||||
binary_open(aux); aux.repaintWindow()
|
||||
|
||||
(table, image) = analyse_particles(aux, 250,1000,
|
||||
fill_holes = False, exclude_edges = True,print_table=True,
|
||||
output_image = "outlines", minCirc = 0.9, maxCirc = 1.0)
|
||||
|
||||
ip = load_array(img.getData().getMatrix())
|
||||
detect_samples(ip)
|
||||
|
||||
image.show()
|
||||
Reference in New Issue
Block a user