Giter VIP home page Giter VIP logo

stmlearn's Introduction

STMLearn

STMLearn is a python library which implements several active state machine learning algorithms. This library is currently under active development, and things may change at any time. If you want to use this for anything important right now you would probably be better off with LearnLib :)

Learning algorithms:

at the moment L* and TTT are supported for DFAs and Mealy machines.

Algorithm DFA Mealy machine
L* ✔️
TTT ✔️

Equivalence checking methods:

The following equivalence checking methods are available, or will be soon:

  • W-method
  • Smart W-method (early stopping etc.)
  • Random walk
  • Brute force

Simple example:

# Set up a SUL using regex
sm = RegexMachine('(bb)*(aa)*(bb)*')

# We are using the brute force equivalence checker
eqc = BFEquivalenceChecker(sm, max_depth=15)

# Set up the teacher, with the system under learning and the equivalence checker
teacher = Teacher(sm, eqc)

# Set up the learner who only talks to the teacher
learner = LStarDFALearner(teacher)

# Get the learners hypothesis
hyp = learner.run()

# Draw the learned dfa
hyp.render_graph(tempfile.mktemp('.gv'))

For the SUL described by the regular expression (bb)*(aa)*(bb)* the following dfa is learned: simple dfa

stmlearn's People

Contributors

tcatshoek avatar

Watchers

 avatar  avatar

Forkers

bramverb

stmlearn's Issues

TTT Bugs

The current implementation of TTT has some bugs. It seems to work fine on some systems but randomly fails on others, will investigate asap.

TODO: remove dependency on minsepseq binary

A lot of things are broken right now when you install from pypi because a small binary we rely on to get the distinguishing set of a mealy machine does not get packaged correctly. We either need to make sure it can be built and packaged correctly, or remove it entirely.

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.