Hi Ken.
I finally managed to compile Julian. I did it on my friend`s computer, I suppose there were some issues with Cygwin on my PC. The new compiled Julian is few bytes larger than the precompiled binary available at the Julian site. Strange.
There is another problem. I`m writing a Java application that displays in a window the full stream that Julian writes on windows console (cmd) . The problem is that when I used precompiled binary of Julian ( downloaded from Julius/Julian site) it worked but with display issues ( no "please speek" sentence displayed at the java window). I figured out that it needs some more fflush instructions in the source code to make it work smoothly and display full stream from the console. That`s why i wanted to compile Julian from source.
I did this before with HVite from HTK and it run flawless under Java application.
Now my new compiled Julian ( without the fflush instructions, original code) does not work when I switch it with precompiled binary of Julian I had before. It simply does not display anything :(
Whereas when I run this new compiled Julian from windows cmd it works fine. What may be the cause of it? Could it be the POSIX? I tried to turn off the POSIX but was unsuccesful in that.
I would be grateful for any hints or suggestions, what may be wrong.
Thanks again for help Ken.
Regards
Marcin
--- (Edited on 12/11/2007 5:41 pm [GMT-0600] by Visitor) ---
Hi Marcin,
>The problem is that when I used precompiled binary of Julian ( downloaded
>from Julius/Julian site) it worked but with display issues ( no "please speek"
>sentence displayed at the java window)
I think the problem is that Julian uses both STDOUT and STDERR for its output. Try executing the precompiled Julian binary from your Java program using something like this:
julian -input mic -C julian.jconf 2>&1
The "2>&1" notation tells your system to direct your STDERR to STDOUT.
>Now my new compiled Julian ( without the fflush instructions, original code)
>does not work when I switch it with precompiled binary of Julian I had
>before. It simply does not display anything :(
Try executing this perl program on both your precompiled Julian and your new compiled Julian:
#!/usr/bin/perl -w
#open pipe to Julian
open(FILEHANDLE,"julian -input mic -C julian.jconf 2>&1 | ");
while (<FILEHANDLE>) {
print "test" . $_;
}
close FILEHANDLE;what does it display (if anything...?). If everything is working OK, you should have the word "test" appended at the beginning of all your Julian output.
>Whereas when I run this new compiled Julian from windows cmd it works
>fine. What may be the cause of it? Could it be the POSIX? I tried to turn off
>the POSIX but was unsuccesful in that.
I don't know enough about the POSIX standard to say one way or another ... If your Java program can capture output from a program's STDOUT filehandle it should work (if your new Julian works OK from the command line).
Another option might be to use Julian in server mode - rather than trying to get Julian output from the command line. adintool is the audio client that sends the audio to the Julian server, and you use jcontrol to send commands and obtain results from the Julian server. Therefore you would need your Java program to replicate what jcontrol does (or monitor jcontrol output) rather than trying to monitor Julian directly.
Hope this helps,
Ken
--- (Edited on 12/11/2007 10:21 pm [GMT-0500] by kmaclean) ---
Ken I tried the command 2>&1 while running Julian (original unaltered binary) from my Java application. It does not display anything, just like the Julian freezes. Maybe it needs some fflush instructions?
Another interesting fact is that when i run Julian via my Java application ( again original Julian binary) it performs recognition only 31 times and not one more time! This is very strange! Under windows CMD the same Julian binary works all the time. What may be the cause of those exact 31 recognitions? How to overcome this snag?
Thanks again for any help.
Regards
Marcin
--- (Edited on 1/22/2008 4:51 pm [GMT-0600] by Visitor) ---
>Ken I tried the command 2>&1 while running Julian (original unaltered binary)
>from my Java application. It does not display anything, just like the Julian
>freezes. Maybe it needs some fflush instructions?
Does short Perl program I wrote work for you? If it does, I would guess that the problem lies somewhere in your Java program.
Ken--- (Edited on 1/22/2008 6:30 pm [GMT-0500] by kmaclean) ---
Hello Ken.
It took me a while to figure what was the problem. You were right it was Java process buffer. It was too small. Julian now recognizes indefinitely under my application.
Thank you again for all your help. I really appreciate it.
I also have one quick question about *.dfa file (a converted HTK`s lattice to Julian format) Here is a structure of my .dfa when I view it in notepad:
0 0 8 0 0
2 1 1 0 0
3 2 2 0 0
4 3 2 0 0
5 4 2 0 0
6 5 2 0 0
7 6 2 0 0
8 7 3 0 0
8 8 5 0 0
8 9 7 0 0
8 10 6 0 0
8 11 4 0 0
1 -1 -1 1 0
My question is: what to those digits mean? When I view HTK lattice it is understandable but I would like to know how to understand the Julian converted version of lattice.
Thanks for all your help.
Best regards
Marcin
--- (Edited on 2/27/2008 2:28 pm [GMT-0600] by Visitor) ---
Hi Marcin,
Sorry, I never really got into the details of a dfa file's structure. You might take a look at the source for mkdfa.pl and figure it out from there.
Ken
--- (Edited on 2/29/2008 12:32 pm [GMT-0500] by kmaclean) ---