| Newsgroups |
gmane.text.yaml.general |
| Message-ID |
<BA02A06A22A52C449E4B5EE4CE1DBC3F999B60BDC9@EMV66-UKRD.domain1.systemhost.net> |
I am using PyYaml with libyaml. When trying to read a 100Mb YAML file, I get the following error. This is on a machine with 4G RAM. How can this happen?
Keith
kbriggs@gold> time python germany.py
yaml_loader_01: germany.pkl does not exist; will build it Traceback (most recent call last):
File "germany.py", line 21, in <module>
data=Germany()
File "germany.py", line 9, in __init__
s.d=yaml_safe_load('germany.yaml')
File "/home/kbriggs/yaml_loader_01.py", line 54, in yaml_safe_load
d=load(fy,Loader=Loader)
File "/usr/local/lib/python2.7/site-packages/yaml/__init__.py", line 71, in load
return loader.get_single_data()
File "/usr/local/lib/python2.7/site-packages/yaml/constructor.py", line 37, in get_single_data
node = self.get_single_node()
File "_yaml.pyx", line 707, in _yaml.CParser.get_single_node (ext/_yaml.c:7695)
File "_yaml.pyx", line 725, in _yaml.CParser._compose_document (ext/_yaml.c:7948)
File "_yaml.pyx", line 776, in _yaml.CParser._compose_node (ext/_yaml.c:8638)
File "_yaml.pyx", line 890, in _yaml.CParser._compose_mapping_node (ext/_yaml.c:10186)
File "_yaml.pyx", line 774, in _yaml.CParser._compose_node (ext/_yaml.c:8613)
File "_yaml.pyx", line 774, in _yaml.CParser._compose_node (ext/_yaml.c:8613)
File "_yaml.pyx", line 772, in _yaml.CParser._compose_node (ext/_yaml.c:8588)
File "/usr/local/lib/python2.7/site-packages/yaml/resolver.py", line 148, in resolve
if regexp.match(value):
MemoryError
real 4m17.797s
user 3m59.176s
sys 0m12.225s
------------------------------------------------------------------------------
AppSumo Presents a FREE Video for the SourceForge Community by Eric
Ries, the creator of the Lean Startup Methodology on "Lean Startup
Secrets Revealed." This video shows you how to validate your ideas,
optimize your ideas and identify your business strategy.
http://p.sf.net/sfu/appsumosfdev2dev