Register Guidelines E-Books Search Today's Posts Mark Forums Read

Go Back   MobileRead Forums > E-Book Readers > Kobo Reader > Kobo Developer's Corner

Notices

Reply
 
Thread Tools Search this Thread
Old 02-15-2013, 02:30 AM   #196
gouni
Connoisseur
gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.
 
gouni's Avatar
 
Posts: 86
Karma: 546021
Join Date: Nov 2012
Device: kobo
@Alpe, I am sorry if I am slow to understand, I take my retirement to learn the use of the computer.


I have a mobi ( dictionarie )

I do not know to do mobi ==> stardict

If you know or find already on the internet a script

I know to do stardict ==> kobo ( I know not yet use penelope I do by hand )

to be able to mobi ==> stardict ==> kobo


My next step learn penelope, I will take the time it takes, I like to understand.

Last edited by gouni; 02-15-2013 at 05:32 AM.
gouni is offline   Reply With Quote
Old 02-15-2013, 07:18 AM   #197
AlPe
Digital Amanuensis
AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.
 
AlPe's Avatar
 
Posts: 727
Karma: 1446357
Join Date: Dec 2011
Location: Turin, Italy
Device: Several eReaders and tablets
No problem, I was just unable to parse your request.

About MOBI => Kobo. As I wrote in the previous message, right now there is no direct support in Penelope. You might want to unpack the MOBI with the mobiunpack script, but then you must somehow parse the resulting HTML files, and output from it a CSV/XML file, so that you can use Penelope from this CSV/XML to produce the Kobo dictionary.

The parsing part might be hard (I do not know how much skilled you are), so perhaps you might want to wait a couple of weeks for me to complete MOBI support in Penelope.

(Alternatively, if you find a Mobi => Stardict converter, you can output an intermediate Stardict dictionary and then use Penelope to convert the latter to Kobo.)
AlPe is offline   Reply With Quote
Advert
Old 02-15-2013, 07:36 AM   #198
gouni
Connoisseur
gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.
 
gouni's Avatar
 
Posts: 86
Karma: 546021
Join Date: Nov 2012
Device: kobo
@ Alpe

Thanks for all your time Alpe.

My level of qualification in computer science: I am 72 years old, I learned by reading and asking many questions. I'm in a computer club in my city for the elderly.

I am patient.

Alpe while you expand, I'll learn how to use Penelope and Python. Someone from the club will install me linux and I bought a book to use. If I do not know I have a person who shows me, as we had to show me to use the command line.

It's all magic to me, it's a wonderful world. And on the internet I learned and share a lot.

I'll also try to find a script for mobi to stardict. Research is sometimes more interesting than the discovery.

I took more pleasure to do my first dictionary kobo, in two months. What to do in fifteen minutes an automatic mobi dictionary.

gouni is offline   Reply With Quote
Old 02-15-2013, 12:31 PM   #199
AlPe
Digital Amanuensis
AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.
 
AlPe's Avatar
 
Posts: 727
Karma: 1446357
Join Date: Dec 2011
Location: Turin, Italy
Device: Several eReaders and tablets
Sure, no problem.

For the penelope usage, just invoke
Code:
$ python penelope.py
without arguments (the "$" is just a symbol of your shell prompt, it might be different on your PC) to get the help printed.
AlPe is offline   Reply With Quote
Old 02-15-2013, 01:15 PM   #200
gouni
Connoisseur
gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.gouni ought to be getting tired of karma fortunes by now.
 
gouni's Avatar
 
Posts: 86
Karma: 546021
Join Date: Nov 2012
Device: kobo
Thank's

I take my time to read the documentation.

the advantage I have, my first dictionary I made by hand with your help.

so I understand what is happening.

It will take me a while to take advantage of penelope, but I feel that I'm going to spend a great time.

gouni is offline   Reply With Quote
Advert
Old 02-17-2013, 05:53 PM   #201
mooncalf78
Junior Member
mooncalf78 began at the beginning.
 
Posts: 1
Karma: 10
Join Date: Feb 2013
Device: Kobo Glo
Hi guys,

I almost sold my Kobo Glo because it seemed that it is not possible to download custom dictionary. I bought eReader because I wanted to improve my English grammar skills. My idea was to have at least two dictionaries: 1) ENG to my mother tongue (Czech) and 2) some comprehensive English monolingual dictionary. However as I discovered Kobo's internal EN-EN is quite poor unfortunately and there is no EN-Czech dictionary. I was pretty desperate - until I found this thread.

The first thing I tried was to convert a Shorter Oxford English Dictionary (SOED) to my Kobo. I found it on the web in Startdict format. So I installed the first time in my life a Python compiler and used AlPe's Penelope script. It worked on the first attempt. However later I discovered following annoying issue:

The SOED contains multiple definition of the same word with added number in brackets. For example: "know(1)" and "know(2)". So when I look for "knows" the closest match was "knowe". I have to manually type "know(" to show "know(1)" and "know(2)" translation.

So I converted SOED to CSV format using Penelope and I created C# console app which stripped the brackets and numbers from entries (from the first string before '\t' char). After that I converted CSV back to Kobo dictionary. It seems to work now! However maybe there is easier way? It would be nice if Penelope support that (maybe already does, I just I overlooked that – let me know). The final SOED has 23 MB size.

After that I also successfully ported ENG-Czech dictionary (Lingea Lexicon 2002). It was a bit more difficult because I had to convert it from original encoded format (.trd) to StarDict format, but I found public decoder (lingea-trd-decoder.py).
So right now when I click on any word in Kobo, the ENG-Czech dictionary shows me Czech translation and when I want to learn more English I click on “A-Z” button and to "Translation dictionary" to show SOED translation. I had to overwrite FR-EN translation dictionary because for unknown reason it is set as default translation dictionary. I'm not sure why and if is it possible to change that.

So now I have everything I wanted – very good EN-Czech dictionary and one of the best monolingual English dictionaries. I’m not sure if full version of OED is necessary, but after one day reading I found every word I was looking for. Btw: Does anybody ported full OED to Kobo?

Anyway thanks everybody in this forum for your work, especially AlPe for his Penelope script
mooncalf78 is offline   Reply With Quote
Old 02-18-2013, 02:31 PM   #202
AlPe
Digital Amanuensis
AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.
 
AlPe's Avatar
 
Posts: 727
Karma: 1446357
Join Date: Dec 2011
Location: Turin, Italy
Device: Several eReaders and tablets
Yes, there is a (relatively) shorter way: define your custom parser in Python, and pass it to Penelope!

See "Custom parser for the input dictionary" at http://www.albertopettarin.it/penelope.html and the related example webster_parser.py .
AlPe is offline   Reply With Quote
Old 02-22-2013, 10:19 PM   #203
Frankr
Zealot
Frankr ought to be getting tired of karma fortunes by now.Frankr ought to be getting tired of karma fortunes by now.Frankr ought to be getting tired of karma fortunes by now.Frankr ought to be getting tired of karma fortunes by now.Frankr ought to be getting tired of karma fortunes by now.Frankr ought to be getting tired of karma fortunes by now.Frankr ought to be getting tired of karma fortunes by now.Frankr ought to be getting tired of karma fortunes by now.Frankr ought to be getting tired of karma fortunes by now.Frankr ought to be getting tired of karma fortunes by now.Frankr ought to be getting tired of karma fortunes by now.
 
Posts: 129
Karma: 1012044
Join Date: Jun 2009
Location: Connecticut (USA)
Device: EzReader, Sony 650, Kindle 5, Onyx i62HD, Kobo Aura HD
Hello, I'm missing something, I keep getting "ImportError" No module named dictEPUB" when running penelope.py Any help would be appreciated. I'm using python ver 2.7 and I'm attempting to convert a StarDict dictionary. Running on Windows 7

Last edited by Frankr; 02-22-2013 at 11:31 PM.
Frankr is offline   Reply With Quote
Old 02-23-2013, 04:15 AM   #204
AlPe
Digital Amanuensis
AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.
 
AlPe's Avatar
 
Posts: 727
Karma: 1446357
Join Date: Dec 2011
Location: Turin, Italy
Device: Several eReaders and tablets
Download "dictEPUB.py" from the Google Code page, and place it in the same directory where penelope.py is.
AlPe is offline   Reply With Quote
Old 03-10-2013, 07:54 AM   #205
Arrow245
Junior Member
Arrow245 began at the beginning.
 
Posts: 6
Karma: 10
Join Date: Mar 2013
Device: Kobo Touch
Alberto, you're great!
Arrow245 is offline   Reply With Quote
Old 03-10-2013, 08:50 AM   #206
AlPe
Digital Amanuensis
AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.
 
AlPe's Avatar
 
Posts: 727
Karma: 1446357
Join Date: Dec 2011
Location: Turin, Italy
Device: Several eReaders and tablets
You are welcome.
AlPe is offline   Reply With Quote
Old 04-01-2013, 03:18 PM   #207
tshering
Wizard
tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.tshering ought to be getting tired of karma fortunes by now.
 
Posts: 3,489
Karma: 2914715
Join Date: Jun 2012
Device: kobo touch
I would like to report a finding. As we already know it is possible to have several entries with the same keyword and all of them get displayed, for instance:
Code:
<w><p><a name="word" />definition 1</p></w>
<w><p><a name="word" />definition 2 </p></w>
If one looks up "word", the definitions 1 and 2 will get displayed.
It is also possible to have variants, for instance:
Code:
<w><p><a name="word" /><variant name="words"/>definition 1</p></w>
If one looks up "word" or "words", definition 1 will get displayed.

Oddly, these two things cannot be combined.
Code:
<w><p><a name="word" /><variant name="words"/>definition 1</p></w>
<w><p><a name="word" /><variant name="words"/>definition 2</p></w>
If one looks up "words", only definition 1 will be displayed, not definition 2.

Therefore, it seems best to merge entries with identical keywords into one single entry.
tshering is offline   Reply With Quote
Old 04-09-2013, 07:56 AM   #208
mietek81
Connoisseur
mietek81 , Klaatu Barada Niktu!mietek81 , Klaatu Barada Niktu!mietek81 , Klaatu Barada Niktu!mietek81 , Klaatu Barada Niktu!mietek81 , Klaatu Barada Niktu!mietek81 , Klaatu Barada Niktu!mietek81 , Klaatu Barada Niktu!mietek81 , Klaatu Barada Niktu!mietek81 , Klaatu Barada Niktu!mietek81 , Klaatu Barada Niktu!mietek81 , Klaatu Barada Niktu!
 
Posts: 77
Karma: 5414
Join Date: Mar 2013
Location: CK, Poland
Device: Kobo Glo, H2O
Hi
I have a stardict format dictionary which is separated into 2 parts (so I have 2 idx, 2 ifo and 2 dict.diz files). Is there a way to merge them into one dictionary?
mietek81 is offline   Reply With Quote
Old 04-09-2013, 08:06 AM   #209
AlPe
Digital Amanuensis
AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.
 
AlPe's Avatar
 
Posts: 727
Karma: 1446357
Join Date: Dec 2011
Location: Turin, Italy
Device: Several eReaders and tablets
Do you mean "merge them into one dictionary for the Kobo" ?

Unfortunately the merging function is not implemented in Penelope yet. Meanwhile, you can do the following:

1) Convert first StarDict dictionary to XML
2) Convert second StarDict dictionary to XML
3) Concatenate the two XML files of 1) and 2) (deleting the "tail/header" at the joining site) into a single XML file
4) Convert the XML file of step 3) into Kobo format
AlPe is offline   Reply With Quote
Old 04-09-2013, 08:06 AM   #210
AlPe
Digital Amanuensis
AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.AlPe ought to be getting tired of karma fortunes by now.
 
AlPe's Avatar
 
Posts: 727
Karma: 1446357
Join Date: Dec 2011
Location: Turin, Italy
Device: Several eReaders and tablets
Quote:
Originally Posted by tshering View Post
I would like to report a finding. As we already know it is possible to have several entries with the same keyword and all of them get displayed, for instance:
Code:
<w><p><a name="word" />definition 1</p></w>
<w><p><a name="word" />definition 2 </p></w>
If one looks up "word", the definitions 1 and 2 will get displayed.
It is also possible to have variants, for instance:
Code:
<w><p><a name="word" /><variant name="words"/>definition 1</p></w>
If one looks up "word" or "words", definition 1 will get displayed.

Oddly, these two things cannot be combined.
Code:
<w><p><a name="word" /><variant name="words"/>definition 1</p></w>
<w><p><a name="word" /><variant name="words"/>definition 2</p></w>
If one looks up "words", only definition 1 will be displayed, not definition 2.

Therefore, it seems best to merge entries with identical keywords into one single entry.
Thanks for the lead, I will try to reserve some time during the weekend to update Penelope accordingly.
AlPe is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
What's file format of dictionary mnjkl Kobo Reader 2 12-12-2011 08:48 AM
Dictionary format jgray Sony Reader 1 10-25-2010 09:52 AM
English Thesaurus in the dictionary format osnova Amazon Kindle 14 12-12-2009 06:42 PM
Dictionary: what version? can it be in firmware? jedix Sony Reader Dev Corner 7 12-05-2008 12:00 PM
Webster dictionary in DEPReader format abigail Reading and Management 0 08-10-2005 08:00 AM


All times are GMT -4. The time now is 08:56 PM.


MobileRead.com is a privately owned, operated and funded community.