{"id":19530841,"url":"https://github.com/alexeyev/glyphnet-pytorch","last_synced_at":"2025-04-26T13:31:03.765Z","repository":{"id":74082004,"uuid":"431622962","full_name":"alexeyev/glyphnet-pytorch","owner":"alexeyev","description":"Сracking Egyptologist's MNIST: PyTorch implementation of the Glyphnet model introduced in \"A Deep Learning Approach to Ancient Egyptian Hieroglyphs Classification\", Barucci et al., 2021.","archived":false,"fork":false,"pushed_at":"2022-09-06T06:57:25.000Z","size":64,"stargazers_count":14,"open_issues_count":0,"forks_count":4,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-04-12T03:07:53.044Z","etag":null,"topics":["computer-vision","deep-learning","egyptian-hieroglyphics","egyptology","hieroglyph-recognition","hieroglyphics","inception"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/alexeyev.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":"CITATION.cff","codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2021-11-24T20:43:23.000Z","updated_at":"2025-02-22T18:24:58.000Z","dependencies_parsed_at":null,"dependency_job_id":"f4b6b78e-654a-4461-92c3-8637b0773f64","html_url":"https://github.com/alexeyev/glyphnet-pytorch","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexeyev%2Fglyphnet-pytorch","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexeyev%2Fglyphnet-pytorch/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexeyev%2Fglyphnet-pytorch/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alexeyev%2Fglyphnet-pytorch/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alexeyev","download_url":"https://codeload.github.com/alexeyev/glyphnet-pytorch/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250993133,"owners_count":21519618,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["computer-vision","deep-learning","egyptian-hieroglyphics","egyptology","hieroglyph-recognition","hieroglyphics","inception"],"created_at":"2024-11-11T01:36:36.861Z","updated_at":"2025-04-26T13:31:03.758Z","avatar_url":"https://github.com/alexeyev.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# glyphnet-pytorch\n\n![Python 3x](https://img.shields.io/badge/python-3.x-blue.svg)\n\nThis repository presents a custom (non-official) PyTorch-based implementation of the **Glyphnet** \nclassifier introduced in the work [A Deep Learning Approach \nto Ancient Egyptian Hieroglyphs \nClassification, 2021](https://ieeexplore.ieee.org/stamp/stamp.jsp?arnumber=9528382) \nand applies it to the data accompanying the work [\"Automatic Egyptian \nHieroglyph Recognition by Retrieving Images as Texts\", 2013](https://jvgemert.github.io/pub/FrankenACMMM13egyptian.pdf) \n(NB! Glyphnet paper uses a larger dataset).\n\n\n![what](/sample_images/230128_G17.png) | ![a](/sample_images/230067_G26.png) | ![pretty](/sample_images/230034_G25.png) | ![bird](/sample_images/230092_G4.png) | ![you](/sample_images/230084_G5.png) | ![are](/sample_images/230178_G43.png) \n------------ | ------------- | ------------- | ------------- | ------------- | -------------\nG17 | G26 | G25 | G4 | G5 | G43\n\n\nWe hope that this implementation of the model will encourage\nthe further research in this direction.\n\n\n**UPDATE** April 2022: [the original AUTHORS' CODE](https://github.com/GAIA-IFAC-CNR/Glyphnet) is now available.\n\n\n## Requirements\n\nPlease see `requirements.txt`.\n\n## Quickstart\n\n**TL;DR: run `prepare_data.sh`, then `main.py`.**\n\n### Setting everything up\n\nAn entry point is the script `prepare_data.sh` that downloads the dataset and splits it into train/test \nparts in a 'stratified' manner, i.e. keeping all labels with just a single image in the training set, \nyet preserving similar label counts distributions in each part of the dataset. \n\nIt should print\n\n    DEBUG:root:Labels total: 172\n    DEBUG:root:Labels seen just once: 37\n\nbefore shutting down.\n\n### Training\n\nTraining script `main.py` uses standard **hydra** configuration mechanism; the parameters one can modify\nat the CLI call can be found in `configs/...`.\n\n```bash\npython3 main.py model.epochs=10\n``` \n\n## How to cite\n\nIf you use the GlyphNet model, please cite the original work:\n\n```bibtex\n@article{barucci2021deep,\n  title={A Deep Learning Approach to Ancient Egyptian Hieroglyphs Classification},\n  author={Barucci, Andrea and Cucci, Costanza and Franci, Massimiliano and Loschiavo, Marco and Argenti, Fabrizio},\n  journal={IEEE Access},\n  volume={9},\n  pages={123438--123447},\n  year={2021},\n  publisher={IEEE}\n}\n```\n\nIf you use the dataset, please cite the original work:\n\n```bibtex\n@inproceedings{franken2013automatic,\n  title={Automatic Egyptian hieroglyph recognition by retrieving images as texts},\n  author={Franken, Morris and van Gemert, Jan C},\n  booktitle={Proceedings of the 21st ACM international conference on Multimedia},\n  pages={765--768},\n  year={2013}\n}\n```\n\nCiting this repository is also appreciated:\n\n```bibtex\n@misc{glyphnetpytorch2021alekseev,\n  title     = {{alexeyev/glyphnet-pytorch: GlyphNet, PyTorch implementation}},\n  author    = {Anton Alekseev}, \n  year      = {2021},\n  url       = {https://github.com/alexeyev/glyphnet-pytorch},\n  language  = {english}\n}\n```\n\n## TODO\n\n* Add a practical usage scenario using [data augmentation](https://albumentations.ai/)\n* Add an end-to-end image-to-prediction inference script using a pre-trained GlyphNet model \n\n## Notes\n\n* [morrisfranken/glyphreader](https://github.com/morrisfranken/glyphreader), \n  the source of the [Pyramid of Unas](https://en.wikipedia.org/wiki/Pyramid_of_Unas) data\n* Please do not confuse this work with another [GlyphNet project](https://github.com/noahtren/GlyphNet) \n  training networks to communicate using a visual language\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexeyev%2Fglyphnet-pytorch","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falexeyev%2Fglyphnet-pytorch","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falexeyev%2Fglyphnet-pytorch/lists"}