GitXplorerGitXplorer
m

deepsort

public
6 stars
2 forks
0 issues

Commits

List of commits on branch master.
Verified
c76cbb7e4aa5b3c28f7600110be59483023491d9

Update README.md

mmayank26saxena committed 7 years ago
Verified
e84461c0bf5e0f0babeeb3ec1c4749f94a5f8d71

Added details and images

mmayank26saxena committed 7 years ago
Unverified
f3f3d989864d80e96cdad6e74527566601de0914

renamed images

mmayank26saxena committed 7 years ago
Unverified
c24d60de932e8faca1effcd29a2c8f74b00c20ba

added images

mmayank26saxena committed 7 years ago
Verified
93150f467c31eaf5f556fdf3a98cd7514e121029

Update README.md

mmayank26saxena committed 7 years ago
Unverified
c651ea1b1bc1fb9418474c6338551dbee13de624

achieved 99.5% accuracy

mmayank26saxena committed 7 years ago

README

The README file for this repository.

Deepsort

A recurrent neural network based sorting algorithm.

How it works?

RNNs can compute any arbitrary function, given finite resources since they are "Turing Complete" machines. I have used a sequence to sequence (seq2seq) based neural network model. I have chosen this model since, both the input and output are sequences. Input being unsorted sequence of integers and the output being the sorted sequence of integers.

I achieved 99.5% accuracy after 50,000 epochs.

Results

For the purpose of evaluating the performance (in terms of correct predictions) of this algorithm, I have considered that the input sequence will be of length = 15 and that the maximum number in this sequence will be <= 100. The success rate is evaluated as (number of correct predictions)/(number of trials).

Number of Trials Success Rate
100 97%
1000 96%
10000 95%

Screenshots

Below is an example of sorting using deepsort - alt text

To Do

  • [ ] Try with different sequence lengths and max number.
  • [ ] Add plots.
  • [ ] Compare average running time with other sorting algorithms.

Contributions

All patches are welcome!

License

MIT License - see the LICENSE file for details.

Credits

  1. https://github.com/keras-team/keras/blob/master/examples/addition_rnn.py
  2. http://shashank-gupta.com/2016/07/22/learning-to-sort-using-seq2seq/