Changeset 4817
- Timestamp:
- Nov 15, 2007, 11:20:04 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_core/source/anuga/caching/caching.py
r4425 r4817 1775 1775 import os 1776 1776 import os.path 1777 from string import split, rstrip, find , atof, atoi1777 from string import split, rstrip, find 1778 1778 from time import strptime, localtime, strftime, mktime, ctime 1779 1779 … … 1827 1827 for record in A: 1828 1828 record = tuple(split(rstrip(record),',')) 1829 #print record 1830 1831 if len(record) in [8,9]: 1832 n = 0 1833 timestamp = record[n]; n=n+1 1829 #print record, len(record) 1830 1831 if len(record) == 9: 1832 timestamp = record[0] 1834 1833 1835 1834 try: … … 1844 1843 firstday = t 1845 1844 1846 user = record[ n]; n=n+11847 func = record[ n]; n=n+11845 user = record[1] 1846 func = record[2] 1848 1847 1849 1848 # Strip hash-stamp off … … 1852 1851 func = func[:i] 1853 1852 1854 size = atof(record[n]); n=n+1 1855 compression = atoi(record[n]); n=n+1 1856 hit = atoi(record[n]); n=n+1 1857 reason = atoi(record[n]); n=n+1 # Not used here 1858 cputime = atof(record[n]); n=n+1 1859 loadtime = atof(record[n]); n=n+1 1853 size = float(record[3]) 1854 1855 # Compression kepword can be Boolean 1856 if record[4] in ['True', '1']: 1857 compression = 1 1858 elif record[4] in ['False', '0']: 1859 compression = 0 1860 else: 1861 print 'Unknown value of compression', record[4] 1862 print record 1863 total_discarded = total_discarded + 1 1864 continue 1865 1866 #compression = int(record[4]) # Can be Boolean 1867 hit = int(record[5]) 1868 reason = int(record[6]) # Not used here 1869 cputime = float(record[7]) 1870 loadtime = float(record[8]) 1860 1871 1861 1872 if hit:
Note: See TracChangeset
for help on using the changeset viewer.