GithubHelp home page GithubHelp logo

chinchien-lin / imagej-jython-package Goto Github PK

View Code? Open in Web Editor NEW

This project forked from m-entrup/imagej-jython-package

0.0 1.0 0.0 11 KB

A minimal envirement to package Jython modules with maven.

Home Page: http://imagej.net/Jython_Scripting#Bundle_packages_in_a_JAR_file

Python 100.00%

imagej-jython-package's Introduction

imagej-jython-package

A minimal environment to package Jython modules with maven.

Motivation

With ImageJ it is possible to use self written Jython modules to extend the functionality. Packages and modules can be placed at the directory jars/Lib. ImageJ's Jython is configured to add jars/Lib to the default search path for packages and modules.

If you want to use the Updater to distribute Jython packages and modules, it can be handy pack these files as a singe Jar file. As mavens is designed to create Jar files, it can be used to automate the packaging. This repository is a template for a maven project to achieve the given goal.

How-to use it

The prerequisite for using this template is to have maven installed. Afterwards only four steps will allow you to use batch_opener.py.

  1. Clone this repository.

    git clone [email protected]:m-entrup/imagej-jython-package
  2. Create the jar file by running maven.

    cd imagej-jython-package
    mvn package
  3. Copy the jar file to jars/Lib. Lib may not exist, yet.

    mkdir -p path-to-ImageJ/jars/Lib
    cp target/imagej-jython-package-0.1.0-SNAPSHOT.jar path-to-ImageJ/jars/Lib/
  4. Start ImageJ and run the following Jython script.

    # @File(label='Choose a directory', style='directory') import_dir
    
    from examplePackage import batch_opener
    
    images = batch_opener.batch_open_images(import_dir, recursive=True)
    for image in images:
    	print(image)

imagej-jython-package's People

Contributors

m-entrup avatar ctrueden avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.