News for hackers. Stuff that matters.
Re:Typefont – An algorithm to recognize the font of a text i... by Bluestrike2 on Sunday April 30, 2017 @11:52AM (#14232094)
It's a neat implementation for a very annoying (and common) scenario. I've used various font ID tools in the past and always found them rather limited. The vast majority are manual ones that ask you to identify particular characteristics of the font in question and then go from there. While that might be helpful, it's also pretty limited. Most of the time, I wound up posting an image to a typography forum to get an ID.

A few sites like My Fonts have an API that lets you generate font samples.[0] You could probably use that to automate generating your font database. Throw in a few other APIs (Google Fonts[1], Typekit[2], etc.) and some other type stores--along with some of the foundry websites that don't sell their fonts on other sites (Hoefler & Co., cough)--and you could build up a very rigorous database/recognition tool in short order.

0. https://dev.myfonts.com/#font_sample

1. https://developers.google.com/fonts/docs/developer_api

2. https://www.adobe.io/apis/creativecloud/typekit/docs/overvie...

Re:Typefont – An algorithm to recognize the font of a text i... by mrspeaker on Sunday April 30, 2017 @10:32AM (#14231666)
My Fonts had a tool for doing this back in (at least) 2009... I remember because I tried to run the burning "NERDS" sign from "Revenge of the nerds" through it. Didn't work very well though: I had to resort to human intervention. http://www.mrspeaker.net/2009/01/21/revenge-of-the-font-nerd...

Keen for an online version of this project so I can see if it fares any better!

Re:Typefont – An algorithm to recognize the font of a text i... by rendernos on Sunday April 30, 2017 @02:09PM (#14232955)
I changed the description of the repository and removed the AI tag, thank you and don't be evil!
Re:Typefont – An algorithm to recognize the font of a text i... by nom on Sunday April 30, 2017 @12:38PM (#14232355)
Please stop using "AI" to describe simple algorithms like this. This has nothing to do with the field of artificial intelligence. The code just extracts individual characters from the image and compares them visually to a prepared database of known fonts, using the hamming distance. You wouldn't call OCR an "AI algorithm", would you?

Edit: "nothing to do" is not accurate, but AI is definitely not an appropriate term to use here

Re:Typefont – An algorithm to recognize the font of a text i... by keppanaviimen on Sunday April 30, 2017 @12:45PM (#14232399)
"The code just extracts" please. Do you think extracting letters from a image is a joke? There is a engine in development since 1985 for doing that. http://www.kloover.com/publications/Kluever_-_OCR_using_ANN....
Re:Typefont – An algorithm to recognize the font of a text i... by nom on Sunday April 30, 2017 @01:11PM (#14232584)
Yes, I know it's a hard problem. Tesseract (the OCR library that is used in this project) is in development since 1985, but even google doesn't dare to call it an AI algorithm. OCR is of course a part that is required to build an artificial intelligence, but the term "AI" is just to overused nowadays and calling every single algorithm capable of recognizing something in some data is poison to the field itself. Solving AI is a huuge and daring problem and we should use the term appropriately.
Re:Typefont – An algorithm to recognize the font of a text i... by hk__2 on Sunday April 30, 2017 @01:12PM (#14232586)
It’s not a joke, but it’s not AI either.
Re:Typefont – An algorithm to recognize the font of a text i... by GordonS on Sunday April 30, 2017 @12:51PM (#14232456)
> You wouldn't call OCR an "AI algorithm", would you?

It depends on how it was implemented; if it used a neural network for example, then yes, I would

Re:Typefont – An algorithm to recognize the font of a text i... by rsrsrs86 on Sunday April 30, 2017 @06:14PM (#14234153)
This is a canonical AI problem. This is a task usually performed by human beings that was found to be excellently performed by computers. It falls within the grand field of computer vision. It is a solved and trivial problem nowadays, but is sure is AI.
Re:Typefont – An algorithm to recognize the font of a text i... by stevehiehn on Sunday April 30, 2017 @11:09AM (#14231882)
This problem is nice because unlike other datasets i think you could automate the creation of the data. I'm thinking you could generate a couple million photos with text captions all with known fonts.
Re:Typefont – An algorithm to recognize the font of a text i... by aamederen on Sunday April 30, 2017 @12:23PM (#14232275)
Can this technique be used for recognizing handwriting of individuals?
Re:Typefont – An algorithm to recognize the font of a text i... by rsrsrs86 on Sunday April 30, 2017 @06:15PM (#14234159)
Yes. You wouldn't need to worry about breaking it down to individual letters, though. Not necessarily. You would need pages and pages of writing from the individuals.
Re:Typefont – An algorithm to recognize the font of a text i... by Sujan on Sunday April 30, 2017 @10:10AM (#14231571)
Nice project, but:

> An artificial intelligence [...]

Really?

Re:Typefont – An algorithm to recognize the font of a text i... by rendernos on Sunday April 30, 2017 @10:26AM (#14231646)
The term "artificial intelligence" is applied when a machine mimics "cognitive" functions that humans associate with other human minds. Understanding the shape in a image, reading the text from a photo can also be considered AI.
Re:Typefont – An algorithm to recognize the font of a text i... by nom on Sunday April 30, 2017 @12:39PM (#14232363)
Extracting characters from an image and comparing them to a database of known fonts using a naive distance metric can be called AI? Really?
Re:Typefont – An algorithm to recognize the font of a text i... by surajx on Sunday April 30, 2017 @02:47PM (#14233174)
The key term here is mimics - to be classified as intelligent, the an algorithm should be able to significantly mimic human level intelligence in your domain. For example if your algorithm could read human handwriting and predict what font it was written in, or maybe what font it's closely related to, is something that's closer to the AI bandwagon.
Re:Typefont – An algorithm to recognize the font of a text i... by jacquesm on Sunday April 30, 2017 @11:35AM (#14232015)
But that doesn't make it 'an AI'. That's a subtle difference but it matters.
Re:Typefont – An algorithm to recognize the font of a text i... by amelius on Sunday April 30, 2017 @10:13AM (#14231587)
Re:Typefont – An algorithm to recognize the font of a text i... by retox on Sunday April 30, 2017 @12:55PM (#14232478)
What The Font has been good to me in this past.
Re:Typefont – An algorithm to recognize the font of a text i... by tyingq on Sunday April 30, 2017 @11:21AM (#14231949)
https://www.whatfontis.com/ as well, though it presents an irritating survey you have to decline to see the results.
Re:Typefont – An algorithm to recognize the font of a text i... by chc on Sunday April 30, 2017 @11:47AM (#14232071)
This certainly sounds like an AI application. Do you have some reason to think it isn't?
Re:Typefont – An algorithm to recognize the font of a text i... by hk__2 on Sunday April 30, 2017 @01:11PM (#14232580)
It uses OCR then compares what it find with everything in the database. It doesn’t “learn” anything from what it finds; in fact you can’t even train it because it uses a static database.
Re:Typefont – An algorithm to recognize the font of a text i... by nom on Sunday April 30, 2017 @03:31PM (#14233388)
Yes, it is a necessary part of an AI, but I still wouldn't dare to call it an "AI Algorithm". Overuse of the term poisons the actual AI research field, it's only use is to aid click bait.
Re:Typefont – An algorithm to recognize the font of a text i... by rsrsrs86 on Sunday April 30, 2017 @06:16PM (#14234167)
It is AI, it is just that not everything called AI is really interesting anymore. This should have attracted interest in the 80's.
Re:Typefont – An algorithm to recognize the font of a text i... by mrcactu5 on Sunday April 30, 2017 @02:17PM (#14233011)
this is amazing ... how is this even possible?