Code Monkey home page Code Monkey logo

densenet_1d's Introduction

densenet_1d

This repository contains a Keras implementation of the DenseNet paper (Huang et al, "Densely Connected Convolutional Networks", CVPR 2017). This implementation will focus on use-cases where the inputs are 1D sequences.

Setup

To install densenet, simply clone this repository, and run

python setup.py install

Usage

The classifiers directory contains classifiers implemented as subclasses of keras.models.Model classes. This means that once a densenet.classifier is instantiated, it contains all of the usual methods of keras.models.Model, such as fit, predict, evaluate, summary, etc.

Here is an instantiation of the model that matches the original Huang et al. paper, except using a one-dimensional input rather than a two-dimensional input:

from densenet.classifiers.one_d import DenseNet121
model = DenseNet121(input_shape=(224, 13))
print(model.summary())

Upon running those lines, you should see an extensive summary indicating the layers in the model.

Note that the DenseNet implementations are highly customizable. For example, say you want to replace the default width-3 convolutions with width-5 ones. Simply instantiate your model as

from densenet.classifiers.one_d import DenseNet121
model = DenseNet121(input_shape=(224, 13), conv_kernel_width=5)
print(model.summary())

References

densenet_1d's People

Contributors

ankitvgupta avatar kotoroshinoto avatar

Watchers

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