Comments (9)
我的猜想是編輯安裝目錄下\opencc\dictionary\的文件
看起來像對照表,可以編輯試試?
可以參考
https://blog.darkthread.net/blog/opencc-conv-customization/
from epubconv_python.
這個部分的確可以自行在 opencc/dictionary 中修改
詳細要修改的檔案可以查看 opencc/config 中的設定檔
比如說使用 s2t 好了 就可以看到到底這個模式所使用的字典檔是那些,再去opencc/dictionary中修改,或者如 #8 (comment) 所說的用自訂字典的方式修改
EpubConv_Python/opencc/config/s2t.json
Line 15 in ba5cd3a
EpubConv_Python/opencc/config/s2t.json
Line 18 in ba5cd3a
但是比較需要注意的問題是 Python 版本的 OpenCC 有一個 BUG,就是當一個詞有兩種結果只會回傳第一個結果,作者頁面
如果需要非常準確的翻譯結果可以嘗試看看使用 v2.0.0 的繁化姬引擎翻譯看看,只不過因為是使用網路功能需要有網路的環境以及轉換的效率並沒有 OpenCC 來的快速
from epubconv_python.
ver.2.0.0無法使用,用calibre轉檔也一樣,這檔案在ver.1.0.5.2可以正常轉換。
log 記錄檔如下:
2019-07-27 20:49:25,353 EPUB INFO : * function: _read_config, * msg: read config
2019-07-27 20:49:25,353 EPUB INFO : * function: _read_config encoding, * msg: ASCII
2019-07-27 20:49:25,353 EPUB INFO : * function: _read_config, * msg: already read config
engine: zhconvert
converter: Traditional
format: Horizontal
2019-07-27 20:49:25,353 EPUB INFO : * function: convert, * msg: file path: D:\Program Files\EpubConv 2.0.0\冒险者入门篇[简].epub
2019-07-27 20:49:25,494 EPUB ERROR : * function: convert, * msg: File is not a epub file
from epubconv_python.
@mtis1233 我從這邊只能知道程式判斷檔案並非epub格式,epub格式為 application/epub+zip
from epubconv_python.
mimetype是application/epub+zip,檔案格式應該沒錯,我有寄檔案了,希望有幫助
from epubconv_python.
@mtis1233 恩...我這邊執行結果是正常的捏?
如果判斷還是非 epub 檔案
我預計會先釋出 2.0.1 讓程式可以輸出 debug log 這樣也比較好排除
from epubconv_python.
@mtis1233 我嘗試過很多方式還是無法還原你的問題 冏
一開始認為會不會是環境問題 我把 v2.0.1 版本的程式丟給朋友(完全無開發環境) 跟你提供的 epub 一樣可以轉換
接下來猜測作業系統? 防毒軟體? 或者有其他不明因素導致這個狀況發生
如同我回信的內容,照理說不管是怎樣的檔案規格應該都會有檔案格式,但是在debug內容中卻是回傳 None
又或者你執行方式是使用 cli 去呼叫轉換
那如果 epub 路徑中有空白比如說
python app2.py <file path>/example file.epub
在 cli 中會判斷成只執行
python app2.py <file path>/example
如果要完整寫上路徑建議是在檔案路徑前後還是用雙引號框起來
from epubconv_python.
我也找不到原因,win10內建防毒都關了也一樣,可能真的是作業系統bug吧 很久沒更新了。
目前是把self._check(epub_file_path)刪除就能正常運行
下圖:原檔案和刪除後
from epubconv_python.
这个bug大概是calibre造成的,我之前安装calibre之后使用程序就会报错,卸载calibre无效,但是重装系统之后程序恢复正常。
from epubconv_python.
Related Issues (14)
- Win10 最新版本無法直接使用 .exe 檔案轉換 HOT 2
- 轉換後失去章節 HOT 5
- Miss cssutils in requirements.txt HOT 1
- Epubconv ver.1.0.3.1 被 Windows判斷成病毒 HOT 2
- Error function: convert, *msg: local variable 'opf' referenced before assignment HOT 2
- Add linux binary relase
- zhconvert Request error. status code: 429 HOT 7
- 希望支持简繁互转 HOT 5
- 加入直排功能 HOT 8
- List index out of range HOT 2
- 是否考慮加入以繁化姬 API 轉換的選項 HOT 5
- 能否增加參數設定? HOT 3
- 轉換檔案時判斷檔案格式錯誤 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from epubconv_python.