Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,6 @@
target/*
target
src/main/resources/models
src/main/resources/analytics.properties
.classpath
.project
.settings
46 changes: 35 additions & 11 deletions README → README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@ Copyright 2010-2012 Benjamin Van Durme. All rights reserved.
This software is released under the 2-clause BSD license.
See jerboa/LICENSE, or http://cs.jhu.edu/~vandurme/jerboa/LICENSE

Jerboa
======

Introduction
------------

Jerboa is a package for prototyping randomized/streaming algorithms and data
structures, primarily intended for HLT applications. As of the time of this
writing much of the library is Java-based: not for efficiency, but for ease of
Expand All @@ -14,22 +20,40 @@ then feel free to issue a pull request via GitHub.

To reference this package in academic writing:

<pre>
@TechReport{Jerboa:TR:2012,
author = {Benjamin {Van Durme}},
title = {Jerboa: A Toolkit for Randomized and Streaming Algorithms},
institution = {Human Language Technology Center of Excellence, Johns Hopkins University},
year = {2012},
number = {7}
author = {Benjamin {Van Durme}},
title = {Jerboa: A Toolkit for Randomized and Streaming Algorithms},
institution = {Human Language Technology Center of Excellence, Johns Hopkins University},
year = {2012},
number = {7}
}
</pre>

which can be found at: http://cs.jhu.edu/~vandurme/papers/JerboaTR2012.pdf .

Requirements
------------

Jerboa requires the following:
* Java, 1.6 or greater
* Maven, 3.0.4 or greater

Installation
------------

mvn package - build a jar

mvn install - will install the plugin to your local repository.

Adding to your project
----------------------

<dependency>
<groupId>edu.jhu.jerboa</groupId>
<artifactId>jerboa</artifactId>
<version>1.0.0</version>
</dependency>

README : this file
LICENSE : 2-clause BSD license
Makefile : a simple Makefile to build the .jar file
proj/ : projects with associated property files and shell scripts
src/ : maven source directory
scripts/ : utility scripts
At this time, we do not have this hosted on a public maven server.

29 changes: 27 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>edu.jhu.jerboa</groupId>
Expand Down Expand Up @@ -33,15 +33,40 @@
</configuration>
<version>3.0</version>
</plugin>
<plugin>
<artifactId>maven-assembly-plugin</artifactId>
<version>2.4</version>
<configuration>
<descriptorRefs>
<descriptorRef>jar-with-dependencies</descriptorRef>
</descriptorRefs>
</configuration>
<executions>
<execution>
<id>make-assembly</id> <!-- this is used for inheritance merges -->
<phase>package</phase> <!-- bind to the packaging phase -->
<goals>
<goal>single</goal>
</goals>
</execution>
</executions>
</plugin>

</plugins>
</build>

<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.8</version>
<version>4.11</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
<version>1.0.13</version>
</dependency>

</dependencies>
</project>
6 changes: 3 additions & 3 deletions scripts/compile-run.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/sh
cd ../java
ant jar
java -DJerboa.resourceType=jar -DJerboaProperties.filename=config/analytics.properties -cp .:dist/*:opt/*:config/ edu.jhu.jerboa.classification.InteractiveAnalytic
cd ..
mvn clean package
java -DJerboa.resourceType=jar -DJerboaProperties.filename=analytics.properties -cp .:target/*:proj/analytic/models/* edu.jhu.jerboa.classification.InteractiveAnalytic
8 changes: 6 additions & 2 deletions scripts/run.sh
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
#!/bin/sh
cd ../java
java -DJerboa.resourceType=jar -DJerboaProperties.filename=config/analytics.properties -cp .:dist/*:opt/*:config/ edu.jhu.jerboa.classification.InteractiveAnalytic
cd ..
java \
-DJerboa.resourceType=jar \
-cp .:target/*:$1 \
edu.jhu.jerboa.classification.InteractiveAnalytic $2 true

46 changes: 46 additions & 0 deletions src/main/java/edu/jhu/jerboa/JerboaConfigurationException.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
/**
*
*/
package edu.jhu.jerboa;

/**
* @author max
*
*/
public class JerboaConfigurationException extends Exception {

/**
*
*/
private static final long serialVersionUID = 2447020139651157497L;

/**
*
*/
public JerboaConfigurationException() {
super("There was an issue with the Jerboa configuration.");
}

/**
* @param errorMessage
*/
public JerboaConfigurationException(String errorMessage) {
super(errorMessage);
}

/**
* @param cause
*/
public JerboaConfigurationException(Throwable cause) {
super(cause);
}

/**
* @param message
* @param cause
*/
public JerboaConfigurationException(String message, Throwable cause) {
super(message, cause);
}

}
46 changes: 46 additions & 0 deletions src/main/java/edu/jhu/jerboa/MissingPropertyException.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
/**
*
*/
package edu.jhu.jerboa;

/**
* @author thomamj1
*
*/
public class MissingPropertyException extends Exception {

/**
*
*/
private static final long serialVersionUID = 3968420245010349740L;

/**
*
*/
public MissingPropertyException() {
super("One or more referenced properties were not found in the JerboaProperties.filename file.");
}

/**
* @param missingProperty
*/
public MissingPropertyException(String missingProperty) {
super("The specified property does not exist: " + missingProperty);
}

/**
* @param cause
*/
public MissingPropertyException(Throwable cause) {
super(cause);
}

/**
* @param message
* @param cause
*/
public MissingPropertyException(String message, Throwable cause) {
super(message, cause);
}

}
Loading