graphite-dl4j

Perform machine algorithms on graphite query results

License

License

Categories

Categories

Ant Build Tools Net Deeplearning4j Business Logic Libraries Machine Learning
GroupId

GroupId

net.savantly.learning
ArtifactId

ArtifactId

graphite-dl4j
Last Version

Last Version

1.0.0-RELEASE
Release Date

Release Date

Type

Type

jar
Description

Description

graphite-dl4j
Perform machine algorithms on graphite query results
Project URL

Project URL

https://github.com/savantly-net/graphite-dl4j
Project Organization

Project Organization

savantly.net
Source Code Management

Source Code Management

https://github.com/savantly-net/graphite-dl4j

Download graphite-dl4j

How to add to project

<!-- https://jarcasting.com/artifacts/net.savantly.learning/graphite-dl4j/ -->
<dependency>
    <groupId>net.savantly.learning</groupId>
    <artifactId>graphite-dl4j</artifactId>
    <version>1.0.0-RELEASE</version>
</dependency>
// https://jarcasting.com/artifacts/net.savantly.learning/graphite-dl4j/
implementation 'net.savantly.learning:graphite-dl4j:1.0.0-RELEASE'
// https://jarcasting.com/artifacts/net.savantly.learning/graphite-dl4j/
implementation ("net.savantly.learning:graphite-dl4j:1.0.0-RELEASE")
'net.savantly.learning:graphite-dl4j:jar:1.0.0-RELEASE'
<dependency org="net.savantly.learning" name="graphite-dl4j" rev="1.0.0-RELEASE">
  <artifact name="graphite-dl4j" type="jar" />
</dependency>
@Grapes(
@Grab(group='net.savantly.learning', module='graphite-dl4j', version='1.0.0-RELEASE')
)
libraryDependencies += "net.savantly.learning" % "graphite-dl4j" % "1.0.0-RELEASE"
[net.savantly.learning/graphite-dl4j "1.0.0-RELEASE"]

Dependencies

compile (5)

Group / Artifact Type Version
org.slf4j : slf4j-api jar 1.7.7
com.fasterxml.jackson.core : jackson-databind jar 2.9.4
org.datavec : datavec-data-codec jar 0.9.1
org.deeplearning4j : deeplearning4j-core jar 0.9.1
org.nd4j : nd4j-native-platform jar 0.9.1

test (4)

Group / Artifact Type Version
junit : junit jar 4.12
ch.qos.logback : logback-classic jar 1.1.8
org.springframework.boot : spring-boot-starter jar 1.5.10.RELEASE
org.springframework.boot : spring-boot-starter-test jar 1.5.10.RELEASE

Project Modules

There are no modules declared in this project.

graphite-dl4j

Java CI

Perform machine algorithms on graphite query results.

Also see -
graphite client

Usage

<dependency>
	<groupId>net.savantly.learning</groupId>
	<artifactId>graphite-dl4j</artifactId>
	<version>2.0.0-SNAPSHOT</version>
</dependency>

Quickstart

add graphite-dl4j as a dependency to your project.

This example uses a preconfigured multilayer network to train and predict -

private static final String graphiteHost = "127.0.0.1";
private static final int windowSize = 2;
private static final String target = "randomWalk()";
private static final String targetAlias = "random.walk";
private static final int epochs = 20;
private static final int hiddenLayerWidth = 30;
private static final double learningRate = 0.001;

public void testTraining() throws UnknownHostException, SocketException {
	QueryableGraphiteClient client = GraphiteClientFactory.queryableGraphiteClient(graphiteHost);
	PersistentGraphitePredictor learner = 
			PersistentGraphitePredictor.builder(client )
			.setWindowSize(windowSize)
			.setTrainingTarget(target)
			.setTestingTarget(target)
			.setTargetAlias(targetAlias)
			.setEpochs(epochs)
			.setHiddenLayerWidth(hiddenLayerWidth)
			.setLearningRate(learningRate)
			.setRnnLearningRate(learningRate)
			.setUseCache(false) // you can cache/store the model to re-use between app restarts
			.build();
	
	learner.train(); // train the network using the graphite targets
	learner.update(); // make a 2 min prediction and store it in graphite
}

Lower level configuration

	this.graphitePredictor = GraphitePredictor.builder()
			.setClient(client)
			.setEpochs(this.getEpochs())
			.setMiniBatchSize(1)
			.setLearningRate(this.getLearningRate())
			.setRnnLearningRate(this.getRnnLearningRate())
			.setNumOfInputs(windowSize+1)
			.setWindowSize(windowSize)
			.setHiddenLayerWidth(this.getHiddenLayerWidth());

Even lower...

	this.network = RegressionNetwork.builder()
			.setEpochs(epochs)
			.setLearningRate(learningRate)
			.setRnnLearningRate(rnnLearningRate)
			.setTrainingData(trainingData)
			.setNumOfInputs(numOfInputs)
			.setHiddenLayerWidth(hiddenLayerWidth)
			.setIterationListeners(iterationListeners);
net.savantly.learning

Savantly

Savantly custom software solutions for your business

Versions

Version
1.0.0-RELEASE