Giter Club home page Giter Club logo

lshm's Introduction

LSHM : LOFAR System Health Management

We use a cascaded autoencoder duo with k-harmonic clustering to learn features in LOFAR spectrograms. The autoencoders work in the real space and the Fourier space of the spectrograms. We combine Deep K-means and K Harmonic means to implement deep-K-Harmonic means clustering.

Files included are:

lofar_models.py : Methods to read LOFAR H5 data and Autoencoder models.

kharmonic_lofar.py : Train K-harmonic autoencoders (in real and Fourier space) as well as perform clustering in latent space.

evaluate_clustering.py : Load trained models and print clustering results for given dataset.

lbfgsnew.py : Improved LBFGS optimizer.

train_graph.py : Build a line-graph using baselines and train a classifier (Pytorch Geometric).

Architecture of the full system

The above image summarizes the three autoencoders that extract latent space representations and the training scheme with various constraints.

LBFGS vs Adam

How to train

Sometimes Adam will diverge (see figure above), and LBFGS will give a more stable result. Here is a training strategy that will generally work:

  • Set alpha=beta=gamma=0.001 (a low value), use Adam for training the autoencoders, a few epochs.
  • Increase alpha, beta, gamma (say to 0.01 and thereafter 0.1) and use LBFGS for the remainder of the training.
  • Always keep an eye for the k-harmonic loss exploding (as shown in the figure above). Control this by tuning alpha.
  • Important: divide the training into three: i) 2D CNN, ii) 1D CNN and iii) K Harmonic model, and iteratively update parameters of each of these models. This will give a stable result.

Example input/output

The above figure shows of an example of the autoencoders in action: top left: input x, bottom left: output xhat of the first autoencoder, top right: input y, bottom right: output yhat of the second autoencoder.

Below is one example, the first figure shows the t-SNE plot, and following that, the spectrograms for two closest cluster ids.

Example input/output

Example input/output

Example input/output

lshm's People

Contributors

klemenvon avatar sarodyatawatta avatar

Stargazers

 avatar

Watchers

 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.