rem
stringlengths
1
226k
add
stringlengths
0
227k
context
stringlengths
6
326k
meta
stringlengths
143
403
input_ids
listlengths
256
256
attention_mask
listlengths
256
256
labels
listlengths
128
128
self.assertEquals(work_item, "work_item")
self.test.assertEquals(work_item, "work_item")
def should_proceed_with_work_item(self, work_item): self.callbacks.append("should_proceed_with_work_item") self.assertEquals(work_item, "work_item") return (True, "waiting_message", 42)
2ab6dd9042cc607541b00e081f35dd79a297dbd0 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9392/2ab6dd9042cc607541b00e081f35dd79a297dbd0/workqueue_unittest.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1410, 67, 685, 5288, 67, 1918, 67, 1252, 67, 1726, 12, 2890, 16, 1440, 67, 1726, 4672, 365, 18, 13316, 18, 6923, 2932, 13139, 67, 685, 5288, 67, 1918, 67, 1252, 67, 1726, 7923, 365, 18, 3813, 18, 11231, 8867, 12, 1252, 67, 1726, 16, 315, 1252, 67, 1726, 7923, 327, 261, 5510, 16, 315, 20241, 67, 2150, 3113, 14856, 13, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,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, 18, 11231, 8867, 12, 1252, 67, 1726, 16, 315, 1252, 67, 1726, 7923, 327, 261, 5510, 16, 315, 20241, 67, 2150, 3113, 14856, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
'The generated source will be invalid outside the Designer' ' and should be fixed before executing.')
'The generated source will be invalid outside the ' 'Designer and should be fixed before executing.')
def writeCollectionItems(self, output, stripFrmId=''): CollectionDTC.writeCollectionItems(self, output, stripFrmId) warn = 0 for constr in self.textConstrLst: if constr.params[0] == 'None': wxLogWarning('No control/sizer for sizer item of %s'%( self.parentCompanion.name)) warn = 1 if warn: wxLogWarning('None values are only valid in the Designer.\n' 'The generated source will be invalid outside the Designer' ' and should be fixed before executing.')
f1282503f876232c6a9f48c3d5b7a52bbc481a8d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/f1282503f876232c6a9f48c3d5b7a52bbc481a8d/SizerCompanions.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1045, 2532, 3126, 12, 2890, 16, 876, 16, 2569, 7167, 81, 548, 2218, 11, 4672, 2200, 9081, 39, 18, 2626, 2532, 3126, 12, 2890, 16, 876, 16, 2569, 7167, 81, 548, 13, 1894, 273, 374, 364, 14472, 316, 365, 18, 955, 442, 701, 28134, 30, 309, 14472, 18, 2010, 63, 20, 65, 422, 296, 7036, 4278, 7075, 1343, 6210, 2668, 2279, 3325, 19, 87, 1824, 364, 272, 1824, 761, 434, 738, 87, 11, 17105, 365, 18, 2938, 2945, 304, 285, 18, 529, 3719, 1894, 273, 404, 309, 1894, 30, 7075, 1343, 6210, 2668, 7036, 924, 854, 1338, 923, 316, 326, 29703, 264, 8403, 82, 11, 296, 1986, 4374, 1084, 903, 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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1045, 2532, 3126, 12, 2890, 16, 876, 16, 2569, 7167, 81, 548, 2218, 11, 4672, 2200, 9081, 39, 18, 2626, 2532, 3126, 12, 2890, 16, 876, 16, 2569, 7167, 81, 548, 13, 1894, 273, 374, 364, 14472, 316, 365, 18, 955, 442, 701, 28134, 30, 309, 14472, 18, 2010, 63, 20, 65, 422, 296, 7036, 4278, 7075, 1343, 6210, 2668, 2279, 3325, 19, 87, 1824, 364, 272, 1824, 761, 434, 738, 87, 11, 17105, 365, 18, 2938, 2945, 304, 285, 18, 529, 3719, 1894, 273, 404, 309, 1894, 30, 7075, 1343, 6210, 2668, 7036, 924, 854, 1338, 923, 316, 326, 29703, 264, 8403, 82, 11, 296, 1986, 4374, 1084, 903, 506, 2057, 8220, 326, 29703, 264, 11, 296, 2 ]
try: sql = 'SELECT username FROM %susers WHERE username LIKE %%s' % cfg.database.prefix
if not filter: filter = '%' try: sql = 'SELECT user_id, username FROM %susers WHERE (user_type = 0 OR user_type = 3) AND username LIKE %%s' % cfg.database.prefix
def getRegisteredUsers(self, filter, current = None): """ Returns a list of usernames in the phpBB3 database which contain filter as a substring. """ try: sql = 'SELECT username FROM %susers WHERE username LIKE %%s' % cfg.database.prefix cur = threadDB.execute(sql, filter) except threadDbException: return []
9f36caa421806530adcbe0a45cf04a0e8eb4d8ff /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/13030/9f36caa421806530adcbe0a45cf04a0e8eb4d8ff/phpBB3auth.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 10868, 6588, 12, 2890, 16, 1034, 16, 783, 273, 599, 4672, 3536, 2860, 279, 666, 434, 27675, 316, 326, 3863, 9676, 23, 2063, 1492, 912, 1034, 487, 279, 3019, 18, 3536, 225, 309, 486, 1034, 30, 1034, 273, 9089, 225, 775, 30, 1847, 273, 296, 4803, 729, 67, 350, 16, 2718, 4571, 738, 87, 5577, 4852, 261, 1355, 67, 723, 273, 374, 4869, 729, 67, 723, 273, 890, 13, 4116, 2718, 13161, 26510, 87, 11, 738, 2776, 18, 6231, 18, 3239, 662, 273, 2650, 2290, 18, 8837, 12, 4669, 16, 1034, 13, 1335, 2650, 4331, 503, 30, 327, 5378, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 10868, 6588, 12, 2890, 16, 1034, 16, 783, 273, 599, 4672, 3536, 2860, 279, 666, 434, 27675, 316, 326, 3863, 9676, 23, 2063, 1492, 912, 1034, 487, 279, 3019, 18, 3536, 225, 309, 486, 1034, 30, 1034, 273, 9089, 225, 775, 30, 1847, 273, 296, 4803, 729, 67, 350, 16, 2718, 4571, 738, 87, 5577, 4852, 261, 1355, 67, 723, 273, 374, 4869, 729, 67, 723, 273, 890, 13, 4116, 2718, 13161, 26510, 87, 11, 738, 2776, 18, 6231, 18, 3239, 662, 273, 2650, 2290, 18, 8837, 12, 4669, 16, 1034, 13, 1335, 2650, 4331, 503, 30, 327, 5378, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
rect = components.entity('Red Rect', clock, location=(300, 100), motion=components.motion(velocity=(3,-0.5)), graphics=components.graphics((255, 0, 0), (20, 20))) player = components.entity('White Rect', clock, keyboard, location=(0, 0), motion=components.motion([0, 0], [0, 0]), graphics=components.graphics((128, 128, 128), (10, 10)))
rect = entity('Red Rect', clock, location=(300, 100), motion=motion(velocity=(3,-0.5)), graphics=graphics((255, 0, 0), (20, 20))) player = entity('White Rect', clock, keyboard, location=(425, 300), motion=motion([0, 0], [0, 0]), graphics=graphics((128, 128, 128), (10, 10)))
def main(): clock = events.dispatcher('Clock') keyboard = events.dispatcher('Keyboard') rect = components.entity('Red Rect', clock, location=(300, 100), motion=components.motion(velocity=(3,-0.5)), graphics=components.graphics((255, 0, 0), (20, 20))) player = components.entity('White Rect', clock, keyboard, location=(0, 0), motion=components.motion([0, 0], [0, 0]), graphics=components.graphics((128, 128, 128), (10, 10))) accelerate_on_keypress(player, K_UP, (0, -0.25), frames=0) accelerate_on_keypress(player, K_DOWN, (0, 0.25), frames=0) accelerate_on_keypress(player, K_LEFT, (-0.25, 0), frames=0) accelerate_on_keypress(player, K_RIGHT, (0.25, 0), frames=0) things = [rect, player] for thing in things: attractor(thing, (300, 300), 5000) attractor(thing, (600, 300), 5000) velocity_updater(thing) court_order(thing, (300, 300), 60) court_order(thing, (600, 300), 60) location_updater(thing) location_clamper(thing, (0, 0), (1000, 600)) frame_time = 0.02 pygame.init() screen = pygame.display.set_mode((1000, 600)) tick_event = pygame.event.Event(TICK) while True: start = time.clock() clock.dispatch(tick_event) for event in pygame.event.get(): if event.type == QUIT: return 0 elif event.type == KEYDOWN or event.type == KEYUP: keyboard.dispatch(event) screen.fill((0, 0, 0)) for thing in things: if thing.graphics is not None and thing.location is not None: screen.fill(thing.graphics.color, pygame.Rect(thing.location[0] - thing.graphics.size[0] / 2, thing.location[1] - thing.graphics.size[1] / 2, thing.graphics.size[0], thing.graphics.size[1])) pygame.display.flip() delta = time.clock() - start if delta < frame_time: time.sleep(frame_time - delta)
119cfe026c332e53b422ce373082a2b100697643 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/13911/119cfe026c332e53b422ce373082a2b100697643/orbitals.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2774, 13332, 7268, 273, 2641, 18, 18495, 2668, 14027, 6134, 16263, 273, 2641, 18, 18495, 2668, 17872, 6134, 4917, 273, 1522, 2668, 3715, 9315, 2187, 7268, 16, 2117, 28657, 19249, 16, 2130, 3631, 21188, 33, 81, 8240, 12, 29418, 560, 28657, 23, 16, 17, 20, 18, 25, 13, 3631, 17313, 33, 31586, 12443, 10395, 16, 374, 16, 374, 3631, 261, 3462, 16, 4200, 20349, 7291, 273, 1522, 2668, 13407, 9315, 2187, 7268, 16, 16263, 16, 2117, 28657, 24, 2947, 16, 11631, 3631, 21188, 33, 81, 8240, 3816, 20, 16, 374, 6487, 306, 20, 16, 374, 65, 3631, 17313, 33, 31586, 12443, 10392, 16, 8038, 16, 8038, 3631, 261, 2163, 16, 1728, 20349, 15153, 12600, 67, 265, 67, 856, 1028, 12, 14872, 16, 1475, 67, 3079, 16, 261, 20, 16, 300, 20, 18, 2947, 3631, 7793, 33, 20, 13, 15153, 12600, 67, 265, 67, 856, 1028, 12, 14872, 16, 1475, 67, 12711, 16, 261, 20, 16, 374, 18, 2947, 3631, 7793, 33, 20, 13, 15153, 12600, 67, 265, 67, 856, 1028, 12, 14872, 16, 1475, 67, 10066, 16, 24927, 20, 18, 2947, 16, 374, 3631, 7793, 33, 20, 13, 15153, 12600, 67, 265, 67, 856, 1028, 12, 14872, 16, 1475, 67, 11847, 16, 261, 20, 18, 2947, 16, 374, 3631, 7793, 33, 20, 13, 9198, 273, 306, 2607, 16, 7291, 65, 364, 7757, 316, 9198, 30, 622, 1575, 280, 12, 4274, 16, 261, 19249, 16, 11631, 3631, 20190, 13, 622, 1575, 280, 12, 4274, 16, 261, 28133, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2774, 13332, 7268, 273, 2641, 18, 18495, 2668, 14027, 6134, 16263, 273, 2641, 18, 18495, 2668, 17872, 6134, 4917, 273, 1522, 2668, 3715, 9315, 2187, 7268, 16, 2117, 28657, 19249, 16, 2130, 3631, 21188, 33, 81, 8240, 12, 29418, 560, 28657, 23, 16, 17, 20, 18, 25, 13, 3631, 17313, 33, 31586, 12443, 10395, 16, 374, 16, 374, 3631, 261, 3462, 16, 4200, 20349, 7291, 273, 1522, 2668, 13407, 9315, 2187, 7268, 16, 16263, 16, 2117, 28657, 24, 2947, 16, 11631, 3631, 21188, 33, 81, 8240, 3816, 20, 16, 374, 6487, 306, 20, 16, 374, 65, 3631, 17313, 33, 31586, 12443, 10392, 16, 8038, 16, 8038, 3631, 261, 2163, 16, 1728, 20349, 15153, 12600, 67, 265, 67, 856, 2 ]
if len(prev_misc_txt) > 0: count_misc += 1
def convert_processed_reference_line_to_marc_xml(line): """Given a processed reference line, convert it to MARC XML. @param line: (string) - the processed reference line, in which the recognised citations have been tagged. @return: (tuple) - + xml_line (string) - the reference line with all of its identified citations marked up into the various subfields. + count_misc (integer) - number of sections of miscellaneous found in the line + count_title (integer) - number of title-citations found in the line + count_reportnum (integer) - number of report numbers found in the line + count_url (integer) - number of URLs found in the line """ count_misc = count_title = count_reportnum = count_url = 0 xml_line = "" previously_cited_item = None processed_line = line.lstrip() ## 1. Extract reference line marker (e.g. [1]) from start of line and tag it: ## get patterns to identify numeration markers at the start of lines: marker_patterns = get_reference_line_numeration_marker_patterns() marker_match = perform_regex_search_upon_line_with_pattern_list(processed_line, marker_patterns) if marker_match is not None: ## found a marker: marker_val = marker_match.group(u'mark') ## trim the marker from the start of the line: processed_line = processed_line[marker_match.end():].lstrip() else: marker_val = u" " ## Now display the marker in marked-up XML: xml_line += _refextract_markup_reference_line_marker_as_marcxml(marker_val) ## 2. Loop through remaining identified segments in line and tag them into MARC XML segments: cur_misc_txt = u"" ## a marker to hold gathered miscellaneous text before a citation tag_match = sre_tagged_citation.search(processed_line) while tag_match is not None: ## found a tag - process it: tag_match_start = tag_match.start() tag_match_end = tag_match.end() tag_type = tag_match.group(1) if tag_type == "TITLE": ## This tag is an identified journal TITLE. It should be followed by VOLUME, ## YEAR and PAGE tags. cur_misc_txt += processed_line[0:tag_match_start] ## extract the title from the line: idx_closing_tag = processed_line.find(CFG_REFEXTRACT_MARKER_CLOSING_TITLE, tag_match_end) ## Sanity check - did we find a closing TITLE tag? if idx_closing_tag == -1: ## no closing </cds.TITLE> tag found - strip the opening tag and move past it processed_line = processed_line[tag_match_end:] else: ## Closing tag was found: title_text = processed_line[tag_match_end:idx_closing_tag] ## Now trim this matched title and its tags from the start of the line: processed_line = processed_line[idx_closing_tag+len(CFG_REFEXTRACT_MARKER_CLOSING_TITLE):] ## Was this title followed by the tags of recognised VOLUME, YEAR and PAGE objects? numeration_match = sre_recognised_numeration_for_title.match(processed_line) if numeration_match is not None: ## recognised numeration immediately after the title - extract it: reference_volume = numeration_match.group(2) reference_year = numeration_match.group(3) reference_page = numeration_match.group(4) ## Skip past the matched numeration in the working line: processed_line = processed_line[numeration_match.end():] if previously_cited_item is None: ## There is no previously cited item - this should be added as the previously ## cited item: previously_cited_item = { 'type' : "TITLE", 'misc_txt' : cur_misc_txt, 'title' : title_text, 'volume' : reference_volume, 'year' : reference_year, 'page' : reference_page, } ## Now empty the miscellaneous text and title components: cur_misc_txt = "" title_text = "" reference_volume = "" reference_year = "" reference_page = "" elif (previously_cited_item is not None) and \ (previously_cited_item['type'] == "REPORTNUMBER") and \ (len(cur_misc_txt.lower().replace("arxiv", "").strip(".,:;- []")) == 0): ## This TITLE belongs with the REPORT NUMBER before it - add them both into ## the same datafield tag (REPORT NUMBER first, TITLE second): prev_report_num = previously_cited_item['report_num'] prev_misc_txt = previously_cited_item['misc_txt'].lstrip(".;, ").rstrip() xml_line += \ _refextract_markup_title_followed_by_report_number_as_marcxml(title_text, reference_volume, reference_year, reference_page, prev_report_num, prev_misc_txt) ## Increment the stats counters: if len(prev_misc_txt) > 0: count_misc += 1 count_title += 1 count_reportnum += 1 ## reset the various variables: previously_cited_item = None cur_misc_txt = u"" title_text = "" reference_volume = "" reference_year = "" reference_page = "" else: ## either the previously cited item is NOT a REPORT NUMBER, or this cited TITLE ## is preceeded by miscellaneous text. In either case, the two cited objects are ## not the same and do not belong together in the same datafield. if previously_cited_item['type'] == "REPORTNUMBER": ## previously cited item was a REPORT NUMBER. ## Add previously cited REPORT NUMBER to XML string: prev_report_num = previously_cited_item['report_num'] prev_misc_txt = previously_cited_item['misc_txt'].lstrip(".;, ").rstrip() xml_line += _refextract_markup_reportnumber_as_marcxml(prev_report_num, prev_misc_txt) ## Increment the stats counters: if len(prev_misc_txt) > 0: count_misc += 1 count_reportnum += 1 elif previously_cited_item['type'] == "TITLE": ## previously cited item was a TITLE. ## Add previously cited TITLE to XML string: prev_title = previously_cited_item['title'] prev_volume = previously_cited_item['volume'] prev_year = previously_cited_item['year'] prev_page = previously_cited_item['page'] prev_misc_txt = previously_cited_item['misc_txt'].lstrip(".;, ").rstrip() xml_line += _refextract_markup_title_as_marcxml(prev_title, prev_volume, prev_year, prev_page, prev_misc_txt) ## Increment the stats counters: if len(prev_misc_txt) > 0: count_misc += 1 count_title += 1 ## Now add the current cited item into the previously cited item marker previously_cited_item = { 'type' : "TITLE", 'misc_txt' : cur_misc_txt, 'title' : title_text, 'volume' : reference_volume, 'year' : reference_year, 'page' : reference_page, } ## empty miscellaneous text cur_misc_txt = u"" title_text = "" reference_volume = "" reference_year = "" reference_page = "" else: ## No numeration was recognised after the title. Add the title into misc and carry on: cur_misc_txt += " %s" % title_text elif tag_type == "REPORTNUMBER": ## This tag is an identified institutional report number: ## Account for the miscellaneous text before the citation: cur_misc_txt += processed_line[0:tag_match_start] ## extract the institutional report-number from the line: idx_closing_tag = processed_line.find(CFG_REFEXTRACT_MARKER_CLOSING_REPORT_NUM, tag_match_end) ## Sanity check - did we find a closing report-number tag? if idx_closing_tag == -1: ## no closing </cds.REPORTNUMBER> tag found - strip the opening tag and move past this ## recognised reportnumber as it is unreliable: processed_line = processed_line[tag_match_end:] else: ## closing tag was found report_num = processed_line[tag_match_end:idx_closing_tag] ## now trim this matched institutional report-number and its tags from the start of the line: processed_line = processed_line[idx_closing_tag+len(CFG_REFEXTRACT_MARKER_CLOSING_REPORT_NUM):] ## Now, if there was a previous TITLE citation and this REPORT NUMBER citation one has no ## miscellaneous text after punctuation has been stripped, the two refer to the same object, ## so group them under the same datafield: if previously_cited_item is None: ## There is no previously cited item - this should be added as the previously ## cited item: previously_cited_item = { 'type' : "REPORTNUMBER", 'misc_txt' : "%s" % cur_misc_txt, 'report_num' : "%s" % report_num, } ## empty miscellaneous text cur_misc_txt = u"" report_num = u"" elif (previously_cited_item is not None) and \ (previously_cited_item['type'] == "TITLE") and \ (len(cur_misc_txt.lower().replace("arxiv", "").strip(".,:;- []")) == 0): ## This REPORT NUMBER belongs with the title before it - add them both into ## the same datafield tag (TITLE first, REPORT NUMBER second): prev_title = previously_cited_item['title'] prev_volume = previously_cited_item['volume'] prev_year = previously_cited_item['year'] prev_page = previously_cited_item['page'] prev_misc_txt = previously_cited_item['misc_txt'].lstrip(".;, ").rstrip() xml_line += \ _refextract_markup_title_followed_by_report_number_as_marcxml(prev_title, prev_volume, prev_year, prev_page, report_num, prev_misc_txt) ## Increment the stats counters: if len(prev_misc_txt) > 0: count_misc += 1 count_title += 1 count_reportnum += 1 ## Reset variables: previously_cited_item = None cur_misc_txt = u"" else: ## either the previously cited item is NOT a TITLE, or this cited REPORT NUMBER ## is preceeded by miscellaneous text. In either case, the two cited objects are ## not the same and do not belong together in the same datafield. if previously_cited_item['type'] == "REPORTNUMBER": ## previously cited item was a REPORT NUMBER. ## Add previously cited REPORT NUMBER to XML string: prev_report_num = previously_cited_item['report_num'] prev_misc_txt = previously_cited_item['misc_txt'].lstrip(".;, ").rstrip() xml_line += _refextract_markup_reportnumber_as_marcxml(prev_report_num, prev_misc_txt) ## Increment the stats counters: if len(prev_misc_txt) > 0: count_misc += 1 count_reportnum += 1 elif previously_cited_item['type'] == "TITLE": ## previously cited item was a TITLE. ## Add previously cited TITLE to XML string: prev_title = previously_cited_item['title'] prev_volume = previously_cited_item['volume'] prev_year = previously_cited_item['year'] prev_page = previously_cited_item['page'] prev_misc_txt = previously_cited_item['misc_txt'].lstrip(".;, ").rstrip() xml_line += _refextract_markup_title_as_marcxml(prev_title, prev_volume, prev_year, prev_page, prev_misc_txt) ## Increment the stats counters: if len(prev_misc_txt) > 0: count_misc += 1 count_title += 1 ## Now add the current cited item into the previously cited item marker previously_cited_item = { 'type' : "REPORTNUMBER", 'misc_txt' : "%s" % cur_misc_txt, 'report_num' : "%s" % report_num, } ## empty miscellaneous text cur_misc_txt = u"" report_num = u"" elif tag_type == "URL": ## This tag is an identified URL: ## Account for the miscellaneous text before the URL: cur_misc_txt += processed_line[0:tag_match_start] ## extract the URL information from within the tags in the line: idx_closing_tag = processed_line.find(CFG_REFEXTRACT_MARKER_CLOSING_URL, tag_match_end) ## Sanity check - did we find a closing URL tag? if idx_closing_tag == -1: ## no closing </cds.URL> tag found - strip the opening tag and move past it processed_line = processed_line[tag_match_end:] else: ## Closing tag was found: ## First, get the URL string from between the tags: url_string = processed_line[tag_match_end:idx_closing_tag] ## Now, get the URL description string from within the opening cds tag. E.g.: ## from <cds.URL description="abc"> get the "abc" value: opening_url_tag = processed_line[tag_match_start:tag_match_end] if opening_url_tag.find(u"""<cds.URL description=\"""") != -1: ## the description is present - extract it: ## (Stop 2 characters before the end of the string - we assume they are the ## closing characters '">'. url_descr = opening_url_tag[22:-2] else: ## There is no description - description should now be the url string: url_descr = url_string ## now trim this URL and its tags from the start of the line: processed_line = processed_line[idx_closing_tag+len(CFG_REFEXTRACT_MARKER_CLOSING_URL):] ## Build the MARC XML representation of this identified URL: if previously_cited_item is not None: ## There was a previously cited item. We must convert it to XML before we can ## convert this URL to XML: if previously_cited_item['type'] == "REPORTNUMBER": ## previously cited item was a REPORT NUMBER. ## Add previously cited REPORT NUMBER to XML string: prev_report_num = previously_cited_item['report_num'] prev_misc_txt = previously_cited_item['misc_txt'].lstrip(".;, ").rstrip() xml_line += _refextract_markup_reportnumber_as_marcxml(prev_report_num, prev_misc_txt) ## Increment the stats counters: if len(prev_misc_txt) > 0: count_misc += 1 count_reportnum += 1 elif previously_cited_item['type'] == "TITLE": ## previously cited item was a TITLE. ## Add previously cited TITLE to XML string: prev_title = previously_cited_item['title'] prev_volume = previously_cited_item['volume'] prev_year = previously_cited_item['year'] prev_page = previously_cited_item['page'] prev_misc_txt = previously_cited_item['misc_txt'].lstrip(".;, ").rstrip() xml_line += _refextract_markup_title_as_marcxml(prev_title, prev_volume, prev_year, prev_page, prev_misc_txt) ## Increment the stats counters: if len(prev_misc_txt) > 0: count_misc += 1 count_title += 1 ## Empty the previously-cited item place-holder: previously_cited_item = None ## Now convert this URL to MARC XML cur_misc_txt = cur_misc_txt.lstrip(".;, ").rstrip() if url_string.find("http //") == 0: url_string = u"http://" + url_string[7:] elif url_string.find("ftp //") == 0: url_string = u"ftp://" + url_string[6:] if url_descr.find("http //") == 0: url_descr = u"http://" + url_descr[7:] elif url_descr.find("ftp //") == 0: url_descr = u"ftp://" + url_descr[6:] xml_line += \ _refextract_markup_url_as_marcxml(url_string, url_descr, cur_misc_txt) ## Increment the stats counters: if len(cur_misc_txt) > 0: count_misc += 1 count_url += 1 cur_misc_txt = u"" elif tag_type == "SER": ## This tag is a SERIES tag; Since it was not preceeded by a TITLE tag, ## it is useless - strip the tag and put it into miscellaneous: (cur_misc_txt, processed_line) = \ _convert_unusable_tag_to_misc(processed_line, cur_misc_txt, \ tag_match_start,tag_match_end, CFG_REFEXTRACT_MARKER_CLOSING_SERIES) elif tag_type == "VOL": ## This tag is a VOLUME tag; Since it was not preceeded by a TITLE tag, ## it is useless - strip the tag and put it into miscellaneous: (cur_misc_txt, processed_line) = \ _convert_unusable_tag_to_misc(processed_line, cur_misc_txt, \ tag_match_start,tag_match_end, CFG_REFEXTRACT_MARKER_CLOSING_VOLUME) elif tag_type == "YR": ## This tag is a YEAR tag; Since it's not preceeded by TITLE and VOLUME tags, it ## is useless - strip the tag and put the contents into miscellaneous: (cur_misc_txt, processed_line) = \ _convert_unusable_tag_to_misc(processed_line, cur_misc_txt, \ tag_match_start,tag_match_end, CFG_REFEXTRACT_MARKER_CLOSING_YEAR) elif tag_type == "PG": ## This tag is a PAGE tag; Since it's not preceeded by TITLE, VOLUME and YEAR tags, ## it is useless - strip the tag and put the contents into miscellaneous: (cur_misc_txt, processed_line) = \ _convert_unusable_tag_to_misc(processed_line, cur_misc_txt, \ tag_match_start,tag_match_end, CFG_REFEXTRACT_MARKER_CLOSING_PAGE) else: ## Unknown tag - discard as miscellaneous text: cur_misc_txt += processed_line[0:tag_match.end()] processed_line = processed_line[tag_match.end():] ## Look for the next tag in the processed line: tag_match = sre_tagged_citation.search(processed_line) ## If a previously cited item remains, convert it into MARC XML: if previously_cited_item is not None: if previously_cited_item['type'] == "REPORTNUMBER": ## previously cited item was a REPORT NUMBER. ## Add previously cited REPORT NUMBER to XML string: prev_report_num = previously_cited_item['report_num'] prev_misc_txt = previously_cited_item['misc_txt'].lstrip(".;, ").rstrip() xml_line += _refextract_markup_reportnumber_as_marcxml(prev_report_num, prev_misc_txt) ## Increment the stats counters: if len(prev_misc_txt) > 0: count_misc += 1 count_reportnum += 1 elif previously_cited_item['type'] == "TITLE": ## previously cited item was a TITLE. ## Add previously cited TITLE to XML string: prev_title = previously_cited_item['title'] prev_volume = previously_cited_item['volume'] prev_year = previously_cited_item['year'] prev_page = previously_cited_item['page'] prev_misc_txt = previously_cited_item['misc_txt'].lstrip(".;, ").rstrip() xml_line += _refextract_markup_title_as_marcxml(prev_title, prev_volume, prev_year, prev_page, prev_misc_txt) ## Increment the stats counters: if len(prev_misc_txt) > 0: count_misc += 1 count_title += 1 ## free up previously_cited_item: previously_cited_item = None ## place any remaining miscellaneous text into the appropriate MARC XML fields: cur_misc_txt += processed_line if len(cur_misc_txt.strip(" .;,")) > 0: ## The remaining misc text is not just a full-stop or semi-colon. Add it: xml_line += _refextract_markup_miscellaneous_text_as_marcxml(cur_misc_txt) ## Increment the stats counters: count_misc += 1 ## return the reference-line as MARC XML: return (xml_line, count_misc, count_title, count_reportnum, count_url)
6258c992576ce615917d5d2bfa3f925bb23de3b5 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/12027/6258c992576ce615917d5d2bfa3f925bb23de3b5/refextract.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1765, 67, 11005, 67, 6180, 67, 1369, 67, 869, 67, 3684, 71, 67, 2902, 12, 1369, 4672, 3536, 6083, 279, 5204, 2114, 980, 16, 1765, 518, 358, 490, 27206, 3167, 18, 632, 891, 980, 30, 261, 1080, 13, 300, 326, 5204, 2114, 980, 16, 316, 1492, 326, 14603, 5918, 276, 18282, 1240, 2118, 12503, 18, 632, 2463, 30, 261, 8052, 13, 300, 397, 2025, 67, 1369, 261, 1080, 13, 300, 326, 2114, 980, 598, 777, 434, 2097, 9283, 276, 18282, 9350, 731, 1368, 326, 11191, 720, 2821, 18, 397, 1056, 67, 23667, 261, 7745, 13, 300, 1300, 434, 7178, 434, 7524, 3855, 15522, 1392, 316, 326, 980, 397, 1056, 67, 2649, 261, 7745, 13, 300, 1300, 434, 2077, 17, 71, 18282, 1392, 316, 326, 980, 397, 1056, 67, 6006, 2107, 261, 7745, 13, 300, 1300, 434, 2605, 5600, 1392, 316, 326, 980, 397, 1056, 67, 718, 261, 7745, 13, 300, 1300, 434, 10414, 1392, 316, 326, 980, 3536, 1056, 67, 23667, 273, 1056, 67, 2649, 273, 1056, 67, 6006, 2107, 273, 1056, 67, 718, 273, 374, 2025, 67, 1369, 273, 1408, 7243, 67, 71, 16261, 67, 1726, 273, 599, 5204, 67, 1369, 273, 980, 18, 80, 6406, 1435, 225, 7541, 404, 18, 8152, 2114, 980, 5373, 261, 73, 18, 75, 18, 306, 21, 5717, 628, 787, 434, 980, 471, 1047, 518, 30, 7541, 336, 6884, 358, 9786, 818, 7067, 11754, 622, 326, 787, 434, 2362, 30, 5373, 67, 13317, 273, 336, 67, 6180, 67, 1369, 67, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1765, 67, 11005, 67, 6180, 67, 1369, 67, 869, 67, 3684, 71, 67, 2902, 12, 1369, 4672, 3536, 6083, 279, 5204, 2114, 980, 16, 1765, 518, 358, 490, 27206, 3167, 18, 632, 891, 980, 30, 261, 1080, 13, 300, 326, 5204, 2114, 980, 16, 316, 1492, 326, 14603, 5918, 276, 18282, 1240, 2118, 12503, 18, 632, 2463, 30, 261, 8052, 13, 300, 397, 2025, 67, 1369, 261, 1080, 13, 300, 326, 2114, 980, 598, 777, 434, 2097, 9283, 276, 18282, 9350, 731, 1368, 326, 11191, 720, 2821, 18, 397, 1056, 67, 23667, 261, 7745, 13, 300, 1300, 434, 7178, 434, 7524, 3855, 15522, 1392, 316, 326, 980, 397, 1056, 67, 2649, 261, 7745, 13, 300, 1300, 434, 2077, 2 ]
raise "could not import pylab"
raise ImportError, "could not import pylab"
def main(): parser = OptionParser( usage = usage ) parser.add_option( "-c", "--compare", action = "store_true", dest = "compare", default = False, help = "compare with default scipy.sparse solver [default: %default]" ) parser.add_option( "-p", "--plot", action = "store_true", dest = "plot", default = False, help = "plot time statistics [default: %default]" ) parser.add_option( "-d", "--default-url", action = "store_true", dest = "default_url", default = False, help = "use default url [default: %default]" ) parser.add_option( "-f", "--format", type = type( '' ), dest = "format", default = 'triplet', help = "matrix format [default: %default]" ) (options, args) = parser.parse_args() if (len( args ) >= 1): matrixNames = args; else: parser.print_help(), return sizes, nnzs, times, errors = [], [], [], [] legends = ['umfpack', 'sparse.solve'] for ii, matrixName in enumerate( matrixNames ): print '*' * 50 mtx = readMatrix( matrixName, options ) sizes.append( mtx.shape ) nnzs.append( mtx.nnz ) tts = nm.zeros( (2,), dtype = nm.double ) times.append( tts ) err = nm.zeros( (2,2), dtype = nm.double ) errors.append( err ) print 'size : %s (%d nnz)' % (mtx.shape, mtx.nnz) sol0 = nm.ones( (mtx.shape[0],), dtype = nm.double ) rhs = mtx * sol0 umfpack = um.UmfpackContext() tt = time.clock() sol = umfpack( um.UMFPACK_A, mtx, rhs, autoTranspose = True ) tts[0] = time.clock() - tt print "umfpack : %.2f s" % tts[0] error = mtx * sol - rhs err[0,0] = nla.norm( error ) print '||Ax-b|| :', err[0,0] error = sol0 - sol err[0,1] = nla.norm( error ) print '||x - x_{exact}|| :', err[0,1] if options.compare: tt = time.clock() sol = sp.solve( mtx, rhs ) tts[1] = time.clock() - tt print "sparse.solve : %.2f s" % tts[1] error = mtx * sol - rhs err[1,0] = nla.norm( error ) print '||Ax-b|| :', err[1,0] error = sol0 - sol err[1,1] = nla.norm( error ) print '||x - x_{exact}|| :', err[1,1] if options.plot: try: import pylab except ImportError: raise "could not import pylab" times = nm.array( times ) print times pylab.plot( times[:,0], 'b-o' ) if options.compare: pylab.plot( times[:,1], 'r-s' ) else: del legends[1] print legends ax = pylab.axis() y2 = 0.5 * (ax[3] - ax[2]) xrng = range( len( nnzs ) ) for ii in xrng: yy = y2 + 0.4 * (ax[3] - ax[2])\ * nm.sin( ii * 2 * nm.pi / (len( xrng ) - 1) ) if options.compare: pylab.text( ii+0.02, yy, '%s\n%.2e err_umf\n%.2e err_sp' % (sizes[ii], nm.sum( errors[ii][0,:] ), nm.sum( errors[ii][1,:] )) ) else: pylab.text( ii+0.02, yy, '%s\n%.2e err_umf' % (sizes[ii], nm.sum( errors[ii][0,:] )) ) pylab.plot( [ii, ii], [ax[2], ax[3]], 'k:' ) pylab.xticks( xrng, ['%d' % (nnzs[ii] ) for ii in xrng] ) pylab.xlabel( 'nnz' ) pylab.ylabel( 'time [s]' ) pylab.legend( legends ) pylab.axis( [ax[0] - 0.05, ax[1] + 1, ax[2], ax[3]] ) pylab.show()
cecc9fce65da8b1cada916c7bd787391a1165b6b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12971/cecc9fce65da8b1cada916c7bd787391a1165b6b/test_umfpack.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2774, 13332, 2082, 273, 18862, 12, 4084, 273, 4084, 262, 2082, 18, 1289, 67, 3482, 12, 3701, 71, 3113, 5238, 9877, 3113, 1301, 273, 315, 2233, 67, 3767, 3113, 1570, 273, 315, 9877, 3113, 805, 273, 1083, 16, 2809, 273, 315, 9877, 598, 805, 10966, 18, 17472, 12776, 306, 1886, 30, 738, 1886, 4279, 262, 2082, 18, 1289, 67, 3482, 12, 3701, 84, 3113, 5238, 4032, 3113, 1301, 273, 315, 2233, 67, 3767, 3113, 1570, 273, 315, 4032, 3113, 805, 273, 1083, 16, 2809, 273, 315, 4032, 813, 7691, 306, 1886, 30, 738, 1886, 4279, 262, 2082, 18, 1289, 67, 3482, 12, 3701, 72, 3113, 5238, 1886, 17, 718, 3113, 1301, 273, 315, 2233, 67, 3767, 3113, 1570, 273, 315, 1886, 67, 718, 3113, 805, 273, 1083, 16, 2809, 273, 315, 1202, 805, 880, 306, 1886, 30, 738, 1886, 4279, 262, 2082, 18, 1289, 67, 3482, 12, 3701, 74, 3113, 5238, 2139, 3113, 618, 273, 618, 12, 875, 262, 16, 1570, 273, 315, 2139, 3113, 805, 273, 296, 16857, 1469, 2187, 2809, 273, 315, 5667, 740, 306, 1886, 30, 738, 1886, 4279, 262, 261, 2116, 16, 833, 13, 273, 2082, 18, 2670, 67, 1968, 1435, 225, 309, 261, 1897, 12, 833, 262, 1545, 404, 4672, 3148, 1557, 273, 833, 31, 469, 30, 2082, 18, 1188, 67, 5201, 9334, 327, 225, 8453, 16, 7761, 30424, 16, 4124, 16, 1334, 273, 5378, 16, 5378, 16, 5378, 16, 5378, 4553, 5839, 273, 10228, 379, 74, 2920, 2187, 296, 17472, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2774, 13332, 2082, 273, 18862, 12, 4084, 273, 4084, 262, 2082, 18, 1289, 67, 3482, 12, 3701, 71, 3113, 5238, 9877, 3113, 1301, 273, 315, 2233, 67, 3767, 3113, 1570, 273, 315, 9877, 3113, 805, 273, 1083, 16, 2809, 273, 315, 9877, 598, 805, 10966, 18, 17472, 12776, 306, 1886, 30, 738, 1886, 4279, 262, 2082, 18, 1289, 67, 3482, 12, 3701, 84, 3113, 5238, 4032, 3113, 1301, 273, 315, 2233, 67, 3767, 3113, 1570, 273, 315, 4032, 3113, 805, 273, 1083, 16, 2809, 273, 315, 4032, 813, 7691, 306, 1886, 30, 738, 1886, 4279, 262, 2082, 18, 1289, 67, 3482, 12, 3701, 72, 3113, 5238, 1886, 17, 718, 3113, 1301, 273, 315, 2233, 67, 3767, 3113, 1570, 2 ]
assert dt - dt1 == 3000000.0, (dt, dt1)
assert dt - dt1 == 3000000.0, (dt - dt1)
def testY10KDate(self): '''Comparison of a Y10K date and a Y2K date''' dt = DateTime('10213/09/21') dt1 = DateTime(2000, 1, 1) assert dt - dt1 == 3000000.0, (dt, dt1)
d41ce08c13b2fb3bce1812416c489841c0d38031 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9658/d41ce08c13b2fb3bce1812416c489841c0d38031/testDateTime.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 61, 2163, 47, 1626, 12, 2890, 4672, 9163, 16059, 434, 279, 1624, 2163, 47, 1509, 471, 279, 1624, 22, 47, 1509, 26418, 3681, 273, 3716, 2668, 20481, 3437, 19, 5908, 19, 5340, 6134, 3681, 21, 273, 3716, 12, 17172, 16, 404, 16, 404, 13, 1815, 3681, 300, 3681, 21, 422, 890, 9449, 18, 20, 16, 261, 7510, 16, 3681, 21, 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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 61, 2163, 47, 1626, 12, 2890, 4672, 9163, 16059, 434, 279, 1624, 2163, 47, 1509, 471, 279, 1624, 22, 47, 1509, 26418, 3681, 273, 3716, 2668, 20481, 3437, 19, 5908, 19, 5340, 6134, 3681, 21, 273, 3716, 12, 17172, 16, 404, 16, 404, 13, 1815, 3681, 300, 3681, 21, 422, 890, 9449, 18, 20, 16, 261, 7510, 16, 3681, 21, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
self._preprocess(body, headers, lang)
self._preprocess(body, headers, include_dirs, lang)
def try_cpp (self, body=None, headers=None, include_dirs=None, lang="c"): """Construct a source file from 'body' (a string containing lines of C/C++ code) and 'headers' (a list of header files to include) and run it through the preprocessor. Return true if the preprocessor succeeded, false if there were any errors. ('body' probably isn't of much use, but what the heck.) """ from distutils.ccompiler import CompileError self._check_compiler() ok = 1 try: self._preprocess(body, headers, lang) except CompileError: ok = 0
57e7661ae761a48e4f9827701bb2df3fb3dc94f4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12029/57e7661ae761a48e4f9827701bb2df3fb3dc94f4/config.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 775, 67, 4057, 84, 261, 2890, 16, 1417, 33, 7036, 16, 1607, 33, 7036, 16, 2341, 67, 8291, 33, 7036, 16, 3303, 1546, 71, 6, 4672, 3536, 7249, 279, 1084, 585, 628, 296, 3432, 11, 261, 69, 533, 4191, 2362, 434, 385, 19, 39, 9904, 981, 13, 471, 296, 2485, 11, 261, 69, 666, 434, 1446, 1390, 358, 2341, 13, 471, 1086, 518, 3059, 326, 31445, 18, 225, 2000, 638, 309, 326, 31445, 15784, 16, 629, 309, 1915, 4591, 1281, 1334, 18, 7707, 3432, 11, 8656, 5177, 1404, 434, 9816, 999, 16, 1496, 4121, 326, 366, 762, 12998, 3536, 628, 2411, 5471, 18, 71, 9576, 1930, 16143, 668, 365, 6315, 1893, 67, 9576, 1435, 1529, 273, 404, 775, 30, 365, 6315, 27545, 12, 3432, 16, 1607, 16, 2341, 67, 8291, 16, 3303, 13, 1335, 16143, 668, 30, 1529, 273, 374, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 775, 67, 4057, 84, 261, 2890, 16, 1417, 33, 7036, 16, 1607, 33, 7036, 16, 2341, 67, 8291, 33, 7036, 16, 3303, 1546, 71, 6, 4672, 3536, 7249, 279, 1084, 585, 628, 296, 3432, 11, 261, 69, 533, 4191, 2362, 434, 385, 19, 39, 9904, 981, 13, 471, 296, 2485, 11, 261, 69, 666, 434, 1446, 1390, 358, 2341, 13, 471, 1086, 518, 3059, 326, 31445, 18, 225, 2000, 638, 309, 326, 31445, 15784, 16, 629, 309, 1915, 4591, 1281, 1334, 18, 7707, 3432, 11, 8656, 5177, 1404, 434, 9816, 999, 16, 1496, 4121, 326, 366, 762, 12998, 3536, 628, 2411, 5471, 18, 71, 9576, 1930, 16143, 668, 365, 6315, 1893, 67, 9576, 1435, 1529, 273, 404, 775, 2 ]
test_hooks = get_test_hooks(test_files, cfg)
test_hooks = get_test_hooks(test_files, cfg, tracer=tracer)
def main(argv): """Main program.""" # Environment if sys.version_info < (2, 3): print >> sys.stderr, '%s: need Python 2.3 or later' % argv[0] print >> sys.stderr, 'your python is %s' % sys.version return 1 # Defaults cfg = Options() cfg.basedir = os.path.join(os.path.dirname(argv[0]), 'src') cfg.basedir = os.path.abspath(cfg.basedir) # Figure out terminal size try: import curses except ImportError: pass else: try: curses.setupterm() cols = curses.tigetnum('cols') if cols > 0: cfg.screen_width = cols except curses.error: pass # Option processing opts, args = getopt.gnu_getopt(argv[1:], 'hvpqufw', ['list-files', 'list-tests', 'list-hooks', 'level=', 'all-levels', 'coverage']) for k, v in opts: if k == '-h': print __doc__ return 0 elif k == '-v': cfg.verbosity += 1 cfg.quiet = False elif k == '-p': cfg.progress = True cfg.quiet = False elif k == '-q': cfg.verbosity = 0 cfg.progress = False cfg.quiet = True elif k == '-u': cfg.unit_tests = True elif k == '-f': cfg.functional_tests = True elif k == '-w': cfg.warn_omitted = True elif k == '--list-files': cfg.list_files = True cfg.run_tests = False elif k == '--list-tests': cfg.list_tests = True cfg.run_tests = False elif k == '--list-hooks': cfg.list_hooks = True cfg.run_tests = False elif k == '--coverage': cfg.coverage = True elif k == '--level': try: cfg.level = int(v) except ValueError: print >> sys.stderr, '%s: invalid level: %s' % (argv[0], v) print >> sys.stderr, 'run %s -h for help' return 1 elif k == '--all-levels': cfg.level = None else: print >> sys.stderr, '%s: invalid option: %s' % (argv[0], k) print >> sys.stderr, 'run %s -h for help' return 1 if args: cfg.pathname_regex = args[0] if len(args) > 1: cfg.test_regex = args[1] if len(args) > 2: print >> sys.stderr, '%s: too many arguments: %s' % (argv[0], args[2]) print >> sys.stderr, 'run %s -h for help' return 1 if not cfg.unit_tests and not cfg.functional_tests: cfg.unit_tests = True # Set up the python path sys.path[0] = cfg.basedir # Finding and importing test_files = get_test_files(cfg) if cfg.list_tests or cfg.run_tests: test_cases = get_test_cases(test_files, cfg) if cfg.list_hooks or cfg.run_tests: test_hooks = get_test_hooks(test_files, cfg) # Configure the logging module import logging logging.basicConfig() logging.root.setLevel(logging.CRITICAL) # Running success = True if cfg.list_files: baselen = len(cfg.basedir) + 1 print "\n".join([fn[baselen:] for fn in test_files]) if cfg.list_tests: print "\n".join([test.id() for test in test_cases]) if cfg.list_hooks: print "\n".join([str(hook) for hook in test_hooks]) if cfg.run_tests: runner = CustomTestRunner(cfg, test_hooks) suite = unittest.TestSuite() suite.addTests(test_cases) if cfg.coverage: import trace ignoremods = ['test'] ignoredirs = [sys.prefix, sys.exec_prefix] tracer = trace.Trace(count=True, trace=False, ignoremods=ignoremods, ignoredirs=ignoredirs) success = tracer.runfunc(runner.run, suite).wasSuccessful() results = tracer.results() results.write_results(show_missing=True, coverdir=cfg.coverdir) # trace.py in Python 2.3.1 is buggy: # 1) despite sys.prefix being in ignoredirs, a lot of system-wide # modules are included in the coverage reports # 2) some module file names do not have the first two characters, # and in general the prefix used seems to be arbitrary # these bugs are fixed in src/trace.py else: success = runner.run(suite).wasSuccessful() # That's all if success: return 0 else: return 1
d17dbf391666aabed86a5c23a7a5a4545107f4ae /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/7127/d17dbf391666aabed86a5c23a7a5a4545107f4ae/test.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2774, 12, 19485, 4672, 3536, 6376, 5402, 12123, 225, 468, 7518, 309, 2589, 18, 1589, 67, 1376, 411, 261, 22, 16, 890, 4672, 1172, 1671, 2589, 18, 11241, 16, 1995, 87, 30, 1608, 6600, 576, 18, 23, 578, 5137, 11, 738, 5261, 63, 20, 65, 1172, 1671, 2589, 18, 11241, 16, 296, 93, 477, 5790, 353, 738, 87, 11, 738, 2589, 18, 1589, 327, 404, 225, 468, 14159, 2776, 273, 5087, 1435, 2776, 18, 31722, 273, 1140, 18, 803, 18, 5701, 12, 538, 18, 803, 18, 12287, 12, 19485, 63, 20, 65, 3631, 296, 4816, 6134, 2776, 18, 31722, 273, 1140, 18, 803, 18, 5113, 803, 12, 7066, 18, 31722, 13, 225, 468, 18818, 596, 8651, 963, 775, 30, 1930, 30436, 1335, 11308, 30, 1342, 469, 30, 775, 30, 30436, 18, 542, 3648, 1035, 1435, 5347, 273, 30436, 18, 88, 360, 278, 2107, 2668, 6842, 6134, 309, 5347, 405, 374, 30, 2776, 18, 9252, 67, 2819, 273, 5347, 1335, 30436, 18, 1636, 30, 1342, 225, 468, 2698, 4929, 1500, 16, 833, 273, 336, 3838, 18, 1600, 89, 67, 588, 3838, 12, 19485, 63, 21, 30, 6487, 296, 76, 20106, 372, 11966, 2187, 10228, 1098, 17, 2354, 2187, 296, 1098, 17, 16341, 2187, 296, 1098, 17, 10468, 2187, 296, 2815, 33, 2187, 296, 454, 17, 12095, 2187, 296, 16356, 19486, 364, 417, 16, 331, 316, 1500, 30, 309, 417, 422, 2400, 76, 4278, 1172, 1001, 2434, 972, 327, 374, 1327, 417, 422, 2400, 90, 4278, 2776, 18, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2774, 12, 19485, 4672, 3536, 6376, 5402, 12123, 225, 468, 7518, 309, 2589, 18, 1589, 67, 1376, 411, 261, 22, 16, 890, 4672, 1172, 1671, 2589, 18, 11241, 16, 1995, 87, 30, 1608, 6600, 576, 18, 23, 578, 5137, 11, 738, 5261, 63, 20, 65, 1172, 1671, 2589, 18, 11241, 16, 296, 93, 477, 5790, 353, 738, 87, 11, 738, 2589, 18, 1589, 327, 404, 225, 468, 14159, 2776, 273, 5087, 1435, 2776, 18, 31722, 273, 1140, 18, 803, 18, 5701, 12, 538, 18, 803, 18, 12287, 12, 19485, 63, 20, 65, 3631, 296, 4816, 6134, 2776, 18, 31722, 273, 1140, 18, 803, 18, 5113, 803, 12, 7066, 18, 31722, 13, 225, 468, 18818, 596, 8651, 963, 775, 2 ]
self._debug(NIGHTMARE, "flushbuf")
def flushbuf (self): """clear and return the output buffer""" self._debug(NIGHTMARE, "flushbuf") data = self.outbuf.getvalue() self.outbuf.close() self.outbuf = StringIO() return data
5827a6b2fdf9c1202486a8f36e257a6eab010228 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3948/5827a6b2fdf9c1202486a8f36e257a6eab010228/HtmlParser.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3663, 4385, 261, 2890, 4672, 3536, 8507, 471, 327, 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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3663, 4385, 261, 2890, 4672, 3536, 8507, 471, 327, 326, 876, 1613, 8395, 225, 501, 273, 365, 18, 659, 4385, 18, 588, 1132, 1435, 365, 18, 659, 4385, 18, 4412, 1435, 365, 18, 659, 4385, 273, 15777, 1435, 327, 501, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
updateUsedSE.append(lfnFilesIDs[lfn])
updateUsedSE.append( lfnFilesIDs[lfn] )
def setFileUsedSEForTransformation(self,transName,usedSE,lfns,connection=False): """ Set the UsedSE for supplied files and the Status = 'Processed' """ res = self._getConnectionTransID(connection,transName) if not res['OK']: return res connection = res['Value']['Connection'] transID = res['Value']['TransformationID'] res = self.setFileStatusForTransformation(transID,'Processed',lfns,connection=connection) if not res['OK']: return res resDict = res['Value'] res = self.__getFileIDsForLfns(resDict['Successful'].keys(),connection=connection) if not res['OK']: return res fileIDs,lfnFilesIDs = res['Value'] updateUsedSE = [] for lfn,message in resDict['Successful'].items(): if message == 'Status updated to Processed': updateUsedSE.append(lfnFilesIDs[lfn]) if updateUsedSE: print self.__setTransformationFileUsedSE(updateUsedSE,usedSE,connection=connection) return S_OK(resDict)
9ad007ea503b29694fc081c1646b7c5ecd07b1f2 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12864/9ad007ea503b29694fc081c1646b7c5ecd07b1f2/TransformationDB.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 19658, 6668, 1090, 1290, 15292, 12, 2890, 16, 2338, 461, 16, 3668, 1090, 16, 20850, 2387, 16, 4071, 33, 8381, 4672, 3536, 1000, 326, 10286, 1090, 364, 4580, 1390, 471, 326, 2685, 273, 296, 13533, 11, 3536, 400, 273, 365, 6315, 588, 1952, 1429, 734, 12, 4071, 16, 2338, 461, 13, 309, 486, 400, 3292, 3141, 3546, 30, 327, 400, 1459, 273, 400, 3292, 620, 21712, 1952, 3546, 906, 734, 273, 400, 3292, 620, 21712, 15292, 734, 3546, 400, 273, 365, 18, 542, 812, 1482, 1290, 15292, 12, 2338, 734, 11189, 13533, 2187, 20850, 2387, 16, 4071, 33, 4071, 13, 309, 486, 400, 3292, 3141, 3546, 30, 327, 400, 400, 5014, 273, 400, 3292, 620, 3546, 400, 273, 365, 16186, 29925, 5103, 1290, 48, 74, 2387, 12, 455, 5014, 3292, 14277, 29489, 2452, 9334, 4071, 33, 4071, 13, 309, 486, 400, 3292, 3141, 3546, 30, 327, 400, 585, 5103, 16, 80, 4293, 2697, 5103, 273, 400, 3292, 620, 3546, 1089, 6668, 1090, 273, 5378, 364, 328, 4293, 16, 2150, 316, 400, 5014, 3292, 14277, 29489, 3319, 13332, 309, 883, 422, 296, 1482, 3526, 358, 1186, 3692, 4278, 1089, 6668, 1090, 18, 6923, 12, 328, 4293, 2697, 5103, 63, 80, 4293, 65, 262, 309, 1089, 6668, 1090, 30, 1172, 365, 16186, 542, 15292, 812, 6668, 1090, 12, 2725, 6668, 1090, 16, 3668, 1090, 16, 4071, 33, 4071, 13, 327, 348, 67, 3141, 12, 455, 5014, 13, 225, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 19658, 6668, 1090, 1290, 15292, 12, 2890, 16, 2338, 461, 16, 3668, 1090, 16, 20850, 2387, 16, 4071, 33, 8381, 4672, 3536, 1000, 326, 10286, 1090, 364, 4580, 1390, 471, 326, 2685, 273, 296, 13533, 11, 3536, 400, 273, 365, 6315, 588, 1952, 1429, 734, 12, 4071, 16, 2338, 461, 13, 309, 486, 400, 3292, 3141, 3546, 30, 327, 400, 1459, 273, 400, 3292, 620, 21712, 1952, 3546, 906, 734, 273, 400, 3292, 620, 21712, 15292, 734, 3546, 400, 273, 365, 18, 542, 812, 1482, 1290, 15292, 12, 2338, 734, 11189, 13533, 2187, 20850, 2387, 16, 4071, 33, 4071, 13, 309, 486, 400, 3292, 3141, 3546, 30, 327, 400, 400, 5014, 273, 400, 3292, 620, 3546, 400, 273, 2 ]
if self.network is not None:
if self.network is not None and 'network' not in already_processed: already_processed.append('network')
def exportAttributes(self, outfile, level, namespace_='', name_='TreeAndNetworkSet'): super(TreeAndNetworkSet, self).exportAttributes(outfile, level, namespace_, name_='TreeAndNetworkSet') if self.tree is not None: outfile.write(' tree=%s' % (self.gds_format_string(quote_attrib(self.tree).encode(ExternalEncoding), input_name='tree'), )) if self.network is not None: outfile.write(' network=%s' % (self.gds_format_string(quote_attrib(self.network).encode(ExternalEncoding), input_name='network'), ))
10f2a4b3101435822c472af9b202a5a0bb496366 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/14016/10f2a4b3101435822c472af9b202a5a0bb496366/_nexml.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3359, 2498, 12, 2890, 16, 8756, 16, 1801, 16, 1981, 67, 2218, 2187, 508, 67, 2218, 2471, 1876, 3906, 694, 11, 4672, 2240, 12, 2471, 1876, 3906, 694, 16, 365, 2934, 6530, 2498, 12, 26050, 16, 1801, 16, 1981, 67, 16, 508, 67, 2218, 2471, 1876, 3906, 694, 6134, 309, 365, 18, 3413, 353, 486, 599, 30, 8756, 18, 2626, 2668, 2151, 5095, 87, 11, 738, 261, 2890, 18, 75, 2377, 67, 2139, 67, 1080, 12, 6889, 67, 14588, 12, 2890, 18, 3413, 2934, 3015, 12, 6841, 4705, 3631, 810, 67, 529, 2218, 3413, 19899, 8623, 309, 365, 18, 5185, 353, 486, 599, 471, 296, 5185, 11, 486, 316, 1818, 67, 11005, 30, 1818, 67, 11005, 18, 6923, 2668, 5185, 6134, 8756, 18, 2626, 2668, 2483, 5095, 87, 11, 738, 261, 2890, 18, 75, 2377, 67, 2139, 67, 1080, 12, 6889, 67, 14588, 12, 2890, 18, 5185, 2934, 3015, 12, 6841, 4705, 3631, 810, 67, 529, 2218, 5185, 19899, 8623, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3359, 2498, 12, 2890, 16, 8756, 16, 1801, 16, 1981, 67, 2218, 2187, 508, 67, 2218, 2471, 1876, 3906, 694, 11, 4672, 2240, 12, 2471, 1876, 3906, 694, 16, 365, 2934, 6530, 2498, 12, 26050, 16, 1801, 16, 1981, 67, 16, 508, 67, 2218, 2471, 1876, 3906, 694, 6134, 309, 365, 18, 3413, 353, 486, 599, 30, 8756, 18, 2626, 2668, 2151, 5095, 87, 11, 738, 261, 2890, 18, 75, 2377, 67, 2139, 67, 1080, 12, 6889, 67, 14588, 12, 2890, 18, 3413, 2934, 3015, 12, 6841, 4705, 3631, 810, 67, 529, 2218, 3413, 19899, 8623, 309, 365, 18, 5185, 353, 486, 599, 471, 296, 5185, 11, 486, 316, 1818, 67, 11005, 30, 1818, 67, 11005, 18, 6923, 2 ]
firstafter = 0 try: while s2[firstafter-1] == oldtext[firstafter-1]: firstafter -= 1 except IndexError: pass
firstafter = s2.find(marker) + len(marker)
def replaceLanguageLinks(oldtext, new, site = None): """Replace the interwiki language links given in the wikitext given in oldtext by the new links given in new. 'new' should be a dictionary with the language names as keys, and Page objects as values. """ if site == None: site = getSite() s = interwikiFormat(new, insite = site) s2 = removeLanguageLinks(oldtext, site = site) if s: if site.language() in site.family.interwiki_attop: newtext = s + site.family.interwiki_text_separator + s2 else: # calculate what was after the language links on the page firstafter = 0 try: while s2[firstafter-1] == oldtext[firstafter-1]: firstafter -= 1 except IndexError: pass # Is there any text in the 'after' part that means we should keep it after? if "</noinclude>" in s2[firstafter:] and firstafter < 0: newtext = s2[:firstafter] + s + s2[firstafter:] elif site.language() in site.family.categories_last: cats = getCategoryLinks(s2, site = site) s2 = removeCategoryLinks(s2, site) + site.family.interwiki_text_separator + s newtext = replaceCategoryLinks(s2, cats, site=site) else: newtext = s2 + site.family.interwiki_text_separator + s else: newtext = s2 return newtext
a6a278e6989b765ab6289378bf9f5195c3b634e1 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/4404/a6a278e6989b765ab6289378bf9f5195c3b634e1/wikipedia.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1453, 3779, 7100, 12, 1673, 955, 16, 394, 16, 2834, 273, 599, 4672, 3536, 5729, 326, 1554, 13044, 2653, 4716, 864, 316, 326, 341, 1766, 305, 408, 864, 316, 1592, 955, 635, 326, 394, 4716, 864, 316, 394, 18, 225, 296, 2704, 11, 1410, 506, 279, 3880, 598, 326, 2653, 1257, 487, 1311, 16, 471, 3460, 2184, 487, 924, 18, 3536, 309, 2834, 422, 599, 30, 2834, 273, 11021, 1435, 272, 273, 1554, 13044, 1630, 12, 2704, 16, 2763, 1137, 273, 2834, 13, 272, 22, 273, 1206, 3779, 7100, 12, 1673, 955, 16, 2834, 273, 2834, 13, 309, 272, 30, 309, 2834, 18, 4923, 1435, 316, 2834, 18, 9309, 18, 2761, 13044, 67, 270, 3669, 30, 394, 955, 273, 272, 397, 2834, 18, 9309, 18, 2761, 13044, 67, 955, 67, 11287, 397, 272, 22, 469, 30, 468, 4604, 4121, 1703, 1839, 326, 2653, 4716, 603, 326, 1363, 1122, 5205, 273, 272, 22, 18, 4720, 12, 11145, 13, 397, 562, 12, 11145, 13, 468, 2585, 1915, 1281, 977, 316, 326, 296, 5205, 11, 1087, 716, 4696, 732, 1410, 3455, 518, 1839, 35, 309, 6823, 82, 885, 1571, 2984, 316, 272, 22, 63, 3645, 5205, 26894, 471, 1122, 5205, 411, 374, 30, 394, 955, 273, 272, 22, 10531, 3645, 5205, 65, 397, 272, 397, 272, 22, 63, 3645, 5205, 26894, 1327, 2834, 18, 4923, 1435, 316, 2834, 18, 9309, 18, 8995, 67, 2722, 30, 27525, 273, 19110, 7100, 12, 87, 22, 16, 2834, 273, 2834, 13, 272, 22, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1453, 3779, 7100, 12, 1673, 955, 16, 394, 16, 2834, 273, 599, 4672, 3536, 5729, 326, 1554, 13044, 2653, 4716, 864, 316, 326, 341, 1766, 305, 408, 864, 316, 1592, 955, 635, 326, 394, 4716, 864, 316, 394, 18, 225, 296, 2704, 11, 1410, 506, 279, 3880, 598, 326, 2653, 1257, 487, 1311, 16, 471, 3460, 2184, 487, 924, 18, 3536, 309, 2834, 422, 599, 30, 2834, 273, 11021, 1435, 272, 273, 1554, 13044, 1630, 12, 2704, 16, 2763, 1137, 273, 2834, 13, 272, 22, 273, 1206, 3779, 7100, 12, 1673, 955, 16, 2834, 273, 2834, 13, 309, 272, 30, 309, 2834, 18, 4923, 1435, 316, 2834, 18, 9309, 18, 2761, 13044, 67, 270, 3669, 30, 394, 955, 2 ]
""" An in-memory filesystem. MemoryFS objects are very fast, but non-permantent. They are useful for creating a directory structure prior to writing it somewhere permanent.
"""An in-memory filesystem.
def __str__(self): return "%s: %s" % (self.name, self.desc_contents())
364bba5e2048a0bd501bc9ddbb5724d8cf8b5d3c /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/5578/364bba5e2048a0bd501bc9ddbb5724d8cf8b5d3c/memoryfs.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 701, 972, 12, 2890, 4672, 327, 2213, 87, 30, 738, 87, 6, 738, 261, 2890, 18, 529, 16, 365, 18, 5569, 67, 3980, 10756, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 701, 972, 12, 2890, 4672, 327, 2213, 87, 30, 738, 87, 6, 738, 261, 2890, 18, 529, 16, 365, 18, 5569, 67, 3980, 10756, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
sys.exit (0)
sys.exit (0)
def resolved (request): model = list (request.dns_question) if request.dns_resources == None: model.append ('') elif len (request.dns_resources) > 1: model.append (netstring.encode ( request.dns_resources )) elif request.dns_resources: model.append (request.dns_resources[0]) else: model.append ('') model.append (request.dns_peer[0]) loginfo.log (netstring.encode (model))
79906933ee4150b4a6dc21c74f2849f7ab831a23 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2577/79906933ee4150b4a6dc21c74f2849f7ab831a23/dns_client.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4640, 261, 2293, 4672, 938, 273, 666, 261, 2293, 18, 14926, 67, 4173, 13, 309, 590, 18, 14926, 67, 4683, 422, 599, 30, 938, 18, 6923, 7707, 6134, 1327, 562, 261, 2293, 18, 14926, 67, 4683, 13, 405, 404, 30, 938, 18, 6923, 261, 2758, 1080, 18, 3015, 261, 590, 18, 14926, 67, 4683, 8623, 1327, 590, 18, 14926, 67, 4683, 30, 938, 18, 6923, 261, 2293, 18, 14926, 67, 4683, 63, 20, 5717, 469, 30, 938, 18, 6923, 7707, 6134, 938, 18, 6923, 261, 2293, 18, 14926, 67, 12210, 63, 20, 5717, 613, 1376, 18, 1330, 261, 2758, 1080, 18, 3015, 261, 2284, 3719, 225, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4640, 261, 2293, 4672, 938, 273, 666, 261, 2293, 18, 14926, 67, 4173, 13, 309, 590, 18, 14926, 67, 4683, 422, 599, 30, 938, 18, 6923, 7707, 6134, 1327, 562, 261, 2293, 18, 14926, 67, 4683, 13, 405, 404, 30, 938, 18, 6923, 261, 2758, 1080, 18, 3015, 261, 590, 18, 14926, 67, 4683, 8623, 1327, 590, 18, 14926, 67, 4683, 30, 938, 18, 6923, 261, 2293, 18, 14926, 67, 4683, 63, 20, 5717, 469, 30, 938, 18, 6923, 7707, 6134, 938, 18, 6923, 261, 2293, 18, 14926, 67, 12210, 63, 20, 5717, 613, 1376, 18, 1330, 261, 2758, 1080, 18, 3015, 261, 2284, 3719, 225, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
if line.startswith("/me"):
if line.startswith("* "):
def _append(buffer, text, tag): iter = buffer.get_end_iter() if tag is not None: buffer.insert_with_tags(iter, text, tag) else: buffer.insert(iter, text)
4cc26d5df3e4c1fe20b6e8a1191c259119492ee0 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/8738/4cc26d5df3e4c1fe20b6e8a1191c259119492ee0/utils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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 6923, 12, 4106, 16, 977, 16, 1047, 4672, 1400, 273, 1613, 18, 588, 67, 409, 67, 2165, 1435, 309, 1047, 353, 486, 599, 30, 1613, 18, 6387, 67, 1918, 67, 4156, 12, 2165, 16, 977, 16, 1047, 13, 469, 30, 1613, 18, 6387, 12, 2165, 16, 977, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
license = "Commercial", license = "GPL",
def run (self): res = build_scripts.run(self) for script in self.scripts: filename = os.path.basename(script) if filename.endswith('.py'): path = os.path.join(self.build_dir, filename) print 'renaming %s -> %s' % (path, path[:-3]) os.rename(path, path[:-3])
fc2df9ebcf81f75b17d6436529dfbc3ae583cc03 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/3449/fc2df9ebcf81f75b17d6436529dfbc3ae583cc03/setup.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1086, 261, 2890, 4672, 400, 273, 1361, 67, 12827, 18, 2681, 12, 2890, 13, 364, 2728, 316, 365, 18, 12827, 30, 1544, 273, 1140, 18, 803, 18, 13909, 12, 4263, 13, 309, 1544, 18, 5839, 1918, 2668, 18, 2074, 11, 4672, 589, 273, 1140, 18, 803, 18, 5701, 12, 2890, 18, 3510, 67, 1214, 16, 1544, 13, 1172, 296, 1187, 7772, 738, 87, 317, 738, 87, 11, 738, 261, 803, 16, 589, 10531, 17, 23, 5717, 1140, 18, 18539, 12, 803, 16, 589, 10531, 17, 23, 5717, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1086, 261, 2890, 4672, 400, 273, 1361, 67, 12827, 18, 2681, 12, 2890, 13, 364, 2728, 316, 365, 18, 12827, 30, 1544, 273, 1140, 18, 803, 18, 13909, 12, 4263, 13, 309, 1544, 18, 5839, 1918, 2668, 18, 2074, 11, 4672, 589, 273, 1140, 18, 803, 18, 5701, 12, 2890, 18, 3510, 67, 1214, 16, 1544, 13, 1172, 296, 1187, 7772, 738, 87, 317, 738, 87, 11, 738, 261, 803, 16, 589, 10531, 17, 23, 5717, 1140, 18, 18539, 12, 803, 16, 589, 10531, 17, 23, 5717, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
except AttributeError: return ln(x) / ln(base)
except (AttributeError, TypeError): return log(x) / log(base)
def log(x, base=None): """ Return the logarithm of x to the given base. Calls the ``log`` method of the object x when computing the logarithm, thus allowing use of logarithm on any object containing a ``log`` method. In other words, log works on more than just real numbers. EXAMPLES:: sage: log(e^2) 2 sage: log(1024, 2); RDF(log(1024, 2)) 10 10.0 sage: log(10, 4); RDF(log(10, 4)) log(10)/log(4) 1.66096404744 :: sage: log(10, 2) log(10)/log(2) sage: n(log(10, 2)) 3.32192809488736 sage: log(10, e) log(10) sage: n(log(10, e)) 2.30258509299405 The log function works for negative numbers, complex numbers, and symbolic numbers too, picking the branch with angle between `-pi` and `pi`:: sage: log(-1+0*I) I*pi sage: log(CC(-1)) 3.14159265358979*I sage: log(-1.0) 3.14159265358979*I For input zero, the following behavior occurs:: sage: log(0) -Infinity sage: log(CC(0)) -infinity sage: log(0.0) -infinity The log function also works in finite fields as long as the base is generator of the multiplicative group:: sage: F = GF(13); g = F.multiplicative_generator(); g 2 sage: a = F(8) sage: log(a,g); g^log(a,g) 3 8 sage: log(a,3) Traceback (most recent call last): ... ValueError: base (=3) for discrete log must generate multiplicative group The log function also works for p-adics (see documentation for p-adics for more information):: sage: R = Zp(5); R 5-adic Ring with capped relative precision 20 sage: a = R(16); a 1 + 3*5 + O(5^20) sage: log(a) 3*5 + 3*5^2 + 3*5^4 + 3*5^5 + 3*5^6 + 4*5^7 + 2*5^8 + 5^9 + 5^11 + 2*5^12 + 5^13 + 3*5^15 + 2*5^16 + 4*5^17 + 3*5^18 + 3*5^19 + O(5^20) """ if base is None: try: return x.log() except AttributeError: return ln(x) else: try: return x.log(base) except AttributeError: return ln(x) / ln(base)
ba84b82b30350f19e34aeb09e240c292fef9d64d /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9890/ba84b82b30350f19e34aeb09e240c292fef9d64d/log.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 613, 12, 92, 16, 1026, 33, 7036, 4672, 3536, 2000, 326, 613, 31249, 434, 619, 358, 326, 864, 1026, 18, 225, 23665, 326, 12176, 1330, 10335, 707, 434, 326, 733, 619, 1347, 20303, 326, 613, 31249, 16, 12493, 15632, 999, 434, 613, 31249, 603, 1281, 733, 4191, 279, 12176, 1330, 10335, 707, 18, 657, 1308, 4511, 16, 613, 6330, 603, 1898, 2353, 2537, 2863, 5600, 18, 225, 5675, 8900, 11386, 2866, 225, 272, 410, 30, 613, 12, 73, 66, 22, 13, 576, 272, 410, 30, 613, 12, 2163, 3247, 16, 576, 1769, 13539, 12, 1330, 12, 2163, 3247, 16, 576, 3719, 1728, 1728, 18, 20, 272, 410, 30, 613, 12, 2163, 16, 1059, 1769, 13539, 12, 1330, 12, 2163, 16, 1059, 3719, 613, 12, 2163, 13176, 1330, 12, 24, 13, 404, 18, 26, 4848, 29, 1105, 3028, 5608, 24, 225, 493, 225, 272, 410, 30, 613, 12, 2163, 16, 576, 13, 613, 12, 2163, 13176, 1330, 12, 22, 13, 272, 410, 30, 290, 12, 1330, 12, 2163, 16, 576, 3719, 890, 18, 1578, 15561, 3672, 11290, 5482, 27, 5718, 272, 410, 30, 613, 12, 2163, 16, 425, 13, 613, 12, 2163, 13, 272, 410, 30, 290, 12, 1330, 12, 2163, 16, 425, 3719, 576, 18, 5082, 2947, 28, 5995, 22, 2733, 24, 6260, 225, 1021, 613, 445, 6330, 364, 6092, 5600, 16, 7233, 5600, 16, 471, 16754, 5600, 4885, 16, 6002, 310, 326, 3803, 598, 5291, 3086, 1375, 17, 7259, 68, 471, 1375, 7259, 68, 2866, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 613, 12, 92, 16, 1026, 33, 7036, 4672, 3536, 2000, 326, 613, 31249, 434, 619, 358, 326, 864, 1026, 18, 225, 23665, 326, 12176, 1330, 10335, 707, 434, 326, 733, 619, 1347, 20303, 326, 613, 31249, 16, 12493, 15632, 999, 434, 613, 31249, 603, 1281, 733, 4191, 279, 12176, 1330, 10335, 707, 18, 657, 1308, 4511, 16, 613, 6330, 603, 1898, 2353, 2537, 2863, 5600, 18, 225, 5675, 8900, 11386, 2866, 225, 272, 410, 30, 613, 12, 73, 66, 22, 13, 576, 272, 410, 30, 613, 12, 2163, 3247, 16, 576, 1769, 13539, 12, 1330, 12, 2163, 3247, 16, 576, 3719, 1728, 1728, 18, 20, 272, 410, 30, 613, 12, 2163, 16, 1059, 1769, 13539, 12, 1330, 12, 2 ]
unittest.TextTestRunner().run(makeSuite())
if '-debug' in sys.argv: run() else: unittest.TextTestRunner().run(makeSuite())
def makeSuite(): suite = unittest.TestSuite() suite.addTest(PlatypusTestCase('test1')) return suite
d4416166c810994c9fddb52037b50adb50274eaf /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/7053/d4416166c810994c9fddb52037b50adb50274eaf/test_platypus_general.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1221, 13587, 13332, 11371, 273, 2836, 3813, 18, 4709, 13587, 1435, 11371, 18, 1289, 4709, 12, 1749, 270, 879, 407, 4709, 2449, 2668, 3813, 21, 26112, 327, 11371, 282, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1221, 13587, 13332, 11371, 273, 2836, 3813, 18, 4709, 13587, 1435, 11371, 18, 1289, 4709, 12, 1749, 270, 879, 407, 4709, 2449, 2668, 3813, 21, 26112, 327, 11371, 282, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
raise ValueError, "file is closed"
raise ValueError("file is closed")
def _readsparse(self, size=None): """Read operation for sparse files. """ if self.closed: raise ValueError, "file is closed"
9d576e732e0c14bd37ecb65d8001d6f596cc8566 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3187/9d576e732e0c14bd37ecb65d8001d6f596cc8566/tarfile.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 11904, 2670, 12, 2890, 16, 963, 33, 7036, 4672, 3536, 1994, 1674, 364, 9387, 1390, 18, 3536, 309, 365, 18, 12204, 30, 1002, 2068, 16, 315, 768, 353, 4375, 6, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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18, 3536, 309, 365, 18, 12204, 30, 1002, 2068, 16, 315, 768, 353, 4375, 6, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
app.Control_Panel.initialize_cache()
def initialize(app): # Initialize the application # Initialize the cache: app.Control_Panel.initialize_cache() # The following items marked b/c are backward compatibility hacks # which make sure that expected system objects are added to the # bobobase. This is required because the bobobase in use may pre- # date the introduction of certain system objects such as those # which provide Lever support. # b/c: Ensure that Control Panel exists. if not hasattr(app, 'Control_Panel'): cpl=ApplicationManager() cpl._init() app._setObject('Control_Panel', cpl) get_transaction().note('Added Control_Panel') get_transaction().commit() # b/c: Ensure that a ProductFolder exists. if not hasattr(app.Control_Panel.aq_base, 'Products'): app.Control_Panel.Products=App.Product.ProductFolder() get_transaction().note('Added Control_Panel.Products') get_transaction().commit() # Ensure that a temp folder exists if not hasattr(app, 'temp_folder'): from Products.TemporaryFolder.TemporaryFolder import \ MountedTemporaryFolder tf = MountedTemporaryFolder('temp_folder','Temporary Folder') app._setObject('temp_folder', tf) get_transaction().note('Added temp_folder') get_transaction().commit() del tf # Ensure that there is a transient container in the temp folder tf = app.temp_folder if not hasattr(tf, 'session_data'): env_has = os.environ.get from Products.Transience.Transience import TransientObjectContainer addnotify = env_has('ZSESSION_ADD_NOTIFY', None) delnotify = env_has('ZSESSION_DEL_NOTIFY', None) default_limit = 1000 limit = env_has('ZSESSION_OBJECT_LIMIT', default_limit) try: limit=int(limit) if limit != default_limit: LOG('Zope Default Object Creation', INFO, ('using ZSESSION_OBJECT_LIMIT-specified max objects ' 'value of %s' % limit)) except ValueError: LOG('Zope Default Object Creation', WARNING, ('Noninteger value %s specified for ZSESSION_OBJECT_LIMIT, ' 'defaulting to %s' % (limit, default_limit))) limit = default_limit if addnotify and app.unrestrictedTraverse(addnotify, None) is None: LOG('Zope Default Object Creation', WARNING, ('failed to use nonexistent "%s" script as ' 'ZSESSION_ADD_NOTIFY' % addnotify)) addnotify=None elif addnotify: LOG('Zope Default Object Creation', INFO, 'using %s as add notification script' % addnotify) if delnotify and app.unrestrictedTraverse(delnotify, None) is None: LOG('Zope Default Object Creation', WARNING, ('failed to use nonexistent "%s" script as ' 'ZSESSION_DEL_NOTIFY' % delnotify)) delnotify=None elif delnotify: LOG('Zope Default Object Creation', INFO, 'using %s as delete notification script' % delnotify) toc = TransientObjectContainer('session_data', 'Session Data Container', addNotification = addnotify, delNotification = delnotify, limit=limit) timeout_spec = env_has('ZSESSION_TIMEOUT_MINS', '') if timeout_spec: try: timeout_spec = int(timeout_spec) except ValueError: LOG('Zope Default Object Creation', WARNING, ('"%s" is an illegal value for ZSESSION_TIMEOUT_MINS, ' 'using default timeout instead.' % timeout_spec)) else: LOG('Zope Default Object Creation', INFO, ('using ZSESSION_TIMEOUT_MINS-specified session timeout ' 'value of %s' % timeout_spec)) toc = TransientObjectContainer('session_data', 'Session Data Container', timeout_mins = timeout_spec, addNotification=addnotify, delNotification = delnotify, limit=limit) tf._setObject('session_data', toc) tf_reserved = getattr(tf, '_reserved_names', ()) if 'session_data' not in tf_reserved: tf._reserved_names = tf_reserved + ('session_data',) get_transaction().note('Added session_data to temp_folder') get_transaction().commit() del toc del addnotify del delnotify del timeout_spec del env_has del tf # Ensure that a browser ID manager exists if not hasattr(app, 'browser_id_manager'): from Products.Sessions.BrowserIdManager import BrowserIdManager bid = BrowserIdManager('browser_id_manager', 'Browser Id Manager') app._setObject('browser_id_manager', bid) get_transaction().note('Added browser_id_manager') get_transaction().commit() del bid # Ensure that a session data manager exists if not hasattr(app, 'session_data_manager'): from Products.Sessions.SessionDataManager import SessionDataManager sdm = SessionDataManager('session_data_manager', title='Session Data Manager', path='/temp_folder/session_data', requestName='SESSION') app._setObject('session_data_manager', sdm) get_transaction().note('Added session_data_manager') get_transaction().commit() del sdm # Ensure that there's an Examples folder with examples. # However, make sure that if the examples have been added already # and then deleted that we don't add them again. if not hasattr(app, 'Examples') and not \ hasattr(app, '_Zope25_examples_have_been_added'): examples_path = os.path.join(Globals.SOFTWARE_HOME, \ '..','..','import', 'Examples.zexp') if os.path.isfile(examples_path): app._importObjectFromFile(examples_path, verify=0) app._Zope25_examples_have_been_added=1 get_transaction().note('Added Examples folder') get_transaction().commit() else: LOG('Zope Default Object Creation', INFO, '%s examples import file could not be found.' % examples_path) # b/c: Ensure that Owner role exists. if hasattr(app, '__ac_roles__') and not ('Owner' in app.__ac_roles__): app.__ac_roles__=app.__ac_roles__ + ('Owner',) get_transaction().note('Added Owner role') get_transaction().commit() # ensure the Authenticated role exists. if hasattr(app, '__ac_roles__'): if not 'Authenticated' in app.__ac_roles__: app.__ac_roles__=app.__ac_roles__ + ('Authenticated',) get_transaction().note('Added Authenticated role') get_transaction().commit() # Make sure we have Globals root=app._p_jar.root() if not root.has_key('ZGlobals'): import BTree app._p_jar.root()['ZGlobals']=BTree.BTree() get_transaction().note('Added Globals') get_transaction().commit() # Install the initial user. if hasattr(app, 'acl_users'): users = app.acl_users if hasattr(users, '_createInitialUser'): app.acl_users._createInitialUser() get_transaction().note('Created initial user') get_transaction().commit() install_products(app) install_standards(app) # Note that the code from here on only runs if we are not a ZEO # client, or if we are a ZEO client and we've specified by way # of env variable that we want to force products to load. if (os.environ.get('ZEO_CLIENT') and not os.environ.get('FORCE_PRODUCT_LOAD')): return # Check for dangling pointers (broken zclass dependencies) in the # global class registry. If found, rebuild the registry. Note that # if the check finds problems but fails to successfully rebuild the # registry we abort the transaction so that we don't leave it in an # indeterminate state. did_fixups=0 bad_things=0 try: if app.checkGlobalRegistry(): LOG('Zope', INFO, 'Beginning attempt to rebuild the global ZClass registry.') app.fixupZClassDependencies(rebuild=1) did_fixups=1 LOG('Zope', INFO, 'The global ZClass registry has successfully been rebuilt.') get_transaction().note('Rebuilt global product registry') get_transaction().commit() except: bad_things=1 LOG('Zope', ERROR, 'The attempt to rebuild the registry failed.', error=sys.exc_info()) get_transaction().abort() # Now we need to see if any (disk-based) products were installed # during intialization. If so (and the registry has no errors), # there may still be zclasses dependent on a base class in the # newly installed product that were previously broken and need to # be fixed up. If any really Bad Things happened (dangling pointers # were found in the registry but it couldn't be rebuilt), we don't # try to do anything to avoid making the problem worse. if (not did_fixups) and (not bad_things): # App.Product.initializeProduct will set this if a disk-based # product was added or updated and we are not a ZEO client. if getattr(Globals, '__disk_product_installed__', 0): try: LOG('Zope', INFO, 'New disk product detected, determining '\ 'if we need to fix up any ZClasses.') if app.fixupZClassDependencies(): LOG('Zope', INFO, 'Repaired broken ZClass dependencies.') get_transaction().commit() except: LOG('Zope', ERROR, 'Attempt to fixup ZClass dependencies after detecting ' \ 'an updated disk-based product failed.', error=sys.exc_info()) get_transaction().abort()
46b57e43ac861f750a8afcf7711068b942d66d2d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9658/46b57e43ac861f750a8afcf7711068b942d66d2d/Application.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4046, 12, 2910, 4672, 468, 9190, 326, 2521, 225, 468, 9190, 326, 1247, 27363, 1021, 3751, 1516, 9350, 324, 19, 71, 854, 12555, 8926, 11769, 87, 468, 1492, 1221, 3071, 716, 2665, 2619, 2184, 854, 3096, 358, 326, 468, 800, 70, 947, 448, 18, 1220, 353, 1931, 2724, 326, 800, 70, 947, 448, 316, 999, 2026, 675, 17, 468, 1509, 326, 16658, 349, 434, 8626, 2619, 2184, 4123, 487, 5348, 468, 1492, 5615, 3519, 502, 2865, 18, 225, 468, 324, 19, 71, 30, 7693, 716, 8888, 23641, 1704, 18, 309, 486, 3859, 12, 2910, 16, 296, 3367, 67, 5537, 11, 4672, 276, 412, 33, 3208, 1318, 1435, 276, 412, 6315, 2738, 1435, 595, 6315, 542, 921, 2668, 3367, 67, 5537, 2187, 276, 412, 13, 336, 67, 7958, 7675, 7652, 2668, 8602, 8888, 67, 5537, 6134, 336, 67, 7958, 7675, 7371, 1435, 225, 468, 324, 19, 71, 30, 7693, 716, 279, 8094, 3899, 1704, 18, 309, 486, 3859, 12, 2910, 18, 3367, 67, 5537, 18, 69, 85, 67, 1969, 16, 296, 13344, 11, 4672, 595, 18, 3367, 67, 5537, 18, 13344, 33, 3371, 18, 4133, 18, 4133, 3899, 1435, 336, 67, 7958, 7675, 7652, 2668, 8602, 8888, 67, 5537, 18, 13344, 6134, 336, 67, 7958, 7675, 7371, 1435, 225, 468, 7693, 716, 279, 1906, 3009, 1704, 309, 486, 3859, 12, 2910, 16, 296, 5814, 67, 5609, 11, 4672, 628, 8094, 87, 18, 11685, 3899, 18, 11685, 3899, 1930, 521, 13076, 329, 11685, 3899, 3253, 273, 13076, 329, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4046, 12, 2910, 4672, 468, 9190, 326, 2521, 225, 468, 9190, 326, 1247, 27363, 1021, 3751, 1516, 9350, 324, 19, 71, 854, 12555, 8926, 11769, 87, 468, 1492, 1221, 3071, 716, 2665, 2619, 2184, 854, 3096, 358, 326, 468, 800, 70, 947, 448, 18, 1220, 353, 1931, 2724, 326, 800, 70, 947, 448, 316, 999, 2026, 675, 17, 468, 1509, 326, 16658, 349, 434, 8626, 2619, 2184, 4123, 487, 5348, 468, 1492, 5615, 3519, 502, 2865, 18, 225, 468, 324, 19, 71, 30, 7693, 716, 8888, 23641, 1704, 18, 309, 486, 3859, 12, 2910, 16, 296, 3367, 67, 5537, 11, 4672, 276, 412, 33, 3208, 1318, 1435, 276, 412, 6315, 2738, 1435, 595, 6315, 542, 921, 2668, 3367, 2 ]
x = self._padx / 2 + pos_x * self._col_size -self._curx y = self._pady / 2 + pos_y * self._row_size -self._cury
x = pos_x * self._col_size -self._x0 y = pos_y * self._row_size -self._y0
def _render_child(self, item_num, pos_x, pos_y): """ Render one child """ if item_num < 0 or item_num >= len(self._items): self._rendered[(pos_x, pos_y)] = None return x = self._padx / 2 + pos_x * self._col_size -self._curx y = self._pady / 2 + pos_y * self._row_size -self._cury context = copy.copy(self.get_context()) context[self._cell_item] = self._items[item_num] child = self._child_template(x=x, y=y, size=self.cell_size, context=context) child.set_parent(self) self._rendered[(pos_x, pos_y)] = child
7b14a2b208acc2ce1dd643af75f0c785a0bc8172 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/11702/7b14a2b208acc2ce1dd643af75f0c785a0bc8172/grid.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 5902, 67, 3624, 12, 2890, 16, 761, 67, 2107, 16, 949, 67, 92, 16, 949, 67, 93, 4672, 3536, 6987, 1245, 1151, 3536, 309, 761, 67, 2107, 411, 374, 578, 761, 67, 2107, 1545, 562, 12, 2890, 6315, 3319, 4672, 365, 6315, 26332, 63, 12, 917, 67, 92, 16, 949, 67, 93, 25887, 273, 599, 327, 619, 273, 949, 67, 92, 380, 365, 6315, 1293, 67, 1467, 300, 2890, 6315, 92, 20, 677, 273, 949, 67, 93, 380, 365, 6315, 492, 67, 1467, 300, 2890, 6315, 93, 20, 819, 273, 1610, 18, 3530, 12, 2890, 18, 588, 67, 2472, 10756, 819, 63, 2890, 6315, 3855, 67, 1726, 65, 273, 365, 6315, 3319, 63, 1726, 67, 2107, 65, 1151, 273, 365, 6315, 3624, 67, 3202, 12, 92, 33, 92, 16, 677, 33, 93, 16, 963, 33, 2890, 18, 3855, 67, 1467, 16, 819, 33, 2472, 13, 1151, 18, 542, 67, 2938, 12, 2890, 13, 365, 6315, 26332, 63, 12, 917, 67, 92, 16, 949, 67, 93, 25887, 273, 1151, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 5902, 67, 3624, 12, 2890, 16, 761, 67, 2107, 16, 949, 67, 92, 16, 949, 67, 93, 4672, 3536, 6987, 1245, 1151, 3536, 309, 761, 67, 2107, 411, 374, 578, 761, 67, 2107, 1545, 562, 12, 2890, 6315, 3319, 4672, 365, 6315, 26332, 63, 12, 917, 67, 92, 16, 949, 67, 93, 25887, 273, 599, 327, 619, 273, 949, 67, 92, 380, 365, 6315, 1293, 67, 1467, 300, 2890, 6315, 92, 20, 677, 273, 949, 67, 93, 380, 365, 6315, 492, 67, 1467, 300, 2890, 6315, 93, 20, 819, 273, 1610, 18, 3530, 12, 2890, 18, 588, 67, 2472, 10756, 819, 63, 2890, 6315, 3855, 67, 1726, 65, 273, 365, 6315, 3319, 63, 1726, 67, 2107, 65, 2 ]
location_id='', channel_id='EHE', phase='P',
location_id='', channel_id='EHZ', phase='P',
def xcorrEvents(starttime, endtime, network_id='*', station_id='*', location_id='', channel_id='EHE', phase='P', time_window=(-1, 6), winlen=10.0): """ """ # get all events between start and end time client = Client("http://admin:admin@teide.geophysik.uni-muenchen.de:8080") event_list = client.event.getList(datetime=(starttime, endtime), localisation_method='manual') print "Fetching events ..." networks = {} for event in event_list: id = event['resource_name'] print " EVENT:", str(event['datetime']), id # request event resource res = client.event.getXMLResource(id) # fetch all picks with given phase pick_list = res.xpath("/event/pick[phaseHint='%s']" % phase) # cycle through picks streams = [] for pick in pick_list: temp = {} # XXX: ignoring location code for now try: dt = UTCDateTime(str(pick.time.value)) except: continue sid = pick.waveform.attrib['stationCode'] nid = pick.waveform.attrib['networkCode'] or 'BW' cid = pick.waveform.attrib['channelCode'] lid = pick.waveform.attrib['locationCode'] print " PICK: %s.%s.%s.%s - %s - %s" % (nid, sid, lid, cid, phase, dt) # generate station/network list networks.setdefault(nid, {}) networks[nid].setdefault(sid, []) networks[nid][sid].append((event, dt)) print print "Correlate events over each station ..." # cycle through all networks/stations/events for nid, stations in networks.iteritems(): for sid, events in stations.iteritems(): print " %s.%s:" % (nid, sid) if len(events) < 2: print " -> Skipping: Need at least 2 events per station" print continue streams = [] for event in events: id = event[0]['resource_name'] dt = event[1] # get station PAZ for this date time paz = client.station.getPAZ(nid, sid, dt, location_id, channel_id) if not paz: print "!!! Missing PAZ for %s.%s for %s" % (nid, sid, dt) continue # get waveforms try: stream = client.waveform.getWaveform(nid, sid, location_id, channel_id, dt + time_window[0], dt + time_window[1]) except: msg = "!!! Error fetching waveform for %s.%s.%s.%s for %s" print msg % (nid, sid, location_id, channel_id, dt) continue # trim to time window stream.trim(dt + time_window[0], dt + time_window[1]) for trace in stream: # calculate zero mean trace.data = trace.data - trace.data.mean() # instrument correction trace.data = seisSim(trace.data, trace.stats.sampling_rate, paz, inst_sim=None, water_level=50.0) print ' Got Trace:', trace # append streams.append((id, stream)) # cross correlation over all prepared streams l = len(streams) if l < 2: print " -> Skipping: Need at least 2 events per station" print fp.close() continue # output file filename = "%s.%s.txt" % (nid, sid) fp = open(filename, "w") #print "XCORR:" for i in range(0, l - 1): id1 = streams[i][0] tr1 = streams[i][1][0] for j in range(i + 1, l): id2 = streams[j][0] tr2 = streams[j][1][0] #print ' ' , i, ' x ', j, ' = ', # check sampling rate for both traces if tr1.stats.sampling_rate != tr2.stats.sampling_rate: print print "!!! Sampling rate are not equal!" fp.close() continue if tr1.stats.npts != tr2.stats.npts: print print "!!! Number of samples are not equal!" fp.close() continue # divide by 2.0 as in eventcluster.c line 604 winlen = int(winlen / float(tr1.stats.sampling_rate) / 2.0) shift, coe = xcorr(tr1.data.astype('float32'), tr2.data.astype('float32'), winlen) fp.write("%d %d % .3f %d %s %s\n" % (i + 1, j + 1, coe, shift, id1, id2)) print fp.close()
c74c4adfcca12112b384a200797a406509801751 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/10470/c74c4adfcca12112b384a200797a406509801751/eventcluster.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 619, 17515, 3783, 12, 1937, 957, 16, 31361, 16, 2483, 67, 350, 2218, 14, 2187, 13282, 67, 350, 2218, 14, 2187, 2117, 67, 350, 2218, 2187, 1904, 67, 350, 2218, 41, 44, 62, 2187, 6855, 2218, 52, 2187, 813, 67, 5668, 33, 19236, 21, 16, 1666, 3631, 5657, 1897, 33, 2163, 18, 20, 4672, 3536, 3536, 468, 336, 777, 2641, 3086, 787, 471, 679, 813, 1004, 273, 2445, 2932, 2505, 2207, 3666, 30, 3666, 36, 736, 831, 18, 908, 23169, 1900, 1766, 18, 318, 77, 17, 13297, 7382, 275, 18, 323, 30, 3672, 3672, 7923, 871, 67, 1098, 273, 1004, 18, 2575, 18, 588, 682, 12, 6585, 28657, 1937, 957, 16, 31361, 3631, 1191, 10742, 67, 2039, 2218, 19840, 6134, 225, 1172, 315, 30806, 2641, 18483, 13884, 273, 2618, 364, 871, 316, 871, 67, 1098, 30, 612, 273, 871, 3292, 3146, 67, 529, 3546, 1172, 315, 225, 9964, 2773, 16, 609, 12, 2575, 3292, 6585, 3546, 3631, 612, 468, 590, 871, 1058, 400, 273, 1004, 18, 2575, 18, 588, 4201, 1420, 12, 350, 13, 468, 2158, 777, 6002, 87, 598, 864, 6855, 6002, 67, 1098, 273, 400, 18, 18644, 2932, 19, 2575, 19, 11503, 63, 13961, 7002, 28713, 87, 31867, 738, 6855, 13, 468, 8589, 3059, 6002, 87, 8205, 273, 5378, 364, 6002, 316, 6002, 67, 1098, 30, 1906, 273, 2618, 468, 11329, 30, 14398, 2117, 981, 364, 2037, 775, 30, 3681, 273, 9951, 5096, 12, 701, 12, 11503, 18, 957, 18, 1132, 3719, 1335, 30, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 619, 17515, 3783, 12, 1937, 957, 16, 31361, 16, 2483, 67, 350, 2218, 14, 2187, 13282, 67, 350, 2218, 14, 2187, 2117, 67, 350, 2218, 2187, 1904, 67, 350, 2218, 41, 44, 62, 2187, 6855, 2218, 52, 2187, 813, 67, 5668, 33, 19236, 21, 16, 1666, 3631, 5657, 1897, 33, 2163, 18, 20, 4672, 3536, 3536, 468, 336, 777, 2641, 3086, 787, 471, 679, 813, 1004, 273, 2445, 2932, 2505, 2207, 3666, 30, 3666, 36, 736, 831, 18, 908, 23169, 1900, 1766, 18, 318, 77, 17, 13297, 7382, 275, 18, 323, 30, 3672, 3672, 7923, 871, 67, 1098, 273, 1004, 18, 2575, 18, 588, 682, 12, 6585, 28657, 1937, 957, 16, 31361, 3631, 1191, 10742, 67, 2039, 2218, 2 ]
[[1.1892071150027208 .. 1.1892071150027213], [-1.1892071150027213 .. -1.1892071150027208], [1.1892071150027208 .. 1.1892071150027213]*I, [-1.1892071150027213 .. -1.1892071150027208]*I]
[[1.1892071150027208 .. 1.1892071150027213], [-1.1892071150027213 .. -1.18920711500272...], [1.1892071150027208 .. 1.1892071150027213]*I, [-1.1892071150027213 .. -1.1892071150027208]*I]
def complex_roots(self, prec, multiplicity): """ EXAMPLES: sage: x = polygen(ZZ) sage: cp = AA.common_polynomial(x^4 - 2) sage: cp.complex_roots(30, 1) [[1.1892071150027208 .. 1.1892071150027213], [-1.1892071150027213 .. -1.1892071150027208], [1.1892071150027208 .. 1.1892071150027213]*I, [-1.1892071150027213 .. -1.1892071150027208]*I] """ if self._roots_cache.has_key(multiplicity): roots = self._roots_cache[multiplicity] if roots[0] >= prec: return roots[1]
3a112463dd73fe17c9981e7c7a7e1a276b6d47ec /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9890/3a112463dd73fe17c9981e7c7a7e1a276b6d47ec/qqbar.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 7233, 67, 22078, 12, 2890, 16, 13382, 16, 3309, 20458, 4672, 3536, 5675, 8900, 11386, 30, 272, 410, 30, 619, 273, 2952, 4338, 275, 12, 27096, 13, 272, 410, 30, 3283, 273, 27343, 18, 6054, 67, 3915, 13602, 12, 92, 66, 24, 300, 576, 13, 272, 410, 30, 3283, 18, 14259, 67, 22078, 12, 5082, 16, 404, 13, 12167, 21, 18, 29426, 3462, 27, 2499, 12483, 5324, 26825, 6116, 404, 18, 29426, 3462, 27, 2499, 12483, 5324, 22, 3437, 6487, 23059, 21, 18, 29426, 3462, 27, 2499, 12483, 5324, 22, 3437, 6116, 300, 21, 18, 29426, 3462, 27, 2499, 12483, 5324, 22, 2777, 6487, 306, 21, 18, 29426, 3462, 27, 2499, 12483, 5324, 26825, 6116, 404, 18, 29426, 3462, 27, 2499, 12483, 5324, 22, 3437, 5772, 45, 16, 23059, 21, 18, 29426, 3462, 27, 2499, 12483, 5324, 22, 3437, 6116, 300, 21, 18, 29426, 3462, 27, 2499, 12483, 5324, 26825, 5772, 45, 65, 3536, 309, 365, 6315, 22078, 67, 2493, 18, 5332, 67, 856, 12, 7027, 20458, 4672, 12876, 273, 365, 6315, 22078, 67, 2493, 63, 7027, 20458, 65, 309, 12876, 63, 20, 65, 1545, 13382, 30, 327, 12876, 63, 21, 65, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 3283, 18, 14259, 67, 22078, 12, 5082, 16, 404, 13, 12167, 21, 18, 29426, 3462, 27, 2499, 12483, 5324, 26825, 6116, 404, 18, 29426, 3462, 27, 2499, 12483, 5324, 22, 3437, 6487, 23059, 21, 18, 29426, 3462, 27, 2499, 12483, 5324, 22, 3437, 6116, 300, 21, 18, 29426, 3462, 27, 2499, 12483, 5324, 22, 2777, 6487, 306, 21, 18, 29426, 3462, 27, 2499, 12483, 5324, 26825, 6116, 404, 18, 29426, 2 ]
log( 'Cannot instantiate episode: %s. Skipping.', entry.get( 'id', '(no id available)'), sender = channel)
log( 'Cannot instantiate episode: %s. Skipping.', entry.get( 'id', '(no id available)'), sender = channel, traceback=True)
def get_by_url(cls, url, force_update=False, offline=False, default_title=None): if isinstance( url, unicode): url = url.encode('utf-8')
75a41b62a3796f40b3e271f0adf15d717416627c /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/12778/75a41b62a3796f40b3e271f0adf15d717416627c/libpodcasts.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 1637, 67, 718, 12, 6429, 16, 880, 16, 2944, 67, 2725, 33, 8381, 16, 13493, 33, 8381, 16, 805, 67, 2649, 33, 7036, 4672, 309, 1549, 12, 880, 16, 5252, 4672, 880, 273, 880, 18, 3015, 2668, 3158, 17, 28, 6134, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 1637, 67, 718, 12, 6429, 16, 880, 16, 2944, 67, 2725, 33, 8381, 16, 13493, 33, 8381, 16, 805, 67, 2649, 33, 7036, 4672, 309, 1549, 12, 880, 16, 5252, 4672, 880, 273, 880, 18, 3015, 2668, 3158, 17, 28, 6134, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
gPeiCoreEntryPointString = """
gPeiCoreEntryPointPrototype = """
#ifndef _AUTOGENH_${Guid}
c0df5fc3f54d659cf283e68f6c5e03b271e178cb /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/914/c0df5fc3f54d659cf283e68f6c5e03b271e178cb/GenC.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 468, 430, 82, 536, 389, 18909, 16652, 44, 67, 18498, 22549, 97, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 468, 430, 82, 536, 389, 18909, 16652, 44, 67, 18498, 22549, 97, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
axvline(x=-percentiles[0], ymin=0, ymax=max(histoList), color='g', label='50th percentile', linewidth=2, linestyle='--') axvline(x=-percentiles[1], ymin=0, ymax=max(histoList), color='m', label='95th percentile', linewidth=2, linestyle='--') axvline(x=-percentiles[2], ymin=0, ymax=max(histoList), color='r', label='99th percentile', linewidth=2, linestyle='--')
pylab.axvline(x=-percentiles[0], ymin=0, ymax=max(histoList), color='g', label='50th percentile', linewidth=2, linestyle='--') pylab.axvline(x=-percentiles[1], ymin=0, ymax=max(histoList), color='m', label='95th percentile', linewidth=2, linestyle='--') pylab.axvline(x=-percentiles[2], ymin=0, ymax=max(histoList), color='r', label='99th percentile', linewidth=2, linestyle='--')
def plotHistogram(chan,opts,distribution,histoList,binList,figNumber,percentiles=None,candidate=None,candidateRank=None): parameter = distribution.split('-')[0] step = binList[1] - binList[0] counter = sum(histoList) xlimInf = min(binList) if candidate and not parameter == 'dt': xlimSup = max(max(binList),candidate + 2.0) else: xlimSup = max(binList) figure(figNumber) # semilogy(bins + step/2., z_dist+0.0001, 'r^',markerfacecolor="b",markersize=12) # plot(bins + step/2., z_dist) bar(binList, histoList, width=step, bottom=0) if percentiles: line1 = axvline(x=percentiles[0], ymin=0, ymax=max(histoList), color='g', label='50th percentile', linewidth=2, linestyle='--') line2 = axvline(x=percentiles[1], ymin=0, ymax=max(histoList), color='m', label='95th percentile', linewidth=2, linestyle='--') line3 = axvline(x=percentiles[2], ymin=0, ymax=max(histoList), color='r', label='99th percentile', linewidth=2, linestyle='--') if parameter == 'dt': axvline(x=-percentiles[0], ymin=0, ymax=max(histoList), color='g', label='50th percentile', linewidth=2, linestyle='--') axvline(x=-percentiles[1], ymin=0, ymax=max(histoList), color='m', label='95th percentile', linewidth=2, linestyle='--') axvline(x=-percentiles[2], ymin=0, ymax=max(histoList), color='r', label='99th percentile', linewidth=2, linestyle='--') if candidate: line0 = axvline(x=candidate, ymin=0, ymax=max(histoList), color='k', label='candidate value (%s percentile)' % (candidateRank), linewidth=2, linestyle='-') if percentiles and candidate: legend((line0,line1,line2,line3),('candidate','50%','95%','99%'),loc = 'upper right') if percentiles and not candidate: legend((line1,line2,line3),('50%','95%','99%'),loc = 'upper right') xlim(xlimInf,xlimSup) xlabel(parameter + ' value',size='large') # ylabel(r'#',size='x-large') grid() title("Histogram of the " + parameter + " value for " + chan + ', Statistics = ' + str(counter)) figText = chan.split(':')[0] + '_' + chan.split(':')[1] + '_' + parameter + '_dist' figFileName = InspiralUtils.set_figure_name(opts,figText) InspiralUtils.savefig_pylal(figFileName) close(figNumber) return figFileName
fd13c4566cb6da062a6e5ba73e68bd260af90c85 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/5758/fd13c4566cb6da062a6e5ba73e68bd260af90c85/analyseQscan.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3207, 12874, 12, 7472, 16, 4952, 16, 16279, 16, 11488, 83, 682, 16, 4757, 682, 16, 470, 1854, 16, 8849, 1449, 33, 7036, 16, 19188, 33, 7036, 16, 19188, 12925, 33, 7036, 4672, 225, 1569, 273, 7006, 18, 4939, 2668, 17, 6134, 63, 20, 65, 225, 2235, 273, 4158, 682, 63, 21, 65, 300, 4158, 682, 63, 20, 65, 3895, 273, 2142, 12, 11488, 83, 682, 13, 225, 19744, 13149, 273, 1131, 12, 4757, 682, 13, 309, 5500, 471, 486, 1569, 422, 296, 7510, 4278, 19744, 3088, 273, 943, 12, 1896, 12, 4757, 682, 3631, 19188, 397, 576, 18, 20, 13, 469, 30, 19744, 3088, 273, 943, 12, 4757, 682, 13, 225, 7837, 12, 470, 1854, 13, 468, 6111, 330, 19556, 12, 11862, 397, 2235, 19, 22, 12990, 998, 67, 4413, 15, 20, 18, 13304, 16, 296, 86, 66, 2187, 11145, 865, 3266, 1546, 70, 3113, 22807, 554, 33, 2138, 13, 468, 3207, 12, 11862, 397, 2235, 19, 22, 12990, 998, 67, 4413, 13, 4653, 12, 4757, 682, 16, 5356, 83, 682, 16, 1835, 33, 4119, 16, 5469, 33, 20, 13, 225, 309, 5551, 1449, 30, 980, 21, 273, 1740, 90, 1369, 12, 92, 33, 8849, 1449, 63, 20, 6487, 15763, 33, 20, 16, 15275, 33, 1896, 12, 11488, 83, 682, 3631, 2036, 2218, 75, 2187, 1433, 2218, 3361, 451, 17279, 2187, 18795, 33, 22, 16, 26388, 2218, 413, 6134, 980, 22, 273, 1740, 90, 1369, 12, 92, 33, 8849, 1449, 63, 21, 6487, 15763, 33, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3207, 12874, 12, 7472, 16, 4952, 16, 16279, 16, 11488, 83, 682, 16, 4757, 682, 16, 470, 1854, 16, 8849, 1449, 33, 7036, 16, 19188, 33, 7036, 16, 19188, 12925, 33, 7036, 4672, 225, 1569, 273, 7006, 18, 4939, 2668, 17, 6134, 63, 20, 65, 225, 2235, 273, 4158, 682, 63, 21, 65, 300, 4158, 682, 63, 20, 65, 3895, 273, 2142, 12, 11488, 83, 682, 13, 225, 19744, 13149, 273, 1131, 12, 4757, 682, 13, 309, 5500, 471, 486, 1569, 422, 296, 7510, 4278, 19744, 3088, 273, 943, 12, 1896, 12, 4757, 682, 3631, 19188, 397, 576, 18, 20, 13, 469, 30, 19744, 3088, 273, 943, 12, 4757, 682, 13, 225, 7837, 12, 470, 1854, 13, 468, 2 ]
for l in text[1:]: lines.append (big_indent + l)
def generate_help (self, header=None): """Generate help text (a list of strings, one per suggested line of output) from the option table for this FancyGetopt object."""
249dde1d04aa8acf8fb0b98afc3edd19986effc3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8125/249dde1d04aa8acf8fb0b98afc3edd19986effc3/fancy_getopt.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2103, 67, 5201, 261, 2890, 16, 1446, 33, 7036, 4672, 3536, 4625, 2809, 977, 261, 69, 666, 434, 2064, 16, 1245, 1534, 22168, 980, 434, 876, 13, 628, 326, 1456, 1014, 364, 333, 478, 12514, 967, 3838, 733, 12123, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2103, 67, 5201, 261, 2890, 16, 1446, 33, 7036, 4672, 3536, 4625, 2809, 977, 261, 69, 666, 434, 2064, 16, 1245, 1534, 22168, 980, 434, 876, 13, 628, 326, 1456, 1014, 364, 333, 478, 12514, 967, 3838, 733, 12123, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
aws_key = '1XHSE4FQJ0RK0X3S9WR2'
def got_error(self, failure, url): print "got_error", failure, url
54a4f7f3e20b1ce78e86f8022714fea950bff832 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/11626/54a4f7f3e20b1ce78e86f8022714fea950bff832/covers_by_amazon.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2363, 67, 1636, 12, 2890, 16, 5166, 16, 880, 4672, 1172, 315, 13212, 67, 1636, 3113, 5166, 16, 880, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2363, 67, 1636, 12, 2890, 16, 5166, 16, 880, 4672, 1172, 315, 13212, 67, 1636, 3113, 5166, 16, 880, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
self.setupJob(self.__prog__,dir=dir,tag_base=tag_base)
self.name = os.path.split(self.__executable.rstrip('/'))[1] self.setupJob(name=self.name,dir=dir,tag_base=tag_base)
def __init__(self, options, cp, dir='',tag_base='SKY_PLOT'): """ """ self.__prog__ = 'pylal_skyPlotJob' self.__executable = string.strip(cp.get('fu-condor','pylal_skyPlotJob')) self.__universe = "vanilla" pipeline.CondorDAGJob.__init__(self,self.__universe,self.__executable) self.add_condor_cmd('getenv','True') self.setupJob(self.__prog__,dir=dir,tag_base=tag_base)
4f059de02ba49cc10932529819f1976c7ed0ae64 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/5758/4f059de02ba49cc10932529819f1976c7ed0ae64/stfu_pipe.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 702, 16, 3283, 16, 1577, 2218, 2187, 2692, 67, 1969, 2218, 11129, 61, 67, 20485, 56, 11, 4672, 3536, 3536, 365, 16186, 14654, 972, 273, 296, 2074, 80, 287, 67, 22921, 11532, 2278, 11, 365, 16186, 17751, 273, 533, 18, 6406, 12, 4057, 18, 588, 2668, 27074, 17, 10013, 280, 17023, 2074, 80, 287, 67, 22921, 11532, 2278, 26112, 365, 16186, 318, 17488, 273, 315, 90, 26476, 6, 5873, 18, 12441, 280, 40, 1781, 2278, 16186, 2738, 972, 12, 2890, 16, 2890, 16186, 318, 17488, 16, 2890, 16186, 17751, 13, 365, 18, 1289, 67, 10013, 280, 67, 4172, 2668, 588, 3074, 17023, 5510, 6134, 365, 18, 8401, 2278, 12, 2890, 16186, 14654, 972, 16, 1214, 33, 1214, 16, 2692, 67, 1969, 33, 2692, 67, 1969, 13, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 702, 16, 3283, 16, 1577, 2218, 2187, 2692, 67, 1969, 2218, 11129, 61, 67, 20485, 56, 11, 4672, 3536, 3536, 365, 16186, 14654, 972, 273, 296, 2074, 80, 287, 67, 22921, 11532, 2278, 11, 365, 16186, 17751, 273, 533, 18, 6406, 12, 4057, 18, 588, 2668, 27074, 17, 10013, 280, 17023, 2074, 80, 287, 67, 22921, 11532, 2278, 26112, 365, 16186, 318, 17488, 273, 315, 90, 26476, 6, 5873, 18, 12441, 280, 40, 1781, 2278, 16186, 2738, 972, 12, 2890, 16, 2890, 16186, 318, 17488, 16, 2890, 16186, 17751, 13, 365, 18, 1289, 67, 10013, 280, 67, 4172, 2668, 588, 3074, 17023, 5510, 6134, 365, 18, 8401, 2278, 12, 2890, 16186, 14654, 2 ]
addtobook(char, cont, item)
return addtobook(char, cont, item)
def onDropOnItem( cont, item ): # Who is dragging us? char = item.container if not char.ischar(): return False addtobook(char, cont, item)
22abf4139be11b00975b36579077a864900b0bc9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2534/22abf4139be11b00975b36579077a864900b0bc9/scroll.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 603, 7544, 1398, 1180, 12, 466, 16, 761, 262, 30, 468, 3497, 83, 353, 25434, 584, 35, 1149, 273, 761, 18, 3782, 225, 309, 486, 1149, 18, 291, 3001, 13332, 327, 1083, 327, 527, 869, 3618, 12, 3001, 16, 466, 16, 761, 13, 225, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 603, 7544, 1398, 1180, 12, 466, 16, 761, 262, 30, 468, 3497, 83, 353, 25434, 584, 35, 1149, 273, 761, 18, 3782, 225, 309, 486, 1149, 18, 291, 3001, 13332, 327, 1083, 327, 527, 869, 3618, 12, 3001, 16, 466, 16, 761, 13, 225, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
'tashi-%i-%i.qcow' %(instanceId, disknum))
'tashi-%i-%i.%s' %(instanceId, disknum, disktype))
def transientDisk(self, instanceId, disknum): newdisk = os.path.join(self.transientDir, 'tashi-%i-%i.qcow' %(instanceId, disknum)) return newdisk
787afd97a19dbc056f066117a0e80a968ac780eb /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/5161/787afd97a19dbc056f066117a0e80a968ac780eb/xenpv.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 12315, 6247, 12, 2890, 16, 17608, 16, 4234, 2107, 4672, 394, 10863, 273, 1140, 18, 803, 18, 5701, 12, 2890, 18, 22670, 1621, 16, 296, 88, 961, 77, 6456, 77, 6456, 77, 7866, 87, 11, 8975, 1336, 548, 16, 4234, 2107, 16, 4234, 723, 3719, 327, 394, 10863, 225, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 12315, 6247, 12, 2890, 16, 17608, 16, 4234, 2107, 4672, 394, 10863, 273, 1140, 18, 803, 18, 5701, 12, 2890, 18, 22670, 1621, 16, 296, 88, 961, 77, 6456, 77, 6456, 77, 7866, 87, 11, 8975, 1336, 548, 16, 4234, 2107, 16, 4234, 723, 3719, 327, 394, 10863, 225, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
self.CondPrint('verbose', "Need to remove packages:", self.pkgwork['remove']) self.CondPrint('verbose', "Need to remove services:", self.extra_services)
self.CondPrint('verbose', "Need to remove packages:" % self.pkgwork['remove']) self.CondPrint('verbose', "Need to remove services:" % self.extra_services)
def HandleExtra(self): '''Deal with extra configuration detected''' if self.setup['remove'] in ['all', 'packages']: self.CondPrint('verbose', "Removing packages:", self.pkgwork['remove']) system("apt-get remove %s" % " ".join(self.pkgwork['remove'])) else: self.CondPrint('verbose', "Need to remove packages:", self.pkgwork['remove']) self.CondPrint('verbose', "Need to remove services:", self.extra_services)
1fb3bac2de5ee20e046b5aeb20fc37f1377b3f2b /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/11867/1fb3bac2de5ee20e046b5aeb20fc37f1377b3f2b/Debian.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 5004, 7800, 12, 2890, 4672, 9163, 758, 287, 598, 2870, 1664, 8316, 26418, 309, 365, 18, 8401, 3292, 4479, 3546, 316, 10228, 454, 2187, 296, 10308, 3546, 30, 365, 18, 12441, 5108, 2668, 11369, 2187, 315, 18939, 5907, 2773, 16, 365, 18, 10657, 1252, 3292, 4479, 19486, 2619, 2932, 1657, 17, 588, 1206, 738, 87, 6, 738, 315, 3552, 5701, 12, 2890, 18, 10657, 1252, 3292, 4479, 3546, 3719, 469, 30, 365, 18, 12441, 5108, 2668, 11369, 2187, 315, 14112, 358, 1206, 5907, 2773, 738, 365, 18, 10657, 1252, 3292, 4479, 19486, 365, 18, 12441, 5108, 2668, 11369, 2187, 315, 14112, 358, 1206, 4028, 2773, 738, 365, 18, 7763, 67, 8387, 13, 225, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 5004, 7800, 12, 2890, 4672, 9163, 758, 287, 598, 2870, 1664, 8316, 26418, 309, 365, 18, 8401, 3292, 4479, 3546, 316, 10228, 454, 2187, 296, 10308, 3546, 30, 365, 18, 12441, 5108, 2668, 11369, 2187, 315, 18939, 5907, 2773, 16, 365, 18, 10657, 1252, 3292, 4479, 19486, 2619, 2932, 1657, 17, 588, 1206, 738, 87, 6, 738, 315, 3552, 5701, 12, 2890, 18, 10657, 1252, 3292, 4479, 3546, 3719, 469, 30, 365, 18, 12441, 5108, 2668, 11369, 2187, 315, 14112, 358, 1206, 5907, 2773, 738, 365, 18, 10657, 1252, 3292, 4479, 19486, 365, 18, 12441, 5108, 2668, 11369, 2187, 315, 14112, 358, 1206, 4028, 2773, 738, 365, 18, 7763, 67, 8387, 13, 225, 2, -100, -100, -100, -100, -100 ]
return db_type
self.__class__._db_type = db_type
def determine_db_type(self, path): ''' determine which DB wrote the class file ''' db_type = '' if os.path.exists(path): db_type = whichdb.whichdb(path) if not db_type: raise hyperdb.DatabaseError, "Couldn't identify database type" elif os.path.exists(path+'.db'): # if the path ends in '.db', it's a dbm database, whether # anydbm says it's dbhash or not! db_type = 'dbm' return db_type
3ead45221cfcc20c56df38cbb14e9d9c64243a54 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/1906/3ead45221cfcc20c56df38cbb14e9d9c64243a54/sessions.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4199, 67, 1966, 67, 723, 12, 2890, 16, 589, 4672, 9163, 4199, 1492, 2383, 341, 21436, 326, 667, 585, 9163, 1319, 67, 723, 273, 875, 309, 1140, 18, 803, 18, 1808, 12, 803, 4672, 1319, 67, 723, 273, 1492, 1966, 18, 12784, 1966, 12, 803, 13, 309, 486, 1319, 67, 723, 30, 1002, 9512, 1966, 18, 4254, 668, 16, 315, 16342, 1404, 9786, 2063, 618, 6, 1327, 1140, 18, 803, 18, 1808, 12, 803, 6797, 18, 1966, 11, 4672, 468, 309, 326, 589, 3930, 316, 2418, 1966, 2187, 518, 1807, 279, 1319, 81, 2063, 16, 2856, 468, 1281, 1966, 81, 20185, 518, 1807, 1319, 2816, 578, 486, 5, 1319, 67, 723, 273, 296, 1966, 81, 11, 327, 1319, 67, 723, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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589, 4672, 9163, 4199, 1492, 2383, 341, 21436, 326, 667, 585, 9163, 1319, 67, 723, 273, 875, 309, 1140, 18, 803, 18, 1808, 12, 803, 4672, 1319, 67, 723, 273, 1492, 1966, 18, 12784, 1966, 12, 803, 13, 309, 486, 1319, 67, 723, 30, 1002, 9512, 1966, 18, 4254, 668, 16, 315, 16342, 1404, 9786, 2063, 618, 6, 1327, 1140, 18, 803, 18, 1808, 12, 803, 6797, 18, 1966, 11, 4672, 468, 309, 326, 589, 3930, 316, 2418, 1966, 2187, 518, 1807, 279, 1319, 81, 2063, 16, 2856, 468, 1281, 1966, 81, 20185, 518, 1807, 1319, 2816, 578, 486, 5, 1319, 67, 723, 273, 296, 1966, 81, 11, 327, 1319, 2 ]
self._serial = serial.Serial("/dev/%s" % device,getConfig("serial_baudrate"), getConfig("serial_line_timeout"))
log(Log.Info, "serial", "Trying /dev/%s" % device) self._serial = serial.Serial("/dev/%s" % device,getConfig("serial_baudrate"), timeout=getConfig("serial_line_timeout"))
def __init__(self): attempts = 0 devices = ["ttyUSB0", "ttyUSB1", "ttyS0", "ttyS1"] while attempts < 5 * len(devices): for device in devices: try: self._serial = serial.Serial("/dev/%s" % device,getConfig("serial_baudrate"), getConfig("serial_line_timeout")) log(Log.Info, "serial", "Using /dev/%s for serial communication." % device) log(Log.Info, "serial", "Running at %d without a line timeout of %d." % (self._serial.baudrate, self._serial.timeout)) self._handler = _SerialHandler(self) return except: attempts += 1 log(Log.Error, "serial", "Failed to initialize a serial device after 5 attempts, we're going nowhere.") fatalError("No serial device")
7ab1ee95b6f1543db6c17a8f554dda76d2d57e04 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12317/7ab1ee95b6f1543db6c17a8f554dda76d2d57e04/Serial.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 4672, 7531, 273, 374, 7166, 273, 8247, 5512, 24128, 20, 3113, 315, 5512, 24128, 21, 3113, 315, 5512, 55, 20, 3113, 315, 5512, 55, 21, 11929, 1323, 7531, 411, 1381, 380, 562, 12, 12506, 4672, 364, 2346, 316, 7166, 30, 775, 30, 613, 12, 1343, 18, 966, 16, 315, 8818, 3113, 315, 18038, 342, 5206, 5258, 87, 6, 738, 2346, 13, 365, 6315, 8818, 273, 2734, 18, 6342, 2932, 19, 5206, 5258, 87, 6, 738, 2346, 16, 588, 809, 2932, 8818, 67, 12124, 1100, 5141, 6, 3631, 2021, 33, 588, 809, 2932, 8818, 67, 1369, 67, 4538, 6, 3719, 613, 12, 1343, 18, 966, 16, 315, 8818, 3113, 315, 7736, 342, 5206, 5258, 87, 364, 2734, 18279, 1199, 738, 2346, 13, 613, 12, 1343, 18, 966, 16, 315, 8818, 3113, 315, 7051, 622, 738, 72, 2887, 279, 980, 2021, 434, 738, 72, 1199, 738, 261, 2890, 6315, 8818, 18, 12124, 1100, 5141, 16, 365, 6315, 8818, 18, 4538, 3719, 365, 6315, 4176, 273, 389, 6342, 1503, 12, 2890, 13, 327, 1335, 30, 7531, 1011, 404, 613, 12, 1343, 18, 668, 16, 315, 8818, 3113, 315, 2925, 358, 4046, 279, 2734, 2346, 1839, 1381, 7531, 16, 732, 4565, 8554, 2037, 14852, 1199, 13, 10081, 668, 2932, 2279, 2734, 2346, 7923, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 4672, 7531, 273, 374, 7166, 273, 8247, 5512, 24128, 20, 3113, 315, 5512, 24128, 21, 3113, 315, 5512, 55, 20, 3113, 315, 5512, 55, 21, 11929, 1323, 7531, 411, 1381, 380, 562, 12, 12506, 4672, 364, 2346, 316, 7166, 30, 775, 30, 613, 12, 1343, 18, 966, 16, 315, 8818, 3113, 315, 18038, 342, 5206, 5258, 87, 6, 738, 2346, 13, 365, 6315, 8818, 273, 2734, 18, 6342, 2932, 19, 5206, 5258, 87, 6, 738, 2346, 16, 588, 809, 2932, 8818, 67, 12124, 1100, 5141, 6, 3631, 2021, 33, 588, 809, 2932, 8818, 67, 1369, 67, 4538, 6, 3719, 613, 12, 1343, 18, 966, 16, 315, 8818, 3113, 315, 7736, 342, 5206, 5258, 2 ]
if job.is_example:
if job.is_example or job.is_pyexample:
def run_tests(): # # Run waf to make sure that everything is built, configured and ready to go # unless we are explicitly told not to. We want to be careful about causing # our users pain while waiting for extraneous stuff to compile and link, so # we allow users that know what they''re doing to not invoke waf at all. # if not options.nowaf: # # If the user is running the "kinds" or "list" options, there is an # implied dependency on the test-runner since we call that program # if those options are selected. We will exit after processing those # options, so if we see them, we can safely only build the test-runner. # # If the user has constrained us to running only a particular type of # file, we can only ask waf to build what we know will be necessary. # For example, if the user only wants to run BVT tests, we only have # to build the test-runner and can ignore all of the examples. # # If the user only wants to run a single example, then we can just build # that example. # # If there is no constraint, then we have to build everything since the # user wants to run everything. # if options.kinds or options.list or (len(options.constrain) and options.constrain in core_kinds): if sys.platform == "win32": waf_cmd = "waf --target=test-runner" else: waf_cmd = "./waf --target=test-runner" elif len(options.example): if sys.platform == "win32": waf_cmd = "waf --target=%s" % os.path.basename(options.example) else: waf_cmd = "./waf --target=%s" % os.path.basename(options.example) else: if sys.platform == "win32": waf_cmd = "waf" else: waf_cmd = "./waf" if options.verbose: print "Building: %s" % waf_cmd proc = subprocess.Popen(waf_cmd, shell = True) proc.communicate() # # Pull some interesting configuration information out of waf, primarily # so we can know where executables can be found, but also to tell us what # pieces of the system have been built. This will tell us what examples # are runnable. # read_waf_active_variant() read_waf_config() make_library_path() # # If lots of logging is enabled, we can crash Python when it tries to # save all of the text. We just don't allow logging to be turned on when # test.py runs. If you want to see logging output from your tests, you # have to run them using the test-runner directly. # os.environ["NS_LOG"] = "" # # There are a couple of options that imply we can to exit before starting # up a bunch of threads and running tests. Let's detect these cases and # handle them without doing all of the hard work. # if options.kinds: path_cmd = os.path.join("utils", "test-runner --kinds") (rc, standard_out, standard_err, et) = run_job_synchronously(path_cmd, os.getcwd(), False, False) print standard_out if options.list: path_cmd = os.path.join("utils", "test-runner --list") (rc, standard_out, standard_err, et) = run_job_synchronously(path_cmd, os.getcwd(), False, False) print standard_out if options.kinds or options.list: return # # We communicate results in two ways. First, a simple message relating # PASS, FAIL, CRASH or SKIP is always written to the standard output. It # is expected that this will be one of the main use cases. A developer can # just run test.py with no options and see that all of the tests still # pass. # # The second main use case is when detailed status is requested (with the # --text or --html options). Typicall this will be text if a developer # finds a problem, or HTML for nightly builds. In these cases, an # XML file is written containing the status messages from the test suites. # This file is then read and translated into text or HTML. It is expected # that nobody will really be interested in the XML, so we write it somewhere # with a unique name (time) to avoid collisions. In case an error happens, we # provide a runtime option to retain the temporary files. # # When we run examples as smoke tests, they are going to want to create # lots and lots of trace files. We aren't really interested in the contents # of the trace files, so we also just stash them off in the temporary dir. # The retain option also causes these unchecked trace files to be kept. # date_and_time = time.strftime("%Y-%m-%d-%H-%M-%S-CUT", time.gmtime()) if not os.path.exists(TMP_OUTPUT_DIR): os.makedirs(TMP_OUTPUT_DIR) testpy_output_dir = os.path.join(TMP_OUTPUT_DIR, date_and_time); if not os.path.exists(testpy_output_dir): os.makedirs(testpy_output_dir) # # Create the main output file and start filling it with XML. We need to # do this since the tests will just append individual results to this file. # xml_results_file = os.path.join(testpy_output_dir, "results.xml") f = open(xml_results_file, 'w') f.write('<?xml version="1.0"?>\n') f.write('<TestResults>\n') f.close() # # We need to figure out what test suites to execute. We are either given one # suite or example explicitly via the --suite or --example/--pyexample option, # or we need to call into the test runner and ask it to list all of the available # test suites. Further, we need to provide the constraint information if it # has been given to us. # # This translates into allowing the following options with respect to the # suites # # ./test,py: run all of the suites and examples # ./test.py --constrain=core: run all of the suites of all kinds # ./test.py --constrain=unit: run all unit suites # ./test,py --suite=some-test-suite: run a single suite # ./test,py --example=udp/udp-echo: run no test suites # ./test,py --pyexample=wireless/mixed-wireless.py: run no test suites # ./test,py --suite=some-suite --example=some-example: run the single suite # # We can also use the --constrain option to provide an ordering of test # execution quite easily. # if len(options.suite): suites = options.suite + "\n" elif len(options.example) == 0 and len(options.pyexample) == 0: if len(options.constrain): path_cmd = os.path.join("utils", "test-runner --list --constrain=%s" % options.constrain) (rc, suites, standard_err, et) = run_job_synchronously(path_cmd, os.getcwd(), False, False) else: path_cmd = os.path.join("utils", "test-runner --list") (rc, suites, standard_err, et) = run_job_synchronously(path_cmd, os.getcwd(), False, False) else: suites = "" # # suite_list will either a single test suite name that the user has # indicated she wants to run or a list of test suites provided by # the test-runner possibly according to user provided constraints. # We go through the trouble of setting up the parallel execution # even in the case of a single suite to avoid having two process the # results in two different places. # suite_list = suites.split('\n') # # We now have a possibly large number of test suites to run, so we want to # run them in parallel. We're going to spin up a number of worker threads # that will run our test jobs for us. # input_queue = Queue.Queue(0) output_queue = Queue.Queue(0) jobs = 0 threads=[] # # In Python 2.6 you can just use multiprocessing module, but we don't want # to introduce that dependency yet; so we jump through a few hoops. # processors = 1 if sys.platform != "win32": if 'SC_NPROCESSORS_ONLN'in os.sysconf_names: processors = os.sysconf('SC_NPROCESSORS_ONLN') else: proc = subprocess.Popen("sysctl -n hw.ncpu", shell = True, stdout=subprocess.PIPE, stderr=subprocess.PIPE) stdout_results, stderr_results = proc.communicate() if len(stderr_results) == 0: processors = int(stdout_results) # # Now, spin up one thread per processor which will eventually mean one test # per processor running concurrently. # for i in range(processors): thread = worker_thread(input_queue, output_queue) threads.append(thread) thread.start() # # Keep track of some summary statistics # total_tests = 0 skipped_tests = 0 # # We now have worker threads spun up, and a list of work to do. So, run # through the list of test suites and dispatch a job to run each one. # # Dispatching will run with unlimited speed and the worker threads will # execute as fast as possible from the queue. # # Note that we actually dispatch tests to be skipped, so all of the # PASS, FAIL, CRASH and SKIP processing is done in the same place. # for test in suite_list: test = test.strip() if len(test): job = Job() job.set_is_example(False) job.set_is_pyexample(False) job.set_display_name(test) job.set_tmp_file_name(os.path.join(testpy_output_dir, "%s.xml" % test)) job.set_cwd(os.getcwd()) job.set_basedir(os.getcwd()) job.set_tempdir(testpy_output_dir) if (options.multiple): multiple = " --multiple" else: multiple = "" path_cmd = os.path.join("utils", "test-runner --suite=%s%s" % (test, multiple)) job.set_shell_command(path_cmd) if options.valgrind and test in core_valgrind_skip_tests: job.set_is_skip(True) if options.verbose: print "Queue %s" % test input_queue.put(job) jobs = jobs + 1 total_tests = total_tests + 1 # # We've taken care of the discovered or specified test suites. Now we # have to deal with examples run as smoke tests. We have a list of all of # the example programs it makes sense to try and run. Each example will # have a condition associated with it that must evaluate to true for us # to try and execute it. This is used to determine if the example has # a dependency that is not satisfied. For example, if an example depends # on NSC being configured by waf, that example should have a condition # that evaluates to true if NSC is enabled. For example, # # ("tcp-nsc-zoo", "ENABLE_NSC == True"), # # In this case, the example "tcp-nsc-zoo" will only be run if we find the # waf configuration variable "ENABLE_NSC" to be True. # # We don't care at all how the trace files come out, so we just write them # to a single temporary directory. # # XXX As it stands, all of the trace files have unique names, and so file # collisions can only happen if two instances of an example are running in # two versions of the test.py process concurrently. We may want to create # uniquely named temporary traces directories to avoid this problem. # # We need to figure out what examples to execute. We are either given one # suite or example explicitly via the --suite or --example option, or we # need to walk the list of examples looking for available example # conditions. # # This translates into allowing the following options with respect to the # suites # # ./test,py: run all of the examples # ./test.py --constrain=unit run no examples # ./test.py --constrain=example run all of the examples # ./test.py --suite=some-test-suite: run no examples # ./test.py --example=some-example: run the single example # ./test.py --suite=some-suite --example=some-example: run the single example # # XXX could use constrain to separate out examples used for performance # testing # if len(options.suite) == 0 and len(options.example) == 0 and len(options.pyexample) == 0: if len(options.constrain) == 0 or options.constrain == "example": if ENABLE_EXAMPLES: for test, do_run, do_valgrind_run in example_tests: if eval(do_run): job = Job() job.set_is_example(True) job.set_is_pyexample(False) job.set_display_name(test) job.set_tmp_file_name("") job.set_cwd(testpy_output_dir) job.set_basedir(os.getcwd()) job.set_tempdir(testpy_output_dir) job.set_shell_command("examples/%s" % test) if options.valgrind and not eval(do_valgrind_run): job.set_is_skip (True) if options.verbose: print "Queue %s" % test input_queue.put(job) jobs = jobs + 1 total_tests = total_tests + 1 elif len(options.example): # # If you tell me to run an example, I will try and run the example # irrespective of any condition. # job = Job() job.set_is_example(True) job.set_is_pyexample(False) job.set_display_name(options.example) job.set_tmp_file_name("") job.set_cwd(testpy_output_dir) job.set_basedir(os.getcwd()) job.set_tempdir(testpy_output_dir) job.set_shell_command("examples/%s" % options.example) if options.verbose: print "Queue %s" % options.example input_queue.put(job) jobs = jobs + 1 total_tests = total_tests + 1 # # Run some Python examples as smoke tests. We have a list of all of # the example programs it makes sense to try and run. Each example will # have a condition associated with it that must evaluate to true for us # to try and execute it. This is used to determine if the example has # a dependency that is not satisfied. # # We don't care at all how the trace files come out, so we just write them # to a single temporary directory. # # We need to figure out what python examples to execute. We are either # given one pyexample explicitly via the --pyexample option, or we # need to walk the list of python examples # # This translates into allowing the following options with respect to the # suites # # ./test.py --constrain=pyexample run all of the python examples # ./test.py --pyexample=some-example.py: run the single python example # if len(options.suite) == 0 and len(options.example) == 0 and len(options.pyexample) == 0: if len(options.constrain) == 0 or options.constrain == "pyexample": if ENABLE_EXAMPLES: for test, do_run in python_tests: if eval(do_run): job = Job() job.set_is_example(False) job.set_is_pyexample(True) job.set_display_name(test) job.set_tmp_file_name("") job.set_cwd(testpy_output_dir) job.set_basedir(os.getcwd()) job.set_tempdir(testpy_output_dir) job.set_shell_command("examples/%s" % test) if options.valgrind and not eval(do_valgrind_run): job.set_is_skip (True) if options.verbose: print "Queue %s" % test input_queue.put(job) jobs = jobs + 1 total_tests = total_tests + 1 elif len(options.pyexample): # # If you tell me to run a python example, I will try and run the example # irrespective of any condition. # job = Job() job.set_is_pyexample(True) job.set_display_name(options.pyexample) job.set_tmp_file_name("") job.set_cwd(testpy_output_dir) job.set_basedir(os.getcwd()) job.set_tempdir(testpy_output_dir) job.set_shell_command("examples/%s" % options.pyexample) if options.verbose: print "Queue %s" % options.pyexample input_queue.put(job) jobs = jobs + 1 total_tests = total_tests + 1 # # Tell the worker threads to pack up and go home for the day. Each one # will exit when they see their is_break task. # for i in range(processors): job = Job() job.set_is_break(True) input_queue.put(job) # # Now all of the tests have been dispatched, so all we have to do here # in the main thread is to wait for them to complete. Keyboard interrupt # handling is broken as mentioned above. We use a signal handler to catch # sigint and set a global variable. When the worker threads sense this # they stop doing real work and will just start throwing jobs back at us # with is_break set to True. In this case, there are no real results so we # ignore them. If there are real results, we always print PASS or FAIL to # standard out as a quick indication of what happened. # passed_tests = 0 failed_tests = 0 crashed_tests = 0 valgrind_errors = 0 for i in range(jobs): job = output_queue.get() if job.is_break: continue if job.is_example: kind = "Example" elif job.is_pyexample: kind = "PythonExample" else: kind = "TestSuite" if job.is_skip: status = "SKIP" skipped_tests = skipped_tests + 1 else: if job.returncode == 0: status = "PASS" passed_tests = passed_tests + 1 elif job.returncode == 1: failed_tests = failed_tests + 1 status = "FAIL" elif job.returncode == 2: valgrind_errors = valgrind_errors + 1 status = "VALGR" else: crashed_tests = crashed_tests + 1 status = "CRASH" print "%s: %s %s" % (status, kind, job.display_name) if job.is_example or job.is_pyexample: # # Examples are the odd man out here. They are written without any # knowledge that they are going to be run as a test, so we need to # cook up some kind of output for them. We're writing an xml file, # so we do some simple XML that says we ran the example. # # XXX We could add some timing information to the examples, i.e. run # them through time and print the results here. # f = open(xml_results_file, 'a') f.write('<Example>\n') example_name = " <Name>%s</Name>\n" % job.display_name f.write(example_name) if status == "PASS": f.write(' <Result>PASS</Result>\n') elif status == "FAIL": f.write(' <Result>FAIL</Result>\n') elif status == "VALGR": f.write(' <Result>VALGR</Result>\n') elif status == "SKIP": f.write(' <Result>SKIP</Result>\n') else: f.write(' <Result>CRASH</Result>\n') f.write(' <ElapsedTime>%.3f</ElapsedTime>\n' % job.elapsed_time) f.write('</Example>\n') f.close() else: # # If we're not running an example, we're running a test suite. # These puppies are running concurrently and generating output # that was written to a temporary file to avoid collisions. # # Now that we are executing sequentially in the main thread, we can # concatenate the contents of the associated temp file to the main # results file and remove that temp file. # # One thing to consider is that a test suite can crash just as # well as any other program, so we need to deal with that # possibility as well. If it ran correctly it will return 0 # if it passed, or 1 if it failed. In this case, we can count # on the results file it saved being complete. If it crashed, it # will return some other code, and the file should be considered # corrupt and useless. If the suite didn't create any XML, then # we're going to have to do it ourselves. # # Another issue is how to deal with a valgrind error. If we run # a test suite under valgrind and it passes, we will get a return # code of 0 and there will be a valid xml results file since the code # ran to completion. If we get a return code of 1 under valgrind, # the test case failed, but valgrind did not find any problems so the # test case return code was passed through. We will have a valid xml # results file here as well since the test suite ran. If we see a # return code of 2, this means that valgrind found an error (we asked # it to return 2 if it found a problem in run_job_synchronously) but # the suite ran to completion so there is a valid xml results file. # If the suite crashes under valgrind we will see some other error # return code (like 139). If valgrind finds an illegal instruction or # some other strange problem, it will die with its own strange return # code (like 132). However, if the test crashes by itself, not under # valgrind we will also see some other return code. # # If the return code is 0, 1, or 2, we have a valid xml file. If we # get another return code, we have no xml and we can't really say what # happened -- maybe the TestSuite crashed, maybe valgrind crashed due # to an illegal instruction. If we get something beside 0-2, we assume # a crash and fake up an xml entry. After this is all done, we still # need to indicate a valgrind error somehow, so we fake up an xml entry # with a VALGR result. Thus, in the case of a working TestSuite that # fails valgrind, we'll see the PASS entry for the working TestSuite # followed by a VALGR failing test suite of the same name. # if job.is_skip: f = open(xml_results_file, 'a') f.write("<TestSuite>\n") f.write(" <SuiteName>%s</SuiteName>\n" % job.display_name) f.write(' <SuiteResult>SKIP</SuiteResult>\n') f.write(' <SuiteTime>Execution times not available</SuiteTime>\n') f.write("</TestSuite>\n") f.close() else: if job.returncode == 0 or job.returncode == 1 or job.returncode == 2: f_to = open(xml_results_file, 'a') f_from = open(job.tmp_file_name) f_to.write(f_from.read()) f_to.close() f_from.close() else: f = open(xml_results_file, 'a') f.write("<TestSuite>\n") f.write(" <SuiteName>%s</SuiteName>\n" % job.display_name) f.write(' <SuiteResult>CRASH</SuiteResult>\n') f.write(' <SuiteTime>Execution times not available</SuiteTime>\n') f.write("</TestSuite>\n") f.close() if job.returncode == 2: f = open(xml_results_file, 'a') f.write("<TestSuite>\n") f.write(" <SuiteName>%s</SuiteName>\n" % job.display_name) f.write(' <SuiteResult>VALGR</SuiteResult>\n') f.write(' <SuiteTime>Execution times not available</SuiteTime>\n') f.write("</TestSuite>\n") f.close() # # We have all of the tests run and the results written out. One final # bit of housekeeping is to wait for all of the threads to close down # so we can exit gracefully. # for thread in threads: thread.join() # # Back at the beginning of time, we started the body of an XML document # since the test suites and examples were going to just write their # individual pieces. So, we need to finish off and close out the XML # document # f = open(xml_results_file, 'a') f.write('</TestResults>\n') f.close() # # Print a quick summary of events # print "%d of %d tests passed (%d passed, %d skipped, %d failed, %d crashed, %d valgrind errors)" % (passed_tests, total_tests, passed_tests, skipped_tests, failed_tests, crashed_tests, valgrind_errors) # # The last things to do are to translate the XML results file to "human # readable form" if the user asked for it (or make an XML file somewhere) # if len(options.html): translate_to_html(xml_results_file, options.html) if len(options.text): translate_to_text(xml_results_file, options.text) if len(options.xml): shutil.copyfile(xml_results_file, options.xml) # # If we have been asked to retain all of the little temporary files, we # don't delete tm. If we do delete the temporary files, delete only the # directory we just created. We don't want to happily delete any retained # directories, which will probably surprise the user. # if not options.retain: shutil.rmtree(testpy_output_dir) if passed_tests + skipped_tests == total_tests: return 0 # success else: return 1 # catchall for general errors
36d879aed9338f58c9b0dbcf5d40deebf5c2009c /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12851/36d879aed9338f58c9b0dbcf5d40deebf5c2009c/test.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1086, 67, 16341, 13332, 468, 468, 1939, 24103, 358, 1221, 3071, 716, 7756, 353, 6650, 16, 4351, 471, 5695, 358, 1960, 468, 3308, 732, 854, 8122, 268, 1673, 486, 358, 18, 225, 1660, 2545, 358, 506, 26850, 2973, 25416, 468, 3134, 3677, 293, 530, 1323, 7336, 364, 7582, 15522, 10769, 358, 4074, 471, 1692, 16, 1427, 468, 732, 1699, 3677, 716, 5055, 4121, 2898, 6309, 266, 9957, 358, 486, 4356, 24103, 622, 777, 18, 468, 309, 486, 702, 18, 3338, 1727, 30, 225, 468, 468, 971, 326, 729, 353, 3549, 326, 315, 9224, 87, 6, 578, 315, 1098, 6, 702, 16, 1915, 353, 392, 468, 23547, 4904, 603, 326, 1842, 17, 18156, 3241, 732, 745, 716, 5402, 468, 309, 5348, 702, 854, 3170, 18, 225, 1660, 903, 2427, 1839, 4929, 5348, 468, 702, 16, 1427, 309, 732, 2621, 2182, 16, 732, 848, 15303, 1338, 1361, 326, 1842, 17, 18156, 18, 468, 468, 971, 326, 729, 711, 27666, 584, 358, 3549, 1338, 279, 6826, 618, 434, 468, 585, 16, 732, 848, 1338, 6827, 24103, 358, 1361, 4121, 732, 5055, 903, 506, 4573, 18, 468, 2457, 3454, 16, 309, 326, 729, 1338, 14805, 358, 1086, 605, 58, 56, 7434, 16, 732, 1338, 1240, 468, 358, 1361, 326, 1842, 17, 18156, 471, 848, 2305, 777, 434, 326, 10991, 18, 468, 468, 971, 326, 729, 1338, 14805, 358, 1086, 279, 2202, 3454, 16, 1508, 732, 848, 2537, 1361, 468, 716, 3454, 18, 468, 468, 971, 1915, 353, 1158, 4954, 16, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1086, 67, 16341, 13332, 468, 468, 1939, 24103, 358, 1221, 3071, 716, 7756, 353, 6650, 16, 4351, 471, 5695, 358, 1960, 468, 3308, 732, 854, 8122, 268, 1673, 486, 358, 18, 225, 1660, 2545, 358, 506, 26850, 2973, 25416, 468, 3134, 3677, 293, 530, 1323, 7336, 364, 7582, 15522, 10769, 358, 4074, 471, 1692, 16, 1427, 468, 732, 1699, 3677, 716, 5055, 4121, 2898, 6309, 266, 9957, 358, 486, 4356, 24103, 622, 777, 18, 468, 309, 486, 702, 18, 3338, 1727, 30, 225, 468, 468, 971, 326, 729, 353, 3549, 326, 315, 9224, 87, 6, 578, 315, 1098, 6, 702, 16, 1915, 353, 392, 468, 23547, 4904, 603, 326, 1842, 17, 18156, 3241, 732, 745, 716, 5402, 468, 2 ]
this = apply(_quickfix.new_CollStatus, args)
this = _quickfix.new_CollStatus(*args)
def __init__(self, *args): this = apply(_quickfix.new_CollStatus, args) try: self.this.append(this) except: self.this = this
7e632099fd421880c8c65fb0cf610d338d115ee9 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/8819/7e632099fd421880c8c65fb0cf610d338d115ee9/quickfix.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 380, 1968, 4672, 333, 273, 389, 19525, 904, 18, 2704, 67, 13535, 1482, 30857, 1968, 13, 775, 30, 365, 18, 2211, 18, 6923, 12, 2211, 13, 1335, 30, 365, 18, 2211, 273, 333, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 380, 1968, 4672, 333, 273, 389, 19525, 904, 18, 2704, 67, 13535, 1482, 30857, 1968, 13, 775, 30, 365, 18, 2211, 18, 6923, 12, 2211, 13, 1335, 30, 365, 18, 2211, 273, 333, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
mixer.setLineinVolume(90)
mixer.setLineinVolume( config.TV_IN_VOLUME ) mixer.setIgainVolume( config.TV_IN_VOLUME )
def Play(self, mode, tuner_channel=None):
288493038f35f8d2cf5f29dd7706d18eb5ab81b7 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/11399/288493038f35f8d2cf5f29dd7706d18eb5ab81b7/v4l1tv.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 19592, 12, 2890, 16, 1965, 16, 268, 29640, 67, 4327, 33, 7036, 4672, 2, 0, 0, 0, 0, 0, 0,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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 19592, 12, 2890, 16, 1965, 16, 268, 29640, 67, 4327, 33, 7036, 4672, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
compiz_call('water/allscreens/point','activate','root',self.root_xid,'x',x,'y',y)
try: compiz_call('water/allscreens/point','activate','root',self.root_xid,'x',x,'y',y) except: pass
def attention_effect (self): self.attention_effect_running = True if self.needs_attention: if settings["groupbutton_attention_notification_type"] == 'compwater': x,y = self.button.window.get_origin() alloc = self.button.get_allocation() x = x + alloc.x + alloc.width/2 y = y + alloc.y + alloc.height/2 compiz_call('water/allscreens/point','activate','root',self.root_xid,'x',x,'y',y) elif settings["groupbutton_attention_notification_type"] == 'blink': if not self.needs_attention_anim_trigger: self.needs_attention_anim_trigger = True pixbuf = self.icon_factory.pixbuf_update(self.icon_mode | IconFactory.BRIGHT | self.icon_active | self.dd_effect) self.image.set_from_pixbuf(pixbuf) else: self.needs_attention_anim_trigger = False pixbuf = self.icon_factory.pixbuf_update(self.icon_mode | self.icon_active | self.dd_effect) self.image.set_from_pixbuf(pixbuf) pixbuf = None return True else: self.needs_attention_anim_trigger = False self.attention_effect_running = False return False
36703b1b4800fdeeaa6229ba131abda703f851d3 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/7075/36703b1b4800fdeeaa6229ba131abda703f851d3/dockbarx.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 17278, 67, 13867, 261, 2890, 4672, 365, 18, 17899, 67, 13867, 67, 8704, 273, 1053, 309, 365, 18, 20600, 67, 17899, 30, 309, 1947, 9614, 1655, 5391, 67, 17899, 67, 9927, 67, 723, 11929, 422, 296, 2919, 91, 2045, 4278, 619, 16, 93, 273, 365, 18, 5391, 18, 5668, 18, 588, 67, 10012, 1435, 4767, 273, 365, 18, 5391, 18, 588, 67, 29299, 1435, 619, 273, 619, 397, 4767, 18, 92, 397, 4767, 18, 2819, 19, 22, 677, 273, 677, 397, 4767, 18, 93, 397, 4767, 18, 4210, 19, 22, 775, 30, 1161, 452, 67, 1991, 2668, 91, 2045, 19, 454, 1017, 266, 773, 19, 1153, 17023, 10014, 17023, 3085, 2187, 2890, 18, 3085, 67, 6212, 11189, 92, 2187, 92, 11189, 93, 2187, 93, 13, 1335, 30, 1342, 1327, 1947, 9614, 1655, 5391, 67, 17899, 67, 9927, 67, 723, 11929, 422, 296, 70, 1232, 4278, 309, 486, 365, 18, 20600, 67, 17899, 67, 304, 381, 67, 10668, 30, 365, 18, 20600, 67, 17899, 67, 304, 381, 67, 10668, 273, 1053, 11871, 4385, 273, 365, 18, 3950, 67, 6848, 18, 14861, 4385, 67, 2725, 12, 2890, 18, 3950, 67, 3188, 571, 16011, 1733, 18, 38, 11847, 571, 365, 18, 3950, 67, 3535, 571, 365, 18, 449, 67, 13867, 13, 365, 18, 2730, 18, 542, 67, 2080, 67, 14861, 4385, 12, 14861, 4385, 13, 469, 30, 365, 18, 20600, 67, 17899, 67, 304, 381, 67, 10668, 273, 1083, 11871, 4385, 273, 365, 18, 3950, 67, 6848, 18, 14861, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 17278, 67, 13867, 261, 2890, 4672, 365, 18, 17899, 67, 13867, 67, 8704, 273, 1053, 309, 365, 18, 20600, 67, 17899, 30, 309, 1947, 9614, 1655, 5391, 67, 17899, 67, 9927, 67, 723, 11929, 422, 296, 2919, 91, 2045, 4278, 619, 16, 93, 273, 365, 18, 5391, 18, 5668, 18, 588, 67, 10012, 1435, 4767, 273, 365, 18, 5391, 18, 588, 67, 29299, 1435, 619, 273, 619, 397, 4767, 18, 92, 397, 4767, 18, 2819, 19, 22, 677, 273, 677, 397, 4767, 18, 93, 397, 4767, 18, 4210, 19, 22, 775, 30, 1161, 452, 67, 1991, 2668, 91, 2045, 19, 454, 1017, 266, 773, 19, 1153, 17023, 10014, 17023, 3085, 2187, 2890, 18, 3085, 67, 6212, 11189, 92, 2 ]
], CONTEXT)
], 0, None, None, CONTEXT)
def test0050char(self): ''' Test Char. ''' char1_id = self.char.create({ 'char': 'Test', }, CONTEXT) self.assert_(char1_id)
52062c763bf1737b3f2071e48338f60845edc54d /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9266/52062c763bf1737b3f2071e48338f60845edc54d/test_tryton.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 713, 3361, 3001, 12, 2890, 4672, 9163, 7766, 3703, 18, 9163, 1149, 21, 67, 350, 273, 365, 18, 3001, 18, 2640, 12590, 296, 3001, 4278, 296, 4709, 2187, 19879, 13862, 13, 365, 18, 11231, 67, 12, 3001, 21, 67, 350, 13, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 713, 3361, 3001, 12, 2890, 4672, 9163, 7766, 3703, 18, 9163, 1149, 21, 67, 350, 273, 365, 18, 3001, 18, 2640, 12590, 296, 3001, 4278, 296, 4709, 2187, 19879, 13862, 13, 365, 18, 11231, 67, 12, 3001, 21, 67, 350, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
app({"SERVER_NAME":"127.0.0.1", "SERVER_PORT":"8080", "REQUEST_METHOD":"GET",
app({"REQUEST_METHOD":"GET",
def test_folder_on_zope_side(self): factory = RewriteFactory({}, host="www.example.com", port="80", internalpath="/foo") r = response() app = factory(PathAssertionEndpoint("/VirtualHostBase/http/www.example.com:80/foo/VirtualHostRoot/", self)) app({"SERVER_NAME":"127.0.0.1", "SERVER_PORT":"8080", "REQUEST_METHOD":"GET", "PATH_INFO":"/"}, r.start_response) assert r.status.startswith("200")
737aa73e6c7065d1ef223f0d88d6a6f7c9c0d5d2 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9186/737aa73e6c7065d1ef223f0d88d6a6f7c9c0d5d2/test_url.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 67, 5609, 67, 265, 67, 94, 1306, 67, 5564, 12, 2890, 4672, 3272, 273, 17851, 1733, 23506, 16, 1479, 1546, 5591, 18, 8236, 18, 832, 3113, 1756, 1546, 3672, 3113, 2713, 803, 1546, 19, 11351, 7923, 436, 273, 766, 1435, 595, 273, 3272, 12, 743, 14979, 3293, 2932, 19, 6466, 2594, 2171, 19, 2505, 19, 5591, 18, 8236, 18, 832, 30, 3672, 19, 11351, 19, 6466, 2594, 2375, 19, 3113, 365, 3719, 595, 12590, 6, 5519, 67, 5327, 15563, 3264, 3113, 315, 4211, 67, 5923, 15563, 4898, 5779, 436, 18, 1937, 67, 2740, 13, 1815, 436, 18, 2327, 18, 17514, 1918, 2932, 6976, 7923, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 67, 5609, 67, 265, 67, 94, 1306, 67, 5564, 12, 2890, 4672, 3272, 273, 17851, 1733, 23506, 16, 1479, 1546, 5591, 18, 8236, 18, 832, 3113, 1756, 1546, 3672, 3113, 2713, 803, 1546, 19, 11351, 7923, 436, 273, 766, 1435, 595, 273, 3272, 12, 743, 14979, 3293, 2932, 19, 6466, 2594, 2171, 19, 2505, 19, 5591, 18, 8236, 18, 832, 30, 3672, 19, 11351, 19, 6466, 2594, 2375, 19, 3113, 365, 3719, 595, 12590, 6, 5519, 67, 5327, 15563, 3264, 3113, 315, 4211, 67, 5923, 15563, 4898, 5779, 436, 18, 1937, 67, 2740, 13, 1815, 436, 18, 2327, 18, 17514, 1918, 2932, 6976, 7923, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
self.AddError(_("No one can subscribe to the digest of this list!"))
self.AddError( _("No one can subscribe to the digest of this list!"))
def ProcessSubscribeCmd(self, args, cmd, mail): """Parse subscription request and send confirmation request."""
bfed9ae359e2eea17ad856f6284f7870ede7b63f /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2120/bfed9ae359e2eea17ad856f6284f7870ede7b63f/MailCommandHandler.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4389, 16352, 5931, 12, 2890, 16, 833, 16, 1797, 16, 4791, 4672, 3536, 3201, 4915, 590, 471, 1366, 14296, 590, 12123, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4389, 16352, 5931, 12, 2890, 16, 833, 16, 1797, 16, 4791, 4672, 3536, 3201, 4915, 590, 471, 1366, 14296, 590, 12123, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
res = self._getConnectionTransID(connection,transName) if not res['OK']: return res connection = res['Value']['Connection'] transID = res['Value']['TransformationID'] req = "INSERT INTO TransformationLog (TransformationID,Message,Author,MessageDate) VALUES (%s,'%s','%s',UTC_TIMESTAMP());" % (transID,message,authorDN) return self._update(req,connection) def getTransformationLogging(self,transName,connection=False):
res = self._getConnectionTransID( connection, transName ) if not res['OK']: return res connection = res['Value']['Connection'] transID = res['Value']['TransformationID'] req = "INSERT INTO TransformationLog (TransformationID,Message,Author,MessageDate) VALUES (%s,'%s','%s',UTC_TIMESTAMP());" % ( transID, message, authorDN ) return self._update( req, connection ) def getTransformationLogging( self, transName, connection = False ):
def __updateTransformationLogging(self,transName,message,authorDN,connection=False): """ Update the Transformation log table with any modifications """ if not authorDN: res = getProxyInfo(False,False) if res['OK']: authorDN = res['Value']['identity'] res = self._getConnectionTransID(connection,transName) if not res['OK']: return res connection = res['Value']['Connection'] transID = res['Value']['TransformationID'] req = "INSERT INTO TransformationLog (TransformationID,Message,Author,MessageDate) VALUES (%s,'%s','%s',UTC_TIMESTAMP());" % (transID,message,authorDN) return self._update(req,connection)
9ad007ea503b29694fc081c1646b7c5ecd07b1f2 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12864/9ad007ea503b29694fc081c1646b7c5ecd07b1f2/TransformationDB.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2725, 15292, 7735, 12, 2890, 16, 2338, 461, 16, 2150, 16, 4161, 8609, 16, 4071, 33, 8381, 4672, 3536, 2315, 326, 21274, 613, 1014, 598, 1281, 17953, 3536, 309, 486, 2869, 8609, 30, 400, 273, 18992, 966, 12, 8381, 16, 8381, 13, 309, 400, 3292, 3141, 3546, 30, 2869, 8609, 273, 400, 3292, 620, 21712, 10781, 3546, 400, 273, 365, 6315, 588, 1952, 1429, 734, 12, 4071, 16, 2338, 461, 13, 309, 486, 400, 3292, 3141, 3546, 30, 327, 400, 1459, 273, 400, 3292, 620, 21712, 1952, 3546, 906, 734, 273, 400, 3292, 620, 21712, 15292, 734, 3546, 1111, 273, 315, 11356, 12421, 21274, 1343, 261, 15292, 734, 16, 1079, 16, 3594, 16, 1079, 1626, 13, 13477, 6142, 87, 11189, 9, 87, 17023, 9, 87, 2187, 11471, 67, 17201, 10663, 6, 738, 261, 2338, 734, 16, 2150, 16, 4161, 8609, 13, 327, 365, 6315, 2725, 12, 3658, 16, 4071, 13, 225, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2725, 15292, 7735, 12, 2890, 16, 2338, 461, 16, 2150, 16, 4161, 8609, 16, 4071, 33, 8381, 4672, 3536, 2315, 326, 21274, 613, 1014, 598, 1281, 17953, 3536, 309, 486, 2869, 8609, 30, 400, 273, 18992, 966, 12, 8381, 16, 8381, 13, 309, 400, 3292, 3141, 3546, 30, 2869, 8609, 273, 400, 3292, 620, 21712, 10781, 3546, 400, 273, 365, 6315, 588, 1952, 1429, 734, 12, 4071, 16, 2338, 461, 13, 309, 486, 400, 3292, 3141, 3546, 30, 327, 400, 1459, 273, 400, 3292, 620, 21712, 1952, 3546, 906, 734, 273, 400, 3292, 620, 21712, 15292, 734, 3546, 1111, 273, 315, 11356, 12421, 21274, 1343, 261, 15292, 734, 16, 1079, 16, 3594, 16, 1079, 1626, 13, 13477, 2 ]
self._DocumentStateChanged() return rc
def OnOpenDocument(self, name): rc = ParentEditorDocument.OnOpenDocument(self, name)
0c9ebab2188c71a606f27405886771ad61f42c35 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/992/0c9ebab2188c71a606f27405886771ad61f42c35/document.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2755, 3678, 2519, 12, 2890, 16, 508, 4672, 4519, 273, 9520, 6946, 2519, 18, 1398, 3678, 2519, 12, 2890, 16, 508, 13, 2, 0, 0, 0, 0, 0, 0, 0,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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2755, 3678, 2519, 12, 2890, 16, 508, 4672, 4519, 273, 9520, 6946, 2519, 18, 1398, 3678, 2519, 12, 2890, 16, 508, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
P.imshow(panel,interpolation='nearest',cmap=P.cm.gray) P.plot([ref_pos[1],target_pos[1]],[ref_pos[0],target_pos[0]],'r-o') for rf in reference_frames: ref_pos = rf['source'].info['position'] P.plot([ref_pos[1]],[ref_img.shape[0] - ref_pos[0]],'-wo') P.rcParams['figure.figsize'] = (3.24,3.24) P.axis('off') P.box('off') P.savefig('features_%d.eps' % fnum) P.close()
def _lpt_peak(pos,frame,bmf,window_shape,fft_shape): corr = lpt_corr([bmf['source'].info['reference']],frame,bmf,[pos],window_shape,fft_shape) return corr[0]
cc3c399ed2f306cdf02d244f317c4793f63d5a0c /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12843/cc3c399ed2f306cdf02d244f317c4793f63d5a0c/logpolar.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 80, 337, 67, 10244, 12, 917, 16, 3789, 16, 70, 16126, 16, 5668, 67, 4867, 16, 25174, 67, 4867, 4672, 19480, 273, 328, 337, 67, 17515, 3816, 70, 16126, 3292, 3168, 29489, 1376, 3292, 6180, 3546, 6487, 3789, 16, 70, 16126, 16, 63, 917, 6487, 5668, 67, 4867, 16, 25174, 67, 4867, 13, 327, 19480, 63, 20, 65, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 80, 337, 67, 10244, 12, 917, 16, 3789, 16, 70, 16126, 16, 5668, 67, 4867, 16, 25174, 67, 4867, 4672, 19480, 273, 328, 337, 67, 17515, 3816, 70, 16126, 3292, 3168, 29489, 1376, 3292, 6180, 3546, 6487, 3789, 16, 70, 16126, 16, 63, 917, 6487, 5668, 67, 4867, 16, 25174, 67, 4867, 13, 327, 19480, 63, 20, 65, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
sage: ct1 = CartanType(['A',1],['B',2]) sage: ct2 = CartanType(['B',2],['A',1]) sage: ct3 = CartanType(['A',4]) sage: ct = [ct1, ct2, ct3] sage: [[x.__cmp__(y) for x in ct] for y in ct] [[0, 1, -1], [-1, 0, -1], [1, 1, 0]] sage: sorted(ct) [['A', 4], A1xB2, B2xA1]
sage: ct1 = CartanType(['B',2]).dual() sage: ct2 = CartanType(['B',2]).dual() sage: ct3 = CartanType(['D',4]).dual() sage: ct1 == ct2 True sage: ct1 == ct3 False
def __cmp__(self, other): """ EXAMPLES: sage: ct1 = CartanType(['A',1],['B',2]) sage: ct2 = CartanType(['B',2],['A',1]) sage: ct3 = CartanType(['A',4]) sage: ct = [ct1, ct2, ct3] sage: [[x.__cmp__(y) for x in ct] for y in ct] [[0, 1, -1], [-1, 0, -1], [1, 1, 0]] sage: sorted(ct) [['A', 4], A1xB2, B2xA1] """ if other.__class__ != self.__class__: return cmp(self.__class__, other.__class__) return cmp(self._dual, other._dual)
cd1dea0f711f2dc4d912fdde719819a16da8a0fa /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9417/cd1dea0f711f2dc4d912fdde719819a16da8a0fa/type_dual.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 9625, 972, 12, 2890, 16, 1308, 4672, 3536, 5675, 8900, 11386, 30, 272, 410, 30, 5691, 21, 273, 17695, 304, 559, 12, 3292, 38, 2187, 22, 65, 2934, 72, 1462, 1435, 272, 410, 30, 5691, 22, 273, 17695, 304, 559, 12, 3292, 38, 2187, 22, 65, 2934, 72, 1462, 1435, 272, 410, 30, 5691, 23, 273, 17695, 304, 559, 12, 3292, 40, 2187, 24, 65, 2934, 72, 1462, 1435, 272, 410, 30, 5691, 21, 422, 5691, 22, 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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 9625, 972, 12, 2890, 16, 1308, 4672, 3536, 5675, 8900, 11386, 30, 272, 410, 30, 5691, 21, 273, 17695, 304, 559, 12, 3292, 38, 2187, 22, 65, 2934, 72, 1462, 1435, 272, 410, 30, 5691, 22, 273, 17695, 304, 559, 12, 3292, 38, 2187, 22, 65, 2934, 72, 1462, 1435, 272, 410, 30, 5691, 23, 273, 17695, 304, 559, 12, 3292, 40, 2187, 24, 65, 2934, 72, 1462, 1435, 272, 410, 30, 5691, 21, 422, 5691, 22, 1053, 272, 410, 30, 5691, 21, 422, 5691, 23, 1083, 3536, 309, 1308, 16186, 1106, 972, 480, 365, 16186, 1106, 972, 30, 327, 9411, 12, 2890, 16186, 1106, 972, 16, 1308, 16186, 1106, 972, 13, 327, 9411, 12, 2890, 6315, 2 ]
return self.run_command('git svn dcommit')
return self.run_command(['git', 'svn', 'dcommit'])
def push_local_commits_to_server(self): if self.dryrun: return "Dry run, no remote commit." return self.run_command('git svn dcommit')
47776b014bbf74781b60545bb5f16d07a3aa548e /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9392/47776b014bbf74781b60545bb5f16d07a3aa548e/scm.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1817, 67, 3729, 67, 27000, 67, 869, 67, 3567, 12, 2890, 4672, 309, 365, 18, 25011, 2681, 30, 327, 315, 40, 1176, 1086, 16, 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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1817, 67, 3729, 67, 27000, 67, 869, 67, 3567, 12, 2890, 4672, 309, 365, 18, 25011, 2681, 30, 327, 315, 40, 1176, 1086, 16, 1158, 2632, 3294, 1199, 327, 365, 18, 2681, 67, 3076, 2668, 6845, 5893, 82, 302, 7371, 6134, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
'certificate': terp.get('certificate', ''),
'certificate': terp.get('certificate'),
def update_list(self, cr, uid, context={}): robj = self.pool.get('ir.module.repository') res = [0, 0] # [update, add]
7a39d075905015df8a4effc2b0457c1deea774a3 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12853/7a39d075905015df8a4effc2b0457c1deea774a3/module.py
[ 1, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1089, 67, 1098, 12, 2890, 16, 4422, 16, 4555, 16, 819, 12938, 4672, 721, 441, 273, 365, 18, 6011, 18, 588, 2668, 481, 18, 2978, 18, 9071, 6134, 400, 273, 306, 20, 16, 374, 65, 468, 306, 2725, 16, 527, 65, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
return os.fstat(data_or_fp.fileno().st_size)
return os.fstat(data_or_fp.fileno()).st_size
def get_content_length(data_or_fp): """Try to get the content length from the given string or file pointer. If the length can't be determined the return value is None. """ try: return len(data_or_fp) except TypeError: try: return os.fstat(data_or_fp.fileno().st_size) except (AttributeError, OSError): pass
be56c20361f5e73dd6ce37ccbb8b064682ccd908 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12815/be56c20361f5e73dd6ce37ccbb8b064682ccd908/net.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 1745, 67, 2469, 12, 892, 67, 280, 67, 7944, 4672, 3536, 7833, 358, 336, 326, 913, 769, 628, 326, 864, 533, 578, 585, 4407, 18, 225, 971, 326, 769, 848, 1404, 506, 11383, 326, 327, 460, 353, 599, 18, 3536, 775, 30, 327, 562, 12, 892, 67, 280, 67, 7944, 13, 1335, 3580, 30, 775, 30, 327, 1140, 18, 74, 5642, 12, 892, 67, 280, 67, 7944, 18, 7540, 5764, 1435, 2934, 334, 67, 1467, 1335, 261, 1499, 668, 16, 10002, 4672, 1342, 282, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 1745, 67, 2469, 12, 892, 67, 280, 67, 7944, 4672, 3536, 7833, 358, 336, 326, 913, 769, 628, 326, 864, 533, 578, 585, 4407, 18, 225, 971, 326, 769, 848, 1404, 506, 11383, 326, 327, 460, 353, 599, 18, 3536, 775, 30, 327, 562, 12, 892, 67, 280, 67, 7944, 13, 1335, 3580, 30, 775, 30, 327, 1140, 18, 74, 5642, 12, 892, 67, 280, 67, 7944, 18, 7540, 5764, 1435, 2934, 334, 67, 1467, 1335, 261, 1499, 668, 16, 10002, 4672, 1342, 282, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
def findall(pattern, string, maxsplit=0):
def findall(pattern, string):
def findall(pattern, string, maxsplit=0): """Return a list of all non-overlapping matches in the string. If one or more groups are present in the pattern, return a list of groups; this will be a list of tuples if the pattern has more than one group. Empty matches are included in the result.""" return _compile(pattern, 0).findall(string, maxsplit)
f1056bcc31c4324f75316a57e0a45a15cda57be6 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12029/f1056bcc31c4324f75316a57e0a45a15cda57be6/sre.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 11842, 12, 4951, 16, 533, 4672, 3536, 990, 279, 666, 434, 777, 1661, 17, 17946, 1382, 1885, 316, 326, 533, 18, 225, 971, 1245, 578, 1898, 3252, 854, 3430, 316, 326, 1936, 16, 327, 279, 666, 434, 3252, 31, 333, 903, 506, 279, 666, 434, 10384, 309, 326, 1936, 711, 1898, 2353, 1245, 1041, 18, 225, 8953, 1885, 854, 5849, 316, 326, 563, 12123, 327, 389, 11100, 12, 4951, 16, 374, 2934, 4720, 454, 12, 1080, 16, 943, 4939, 13, 225, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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 854, 3430, 316, 326, 1936, 16, 327, 279, 666, 434, 3252, 31, 333, 903, 506, 279, 666, 434, 10384, 309, 326, 1936, 711, 1898, 2353, 1245, 1041, 18, 225, 8953, 1885, 854, 5849, 316, 326, 563, 12123, 327, 389, 11100, 12, 4951, 16, 374, 2934, 4720, 454, 12, 1080, 16, 943, 4939, 13, 225, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
command = 'INSERT INTO Files (name, size, mtime, type) ' + \
command = 'REPLACE INTO Files (name, size, mtime, type) ' + \
def walk(top, path, cursor, xdb, indexer, lang): ''' recursive folder walk''' global langmap dirpath = os.path.join(top, path) if path != '.': command = 'INSERT INTO Files (name, size, mtime, type) ' + \ 'values (\'%s\', NULL, NULL, \'dir\') ' % ("/" + path) try: cursor.execute(command) except sqlite3.Error, msg: print 'Error: ', msg print "Command: ", command for f in os.listdir(dirpath): abspath = os.path.join(dirpath, f) fstat = os.stat(abspath) mode = fstat[ST_MODE] if path != '.': relpath = os.path.join(path, f) else: relpath = f if S_ISDIR(mode): walk(top, relpath, cursor, xdb, indexer, lang) elif S_ISREG(mode): print 'Indexing file %s' % relpath command = 'INSERT INTO Files (name, size, mtime, type) ' + \ 'values (\'%s\', %i, %i, \'reg\') ' % \ ("/"+relpath, fstat.st_size, fstat.st_mtime) try: cursor.execute(command) except sqlite3.Error, msg: print 'Error: ', msg print "Command: ", command # temp field lang if lang == None: indexXapian.indexFile(top, relpath, xdb, indexer) elif os.path.splitext(relpath)[1] in langmap[lang]: indexXapian.indexFile(top, relpath, xdb, indexer)
738cf53013d62cf9f83f8233bdcc76672264d8a1 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/8874/738cf53013d62cf9f83f8233bdcc76672264d8a1/indexer.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 5442, 12, 3669, 16, 589, 16, 3347, 16, 619, 1966, 16, 12635, 16, 3303, 4672, 9163, 5904, 3009, 5442, 26418, 225, 2552, 3303, 1458, 17803, 273, 1140, 18, 803, 18, 5701, 12, 3669, 16, 589, 13, 225, 309, 589, 480, 2611, 30, 1296, 273, 296, 21726, 12421, 6471, 261, 529, 16, 963, 16, 13158, 16, 618, 13, 296, 397, 521, 296, 2372, 261, 3730, 9, 87, 22369, 3206, 16, 3206, 16, 7164, 1214, 3730, 13, 296, 738, 7566, 4898, 397, 589, 13, 775, 30, 3347, 18, 8837, 12, 3076, 13, 1335, 16184, 23, 18, 668, 16, 1234, 30, 1172, 296, 668, 30, 2265, 1234, 1172, 315, 2189, 30, 3104, 1296, 225, 364, 284, 316, 225, 1140, 18, 1098, 1214, 12, 1214, 803, 4672, 9488, 273, 1140, 18, 803, 18, 5701, 12, 1214, 803, 16, 284, 13, 284, 5642, 225, 273, 1140, 18, 5642, 12, 5113, 803, 13, 1965, 273, 284, 5642, 63, 882, 67, 7038, 65, 309, 589, 480, 2611, 30, 14614, 273, 1140, 18, 803, 18, 5701, 12, 803, 16, 284, 13, 469, 30, 14614, 273, 284, 309, 348, 67, 5127, 4537, 12, 3188, 4672, 5442, 12, 3669, 16, 14614, 16, 3347, 16, 619, 1966, 16, 12635, 16, 3303, 13, 1327, 348, 67, 5127, 5937, 12, 3188, 4672, 1172, 296, 24465, 585, 738, 87, 11, 738, 14614, 1296, 273, 296, 21726, 12421, 6471, 261, 529, 16, 963, 16, 13158, 16, 618, 13, 296, 397, 521, 296, 2372, 261, 3730, 9, 87, 22369, 738, 77, 16, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 5442, 12, 3669, 16, 589, 16, 3347, 16, 619, 1966, 16, 12635, 16, 3303, 4672, 9163, 5904, 3009, 5442, 26418, 225, 2552, 3303, 1458, 17803, 273, 1140, 18, 803, 18, 5701, 12, 3669, 16, 589, 13, 225, 309, 589, 480, 2611, 30, 1296, 273, 296, 21726, 12421, 6471, 261, 529, 16, 963, 16, 13158, 16, 618, 13, 296, 397, 521, 296, 2372, 261, 3730, 9, 87, 22369, 3206, 16, 3206, 16, 7164, 1214, 3730, 13, 296, 738, 7566, 4898, 397, 589, 13, 775, 30, 3347, 18, 8837, 12, 3076, 13, 1335, 16184, 23, 18, 668, 16, 1234, 30, 1172, 296, 668, 30, 2265, 1234, 1172, 315, 2189, 30, 3104, 1296, 225, 364, 284, 316, 225, 1140, 18, 1098, 2 ]
cf_name = 'config files %s' % ', '.join(options.configfiles
cf_name = 'config files %s' % ', '.join(options.configfiles)
def parse_arguments(): # Construct the option parser. usage = '%prog ACTION [options] NAMES...' version = "Epydoc, version %s" % epydoc.__version__ optparser = OptionParser(usage=usage, version=version) action_group = OptionGroup(optparser, 'Actions') options_group = OptionGroup(optparser, 'Options') # Add options -- Actions action_group.add_option( # --html "--html", action="store_const", dest="action", const="html", help="Write HTML output.") action_group.add_option( # --latex "--text", action="store_const", dest="action", const="text", help="Write plaintext output. (not implemented yet)") action_group.add_option( # --latex "--latex", action="store_const", dest="action", const="latex", help="Write LaTeX output.") action_group.add_option( # --dvi "--dvi", action="store_const", dest="action", const="dvi", help="Write DVI output.") action_group.add_option( # --ps "--ps", action="store_const", dest="action", const="ps", help="Write Postscript output.") action_group.add_option( # --pdf "--pdf", action="store_const", dest="action", const="pdf", help="Write PDF output.") action_group.add_option( # --check "--check", action="store_const", dest="action", const="check", help="Check completeness of docs.") # Add options -- Options options_group.add_option( # --output "--output", "-o", dest="target", metavar="PATH", help="The output directory. If PATH does not exist, then " "it will be created.") options_group.add_option( # --show-imports "--inheritance", dest="inheritance", metavar="STYLE", help="The format for showing inheritance objects. STYLE " "should be one of: %s." % ', '.join(INHERITANCE_STYLES)) options_group.add_option( # --output "--docformat", dest="docformat", metavar="NAME", help="The default markup language for docstrings. Defaults " "to \"%s\"." % DEFAULT_DOCFORMAT) options_group.add_option( # --css "--css", dest="css", metavar="STYLESHEET", help="The CSS stylesheet. STYLESHEET can be either a " "builtin stylesheet or the name of a CSS file.") options_group.add_option( # --name "--name", dest="prj_name", metavar="NAME", help="The documented project's name (for the navigation bar).") options_group.add_option( # --url "--url", dest="prj_url", metavar="URL", help="The documented project's URL (for the navigation bar).") options_group.add_option( # --navlink "--navlink", dest="prj_link", metavar="HTML", help="HTML code for a navigation link to place in the " "navigation bar.") options_group.add_option( # --top "--top", dest="top_page", metavar="PAGE", help="The \"top\" page for the HTML documentation. PAGE can " "be a URL, the name of a module or class, or one of the " "special names \"trees.html\", \"indices.html\", or \"help.html\"") options_group.add_option( # --help-file "--help-file", dest="help_file", metavar="FILE", help="An alternate help file. FILE should contain the body " "of an HTML file -- navigation bars will be added to it.") options_group.add_option( # --frames "--show-frames", action="store_true", dest="show_frames", help="Include frames in the HTML output. (default)") options_group.add_option( # --no-frames "--no-frames", action="store_false", dest="show_frames", help="Do not include frames in the HTML output.") options_group.add_option( # --private "--show-private", action="store_true", dest="show_private", help="Include private variables in the output. (default)") options_group.add_option( # --no-private "--no-private", action="store_false", dest="show_private", help="Do not include private variables in the output.") options_group.add_option( # --show-imports "--show-imports", action="store_true", dest="show_imports", help="List each module's imports.") options_group.add_option( # --show-imports "--no-imports", action="store_false", dest="show_imports", help="Do not list each module's imports. (default)") options_group.add_option( # --quiet "--quiet", "-q", action="count", dest="quiet", help="Decrease the verbosity.") options_group.add_option( # --verbose "--verbose", "-v", action="count", dest="verbose", help="Increase the verbosity.") options_group.add_option( # --debug "--debug", action="store_true", dest="debug", help="Show full tracebacks for internal errors.") options_group.add_option( # --parse-only "--parse-only", action="store_false", dest="introspect", help="Get all information from parsing (don't introspect)") options_group.add_option( # --introspect-only "--introspect-only", action="store_false", dest="parse", help="Get all information from introspecting (don't parse)") if epydoc.DEBUG: # this option is for developers, not users. options_group.add_option( "--profile-epydoc", action="store_true", dest="profile", help="Run the profiler. Output will be written to profile.out") options_group.add_option( "--dotpath", dest="dotpath", metavar='PATH', help="The path to the Graphviz 'dot' executable.") options_group.add_option( '--config', action='append', dest="configfiles", metavar='FILE', help=("A configuration file, specifying additional OPTIONS " "and/or NAMES. This option may be repeated.")) options_group.add_option( '--graph', action='append', dest='graphs', metavar='GRAPHTYPE', help=("Include graphs of type GRAPHTYPE in the generated output. " "Graphs are generated using the Graphviz dot executable. " "If this executable is not on the path, then use --dotpath " "to specify its location. This option may be repeated to " "include multiple graph types in the output. GRAPHTYPE " "should be one of: all, %s." % ', '.join(GRAPH_TYPES))) options_group.add_option( '--separate-classes', action='store_true', dest='list_classes_separately', help=("When generating LaTeX or PDF output, list each class in " "its own section, instead of listing them under their " "containing module.")) options_group.add_option( '--show-sourcecode', action='store_true', dest='include_source_code', help=("Include source code with syntax highlighting in the " "HTML output.")) options_group.add_option( '--no-sourcecode', action='store_false', dest='include_source_code', help=("Do not include source code with syntax highlighting in the " "HTML output.")) options_group.add_option( '--pstat', action='append', dest='pstat_files', metavar='FILE', help="A pstat output file, to be used in generating call graphs.") # Add the option groups. optparser.add_option_group(action_group) optparser.add_option_group(options_group) # Set the option parser's defaults. optparser.set_defaults(action="html", show_frames=True, docformat=DEFAULT_DOCFORMAT, show_private=True, show_imports=False, inheritance="listed", verbose=0, quiet=0, parse=True, introspect=True, debug=epydoc.DEBUG, profile=False, graphs=[], list_classes_separately=False, include_source_code=True, pstat_files=[]) # Parse the arguments. options, names = optparser.parse_args() # Process any config files. if options.configfiles: try: parse_configfiles(options.configfiles, options, names) except (KeyboardInterrupt,SystemExit): raise except Exception, e: if len(options.configfiles) == 1: cf_name = 'config file %s' % options.configfiles[0] else: cf_name = 'config files %s' % ', '.join(options.configfiles optparser.error('Error reading %s:\n %s' % (cf_name, e)) # Check to make sure all options are valid. if len(names) == 0: optparser.error("No names specified.") # perform shell expansion. for i, name in enumerate(names[:]): if '?' in name or '*' in name: names[i:i+1] = glob(name) if options.inheritance not in INHERITANCE_STYLES: optparser.error("Bad inheritance style. Valid options are " + ",".join(INHERITANCE_STYLES)) if not options.parse and not options.introspect: optparser.error("Invalid option combination: --parse-only " "and --introspect-only.") if options.action == 'text' and len(names) > 1: optparser.error("--text option takes only one name.") # Check the list of requested graph types to make sure they're # acceptable. options.graphs = [graph_type.lower() for graph_type in options.graphs] for graph_type in options.graphs: if graph_type == 'callgraph' and not options.pstat_files: optparser.error('"callgraph" graph type may only be used if ' 'one or more pstat files are specified.') # If it's 'all', then add everything (but don't add callgraph if # we don't have any profiling info to base them on). if graph_type == 'all': if options.pstat_files: options.graphs = GRAPH_TYPES else: options.graphs = [g for g in GRAPH_TYPES if g != 'callgraph'] break elif graph_type not in GRAPH_TYPES: optparser.error("Invalid graph type %s." % graph_type) # Calculate verbosity. options.verbosity = options.verbose - options.quiet # The target default depends on the action. if options.target is None: options.target = options.action # Return parsed args. return options, names
5817516e8b44ee5cc092727e2126d52183c5541e /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3512/5817516e8b44ee5cc092727e2126d52183c5541e/cli.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1109, 67, 7099, 13332, 468, 14291, 326, 1456, 2082, 18, 4084, 273, 1995, 14654, 11385, 306, 2116, 65, 6048, 55, 7821, 1177, 273, 315, 41, 2074, 2434, 16, 1177, 738, 87, 6, 738, 425, 2074, 2434, 16186, 1589, 972, 2153, 4288, 273, 18862, 12, 9167, 33, 9167, 16, 1177, 33, 1589, 13, 1301, 67, 1655, 273, 2698, 1114, 12, 3838, 4288, 16, 296, 6100, 6134, 702, 67, 1655, 273, 2698, 1114, 12, 3838, 4288, 16, 296, 1320, 6134, 225, 468, 1436, 702, 1493, 18765, 1301, 67, 1655, 18, 1289, 67, 3482, 12, 1171, 9079, 468, 1493, 2620, 5238, 2620, 3113, 1301, 1546, 2233, 67, 10248, 3113, 1570, 1546, 1128, 3113, 1866, 1546, 2620, 3113, 2809, 1546, 3067, 3982, 876, 1199, 13, 1301, 67, 1655, 18, 1289, 67, 3482, 12, 1171, 9079, 468, 1493, 26264, 5238, 955, 3113, 1301, 1546, 2233, 67, 10248, 3113, 1570, 1546, 1128, 3113, 1866, 1546, 955, 3113, 2809, 1546, 3067, 11917, 876, 18, 261, 902, 8249, 4671, 2225, 13, 1301, 67, 1655, 18, 1289, 67, 3482, 12, 1171, 9079, 468, 1493, 26264, 5238, 26264, 3113, 1301, 1546, 2233, 67, 10248, 3113, 1570, 1546, 1128, 3113, 1866, 1546, 26264, 3113, 2809, 1546, 3067, 21072, 21575, 60, 876, 1199, 13, 1301, 67, 1655, 18, 1289, 67, 3482, 12, 1171, 9079, 468, 1493, 72, 522, 5238, 72, 522, 3113, 1301, 1546, 2233, 67, 10248, 3113, 1570, 1546, 1128, 3113, 1866, 1546, 72, 522, 3113, 2809, 1546, 3067, 463, 4136, 876, 1199, 13, 1301, 67, 1655, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1109, 67, 7099, 13332, 468, 14291, 326, 1456, 2082, 18, 4084, 273, 1995, 14654, 11385, 306, 2116, 65, 6048, 55, 7821, 1177, 273, 315, 41, 2074, 2434, 16, 1177, 738, 87, 6, 738, 425, 2074, 2434, 16186, 1589, 972, 2153, 4288, 273, 18862, 12, 9167, 33, 9167, 16, 1177, 33, 1589, 13, 1301, 67, 1655, 273, 2698, 1114, 12, 3838, 4288, 16, 296, 6100, 6134, 702, 67, 1655, 273, 2698, 1114, 12, 3838, 4288, 16, 296, 1320, 6134, 225, 468, 1436, 702, 1493, 18765, 1301, 67, 1655, 18, 1289, 67, 3482, 12, 1171, 9079, 468, 1493, 2620, 5238, 2620, 3113, 1301, 1546, 2233, 67, 10248, 3113, 1570, 1546, 1128, 3113, 1866, 1546, 2620, 3113, 2809, 1546, 3067, 3982, 2 ]
sharedItem.sharedIn.remove(self)
self.items.remove(item)
def removeSharedItem(self, item): """ Remove an item from the share's sharedIn refcoll, unstamping if the last share for this item """ if not pim.has_stamp(item, SharedItem): return sharedItem = SharedItem(item) logger.info("Removing item %s from sharedIn", item.itsUUID) sharedItem.sharedIn.remove(self) if not sharedItem.sharedIn: logger.info("Unstamping item %s as SharedItem", item.itsUUID) sharedItem.remove()
a1839f3348df6bebbd146f3cbe8acd158244820b /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9228/a1839f3348df6bebbd146f3cbe8acd158244820b/shares.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1206, 7887, 1180, 12, 2890, 16, 761, 4672, 3536, 3581, 392, 761, 628, 326, 7433, 1807, 5116, 382, 1278, 12910, 16, 640, 14317, 310, 309, 326, 1142, 7433, 364, 333, 761, 3536, 309, 486, 293, 381, 18, 5332, 67, 14317, 12, 1726, 16, 10314, 1180, 4672, 327, 5116, 1180, 273, 10314, 1180, 12, 1726, 13, 1194, 18, 1376, 2932, 18939, 761, 738, 87, 628, 5116, 382, 3113, 761, 18, 1282, 5562, 13, 365, 18, 3319, 18, 4479, 12, 1726, 13, 309, 486, 5116, 1180, 18, 11574, 382, 30, 1194, 18, 1376, 2932, 984, 14317, 310, 761, 738, 87, 487, 10314,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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1206, 7887, 1180, 12, 2890, 16, 761, 4672, 3536, 3581, 392, 761, 628, 326, 7433, 1807, 5116, 382, 1278, 12910, 16, 640, 14317, 310, 309, 326, 1142, 7433, 364, 333, 761, 3536, 309, 486, 293, 381, 18, 5332, 67, 14317, 12, 1726, 16, 10314, 1180, 4672, 327, 5116, 1180, 273, 10314, 1180, 12, 1726, 13, 1194, 18, 1376, 2932, 18939, 761, 738, 87, 628, 5116, 382, 3113, 761, 18, 1282, 5562, 13, 365, 18, 3319, 18, 4479, 12, 1726, 13, 309, 486, 5116, 1180, 18, 11574, 382, 30, 1194, 18, 1376, 2932, 984, 14317, 310, 761, 738, 87, 487, 10314, 1180, 3113, 761, 18, 1282, 5562, 13, 5116, 1180, 18, 4479, 1435, 2, -100, -100, -100, -100, -100, -100 ]
def getSuggestionListFile(word, filename): try: f = file(filename, 'r') except IOError: return [] pattern = sre.compile(word+r'.*?\b') matches = [] for line in f.readlines(): for match in pattern.findall(line): if match != word and match not in matches: matches.append(match) matches.sort() return matches def complete(word, line, column, filename=None): moduleName = getModuleNameFromLine(word, line, column) if not moduleName: return getSuggestionListFile(word=word, filename=filename) return getSuggestionListModule(word, moduleName) class Usage(Exception): def __init__(self, msg): self.msg = msg def main(argv=None): if argv is None: argv = sys.argv try: try: opts, args = getopt.getopt(argv[1:], "hw:l:c:f:", ["help","output=","word=","line=","column=","filename="]) except getopt.error, msg: raise Usage(msg) tmColumn = None tmLine = None tmWord = None tmFilename = None for option, value in opts: if option in ("-h", "--help"): raise Usage(__doc__) if option in ("-w", "--word"): tmWord = value if option in ("-l", "--line"): tmLine = value if option in ("-c", "--column"): tmColumn = int(value) if option in ("-f", "--filename"): tmFilename = value if not (tmWord and tmLine and tmColumn and tmFilename): raise Usage(__doc__) except Usage, err: print >>sys.stderr, str(err.msg) print >>sys.stderr, "\t for help use --help" return 2 for match in complete(word=tmWord, line=tmLine, column=tmColumn, filename=tmFilename): print match if __name__ == "__main__": sys.exit(main())
if __name__ == '__main__': unittest.main()
def getSuggestionListFile(word, filename): try: f = file(filename, 'r') except IOError: return [] pattern = sre.compile(word+r'.*?\b') matches = [] for line in f.readlines(): for match in pattern.findall(line): if match != word and match not in matches: matches.append(match) matches.sort() return matches
c4bbd78983b64186544bb9ad103e27aa675bbc54 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12650/c4bbd78983b64186544bb9ad103e27aa675bbc54/pythonCompletionTest.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1322, 21166, 682, 812, 12, 1095, 16, 1544, 4672, 775, 30, 284, 273, 585, 12, 3459, 16, 296, 86, 6134, 1335, 8340, 30, 327, 5378, 1936, 273, 272, 266, 18, 11100, 12, 1095, 15, 86, 11, 4509, 10936, 70, 6134, 1885, 273, 5378, 364, 980, 316, 284, 18, 896, 3548, 13332, 364, 845, 316, 1936, 18, 4720, 454, 12, 1369, 4672, 309, 845, 480, 2076, 471, 845, 486, 316, 1885, 30, 1885, 18, 6923, 12, 1916, 13, 1885, 18, 3804, 1435, 327, 1885, 225, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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22398, 316, 326, 981, 30, 1652, 1322, 21166, 682, 812, 12, 1095, 16, 1544, 4672, 775, 30, 284, 273, 585, 12, 3459, 16, 296, 86, 6134, 1335, 8340, 30, 327, 5378, 1936, 273, 272, 266, 18, 11100, 12, 1095, 15, 86, 11, 4509, 10936, 70, 6134, 1885, 273, 5378, 364, 980, 316, 284, 18, 896, 3548, 13332, 364, 845, 316, 1936, 18, 4720, 454, 12, 1369, 4672, 309, 845, 480, 2076, 471, 845, 486, 316, 1885, 30, 1885, 18, 6923, 12, 1916, 13, 1885, 18, 3804, 1435, 327, 1885, 225, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
savefig(figName)
savefig(outputPath +"/" + figName)
def plotsnrchisq(gpsTime,frameFile,outputPath,inspProcParams,tableFileName,imgFile,page): rsqThreshold = 0; for row in inspProcParams: if row.param == "--channel-name": chanStringBase = row.value ifoName = str(row.value).split(":",1) if row.param == "--segment-length": segLen = eval(row.value) if row.param == "--sample-rate": sampleRate = eval(row.value) if row.param == "--segment-overlap": segOverlap = eval(row.value) if (row.param == "--chisq-delta") or (row.param == "--minimal-match"): chisqDelta = eval(row.value) if row.param =="--chisq-bins": chisqBins = eval(row.value) if row.param == "--snr-threshold": snrThreshold = eval(row.value) if row.param == "--chisq-threshold": chisqThreshold = eval(row.value) if row.param == "--rsq-veto-threshold": rsqThreshold = eval(row.value) if row.param == "--trig-start-time": trigStart = eval(row.value) if row.param == "--gps-start-time": gpsStart = eval(row.value) segLenSec = segLen / sampleRate segOverlapSec = segOverlap / sampleRate if (trigStart): trigPosition = int((trigStart - gpsStart - segOverlapSec ) / (segLenSec -segOverlapSec)) else: trigPosition = 0 gpsPosition = int((eval(gpsTime) - gpsStart - segOverlapSec/2. ) / (segLenSec -segOverlapSec)) if (trigPosition < 0): trigPosition = 0 position = gpsPosition - trigPosition chanNumber = str(position) chanNameSnr = chanStringBase + "_SNRSQ_" + chanNumber chanNameChisq = chanStringBase + "_CHISQ_" + chanNumber # now, read the data !! # The window width should be an input argument maybe ? duration = 2.0 squareSnr_tuple = Fr.frgetvect(frameFile,chanNameSnr,-1,segLenSec,0) squareChisq_tuple = Fr.frgetvect(frameFile,chanNameChisq,-1,segLenSec,0) snr_position = eval(gpsTime) - (gpsStart + gpsPosition* (segLenSec - segOverlapSec) ) chisq_position = snr_position # compute the snr vector snr_vector = sqrt(squareSnr_tuple[0]) # print squareSnr_tuple snr_time = array(range(0, segLen)) * squareSnr_tuple[3][0] - snr_position # compute the r^2 rsq_vector = squareChisq_tuple[0] chisq_time = array(range(0, segLen)) * squareChisq_tuple[3][0] - chisq_position # compute the normalized chisq if(chisqBins > 0): chisqNorm_vector = rsq_vector/(1 + chisqDelta/chisqBins*squareSnr_tuple[0]) else: chisqNorm_vector = rsq_vector # define the time boundaries of the plot snr_start = (snr_position - duration/2.) * 1/squareSnr_tuple[3][0] snr_stop = (snr_position + duration/2.) * 1/squareSnr_tuple[3][0] lengthSnr = int(snr_stop) - int(snr_start) chisq_start = (chisq_position - duration/2.) * 1/squareChisq_tuple[3][0] chisq_stop = (chisq_position + duration/2.) * 1/squareChisq_tuple[3][0] lengthChisq = int(chisq_stop) - int(chisq_start) #prepare the thresholds to be plotted snrThreshVect = lengthSnr * [snrThreshold] if(chisqThreshold < 100.): chisqThreshVect = lengthChisq * [chisqThreshold] if((rsqThreshold > 0) and (rsqThreshold < 100.)): rsqThreshVect = lengthChisq * [rsqThreshold] # Now plot the snr time serie !! figure(1) plot(snr_time[int(snr_start):int(snr_stop)],snr_vector[int(snr_start):int(snr_stop)]) hold(1) plot(snr_time[int(snr_start):int(snr_stop)],snrThreshVect) hold(0) xlim(-duration/2., duration/2.) xlabel('time (s)',size='x-large') ylabel(r'snr',size='x-large') grid() title(ifoName[0] + ' trigger: ' + gpsTime) figName = ifoName[0] + '_' + str(gpsTime).replace(".","_") + '_snr.png' savefig(outputPath +"/" + figName) tableFile = open(tableFileName,'a') table = HTMLTable() rowStr = '<img width=400 src="' + page + "/" + outputPath + "/" + figName +'">' table.add_column([rowStr],'SNR') figure(11) plot(snr_time[int(snr_start):int(snr_stop)],snr_vector[int(snr_start):int(snr_stop)]) hold(1) plot(snr_time[int(snr_start):int(snr_stop)],snrThreshVect) hold(0) xlim(-duration/20., duration/20.) xlabel('time (s)',size='x-large') ylabel(r'snr',size='x-large') grid() title(ifoName[0] + ' trigger: ' + gpsTime + ' Zoom') figName = ifoName[0] + '_' + str(gpsTime).replace(".","_") + '_snr_zoom.png' savefig(outputPath +"/" + figName) savefig(imgFile) rowStr = '<img width=400 src="' + page + "/" + outputPath + "/" + figName +'">' table.add_column([rowStr],'SNR') table.write(tableFile) tableFile.close() ### END CHADS CHANGES ### # Now plot the r^2 time serie !! figure(2) plot(chisq_time[int(chisq_start):int(chisq_stop)],rsq_vector[int(chisq_start):int(chisq_stop)]) if(chisqThreshold < 100.): hold(1) plot(chisq_time[int(chisq_start):int(chisq_stop)],rsqThreshVect) hold(0) xlim(-duration/2., duration/2.) xlabel('time (s)',size='x-large') ylabel(r'chisq/p',size='x-large') grid() title(ifoName[0] + ' trigger: ' + gpsTime) figName = ifoName[0] + '_' + str(gpsTime).replace(".","_") + '_rsq.png' savefig(figName) tableFile = open(tableFileName,'a') table = HTMLTable() rowStr = '<img width=400 src="' + page + "/" + outputPath + "/" + figName +'">' table.add_column([rowStr],'CHISQ/P') figure(22) plot(chisq_time[int(chisq_start):int(chisq_stop)],rsq_vector[int(chisq_start):int(chisq_stop)]) if(chisqThreshold < 100.): hold(1) plot(chisq_time[int(chisq_start):int(chisq_stop)],rsqThreshVect) hold(0) xlim(-duration/20., duration/20.) xlabel('time (s)',size='x-large') ylabel(r'chisq/p',size='x-large') grid() title(ifoName[0] + ' trigger: ' + gpsTime + ' Zoom') figName = ifoName[0] + '_' + str(gpsTime).replace(".","_") + '_rsq_zoom.png' savefig(figName) rowStr = '<img width=400 src="' + page + "/" + outputPath + "/" + figName +'">' table.add_column([rowStr],'CHISQ/P Zoom') table.write(tableFile) tableFile.close() # Now plot the normalized chisq time serie !! figure(3) plot(chisq_time[int(chisq_start):int(chisq_stop)],chisqNorm_vector[int(chisq_start):int(chisq_stop)]) if(rsqThreshold > 0 and rsqThreshold < 100.): hold(1) plot(chisq_time[int(chisq_start):int(chisq_stop)],chisqThreshVect) hold(0) xlim(-duration/2., duration/2.) xlabel('time (s)',size='x-large') ylabel(r'chisq / (p + Delta * snrsq)',size='x-large') grid(1) title(ifoName[0] + ' trigger: ' + gpsTime) figName = ifoName[0] + '_' + str(gpsTime).replace(".","_") + '_chisq.png' savefig(figName) tableFile = open(tableFileName,'a') table = HTMLTable() rowStr = '<img width=400 src="' + page + "/" + outputPath + "/" + figName +'">' table.add_column([rowStr],'CHISQ/(P+delta*SNR^2)') figure(33) plot(chisq_time[int(chisq_start):int(chisq_stop)],chisqNorm_vector[int(chisq_start):int(chisq_stop)]) if(rsqThreshold > 0 and rsqThreshold < 100.): hold(1) plot(chisq_time[int(chisq_start):int(chisq_stop)],chisqThreshVect) hold(0) xlim(-duration/20., duration/20.) xlabel('time (s)',size='x-large') ylabel(r'chisq / (p + Delta * snrsq)',size='x-large') grid(1) title(ifoName[0] + ' trigger: ' + gpsTime + ' Zoom') savefig(ifoName[0] + '_' + str(gpsTime).replace(".","_") + '_chisq_zoom.png') rowStr = '<img width=400 src="' + page + "/" + outputPath + "/" + figName +'">' table.add_column([rowStr],'CHISQ/(P+delta*SNR^2) Zoom') # write all the plots to the web page table.write(tableFile) tableFile.close()
39bcfbf97ed7af5cc4c26a9666f90e8181718403 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/5758/39bcfbf97ed7af5cc4c26a9666f90e8181718403/plotsnrchisq_pipe.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3207, 8134, 86, 343, 291, 85, 12, 75, 1121, 950, 16, 3789, 812, 16, 2844, 743, 16, 267, 1752, 15417, 1370, 16, 2121, 4771, 16, 6081, 812, 16, 2433, 4672, 225, 3597, 85, 7614, 273, 374, 31, 225, 364, 1027, 316, 316, 1752, 15417, 1370, 30, 309, 1027, 18, 891, 422, 5238, 4327, 17, 529, 6877, 3861, 780, 2171, 273, 1027, 18, 1132, 21479, 461, 273, 609, 12, 492, 18, 1132, 2934, 4939, 2932, 2773, 16, 21, 13, 309, 1027, 18, 891, 422, 5238, 9273, 17, 2469, 6877, 2291, 2891, 273, 5302, 12, 492, 18, 1132, 13, 309, 1027, 18, 891, 422, 5238, 6358, 17, 5141, 6877, 27505, 273, 5302, 12, 492, 18, 1132, 13, 309, 1027, 18, 891, 422, 5238, 9273, 17, 17946, 6877, 2291, 17411, 273, 5302, 12, 492, 18, 1132, 13, 309, 261, 492, 18, 891, 422, 5238, 343, 291, 85, 17, 9878, 7923, 578, 261, 492, 18, 891, 422, 5238, 1154, 2840, 17, 1916, 6, 4672, 462, 291, 85, 9242, 273, 5302, 12, 492, 18, 1132, 13, 309, 1027, 18, 891, 422, 6, 413, 343, 291, 85, 17, 11862, 6877, 462, 291, 85, 38, 2679, 273, 5302, 12, 492, 18, 1132, 13, 309, 1027, 18, 891, 422, 5238, 8134, 86, 17, 8699, 6877, 29248, 7614, 273, 5302, 12, 492, 18, 1132, 13, 309, 1027, 18, 891, 422, 5238, 343, 291, 85, 17, 8699, 6877, 462, 291, 85, 7614, 273, 5302, 12, 492, 18, 1132, 13, 309, 1027, 18, 891, 422, 5238, 5453, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3207, 8134, 86, 343, 291, 85, 12, 75, 1121, 950, 16, 3789, 812, 16, 2844, 743, 16, 267, 1752, 15417, 1370, 16, 2121, 4771, 16, 6081, 812, 16, 2433, 4672, 225, 3597, 85, 7614, 273, 374, 31, 225, 364, 1027, 316, 316, 1752, 15417, 1370, 30, 309, 1027, 18, 891, 422, 5238, 4327, 17, 529, 6877, 3861, 780, 2171, 273, 1027, 18, 1132, 21479, 461, 273, 609, 12, 492, 18, 1132, 2934, 4939, 2932, 2773, 16, 21, 13, 309, 1027, 18, 891, 422, 5238, 9273, 17, 2469, 6877, 2291, 2891, 273, 5302, 12, 492, 18, 1132, 13, 309, 1027, 18, 891, 422, 5238, 6358, 17, 5141, 6877, 27505, 273, 5302, 12, 492, 18, 1132, 13, 309, 1027, 18, 2 ]
EventsPerJob = self.eventsPerJob)
EventsPerJob = self.eventsPerJob, Sites = self.sites)
def handleInput(self, payload): logging.info("RequestFeeder: Handling %s" % payload)
a9bc2e8296b8d648a4627bd6e23ba4f1469517f3 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/8887/a9bc2e8296b8d648a4627bd6e23ba4f1469517f3/RequestFeeder.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1640, 1210, 12, 2890, 16, 2385, 4672, 2907, 18, 1376, 2932, 691, 8141, 264, 30, 2841, 2456, 738, 87, 6, 738, 2385, 13, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1640, 1210, 12, 2890, 16, 2385, 4672, 2907, 18, 1376, 2932, 691, 8141, 264, 30, 2841, 2456, 738, 87, 6, 738, 2385, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
if not option == None:
if not option == None:
def convert_bibitem(document): """ Convert
9285259c560f5233584134ed83d267f93a4cb6de /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/7514/9285259c560f5233584134ed83d267f93a4cb6de/lyx_1_5.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1765, 67, 70, 495, 1726, 12, 5457, 4672, 3536, 4037, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1765, 67, 70, 495, 1726, 12, 5457, 4672, 3536, 4037, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
/* Automatically generated. Do not edit! */
/* Automatically generated by ext/gen_interpreters.py. Do not edit! */
def get_interpreter(self): r""" Returns the code for the C interpreter.
89c8332de5c914b500ffb00940fc8eebaae69cfa /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9417/89c8332de5c914b500ffb00940fc8eebaae69cfa/gen_interpreters.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 2761, 11599, 12, 2890, 4672, 436, 8395, 2860, 326, 981, 364, 326, 385, 16048, 18, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 2761, 11599, 12, 2890, 4672, 436, 8395, 2860, 326, 981, 364, 326, 385, 16048, 18, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
Should only be called by __init__''' if self.__creating: fpar=file(self.datadir+'dim.dat')
Should only be called by set_param''' if self.__updating: print "Reading dim.dat...", fpar=file(self.datadir+'dim.dat')
def __read_dim(self): ''' Read dim.dat file and write corresponding data Should only be called by __init__''' if self.__creating: fpar=file(self.datadir+'dim.dat') line=fpar.readline().split() if len(line) == 6: mx,my,mz,mvar,maux,mglobal = tuple(map(int,line)) else: mx,my,mz,mvar,maux = tuple(map(int,line)) mglobal = 0 precision=fpar.readline().strip() if precision == 'D': precision = 'd' else: precision = 'f' self.precision=precision nghostx,nghosty,nghostz = tuple(map(int,fpar.readline().split())) nprocx,nprocy,nprocz,iprocz_slowest = tuple(map(int,fpar.readline().split())) nproc=nprocx*nprocy*nprocz ipx=ipy=ipz=-1 fpar.close() nx = mx - (2 * nghostx) ny = my - (2 * nghosty) nz = mz - (2 * nghostz) mw = mx * my * mz l1 = nghostx l2 = mx-nghostx-1 m1 = nghosty m2 = my-nghosty-1 n1 = nghostz n2 = mz-nghostz-1 nxgrid = nx nygrid = ny nzgrid = nz mxgrid = nxgrid + (2 * nghostx) mygrid = nygrid + (2 * nghosty) mzgrid = nzgrid + (2 * nghostz) self.param['dim'].create_dataset('mx',(nproc+1,),'i') self.param['dim'].create_dataset('my',(nproc+1,),'i') self.param['dim'].create_dataset('mz',(nproc+1,),'i') self.param['dim'].create_dataset('mvar',(nproc+1,),'i') self.param['dim'].create_dataset('maux',(nproc+1,),'i') self.param['dim'].create_dataset('mglobal',(nproc+1,),'i') self.param['dim'].create_dataset('precision',(nproc+1,),'c') self.param['dim'].create_dataset('nghostx',(nproc+1,),'i') self.param['dim'].create_dataset('nghosty',(nproc+1,),'i') self.param['dim'].create_dataset('nghostz',(nproc+1,),'i') self.param['dim'].create_dataset('nprocx',(1,),data=nprocx) self.param['dim'].create_dataset('nprocy',(1,),data=nprocy) self.param['dim'].create_dataset('nprocz',(1,),data=nprocz) self.param['dim'].create_dataset('iprocz_slowest',(1,),data=iprocz_slowest) self.param['dim'].create_dataset('ipx',(nproc+1,),'i') self.param['dim'].create_dataset('ipy',(nproc+1,),'i') self.param['dim'].create_dataset('ipz',(nproc+1,),'i') self.param['dim'].create_dataset('nproc',(1,),data=nproc) self.param['dim'].create_dataset('nx',(nproc+1,),'i') self.param['dim'].create_dataset('ny',(nproc+1,),'i') self.param['dim'].create_dataset('nz',(nproc+1,),'i') self.param['dim'].create_dataset('mw',(nproc+1,),'i') self.param['dim'].create_dataset('l1',(nproc+1,),'i') self.param['dim'].create_dataset('l2',(nproc+1,),'i') self.param['dim'].create_dataset('m1',(nproc+1,),'i') self.param['dim'].create_dataset('m2',(nproc+1,),'i') self.param['dim'].create_dataset('n1',(nproc+1,),'i') self.param['dim'].create_dataset('n2',(nproc+1,),'i') self.param['dim'].create_dataset('nxgrid',(1,),data=nxgrid) self.param['dim'].create_dataset('nygrid',(1,),data=nygrid) self.param['dim'].create_dataset('nzgrid',(1,),data=nzgrid) self.param['dim'].create_dataset('mxgrid',(1,),data=mxgrid) self.param['dim'].create_dataset('mygrid',(1,),data=mygrid) self.param['dim'].create_dataset('mzgrid',(1,),data=mzgrid) for i in range(-1,nproc): if i != -1: fpar=file(self.datadir+'proc'+str(i)+'/dim.dat') line=fpar.readline().split() if len(line) == 6: mx,my,mz,mvar,maux,mglobal = tuple(map(int,line)) else: mx,my,mz,mvar,maux = tuple(map(int,line)) mglobal = 0 precision=fpar.readline().strip() if precision == 'D': precision = 'd' else: precision = 'f' nghostx,nghosty,nghostz = tuple(map(int,fpar.readline().split())) ipx,ipy,ipz=tuple(map(int,fpar.readline().split())) fpar.close() nx = mx - (2 * nghostx) ny = my - (2 * nghosty) nz = mz - (2 * nghostz) mw = mx * my * mz l1 = nghostx l2 = mx-nghostx-1 m1 = nghosty m2 = my-nghosty-1 n1 = nghostz n2 = mz-nghostz-1 self.param['dim/mx'][i+1]=mx self.param['dim/my'][i+1]=my self.param['dim/mz'][i+1]=mz self.param['dim/mvar'][i+1]=mvar self.param['dim/maux'][i+1]=maux self.param['dim/mglobal'][i+1]=mglobal self.param['dim/precision'][i+1]=precision self.param['dim/nghostx'][i+1]=nghostx self.param['dim/nghosty'][i+1]=nghosty self.param['dim/nghostz'][i+1]=nghostz self.param['dim/ipx'][i+1]=ipx self.param['dim/ipy'][i+1]=ipy self.param['dim/ipz'][i+1]=ipz self.param['dim/nx'][i+1]=nx self.param['dim/ny'][i+1]=ny self.param['dim/nz'][i+1]=nz self.param['dim/mw'][i+1]=mw self.param['dim/l1'][i+1]=l1 self.param['dim/l2'][i+1]=l2 self.param['dim/m1'][i+1]=m1 self.param['dim/m2'][i+1]=m2 self.param['dim/n1'][i+1]=n1 self.param['dim/n2'][i+1]=n2
bf1a599ad9cde581f4679533ab3c54c55f5e9732 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/1377/bf1a599ad9cde581f4679533ab3c54c55f5e9732/hdf5.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 896, 67, 3509, 12, 2890, 4672, 9163, 2720, 2464, 18, 3404, 585, 471, 1045, 4656, 501, 9363, 1338, 506, 2566, 635, 444, 67, 891, 26418, 309, 365, 16186, 5533, 1776, 30, 1172, 315, 15714, 2464, 18, 3404, 7070, 16, 284, 1065, 33, 768, 12, 2890, 18, 3404, 361, 481, 6797, 3509, 18, 3404, 6134, 980, 33, 74, 1065, 18, 896, 1369, 7675, 4939, 1435, 309, 562, 12, 1369, 13, 422, 1666, 30, 7938, 16, 4811, 16, 81, 94, 16, 81, 1401, 16, 2540, 2616, 16, 81, 6347, 273, 3193, 12, 1458, 12, 474, 16, 1369, 3719, 469, 30, 7938, 16, 4811, 16, 81, 94, 16, 81, 1401, 16, 2540, 2616, 273, 3193, 12, 1458, 12, 474, 16, 1369, 3719, 312, 6347, 273, 374, 6039, 33, 74, 1065, 18, 896, 1369, 7675, 6406, 1435, 309, 6039, 422, 296, 40, 4278, 6039, 273, 296, 72, 11, 469, 30, 6039, 273, 296, 74, 11, 365, 18, 14548, 33, 14548, 10944, 2564, 92, 16, 3368, 2564, 93, 16, 3368, 2564, 94, 273, 3193, 12, 1458, 12, 474, 16, 74, 1065, 18, 896, 1369, 7675, 4939, 1435, 3719, 290, 9381, 92, 16, 82, 685, 2431, 16, 82, 9381, 94, 16, 625, 303, 71, 94, 67, 87, 821, 395, 273, 3193, 12, 1458, 12, 474, 16, 74, 1065, 18, 896, 1369, 7675, 4939, 1435, 3719, 290, 9381, 33, 82, 9381, 92, 14, 82, 685, 2431, 14, 82, 9381, 94, 2359, 92, 33, 9126, 33, 625, 94, 29711, 21, 284, 1065, 18, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 896, 67, 3509, 12, 2890, 4672, 9163, 2720, 2464, 18, 3404, 585, 471, 1045, 4656, 501, 9363, 1338, 506, 2566, 635, 444, 67, 891, 26418, 309, 365, 16186, 5533, 1776, 30, 1172, 315, 15714, 2464, 18, 3404, 7070, 16, 284, 1065, 33, 768, 12, 2890, 18, 3404, 361, 481, 6797, 3509, 18, 3404, 6134, 980, 33, 74, 1065, 18, 896, 1369, 7675, 4939, 1435, 309, 562, 12, 1369, 13, 422, 1666, 30, 7938, 16, 4811, 16, 81, 94, 16, 81, 1401, 16, 2540, 2616, 16, 81, 6347, 273, 3193, 12, 1458, 12, 474, 16, 1369, 3719, 469, 30, 7938, 16, 4811, 16, 81, 94, 16, 81, 1401, 16, 2540, 2616, 273, 3193, 12, 1458, 12, 474, 16, 2 ]
realname = self.real_name subject = _('%(realname)s subscription notification')
lang = self.preferred_language otrans = i18n.get_translation() i18n.set_language(lang) try: realname = self.real_name subject = _('%(realname)s subscription notification') finally: i18n.set_translation(otrans) if isinstance(name, UnicodeType): name = name.encode(Utils.GetCharSet(lang), 'replace')
def ApprovedAddMember(self, userdesc, ack=None, admin_notif=None, text=''): """Add a member right now.
9b9452df1e362c046abba939ef1a76aeac33e0bf /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2120/9b9452df1e362c046abba939ef1a76aeac33e0bf/MailList.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1716, 685, 2155, 986, 4419, 12, 2890, 16, 729, 5569, 16, 8479, 33, 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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1716, 685, 2155, 986, 4419, 12, 2890, 16, 729, 5569, 16, 8479, 33, 7036, 16, 3981, 67, 902, 430, 33, 7036, 16, 977, 2218, 11, 4672, 3536, 986, 279, 3140, 2145, 2037, 18, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
stdout_thread.setDaemon(True)
stdout_thread.set_daemon(True)
def _communicate(self, input): stdout = None # Return stderr = None # Return
2d9a086410546ef86358220eab652e03cd5ae5ab /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/8546/2d9a086410546ef86358220eab652e03cd5ae5ab/subprocess.py
[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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 5702, 318, 2659, 12, 2890, 16, 810, 4672, 3909, 273, 599, 468, 2000, 4514, 273, 599, 468, 2000, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
del self.canvas
def render(self, out): self.canvas = canvas.Canvas(out) el = self.dom.documentElement.getElementsByTagName('docinit') if el: self.docinit(el)
4160b63de7ca732ce2ad7f4dc47049ae073a97d0 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/12853/4160b63de7ca732ce2ad7f4dc47049ae073a97d0/trml2pdf.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1743, 12, 2890, 16, 596, 4672, 365, 18, 15424, 273, 5953, 18, 12971, 12, 659, 13, 415, 273, 365, 18, 9859, 18, 5457, 1046, 18, 588, 3471, 10401, 2668, 2434, 2738, 6134, 309, 415, 30, 365, 18, 2434, 2738, 12, 292, 13, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1743, 12, 2890, 16, 596, 4672, 365, 18, 15424, 273, 5953, 18, 12971, 12, 659, 13, 415, 273, 365, 18, 9859, 18, 5457, 1046, 18, 588, 3471, 10401, 2668, 2434, 2738, 6134, 309, 415, 30, 365, 18, 2434, 2738, 12, 292, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
value = hlr_utils.get_value(obj,i,o_descr,axis,axis_pos) error = hlr_utils.get_err2(obj,i,o_descr,axis,axis_pos)
value = hlr_utils.get_value(obj, i, o_descr, axis, axis_pos) error = hlr_utils.get_err2(obj, i, o_descr, axis, axis_pos)
def integrate_axis(obj, **kwargs): """ This function takes a SOM or a SO and integrates the given axis. The function assumes that the incoming data is in the histogram form. Parameters: ---------- -> obj is a SOM or a SO -> kwargs is a list of key word arguments that the function accepts: start=<index of starting bin> end=<index of ending bin> This index is made inclusive by the function. axis=<y or x> This is the axis one wishes to manipulate. If no argument is given the default value is y axis_pos=<number> This is position of the axis in the axis array. If no argument is given, the default value is 0 Returns: ------- <- A tuple containing the integration value and its associated error Exceptions: ---------- <- RuntimError is raised if a SOM or SO is not given to the function """ # import the helper functions import hlr_utils # set up for working through data o_descr=hlr_utils.get_descr(obj) if o_descr == "number" or o_descr == "list": raise RuntimeError, "Must provide a SOM of a SO to the function." # Go on else: pass # Check for starting bin try: start = kwargs["start"] except KeyError: start = 0 # Check for ending bin try: end = kwargs["end"]+1 except KeyError: end = -1 # Check for axis keyword argument try: axis = kwargs["axis"] except KeyError: axis = "y" # Check for axis_pos keyword argument try: axis_pos = kwargs["axis_pos"] except KeyError: axis_pos = 0 integration = 0 integration_error2 = 0 for i in range(hlr_utils.get_length(obj)): value = hlr_utils.get_value(obj,i,o_descr,axis,axis_pos) error = hlr_utils.get_err2(obj,i,o_descr,axis,axis_pos) if end == -1: value = value[start:] error = error[start:] else: value = value[start:end] error = error[start:end] for (val,err) in map(None, value, error): integration += val integration_error2 += err return (integration,integration_error2)
6fe6bd8f1c3a8e6b1bc8ec8a02a774c1f6891ea9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/763/6fe6bd8f1c3a8e6b1bc8ec8a02a774c1f6891ea9/hlr_integrate_axis.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 23367, 67, 4890, 12, 2603, 16, 2826, 4333, 4672, 3536, 1220, 445, 5530, 279, 348, 1872, 578, 279, 7460, 471, 11301, 815, 326, 864, 2654, 18, 1021, 445, 13041, 716, 326, 6935, 501, 353, 316, 326, 8892, 646, 18, 225, 7012, 30, 12181, 317, 1081, 353, 279, 348, 1872, 578, 279, 7460, 317, 1205, 353, 279, 666, 434, 498, 2076, 1775, 716, 326, 445, 8104, 30, 787, 27127, 1615, 434, 5023, 4158, 34, 679, 27127, 1615, 434, 11463, 4158, 34, 1220, 770, 353, 7165, 13562, 635, 326, 445, 18, 2654, 27127, 93, 578, 619, 34, 1220, 353, 326, 2654, 1245, 14302, 281, 358, 28286, 18, 971, 1158, 1237, 353, 864, 326, 805, 460, 353, 677, 2654, 67, 917, 27127, 2696, 34, 1220, 353, 1754, 434, 326, 2654, 316, 326, 2654, 526, 18, 971, 1158, 1237, 353, 864, 16, 326, 805, 460, 353, 374, 225, 2860, 30, 18365, 3290, 432, 3193, 4191, 326, 12040, 460, 471, 2097, 3627, 555, 225, 12781, 30, 12181, 3290, 1939, 8584, 668, 353, 11531, 309, 279, 348, 1872, 578, 7460, 353, 486, 864, 358, 326, 445, 3536, 225, 468, 1930, 326, 4222, 4186, 1930, 366, 10826, 67, 5471, 225, 468, 444, 731, 364, 5960, 3059, 501, 320, 67, 28313, 33, 76, 10826, 67, 5471, 18, 588, 67, 28313, 12, 2603, 13, 225, 309, 320, 67, 28313, 422, 315, 2696, 6, 578, 320, 67, 28313, 422, 315, 1098, 6877, 1002, 7265, 16, 315, 10136, 5615, 279, 348, 1872, 434, 279, 7460, 358, 326, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 23367, 67, 4890, 12, 2603, 16, 2826, 4333, 4672, 3536, 1220, 445, 5530, 279, 348, 1872, 578, 279, 7460, 471, 11301, 815, 326, 864, 2654, 18, 1021, 445, 13041, 716, 326, 6935, 501, 353, 316, 326, 8892, 646, 18, 225, 7012, 30, 12181, 317, 1081, 353, 279, 348, 1872, 578, 279, 7460, 317, 1205, 353, 279, 666, 434, 498, 2076, 1775, 716, 326, 445, 8104, 30, 787, 27127, 1615, 434, 5023, 4158, 34, 679, 27127, 1615, 434, 11463, 4158, 34, 1220, 770, 353, 7165, 13562, 635, 326, 445, 18, 2654, 27127, 93, 578, 619, 34, 1220, 353, 326, 2654, 1245, 14302, 281, 358, 28286, 18, 971, 1158, 1237, 353, 864, 326, 805, 460, 353, 677, 2654, 67, 917, 2 ]
len(dist) and reduce(lambda x, y: x+':'+y, [self.precFrmt % (x/a) for x in dist]) or "NA", len(dist) and reduce(lambda x, y: x+':'+y, ["%d" % int(x) for x in dist]) or "NA"
len(dist) and reduce(lambda x, y: x+':'+y, [self.precFrmt % (x/a) for x in dist]) or "N/A", len(dist) and reduce(lambda x, y: x+':'+y, ["%d" % int(x) for x in dist]) or "N/A"
def walkupdate(listviewitem): node = self.nodeClassDict[listviewitem] if not node: return ncl = node.nodeClassifier dist = node.distribution a = dist.abs if a < 1e-20: a = 1 try: p_majclass = f % float(dist[int(ncl.defaultVal)]/a) except: p_majclass = "NA" try: p_tarclass = f % float(dist[self.targetClass]/a) except: p_tarclass = "NA"
a03f0b6c1a8d75124def713bfd07fcb763e1111e /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/6366/a03f0b6c1a8d75124def713bfd07fcb763e1111e/OWClassificationTreeViewer.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 5442, 2725, 12, 1098, 1945, 1726, 4672, 756, 273, 365, 18, 2159, 797, 5014, 63, 1098, 1945, 1726, 65, 309, 486, 756, 30, 327, 290, 830, 273, 756, 18, 2159, 13860, 2411, 273, 756, 18, 16279, 279, 273, 2411, 18, 5113, 309, 279, 411, 404, 73, 17, 3462, 30, 279, 273, 404, 775, 30, 293, 67, 12585, 1106, 273, 284, 738, 1431, 12, 4413, 63, 474, 12, 82, 830, 18, 1886, 3053, 13, 18537, 69, 13, 1335, 30, 293, 67, 12585, 1106, 273, 315, 11277, 6, 775, 30, 293, 67, 11718, 1106, 273, 284, 738, 1431, 12, 4413, 63, 2890, 18, 3299, 797, 18537, 69, 13, 1335, 30, 293, 67, 11718, 1106, 273, 315, 11277, 6, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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 12, 1098, 1945, 1726, 4672, 756, 273, 365, 18, 2159, 797, 5014, 63, 1098, 1945, 1726, 65, 309, 486, 756, 30, 327, 290, 830, 273, 756, 18, 2159, 13860, 2411, 273, 756, 18, 16279, 279, 273, 2411, 18, 5113, 309, 279, 411, 404, 73, 17, 3462, 30, 279, 273, 404, 775, 30, 293, 67, 12585, 1106, 273, 284, 738, 1431, 12, 4413, 63, 474, 12, 82, 830, 18, 1886, 3053, 13, 18537, 69, 13, 1335, 30, 293, 67, 12585, 1106, 273, 315, 11277, 6, 775, 30, 293, 67, 11718, 1106, 273, 284, 738, 1431, 12, 4413, 63, 2890, 18, 3299, 797, 18537, 69, 13, 1335, 30, 293, 67, 11718, 1106, 273, 315, 11277, 6, 2, -100, -100 ]
f.write(" JSBool ok = xpc_qsXPCOMObjectToJsval(lccx, result, " "xpc_qsGetWrapperCache(result), &NS_GET_IID(%s), " "&interfaces[k_%s], &vp.array[0]);" "\n" % (type.name, type.name))
f.write(" JSBool ok = xpc_qsXPCOMObjectToJsval(lccx, " "ToSupports(result), xpc_qsGetWrapperCache(result), " "&NS_GET_IID(%s), &interfaces[k_%s], &vp.array[0]);\n" % (type.name, type.name))
def writeTraceableResultConv(f, type): typeName = getBuiltinOrNativeTypeName(type) if typeName is not None: template = traceableResultConvTemplates.get(typeName) if template is not None: values = { 'errorStr': getFailureString( getTraceInfoDefaultReturn(type), 2) } f.write(substitute(template, values)) return # else fall through; this type isn't supported yet elif isInterfaceType(type): if isVariantType(type): f.write(" JSBool ok = xpc_qsVariantToJsval(lccx, result, " "&vp.array[0]);\n") else: f.write(" JSBool ok = xpc_qsXPCOMObjectToJsval(lccx, result, " "xpc_qsGetWrapperCache(result), &NS_GET_IID(%s), " "&interfaces[k_%s], &vp.array[0]);" "\n" % (type.name, type.name)) f.write(" if (!ok) {\n"); writeFailure(f, getTraceInfoDefaultReturn(type), 2) f.write(" return vp.array[0];\n") return warn("Unable to convert result of type %s" % typeName) f.write(" !; // TODO - Convert `result` to jsval, store in rval.\n") f.write(" return xpc_qsThrow(cx, NS_ERROR_UNEXPECTED); // FIXME\n")
43dac8594b9299b7acacc614359a2709d44ce5a7 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/11102/43dac8594b9299b7acacc614359a2709d44ce5a7/qsgen.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1045, 3448, 429, 1253, 17467, 12, 74, 16, 618, 4672, 8173, 273, 2882, 4853, 267, 1162, 9220, 7947, 12, 723, 13, 309, 8173, 353, 486, 599, 30, 1542, 273, 2606, 429, 1253, 17467, 8218, 18, 588, 12, 723, 461, 13, 309, 1542, 353, 486, 599, 30, 924, 273, 288, 296, 1636, 1585, 4278, 31673, 594, 780, 12, 18698, 966, 1868, 990, 12, 723, 3631, 576, 13, 289, 284, 18, 2626, 12, 1717, 17207, 12, 3202, 16, 924, 3719, 327, 468, 469, 4159, 3059, 31, 333, 618, 5177, 1404, 3260, 4671, 1327, 21456, 559, 12, 723, 4672, 309, 353, 9356, 559, 12, 723, 4672, 284, 18, 2626, 2932, 565, 6756, 7464, 1529, 273, 619, 2436, 67, 12926, 9356, 774, 8382, 1125, 12, 80, 952, 92, 16, 563, 16, 315, 7830, 20106, 18, 1126, 63, 20, 19226, 64, 82, 7923, 469, 30, 284, 18, 2626, 2932, 565, 6756, 7464, 1529, 273, 619, 2436, 67, 12926, 60, 3513, 1872, 921, 774, 8382, 1125, 12, 80, 952, 92, 16, 315, 315, 774, 27878, 12, 2088, 3631, 619, 2436, 67, 12926, 967, 3611, 1649, 12, 2088, 3631, 315, 7830, 3156, 67, 3264, 67, 45, 734, 9275, 87, 3631, 473, 15898, 63, 79, 10185, 87, 6487, 473, 20106, 18, 1126, 63, 20, 19226, 64, 82, 6, 738, 261, 723, 18, 529, 16, 618, 18, 529, 3719, 284, 18, 2626, 2932, 565, 309, 16051, 601, 13, 18890, 82, 8863, 1045, 5247, 12, 74, 16, 18698, 966, 1868, 990, 12, 723, 3631, 576, 13, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1045, 3448, 429, 1253, 17467, 12, 74, 16, 618, 4672, 8173, 273, 2882, 4853, 267, 1162, 9220, 7947, 12, 723, 13, 309, 8173, 353, 486, 599, 30, 1542, 273, 2606, 429, 1253, 17467, 8218, 18, 588, 12, 723, 461, 13, 309, 1542, 353, 486, 599, 30, 924, 273, 288, 296, 1636, 1585, 4278, 31673, 594, 780, 12, 18698, 966, 1868, 990, 12, 723, 3631, 576, 13, 289, 284, 18, 2626, 12, 1717, 17207, 12, 3202, 16, 924, 3719, 327, 468, 469, 4159, 3059, 31, 333, 618, 5177, 1404, 3260, 4671, 1327, 21456, 559, 12, 723, 4672, 309, 353, 9356, 559, 12, 723, 4672, 284, 18, 2626, 2932, 565, 6756, 7464, 1529, 273, 619, 2436, 67, 12926, 9356, 774, 2 ]
local_ip = host.outgoing_ip_for(self._invitation.sdp.proposed_remote.connection.address)
sdp_connection = self._invitation.sdp.proposed_remote.connection or (media.connection for media in self._invitation.sdp.proposed_remote.media if media.connection is not None).next() local_ip = host.outgoing_ip_for(sdp_connection.address)
def accept(self, streams): self.greenlet = api.getcurrent() notification_center = NotificationCenter() settings = SIPSimpleSettings()
c7153664b7a4229923981a500a921de0796d12c9 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/3449/c7153664b7a4229923981a500a921de0796d12c9/session.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2791, 12, 2890, 16, 8205, 4672, 365, 18, 11571, 1810, 273, 1536, 18, 588, 2972, 1435, 3851, 67, 5693, 273, 8050, 8449, 1435, 1947, 273, 348, 2579, 5784, 2628, 1435, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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 326, 981, 30, 1652, 2791, 12, 2890, 16, 8205, 4672, 365, 18, 11571, 1810, 273, 1536, 18, 588, 2972, 1435, 3851, 67, 5693, 273, 8050, 8449, 1435, 1947, 273, 348, 2579, 5784, 2628, 1435, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
pep = pepAln.values()[0]
def findFourFold(aln): """Returns index of all columns in alignment that are completely fourfold degenerate Assumes that columns are already filtered for aligned codons """ # create peptide alignment pepAln = mapalign(aln, valfunc=translate) # find peptide conservation pepcons = [] for i in xrange(pepAln.alignlen()): # get a column from the peptide alignment col = [seq[i] for seq in pepAln.itervalues()] # compute the histogram of the column. # ignore gaps '-' and non-translated 'X' hist = util.histDict(col) if "-" in hist: del hist["-"] if "X" in hist: del hist["X"] # column is conserved if only one AA appears pepcons.append(len(hist) == 1 and "X" not in hist) ind = [] # get peptides of 1st sequence pep = pepAln.values()[0] for i in range(0, len(aln.values()[0]), 3): # process only those columns that are conserved at the peptide level if pepcons[i//3]: degen = AA_DEGEN[pep[i//3]] for j in range(3): if degen[j] == 4: ind.append(i+j) return ind
4e78a3e6dda4524245bc076287f770f0548defe5 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/8482/4e78a3e6dda4524245bc076287f770f0548defe5/alignlib.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1104, 42, 477, 15592, 12, 30907, 4672, 3536, 1356, 770, 434, 777, 2168, 316, 8710, 716, 854, 14416, 12792, 16007, 443, 7163, 225, 25374, 716, 2168, 854, 1818, 5105, 364, 13939, 11012, 7008, 3536, 225, 468, 752, 30159, 8710, 293, 881, 1067, 82, 273, 852, 7989, 12, 30907, 16, 1244, 644, 33, 13929, 13, 225, 468, 1104, 30159, 356, 550, 7112, 293, 881, 8559, 273, 5378, 364, 277, 316, 12314, 12, 29363, 1067, 82, 18, 7989, 1897, 1435, 4672, 468, 336, 279, 1057, 628, 326, 30159, 8710, 645, 273, 306, 5436, 63, 77, 65, 364, 3833, 316, 293, 881, 1067, 82, 18, 2165, 2372, 1435, 65, 225, 468, 3671, 326, 8892, 434, 326, 1057, 18, 468, 2305, 21085, 4014, 471, 1661, 17, 22899, 296, 60, 11, 5356, 273, 1709, 18, 11488, 5014, 12, 1293, 13, 309, 7514, 316, 5356, 30, 1464, 5356, 9614, 10951, 65, 309, 315, 60, 6, 316, 5356, 30, 1464, 5356, 9614, 60, 11929, 225, 468, 1057, 353, 356, 550, 2155, 309, 1338, 1245, 27343, 14606, 293, 881, 8559, 18, 6923, 12, 1897, 12, 11488, 13, 422, 404, 471, 315, 60, 6, 486, 316, 5356, 13, 282, 1547, 273, 5378, 225, 468, 336, 2804, 29608, 434, 404, 334, 3102, 293, 881, 273, 293, 881, 1067, 82, 18, 2372, 1435, 63, 20, 65, 225, 364, 277, 316, 1048, 12, 20, 16, 562, 12, 30907, 18, 2372, 1435, 63, 20, 65, 3631, 890, 4672, 468, 1207, 1338, 5348, 2168, 716, 854, 356, 550, 2155, 622, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1104, 42, 477, 15592, 12, 30907, 4672, 3536, 1356, 770, 434, 777, 2168, 316, 8710, 716, 854, 14416, 12792, 16007, 443, 7163, 225, 25374, 716, 2168, 854, 1818, 5105, 364, 13939, 11012, 7008, 3536, 225, 468, 752, 30159, 8710, 293, 881, 1067, 82, 273, 852, 7989, 12, 30907, 16, 1244, 644, 33, 13929, 13, 225, 468, 1104, 30159, 356, 550, 7112, 293, 881, 8559, 273, 5378, 364, 277, 316, 12314, 12, 29363, 1067, 82, 18, 7989, 1897, 1435, 4672, 468, 336, 279, 1057, 628, 326, 30159, 8710, 645, 273, 306, 5436, 63, 77, 65, 364, 3833, 316, 293, 881, 1067, 82, 18, 2165, 2372, 1435, 65, 225, 468, 3671, 326, 8892, 434, 326, 1057, 18, 468, 2305, 21085, 2 ]
return {'value': result['value'], 'warning':warning}
return {'value': result.get('value',{}), 'warning':warning}
def product_id_change(self, cr, uid, ids, pricelist, product, qty=0, uom=False, qty_uos=0, uos=False, name='', partner_id=False, lang=False, update_tax=True, date_order=False, packaging=False, fiscal_position=False, flag=False): warning = {} if not product: return {'value': {'th_weight' : 0, 'product_packaging': False, 'product_uos_qty': qty}, 'domain': {'product_uom': [], 'product_uos': []}} product_obj = self.pool.get('product.product') product_info = product_obj.browse(cr, uid, product) title = False message = False if product_info.sale_line_warn != 'no-message': if product_info.sale_line_warn == 'block': raise osv.except_osv(_('Alert for %s !') % (product_info.name), product_info.sale_line_warn_msg) title = _("Warning for %s") % product_info.name message = product_info.sale_line_warn_msg warning['title'] = title warning['message'] = message result = super(sale_order_line, self).product_id_change( cr, uid, ids, pricelist, product, qty, uom, qty_uos, uos, name, partner_id, lang, update_tax, date_order, packaging, fiscal_position, flag)
436cfd6954d5ed8e538ae3c4c141e9cf56f75bae /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/7397/436cfd6954d5ed8e538ae3c4c141e9cf56f75bae/warning.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3017, 67, 350, 67, 3427, 12, 2890, 16, 4422, 16, 4555, 16, 3258, 16, 846, 335, 5449, 16, 3017, 16, 26667, 33, 20, 16, 582, 362, 33, 8381, 16, 26667, 67, 89, 538, 33, 20, 16, 582, 538, 33, 8381, 16, 508, 2218, 2187, 19170, 67, 350, 33, 8381, 16, 3303, 33, 8381, 16, 1089, 67, 8066, 33, 5510, 16, 1509, 67, 1019, 33, 8381, 16, 2298, 5755, 33, 8381, 16, 15324, 771, 67, 3276, 33, 8381, 16, 2982, 33, 8381, 4672, 3436, 273, 2618, 309, 486, 3017, 30, 327, 13666, 1132, 4278, 13666, 451, 67, 4865, 11, 294, 374, 16, 296, 5896, 67, 2920, 5755, 4278, 1083, 16, 296, 5896, 67, 89, 538, 67, 85, 4098, 4278, 26667, 5779, 296, 4308, 4278, 13666, 5896, 67, 89, 362, 4278, 5378, 16, 296, 5896, 67, 89, 538, 4278, 5378, 9090, 3017, 67, 2603, 273, 365, 18, 6011, 18, 588, 2668, 5896, 18, 5896, 6134, 3017, 67, 1376, 273, 3017, 67, 2603, 18, 25731, 12, 3353, 16, 4555, 16, 3017, 13, 2077, 273, 1083, 883, 273, 1083, 225, 309, 3017, 67, 1376, 18, 87, 5349, 67, 1369, 67, 8935, 480, 296, 2135, 17, 2150, 4278, 309, 3017, 67, 1376, 18, 87, 5349, 67, 1369, 67, 8935, 422, 296, 2629, 4278, 1002, 1140, 90, 18, 14137, 67, 538, 90, 24899, 2668, 13298, 364, 738, 87, 401, 6134, 738, 261, 5896, 67, 1376, 18, 529, 3631, 3017, 67, 1376, 18, 87, 5349, 67, 1369, 67, 8935, 67, 3576, 13, 2077, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3017, 67, 350, 67, 3427, 12, 2890, 16, 4422, 16, 4555, 16, 3258, 16, 846, 335, 5449, 16, 3017, 16, 26667, 33, 20, 16, 582, 362, 33, 8381, 16, 26667, 67, 89, 538, 33, 20, 16, 582, 538, 33, 8381, 16, 508, 2218, 2187, 19170, 67, 350, 33, 8381, 16, 3303, 33, 8381, 16, 1089, 67, 8066, 33, 5510, 16, 1509, 67, 1019, 33, 8381, 16, 2298, 5755, 33, 8381, 16, 15324, 771, 67, 3276, 33, 8381, 16, 2982, 33, 8381, 4672, 3436, 273, 2618, 309, 486, 3017, 30, 327, 13666, 1132, 4278, 13666, 451, 67, 4865, 11, 294, 374, 16, 296, 5896, 67, 2920, 5755, 4278, 1083, 16, 296, 5896, 67, 89, 538, 67, 85, 4098, 4278, 2 ]
%%%%displayAuth(request)%%%%
%%%%displayFooter(request)%%%%
def process(self,write,request,day,month,year,title,data):
b508ccb48d151365a9e848f61248f21f87fc5e1d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12595/b508ccb48d151365a9e848f61248f21f87fc5e1d/cal.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1207, 12, 2890, 16, 2626, 16, 2293, 16, 2881, 16, 7496, 16, 6874, 16, 2649, 16, 892, 4672, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1207, 12, 2890, 16, 2626, 16, 2293, 16, 2881, 16, 7496, 16, 6874, 16, 2649, 16, 892, 4672, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
sage: p = SQLQuery(DB, {'table_name':'simon', 'display_cols':'b2', 'dillhole':['b2','=', 0]})
sage: p = SQLQuery(DB, {'table_name':'simon', 'display_cols':'b2', 'expression':['b2','=', 0]})
def delete_rows(self, query): """ DOCSTRING COMMENTS: - Query must have no join statements (you can only delete from one table at a time) (This might be an interesting TODO later, ie: another function that creates multiple delete statements from a query with joins... I don't think it's really necessary at this time though. - Use a query instance to modify your database. - Note that you cannot use a GenericSQLQuery. (NO RESPONSIBILITY) - If you would like to remove all data that satisfies a query, enter that query as a parameter in the delete_rows function. - Recommended use: have some kind of primary key column that you use as a parameter in the query - Be careful, test your query first. - (Examples of this) - Also note that this database must be the database that the query is associated with (test that?) ROBERT : I haven't tested this... if if doesn't work, then it is probably the param_tuple thing... send me an email if it's not working EXAMPLES: sage: DB = SQLDatabase() sage: DB.create_table('simon',{'a1':{'sql':'bool','primary_key':False}, 'b2':{'sql':'int', 'primary_key':False}}) sage: DB.add_data('simon',[(0,0),(1,1),(1,2)]) sage: p = SQLQuery(DB, {'table_name':'simon', 'display_cols':'b2', 'dillhole':['b2','=', 0]}) sage: DB.delete_rows(p) sage: cur = DB.get_cursor() sage: (cur.execute('select * from simon')).fetchall() [(1, 1), (1, 2)] syntax: delete from table_name where blah=val """ # Check query is associated with this database # TODO : Robert, does this work? And do you suggest any other checking? if not isinstance(query, SQLQuery): raise TypeError('%s is not a valid SQLQuery'%query) if query.__database__ is not self: raise ValueError('%s is not associated to this database.'%query) if (query.__query_string__).__contains__(' JOIN '): raise ValueError('%s is not a valid query. Can only delete from one table at a time.'%query) delete_statement = re.sub('SELECT .* FROM', 'DELETE FROM', query.__query_string__) try: tup = str(query.__param_tuple__).rstrip(')') + ',)' cur = self.__connection__.cursor() if query.__param_tuple__ is not None: tup = [] for i in range(len(query.__param_tuple__)): tup.append(str(query.__param_tuple__[i])) cur.execute(delete_statement, tuple(tup)) else: cur.execute(delete_statement) except: raise RuntimeError('Failure to complete delete. Check your data.')
5ddf79d83938a9c0191ec3af2f60e264a74ecef9 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9890/5ddf79d83938a9c0191ec3af2f60e264a74ecef9/database.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1430, 67, 3870, 12, 2890, 16, 843, 4672, 3536, 5467, 39, 5804, 19400, 55, 30, 300, 2770, 1297, 1240, 1158, 1233, 6317, 261, 19940, 848, 1338, 1430, 628, 1245, 1014, 622, 279, 813, 13, 261, 2503, 4825, 506, 392, 26122, 2660, 5137, 16, 9228, 30, 4042, 445, 716, 3414, 3229, 1430, 6317, 628, 279, 843, 598, 13471, 2777, 225, 467, 2727, 1404, 15507, 518, 1807, 8654, 4573, 622, 333, 813, 11376, 18, 300, 2672, 279, 843, 791, 358, 5612, 3433, 2063, 18, 300, 3609, 716, 1846, 2780, 999, 279, 7928, 3997, 1138, 18, 225, 261, 3417, 2438, 10789, 30310, 13, 300, 971, 1846, 4102, 3007, 358, 1206, 777, 501, 716, 17917, 279, 843, 16, 6103, 716, 843, 487, 279, 1569, 316, 326, 1430, 67, 3870, 445, 18, 300, 25546, 3934, 999, 30, 1240, 2690, 3846, 434, 3354, 498, 1057, 716, 1846, 999, 487, 279, 1569, 316, 326, 843, 300, 4823, 26850, 16, 1842, 3433, 843, 1122, 18, 300, 261, 23905, 434, 333, 13, 300, 8080, 4721, 716, 333, 2063, 1297, 506, 326, 2063, 716, 326, 843, 353, 3627, 598, 261, 3813, 716, 8535, 534, 5704, 11539, 294, 467, 15032, 1404, 18432, 333, 2777, 309, 309, 3302, 1404, 1440, 16, 1508, 518, 353, 8656, 326, 579, 67, 8052, 7757, 2777, 225, 1366, 1791, 392, 2699, 309, 518, 1807, 486, 5960, 225, 5675, 8900, 11386, 30, 272, 410, 30, 2383, 273, 3063, 4254, 1435, 272, 410, 30, 2383, 18, 2640, 67, 2121, 2668, 9812, 265, 2187, 27828, 69, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1430, 67, 3870, 12, 2890, 16, 843, 4672, 3536, 5467, 39, 5804, 19400, 55, 30, 300, 2770, 1297, 1240, 1158, 1233, 6317, 261, 19940, 848, 1338, 1430, 628, 1245, 1014, 622, 279, 813, 13, 261, 2503, 4825, 506, 392, 26122, 2660, 5137, 16, 9228, 30, 4042, 445, 716, 3414, 3229, 1430, 6317, 628, 279, 843, 598, 13471, 2777, 225, 467, 2727, 1404, 15507, 518, 1807, 8654, 4573, 622, 333, 813, 11376, 18, 300, 2672, 279, 843, 791, 358, 5612, 3433, 2063, 18, 300, 3609, 716, 1846, 2780, 999, 279, 7928, 3997, 1138, 18, 225, 261, 3417, 2438, 10789, 30310, 13, 300, 971, 1846, 4102, 3007, 358, 1206, 777, 501, 716, 17917, 279, 843, 16, 6103, 716, 843, 487, 2 ]
if self.editRestriction: self.site().forceLogin(sysop=True) else: self.site().forceLogin() username = self.site()._loggedInAs
try: if self.editRestriction: self.site().forceLogin(sysop=True) else: self.site().forceLogin() username = self.site()._loggedInAs except NoUsername: username = None
def botMayEdit(self): """ True if page doesn't contain {{bots}} or {{nobots}} or contains them and active bot is allowed or not allowed to edit said page
aede702039b6b257c4543b5b8de34b122c544a1d /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/4404/aede702039b6b257c4543b5b8de34b122c544a1d/wikipedia.py
[ 1, 8585, 326, 22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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2512, 49, 528, 4666, 12, 2890, 4672, 3536, 1053, 309, 1363, 3302, 1404, 912, 10179, 4819, 87, 9090, 578, 10179, 82, 947, 6968, 9090, 578, 1914, 2182, 471, 2695, 2512, 353, 2935, 578, 486, 2935, 358, 3874, 7864, 350, 1363, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
def load_filename(filename, verbose = False, gz = False, xmldoc = None, contenthandler = None):
def load_filename(filename, verbose = False, gz = None, xmldoc = None, contenthandler = None):
def load_filename(filename, verbose = False, gz = False, xmldoc = None, contenthandler = None): """ Parse the contents of the file identified by filename, and return the contents as a LIGO Light Weight document tree. Helpful verbosity messages are printed to stderr if verbose is True, and the file is gzip decompressed while reading if gz is set to True. If filename is None, then stdin is parsed. If the optional xmldoc argument is provided and not None, the parsed XML tree will be appended to that document, otherwise a new document will be created. Example: >>> from glue.ligolw import utils >>> xmldoc = utils.load_filename(name, verbose = True, gz = (name or "stdin").endswidth(".gz")) """ if verbose: print >>sys.stderr, "reading %s ..." % (filename and ("'%s'" % filename) or "stdin") if filename is not None: fileobj = file(filename) else: fileobj = sys.stdin xmldoc, hexdigest = load_fileobj(fileobj, gz = gz, xmldoc = xmldoc, contenthandler = contenthandler) if verbose: print >>sys.stderr, "md5sum: %s %s" % (hexdigest, filename or "") return xmldoc
4eab7f4d4ad91c4a7aa23e82dcbb61b7895f83ed /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/3589/4eab7f4d4ad91c4a7aa23e82dcbb61b7895f83ed/__init__.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1262, 67, 3459, 12, 3459, 16, 3988, 273, 1083, 16, 14136, 273, 599, 16, 2025, 2434, 273, 599, 16, 913, 4176, 273, 599, 4672, 3536, 2884, 326, 2939, 434, 326, 585, 9283, 635, 1544, 16, 471, 327, 326, 2939, 487, 279, 511, 3047, 51, 15992, 15437, 1668, 2151, 18, 225, 11288, 2706, 11561, 2743, 854, 14099, 358, 4514, 309, 3988, 353, 1053, 16, 471, 326, 585, 353, 10331, 443, 15385, 1323, 6453, 309, 14136, 353, 444, 358, 1053, 18, 971, 1544, 353, 599, 16, 1508, 8801, 353, 2707, 18, 225, 971, 326, 3129, 2025, 2434, 1237, 353, 2112, 471, 486, 599, 16, 326, 2707, 3167, 2151, 903, 506, 12317, 358, 716, 1668, 16, 3541, 279, 394, 1668, 903, 506, 2522, 18, 225, 5090, 30, 225, 4080, 628, 17960, 18, 80, 360, 355, 91, 1930, 2990, 4080, 2025, 2434, 273, 2990, 18, 945, 67, 3459, 12, 529, 16, 3988, 273, 1053, 16, 14136, 273, 261, 529, 578, 315, 21772, 20387, 5839, 2819, 2932, 18, 9764, 6, 3719, 3536, 309, 3988, 30, 1172, 1671, 9499, 18, 11241, 16, 315, 21803, 738, 87, 18483, 738, 261, 3459, 471, 261, 5187, 9, 87, 4970, 738, 1544, 13, 578, 315, 21772, 7923, 309, 1544, 353, 486, 599, 30, 17041, 273, 585, 12, 3459, 13, 469, 30, 17041, 273, 2589, 18, 21772, 2025, 2434, 16, 16280, 273, 1262, 67, 768, 2603, 12, 768, 2603, 16, 14136, 273, 14136, 16, 2025, 2434, 273, 2025, 2434, 16, 913, 4176, 273, 913, 4176, 13, 309, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1262, 67, 3459, 12, 3459, 16, 3988, 273, 1083, 16, 14136, 273, 599, 16, 2025, 2434, 273, 599, 16, 913, 4176, 273, 599, 4672, 3536, 2884, 326, 2939, 434, 326, 585, 9283, 635, 1544, 16, 471, 327, 326, 2939, 487, 279, 511, 3047, 51, 15992, 15437, 1668, 2151, 18, 225, 11288, 2706, 11561, 2743, 854, 14099, 358, 4514, 309, 3988, 353, 1053, 16, 471, 326, 585, 353, 10331, 443, 15385, 1323, 6453, 309, 14136, 353, 444, 358, 1053, 18, 971, 1544, 353, 599, 16, 1508, 8801, 353, 2707, 18, 225, 971, 326, 3129, 2025, 2434, 1237, 353, 2112, 471, 486, 599, 16, 326, 2707, 3167, 2151, 903, 506, 12317, 358, 716, 1668, 16, 3541, 279, 394, 1668, 903, 2 ]
"""QueuePage
"""Returns a list of chain IDs and their sizes.
def chain_size_string(self, jdict): """QueuePage """ if jdict.has_key("chains") == False: return "---"
ebe7911aaa6579796c3b771f64c91ad7ae981d9b /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/10674/ebe7911aaa6579796c3b771f64c91ad7ae981d9b/webtlsmd.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2687, 67, 1467, 67, 1080, 12, 2890, 16, 525, 1576, 4672, 3536, 1356, 279, 666, 434, 2687, 7115, 471, 3675, 8453, 18, 3536, 309, 525, 1576, 18, 5332, 67, 856, 2932, 23060, 7923, 422, 1083, 30, 327, 5238, 10951, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2687, 67, 1467, 67, 1080, 12, 2890, 16, 525, 1576, 4672, 3536, 1356, 279, 666, 434, 2687, 7115, 471, 3675, 8453, 18, 3536, 309, 525, 1576, 18, 5332, 67, 856, 2932, 23060, 7923, 422, 1083, 30, 327, 5238, 10951, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
new_crypted = crypt.crypt(password, original_crypted[:2])
new_crypted = crypt.crypt(password, original_crypted)
def authenticate(self, username, password): try: passwd = nis.match(username, 'passwd').split(':') original_crypted = passwd[1] new_crypted = crypt.crypt(password, original_crypted[:2])
bf6d9112e6782ddb4649c9091a2d4ae426785ce3 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/1600/bf6d9112e6782ddb4649c9091a2d4ae426785ce3/backends.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 8929, 12, 2890, 16, 2718, 16, 2201, 4672, 775, 30, 19093, 273, 290, 291, 18, 1916, 12, 5053, 16, 296, 24002, 16063, 4939, 2668, 2497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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 8929, 12, 2890, 16, 2718, 16, 2201, 4672, 775, 30, 19093, 273, 290, 291, 18, 1916, 12, 5053, 16, 296, 24002, 16063, 4939, 2668, 2497, 13, 2282, 67, 71, 4567, 273, 19093, 63, 21, 65, 394, 67, 71, 4567, 273, 13231, 18, 22784, 12, 3664, 16, 2282, 67, 71, 4567, 10531, 22, 5717, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
def hover2_bt_clicked(obj, event, *args, **kargs): pass def hover2_clicked(obj, event, *args, **kargs):
def hover2_clicked(obj, i, *args, **kwargs):
def hover2_bt_clicked(obj, event, *args, **kargs): pass
dff3caa2ec713908f112c4970120d3d880226170 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12343/dff3caa2ec713908f112c4970120d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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 15758, 22, 67, 23602, 67, 7475, 329, 12, 2603, 16, 871, 16, 380, 1968, 16, 2826, 79, 1968, 4672, 1342, 225, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
(panda_config.glite_source,panda_config.native_python,panda_config.lfcClient_dir,
(panda_config.glite_source,panda_config.native_python32,panda_config.lfcClient_dir,
def _getPFNFromLFC(lfns,dq2url,guids,storageName): _log.debug('_getPFNFromLFC') outStr = '' # check paramter if guids == [] or storageName == [] or (len(lfns) != len(guids)): return outStr # extract LFC host lfcHost = re.sub('[/:]',' ',dq2url).split()[1] # loop over all LFNs iLFN = 0 nLFN = 50 strLFNs = '' strGUIDs = '' outStr = '' for iLFN in range(len(lfns)): strLFNs += '%s,' % lfns[iLFN] strGUIDs += '%s,' % guids[iLFN] # bulk operation if (iLFN+1) % nLFN == 0 or (iLFN+1) >= len(lfns): strLFNs = strLFNs[:-1] strGUIDs = strGUIDs[:-1] # construct commands strStorage = '' for storage in storageName: strStorage += '%s,' % storage strStorage = strStorage[:-1] com = 'unset LD_LIBRARY_PATH; unset PYTHONPATH; export PATH=/usr/local/bin:/bin:/usr/bin; ' com+= 'source %s; %s/python -Wignore %s/LFCclient.py -i %s -g %s -l %s -s %s' % \ (panda_config.glite_source,panda_config.native_python,panda_config.lfcClient_dir, strLFNs,strGUIDs,lfcHost,strStorage) _log.debug(com) # exeute status,output = commands.getstatusoutput(com) _log.debug(status) if status == 0: outStr += output else: _log.error("_getPFNFromLFC : %s %s %s" % (dq2url,status,output)) # send message to logger try: # make message message = 'LFC access : %s %s %s' % (dq2url,status,output) # get logger _pandaLogger = PandaLogger() _pandaLogger.lock() _pandaLogger.setParams({'Type':'broker_util'}) logger = _pandaLogger.getHttpLogger(panda_config.loggername) # add message logger.error(message) # release HTTP handler _pandaLogger.release() except: pass return status # reset strLFNs = '' strGUIDs = '' # return return outStr
37701f29dea9eb875a3436cfc7fb9717f1665cf8 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/7525/37701f29dea9eb875a3436cfc7fb9717f1665cf8/broker_util.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 588, 52, 19793, 1265, 48, 4488, 12, 20850, 2387, 16, 72, 85, 22, 718, 16, 14066, 87, 16, 5697, 461, 4672, 389, 1330, 18, 4148, 2668, 67, 588, 52, 19793, 1265, 48, 4488, 6134, 596, 1585, 273, 875, 468, 866, 579, 387, 309, 9875, 87, 422, 5378, 578, 2502, 461, 422, 5378, 578, 261, 1897, 12, 20850, 2387, 13, 480, 562, 12, 14066, 87, 3719, 30, 327, 596, 1585, 468, 2608, 511, 4488, 1479, 328, 7142, 2594, 273, 283, 18, 1717, 2668, 63, 16880, 65, 17023, 2265, 72, 85, 22, 718, 2934, 4939, 1435, 63, 21, 65, 468, 2798, 1879, 777, 18803, 10386, 277, 9105, 50, 273, 374, 290, 9105, 50, 273, 6437, 609, 9105, 10386, 273, 875, 609, 17525, 87, 273, 875, 596, 1585, 273, 875, 364, 277, 9105, 50, 316, 1048, 12, 1897, 12, 20850, 2387, 3719, 30, 609, 9105, 10386, 225, 1011, 1995, 87, 11189, 738, 18594, 2387, 63, 77, 9105, 50, 65, 609, 17525, 87, 1011, 1995, 87, 11189, 738, 9875, 87, 63, 77, 9105, 50, 65, 468, 8280, 1674, 309, 261, 77, 9105, 50, 15, 21, 13, 738, 290, 9105, 50, 422, 374, 578, 261, 77, 9105, 50, 15, 21, 13, 1545, 562, 12, 20850, 2387, 4672, 609, 9105, 10386, 225, 273, 609, 9105, 10386, 10531, 17, 21, 65, 609, 17525, 87, 273, 609, 17525, 87, 10531, 17, 21, 65, 468, 4872, 4364, 609, 3245, 273, 875, 364, 2502, 316, 2502, 461, 30, 609, 3245, 1011, 1995, 87, 11189, 738, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 588, 52, 19793, 1265, 48, 4488, 12, 20850, 2387, 16, 72, 85, 22, 718, 16, 14066, 87, 16, 5697, 461, 4672, 389, 1330, 18, 4148, 2668, 67, 588, 52, 19793, 1265, 48, 4488, 6134, 596, 1585, 273, 875, 468, 866, 579, 387, 309, 9875, 87, 422, 5378, 578, 2502, 461, 422, 5378, 578, 261, 1897, 12, 20850, 2387, 13, 480, 562, 12, 14066, 87, 3719, 30, 327, 596, 1585, 468, 2608, 511, 4488, 1479, 328, 7142, 2594, 273, 283, 18, 1717, 2668, 63, 16880, 65, 17023, 2265, 72, 85, 22, 718, 2934, 4939, 1435, 63, 21, 65, 468, 2798, 1879, 777, 18803, 10386, 277, 9105, 50, 273, 374, 290, 9105, 50, 273, 6437, 609, 9105, 10386, 273, 2 ]
d = (minimaMap(p)-p).magnitude() if (d < mindist): mindist = d setattr(edge, self.attrName, mindist)
near = minimaMap(p, mindist2) if near: mindist2 = (near-p).squaredMagnitude() setattr(edge, self.attrName, math.sqrt(mindist2))
def __init__(self, map, bi): DynamicEdgeStatistics.__init__(self, map) self.attrName = _makeAttrName("minDist_"+bi.name) minimaMap = PositionedMap() minima=localMinmax(bi.gm,True,False,False) for y in range(minima.height()): for x in range(minima.width()): if minima[x,y]<0: minimaMap.insert(Vector2(x,y), Vector2(x,y)) for edge in map.edgeIter(): mindist = 1e8 for p in edge: d = (minimaMap(p)-p).magnitude() if (d < mindist): mindist = d setattr(edge, self.attrName, mindist)
8925518c2ae9f74de3b734317beccbc4670dbd43 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/10394/8925518c2ae9f74de3b734317beccbc4670dbd43/statistics.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 852, 16, 10054, 4672, 12208, 6098, 8569, 16186, 2738, 972, 12, 2890, 16, 852, 13, 365, 18, 1747, 461, 273, 389, 6540, 28973, 2932, 1154, 5133, 9548, 15, 13266, 18, 529, 13, 1131, 13888, 863, 273, 11010, 329, 863, 1435, 1131, 13888, 33, 3729, 2930, 1896, 12, 13266, 18, 23336, 16, 5510, 16, 8381, 16, 8381, 13, 364, 677, 316, 1048, 12, 1154, 13888, 18, 4210, 1435, 4672, 364, 619, 316, 1048, 12, 1154, 13888, 18, 2819, 1435, 4672, 309, 1131, 13888, 63, 92, 16, 93, 65, 32, 20, 30, 1131, 13888, 863, 18, 6387, 12, 5018, 22, 12, 92, 16, 93, 3631, 5589, 22, 12, 92, 16, 93, 3719, 364, 3591, 316, 852, 18, 7126, 2360, 13332, 22838, 376, 273, 404, 73, 28, 364, 293, 316, 3591, 30, 302, 273, 261, 1154, 13888, 863, 12, 84, 24950, 84, 2934, 30279, 1435, 309, 261, 72, 411, 22838, 376, 4672, 22838, 376, 273, 302, 9241, 12, 7126, 16, 365, 18, 1747, 461, 16, 22838, 376, 13, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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, 13, 365, 18, 1747, 461, 273, 389, 6540, 28973, 2932, 1154, 5133, 9548, 15, 13266, 18, 529, 13, 1131, 13888, 863, 273, 11010, 329, 863, 1435, 1131, 13888, 33, 3729, 2930, 1896, 12, 13266, 18, 23336, 16, 5510, 16, 8381, 16, 8381, 13, 364, 677, 316, 1048, 12, 1154, 13888, 18, 4210, 1435, 4672, 364, 619, 316, 1048, 12, 1154, 13888, 18, 2819, 1435, 4672, 309, 1131, 13888, 63, 92, 16, 93, 65, 32, 20, 30, 1131, 13888, 863, 18, 6387, 12, 5018, 22, 12, 92, 16, 93, 3631, 5589, 22, 12, 92, 16, 93, 3719, 364, 3591, 2 ]
result = DIRAC.gConfig.getSections( '/Resources/Sites/LCG' )
gridCfgPath = cfgPath( 'Resources', 'Sites', grid ) result = DIRAC.gConfig.getSections( gridCfgPath )
def usage(): print 'Usage: %s < ce name> [< ce name>]' % ( Script.scriptName ) DIRAC.exit( 2 )
096c758e5e556790bf90e5743318f77f9fc92894 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12864/096c758e5e556790bf90e5743318f77f9fc92894/dirac-admin-ce-info.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4084, 13332, 1172, 296, 5357, 30, 738, 87, 411, 5898, 508, 34, 306, 32, 5898, 508, 34, 3864, 738, 261, 7739, 18, 4263, 461, 262, 18544, 2226, 18, 8593, 12, 576, 262, 225, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4084, 13332, 1172, 296, 5357, 30, 738, 87, 411, 5898, 508, 34, 306, 32, 5898, 508, 34, 3864, 738, 261, 7739, 18, 4263, 461, 262, 18544, 2226, 18, 8593, 12, 576, 262, 225, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
def GetString(ea, len, type):
def GetString(ea, length, strtype):
def GetString(ea, len, type): """ Get string contents @param ea: linear address @param len: string length. -1 means to calculate the max string length @param type: the string type (one of ASCSTR_... constants) return: string contents or empty string """ if len == -1: strlen = idaapi.get_max_ascii_length(ea, type) else: strlen = len return idaapi.get_ascii_contents(ea, strlen, type)
4f22943d42ee1d5013421d280b3bd776bee83fb9 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/3410/4f22943d42ee1d5013421d280b3bd776bee83fb9/idc.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 18921, 12, 24852, 16, 769, 16, 609, 723, 4672, 3536, 968, 533, 2939, 632, 891, 24164, 30, 9103, 1758, 632, 891, 562, 30, 533, 769, 18, 300, 21, 4696, 358, 4604, 326, 943, 533, 769, 632, 891, 618, 30, 326, 533, 618, 261, 476, 434, 8310, 3902, 67, 2777, 6810, 13, 225, 327, 30, 533, 2939, 578, 1008, 533, 3536, 309, 562, 422, 300, 21, 30, 3203, 273, 612, 69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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 18921, 12, 24852, 16, 769, 16, 609, 723, 4672, 3536, 968, 533, 2939, 632, 891, 24164, 30, 9103, 1758, 632, 891, 562, 30, 533, 769, 18, 300, 21, 4696, 358, 4604, 326, 943, 533, 769, 632, 891, 618, 30, 326, 533, 618, 261, 476, 434, 8310, 3902, 67, 2777, 6810, 13, 225, 327, 30, 533, 2939, 578, 1008, 533, 3536, 309, 562, 422, 300, 21, 30, 3203, 273, 612, 69, 2425, 18, 588, 67, 1896, 67, 9184, 67, 2469, 12, 24852, 16, 618, 13, 469, 30, 3203, 273, 562, 225, 327, 612, 69, 2425, 18, 588, 67, 9184, 67, 3980, 12, 24852, 16, 3203, 16, 618, 13, 282, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
objs.extend(list(ctype.objects.all().order_by('-content_object__creation_date')[:N]))
objs.extend(list(ctype.objects.all()[:N]))
def items(self): N = cyc_settings.CYCLOPE_RSS_LIMIT objs = [] for ctype in sites.site.base_content_types.keys(): objs.extend(list(ctype.objects.all().order_by('-content_object__creation_date')[:N])) return sorted(objs, key=lambda x: x.creation_date, reverse = True)[:N]
503668a169932bfdaf40f2ea61eb7710d6f24638 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/797/503668a169932bfdaf40f2ea61eb7710d6f24638/feeds.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1516, 12, 2890, 4672, 423, 273, 6143, 71, 67, 4272, 18, 16068, 22693, 1423, 67, 31211, 67, 8283, 12721, 273, 5378, 364, 11920, 316, 9180, 18, 4256, 18, 1969, 67, 1745, 67, 2352, 18, 2452, 13332, 12721, 18, 14313, 12, 1098, 12, 12387, 18, 6911, 18, 454, 1435, 10531, 50, 22643, 327, 3115, 12, 18093, 16, 498, 33, 14661, 619, 30, 619, 18, 17169, 67, 712, 16, 4219, 273, 1053, 13, 10531, 50, 65, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1516, 12, 2890, 4672, 423, 273, 6143, 71, 67, 4272, 18, 16068, 22693, 1423, 67, 31211, 67, 8283, 12721, 273, 5378, 364, 11920, 316, 9180, 18, 4256, 18, 1969, 67, 1745, 67, 2352, 18, 2452, 13332, 12721, 18, 14313, 12, 1098, 12, 12387, 18, 6911, 18, 454, 1435, 10531, 50, 22643, 327, 3115, 12, 18093, 16, 498, 33, 14661, 619, 30, 619, 18, 17169, 67, 712, 16, 4219, 273, 1053, 13, 10531, 50, 65, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
exercise_threading() exercise_process()
from libtbx import thread_utils thread_utils.exercise_threading() thread_utils.exercise_process()
def _target_function06 (args, kwds, connection) : for i in xrange(1000) : print i time.sleep(1)
87aa46994d8d95744d69de303382b8021d70b4a8 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/696/87aa46994d8d95744d69de303382b8021d70b4a8/thread_utils.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 3299, 67, 915, 7677, 261, 1968, 16, 17149, 16, 1459, 13, 294, 364, 277, 316, 12314, 12, 18088, 13, 294, 1172, 277, 813, 18, 19607, 12, 21, 13, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 3299, 67, 915, 7677, 261, 1968, 16, 17149, 16, 1459, 13, 294, 364, 277, 316, 12314, 12, 18088, 13, 294, 1172, 277, 813, 18, 19607, 12, 21, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
jump(4) """ self.optimize_loop(ops, expected)
jump() """ expected = """ [] jump() """ self.optimize_loop(ops, expected, preamble)
def test_bound_lt_noopt(self): ops = """ [i0] i1 = int_lt(i0, 4) guard_false(i1) [] i2 = int_lt(i0, 5) guard_true(i2) [] jump(i0) """ expected = """ [i0] i1 = int_lt(i0, 4) guard_false(i1) [] i2 = int_lt(i0, 5) guard_true(i2) [] jump(4) """ self.optimize_loop(ops, expected)
c1c567f913716b04331394b638b204be95cb1dc4 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/6934/c1c567f913716b04331394b638b204be95cb1dc4/test_optimizeopt.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 67, 3653, 67, 5618, 67, 2135, 3838, 12, 2890, 4672, 6727, 273, 3536, 306, 77, 20, 65, 277, 21, 273, 509, 67, 5618, 12, 77, 20, 16, 1059, 13, 11026, 67, 5743, 12, 77, 21, 13, 5378, 277, 22, 273, 509, 67, 5618, 12, 77, 20, 16, 1381, 13, 11026, 67, 3767, 12, 77, 22, 13, 5378, 11833, 12, 77, 20, 13, 3536, 2665, 273, 3536, 306, 77, 20, 65, 277, 21, 273, 509, 67, 5618, 12, 77, 20, 16, 1059, 13, 11026, 67, 5743, 12, 77, 21, 13, 5378, 277, 22, 273, 509, 67, 5618, 12, 77, 20, 16, 1381, 13, 11026, 67, 3767, 12, 77, 22, 13, 5378, 11833, 12, 24, 13, 3536, 365, 18, 29155, 67, 6498, 12, 4473, 16, 2665, 13, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,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, 12, 77, 20, 16, 1059, 13, 11026, 67, 5743, 12, 77, 21, 13, 5378, 277, 22, 273, 509, 67, 5618, 12, 77, 20, 16, 1381, 13, 11026, 67, 3767, 12, 77, 22, 13, 5378, 11833, 12, 77, 20, 13, 3536, 2665, 273, 3536, 306, 77, 20, 65, 277, 21, 273, 509, 67, 5618, 12, 77, 20, 16, 1059, 13, 11026, 67, 5743, 12, 77, 21, 13, 5378, 277, 22, 273, 509, 67, 5618, 12, 77, 20, 16, 1381, 13, 11026, 67, 3767, 12, 77, 22, 13, 5378, 11833, 12, 24, 13, 3536, 365, 18, 2 ]
mod_data.append([[x[0] / 60, x[1]] for x in mod_data_seconds])
mod_data.append([[x[0] / X_Scale_Factor, x[1]] for x in mod_data_seconds])
def extract_comp_data(comp_file_info): ## Read in d line dict from config file and Process data from source .csv files. exp_data = [] mod_data = [] exp_data_dict = {} mod_data_dict = {} exp_scatter_data_labels = [] mod_scatter_data_labels = [] #List of variables from configuration file column names. exp_data_filename = comp_file_info['Exp_Filename'] #String of filename exp_column_name_row_index = int(comp_file_info['Exp_Col_Name_Row'])-1 #Experimental Data Column Name Row Number exp_data_row_index = int(comp_file_info['Exp_Data_Row'])-1 #Experimental Data Starting Row Number exp_start_data_val = comp_file_info['Exp_Start_(min.)'] #String in minutes to start exp plot data exp_stop_data_val = comp_file_info['Exp_End_(min.)'] #String in minutes to stop exp plot data exp_start_comp_val = comp_file_info['Exp_Comp_Start_(min.)'] #String in minutes to start exp compare data exp_stop_comp_val = comp_file_info['Exp_Comp_End_(min.)'] #String in minutes to start exp compare data exp_initial_value = comp_file_info['Exp_Intitial_Value'] #Initial Value for Quantity exp_X_column_name_value = comp_file_info['Exp_X_Col_Name'].strip() #Experimental Data X Column Name exp_Y_column_name_value = comp_file_info['Exp_Y_Col_Name'].strip() #Experimental Data Y Column Name X_Scale_Factor = int(comp_file_info['Scale_X']) Y_Scale_Factor = int(comp_file_info['Scale_Y']) mod_data_filename = comp_file_info['Mod_Filename'] #String of filename mod_column_name_row_index = int(comp_file_info['Mod_Col_Name_Row'])-1 #Modeling Data Column Name Row Number mod_data_row_index = int(comp_file_info['Mod_Data_Row'])-1 #Modeling Data Starting Row Number mod_start_data_val = comp_file_info['Mod_Start_(min.)'] #String in minutes to start mod plot data mod_stop_data_val = comp_file_info['Mod_End_(min.)'] #String in minutes to stop mod plot data mod_start_comp_val = comp_file_info['Mod_Comp_Start_(min.)'] #String in minutes to start mod compare data mod_stop_comp_val = comp_file_info['Mod_Comp_End_(min.)'] #String in minutes to start mod compare data mod_initial_value = comp_file_info['Mod_Intitial_Value'] #Initial Value for Quantity mod_X_column_name_value = comp_file_info['Mod_X_Col_Name'].strip() #Modeling Data X Column Name mod_Y_column_name_value = comp_file_info['Mod_Y_Col_Name'].strip() #Modeling Data Y Column Name # Create Scatter Data Labels for the comparison results. if exp_Y_column_name_value[0] == '[': print "Exp Column Name List Detected" exp_compound_col_names = eval(exp_Y_column_name_value) #print "Exp Compound Column Names:", exp_compound_col_names for name in exp_compound_col_names: print "Exp Sub-Column Name:", name exp_scatter_data_labels.append(comp_file_info['Quantity']+"~"+comp_file_info['Group']+"~"+comp_file_info['Dataname']+"~"+name) else: print "Single Exp. Column Name:", exp_Y_column_name_value exp_scatter_data_labels.append(comp_file_info['Quantity']+"~"+comp_file_info['Group']+"~"+comp_file_info['Dataname']+"~"+exp_Y_column_name_value) if mod_Y_column_name_value[0] == '[': print "Mod Column Name List Detected" mod_compound_col_names = eval(mod_Y_column_name_value) #print "Mod Compound Column Names:", mod_Y_column_name_value for name in mod_compound_col_names: print "Mod Sub-Column Name:", name mod_scatter_data_labels.append(comp_file_info['Quantity']+"~"+comp_file_info['Group']+"~"+comp_file_info['Dataname']+"~"+name) else: print "Single Mod. Column Name:", mod_Y_column_name_value mod_scatter_data_labels.append(comp_file_info['Quantity']+"~"+comp_file_info['Group']+"~"+comp_file_info['Dataname']+"~"+mod_Y_column_name_value) print "Exp Data Labels:\n", exp_scatter_data_labels print "Mod Data Labels:\n", mod_scatter_data_labels combined_scatter_data_labels = [exp_scatter_data_labels,mod_scatter_data_labels] #print "Combined Scatter Data:",combined_scatter_data_labels min_max = comp_file_info['max/min'] #String indicating if min or max value is required. group_value = int(comp_file_info['Group']) try: exp_file_object = open(data_directory+exp_data_filename, "U") except: print "!!! Experimental "+exp_data_filename+" Data File will not open. !!!" exit() try: mod_file_object = open(data_directory+mod_data_filename, "U") except: print "!!! Modeling "+mod_data_filename+" Data File will not open. !!!" exit() ## Start File Processing #Read in experimental data and flip lists from rows to columns. print "Reading in:", exp_data_filename exp_data_cols = zip(*csv.reader(exp_file_object)) #print "exp_data_cols: ",exp_data_cols #Find X_Axis index number and confirm Col_Name based on Exp_X_Col_Name value in config file. column_counter = 0 for column in exp_data_cols: if column[exp_column_name_row_index].strip() == exp_X_column_name_value: print "Exp. X Col name is: ",column[exp_column_name_row_index].strip() #print "The Index Value is:",column_counter exp_Xaxis_column_name = column[exp_column_name_row_index].strip() else: column_counter = column_counter + 1 if column_counter == len(exp_data_cols): print "!!! Problem with Exp_X_Col_Name value in Config File !!!" exit() #Convert tuples to lists. exp_data_list = [list(sublist) for sublist in exp_data_cols] #Build Experimental Data Dictionary. #Catch errors if conversion of data from string to float fails. for exp_list in exp_data_list: try: temp_list = [] for x in exp_list[exp_data_row_index:]: if x == 'Null' or x == '' or x == 'NaN' or x == 'inf' or x == '-inf': list_value = 'Null' else: list_value = float(x) temp_list.append(list_value) exp_data_dict[exp_list[exp_column_name_row_index].strip()] = temp_list except: print "!!! Exp Data Conversion in Column Name "+exp_list[exp_column_name_row_index].strip()+". !!!" exit() #Read in model data and flip lists from rows to columns. print "Reading in:", mod_data_filename mod_data_cols = zip(*csv.reader(mod_file_object)) #print "mod_data_cols: ",mod_data_cols #Find X_Axis index number and confirm Col_Name based on Mod_X_Col_Name value in config file. column_counter = 0 for column in mod_data_cols: if column[mod_column_name_row_index].strip() == mod_X_column_name_value: print "Mod. X Col name is: ",column[mod_column_name_row_index].strip() #print "The Index Value is:",column_counter mod_Xaxis_column_name = column[mod_column_name_row_index].strip() else: column_counter = column_counter + 1 if column_counter == len(mod_data_cols): print "!!! Problem with Mod_X_Col_Name value in Config File !!!" exit() #Convert tuples to lists. mod_data_list = [list(sublist) for sublist in mod_data_cols] #Build Prediction/Model Data Dictionary #Catch errors if conversion of data from string to float fails. for mod_list in mod_data_list: try: temp_list = [] for x in mod_list[mod_data_row_index:]: if x == 'Null' or x == '' or x == 'NaN' or x == 'inf' or x == '-inf': list_value = 'Null' else: list_value = float(x) temp_list.append(list_value) mod_data_dict[mod_list[mod_column_name_row_index].strip()] = temp_list except: print "!!! Mod Data Conversion in Column Name "+mod_list[mod_column_name_row_index].strip()+". !!!" exit() # Passing in the X_Axis Column Name. exp_comp_ranges = find_start_stop_index(exp_data_dict,exp_Xaxis_column_name,exp_start_data_val,exp_stop_data_val,exp_start_comp_val,exp_stop_comp_val,X_Scale_Factor) mod_comp_ranges = find_start_stop_index(mod_data_dict,mod_Xaxis_column_name,mod_start_data_val,mod_stop_data_val,mod_start_comp_val,mod_stop_comp_val,X_Scale_Factor) print "EXP COMP RANGES",exp_comp_ranges print "MOD COMP RANGES",mod_comp_ranges #### Begin Column specific operations. scatter_counter = 0 for scatter_label in combined_scatter_data_labels[0]: #print scatter_counter exp_label_temp = [] mod_label_temp = [] exp_label_temp = split("~",combined_scatter_data_labels[0][scatter_counter]) mod_label_temp = split("~",combined_scatter_data_labels[1][scatter_counter]) #print "Exp. Label Split:", exp_label_temp #print "Mod. Label Split:", mod_label_temp ##Find max or min values. exp_data_values_comp = exp_data_dict[exp_label_temp[3]][exp_comp_ranges[2]:exp_comp_ranges[3]] mod_data_values_comp = mod_data_dict[mod_label_temp[3]][mod_comp_ranges[2]:mod_comp_ranges[3]] #print "Exp data values:", exp_data_values_comp #print "Mod data values:", mod_data_values_comp # This allows the d line Quantity value to be set to 0 when either model or experimental data is missing. if comp_file_info['Quantity'] == str(0): print "Quantity set to 0, no comparison made." else: if min_max == 'max': print "*** Compute Rise ***" temp_exp_data_values = [x for x in exp_data_values_comp if x != 'Null'] exp_rise_value = max(temp_exp_data_values) - float(exp_initial_value) temp_mod_data_values = [x for x in mod_data_values_comp if x != 'Null'] mod_rise_value = max(temp_mod_data_values) - float(mod_initial_value) print "Experimental Initial Value is:", exp_initial_value print "Experimental Rise Value is:", exp_rise_value print "Model Initial Value is:", mod_initial_value print "Model Rise Value is:", mod_rise_value print "\n*** Computing Rise Relative Difference ***" try: relative_difference = ((mod_rise_value-exp_rise_value)/exp_rise_value) print "Rise Relative Difference is:", relative_difference except: print "!!! Computation of Rise relative_difference failed. !!!\nCheck source data for columns listed above." exit() #Append Rise Values to Global Scatter Data Dictionary. print combined_scatter_data_labels[0][scatter_counter] scatter_data_dict[combined_scatter_data_labels[0][scatter_counter]] = [exp_rise_value,mod_rise_value,relative_difference] elif min_max == 'min': print "*** Compute Drop ***" temp_exp_data_values = [x for x in exp_data_values_comp if x != 'Null'] exp_drop_value = float(exp_initial_value) - min(temp_exp_data_values) temp_mod_data_values = [x for x in mod_data_values_comp if x != 'Null'] mod_drop_value = float(mod_initial_value) - min(temp_mod_data_values) print "Experimental Initial Value is:", exp_initial_value print "Experimental Drop Value is:", exp_drop_value print "Model Initial Value is:", mod_initial_value print "Model Drop Value is:", mod_drop_value print "\n*** Computing Drop Relative Difference ***" try: relative_difference = ((mod_drop_value-exp_drop_value)/exp_drop_value) print "Min Relative Difference is:", relative_difference except: print "!!! Computation of Min relative_difference failed. !!!\nCheck source data for columns listed above." exit() #Append Drop Values to Global Scatter Data Dictionary. scatter_data_dict[combined_scatter_data_labels[0][scatter_counter]] = [exp_drop_value,mod_drop_value,relative_difference] else: print "!!! Min or Max is undefined in the input file. !!!" exit() #Create data lists based on specified ranges exp_data_seconds = zip(exp_data_dict[exp_Xaxis_column_name][exp_comp_ranges[0]:exp_comp_ranges[1]], exp_data_dict[exp_label_temp[3]][exp_comp_ranges[0]:exp_comp_ranges[1]]) #print exp_data_seconds mod_data_seconds = zip(mod_data_dict[mod_Xaxis_column_name][mod_comp_ranges[0]:mod_comp_ranges[1]], mod_data_dict[mod_label_temp[3]][mod_comp_ranges[0]:mod_comp_ranges[1]]) #print mod_data_seconds #Convert time to minutes from seconds. exp_data.append([[x[0] / 60, x[1]] for x in exp_data_seconds]) #print exp_data mod_data.append([[x[0] / 60, x[1]] for x in mod_data_seconds]) #print mod_data #print "\nUpdating the Scatter Counter.\n" scatter_counter = scatter_counter + 1 # Close files exp_file_object.close() mod_file_object.close() return [exp_data,mod_data]
87973d23d22db6216de05fd97372ac9cd7fd65c3 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/12/87973d23d22db6216de05fd97372ac9cd7fd65c3/Validation_Data_Processor.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2608, 67, 2919, 67, 892, 12, 2919, 67, 768, 67, 1376, 4672, 7541, 2720, 316, 302, 980, 2065, 628, 642, 585, 471, 4389, 501, 628, 1084, 263, 6715, 1390, 18, 225, 1329, 67, 892, 273, 5378, 681, 67, 892, 273, 5378, 1329, 67, 892, 67, 1576, 273, 2618, 681, 67, 892, 67, 1576, 273, 2618, 1329, 67, 31320, 67, 892, 67, 5336, 273, 5378, 681, 67, 31320, 67, 892, 67, 5336, 273, 5378, 225, 468, 682, 434, 3152, 628, 1664, 585, 1057, 1257, 18, 225, 1329, 67, 892, 67, 3459, 273, 1161, 67, 768, 67, 1376, 3292, 2966, 67, 5359, 3546, 468, 780, 434, 1544, 1329, 67, 2827, 67, 529, 67, 492, 67, 1615, 273, 509, 12, 2919, 67, 768, 67, 1376, 3292, 2966, 67, 914, 67, 461, 67, 1999, 19486, 17, 21, 468, 22338, 287, 1910, 4753, 1770, 6556, 3588, 1329, 67, 892, 67, 492, 67, 1615, 273, 509, 12, 2919, 67, 768, 67, 1376, 3292, 2966, 67, 751, 67, 1999, 19486, 17, 21, 468, 22338, 287, 1910, 24591, 6556, 3588, 1329, 67, 1937, 67, 892, 67, 1125, 273, 1161, 67, 768, 67, 1376, 3292, 2966, 67, 1685, 67, 12, 1154, 18, 2506, 65, 468, 780, 316, 6824, 358, 787, 1329, 3207, 501, 1329, 67, 5681, 67, 892, 67, 1125, 273, 1161, 67, 768, 67, 1376, 3292, 2966, 67, 1638, 67, 12, 1154, 18, 2506, 65, 468, 780, 316, 6824, 358, 2132, 1329, 3207, 501, 1329, 67, 1937, 67, 2919, 67, 1125, 273, 1161, 67, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2608, 67, 2919, 67, 892, 12, 2919, 67, 768, 67, 1376, 4672, 7541, 2720, 316, 302, 980, 2065, 628, 642, 585, 471, 4389, 501, 628, 1084, 263, 6715, 1390, 18, 225, 1329, 67, 892, 273, 5378, 681, 67, 892, 273, 5378, 1329, 67, 892, 67, 1576, 273, 2618, 681, 67, 892, 67, 1576, 273, 2618, 1329, 67, 31320, 67, 892, 67, 5336, 273, 5378, 681, 67, 31320, 67, 892, 67, 5336, 273, 5378, 225, 468, 682, 434, 3152, 628, 1664, 585, 1057, 1257, 18, 225, 1329, 67, 892, 67, 3459, 273, 1161, 67, 768, 67, 1376, 3292, 2966, 67, 5359, 3546, 468, 780, 434, 1544, 1329, 67, 2827, 67, 529, 67, 492, 67, 1615, 273, 509, 12, 2919, 2 ]
wikipedia.output(e.message)
wikipedia.output(e)
def treat(self, page): try: oldText = page.get() for match in self.isbnR.finditer(oldText): code = match.group('code') try: getIsbn(code) except InvalidIsbnException, e: wikipedia.output(e.message)
21455d9df1f37faf79cf851734d7df4a4a94ce8a /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/4404/21455d9df1f37faf79cf851734d7df4a4a94ce8a/isbn.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 10116, 12, 2890, 16, 1363, 4672, 775, 30, 1592, 1528, 273, 1363, 18, 588, 1435, 364, 845, 316, 365, 18, 291, 13392, 54, 18, 4720, 2165, 12, 1673, 1528, 4672, 981, 273, 845, 18, 1655, 2668, 710, 6134, 775, 30, 14279, 13392, 12, 710, 13, 1335, 1962, 2520, 13392, 503, 16, 425, 30, 21137, 18, 2844, 12, 73, 18, 2150, 13, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 10116, 12, 2890, 16, 1363, 4672, 775, 30, 1592, 1528, 273, 1363, 18, 588, 1435, 364, 845, 316, 365, 18, 291, 13392, 54, 18, 4720, 2165, 12, 1673, 1528, 4672, 981, 273, 845, 18, 1655, 2668, 710, 6134, 775, 30, 14279, 13392, 12, 710, 13, 1335, 1962, 2520, 13392, 503, 16, 425, 30, 21137, 18, 2844, 12, 73, 18, 2150, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
return self.pool.get("res.partner.bank").browse(cr,uid,bid)
return self.pool.get("res.partner.bank").browse(self.cr,self.uid,bid)
def _bank_get(self, bid): return self.pool.get("res.partner.bank").browse(cr,uid,bid)
ad1032e992df2270077592ddb081acb2b4e6cdcd /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/7397/ad1032e992df2270077592ddb081acb2b4e6cdcd/bvr.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 10546, 67, 588, 12, 2890, 16, 9949, 4672, 327, 365, 18, 6011, 18, 588, 2932, 455, 18, 31993, 18, 10546, 20387, 25731, 12, 3353, 16, 1911, 16, 19773, 13, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 10546, 67, 588, 12, 2890, 16, 9949, 4672, 327, 365, 18, 6011, 18, 588, 2932, 455, 18, 31993, 18, 10546, 20387, 25731, 12, 3353, 16, 1911, 16, 19773, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
kupu_tool.deleteResourceTypes([COMPOSABLE]) out.write("Composable Resource deleted in Kupu Library Tool")
try: kupu_tool.deleteResourceTypes([COMPOSABLE]) out.write("Composable Resource deleted in Kupu Library Tool") except KeyError: pass
def uninstall_kupu_resource(self, out): if hasattr(self, KUPU_TOOL_ID): kupu_tool = getattr(self, KUPU_TOOL_ID) kupu_tool.deleteResourceTypes([COMPOSABLE]) out.write("Composable Resource deleted in Kupu Library Tool") else: out.write("Kupu Library Tool not available")
ea182cd2e1484471730629e4b4e4000ce4ac18ca /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/1807/ea182cd2e1484471730629e4b4e4000ce4ac18ca/Install.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 16577, 67, 79, 416, 89, 67, 3146, 12, 2890, 16, 596, 4672, 309, 3859, 12, 2890, 16, 1475, 3079, 57, 67, 26263, 67, 734, 4672, 417, 416, 89, 67, 6738, 273, 3869, 12, 2890, 16, 1475, 3079, 57, 67, 26263, 67, 734, 13, 775, 30, 417, 416, 89, 67, 6738, 18, 3733, 1420, 2016, 3816, 4208, 7057, 2782, 5717, 596, 18, 2626, 2932, 799, 23252, 2591, 4282, 316, 1475, 416, 89, 18694, 13288, 7923, 1335, 4999, 30, 1342, 469, 30, 596, 18, 2626, 2932, 47, 416, 89, 18694, 13288, 486, 2319, 7923, 225, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 16577, 67, 79, 416, 89, 67, 3146, 12, 2890, 16, 596, 4672, 309, 3859, 12, 2890, 16, 1475, 3079, 57, 67, 26263, 67, 734, 4672, 417, 416, 89, 67, 6738, 273, 3869, 12, 2890, 16, 1475, 3079, 57, 67, 26263, 67, 734, 13, 775, 30, 417, 416, 89, 67, 6738, 18, 3733, 1420, 2016, 3816, 4208, 7057, 2782, 5717, 596, 18, 2626, 2932, 799, 23252, 2591, 4282, 316, 1475, 416, 89, 18694, 13288, 7923, 1335, 4999, 30, 1342, 469, 30, 596, 18, 2626, 2932, 47, 416, 89, 18694, 13288, 486, 2319, 7923, 225, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
if not os.path.isdir(directory): os.mkdir(directory)
if os.path.isdir(directory): shutil.rmtree(directory, True) os.makedirs(directory)
def createBertosProject(project_info): directory = project_info.info("PROJECT_PATH") sources_dir = project_info.info("SOURCES_PATH") if not os.path.isdir(directory): os.mkdir(directory) f = open(directory + "/project.bertos", "w") f.write(pickle.dumps(project_info)) f.close() # Destination source dir srcdir = directory + "/bertos" shutil.rmtree(srcdir, True) copytree.copytree(sources_dir + "/bertos", srcdir, ignore_list=const.IGNORE_LIST) # Destination makefile makefile = directory + "/Makefile" if os.path.exists(makefile): os.remove(makefile) makefile = open("mktemplates/Makefile").read() makefile = makefileGenerator(project_info, makefile) open(directory + "/Makefile", "w").write(makefile) # Destination project dir prjdir = directory + "/" + os.path.basename(directory) shutil.rmtree(prjdir, True) os.mkdir(prjdir) # Destination hw files hwdir = prjdir + "/hw" shutil.rmtree(hwdir, True) os.mkdir(hwdir) # Copy all the hw files for module, information in project_info.info("MODULES").items(): for hwfile in information["hw"]: string = open(sources_dir + "/" + hwfile, "r").read() open(hwdir + "/" + os.path.basename(hwfile), "w").write(string) # Destination configurations files cfgdir = prjdir + "/cfg" shutil.rmtree(cfgdir, True) os.mkdir(cfgdir) # Set to 1 the autoenabled for enabled modules for module, information in project_info.info("MODULES").items(): if information["enabled"] and "configuration" in information and information["configuration"] != "": configurations = project_info.info("CONFIGURATIONS") configuration = configurations[information["configuration"]] for start, parameter in configuration["paramlist"]: if "type" in configuration[parameter]["informations"] and configuration[parameter]["informations"]["type"] == "autoenabled": configuration[parameter]["value"] = "1" project_info.setInfo("CONFIGURATIONS", configurations) # Copy all the configuration files for configuration, information in project_info.info("CONFIGURATIONS").items(): string = open(sources_dir + "/" + configuration, "r").read() for start, parameter in information["paramlist"]: infos = information[parameter] value = infos["value"] if "unsigned" in infos["informations"] and infos["informations"]["unsigned"]: value += "U" if "long" in infos["informations"] and infos["informations"]["long"]: value += "L" string = sub(string, parameter, value) f = open(cfgdir + "/" + os.path.basename(configuration), "w") f.write(string) f.close() # Destinatio mk file makefile = open("mktemplates/template.mk", "r").read() makefile = mkGenerator(project_info, makefile) open(prjdir + "/" + os.path.basename(prjdir) + ".mk", "w").write(makefile) # Destination main.c file main = open("srctemplates/main.c", "r").read() open(prjdir + "/main.c", "w").write(main) # Files for selected plugins relevants_files = {} for plugin in project_info.info("OUTPUT"): module = loadPlugin(plugin) relevants_files[plugin] = module.createProject(project_info) project_info.setInfo("RELEVANT_FILES", relevants_files)
5bd2e00f5d77f8354649b1a8c434de9cf44b7d25 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9114/5bd2e00f5d77f8354649b1a8c434de9cf44b7d25/bertos_utils.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 752, 38, 1051, 538, 4109, 12, 4406, 67, 1376, 4672, 1867, 273, 1984, 67, 1376, 18, 1376, 2932, 17147, 67, 4211, 7923, 5550, 67, 1214, 273, 1984, 67, 1376, 18, 1376, 2932, 6537, 55, 67, 4211, 7923, 309, 1140, 18, 803, 18, 291, 1214, 12, 5149, 4672, 11060, 18, 86, 17371, 12, 5149, 16, 1053, 13, 1140, 18, 81, 9477, 10539, 12, 5149, 13, 284, 273, 1696, 12, 5149, 397, 2206, 4406, 18, 744, 14627, 3113, 315, 91, 7923, 284, 18, 2626, 12, 20847, 18, 13302, 1121, 12, 4406, 67, 1376, 3719, 284, 18, 4412, 1435, 468, 10691, 1084, 1577, 1705, 1214, 273, 1867, 397, 2206, 744, 14627, 6, 11060, 18, 86, 17371, 12, 4816, 1214, 16, 1053, 13, 1610, 3413, 18, 3530, 3413, 12, 10141, 67, 1214, 397, 2206, 744, 14627, 3113, 1705, 1214, 16, 2305, 67, 1098, 33, 10248, 18, 20118, 67, 7085, 13, 468, 10691, 1221, 768, 1221, 768, 273, 1867, 397, 2206, 6464, 768, 6, 309, 1140, 18, 803, 18, 1808, 12, 6540, 768, 4672, 1140, 18, 4479, 12, 6540, 768, 13, 1221, 768, 273, 1696, 2932, 24816, 8502, 19, 6464, 768, 20387, 896, 1435, 1221, 768, 273, 1221, 768, 3908, 12, 4406, 67, 1376, 16, 1221, 768, 13, 1696, 12, 5149, 397, 2206, 6464, 768, 3113, 315, 91, 20387, 2626, 12, 6540, 768, 13, 468, 10691, 1984, 1577, 27378, 1214, 273, 1867, 397, 4016, 397, 1140, 18, 803, 18, 13909, 12, 5149, 13, 11060, 18, 86, 17371, 12, 683, 78, 1214, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 752, 38, 1051, 538, 4109, 12, 4406, 67, 1376, 4672, 1867, 273, 1984, 67, 1376, 18, 1376, 2932, 17147, 67, 4211, 7923, 5550, 67, 1214, 273, 1984, 67, 1376, 18, 1376, 2932, 6537, 55, 67, 4211, 7923, 309, 1140, 18, 803, 18, 291, 1214, 12, 5149, 4672, 11060, 18, 86, 17371, 12, 5149, 16, 1053, 13, 1140, 18, 81, 9477, 10539, 12, 5149, 13, 284, 273, 1696, 12, 5149, 397, 2206, 4406, 18, 744, 14627, 3113, 315, 91, 7923, 284, 18, 2626, 12, 20847, 18, 13302, 1121, 12, 4406, 67, 1376, 3719, 284, 18, 4412, 1435, 468, 10691, 1084, 1577, 1705, 1214, 273, 1867, 397, 2206, 744, 14627, 6, 11060, 18, 86, 17371, 12, 4816, 1214, 16, 1053, 2 ]
""" if name[0] != 'X' or not name in self.capabilities: raise self.error('unknown extension command: %s' % name)
Returns response appropriate to extension command `name'. """ name = name.upper() if not Commands.has_key(name): Commands[name] = (self.state,)
def xatom(self, name, *args): """Allow simple extension commands notified by server in CAPABILITY response.
ed860500914c98bc53bdadf292c180ffad9bec09 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8125/ed860500914c98bc53bdadf292c180ffad9bec09/imaplib.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 619, 7466, 12, 2890, 16, 508, 16, 380, 1968, 4672, 3536, 7009, 4143, 2710, 4364, 18791, 635, 1438, 316, 29720, 22879, 766, 18, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 619, 7466, 12, 2890, 16, 508, 16, 380, 1968, 4672, 3536, 7009, 4143, 2710, 4364, 18791, 635, 1438, 316, 29720, 22879, 766, 18, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
(self._bymonthday and ii.mdaymask[i] not in self._bymonthday) or (self._byweekday and ii.wdaymask[i] not in self._byweekday) or
(self._byweekday and ii.wdaymask[i] not in self._byweekday) or
def _iter(self): year, month, day, hour, minute, second, weekday, yearday, _ = \ self._dtstart.timetuple()
b3c88411265904f5f13de2fe4210eefdaea843f5 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8441/b3c88411265904f5f13de2fe4210eefdaea843f5/rrule.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 2165, 12, 2890, 4672, 3286, 16, 3138, 16, 2548, 16, 6126, 16, 8044, 16, 2205, 16, 7560, 16, 677, 73, 1060, 528, 16, 389, 273, 521, 365, 6315, 7510, 1937, 18, 8584, 278, 2268, 1435, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 2165, 12, 2890, 4672, 3286, 16, 3138, 16, 2548, 16, 6126, 16, 8044, 16, 2205, 16, 7560, 16, 677, 73, 1060, 528, 16, 389, 273, 521, 365, 6315, 7510, 1937, 18, 8584, 278, 2268, 1435, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
if auth_code and user_info['email'] == 'guest' and not user_info['apache_user']:
if auth_code:
def __call__(self, req, form): """ Perform a search. """ argd = wash_search_urlargd(form)
19aa8278e54f656b5935dcde0aca0276789f8fe4 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/12027/19aa8278e54f656b5935dcde0aca0276789f8fe4/websearch_webinterface.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 1991, 972, 12, 2890, 16, 1111, 16, 646, 4672, 3536, 11217, 279, 1623, 18, 3536, 1501, 72, 273, 341, 961, 67, 3072, 67, 718, 3175, 72, 12, 687, 13, 2, 0, 0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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 1991, 972, 12, 2890, 16, 1111, 16, 646, 4672, 3536, 11217, 279, 1623, 18, 3536, 1501, 72, 273, 341, 961, 67, 3072, 67, 718, 3175, 72, 12, 687, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
print _('You must specify an id')
print >>sys.stderr, _('You must specify an id')
def command_show_metadata(args, dbpath): parser = get_parser(_(
aab8744748b031f43fe9148ccb2cdc2e9db72d82 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/9125/aab8744748b031f43fe9148ccb2cdc2e9db72d82/cli.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1296, 67, 4500, 67, 4165, 12, 1968, 16, 1319, 803, 4672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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1296, 67, 4500, 67, 4165, 12, 1968, 16, 1319, 803, 4672, 2082, 273, 336, 67, 4288, 24899, 12, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
For `Ooc`<http://ooc-lang.org/>_ source code
For `Ooc <http://ooc-lang.org/>`_ source code
# ``cdef foo from "header"``, or ``for foo from 0 < i < 10``
e90acdda0abc938e1808f67b91c2aa64dd3e18b5 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/6148/e90acdda0abc938e1808f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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 468, 12176, 71, 536, 8431, 628, 315, 3374, 8366, 9191, 578, 12176, 1884, 8431, 628, 374, 411, 277, 411, 1728, 10335, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
if widget is self.pres and (self._background or self._black or self._logo) or not slide:
if widget is self.pres and (self._background or self._black or self._logo) \ or not slide:
def _draw(self, widget): 'Render `widget`.' if not widget.window or not widget.window.is_viewable(): return False ccontext = widget.window.cairo_create() screenW, screenH = widget.window.get_size() if widget is self.preview and self.pres.window and self.pres.window.is_viewable(): #Scale if the presentation window size is available win_sz = self.pres.window.get_size() width = int(float(preview_height)*win_sz[0]/win_sz[1]) screenW = screenW*win_sz[0]/width screenH = screenH*win_sz[1]/preview_height ccontext.scale(float(width)/win_sz[0], float(preview_height)/win_sz[1]) elif widget is self.pres: self.preview.queue_draw() slide = exposong.slidelist.slidelist.get_active_item() if widget is self.pres and (self._background or self._black or self._logo) or not slide: #When there's no text to render, just draw the background self._set_background(widget, ccontext, (screenW, screenH)) else: if slide.draw(widget) is not NotImplemented: return True self._set_background(widget, ccontext, (screenW, screenH)) txcol = c2dec(exposong.prefs.config['pres.text_color']) screenCenterY = screenH/2 # Header text # TODO # Footer text ftext = str(slide.footer_text()) if isinstance(ftext, (unicode, str)) and len(ftext): layout = ccontext.create_layout() layout.set_text(ftext) layout.set_alignment(pango.ALIGN_CENTER) layout.set_width(int(screenW*pango.SCALE * 0.97)) attrs = pango.AttrList() attrs.insert(pango.AttrFontDesc(pango.FontDescription("Sans Bold "+str(int(screenH/54.0))), end_index = len(ftext)+40)) layout.set_attributes(attrs) footer_height = layout.get_pixel_size()[1] ccontext.set_source_rgba(txcol[0], txcol[1], txcol[2], 1.0) ccontext.move_to(screenW * 0.015, screenH - footer_height) ccontext.show_layout(layout) screenH -= footer_height screenCenterY -= footer_height/2 # Body Text layout = ccontext.create_layout() size = 16 layout.set_text(str(slide.body_text())) layout.set_alignment(pango.ALIGN_CENTER) layout.set_width(int(screenW*pango.SCALE * 0.97)) attrs = pango.AttrList() attrs.insert(pango.AttrFontDesc(pango.FontDescription("Sans Bold "+str(size)), end_index = len(str(slide.body_text())))) layout.set_attributes(attrs) min_sz = 0 max_sz = int(exposong.prefs.config['pres.max_font_size']) #Loop through until the text is between 78% of the height and 94%, or #until we get a number that is not a multiple of 4 (2,6,10,14, etc) to #make it simpler... TODO Double check that it doesn't overflow while True: if layout.get_pixel_size()[0] > screenW*0.97 \ or layout.get_pixel_size()[1] > screenH*0.94: max_sz = size size = (min_sz + max_sz) / 2 elif size % 4 != 0 or max_sz - min_sz < 3: break elif layout.get_pixel_size()[1] < screenH*0.78: min_sz = size if(max_sz): size = (min_sz + max_sz) / 2 else: size = size * 2 else: break attrs.insert(pango.AttrFontDesc(pango.FontDescription("Sans Bold "+str(size)), end_index = len(slide.body_text()))) layout.set_attributes(attrs) if exposong.prefs.config['pres.text_shadow']: shcol = c2dec(exposong.prefs.config['pres.text_shadow']) ccontext.set_source_rgba(shcol[0], shcol[1], shcol[2], shcol[3]) ccontext.move_to(screenW * 0.015 + size*0.1, screenCenterY - layout.get_pixel_size()[1]/2.0 + size*0.1) ccontext.show_layout(layout) ccontext.set_source_rgba(txcol[0], txcol[1], txcol[2], 1.0) ccontext.move_to(screenW * 0.015,screenCenterY - layout.get_pixel_size()[1]/2.0) ccontext.show_layout(layout) #Draw notification if widget is self.pres and self._notification: layout = ccontext.create_layout() layout.set_text(self._notification) attrs = pango.AttrList() notify_sz = int(screenH/12.0) attrs.insert(pango.AttrFontDesc(pango.FontDescription("Sans Bold "+str(notify_sz)), end_index = len(self._notification)+40)) layout.set_attributes(attrs) while layout.get_pixel_size()[0] > screenW*0.6: notify_sz = int(notify_sz*0.89) attrs.insert(pango.AttrFontDesc(pango.FontDescription("Sans Bold "+str(notify_sz)), end_index = len(slide.body_text())+40)) layout.set_attributes(attrs) sbounds = widget.window.get_size() nbounds = layout.get_pixel_size() pad = notify_sz/14.0 ccontext.rectangle(sbounds[0]-nbounds[0]-pad*2, sbounds[1]-nbounds[1]-pad*2, sbounds[0], sbounds[1]) ccontext.set_source_rgb(exposong.prefs.config['pres.notify_bg'][0], exposong.prefs.config['pres.notify_bg'][1], exposong.prefs.config['pres.notify_bg'][2]) ccontext.fill() ccontext.set_source_rgb(1.0, 1.0, 1.0) ccontext.move_to(sbounds[0]-nbounds[0]-pad, sbounds[1]-nbounds[1]-pad) ccontext.show_layout(layout) return True
8c3f40684164811288ce61ed77b3443a149b13bb /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/5029/8c3f40684164811288ce61ed77b3443a149b13bb/screen.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 9446, 12, 2890, 16, 3604, 4672, 296, 3420, 1375, 6587, 68, 1093, 309, 486, 3604, 18, 5668, 578, 486, 3604, 18, 5668, 18, 291, 67, 1945, 429, 13332, 327, 1083, 225, 276, 2472, 273, 3604, 18, 5668, 18, 5353, 11373, 67, 2640, 1435, 5518, 59, 16, 5518, 44, 273, 3604, 18, 5668, 18, 588, 67, 1467, 1435, 309, 3604, 353, 365, 18, 12102, 471, 365, 18, 12202, 18, 5668, 471, 365, 18, 12202, 18, 5668, 18, 291, 67, 1945, 429, 13332, 468, 5587, 309, 326, 22525, 2742, 963, 353, 2319, 5657, 67, 24575, 273, 365, 18, 12202, 18, 5668, 18, 588, 67, 1467, 1435, 1835, 273, 509, 12, 5659, 12, 12102, 67, 4210, 17653, 8082, 67, 24575, 63, 20, 18537, 8082, 67, 24575, 63, 21, 5717, 5518, 59, 273, 5518, 59, 14, 8082, 67, 24575, 63, 20, 18537, 2819, 5518, 44, 273, 5518, 44, 14, 8082, 67, 24575, 63, 21, 18537, 12102, 67, 4210, 276, 2472, 18, 5864, 12, 5659, 12, 2819, 13176, 8082, 67, 24575, 63, 20, 6487, 1431, 12, 12102, 67, 4210, 13176, 8082, 67, 24575, 63, 21, 5717, 1327, 3604, 353, 365, 18, 12202, 30, 365, 18, 12102, 18, 4000, 67, 9446, 1435, 225, 12701, 273, 431, 917, 932, 18, 2069, 350, 5449, 18, 2069, 350, 5449, 18, 588, 67, 3535, 67, 1726, 1435, 225, 309, 3604, 353, 365, 18, 12202, 471, 261, 2890, 6315, 9342, 578, 365, 6315, 11223, 578, 365, 6315, 19882, 13, 521, 578, 486, 12701, 30, 468, 9434, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 9446, 12, 2890, 16, 3604, 4672, 296, 3420, 1375, 6587, 68, 1093, 309, 486, 3604, 18, 5668, 578, 486, 3604, 18, 5668, 18, 291, 67, 1945, 429, 13332, 327, 1083, 225, 276, 2472, 273, 3604, 18, 5668, 18, 5353, 11373, 67, 2640, 1435, 5518, 59, 16, 5518, 44, 273, 3604, 18, 5668, 18, 588, 67, 1467, 1435, 309, 3604, 353, 365, 18, 12102, 471, 365, 18, 12202, 18, 5668, 471, 365, 18, 12202, 18, 5668, 18, 291, 67, 1945, 429, 13332, 468, 5587, 309, 326, 22525, 2742, 963, 353, 2319, 5657, 67, 24575, 273, 365, 18, 12202, 18, 5668, 18, 588, 67, 1467, 1435, 1835, 273, 509, 12, 5659, 12, 12102, 67, 4210, 17653, 8082, 67, 24575, 2 ]
if line['partner_id'] == 0: nb_err+=1 err_log += '\nThe bank account %s is not defined for the partner %s.'%(cntry_number,contry_name)
def _coda_parsing(self, cr, uid, data, context): pool = pooler.get_pool(cr.dbname) codafile = data['form']['coda'] jur_id = data['form']['journal_id'] def_pay_acc = data['form']['def_payable'] def_rec_acc = data['form']['def_receivable'] str_log = "" err_log = "Errors:\n------\n" nb_err=0 std_log='' str_log1 = "Coda File is Imported : " str_not='' str_not1='' bank_statement={} bank_statement_lines={} bank_statements=[] recordlist = base64.decodestring(codafile).split('\n')#remove \r by dhaval recordlist.pop() for line in recordlist: if line[0] == '0': # header data bank_statement["bank_statement_line"]={} bank_statement['date'] = str2date(line[5:11]) bank_statement['journal_id']=data['form']['journal_id'] period_id = pool.get('account.period').search(cr,uid,[('date_start','<=',time.strftime('%Y-%m-%d',time.strptime(bank_statement['date'],"%y/%m/%d"))),('date_stop','>=',time.strftime('%Y-%m-%d',time.strptime(bank_statement['date'],"%y/%m/%d")))]) bank_statement['period_id'] = period_id[0] bank_statement['state']='draft' elif line[0] == '1': # old balance data bal_start = list2float(line[43:58]) if line[42] == '1': bal_start = - bal_start bank_statement["balance_start"]= bal_start bank_statement["acc_number"]=line[5:17] bank_statement["acc_holder"]=line[64:90] elif line[0]=='2': # movement data record 2 if line[1]=='1': # movement data record 2.1 if bank_statement_lines.has_key(line[2:6]): continue st_line = {} st_line['extra_note'] = '' st_line['statement_id']=0 st_line['ref'] = line[2:10] st_line['date'] = time.strftime('%Y-%m-%d',time.strptime(str2date(line[115:121]),"%y/%m/%d")), st_line_amt = list2float(line[32:47]) if line[61]=='1': st_line['name']=line[65:77] else: st_line['name']=line[62:115] st_line['free_comm'] = st_line['name'] st_line['val_date']=time.strftime('%Y-%m-%d',time.strptime(str2date(line[47:53]),"%y/%m/%d")), st_line['entry_date']=time.strftime('%Y-%m-%d',time.strptime(str2date(line[115:121]),"%y/%m/%d")), st_line['partner_id']=0 if line[31] == '1': st_line_amt = - st_line_amt st_line['account_id'] = def_pay_acc else: st_line['account_id'] = def_rec_acc st_line['amount'] = st_line_amt bank_statement_lines[line[2:6]]=st_line bank_statement["bank_statement_line"]=bank_statement_lines elif line[1] == '2': st_line_name = line[2:6] bank_statement_lines[st_line_name].update({'account_id': data['form']['awaiting_account']}) elif line[1] == '3': # movement data record 3.1 st_line_name = line[2:6] st_line_partner_acc = str(line[10:47]).strip() cntry_number=line[10:47].strip() contry_name=line[47:125].strip() bank_ids = pool.get('res.partner.bank').search(cr,uid,[('acc_number','=',st_line_partner_acc)]) bank_statement_lines[st_line_name].update({'cntry_number': cntry_number, 'contry_name': contry_name}) if bank_ids: bank = pool.get('res.partner.bank').browse(cr,uid,bank_ids[0],context) if line and bank.partner_id: bank_statement_lines[st_line_name].update({'partner_id': bank.partner_id.id}) if bank_statement_lines[st_line_name]['amount'] < 0 : bank_statement_lines[st_line_name].update({'account_id': bank.partner_id.property_account_payable.id}) else : bank_statement_lines[st_line_name].update({'account_id': bank.partner_id.property_account_receivable.id}) else: nb_err += 1 err_log += _('The bank account %s is not defined for the partner %s.\n')%(cntry_number,contry_name) bank_statement_lines[st_line_name].update({'account_id': data['form']['awaiting_account']}) bank_statement["bank_statement_line"]=bank_statement_lines elif line[0]=='3': if line[1] == '1': st_line_name = line[2:6] bank_statement_lines[st_line_name]['extra_note'] += line[40:113] elif line[1] == '2': st_line_name = line[2:6] bank_statement_lines[st_line_name]['extra_note'] += line[10:115] elif line[1] == '3': st_line_name = line[2:6] bank_statement_lines[st_line_name]['extra_note'] += line[10:100] elif line[0]=='8': # new balance record bal_end = list2float(line[42:57]) if line[41] == '1': bal_end = - bal_end bank_statement["balance_end_real"]= bal_end elif line[0]=='9': # footer record bank_statements.append(bank_statement) #end for bkst_list=[] for statement in bank_statements: try: bk_st_id = pool.get('account.bank.statement').create(cr,uid,{ 'journal_id': statement['journal_id'], 'date':time.strftime('%Y-%m-%d',time.strptime(statement['date'],"%y/%m/%d")), 'period_id':statement['period_id'], 'balance_start': statement["balance_start"], 'balance_end_real': statement["balance_end_real"], 'state':'draft', }) lines=statement["bank_statement_line"] for value in lines: line=lines[value] reconcile_id = False rec_id = pool.get('account.move.line').search(cr, uid, [('name','=',line['name']),('account_id.reconcile','=',True)]) if rec_id: reconcile_id = pool.get('account.bank.statement.reconcile').create(cr, uid, { 'line_ids': [(6, 0, rec_id)] }, context=context) str_not1 = '' if line['partner_id'] == 0: nb_err+=1 err_log += '\nThe bank account %s is not defined for the partner %s.'%(cntry_number,contry_name) if line.has_key('contry_name') and line.has_key('cntry_number'): str_not1="Partner name:%s \n Partner Account Number:%s \n Communication:%s \n Value Date:%s \n Entry Date:%s \n"%(line["contry_name"],line["cntry_number"],line["free_comm"]+line['extra_note'],line["val_date"][0],line["entry_date"][0]) id=pool.get('account.bank.statement.line').create(cr,uid,{ 'name':line['name'], 'date': line['date'], 'amount': line['amount'], 'partner_id':line['partner_id'] or 0, 'account_id':line['account_id'], 'statement_id': bk_st_id, 'reconcile_id': reconcile_id, 'note':str_not1, 'ref':line['ref'], }) cr.commit() str_not= "\n \n Account Number: %s \n Account Holder Name: %s " %(statement["acc_number"],statement["acc_holder"]) std_log = std_log + "\nDate : %s, Starting Balance : %.2f , Ending Balance : %.2f \n"\ %(statement['date'], float(statement["balance_start"]), float(statement["balance_end_real"])) bkst_list.append(bk_st_id) except osv.except_osv, e: cr.rollback() nb_err+=1 err_log= err_log +'\n Application Error : ' + str(e) raise # REMOVEME except Exception, e: cr.rollback() nb_err+=1 err_log= err_log +'\n System Error : '+str(e) raise # REMOVEME except : cr.rollback() nb_err+=1 err_log= err_log +'\n Unknown Error' raise err_log= err_log + '\n\nNumber of statements : '+ str(len([bkst_list])) err_log= err_log + '\nNumber of error :'+ str(nb_err) +'\n' pool.get('account.coda').create(cr, uid,{ 'name':codafile, 'statement_id':bk_st_id, 'note':str_log1+str_not+std_log+err_log, 'journal_id':data['form']['journal_id'], 'date':time.strftime("%Y-%m-%d"), 'user_id':uid, }) return {'note':str_log1 + std_log + err_log ,'journal_id': data['form']['journal_id'], 'coda': data['form']['coda'],'statment_id':bk_st_id}
2b8aba5dfb833d1f9a101218c2280e6361bd57e2 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7339/2b8aba5dfb833d1f9a101218c2280e6361bd57e2/coda_import.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 1559, 69, 67, 24979, 12, 2890, 16, 4422, 16, 4555, 16, 501, 16, 819, 4672, 2845, 273, 2845, 264, 18, 588, 67, 6011, 12, 3353, 18, 20979, 13, 11012, 69, 768, 273, 501, 3292, 687, 21712, 1559, 69, 3546, 525, 295, 67, 350, 273, 501, 3292, 687, 21712, 22644, 67, 350, 3546, 1652, 67, 10239, 67, 8981, 273, 501, 3292, 687, 21712, 536, 67, 10239, 429, 3546, 1652, 67, 3927, 67, 8981, 273, 501, 3292, 687, 21712, 536, 67, 8606, 427, 429, 3546, 225, 609, 67, 1330, 273, 1408, 393, 67, 1330, 273, 315, 4229, 5581, 82, 13093, 64, 82, 6, 4264, 67, 370, 33, 20, 2044, 67, 1330, 2218, 11, 609, 67, 1330, 21, 273, 315, 39, 21319, 1387, 353, 2221, 1798, 225, 294, 225, 315, 609, 67, 902, 2218, 11, 609, 67, 902, 21, 2218, 11, 225, 11218, 67, 11516, 12938, 11218, 67, 11516, 67, 3548, 12938, 11218, 67, 18393, 33, 8526, 1409, 1098, 273, 1026, 1105, 18, 4924, 1145, 371, 12, 1559, 69, 768, 2934, 4939, 2668, 64, 82, 6134, 7, 4479, 521, 86, 635, 11007, 842, 287, 1409, 1098, 18, 5120, 1435, 364, 980, 316, 1409, 1098, 30, 309, 980, 63, 20, 65, 422, 296, 20, 4278, 468, 1446, 501, 11218, 67, 11516, 9614, 10546, 67, 11516, 67, 1369, 11929, 12938, 11218, 67, 11516, 3292, 712, 3546, 273, 609, 22, 712, 12, 1369, 63, 25, 30, 2499, 5717, 11218, 67, 11516, 3292, 22644, 67, 350, 3546, 33, 892, 3292, 687, 21712, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 1559, 69, 67, 24979, 12, 2890, 16, 4422, 16, 4555, 16, 501, 16, 819, 4672, 2845, 273, 2845, 264, 18, 588, 67, 6011, 12, 3353, 18, 20979, 13, 11012, 69, 768, 273, 501, 3292, 687, 21712, 1559, 69, 3546, 525, 295, 67, 350, 273, 501, 3292, 687, 21712, 22644, 67, 350, 3546, 1652, 67, 10239, 67, 8981, 273, 501, 3292, 687, 21712, 536, 67, 10239, 429, 3546, 1652, 67, 3927, 67, 8981, 273, 501, 3292, 687, 21712, 536, 67, 8606, 427, 429, 3546, 225, 609, 67, 1330, 273, 1408, 393, 67, 1330, 273, 315, 4229, 5581, 82, 13093, 64, 82, 6, 4264, 67, 370, 33, 20, 2044, 67, 1330, 2218, 11, 609, 67, 1330, 21, 273, 315, 2 ]
if self.ceParameters.has_key('AdminCommands'): commands = self.ceParameters['AdminCommands'].split(';')
if self.ceParameters.has_key( 'AdminCommands' ): commands = self.ceParameters['AdminCommands'].split( ';' )
def submitJob(self,executableFile,jdl,proxy,localID): """ Method to submit job, should be overridden in sub-class. """
05f4284330e23d8d74d0844cee3520964f66a942 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12864/05f4284330e23d8d74d0844cee3520964f66a942/TorqueComputingElement.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4879, 2278, 12, 2890, 16, 17751, 812, 16, 78, 5761, 16, 5656, 16, 3729, 734, 4672, 3536, 2985, 358, 4879, 1719, 16, 1410, 506, 11000, 316, 720, 17, 1106, 18, 3536, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4879, 2278, 12, 2890, 16, 17751, 812, 16, 78, 5761, 16, 5656, 16, 3729, 734, 4672, 3536, 2985, 358, 4879, 1719, 16, 1410, 506, 11000, 316, 720, 17, 1106, 18, 3536, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]
out(' <p class="varlist">' '<span class="varlist-header">Inherited ' 'from <code>%s</code></span>:\n' %
out(' <p class="indent-wrapped-lines">' '<b>Inherited from <code>%s</code></b>:\n' %
def write_inheritance_list(self, out, doc, listed_inh_vars): out(' <tr>\n <td colspan="2" class="summary">\n') for base in doc.mro(): if base not in listed_inh_vars: continue public_vars = [v for v in listed_inh_vars[base] if v.is_public] private_vars = [v for v in listed_inh_vars[base] if not v.is_public] if public_vars: out(' <p class="varlist">' '<span class="varlist-header">Inherited ' 'from <code>%s</code></span>:\n' % self.href(base, context=doc)) self.write_var_list(out, public_vars) out(' </p>\n') if private_vars and self._show_private: out(' <div class="private">') out(' <p class="varlist">' '<span class="varlist-header">Inherited ' 'from <code>%s</code></span> (private):\n' % self.href(base, context=doc)) self.write_var_list(out, private_vars) out(' </p></div>\n') out(' </td>\n </tr>\n')
ead96d86090e18fdeec64a06319b925d20efd2b2 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/11420/ead96d86090e18fdeec64a06319b925d20efd2b2/html.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1045, 67, 6018, 1359, 67, 1098, 12, 2890, 16, 596, 16, 997, 16, 12889, 67, 267, 76, 67, 4699, 4672, 596, 2668, 225, 411, 313, 5333, 82, 565, 411, 4465, 20856, 1546, 22, 6, 667, 1546, 7687, 6, 5333, 82, 6134, 364, 1026, 316, 997, 18, 81, 303, 13332, 309, 1026, 486, 316, 12889, 67, 267, 76, 67, 4699, 30, 1324, 1071, 67, 4699, 273, 306, 90, 364, 331, 316, 12889, 67, 267, 76, 67, 4699, 63, 1969, 65, 309, 331, 18, 291, 67, 482, 65, 3238, 67, 4699, 273, 306, 90, 364, 331, 316, 12889, 67, 267, 76, 67, 4699, 63, 1969, 65, 309, 486, 331, 18, 291, 67, 482, 65, 309, 1071, 67, 4699, 30, 596, 2668, 565, 411, 84, 667, 1546, 9355, 17, 18704, 17, 3548, 7918, 2368, 70, 34, 29078, 628, 411, 710, 9822, 87, 1757, 710, 4695, 70, 34, 5581, 82, 11, 738, 365, 18, 7547, 12, 1969, 16, 819, 33, 2434, 3719, 365, 18, 2626, 67, 1401, 67, 1098, 12, 659, 16, 1071, 67, 4699, 13, 596, 2668, 1377, 7765, 84, 5333, 82, 6134, 309, 3238, 67, 4699, 471, 365, 6315, 4500, 67, 1152, 30, 596, 2668, 565, 411, 2892, 667, 1546, 1152, 7918, 13, 596, 2668, 565, 411, 84, 667, 1546, 1401, 1098, 7918, 2368, 3969, 667, 1546, 1401, 1098, 17, 3374, 6441, 29078, 296, 296, 2080, 411, 710, 9822, 87, 1757, 710, 4695, 3969, 34, 261, 1152, 4672, 64, 82, 11, 738, 365, 18, 7547, 12, 1969, 16, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1045, 67, 6018, 1359, 67, 1098, 12, 2890, 16, 596, 16, 997, 16, 12889, 67, 267, 76, 67, 4699, 4672, 596, 2668, 225, 411, 313, 5333, 82, 565, 411, 4465, 20856, 1546, 22, 6, 667, 1546, 7687, 6, 5333, 82, 6134, 364, 1026, 316, 997, 18, 81, 303, 13332, 309, 1026, 486, 316, 12889, 67, 267, 76, 67, 4699, 30, 1324, 1071, 67, 4699, 273, 306, 90, 364, 331, 316, 12889, 67, 267, 76, 67, 4699, 63, 1969, 65, 309, 331, 18, 291, 67, 482, 65, 3238, 67, 4699, 273, 306, 90, 364, 331, 316, 12889, 67, 267, 76, 67, 4699, 63, 1969, 65, 309, 486, 331, 18, 291, 67, 482, 65, 309, 1071, 67, 4699, 30, 596, 2 ]
writePCDataElement("para", "You can start %s by opening a terminal and typing the <command>%s</command> command."%(taggedAppName, appName))
writePCDataElement("para", "You can start %s by opening a terminal and typing the <command>%s</command> command."%(taggedAppName, cgi.escape(appName)))
def generateUnhelpfulHelp(appName): try: app = root.application(appName) except SearchError: run(appName) print '<?xml version="1.0"?>' print '<!DOCTYPE article PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd">' print '<article>' taggedAppName = '<application>%s</application>'%appName # Artile info: print '\t<articleinfo>' writePCDataElement("title", "The Totally Definitive No-Nonsense Unhelpful Complete Guide to %s for Mannequins in 40 Days - Unleashed!"%taggedAppName) print '\t</articleinfo>' # Guts of the article: print '\t<sect1>' writePCDataElement("title", "Introduction") writePCDataElement("caution", "<para>Do not take these instructions seriously. They are a parody of unhelpful help files found on many computer systems, and were autogenerated by <application>no-help-at-all</application></para>") writePCDataElement("para", "You can start %s by opening a terminal and typing the <command>%s</command> command."%(taggedAppName, appName)) print '\t</sect1>' menus = app.findChildren(predicate.GenericPredicate(roleName="menu")) for menu in menus: print '\t<sect1>' writePCDataElement("title", "The <guimenu>%s</guimenu> menu"%menu.name) writePCDataElement("para", "Use the <guimenu>%s</guimenu> menu to work with %ss"%(menu.name, menu.name.lower())) items = menu.findChildren(predicate.GenericPredicate(roleName="menu item"), recursive=False) if items!=None: for item in items: verb = item.name noun = menu.name print '\t\t<sect2>' writePCDataElement("title", "%sing a %s"%(verb.title(), noun.lower())) writePCDataElement("para", "To %s a %s, choose <guimenu>%s</guimenu> &gt; <guimenuitem>%s</guimenuitem>"%(verb.lower(), noun.lower(), menu.name, item.name)) print '\t\t</sect2>' print '\t</sect1>' print '</article>'
d24d70c5da5bade6842d9a7b40f56bcefda90a90 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/10139/d24d70c5da5bade6842d9a7b40f56bcefda90a90/no-help-at-all.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2103, 984, 5201, 2706, 6696, 12, 2910, 461, 4672, 775, 30, 595, 273, 1365, 18, 3685, 12, 2910, 461, 13, 1335, 5167, 668, 30, 1086, 12, 2910, 461, 13, 1172, 16617, 2902, 1177, 1546, 21, 18, 20, 6, 35, 1870, 1172, 2368, 5, 29824, 7559, 17187, 3701, 759, 28202, 15664, 759, 25728, 3521, 9084, 3167, 776, 24, 18, 21, 18, 22, 759, 1157, 6, 315, 2505, 2207, 5591, 18, 26501, 17, 3190, 18, 3341, 19, 2434, 3618, 19, 2902, 19, 24, 18, 21, 18, 22, 19, 2434, 3618, 92, 18, 31834, 7918, 1172, 2368, 11480, 1870, 225, 12503, 3371, 461, 273, 2368, 3685, 9822, 87, 1757, 3685, 1870, 9, 2910, 461, 225, 468, 9042, 398, 1123, 30, 1172, 2337, 88, 32, 11480, 1376, 1870, 1045, 3513, 751, 1046, 2932, 2649, 3113, 315, 1986, 399, 352, 1230, 18003, 3720, 2631, 17, 3989, 87, 3558, 1351, 5201, 2706, 14575, 13018, 358, 738, 87, 364, 490, 1072, 14298, 2679, 316, 8063, 463, 8271, 300, 1351, 298, 13912, 4442, 9, 23023, 3371, 461, 13, 1172, 2337, 88, 1757, 11480, 1376, 1870, 225, 468, 611, 12940, 434, 326, 7559, 30, 1172, 2337, 88, 32, 5709, 21, 1870, 1045, 3513, 751, 1046, 2932, 2649, 3113, 315, 1702, 303, 2544, 349, 7923, 1045, 3513, 751, 1046, 2932, 5353, 1421, 3113, 3532, 25072, 34, 3244, 486, 4862, 4259, 12509, 703, 22774, 715, 18, 225, 16448, 854, 279, 779, 973, 434, 640, 5201, 2706, 2809, 1390, 1392, 603, 4906, 26579, 14908, 16, 471, 4591, 7840, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2103, 984, 5201, 2706, 6696, 12, 2910, 461, 4672, 775, 30, 595, 273, 1365, 18, 3685, 12, 2910, 461, 13, 1335, 5167, 668, 30, 1086, 12, 2910, 461, 13, 1172, 16617, 2902, 1177, 1546, 21, 18, 20, 6, 35, 1870, 1172, 2368, 5, 29824, 7559, 17187, 3701, 759, 28202, 15664, 759, 25728, 3521, 9084, 3167, 776, 24, 18, 21, 18, 22, 759, 1157, 6, 315, 2505, 2207, 5591, 18, 26501, 17, 3190, 18, 3341, 19, 2434, 3618, 19, 2902, 19, 24, 18, 21, 18, 22, 19, 2434, 3618, 92, 18, 31834, 7918, 1172, 2368, 11480, 1870, 225, 12503, 3371, 461, 273, 2368, 3685, 9822, 87, 1757, 3685, 1870, 9, 2910, 461, 225, 468, 9042, 398, 1123, 30, 1172, 2 ]
sys.stderr.write( "module name in title doesn't match" " <declaremodule>; no <short-synopsis>\n")
ewrite("module name in title doesn't match" " <declaremodule/>; no <short-synopsis/>\n")
def create_module_info(doc, section): # Heavy. node = extract_first_element(section, "modulesynopsis") if node is None: return node._node.name = "synopsis" lastchild = node.childNodes[-1] if lastchild.nodeType == TEXT \ and lastchild.data[-1:] == ".": lastchild.data = lastchild.data[:-1] modauthor = extract_first_element(section, "moduleauthor") if modauthor: modauthor._node.name = "author" modauthor.appendChild(doc.createTextNode( modauthor.getAttribute("name"))) modauthor.removeAttribute("name") platform = extract_first_element(section, "platform") if section.tagName == "section": modinfo_pos = 2 modinfo = doc.createElement("moduleinfo") moddecl = extract_first_element(section, "declaremodule") name = None if moddecl: modinfo.appendChild(doc.createTextNode("\n ")) name = moddecl.attributes["name"].value namenode = doc.createElement("name") namenode.appendChild(doc.createTextNode(name)) modinfo.appendChild(namenode) type = moddecl.attributes.get("type") if type: type = type.value modinfo.appendChild(doc.createTextNode("\n ")) typenode = doc.createElement("type") typenode.appendChild(doc.createTextNode(type)) modinfo.appendChild(typenode) versionadded = extract_first_element(section, "versionadded") if versionadded: modinfo.setAttribute("added", versionadded.getAttribute("version")) title = get_first_element(section, "title") if title: children = title.childNodes if len(children) >= 2 \ and children[0].nodeType == ELEMENT \ and children[0].tagName == "module" \ and children[0].childNodes[0].data == name: # this is it; morph the <title> into <short-synopsis> first_data = children[1] if first_data.data[:4] == " ---": first_data.data = string.lstrip(first_data.data[4:]) title._node.name = "short-synopsis" if children[-1].nodeType == TEXT \ and children[-1].data[-1:] == ".": children[-1].data = children[-1].data[:-1] section.removeChild(title) section.removeChild(section.childNodes[0]) title.removeChild(children[0]) modinfo_pos = 0 else: sys.stderr.write( "module name in title doesn't match" " <declaremodule>; no <short-synopsis>\n") else: sys.stderr.write( "Unexpected condition: <section> without <title>\n") modinfo.appendChild(doc.createTextNode("\n ")) modinfo.appendChild(node) if title and not contents_match(title, node): # The short synopsis is actually different, # and needs to be stored: modinfo.appendChild(doc.createTextNode("\n ")) modinfo.appendChild(title) if modauthor: modinfo.appendChild(doc.createTextNode("\n ")) modinfo.appendChild(modauthor) if platform: modinfo.appendChild(doc.createTextNode("\n ")) modinfo.appendChild(platform) modinfo.appendChild(doc.createTextNode("\n ")) section.insertBefore(modinfo, section.childNodes[modinfo_pos]) section.insertBefore(doc.createTextNode("\n "), modinfo) # # The rest of this removes extra newlines from where we cut out # a lot of elements. A lot of code for minimal value, but keeps # keeps the generated SGML from being too funny looking. # section.normalize() children = section.childNodes for i in range(len(children)): node = children[i] if node.nodeType == ELEMENT \ and node.tagName == "moduleinfo": nextnode = children[i+1] if nextnode.nodeType == TEXT: data = nextnode.data if len(string.lstrip(data)) < (len(data) - 4): nextnode.data = "\n\n\n" + string.lstrip(data)
304ebb260c7d5886ccb4a4738c3e4f83f60820f6 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12029/304ebb260c7d5886ccb4a4738c3e4f83f60820f6/docfixer.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 752, 67, 2978, 67, 1376, 12, 2434, 16, 2442, 4672, 468, 8264, 23935, 18, 756, 273, 2608, 67, 3645, 67, 2956, 12, 3464, 16, 315, 6400, 878, 29522, 7923, 309, 756, 353, 599, 30, 327, 756, 6315, 2159, 18, 529, 273, 315, 11982, 29522, 6, 1142, 3624, 273, 756, 18, 3624, 3205, 18919, 21, 65, 309, 1142, 3624, 18, 2159, 559, 422, 9204, 521, 471, 1142, 3624, 18, 892, 18919, 21, 26894, 422, 4585, 30, 1142, 3624, 18, 892, 273, 1142, 3624, 18, 892, 10531, 17, 21, 65, 681, 4161, 273, 2608, 67, 3645, 67, 2956, 12, 3464, 16, 315, 2978, 4161, 7923, 309, 681, 4161, 30, 681, 4161, 6315, 2159, 18, 529, 273, 315, 4161, 6, 681, 4161, 18, 6923, 1763, 12, 2434, 18, 2640, 17299, 12, 681, 4161, 18, 588, 1499, 2932, 529, 6, 20349, 681, 4161, 18, 4479, 1499, 2932, 529, 7923, 4072, 273, 2608, 67, 3645, 67, 2956, 12, 3464, 16, 315, 9898, 7923, 309, 2442, 18, 2692, 461, 422, 315, 3464, 6877, 681, 1376, 67, 917, 273, 576, 681, 1376, 273, 997, 18, 2640, 1046, 2932, 2978, 1376, 7923, 681, 8840, 273, 2608, 67, 3645, 67, 2956, 12, 3464, 16, 315, 29554, 2978, 7923, 508, 273, 599, 309, 681, 8840, 30, 681, 1376, 18, 6923, 1763, 12, 2434, 18, 2640, 17299, 31458, 82, 565, 315, 3719, 508, 273, 681, 8840, 18, 4350, 9614, 529, 6, 8009, 1132, 15135, 20680, 273, 997, 18, 2640, 1046, 2932, 529, 7923, 15135, 20680, 18, 6923, 2 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 752, 67, 2978, 67, 1376, 12, 2434, 16, 2442, 4672, 468, 8264, 23935, 18, 756, 273, 2608, 67, 3645, 67, 2956, 12, 3464, 16, 315, 6400, 878, 29522, 7923, 309, 756, 353, 599, 30, 327, 756, 6315, 2159, 18, 529, 273, 315, 11982, 29522, 6, 1142, 3624, 273, 756, 18, 3624, 3205, 18919, 21, 65, 309, 1142, 3624, 18, 2159, 559, 422, 9204, 521, 471, 1142, 3624, 18, 892, 18919, 21, 26894, 422, 4585, 30, 1142, 3624, 18, 892, 273, 1142, 3624, 18, 892, 10531, 17, 21, 65, 681, 4161, 273, 2608, 67, 3645, 67, 2956, 12, 3464, 16, 315, 2978, 4161, 7923, 309, 681, 4161, 30, 681, 4161, 6315, 2159, 18, 529, 273, 315, 4161, 6, 681, 2 ]
def trait_names(self, verbose=True, use_disk_cache=True): try: return self.__trait_names except AttributeError: import sage.misc.persist if use_disk_cache: try: self.__trait_names = sage.misc.persist.load(COMMANDS_CACHE) return self.__trait_names except IOError: pass if verbose: print "\nBuilding Axiom command completion list (this takes" print "a few seconds only the first time you do it)." print "To force rebuild later, delete %s."%COMMANDS_CACHE v = self._commands() self.__trait_names = v sage.misc.persist.save(v, COMMANDS_CACHE) return v
def trait_names(self, verbose=True, use_disk_cache=True): try: return self.__trait_names except AttributeError: import sage.misc.persist if use_disk_cache: try: self.__trait_names = sage.misc.persist.load(COMMANDS_CACHE) return self.__trait_names except IOError: pass if verbose: print "\nBuilding Axiom command completion list (this takes" print "a few seconds only the first time you do it)." print "To force rebuild later, delete %s."%COMMANDS_CACHE v = self._commands() self.__trait_names = v sage.misc.persist.save(v, COMMANDS_CACHE) return v
6d26ee404de5ca55a472c0aa9236698863e1dee9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9417/6d26ee404de5ca55a472c0aa9236698863e1dee9/axiom.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 13517, 67, 1973, 12, 2890, 16, 3988, 33, 5510, 16, 999, 67, 10863, 67, 2493, 33, 5510, 4672, 775, 30, 327, 365, 16186, 22513, 67, 1973, 1335, 6394, 30, 1930, 272, 410, 18, 23667, 18, 19251, 309, 999, 67, 10863, 67, 2493, 30, 775, 30, 365, 16186, 22513, 67, 1973, 273, 272, 410, 18, 23667, 18, 19251, 18, 945, 12, 4208, 9560, 3948, 67, 8495, 13, 327, 365, 16186, 22513, 67, 1973, 1335, 8340, 30, 1342, 309, 3988, 30, 1172, 1548, 82, 16713, 22516, 14642, 1296, 8364, 666, 261, 2211, 5530, 6, 1172, 315, 69, 11315, 3974, 1338, 326, 1122, 813, 1846, 741, 518, 14944, 1172, 315, 774, 2944, 13419, 5137, 16, 1430, 738, 87, 1199, 9, 4208, 9560, 3948, 67, 8495, 331, 273, 365, 6315, 7847, 1435, 365, 16186, 22513, 67, 1973, 273, 331, 272, 410, 18, 23667, 18, 19251, 18, 5688, 12, 90, 16, 5423, 9560, 3948, 67, 8495, 13, 327, 331, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 13517, 67, 1973, 12, 2890, 16, 3988, 33, 5510, 16, 999, 67, 10863, 67, 2493, 33, 5510, 4672, 775, 30, 327, 365, 16186, 22513, 67, 1973, 1335, 6394, 30, 1930, 272, 410, 18, 23667, 18, 19251, 309, 999, 67, 10863, 67, 2493, 30, 775, 30, 365, 16186, 22513, 67, 1973, 273, 272, 410, 18, 23667, 18, 19251, 18, 945, 12, 4208, 9560, 3948, 67, 8495, 13, 327, 365, 16186, 22513, 67, 1973, 1335, 8340, 30, 1342, 309, 3988, 30, 1172, 1548, 82, 16713, 22516, 14642, 1296, 8364, 666, 261, 2211, 5530, 6, 1172, 315, 69, 11315, 3974, 1338, 326, 1122, 813, 1846, 741, 518, 14944, 1172, 315, 774, 2944, 13419, 5137, 16, 1430, 738, 87, 1199, 9, 4208, 2 ]
msg = 'Exception caught in send():' + str(e) + '\n'
msg = 'Exception caught in send(): %s' % str(e)
def send(self, text): '''This sends a string to the child process. ''' ### Add code so that an empty string will send an EOF. ### This emulates the symantics of Libes Expect. ### Hmmm... how do I send an EOF? ###C if ((m = write(pty, *buf, p - *buf)) < 0) ###C return (errno == EWOULDBLOCK) ? n : -1;
a6436229531e4cc3cceb58c0322f4ecc258e53d4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9386/a6436229531e4cc3cceb58c0322f4ecc258e53d4/pexpect.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1366, 12, 2890, 16, 977, 4672, 9163, 2503, 9573, 279, 533, 358, 326, 1151, 1207, 18, 9163, 11849, 1436, 981, 1427, 716, 392, 1008, 533, 903, 1366, 392, 6431, 18, 11849, 1220, 801, 17099, 326, 5382, 11119, 434, 10560, 281, 15510, 18, 11849, 670, 7020, 81, 2777, 3661, 741, 467, 1366, 392, 6431, 35, 11849, 39, 225, 309, 14015, 81, 273, 1045, 12, 825, 16, 380, 4385, 16, 293, 300, 380, 4385, 3719, 411, 374, 13, 11849, 39, 1377, 327, 261, 19088, 422, 512, 59, 51, 1506, 2290, 6589, 13, 692, 290, 294, 300, 21, 31, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1366, 12, 2890, 16, 977, 4672, 9163, 2503, 9573, 279, 533, 358, 326, 1151, 1207, 18, 9163, 11849, 1436, 981, 1427, 716, 392, 1008, 533, 903, 1366, 392, 6431, 18, 11849, 1220, 801, 17099, 326, 5382, 11119, 434, 10560, 281, 15510, 18, 11849, 670, 7020, 81, 2777, 3661, 741, 467, 1366, 392, 6431, 35, 11849, 39, 225, 309, 14015, 81, 273, 1045, 12, 825, 16, 380, 4385, 16, 293, 300, 380, 4385, 3719, 411, 374, 13, 11849, 39, 1377, 327, 261, 19088, 422, 512, 59, 51, 1506, 2290, 6589, 13, 692, 290, 294, 300, 21, 31, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100 ]