Files
scikit-image/skimage/morphology/heap_watershed.pxi
T
2013-02-24 14:14:14 +01:00

28 lines
556 B
Cython

"""
Originally part of CellProfiler, code licensed under both GPL and BSD
licenses.
Website: http://www.cellprofiler.org
Copyright (c) 2003-2009 Massachusetts Institute of Technology
Copyright (c) 2009-2011 Broad Institute
All rights reserved.
Original author: Lee Kamentsky
"""
cimport numpy as cnp
cdef struct Heapitem:
cnp.int32_t value
cnp.int32_t age
Py_ssize_t index
cdef inline int smaller(Heapitem *a, Heapitem *b):
if a.value <> b.value:
return a.value < b.value
return a.age < b.age
include "heap_general.pxi"