Difference between revisions of "IJ2-python-lib"

(Replaced content with "Now integrated to https://github.com/hadim/fiji_scripts")
Line 1: Line 1:
Now integrated to https://github.com/hadim/fiji_scripts
| name                  = ij2-python-lib
| logo                    =
| software              = Fiji
| author                = {{Person|Hadim}}
| maintainer            = {{Person|Hadim}}
| source                = {{GitHub|org=hadim|repo=ij2-python-lib}}
| released              = 15/11/2016
| status                = v0.1.0, development
| category              =
== Presentation ==
''ij2-python-lib'' is a set of IJ2 Python Libraries.
Note that this library has been designed to regroup useful functions the author use often. And so many functions are very specific to the use-case of the author.
== Install ==
Add the ''Hadim'' update site in ''Help ▶ Update…'' (see http://imagej.net/Following_an_update_site for details on how to proceed).
== Documentation ==
The best documentation is [https://github.com/hadim/ij2-python-lib/tree/master/src/main/resources/ij2_tools the source code].
Some functions have <code>ij</code> has a first argument, it excepts to receive an <code>ImageJ</code> object. 
<source lang="python"># Do a maximum Z projection
from ij2_tools.z_projection import do_z_projection
do_z_projection(ij, data, save=False, output_dir="")
# Apply a DOG filter
from ij2_tools.dog_filtering import apply_dog_filter
apply_dog_filter(ij, data, sigma1, sigma2, save=False, output_dir="")
# Apply automatic threshold on an image
# Method is string representing available algorithm in `ops.threshold`
from ij2_tools.threshold import do_threshold
do_threshold(ij, data, method, k1=1, save=False, output_dir="")
# Subtract the first image of a stack to the entire stack
from ij2_tools.subtract import subtract_first_image
subtract_first_image(ij, data, save=False, output_dir=""):
# Print dataset dimensions for X, Y, Z, TIME and CHANNEL
from ij2_tools.ij_utils import print_info
# Check if a point is inside a circle
from ij2_tools.geometry import in_circle
in_circle(point, center, radius)
# Return the points defining a circle
from ij2_tools.geometry import get_circle_points
get_circle_points(x_center, y_center, radius, n=20)
# Return the points defining the association of two circles
from ij2_tools.geometry import get_two_circles_points
get_two_circles_points(x1, y1, x2, y2, radius, n=20)
# Detect spots using the TrackMate DOG Detector
from ij2_tools.spot_detector import dog_detector
dog_detector(ij, data, radius, relative_threshold=1, doSubpixel=True, doMedian=False, calibration=None)
# Return the IJ1 ROI Manager
from ij2_tools.ij1 import get_roi_manager
== Related links ==
* Source code on GitHub : https://github.com/hadim/ij2-python-lib
== Authors ==
''ij2-python-lib'' has been created by Hadrien Mary.
This work started in 2016 at the Gary Brouhard laboratory (http://brouhardlab.mcgill.ca) at McGill University.

Latest revision as of 13:31, 13 December 2016

Now integrated to https://github.com/hadim/fiji_scripts