How JustAnswer Works:

  • Ask an Expert
    Experts are full of valuable knowledge and are ready to help with any question. Credentials confirmed by a Fortune 500 verification firm.
  • Get a Professional Answer
    Via email, text message, or notification as you wait on our site.
    Ask follow up questions if you need to.
  • 100% Satisfaction Guarantee
    Rate the answer you receive.

Ask yourteqrepair Your Own Question

yourteqrepair
yourteqrepair, Computer Systems Analyst
Category: Programming
Satisfied Customers: 50
Experience:  I have earned my 13+ years of knowledge through self-taught repairs, research, studying and plain old trial and error.
71069233
Type Your Programming Question Here...
yourteqrepair is online now
A new question is answered every 9 seconds

I am having problems with an application( that has been

Customer Question

I am having problems with an application( that has been working for 3 years on a Windows laptop) , with 'Unpickling' a file - it was working fine until recently, when now get EOFError:
c:\Users\Croker\Documents\SGYMMS>python gym.py
loading members...
Traceback (most recent call last):
File "gym.py", line 43, in
members = pickle.load(pickler)
File "C:\WinPython-64bit-2.7.9.5\python-2.7.9.amd64\lib\pickle.py", line 1378,
in load
return Unpickler(file).load()
File "C:\WinPython-64bit-2.7.9.5\python-2.7.9.amd64\lib\pickle.py", line 858,
in load
dispatch[key](self)
File "C:\WinPython-64bit-2.7.9.5\python-2.7.9.amd64\lib\pickle.py", line 880,
in load_eof
raise EOFError
EOFError
The file size has increased from 1,473,114 to 1,556,480 - Not that big!
If this is a memory problem (i.e. the Unpickler stack too small), how can I increase it?
I have increased the RAM on my laptop and updated to Windows 7 64-bit, abut no difference.nd 64-bit Python,
Python resources seem to be limited, as in:
c:\Users\Croker\Documents\SGYMMS>python
Python 2.7.9 (default, Dec 10 2014, 12:28:03) [MSC v.1500 64 bit (AMD64)] on win
32
Type "help", "copyright", "credits" or "license" for more information.
>>> import psutil
>>> psutil.virtual_memory()
svmem(total=8305168384L, available=6639263744L, percent=20.1, used=1665904640L,
free=6639263744L)
>>>
How can I increase the used memory in the Python interpreter?
Submitted: 1 year ago.
Category: Programming
Expert:  yourteqrepair replied 1 year ago.

Did this issue also occur before you upgraded to 64bit windows?

Customer: replied 1 year ago.
that is why upgraded. Thought 64-bit Python would use more memory so the Unpickler stack would increase. Is there a way of increasing the memory usage?
Expert:  yourteqrepair replied 1 year ago.

Where you working on the code or file before this happened? it could be a missed placed comma or other item in the code.

Customer: replied 1 year ago.
I am a Software Engineer with 30+ years experience in the profession - mainly C, C++. I wrote this application for a school 3 years ago and it has been working fine until this recent addition of data. It is possible that the pickled file is corrupted, but I think it is a memory problem. I really want to know how the Unpickler works and how Python allocates memory for it. Also, why is the interpreter only using 20% of available memory (as noted in my first posting with psutil.virtual_memory().
This showed
svmem(total=8305168384L, available=6639263744L, percent=20.1, used=1665904640L,
free=6639263744L)If the interpreter uses more memory then the Unpickler stack would increase - Yes?
Expert:  yourteqrepair replied 1 year ago.

have you tried Cpickler? What ever the addition data you have added might have a missed placed character. It's will really hard to determine exactly where with out actually seeing all the code. It's not a memory problems. It's reading the file and causing a Eof error when it shouldn't be eof file yet.

Customer: replied 1 year ago.
The pickled data file is hard to interpret - I don't know if there is misplaced character. Do I send the data file and you see if you can read it?
Expert:  yourteqrepair replied 1 year ago.

Yes if you could. My email is***@******.***