Average is beautiful

For details, please refer to the YouTube video. It is suitable for both script and live script.
1 Download
Aktualisiert 20. Mai 2023

Lizenz anzeigen

This script was inspired by the following Japanese paper.
The paper states that "taking the average of handwritten hiragana characters makes them more beautiful."
In the paper, they fold the stroke data to create closed curves and expand them to a degree where the difference from the original becomes sufficiently small.
Since it seemed easier to process using the Discrete Cosine Transform (DCT), I chose that method. (DCT is equivalent to taking the DFT of an even extension of the input and is a reversible transformation.)
You can click and drag to draw one stroke, and when you release the click, it will move on to the second stroke. Press any key (e.g., space key, arrow keys) to move to the second try.
Since the determination of each stroke's similarity is based on simple normalization and distance calculation, there may be some mistakes.
This script is not intended for practical use but rather for enjoyment and experimentation.

Zitieren als

Hiroshi Iwamura (2024). Average is beautiful (https://www.mathworks.com/matlabcentral/fileexchange/129864-average-is-beautiful), MATLAB Central File Exchange. Abgerufen.

Kompatibilität der MATLAB-Version
Erstellt mit R2023a
Kompatibel mit allen Versionen
Plattform-Kompatibilität
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Veröffentlicht Versionshinweise
1.0.1

Added a YouTube link to the Description.

1.0.0