Giter Club home page Giter Club logo

dl4j-spark-ml's Introduction

Spark Package - dl4j-spark-ml

THIS HAS BEEN ABANDONED. PLEASE USE OUR EXISTING SPARK IMPLEMENTATION IN THE NORMAL PROJECT: http://deeplearning4j.org/spark

Join the chat at https://gitter.im/deeplearning4j/dl4j-spark-ml

Introduction

Welcome to the dl4j-spark-ml project! dl4j-spark-ml is a Spark Package for the deeplearning4j library. The package is published to spark-packages.org (here).

The deeplearning4j library provides the following types of neural nets:

  • Restricted Boltzmann machines
  • Convolutional Nets (images)
  • Recurrent Nets/LSTMs (time series and sensor data)
  • Recursive autoencoders
  • Deep-belief networks
  • Deep Autoencoders (QA/data compression)
  • Recursive Neural Tensor Networks (scenes, parsing)
  • Stacked Denoising Autoencoders

The library provides the following Spark components:

  • DataFrame Readers
    • MNIST
    • Labeled Faces in the Wild (LFW)
    • IRIS
  • Pipeline Components
    • NeuralNetworkClassification
    • NeuralNetworkReconstruction

See the README file in deeplearning4j's repository for more details.

Goals

  • Interactive use of deeplearning4j in Spark Shell and Spark Notebook
  • Full integration with Spark ML pipeline
  • Interoperability with data sources and other pipeline components
> $SPARK_HOME/bin/spark-shell --packages deeplearning4j:dl4j-spark-ml:0.4-rc3.1

Example Code

See the example code in the dl4j-spark-ml-examples repository.

Publishing

This section describes how to to publish the Spark Package.

The project uses the sbt-spark-package plugin, which provides the 'spPublish' task.

Create credentials cache

Follow the instructions provided by the sbt-spark-package plugin. Your credentials file should be located at ~/.ivy2/.spcredentials, and resemble:

realm=Spark Packages Realm
host=spark-packages.org
user=(Github Username)
password=(Github Personal Access Token)

Update version info

Update the version information in build.sbt. Update dependencies as necessary.

Register

This task is performed once to register the package at spark-packages.org. It (probably) may be used to update the package description. Run the spRegister task.

Publish

Run the spPublish task.

$ sbt
[info] Loading project definition from /.../dl4j-spark-ml/project
[info] Set current project to dl4j-spark-ml (in build file:/.../dl4j-spark-ml/)
> spPublish

Developing

Background

A Spark Package is a Maven artifact published to a Maven repository like normal. The associated JAR file is not an uber-jar; Spark automatically downloads the dependencies as needed.

The Spark Packages website is a repository that compliments Maven Central with different publishing rules and procedures. The main difference is in how provenance is handled. Your artifact's coordinates must exactly match the code's corresponding github location.

Of course, your artifact's dependencies may originate from any repository known to spark-submit.

Working with Snapshots

It is not possible to publish a package that refers to unpublished artifacts. To make use of a dependency in your local repository (such as org.deeplearning4j:dl4j-spark-ml), update the build script to use the dependency, then publish the package to the local Maven repository.

Publish to Local Maven Repository

The build script is designed to support both the 'publishM2' and the 'spPublishLocal' tasks, to publish to the local-maven-cache and local-ivy-cache respectively. The spark-submit tool gladly looks to both repositories, but mishandles the ivy case due to SPARK-8095. Use local-maven-cache for now.

Clear the ivy cache

Keep in mind that the dl4j build script publishes only to local-maven-cache; the local-ivy-cache is not kept in sync. Delete ~/.ivy2/cache/org.deeplearning4j and similar as necessary.

Troubleshooting

Some relevant snippets:

More Information

Background information on Spark Packages:

dl4j-spark-ml's People

Contributors

eronwright avatar chrisvnicholson avatar gitter-badger avatar lewuathe avatar

Watchers

 avatar  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.