Neural networks powered research of semigroups
Project description
Neural Semigroups
Here we try to model Cayley tables of semigroups using neural networks.
This work was inspired by a sudoku solver. A solved Sudoku puzzle is nothing more than a Cayley table of a quasigroup from 9 items with some well-known additional properties. So, one can imagine a puzzle made from a Cayley table of any other magma, e.g. a semigroup, by hiding part of its cells.
There are two major differences between sudoku and puzzles based on semigroups:
-
it's easy to take a glance on a table to understand whether it is a sudoku or not. That's why it was possible to encode numbers in a table cells as colour intensities. Sudoku is a picture, and a semigroup is not. It's difficult to check a Cayley table's associativity with a naked eye;
-
Sudoku puzzles are solved by humans for fun and thus catalogued. When solving a sudoku one knows for sure that there is a unique solution. On the contrary, nobody guesses values in a partially filled Cayley table of a semigroup as a form of amusement. As a result, one can create a puzzle from a full Cayley table of a semigroup but there may be many distinct solutions.
How to Install
The best way to install this package is to use pip
:
pip install neural-semigroups
How to use
The simplest way to get started is to use Google Colaboratory.
To look at more experimental results for different semigroups cardinalities, you can use Kaggle:
There is also an experimental notebook contributed by Žarko Bulić.
How to Contribute
Pull requests are welcome. To start:
git clone https://github.com/inpefess/neural-semigroups
cd neural-semigroups
# activate python virtual environment with Python 3.6+
pip install -U pip
pip install -U setuptools wheel poetry
poetry install
# recommended but not necessary
pre-commit install
To check the code quality before creating a pull request, one might run the script show_report.sh. It locally does nearly the same as the CI pipeline after the PR is created.
Reporting issues or problems with the software
Questions and bug reports are welcome on the tracker.
More documentation
More documentation can be found here.
The paper
There is also a paper with more maths inside. It can be used to cite the package.
To reproduce results from the paper, use this notebook
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for neural_semigroups-0.6.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6632abb31fb0eaa3f41684b15c01a7e03da09b2fbb1978d6841779d81edcd8a4 |
|
MD5 | 76908e053684f5f7fa1f437016099380 |
|
BLAKE2b-256 | 54ed8aee230ddc64bae9a701c6d67279e92f085ec1cc9f7169603074f81f5164 |