Changeset 8818


Ignore:
Timestamp:
Apr 5, 2013, 9:06:40 PM (12 years ago)
Author:
steve
Message:

Changed the loadsave to save a pickle file

Location:
trunk/anuga_core/source/anuga
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/anuga_core/source/anuga/shallow_water/test_loadsave.py

    r8780 r8818  
    169169
    170170        import cPickle       
    171         cPickle.dump(domain, open('domain_pickle.txt', 'w'))
    172         domain_restored = cPickle.load(open('domain_pickle.txt'))
    173 
     171        cPickle.dump(domain, open('domain_pickle.pickle', 'w'))
     172        domain_restored = cPickle.load(open('domain_pickle.pickle'))
     173
     174       
    174175        for t in domain_restored.evolve(yieldstep=0.1, finaltime=1.0):
    175176            # Shortcuts to quantites
  • trunk/anuga_core/source/anuga/test_all.py

    r8816 r8818  
    207207                file.endswith('.sts') or\
    208208                file.endswith('.tms') or\
    209                 file.endswith('.txt'):
    210             os.remove(file)
     209                file.endswith('.pickle'):
     210            try:
     211                os.remove(file)
     212            except:
     213                pass
    211214
    212215    check_anuga_import()
     
    263266                file.endswith('.sts') or\
    264267                file.endswith('.tms') or\
    265                 file.endswith('.txt'):
     268                file.endswith('.pickle'):
    266269            try:
    267270                os.remove(file)
Note: See TracChangeset for help on using the changeset viewer.