Show
Ignore:
Timestamp:
07/22/07 01:44:44 (5 years ago)
Author:
cdavid
Message:

Split pendigits into training and testing datasets, and convert return value of load to the package conventions.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/learn/scikits/learn/datasets/pendigits/src/convert.py

    r211 r450  
    11#! /usr/bin/env python 
    2 # Last Change: Tue Jul 17 05:00 PM 2007 J 
     2# Last Change: Sun Jul 22 01:00 PM 2007 J 
    33 
    44# This script generates a python file from the txt data 
     
    1717 
    1818# Write the data in pendigits.py 
    19 a = open("../pendigits.py", "w") 
     19ftra = open("../pendigits_tra.py", "w") 
     20ftes = open("../pendigits_tes.py", "w") 
    2021 
    21 a.writelines(dumpvar(tra, 'training')) 
    22 a.writelines(dumpvar(tes, 'testing')) 
    23 a.close() 
     22ftra.writelines(dumpvar(tra, 'training')) 
     23ftra.close() 
     24ftes.writelines(dumpvar(tes, 'testing')) 
     25ftes.close()