I want to convert words to its Arpabet translation.
Something like:
HELLO HH AH L OW
But I want to do it programatically in java, sphinx offers a web tool here http://www.speech.cs.cmu.edu/tools/lmtool.html. I know I can request this tool in Java using sockets and sniffing out the .dic file returned but I cannot use this because not all users of my app has an internet connection.
I also checked-out logios package of Sphinx but it is written in perl and batch files. I can use it but I want to make my app platform-independent and I think it is a bit overboard if I include perl shell in my project.
If there's any java library or algorithm that I can reuse so I can just do something like ConvertToSphinxArpabet("HELLO") and I get the "HH AH L OW" string returned.
Please check the tutorial:
http://cmusphinx.sourceforge.net/wiki/tutorialdict
For example you can use g2p code from FreeTTS written in Java:
http://cmusphinx.sourceforge.net/projects/freetts
OpenMary Java TTS:
http://mary.dfki.de/
For FreeTTS example see our code in the long audio aligner branch:
http://cmusphinx.svn.sourceforge.net/viewvc/cmusphinx/branches/long-audio-aligner/Aligner/src/edu/cmu/sphinx/linguist/dictionary/AllWordDictionary.java?revision=11092&view=markup
Related
I came across https://translate.google.com/ which translates given text to the desired language.
I have nearly 2,000 files, each file 300 KB.
Currently I need to open each file, paste the text and translate it by above web-site then save it.
Is there a way to automate for the 2,000 files by reading and sending portions of files and finally append to the files? Repeat same for all files.
Doubts:
Will the IP address be blocked?
Is it illegal to use selenium for this purpose?
Is there a legal automated way to translate using the above free service?
If nothing is possible, I need to do it manually.
please advise.
thanks.
1- I think not
2- No, its no illegal
3- Yes, you can use the google translate api:
https://translate.googleapis.com/translate_a/
single?
client=gtx
&sl=<SOURCE LANGUAGE, can be auto>
&tl=<TARGUET LANGUAGE, cannot be auto>
&dt=t
&q=<TEXT>
References: https://cloud.google.com/translate/
I recommend you to check the Google API Cloud Translation:
https://cloud.google.com/translate/docs/
and the REST API reference:
https://cloud.google.com/translate/docs/reference/rest/
I need to create an app (using Android Studio) that generates CNC code to operate a 3D printer. It takes a String as input.
I've found a couple libraries in Python and Javascript that does this, but as I don't have time to translate whole libraries to Java, can you recommend any libraries that does that for me? If there are no open-source options, can you recommend any guide to help me develop this conversor?
What we ended up doing:
App asks for a String as input;
String is converted to a bitmap and then saved as a .png;
.png is loaded and converted to a .svg file. We used this repo: https://github.com/jankovicsandras/imagetracerandroid
We developed a parser to convert a .svg to g-code.
It worked but it's not the best solution, we're looking to implement something that runs python in Android, as there are many pythons that do all the work already, but that's how we've done it and it's working by now.
I'm new to Java and UIMA, and I can't find a comprehensive sample to use the AggregatePlaintextUMLSProcessor from code and print results in a proper format.
I managed to run cTakes from command line and I see it's using FileWriterCasConsumer.xml to write the output, but I want to know what other formats can I get.
I'va got the code for apache-ctakes-3.2.2 and it's building on a windows 10 machine.
Stock cTakes supports writing data to:
XMI,
CSV,
Plain text and
HTML files.
You could take a look at sub packages org.apache.ctakes.core.cc.* in the ctakes-core module.
Hope you all be fine and doing great.
I am currently working on a Java Web Application. I am getting Streaming video using RTSP URL. This URL is like:
rtsp://---.---.---./6ca714ae28e52f31
I have been able to capture video, diplay/listen it and store it in .mp4 file using FFMPEG with the following command:
fmpeg -i rtsp://username:password#---.---.---.---/6ca714ae28e52f31 -f mov e:/bay.mov (with authentication)
Now, I want to achieve the same in my Java application using ffmped library. I am sure if all this possible through commands then It will also be possible using its library. But unfortunately couldn't get any working useful material regarding this on web.
So, I simply want to ask that:
1. How can I fetch Streams using this RTSP URL in my Java Application with FFMPEG library
2. How can I Manipulate this fetched streaming such as start, stop, end etc.
3. How can I store this streaming in media file in playable form in any specified format.
I have found a FFMPEG's Java Rapper JJMPEG. Now I have two options either to issue FFMPEG command to CMD using Java Application or use JJMPEG library directly. Don't know which one will be better choice.
Thanks for your time and considerations.
I am looking around for an API in java or c++ to read the MRZ and decode the MRZ code in travel documents(passports).
More information on MRZ is at http://www.highprogrammer.com/alan/numbers/mrp.html. Has any one done this before with an API?
Please see the mrz-java Google code project. It is quite new though - it only supports four MRZ formats for now.
Sorry I can't help directly, but one company I know of that provides this service is using OCR to extract the text and MRZ code and then presumably they have access to the algorithm for computing the MRZ.
I'm guessing though that if you're asking about an API then you may already have access to the characters and just need the algorithm to check that the text computes to ma the MRZ?
It's not clear if you are simply looking for a parser or you need a solution to capture the MRZ from image or images as well as parse it.
Assuming you want to capture the MRZ as well as parse it, there isn't a lot available that is free. If you want to roll up your sleeves and do a lot of the coding yourself there is freeware available but it will take some doing to get it going correctly.
Google Tesseract is available for Android, IOS, and Windows. Its a general purpose OCR engine. You can find it on:
https://github.com/tesseract-ocr
If you want an SDK that is specifically designed to process MRZ, you have a few options. One such option is Xavier by SimonComputing Inc. This SDK works on Android and IOS. It provides a Widget to capture the MRZ through your smart phone's camera, then provides an OCR engine and parsing library to break down the MRZ into fields that you can use in your application.
Free demo application downloads:
On Apple Store - https://itunes.apple.com/us/app/xavier-mrz/id1057308745?mt=8
On Google Play – https://play.google.com/store/apps/details?id=xavier.simoncomputing.com.xavierlibrary
Free Evaluation SDKs on Github:
For IOS – https://github.com/simoncomputing/Public-Xavier-iOS-Eval-SDK
For Github - https://github.com/simoncomputing/Public-Xavier-Android-Eval-SDK