BCBio 的 GFF 解析器出现问题
我正在尝试使用 BCBio GFF 解析器解析 GFF 文件,但出现以下错误。有人可以帮我解决这个问题吗?
回溯(最近一次调用最后一次):
File "gff_parse.py", line 6, in <module>
for rec in GFF.parse(in_handle):
File "build/bdist.linux-x86_64/egg/BCBio/GFF/GFFParser.py", line 709, in parse
File "build/bdist.linux-x86_64/egg/BCBio/GFF/GFFParser.py", line 299, in parse_in_parts
File "build/bdist.linux-x86_64/egg/BCBio/GFF/GFFParser.py", line 320, in parse_simple
File "build/bdist.linux-x86_64/egg/BCBio/GFF/GFFParser.py", line 603, in _gff_process
File "build/bdist.linux-x86_64/egg/BCBio/GFF/GFFParser.py", line 634, in _lines_to_out_info
File "build/bdist.linux-x86_64/egg/BCBio/GFF/GFFParser.py", line 183, in _gff_line_map
ValueError: invalid literal for int() with base 10: 'New Start'
这是我的代码:
from BCBio import GFF
in_file = "infile.gff"
in_handle = open(in_file)
for rec in GFF.parse(in_handle):
print rec
in_handle.close()
谢谢 图利卡
I am trying to parse a GFF file using the BCBio GFF parser and I get the following error. Can anybody help me in resolving this problem?
Traceback (most recent call last):
File "gff_parse.py", line 6, in <module>
for rec in GFF.parse(in_handle):
File "build/bdist.linux-x86_64/egg/BCBio/GFF/GFFParser.py", line 709, in parse
File "build/bdist.linux-x86_64/egg/BCBio/GFF/GFFParser.py", line 299, in parse_in_parts
File "build/bdist.linux-x86_64/egg/BCBio/GFF/GFFParser.py", line 320, in parse_simple
File "build/bdist.linux-x86_64/egg/BCBio/GFF/GFFParser.py", line 603, in _gff_process
File "build/bdist.linux-x86_64/egg/BCBio/GFF/GFFParser.py", line 634, in _lines_to_out_info
File "build/bdist.linux-x86_64/egg/BCBio/GFF/GFFParser.py", line 183, in _gff_line_map
ValueError: invalid literal for int() with base 10: 'New Start'
Here is my code:
from BCBio import GFF
in_file = "infile.gff"
in_handle = open(in_file)
for rec in GFF.parse(in_handle):
print rec
in_handle.close()
Thanks
Tulika
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
你是如何生成 GFF 文件的?它似乎包含至少一个无效行。第四列应包含要素起始坐标的整数;错误消息表明它包含值“New Start”。
GFF3 规范页面 提供了一些有效 GFF 的示例,并且 在线验证器可以帮助调试此类格式问题。
How did you generate the GFF file? It appears to contain at least one invalid line. The fourth column should contain integers for the start coordinate of a feature; the error message indicates it contains the value 'New Start' instead.
The GFF3 specification page has some examples of valid GFF, and the online validator can help with debugging formatting issues like this.