TA的每日心情 | 无聊 2021-1-15 05:13 |
---|
签到天数: 271 天 [LV.8]以坛为家I
会元
  
- 积分
- 6760

|
论坛各位大神:
本人目前在制作瑞-英字典, 正在处理原始数据中, 目的是做出MDict和OSX两个版本的, 所以想要知道OSX字典里具体关于发音的处理, 在OSX字典官方的说明文件和例子中均找不到相关的描述, 所以就想到了看看能不能按照qunwang6的帖子https://www.pdawiki.com/forum/fo ... id=13014&page=1把目前比较完美的MDict词典转为OSX的, 一个是为自己的OSX系统多一个好字典, 第二是可以看到在OSX字典源文件XML里关于是图片和发音的处理, 按照您的帖子, 如果成功的话, 是能够由MDict转出完美的OSX词典的(排版不重要, 可以慢慢调, 关键的东西都在就行)
但目前对于PYGLOSSARY的使用, 碰到了问题, 我的机器是 MacBook Pro, 系统是最新的10.11.4, 已经安装了Xcode, Command Line Tools for Xcode和Auxillary Tools for Xcode, 并执行了- sudo easy_install beautifulsoup4 html5lib
复制代码 命令, 但在执行- Python pyglossary.pyw --read-options=resPath=OtherResources --write-format=AppleDict oald8.mdx oald8.xml
复制代码 时, 提示- invalid write format AppleDict
复制代码 , 甚至在执行- python pyglossary.pyw --help
复制代码 都提示一堆错误, 开头是- error while importing plugin appledict
- Traceback (most recent call last):
- File "/Users/York/Software/pyglossary/pyglossary/glossary.py", line 141, in loadPlugin
- plugin = __import__(pluginName)
- File "/Users/York/Software/pyglossary/pyglossary/plugins/appledict/__init__.py", line 28, in <module>
- from ._dict import write_xml, get_beautiful_soup
- File "/Users/York/Software/pyglossary/pyglossary/plugins/appledict/_dict.py", line 26, in <module>
- import xdxf
- File "/Users/York/Software/pyglossary/pyglossary/plugins/xdxf/__init__.py", line 25, in <module>
- from lxml import etree
- ImportError: No module named lxml
- Traceback locals: {'__builtins__': {'ArithmeticError': <type 'exceptions.ArithmeticError'>,
- 'AssertionError': <type 'exceptions.AssertionError'>,
- 'AttributeError': <type 'exceptions.AttributeError'>,
- 'BaseException': <type 'exceptions.BaseException'>,
- ---------
复制代码
我对python基本一窍不通, 不知道问题出在何处, 不知大神能否指点一二, 先行多谢! |
|