17 |
|
""" |
18 |
|
|
19 |
|
__author__ = "Charles Vardeman (cvardema@nd.edu)" |
20 |
< |
__version__ = "$Revision: 1.2 $" |
21 |
< |
__date__ = "$Date: 2006-10-15 17:02:49 $" |
20 |
> |
__version__ = "$Revision: 1.5 $" |
21 |
> |
__date__ = "$Date: 2007-01-02 20:12:34 $" |
22 |
|
__copyright__ = "Copyright (c) 2006 by the University of Notre Dame" |
23 |
|
__license__ = "OOPSE" |
24 |
|
|
38 |
|
|
39 |
|
def splitFile(mdFileName,skipFrameNumber): |
40 |
|
mdFile = open(mdFileName, 'r') |
41 |
+ |
|
42 |
+ |
(filepath, filename) = os.path.split(mdFileName) |
43 |
|
|
44 |
< |
outfilePrefix,ext = os.path.splitext(mdFileName) |
44 |
> |
(outfilePrefix,ext) = os.path.splitext(filename) |
45 |
|
|
46 |
|
|
47 |
|
|
87 |
|
if (remainder == 0): |
88 |
|
outfilename = outfilePrefix + "_" +repr(foundFrames) + ext |
89 |
|
outFile = open(outfilename,'w') |
90 |
< |
outFile.write(oopseVersion) |
90 |
> |
outFile.write(OOPSEversion) |
91 |
|
for metaline in metaDataFrame: |
92 |
|
outFile.write(metaline) |
93 |
|
while not '</Snapshot>' in line: |
94 |
|
outFile.write(line) |
95 |
|
line = mdFile.readline() |
96 |
|
outFile.write(line) |
97 |
< |
outFile.write("</OOPSE>"> |
97 |
> |
outFile.write("</OOPSE>") |
98 |
|
outFile.close() |
99 |
|
line = mdFile.readline() |
100 |
|
if not line: break |