Mercurial Hosting > traffic-intelligence
comparison python/storage.py @ 48:8aed225f71d8
rearranged code for function readline and getlines (and characters), moved invertHomography to cvutils
author | Nicolas Saunier <nicolas.saunier@polymtl.ca> |
---|---|
date | Thu, 23 Sep 2010 17:24:31 -0400 |
parents | ffddccfab7f9 |
children | 7b06d649122b |
comparison
equal
deleted
inserted
replaced
47:e27598865af3 | 48:8aed225f71d8 |
---|---|
83 | 83 |
84 print nObjectsPerType | 84 print nObjectsPerType |
85 | 85 |
86 out.close() | 86 out.close() |
87 | 87 |
88 # other functions | |
89 def getLines(f): | |
90 '''Gets a complete entry (all the lines) in between delimiterChar.''' | |
91 dataStrings = [] | |
92 s = utils.myreadline(f) | |
93 while (len(s) > 0) and (not s.startswith(delimiterChar)): | |
94 dataStrings += [s.strip()] | |
95 s = utils.myreadline(f) | |
96 return dataStrings | |
97 | |
98 | 88 |
99 | 89 |
100 | 90 |
101 if __name__ == "__main__": | 91 if __name__ == "__main__": |
102 import doctest | 92 import doctest |