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
Returns an encoding of the given string based on the current encoding table INPUT: - ``string`` (string) EXAMPLE: This is how a string is encoded then decoded ::
Encode the given string based on the current encoding table. INPUT: - ``string`` -- a string of symbols over an alphabet. OUTPUT: - A Huffman encoding of ``string``. EXAMPLES: This is how a string is encoded and then decoded::
def encode(self, string): r""" Returns an encoding of the given string based on the current encoding table
0aa5d0e07206199e4e64708c13056046cecfe083 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9890/0aa5d0e07206199e4e64708c13056046cecfe083/huffman.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2017, 12, 2890, 16, 533, 4672, 436, 8395, 2860, 392, 2688, 434, 326, 864, 533, 2511, 603, 326, 783, 2688, 1014, 2, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2017, 12, 2890, 16, 533, 4672, 436, 8395, 2860, 392, 2688, 434, 326, 864, 533, 2511, 603, 326, 783, 2688, 1014, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,...
for myFile in fnmatch.filter(wikiFileFinder.get_analyzeQscan_RDS(),\
for myFile in fnmatch.filter(filesAnalyze,\
def prepareChecklist(wikiFilename=None,wikiCoinc=None,wikiTree=None,file2URL=None): """ Method to prepare a checklist where data products are isolated in directory. """ endOfS5=int(875232014) wikiFileFinder=findFileType(wikiTree,wikiCoinc) # Check to see if wiki file with name already exists maxCount=0 while os.path.exists(wikiFilename) and maxCount < 15: sys.stdout.write("File %s already exists.\n"%\ os.path.split(wikiFilename)[1]) wikiFilename=wikiFilename+".wiki" maxCount=maxCount+1 # #Create the wikipage object etc # wikiPage=wiki(wikiFilename) # # Create top two trigger params tables # cTable=wikiPage.wikiTable(2,9) cTable.data=[ ["Trigger Type", "Rank", "FAR", "SNR", "IFOS(Coinc)", "Instruments(Active)", "Coincidence Time (s)", "Total Mass (mSol)", "Chirp Mass (mSol)" ], ["%s"%(wikiCoinc.type), "%s"%(wikiCoinc.rank), "%s"%(wikiCoinc.far), "%s"%(wikiCoinc.snr), "%s"%(wikiCoinc.ifos), "%s"%(wikiCoinc.instruments), "%s"%(wikiCoinc.time), "%s"%(wikiCoinc.mass), "%s"%(wikiCoinc.mchirp) ] ] pTable=wikiPage.wikiTable(len(wikiCoinc.sngls_in_coinc())+1,7) pTable.data[0]=[ "IFO", "GPS Time(s)", "SNR", "CHISQR", "Mass 1", "Mass 2", "Chirp Mass" ] for row,cSngl in enumerate(wikiCoinc.sngls_in_coinc()): pTable.data[row+1]=[ "%s"%(cSngl.ifo), "%s"%(cSngl.time), "%s"%(cSngl.snr), "%s"%(cSngl.chisqr), "%s"%(cSngl.mass1), "%s"%(cSngl.mass2), "%s"%(cSngl.mchirp) ] #Write the tables into the Wiki object wikiPage.putText("Coincident Trigger Event Information: %s\n"\ %(stfu_pipe.gpsTimeToReadableDate(wikiCoinc.time))) wikiPage.insertTable(cTable) wikiPage.putText("Corresponding Coincident Single IFO Trigger Information\n") wikiPage.insertTable(pTable) #Generate a table of contents to appear after candidate params table wikiPage.tableOfContents(3) #Begin including each checklist item as section with subsections wikiPage.section("Follow-up Checklist") #Put each checklist item wikiPage.subsection("Checklist Summary") wikiPage.subsubsection("Does this candidate pass this checklist?") wikiPage.subsubsection("Answer") wikiPage.subsubsection("Relevant Information and Comments") wikiPage.insertHR() # #First real checklist item wikiPage.subsection("#0 False Alarm Probability") wikiPage.subsubsection("Question") wikiPage.putText("What is the false alarm rate associated with this candidate?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") farTable=wikiPage.wikiTable(2,1) farTable.setTableStyle("background-color: yellow; text-align center;") farTable.data[0][0]="False Alarm Rate" farTable.data[1][0]="%s"%(wikiCoinc.far) wikiPage.insertTable(farTable) wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # #Additional Checklist Item #First real checklist item wikiPage.subsection("#1 Data Quality Flags") wikiPage.subsubsection("Question") wikiPage.putText("Can the data quality flags coincident with this candidate be safely disregarded?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") wikiPath=os.path.split(wikiFilename)[0] dqFileList=wikiFileFinder.get_findFlags() if len(dqFileList) != 1: sys.stdout.write("Warning: DQ flags data product import problem.\n") print "Found %i files."%len(dqFileList) for mf in dqFileList: print mf for myFile in dqFileList: wikiPage.putText("%s\n"%(file(myFile).read())) wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # #Additional Checklist Item #First real checklist item wikiPage.subsection("#2 Veto Investigations") wikiPage.subsubsection("Question") wikiPage.putText("Does the candidate survive the veto investigations performed at its time?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") vetoFileList=wikiFileFinder.get_findVetos() if len(vetoFileList) != 1: sys.stdout.write("Warning: Veto flags data product import problem.\n") for myFile in vetoFileList:print myFile for myFile in vetoFileList: wikiPage.putText("%s\n"%(file(myFile).read())) wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # #Additional Checklist Item #First real checklist item wikiPage.subsection("#3 IFO Status") wikiPage.subsubsection("Question") wikiPage.putText("Are the interferometers operating normally with a reasonable level of sensitivity around the time of the candidate?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") #Add link to Daily Stats if wikiCoinc.time <= endOfS5: statsLink=wikiPage.makeExternalLink("http://blue.ligo-wa.caltech.edu/scirun/S5/DailyStatistics/",\ "S5 Daily Stats Page") else: statsLink="This should be a link to S6 Daily Stats!\n" wikiPage.putText(statsLink) #Link figures of merit #Get link for all members of wikiCoinc wikiPage.putText("Figures of Merit\n") if wikiCoinc.time > endOfS5: fomLinks=dict() elems=0 for wikiSngl in wikiCoinc.sngls: if not(wikiSngl.ifo.upper().rstrip().lstrip() == 'V1'): fomLinks[wikiSngl.ifo]=stfu_pipe.getFOMLinks(wikiCoinc.time,wikiSngl.ifo) elems=elems+len(fomLinks[wikiSngl.ifo]) else: for myLabel,myLink,myThumb in stfu_pipe.getFOMLinks(wikiCoinc.time,wikiSngl.ifo): wikiPage.putText("%s\n"%(wikiPage.makeExternalLink(myLink,myLabel))) cols=4 rows=(elems/3)+1 fTable=wikiPage.wikiTable(rows,cols) fTable.data[0]=["IFO,Shift","FOM1","FOM2","FOM3"] currentIndex=0 for myIFOKey in fomLinks.keys(): for label,link,thumb in fomLinks[myIFOKey]: myRow=currentIndex/int(3)+1 myCol=currentIndex%int(3)+1 fTable.data[myRow][0]=label thumbURL=thumb fTable.data[myRow][myCol]="%s"%(wikiPage.linkedRemoteImage(thumb,link)) currentIndex=currentIndex+1 wikiPage.insertTable(fTable) else: wikiPage.putText("Can not automatically fetch S5 FOM links.") wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # #Additional Checklist Item #First real checklist item wikiPage.subsection("#4 Candidate Appearance") wikiPage.subsubsection("Question") wikiPage.putText("Do the Qscan figures show what we would expect for a gravitational-wave event?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") imageDict=dict() indexDict=dict() thumbDict=dict() for sngl in wikiCoinc.sngls: frametype,channelName=stfu_pipe.figure_out_type(sngl.time,sngl.ifo,'hoft') indexDict[sngl.ifo]=fnmatch.filter(wikiFileFinder.get_hoft_frame(),\ "*/%s/*/%s/*index.html"%(frametype,sngl.time)) imageDict[sngl.ifo]=fnmatch.filter(wikiFileFinder.get_hoft_frame(),\ "*%s*_%s_16.00_spectrogram_whitened.png"\ %(sngl.time,channelName)) thumbDict[sngl.ifo]=fnmatch.filter(wikiFileFinder.get_hoft_frame(),\ "*%s*_%s_16.00_spectrogram_whitened?thumb.png"\ %(sngl.time,channelName)) # #Convert disk locals to URLs imageDict[sngl.ifo]=[file2URL.convert(x) for x in imageDict[sngl.ifo]] indexDict[sngl.ifo]=[file2URL.convert(x) for x in indexDict[sngl.ifo]] thumbDict[sngl.ifo]=[file2URL.convert(x) for x in thumbDict[sngl.ifo]] if len(indexDict[sngl.ifo]) < 1: wikiPage.putText("GW data channel scans for %s not available.\n"%sngl.ifo) enoughImage=[len(imageDict[key])>0 for key in imageDict.keys()].count(True) >= 1 enoughIndex=[len(indexDict[key])>0 for key in indexDict.keys()].count(True) >= 1 if enoughImage and enoughIndex: wikiPage.insertQscanTable(imageDict,\ thumbDict,\ indexDict) else: sys.stdout.write("Warning: Candidate appearance plot import problem.\n") wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # # #Additional Checklist Item wikiPage.subsection("#5 Seismic Plots") wikiPage.subsubsection("Question") wikiPage.putText("Is the seismic activity insignificant around the time of the candidate?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") wikiPage.putText("Plots and pipeline data go here!") imageDict=dict() indexDict=dict() thumbDict=dict() zValueDict=dict() imageDictAQ=dict() indexDictAQ=dict() thumbDictAQ=dict() zValueDictAQ=dict() # for sngl in wikiCoinc.sngls_in_coinc(): indexDict[sngl.ifo]=fnmatch.filter(wikiFileFinder.get_RDS_R_L1_SEIS(),\ "*/%s_RDS_*/%s/*index.html"%(sngl.ifo,sngl.time)) imageDict[sngl.ifo]=fnmatch.filter(wikiFileFinder.get_RDS_R_L1_SEIS(),\ "*/%s_RDS_*/%s/*SEI*_512.00_spectrogram_whitened.png"%\ (sngl.ifo,sngl.time)) thumbDict[sngl.ifo]=fnmatch.filter(wikiFileFinder.get_RDS_R_L1_SEIS(),\ "*/%s_RDS_*/%s/*SEI*_512.00_spectrogram_whitened?thumb.png"%\ (sngl.ifo,sngl.time)) #Search for corresponding Omega summary.txt file zValueFiles=fnmatch.filter(wikiFileFinder.get_RDS_R_L1_SEIS(),\ "*/%s_RDS_*/%s/*summary.txt"%(sngl.ifo,sngl.time)) zValueDict[sngl.ifo]=list() if (len(zValueFiles) > 0): for zFile in zValueFiles: zValueDict[sngl.ifo].extend(wikiFileFinder.__readSummary__(zFile)) #Reparse only keeping SEI channels tmpList=list() for chan in zValueDict[sngl.ifo]: if "SEI" in chan[0]: tmpList.append(chan) zValueDict[sngl.ifo]=tmpList else: sys.stdout.write("Omega scan summary file not for for %s. ...skipping...\n"%sngl.ifo) #Search for analyzeQscan files #/L1-analyseQscan_L1_932797512_687_seis_rds_L1_SEI-ETMX_X_z_scat-unspecified-gpstime.png timeString=str(float(sngl.time)).replace(".","_") zValueFiles=fnmatch.filter(wikiFileFinder.get_analyzeQscan_SEIS(),\ "*_%s_%s_*.txt"%(sngl.ifo,timeString)) indexDictAQ[sngl.ifo]=fnmatch.filter(wikiFileFinder.get_analyzeQscan_SEIS(),\ "*_%s_%s_*.html"%(sngl.ifo,timeString)) thumbDictAQ[sngl.ifo]=fnmatch.filter(wikiFileFinder.get_analyzeQscan_SEIS(),\ "*%s-*_%s_*_SEI*_z_scat-unspecified-gpstime_thumb.png"\ %(sngl.ifo,timeString)) imageDictAQ[sngl.ifo]=fnmatch.filter(wikiFileFinder.get_analyzeQscan_SEIS(),\ "*%s-*_%s_*_SEI*_z_scat-unspecified-gpstime.png"\ %(sngl.ifo,timeString)) #Process zValue ranking file if found for IFO zValueDictAQ[sngl.ifo]=list() if len(zValueFiles)>0: for zFile in zValueFiles: zValueDictAQ[sngl.ifo].extend(wikiFileFinder.__readZranks__(zFile)) #Reparse keeping SEI channels tmpList=list() for chan in zValueDictAQ[sngl.ifo]: if "SEI" in chan[0]: tmpList.append(chan) zValueDictAQ[sngl.ifo]=tmpList else: sys.stdout.write("Analyze Qscan Z ranking file not found for %s. ...skipping...\n"%sngl.ifo) #Convert disk locals to URLs imageDict[sngl.ifo]=[file2URL.convert(x) for x in imageDict[sngl.ifo]] indexDict[sngl.ifo]=[file2URL.convert(x) for x in indexDict[sngl.ifo]] thumbDict[sngl.ifo]=[file2URL.convert(x) for x in thumbDict[sngl.ifo]] imageDictAQ[sngl.ifo]=[file2URL.convert(x) for x in imageDictAQ[sngl.ifo]] indexDictAQ[sngl.ifo]=[file2URL.convert(x) for x in indexDictAQ[sngl.ifo]] thumbDictAQ[sngl.ifo]=[file2URL.convert(x) for x in thumbDictAQ[sngl.ifo]] if len(indexDict[sngl.ifo]) < 1: wikiPage.putText("Seismic scans for %s not available.\n"%sngl.ifo) enoughImage=[len(imageDict[key])>0 for key in imageDict.keys()].count(True) >=1 enoughIndex=[len(indexDict[key])>0 for key in indexDict.keys()].count(True) >=1 if enoughImage and enoughIndex: wikiPage.insertAnalyzeQscanTable(imageDict, thumbDict, indexDict, zValueDict, imageDictAQ, thumbDictAQ, indexDictAQ, zValueDictAQ) else: sys.stdout.write("Warning: Seismic plots product import problem.\n") wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # # #Additional Checklist Item wikiPage.subsection("#6 Other environmental causes") wikiPage.subsubsection("Question") wikiPage.putText("Were the environmental disturbances (other than seismic) insignificant at the time of the candidate?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") wikiPage.putText("Plots and pipeline data go here!") imageDict=dict() indexDict=dict() thumbDict=dict() zValueDict=dict() imageDictAQ=dict() indexDictAQ=dict() thumbDictAQ=dict() zValueDictAQ=dict() #Select only PEM channels for sngl in wikiCoinc.sngls_in_coinc(): imageDict[sngl.ifo]=list() indexDict[sngl.ifo]=list() thumbDict[sngl.ifo]=list() for myFile in fnmatch.filter(wikiFileFinder.get_RDS_R_L1(),\ "*/%s_RDS_*/%s/*html"%(sngl.ifo,sngl.time)): indexDict[sngl.ifo].append(myFile) for myFile in fnmatch.filter(wikiFileFinder.get_RDS_R_L1(),\ "*/%s_RDS_*/%s/*_16.00_spectrogram_whitened.png"%\ (sngl.ifo,sngl.time)): if "PEM" in myFile.upper() and not "SEI" in myFile.upper(): imageDict[sngl.ifo].append(myFile) for myFile in fnmatch.filter(wikiFileFinder.get_RDS_R_L1(),\ "*/%s_RDS_*/%s/*_16.00_spectrogram_whitened?thumb.png"%\ (sngl.ifo,sngl.time)): if "PEM" in myFile.upper() and not "SEI" in myFile.upper(): thumbDict[sngl.ifo].append(myFile) #Search for corresponding Omega summary.txt file zValueFiles=fnmatch.filter(wikiFileFinder.get_RDS_R_L1(),\ "*/%s_RDS_*/%s/*summary.txt"%(sngl.ifo,sngl.time)) zValueDict[sngl.ifo]=list() if len(zValueFiles)>0: for zFile in zValueFiles: zValueDict[sngl.ifo].extend(wikiFileFinder.__readSummary__(zFile)) #Reparse only keeping PEM and not SEI channels tmpList=list() for chan in zValueDict[sngl.ifo]: if "PEM" in chan[0] and not "SEI" in chan[0]: tmpList.append(chan) zValueDict[sngl.ifo]=tmpList else: sys.stdout.write("Omega scan summary file not for for %s. ...skipping...\n"%sngl.ifo) #Select associated analyzeQscans imageDictAQ[sngl.ifo]=list() indexDictAQ[sngl.ifo]=list() thumbDictAQ[sngl.ifo]=list() timeString=str(float(sngl.time)).replace(".","_") for myFile in fnmatch.filter(wikiFileFinder.get_analyzeQscan_RDS(),\ "*%s-*_%s_*html"%(sngl.ifo,timeString)): indexDictAQ[sngl.ifo].append(myFile) zValueFiles=fnmatch.filter(wikiFileFinder.get_analyzeQscan_RDS(),\ "*%s-*_%s_*txt"%(sngl.ifo,timeString)) zValueDictAQ[sngl.ifo]=list() if len(zValueFiles)>0: for zFile in zValueFiles: zValueDictAQ[sngl.ifo].extend(wikiFileFinder.__readZranks__(zFile)) for chan in zValueDictAQ[sngl.ifo]: if "PEM" in chan[0] and not "SEI" in chan[0]: tmpList.append(chan) zValueDictAQ[sngl.ifo]=tmpList else: sys.stdout.write("Analyze Qscan Z ranking file not found for %s. ...skipping...\n"%sngl.ifo) #H1-analyseQscan_H1_931176926_116_rds_H0_PEM-MY_SEISX_z_scat-unspecified-gpstime_thumb.png #H1-analyseQscan_H1_931176926_116_rds_H0_PEM-MY_SEISX_z_scat-unspecified-gpstime.png for myFile in fnmatch.filter(wikiFileFinder.get_analyzeQscan_RDS(),\ "*%s-*_%s_*_z_scat-unspecified-gpstime.png"%\ (sngl.ifo,timeString)): if "PEM" in myFile.upper() and not "SEI" in myFile.upper(): imageDictAQ[sngl.ifo].append(myFile) for myFile in fnmatch.filter(wikiFileFinder.get_analyzeQscan_RDS(),\ "*%s-*_%s_*_z_scat-unspecified-gpstime?thumb.png"%\ (sngl.ifo,timeString)): if "PEM" in myFile.upper() and not "SEI" in myFile.upper(): thumbDictAQ[sngl.ifo].append(myFile) #Convert disk locals to URLs imageDict[sngl.ifo]=[file2URL.convert(x) for x in imageDict[sngl.ifo]] indexDict[sngl.ifo]=[file2URL.convert(x) for x in indexDict[sngl.ifo]] thumbDict[sngl.ifo]=[file2URL.convert(x) for x in thumbDict[sngl.ifo]] imageDictAQ[sngl.ifo]=[file2URL.convert(x) for x in imageDictAQ[sngl.ifo]] indexDictAQ[sngl.ifo]=[file2URL.convert(x) for x in indexDictAQ[sngl.ifo]] thumbDictAQ[sngl.ifo]=[file2URL.convert(x) for x in thumbDictAQ[sngl.ifo]] if len(imageDict[sngl.ifo]) < 1: wikiPage.putText("PEM scans for %s not available.\n"%sngl.ifo) enoughImage=[len(imageDict[key])>0 for key in imageDict.keys()].count(True) >=1 enoughIndex=[len(indexDict[key])>0 for key in indexDict.keys()].count(True) >=1 if enoughImage and enoughIndex: wikiPage.insertAnalyzeQscanTable(imageDict, thumbDict, indexDict, zValueDict, imageDictAQ, thumbDictAQ, indexDictAQ, zValueDictAQ) else: sys.stdout.write("Warning: PEM plots import trouble.\n") wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # # #Additional Checklist Item wikiPage.subsection("#7 Auxiliary degree of freedom") wikiPage.subsubsection("Question") wikiPage.putText("Were the auxiliary channel transients coincident with the candidate insignificant?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") imageDict=dict() indexDict=dict() thumbDict=dict() zValueDict=dict() imageDictAQ=dict() indexDictAQ=dict() thumbDictAQ=dict() zValueDictAQ=dict() #Select only AUX channels for sngl in wikiCoinc.sngls: imageDict[sngl.ifo]=list() indexDict[sngl.ifo]=list() thumbDict[sngl.ifo]=list() for myFile in fnmatch.filter(wikiFileFinder.get_RDS_R_L1(),\ "*/%s_RDS_*/%s/*html"%(sngl.ifo,sngl.time)): indexDict[sngl.ifo].append(myFile) for myFile in fnmatch.filter(wikiFileFinder.get_RDS_R_L1(),\ "*/%s_RDS_*/%s/*_16.00_spectrogram_whitened.png"%\ (sngl.ifo,sngl.time)): if not "PEM" in myFile.upper() or not "SEI" in myFile.upper(): imageDict[sngl.ifo].append(myFile) for myFile in fnmatch.filter(wikiFileFinder.get_RDS_R_L1(),\ "*/%s_RDS_*/%s/*_16.00_spectrogram_whitened?thumb.png"%\ (sngl.ifo,sngl.time)): if not "PEM" in myFile.upper() or not "SEI" in myFile.upper(): thumbDict[sngl.ifo].append(myFile) zValueFiles=fnmatch.filter(wikiFileFinder.get_RDS_R_L1(),\ "*/%s_RDS_*/%s/*summary.txt"%(sngl.ifo,sngl.time)) zValueDict[sngl.ifo]=list() if len(zValueFiles)>0: for zFile in zValueFiles: zValueDict[sngl.ifo].extend(wikiFileFinder.__readSummary__(zFile)) #Reparse NOT keeping PEM or SEI channels tmpList=list() for chan in zValueDict[sngl.ifo]: if not "PEM" in chan[0] or not "SEI" in chan[0]: tmpList.append(chan) zValueDict[sngl.ifo]=tmpList else: sys.stdout.write("Omega scan summary file not for for %s. ...skipping...\n"%sngl.ifo) #Select associated analyzeQscans imageDictAQ[sngl.ifo]=list() indexDictAQ[sngl.ifo]=list() thumbDictAQ[sngl.ifo]=list() timeString=str(float(sngl.time)).replace(".","_") #H1-analyseQscan_H1_931176926_116_rds-unspecified-gpstime.html for myFile in fnmatch.filter(wikiFileFinder.get_analyzeQscan_RDS(),\ "*%s-*_%s_*html"%(sngl.ifo,timeString)): indexDictAQ[sngl.ifo].append(myFile) zValueFiles=fnmatch.filter(wikiFileFinder.get_analyzeQscan_RDS(),\ "*%s-*_%s_*txt"%(sngl.ifo,timeString)) #Process zValue ranking file if found for IFO zValueDictAQ[sngl.ifo]=list() if len(zValueFiles)>0: for zFile in zValueFiles: zValueDictAQ[sngl.ifo].extend(wikiFileFinder.__readZranks__(zFile)) #Reparse NOT keeping PEM or SEI channels tmpList=list() for chan in zValueDictAQ[sngl.ifo]: if not "PEM" in chan[0] or not "SEI" in chan[0]: tmpList.append(chan) zValueDictAQ[sngl.ifo]=tmpList else: sys.stdout.write("Z ranking file not found for %s. ...skipping...\n"%sngl.ifo) #H1-analyseQscan_H1_931176926_116_rds_H0_PEM-MY_SEISX_z_scat-unspecified-gpstime_thumb.png #H1-analyseQscan_H1_931176926_116_rds_H0_PEM-MY_SEISX_z_scat-unspecified-gpstime.png for myFile in fnmatch.filter(wikiFileFinder.get_analyzeQscan_RDS(),\ "*%s-*_%s_*_z_scat-unspecified-gpstime.png"%\ (sngl.ifo,timeString)): if not "PEM" in myFile.upper() or not "SEI" in myFile.upper(): imageDictAQ[sngl.ifo].append(myFile) for myFile in fnmatch.filter(wikiFileFinder.get_analyzeQscan_RDS(),\ "*%s-*_%s_*_z_scat-unspecified-gpstime?thumb.png"%\ (sngl.ifo,timeString)): if not "PEM" in myFile.upper() or not "SEI" in myFile.upper(): thumbDictAQ[sngl.ifo].append(myFile) #Convert disk locals to URLs imageDict[sngl.ifo]=[file2URL.convert(x) for x in imageDict[sngl.ifo]] indexDict[sngl.ifo]=[file2URL.convert(x) for x in indexDict[sngl.ifo]] thumbDict[sngl.ifo]=[file2URL.convert(x) for x in thumbDict[sngl.ifo]] imageDictAQ[sngl.ifo]=[file2URL.convert(x) for x in imageDictAQ[sngl.ifo]] indexDictAQ[sngl.ifo]=[file2URL.convert(x) for x in indexDictAQ[sngl.ifo]] thumbDictAQ[sngl.ifo]=[file2URL.convert(x) for x in thumbDictAQ[sngl.ifo]] if len(indexDict[sngl.ifo]) < 1: wikiPage.putText("Other scans for %s not available.\n"%sngl.ifo) enoughImage=[len(imageDict[key])>0 for key in imageDict.keys()].count(True) >=1 enoughIndex=[len(indexDict[key])>0 for key in indexDict.keys()].count(True) >=1 if enoughImage and enoughIndex: wikiPage.insertAnalyzeQscanTable(imageDict, thumbDict, indexDict, zValueDict, imageDictAQ, thumbDictAQ, indexDictAQ, zValueDictAQ) else: sys.stdout.write("Warning: AUX plots import trouble.\n") wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # # #Additional Checklist Item wikiPage.subsection("#8 Electronic Log Book") wikiPage.subsubsection("Question") wikiPage.putText("Were the instruments behaving normally according to the comments posted by the sci-mons or the operators in the e-log?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") wikiPage.putText("Plots and pipeline data go here!") wikiLinkLHOlog=wikiPage.makeExternalLink(stfu_pipe.getiLogURL(myCoinc.time,"H1"), "Hanford eLog") wikiLinkLLOlog=wikiPage.makeExternalLink(stfu_pipe.getiLogURL(myCoinc.time,"L1"), "Livingston eLog") wikiPage.putText("%s\n\n%s\n\n"%(wikiLinkLHOlog,wikiLinkLLOlog)) wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # # #Additional Checklist Item wikiPage.subsection("#9 Glitch Report") wikiPage.subsubsection("Question") wikiPage.putText("Were the instruments behaving normally according to the weekly glitch report?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") wikiPage.putText("Plots and pipeline data go here!") if int(wikiCoinc.time) >= endOfS5: wikiLinkGlitch=wikiPage.makeExternalLink( "https://www.lsc-group.phys.uwm.edu/twiki/bin/view/DetChar/GlitchStudies", "Glitch Reports for S6" ) else: wikiLinkGlitch=wikiPage.makeExternalLink( "http://www.lsc-group.phys.uwm.edu/glitch/investigations/s5index.html#shift", "Glitch Reports for S5" ) wikiPage.putText("%s\n"%(wikiLinkGlitch)) wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # # #Additional Checklist Item wikiPage.subsection("#10 Snr versus time") wikiPage.subsubsection("Question") wikiPage.putText("Is this trigger significant in a SNR versus time plot of all triggers in its analysis chunk?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") wikiPage.putText("Plots and pipeline data go here!") wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # # #Additional Checklist Item wikiPage.subsection("#11 Parameters of the candidate") wikiPage.subsubsection("Question") wikiPage.putText("Does the candidate have a high likelihood of being a gravitational-wave according to its parameters?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") wikiPage.putText("Effective Distance Ratio Test\n") effDList=wikiFileFinder.get_effDRatio() if len(effDList) != 1: sys.stdout.write("Warning: Effective Distance Test import problem.\n") for myFile in effDList: wikiPage.putText("%s\n"%(file(myFile).read())) wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # # #Additional Checklist Item wikiPage.subsection("#12 Snr and Chisq") wikiPage.subsubsection("Question") wikiPage.putText("Are the SNR and CHISQ time series consistent with our expectations for a gravitational wave?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") # #Put plots SNR and Chi sqr # indexList=fnmatch.filter(wikiFileFinder.get_plotsnrchisq(),"*.html") thumbList=fnmatch.filter(wikiFileFinder.get_plotsnrchisq(),"*_snr-*thumb.png") thumbList.extend(fnmatch.filter(wikiFileFinder.get_plotsnrchisq(),"*_chisq-*thumb.png")) thumbList.sort() indexList=[file2URL.convert(x) for x in indexList] thumbList=[file2URL.convert(x) for x in thumbList] #Two thumb types possible "_thumb.png" or ".thumb.png" imageList=[x.replace("_thumb.png",".png").replace(".thumb.png",".png") for x in thumbList] ifoCount=len(wikiCoinc.sngls) rowLabel={"SNR":1,"CHISQ":2} rowCount=len(rowLabel) colCount=ifoCount if len(indexList) >= 1: snrTable=wikiPage.wikiTable(rowCount+1,colCount+1) for i,sngl in enumerate(wikiCoinc.sngls): myIndex="" for indexFile in indexList: if indexFile.__contains__("_pipe_%s_FOLLOWUP_"%sngl.ifo): myIndex=indexFile if myIndex=="": snrTable.data[0][i+1]=" %s "%sngl.ifo else: snrTable.data[0][i+1]=wikiPage.makeExternalLink(myIndex,sngl.ifo) for col,sngl in enumerate(wikiCoinc.sngls): for row,label in enumerate(rowLabel.keys()): snrTable.data[row+1][0]=label for k,image in enumerate(imageList): if (image.__contains__("_%s-"%label.lower()) \ and image.__contains__("pipe_%s_FOLLOWUP"%sngl.ifo)): snrTable.data[row+1][col+1]=" %s "%(wikiPage.linkedRemoteImage(thumbList[k],thumbList[k])) wikiPage.insertTable(snrTable) else: sys.stdout.write("Warning: SNR and CHISQ plots not found.\n") wikiPage.putText("SNR and CHISQ plots not found.\n") wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # # #Additional Checklist Item wikiPage.subsection("#13 Template bank veto") wikiPage.subsubsection("Question") wikiPage.putText("Is the bank veto value consistent with our expectations for a gravitational wave?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") wikiPage.putText("Plots and pipeline data go here!") wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # # #Additional Checklist Item wikiPage.subsection("#14 Coherent studies") wikiPage.subsubsection("Question") wikiPage.putText("Are the triggers found in multiple interferometers coherent with each other?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") wikiPage.putText("Plots and pipeline data go here!") indexList=fnmatch.filter(wikiFileFinder.get_plotchiatimeseries(),"*.html") if len(indexList) >= 1: myIndex=file2URL.convert(indexList[0]) wikiPage.putText(wikiPage.makeExternalLink(myIndex,\ "%s Coherence Study Results"%(wikiCoinc.ifos))) thumbList=fnmatch.filter(wikiFileFinder.get_plotchiatimeseries(),\ "PLOT_CHIA_%s_snr-squared*thumb.png"%(wikiCoinc.time)) imageList=[x.replace("_thumb.png",".png").replace(".thumb.png",".png") for x in thumbList] rowCount=len(imageList) colCount=1 cohSnrTimeTable=wikiPage.wikiTable(rowCount+1,colCount) cohSnrTimeTable.data[0][0]="%s Coherent SNR Squared Times Series"%(wikiCoinc.ifos) for i,image in enumerate(imageList): cohSnrTimeTable.data[i+1][0]=wikiPage.linkedRemoteImage(image,thumbList[i]) wikiPage.insertTable(cohSnrTimeTable) else: sys.stdout.write("Warning: Coherent plotting jobs not found.\n") wikiPage.putText("Coherent Studies plots not found.\n") wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # # #Additional Checklist Item wikiPage.subsection("#15 Segmentation Stability") wikiPage.subsubsection("Question") wikiPage.putText("Is the candidate stable against changes in segmentation?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") wikiPage.putText("Plots and pipeline data go here!") wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # # #Additional Checklist Item wikiPage.subsection("#16 Calibration Stability") wikiPage.subsubsection("Question") wikiPage.putText("Is the candidate stable against changes in calibration that are consistent with systematic uncertainties?") wikiPage.subsubsection("Answer") wikiPage.putText("Edit Here") wikiPage.subsubsection("Relevant Information") wikiPage.putText("Plots and pipeline data go here!") wikiPage.subsubsection("Investigator Comments") wikiPage.putText("Edit Here") wikiPage.insertHR() # #
fb84ac33aba836b8fcb61075cfaec34ced2846c0 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/5758/fb84ac33aba836b8fcb61075cfaec34ced2846c0/makeCheckListWiki.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2911, 1564, 1098, 12, 13044, 5359, 33, 7036, 16, 13044, 27055, 71, 33, 7036, 16, 13044, 2471, 33, 7036, 16, 768, 22, 1785, 33, 7036, 4672, 3536, 2985, 358, 2911, 279, 866, 1098, 1625, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2911, 1564, 1098, 12, 13044, 5359, 33, 7036, 16, 13044, 27055, 71, 33, 7036, 16, 13044, 2471, 33, 7036, 16, 768, 22, 1785, 33, 7036, 4672, 3536, 2985, 358, 2911, 279, 866, 1098, 1625, ...
log.debug("Received old CSeq %d, ignoring" % cseq)
log.debug("Received old CSeq %d:%d, ignoring" % cseq)
def update_media(self, cseq, to_tag, user_agent, media_list, is_downstream, is_caller_cseq): if self.cseq is None: old_cseq = (0,0) else: old_cseq = self.cseq if is_caller_cseq: cseq = (cseq, old_cseq[1]) if self.to_tag is None and to_tag is not None: self.to_tag = to_tag else: cseq = (old_cseq[0], cseq) if is_downstream: party = "caller" if self.caller_ua is None: self.caller_ua = user_agent else: party = "callee" if self.callee_ua is None: self.callee_ua = user_agent if self.cseq is None or cseq > self.cseq: log.debug("Received new SDP offer") self.streams[cseq] = new_streams = [] if self.cseq is None: old_streams = [] else: old_streams = self.streams[self.cseq] for media_type, media_ip, media_port, media_direction in media_list: stream = None for old_stream in old_streams: old_remote = getattr(old_stream, party).remote_sdp if old_stream.media_type == media_type and ((media_ip == "0.0.0.0" and old_remote[1] == media_port) or old_remote == (media_ip, media_port)): stream = old_stream stream.check_hold(party, media_direction, media_ip) log.debug("Found matching existing stream: %s" % stream) break if stream is None: stream = MediaStream(self, media_type, media_ip, media_port, party, media_direction) log.debug("Added new stream: %s" % stream) new_streams.append(stream) if self.previous_cseq is not None: for stream in self.streams[self.previous_cseq]: if stream not in self.streams[self.cseq] + new_streams: stream.cleanup() self.previous_cseq = self.cseq self.cseq = cseq elif self.cseq == cseq: log.debug("Received updated SDP answer") if self.start_time is None: self.start_time = time() current_streams = self.streams[cseq] if len(media_list) < len(current_streams): for stream in current_streams[len(media_list):]: log.debug("Stream rejected by not being included in the SDP answer: %s" % stream) stream.cleanup("rejected") for stream, (media_type, media_ip, media_port, media_direction) in zip(current_streams, media_list): if stream.media_type != media_type: raise ValueError('Media types do not match: "%s" and "%s"' % (stream.media_type, media_type)) if media_port == 0: log.debug("Stream explicitly rejected: %s" % stream) stream.cleanup("rejected") continue stream.check_hold(party, media_direction, media_ip) party_info = getattr(stream, party) if party_info.remote_sdp is None or party_info.remote_sdp[0] == "0.0.0.0": party_info.remote_sdp = (media_ip, media_port) log.debug("Got initial answer from %s for stream: %s" % (party, stream)) else: if (media_ip == "0.0.0.0" and party_info.remote_sdp[1] != media_port) or party_info.remote_sdp != (media_ip, media_port): stream.reset(party, media_ip, media_port) log.debug("Updated %s for stream: %s" % (party, stream)) else: log.debug("Unchanged stream: %s" % stream) if self.previous_cseq is not None: for stream in [stream for stream in self.streams[self.previous_cseq] if stream not in current_streams]: log.debug("Removing old stream: %s" % stream) stream.cleanup() else: log.debug("Received old CSeq %d, ignoring" % cseq)
0bab9b5a6ac7007070f0e942835ebfdd4193e056 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/3445/0bab9b5a6ac7007070f0e942835ebfdd4193e056/mediacontrol.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1089, 67, 5829, 12, 2890, 16, 276, 5436, 16, 358, 67, 2692, 16, 729, 67, 5629, 16, 3539, 67, 1098, 16, 353, 67, 2378, 3256, 16, 353, 67, 16140, 67, 71, 5436, 4672, 309, 365, 18, 71...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1089, 67, 5829, 12, 2890, 16, 276, 5436, 16, 358, 67, 2692, 16, 729, 67, 5629, 16, 3539, 67, 1098, 16, 353, 67, 2378, 3256, 16, 353, 67, 16140, 67, 71, 5436, 4672, 309, 365, 18, 71...
FunctionBoilerplate = _PyV8.AstFunctionBoilerplateLiteral
SharedFunction = _PyV8.AstSharedFunctionInfoLiteral
def convert(obj): if type(obj) == _PyV8.JSArray: return [convert(v) for v in obj] if type(obj) == _PyV8.JSObject: return dict([[str(k), convert(obj.__getattr__(str(k)))] for k in obj.__members__]) return obj
933d9f258984c67f96da474789be4c8391785e4d /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/5451/933d9f258984c67f96da474789be4c8391785e4d/PyV8.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1765, 12, 2603, 4672, 309, 618, 12, 2603, 13, 422, 389, 9413, 58, 28, 18, 6479, 1076, 30, 327, 306, 6283, 12, 90, 13, 364, 331, 316, 1081, 65, 225, 309, 618, 12, 2603, 13, 422, 389...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 12, 2603, 4672, 309, 618, 12, 2603, 13, 422, 389, 9413, 58, 28, 18, 6479, 1076, 30, 327, 306, 6283, 12, 90, 13, 364, 331, 316, 1081, 65, 225, 309, 618, 12, 2603, 13, 422, 389...
if lop._is_atomic():
if rop._is_atomic():
def _repr_(self, simplify=True): """ TESTS: sage: a = (1-1/r)^(-1); a 1/(1 - (1/r)) sage: a.derivative(r) -1/((1 - (1/r))^2*r^2)
39ed1b976a31ff07cd13588ced18700bc9790c03 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9417/39ed1b976a31ff07cd13588ced18700bc9790c03/calculus.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 12715, 67, 12, 2890, 16, 16499, 33, 5510, 4672, 3536, 22130, 55, 30, 272, 410, 30, 279, 273, 261, 21, 17, 21, 19, 86, 13, 66, 19236, 21, 1769, 279, 404, 19, 12, 21, 300, 261, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 12715, 67, 12, 2890, 16, 16499, 33, 5510, 4672, 3536, 22130, 55, 30, 272, 410, 30, 279, 273, 261, 21, 17, 21, 19, 86, 13, 66, 19236, 21, 1769, 279, 404, 19, 12, 21, 300, 261, ...
-1
(-1)^(1/3)
def _complex_double_(self, field): """ EXAMPLES: sage: CDF((-1)^(1/3)) 0.5 + 0.866025403784*I
003c49f0f0b524f324f91b299f1134cce5502ccf /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9890/003c49f0f0b524f324f91b299f1134cce5502ccf/calculus.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 14259, 67, 9056, 67, 12, 2890, 16, 652, 4672, 3536, 5675, 8900, 11386, 30, 272, 410, 30, 31971, 12443, 17, 21, 13, 29020, 21, 19, 23, 3719, 374, 18, 25, 397, 374, 18, 5292, 4848...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 14259, 67, 9056, 67, 12, 2890, 16, 652, 4672, 3536, 5675, 8900, 11386, 30, 272, 410, 30, 31971, 12443, 17, 21, 13, 29020, 21, 19, 23, 3719, 374, 18, 25, 397, 374, 18, 5292, 4848...
- prec -- integer (deafault: 53), *bits* of precision - a -- integer, as for kloosterman_sum - b -- integer, as for kloosterman_sum.
- ``prec`` -- integer (default: 53), *bits* of precision - ``a`` -- integer, as for :meth:`.kloosterman_sum` - ``b`` -- integer, as for :meth:`.kloosterman_sum`.
def kloosterman_sum_numerical(self, prec=53, a=1,b=0): r""" Return the Kloosterman sum associated to this Dirichlet character as an approximate complex number with prec bits of precision.
e7cb080b1d244c4536831d929cef63ec4f84e355 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9417/e7cb080b1d244c4536831d929cef63ec4f84e355/dirichlet.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 417, 383, 669, 29650, 67, 1364, 67, 2107, 10882, 12, 2890, 16, 13382, 33, 8643, 16, 279, 33, 21, 16, 70, 33, 20, 4672, 436, 8395, 2000, 326, 1475, 383, 669, 29650, 2142, 3627, 358, 3...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 417, 383, 669, 29650, 67, 1364, 67, 2107, 10882, 12, 2890, 16, 13382, 33, 8643, 16, 279, 33, 21, 16, 70, 33, 20, 4672, 436, 8395, 2000, 326, 1475, 383, 669, 29650, 2142, 3627, 358, 3...
kill(self.accept_incoming_job)
self.accept_incoming_job.kill()
def stop_accept_incoming(self): if self.accept_incoming_job: kill(self.accept_incoming_job) self.accept_incoming_job = None
86486162e8822068c3835c02e4ea7cd8afd6a0ba /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/3449/86486162e8822068c3835c02e4ea7cd8afd6a0ba/chatroom.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2132, 67, 9436, 67, 31033, 12, 2890, 4672, 309, 365, 18, 9436, 67, 31033, 67, 4688, 30, 365, 18, 9436, 67, 31033, 67, 4688, 18, 16418, 1435, 365, 18, 9436, 67, 31033, 67, 4688, 273, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2132, 67, 9436, 67, 31033, 12, 2890, 4672, 309, 365, 18, 9436, 67, 31033, 67, 4688, 30, 365, 18, 9436, 67, 31033, 67, 4688, 18, 16418, 1435, 365, 18, 9436, 67, 31033, 67, 4688, 273, ...
It will also set `request.mimetype` so the handler has an easy way to tell what's going on. `request.mimetype` will always be None for multipart form data (what your browser sends.)
It will also set `request.content_type` so the handler has an easy way to tell what's going on. `request.content_type` will always be None for form-encoded and/or multipart form data (what your browser sends.)
def translate(self): """ Will look at the `Content-type` sent by the client, and maybe deserialize the contents into the format they sent. This will work for JSON, YAML, XML and Pickle. Since the data is not just key-value (and maybe just a list), the data will be placed on `request.data` instead, and the handler will have to read from there. It will also set `request.mimetype` so the handler has an easy way to tell what's going on. `request.mimetype` will always be None for multipart form data (what your browser sends.) """ ctype = self.content_type() self.request.content_type = ctype if not self.is_multipart() and ctype: loadee = self.loader_for_type(ctype) try: self.request.data = loadee(self.request.raw_post_data) # Reset both POST and PUT from request, as its # misleading having their presence around. self.request.POST = self.request.PUT = dict() except TypeError: return rc.BAD_REQUEST # TODO: Handle this in super except Exception, e: raise return self.request
1bbdaa1fada56f4f56bd25baddce55c6d9aacf98 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/11777/1bbdaa1fada56f4f56bd25baddce55c6d9aacf98/utils.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4204, 12, 2890, 4672, 3536, 9980, 2324, 622, 326, 1375, 1350, 17, 723, 68, 3271, 635, 326, 1004, 16, 471, 6944, 7673, 326, 2939, 1368, 326, 740, 2898, 3271, 18, 1220, 903, 1440, 364, 1...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 4204, 12, 2890, 4672, 3536, 9980, 2324, 622, 326, 1375, 1350, 17, 723, 68, 3271, 635, 326, 1004, 16, 471, 6944, 7673, 326, 2939, 1368, 326, 740, 2898, 3271, 18, 1220, 903, 1440, 364, 1...
self.commandprefix = options.get('commandprefix', 'C')
self.commandprefix = options.get('commandprefix', 'PY')
def __init__(self, **options): Formatter.__init__(self, **options) self.docclass = options.get('docclass', 'article') self.preamble = options.get('preamble', '') self.linenos = get_bool_opt(options, 'linenos', False) self.linenostart = abs(get_int_opt(options, 'linenostart', 1)) self.linenostep = abs(get_int_opt(options, 'linenostep', 1)) self.verboptions = options.get('verboptions', '') self.nobackground = get_bool_opt(options, 'nobackground', False) self.commandprefix = options.get('commandprefix', 'C')
ebc861ce01aa5ebdbefb67409092fe222e9922b7 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/2885/ebc861ce01aa5ebdbefb67409092fe222e9922b7/latex.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 2826, 2116, 4672, 14924, 16186, 2738, 972, 12, 2890, 16, 2826, 2116, 13, 365, 18, 2434, 1106, 273, 702, 18, 588, 2668, 2434, 1106, 2187, 296, 11480, 6134, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2738, 972, 12, 2890, 16, 2826, 2116, 4672, 14924, 16186, 2738, 972, 12, 2890, 16, 2826, 2116, 13, 365, 18, 2434, 1106, 273, 702, 18, 588, 2668, 2434, 1106, 2187, 296, 11480, 6134, ...
def set_background_color (self, color): """Set the background color of the titlebar""" self.modify_bg (gtk.STATE_NORMAL, color) self._ebox.modify_bg (gtk.STATE_NORMAL, color) def set_foreground_color (self, color): """Set the foreground color of the titlebar""" self._title.modify_fg (gtk.STATE_NORMAL, color) self._group.modify_fg (gtk.STATE_NORMAL, color)
def get_terminal_title (self): """Return the text showin in the titlebar""" return (self._termtext)
58e20f08682147d5bb232d4fab88ecdede542a88 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/1032/58e20f08682147d5bb232d4fab88ecdede542a88/terminatorterm.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 15979, 67, 2649, 261, 2890, 4672, 3536, 990, 326, 977, 2405, 267, 316, 326, 2077, 3215, 8395, 327, 261, 2890, 6315, 6408, 955, 13, 2, 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, 0, 0, 0, 0, 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, 15979, 67, 2649, 261, 2890, 4672, 3536, 990, 326, 977, 2405, 267, 316, 326, 2077, 3215, 8395, 327, 261, 2890, 6315, 6408, 955, 13, 2, -100, -100, -100, -100, -100, -100, -100, ...
pl_book_ids = [self.book_by_id(i.getAttribute('id')).db_id for i in pl.childNodes if hasattr(i, 'getAttribute')]
pl_book_ids = [getattr(self.book_by_id(i), 'db_id', None) for i in db_ids]
def reorder_playlists(self): for title in self.tag_order.keys(): pl = self.playlist_by_title(title) if not pl: continue db_ids = [i.getAttribute('id') for i in pl.childNodes if hasattr(i, 'getAttribute')] pl_book_ids = [self.book_by_id(i.getAttribute('id')).db_id for i in pl.childNodes if hasattr(i, 'getAttribute')] map = {} for i, j in zip(pl_book_ids, db_ids): map[i] = j pl_book_ids = [i for i in pl_book_ids if i is not None] ordered_ids = [i for i in self.tag_order[title] if i in pl_book_ids]
5fa32e48500cd3d6754f312a6a22eedc89c862dc /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9125/5fa32e48500cd3d6754f312a6a22eedc89c862dc/books.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 19427, 67, 1601, 9772, 12, 2890, 4672, 364, 2077, 316, 365, 18, 2692, 67, 1019, 18, 2452, 13332, 886, 273, 365, 18, 1601, 1098, 67, 1637, 67, 2649, 12, 2649, 13, 309, 486, 886, 30, 1...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 19427, 67, 1601, 9772, 12, 2890, 4672, 364, 2077, 316, 365, 18, 2692, 67, 1019, 18, 2452, 13332, 886, 273, 365, 18, 1601, 1098, 67, 1637, 67, 2649, 12, 2649, 13, 309, 486, 886, 30, 1...
handleSectionedFile(['profiles', 'flavors.zcml'],
handleSectionedFile(['flavors.zcml'],
def generatePackageFlavorsZcml(self,package): """ Generate flavors.zcml for packages if it contains flavors """
2e216827ccd16bffcbf032c55a7c689c98424920 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/11941/2e216827ccd16bffcbf032c55a7c689c98424920/ArchetypesGenerator.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2103, 2261, 2340, 842, 1383, 62, 71, 781, 12, 2890, 16, 5610, 4672, 3536, 6654, 31227, 1383, 18, 94, 71, 781, 364, 5907, 309, 518, 1914, 31227, 1383, 3536, 2, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2103, 2261, 2340, 842, 1383, 62, 71, 781, 12, 2890, 16, 5610, 4672, 3536, 6654, 31227, 1383, 18, 94, 71, 781, 364, 5907, 309, 518, 1914, 31227, 1383, 3536, 2, -100, -100, -100, -100, -...
tabs.set_tab(i, pango.TAB_LEFT, pos*char_width+5*scale)
tabs.set_tab(i, pango.TAB_LEFT, pos*char_width+5*int(scale*pango.SCALE))
def maketabs(self, rawtabs): char_width = strwidth(' ') scale = get_scale() tabs = pango.TabArray(len(rawtabs), positions_in_pixels=False) for i in range(tabs.get_size()): pos = rawtabs[i] tabs.set_tab(i, pango.TAB_LEFT, pos*char_width+5*scale) return tabs
850bcc53dd98fad4593cdaa467f4c9305e2e4710 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/14305/850bcc53dd98fad4593cdaa467f4c9305e2e4710/articleformat.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 29796, 278, 5113, 12, 2890, 16, 1831, 16056, 4672, 1149, 67, 2819, 273, 609, 2819, 2668, 8624, 3159, 273, 336, 67, 5864, 1435, 10920, 273, 293, 6399, 18, 5661, 1076, 12, 1897, 12, 1899, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 29796, 278, 5113, 12, 2890, 16, 1831, 16056, 4672, 1149, 67, 2819, 273, 609, 2819, 2668, 8624, 3159, 273, 336, 67, 5864, 1435, 10920, 273, 293, 6399, 18, 5661, 1076, 12, 1897, 12, 1899, ...
print u'('+futureDoc.title.encode('utf-8')+u')'
print '('+futureDoc.title.encode('utf-8')+')'
def indexDocument(self, futureDoc): futureDoc.file_state=FileInfo.CREATED_FILE_STATE if self.verbose: print "Requesting indexation of %s" % futureDoc.filename, try: futureDoc.title = removeControlChar(futureDoc.title) futureDoc.text = removeControlChar(futureDoc.text) if self.verbose: print u'('+futureDoc.title.encode('utf-8')+u')' self.serverProxy.indexDocument(self.cnxId, futureDoc)
70ddb7597f46e9dd1f11ec876b4cd97ca8af0f75 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2259/70ddb7597f46e9dd1f11ec876b4cd97ca8af0f75/indexer.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 770, 2519, 12, 2890, 16, 3563, 1759, 4672, 3563, 1759, 18, 768, 67, 2019, 33, 11995, 18, 18546, 67, 3776, 67, 7998, 309, 365, 18, 11369, 30, 1172, 315, 691, 310, 770, 367, 434, 738, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 770, 2519, 12, 2890, 16, 3563, 1759, 4672, 3563, 1759, 18, 768, 67, 2019, 33, 11995, 18, 18546, 67, 3776, 67, 7998, 309, 365, 18, 11369, 30, 1172, 315, 691, 310, 770, 367, 434, 738, ...
process = process
process = process, livetime_program = { "StringCusp": "StringSearch", "excesspower": "lalapps_power", "omega": None }[search]
si_c_n_def = si_c_n_def,
1126ecd32ca491514cbed02a89dd809841dce610 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/5758/1126ecd32ca491514cbed02a89dd809841dce610/ligolw_binjfind.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 7533, 67, 71, 67, 82, 67, 536, 273, 7533, 67, 71, 67, 82, 67, 536, 16, 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,...
[ 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 7533, 67, 71, 67, 82, 67, 536, 273, 7533, 67, 71, 67, 82, 67, 536, 16, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
base = base + ', qop=auth, nc=%s, cnonce="%s"' % (ncvalue, cnonce)
base += ', qop=auth, nc=%s, cnonce="%s"' % (ncvalue, cnonce)
def get_authorization(self, req, chal): try: realm = chal['realm'] nonce = chal['nonce'] qop = chal.get('qop') algorithm = chal.get('algorithm', 'MD5') # mod_digest doesn't send an opaque, even though it isn't # supposed to be optional opaque = chal.get('opaque', None) except KeyError: return None
cb4a782cca4bbf9b3c7ec6737b954e117ecd3942 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8125/cb4a782cca4bbf9b3c7ec6737b954e117ecd3942/urllib2.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 12218, 12, 2890, 16, 1111, 16, 462, 287, 4672, 775, 30, 11319, 273, 462, 287, 3292, 24056, 3546, 7448, 273, 462, 287, 3292, 12824, 3546, 1043, 556, 273, 462, 287, 18, 588, 266...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 336, 67, 12218, 12, 2890, 16, 1111, 16, 462, 287, 4672, 775, 30, 11319, 273, 462, 287, 3292, 24056, 3546, 7448, 273, 462, 287, 3292, 12824, 3546, 1043, 556, 273, 462, 287, 18, 588, 266...
dates['single'] = []
single = []
def temporal_reference(self): dates = {} try: begin = self.xpath.xpathEval('//gmd:EX_Extent/gmd:temporalElement/gmd:EX_TemporalExtent//gml:beginPosition')[0].content.strip() end = self.xpath.xpathEval('//gmd:EX_Extent/gmd:temporalElement/gmd:EX_TemporalExtent//gml:endPosition')[0].content.strip() except IndexError: dates['range'] = [] else: try: dates['range'] = [self.xsDate2pyDatetime(begin), self.xsDate2pyDatetime(end)] except ValueError: pass
331e5f53addc163347ff857018ae6bd4813ba4ad /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12122/331e5f53addc163347ff857018ae6bd4813ba4ad/dws.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 15262, 67, 6180, 12, 2890, 4672, 7811, 273, 2618, 775, 30, 2376, 273, 365, 18, 18644, 18, 18644, 13904, 2668, 759, 75, 1264, 30, 2294, 67, 17639, 19, 75, 1264, 30, 874, 12036, 1046, 19...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 15262, 67, 6180, 12, 2890, 4672, 7811, 273, 2618, 775, 30, 2376, 273, 365, 18, 18644, 18, 18644, 13904, 2668, 759, 75, 1264, 30, 2294, 67, 17639, 19, 75, 1264, 30, 874, 12036, 1046, 19...
os.rename(nfsPathOf(item.getOldFilename(), item.getNewFilename()))
os.rename(nfsPathOf(item.getOldFilename()), item.getNewFilename()))
def run(self): try: while not tsumufs.unmounted.isSet(): self._debug('TsumuFS not unmounted yet.')
61bb077a9217451f75c82f4bc03b4badb92fc4fa /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/5149/61bb077a9217451f75c82f4bc03b4badb92fc4fa/syncthread.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1086, 12, 2890, 4672, 775, 30, 1323, 486, 268, 1364, 696, 87, 18, 318, 4778, 329, 18, 291, 694, 13332, 365, 6315, 4148, 2668, 56, 1364, 89, 4931, 486, 25670, 329, 4671, 1093, 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, 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, 12, 2890, 4672, 775, 30, 1323, 486, 268, 1364, 696, 87, 18, 318, 4778, 329, 18, 291, 694, 13332, 365, 6315, 4148, 2668, 56, 1364, 89, 4931, 486, 25670, 329, 4671, 1093, 13, 2, ...
log.info("Installing %s documentaion from zip file.\n" % INFO['name'])
log.info("Installing %s documentation from zip file.\n" % INFO['name'])
def generate_docs(): """ If sphinx is installed, generate docs. """ doc_dir = os.path.join(os.path.abspath(os.path.dirname(__file__)), 'docs') source_dir = os.path.join(doc_dir, 'source') html_zip = os.path.join(doc_dir, 'html.zip') dest_dir = doc_dir required_sphinx_version = "0.4.1" sphinx_installed = False try: require("Sphinx>=%s" % required_sphinx_version) sphinx_installed = True except (DistributionNotFound, VersionConflict): log.warn('Sphinx install of version %s could not be verified.' ' Trying simple import...' % required_sphinx_version) try: import sphinx if parse_version(sphinx.__version__) < parse_version( required_sphinx_version): log.error("Sphinx version must be >=" + \ "%s." % required_sphinx_version) else: sphinx_installed = True except ImportError: log.error("Sphnix install not found.") if sphinx_installed: log.info("Generating %s documentation..." % INFO['name']) docsrc = source_dir target = dest_dir try: build = HtmlBuild() build.start({ 'commit_message': None, 'doc_source': docsrc, 'preserve_temp': True, 'subversion': False, 'target': target, 'verbose': True, 'versioned': False }, []) del build except: log.error("The documentation generation failed. Falling back to " "the zip file.") # Unzip the docs into the 'html' folder. unzip_html_docs(html_zip, doc_dir) else: # Unzip the docs into the 'html' folder. log.info("Installing %s documentaion from zip file.\n" % INFO['name']) unzip_html_docs(html_zip, doc_dir)
a4cb0d06c079213094c0fd656a2a68410914b525 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/13168/a4cb0d06c079213094c0fd656a2a68410914b525/setup.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2103, 67, 8532, 13332, 3536, 971, 26296, 353, 5876, 16, 2103, 3270, 18, 3536, 997, 67, 1214, 273, 1140, 18, 803, 18, 5701, 12, 538, 18, 803, 18, 5113, 803, 12, 538, 18, 803, 18, 1228...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 67, 8532, 13332, 3536, 971, 26296, 353, 5876, 16, 2103, 3270, 18, 3536, 997, 67, 1214, 273, 1140, 18, 803, 18, 5701, 12, 538, 18, 803, 18, 5113, 803, 12, 538, 18, 803, 18, 1228...
prevline = EMPTYSTRING.join(outline) linelen = 0 outline = []
thisline = EMPTYSTRING.join(outline) while len(thisline) > MAXLINESIZE: write(thisline[:MAXLINESIZE-1], lineEnd='=\n') thisline = thisline[MAXLINESIZE-1:] prevline = thisline
def write(s, output=output, lineEnd='\n'): # RFC 1521 requires that the line ending in a space or tab must have # that trailing character encoded. if s and s[-1:] in ' \t': output.write(s[:-1] + quote(s[-1]) + lineEnd) else: output.write(s + lineEnd)
dac67ac8bf994b336748283fa25602639c6a9bf4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8546/dac67ac8bf994b336748283fa25602639c6a9bf4/quopri.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1045, 12, 87, 16, 876, 33, 2844, 16, 980, 1638, 2218, 64, 82, 11, 4672, 468, 8372, 4711, 5340, 4991, 716, 326, 980, 11463, 316, 279, 3476, 578, 3246, 1297, 1240, 468, 716, 7341, 3351, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 12, 87, 16, 876, 33, 2844, 16, 980, 1638, 2218, 64, 82, 11, 4672, 468, 8372, 4711, 5340, 4991, 716, 326, 980, 11463, 316, 279, 3476, 578, 3246, 1297, 1240, 468, 716, 7341, 3351, ...
sys.stderr.write('%s: %s, line %d, column %d\n' % (e[0], filename, e[1][0], e[1][1]))
print >> sys.stderr, '%s: %s, line %d, column %d' % ( e[0], filename, e[1][0], e[1][1])
def main(): global default_keywords try: opts, args = getopt.getopt( sys.argv[1:], 'ad:DEhk:Kno:p:S:Vvw:x:', ['extract-all', 'default-domain', 'escape', 'help', 'keyword=', 'no-default-keywords', 'add-location', 'no-location', 'output=', 'output-dir=', 'style=', 'verbose', 'version', 'width=', 'exclude-file=', 'docstrings', ]) except getopt.error, msg: usage(1, msg) # for holding option values class Options: # constants GNU = 1 SOLARIS = 2 # defaults extractall = 0 # FIXME: currently this option has no effect at all. escape = 0 keywords = [] outpath = '' outfile = 'messages.pot' writelocations = 1 locationstyle = GNU verbose = 0 width = 78 excludefilename = '' docstrings = 0 options = Options() locations = {'gnu' : options.GNU, 'solaris' : options.SOLARIS, } # parse options for opt, arg in opts: if opt in ('-h', '--help'): usage(0) elif opt in ('-a', '--extract-all'): options.extractall = 1 elif opt in ('-d', '--default-domain'): options.outfile = arg + '.pot' elif opt in ('-E', '--escape'): options.escape = 1 elif opt in ('-D', '--docstrings'): options.docstrings = 1 elif opt in ('-k', '--keyword'): options.keywords.append(arg) elif opt in ('-K', '--no-default-keywords'): default_keywords = [] elif opt in ('-n', '--add-location'): options.writelocations = 1 elif opt in ('--no-location',): options.writelocations = 0 elif opt in ('-S', '--style'): options.locationstyle = locations.get(arg.lower()) if options.locationstyle is None: usage(1, _('Invalid value for --style: %s') % arg) elif opt in ('-o', '--output'): options.outfile = arg elif opt in ('-p', '--output-dir'): options.outpath = arg elif opt in ('-v', '--verbose'): options.verbose = 1 elif opt in ('-V', '--version'): print _('pygettext.py (xgettext for Python) %s') % __version__ sys.exit(0) elif opt in ('-w', '--width'): try: options.width = int(arg) except ValueError: usage(1, _('--width argument must be an integer: %s') % arg) elif opt in ('-x', '--exclude-file'): options.excludefilename = arg # calculate escapes make_escapes(options.escape) # calculate all keywords options.keywords.extend(default_keywords) # initialize list of strings to exclude if options.excludefilename: try: fp = open(options.excludefilename) options.toexclude = fp.readlines() fp.close() except IOError: sys.stderr.write(_("Can't read --exclude-file: %s") % options.excludefilename) sys.exit(1) else: options.toexclude = [] # slurp through all the files eater = TokenEater(options) for filename in args: if filename == '-': if options.verbose: print _('Reading standard input') fp = sys.stdin closep = 0 else: if options.verbose: print _('Working on %s') % filename fp = open(filename) closep = 1 try: eater.set_filename(filename) try: tokenize.tokenize(fp.readline, eater) except tokenize.TokenError, e: sys.stderr.write('%s: %s, line %d, column %d\n' % (e[0], filename, e[1][0], e[1][1])) finally: if closep: fp.close() # write the output if options.outfile == '-': fp = sys.stdout closep = 0 else: if options.outpath: options.outfile = os.path.join(options.outpath, options.outfile) fp = open(options.outfile, 'w') closep = 1 try: eater.write(fp) finally: if closep: fp.close()
a9d8d69b67996254705aac34cd306812abf1c8c6 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12029/a9d8d69b67996254705aac34cd306812abf1c8c6/pygettext.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2774, 13332, 2552, 805, 67, 11771, 775, 30, 1500, 16, 833, 273, 336, 3838, 18, 588, 3838, 12, 2589, 18, 19485, 63, 21, 30, 6487, 296, 361, 30, 1639, 76, 79, 30, 47, 2135, 30, 84, 3...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2552, 805, 67, 11771, 775, 30, 1500, 16, 833, 273, 336, 3838, 18, 588, 3838, 12, 2589, 18, 19485, 63, 21, 30, 6487, 296, 361, 30, 1639, 76, 79, 30, 47, 2135, 30, 84, 3...
ticket.values = ticket._old
ticket.values.update(ticket._old)
def _validate_ticket(self, req, ticket): valid = True resource = ticket.resource
2c59cb591e28c02c4b63c2d157197fd9bc28dc5a /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/2831/2c59cb591e28c02c4b63c2d157197fd9bc28dc5a/web_ui.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 5662, 67, 16282, 12, 2890, 16, 1111, 16, 9322, 4672, 923, 273, 1053, 1058, 273, 9322, 18, 3146, 2, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 5662, 67, 16282, 12, 2890, 16, 1111, 16, 9322, 4672, 923, 273, 1053, 1058, 273, 9322, 18, 3146, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
r = self._httpreq_json(service, 'POST', form=dict(query=qstr))
r = self._httpreq_json(service, 'POST', form=dict(query=qstr), headers=headers)
def mqlreaditer(self, sq, asof=None): """read a structure query.""" cursor = True service = '/api/service/mqlread' if isinstance(sq, (tuple, list)): if len(sq) > 1: raise MetawebError("You cannot ask mqlreaditer a query in the form: [{}, {}, ...], just [{}] or {}") sq = sq[0] while 1: subq = dict(query=[sq], cursor=cursor, escape=False) if asof: subq['as_of_time'] = asof qstr = json.dumps(subq, separators=SEPARATORS) r = self._httpreq_json(service, 'POST', form=dict(query=qstr)) for item in self._mqlresult(r): yield item if r['cursor']: cursor = r['cursor'] self.log.info('CONTINUING with %s', cursor) else: return
6947e2e18a5eb9fc8d84060a388f51d20c20d28d /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/11603/6947e2e18a5eb9fc8d84060a388f51d20c20d28d/session.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 312, 1217, 896, 2165, 12, 2890, 16, 4744, 16, 487, 792, 33, 7036, 4672, 3536, 896, 279, 3695, 843, 12123, 225, 3347, 273, 1053, 1156, 273, 1173, 2425, 19, 3278, 19, 81, 1217, 896, 11, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 312, 1217, 896, 2165, 12, 2890, 16, 4744, 16, 487, 792, 33, 7036, 4672, 3536, 896, 279, 3695, 843, 12123, 225, 3347, 273, 1053, 1156, 273, 1173, 2425, 19, 3278, 19, 81, 1217, 896, 11, ...
raise errors.BlockDeviceError("DRBD disk not attached in re-attach net")
_ThrowError("drbd%d: disk not attached in re-attach net", self._aminor)
def DisconnectNet(self): """Removes network configuration.
82463074c0c011a83cf2239affbdb44cb2940801 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/7542/82463074c0c011a83cf2239affbdb44cb2940801/bdev.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 23957, 7308, 12, 2890, 4672, 3536, 6220, 2483, 1664, 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, ...
[ 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 23957, 7308, 12, 2890, 4672, 3536, 6220, 2483, 1664, 18, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -1...
'''%(__version__,)
'''
def opts_and_exts(name, op, exts): opts = ' '.join(options(op)) exts.extend([i.upper() for i in exts]) exts='|'.join(exts) return '_'+name+'()'+\
51c08484ef254c8256116e024f16c50db46e4ca6 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9125/51c08484ef254c8256116e024f16c50db46e4ca6/linux.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1500, 67, 464, 67, 408, 87, 12, 529, 16, 1061, 16, 20793, 4672, 1500, 273, 296, 2418, 5701, 12, 2116, 12, 556, 3719, 20793, 18, 14313, 3816, 77, 18, 5797, 1435, 364, 277, 316, 20793, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1500, 67, 464, 67, 408, 87, 12, 529, 16, 1061, 16, 20793, 4672, 1500, 273, 296, 2418, 5701, 12, 2116, 12, 556, 3719, 20793, 18, 14313, 3816, 77, 18, 5797, 1435, 364, 277, 316, 20793, ...
If `i == 0` a plaintext must be provided, if `i == n` a ciphertext must be provided.
If ``i == 0`` a plaintext must be provided, if ``i == n`` a ciphertext must be provided.
def round_polynomials(self, i, plaintext=None, ciphertext=None): r""" Return list of polynomials for a given round `i`. If `i == 0` a plaintext must be provided, if `i == n` a ciphertext must be provided. INPUT: - ``i`` - round number - ``plaintext`` - optional plaintext (mandatory in first round) - ``ciphertext`` - optional ciphertext (mandatory in last round) OUTPUT: MPolynomialRoundSystem EXAMPLE:: sage: sr = mq.SR(1, 1, 1, 4) sage: k = sr.base_ring() sage: p = [k.random_element() for _ in range(sr.r*sr.c)] sage: sr.round_polynomials(0, plaintext=p) [w100 + k000 + (a^2 + 1), w101 + k001 + (a), w102 + k002 + (a^2), w103 + k003 + (a + 1)] """ r = self._r c = self._c e = self._e n = self._n R = self.R
d2531bfd55e8dc010cd9c1e87cc62d2c514562d4 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9890/d2531bfd55e8dc010cd9c1e87cc62d2c514562d4/sr.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3643, 67, 3915, 13602, 87, 12, 2890, 16, 277, 16, 11917, 33, 7036, 16, 12657, 33, 7036, 4672, 436, 8395, 2000, 666, 434, 16991, 87, 364, 279, 864, 3643, 1375, 77, 8338, 225, 971, 12176...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3643, 67, 3915, 13602, 87, 12, 2890, 16, 277, 16, 11917, 33, 7036, 16, 12657, 33, 7036, 4672, 436, 8395, 2000, 666, 434, 16991, 87, 364, 279, 864, 3643, 1375, 77, 8338, 225, 971, 12176...
self.assertEqual(im.get_type(), 'audio/fish')
self.assertEqual(au.get_type(), 'audio/fish')
def checkSetMinor(self): au = MIMEAudio(self._audiodata, 'fish') self.assertEqual(im.get_type(), 'audio/fish')
7e427b776e6c4eb5846cbaa789c696759af1678d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3187/7e427b776e6c4eb5846cbaa789c696759af1678d/test_email.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 866, 694, 19549, 12, 2890, 4672, 20309, 273, 13195, 12719, 12, 2890, 6315, 24901, 2386, 396, 16, 296, 22905, 6134, 365, 18, 11231, 5812, 12, 381, 18, 588, 67, 723, 9334, 296, 11509, 19, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 866, 694, 19549, 12, 2890, 4672, 20309, 273, 13195, 12719, 12, 2890, 6315, 24901, 2386, 396, 16, 296, 22905, 6134, 365, 18, 11231, 5812, 12, 381, 18, 588, 67, 723, 9334, 296, 11509, 19, ...
Torsion quotient of 3-d lattice N
Quotient with torsion of 3-d lattice N
def _repr_(self): r""" Return a string representation of ``self``.
eb8c1be62ed520b8675c215dfc299aab1d8d35bd /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9890/eb8c1be62ed520b8675c215dfc299aab1d8d35bd/toric_lattice.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 12715, 67, 12, 2890, 4672, 436, 8395, 2000, 279, 533, 4335, 434, 12176, 2890, 68, 8338, 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, ...
[ 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 12715, 67, 12, 2890, 4672, 436, 8395, 2000, 279, 533, 4335, 434, 12176, 2890, 68, 8338, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
global number_sites, number_keys, number_persons, number_nodes, number_slices
global number_keys, number_sites, number_persons, number_nodes, number_slices
def big(): global number_sites, number_keys, number_persons, number_nodes, number_slices normal() (number_sites,number_keys,number_persons,number_nodes,number_slices) = [ big_factor * x for x in (number_sites,number_keys,number_persons,number_nodes,number_slices)]
e12b56d5b3d0bf32ad1d930f36276184dea09d45 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/7598/e12b56d5b3d0bf32ad1d930f36276184dea09d45/TestPeers.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 5446, 13332, 2552, 1300, 67, 2452, 16, 1300, 67, 12180, 16, 1300, 67, 12479, 87, 16, 1300, 67, 4690, 16, 1300, 67, 21562, 2212, 1435, 261, 2696, 67, 12180, 16, 2696, 67, 2452, 16, 2696...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 5446, 13332, 2552, 1300, 67, 2452, 16, 1300, 67, 12180, 16, 1300, 67, 12479, 87, 16, 1300, 67, 4690, 16, 1300, 67, 21562, 2212, 1435, 261, 2696, 67, 12180, 16, 2696, 67, 2452, 16, 2696...
if item.text not in self.string_dict: self.string_patterns.append(item) self.string_dict[item.text] = item self._need_commit = True else: text = makePrintable(item.text, "ASCII", to_unicode=True)
if item.text in self.string_dict: return self.string_patterns.append(item) self.string_dict[item.text] = item self._need_commit = True
def addString(self, magic, user=None): item = StringPattern(magic, user) if item.text not in self.string_dict: self.string_patterns.append(item) self.string_dict[item.text] = item self._need_commit = True else: text = makePrintable(item.text, "ASCII", to_unicode=True) #warning("Skip duplicate string pattern (%s)" % text)
9f838e085ed2b42ee9d6b3325d65f3fe55b8061e /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9327/9f838e085ed2b42ee9d6b3325d65f3fe55b8061e/pattern.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 527, 780, 12, 2890, 16, 8146, 16, 729, 33, 7036, 4672, 761, 273, 514, 3234, 12, 11179, 16, 729, 13, 309, 761, 18, 955, 486, 316, 365, 18, 1080, 67, 1576, 30, 365, 18, 1080, 67, 133...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 527, 780, 12, 2890, 16, 8146, 16, 729, 33, 7036, 4672, 761, 273, 514, 3234, 12, 11179, 16, 729, 13, 309, 761, 18, 955, 486, 316, 365, 18, 1080, 67, 1576, 30, 365, 18, 1080, 67, 133...
self.tshack = 0
self.timeshift_enabled = 0 self.__seekableStatusChanged() def activateTimeshiftEnd(self): ts = self.getTimeshift() if ts is None: return if ts.isTimeshiftActive(): print "!! activate timeshift called - but shouldn't this be a normal pause?" self.pauseService() else: self.setSeekState(self.SEEK_STATE_PLAY) ts.activateTimeshift() def activateTimeshiftEndAndPause(self): state = self.seekstate self.activateTimeshiftEnd() print "now, pauseService" if state == self.SEEK_STATE_PLAY: print "is PLAYING, start pause timer" self.ts_pause_timer.start(200, 1) else: print "unpause" self.unPauseService() def __seekableStatusChanged(self): enabled = False print "self.isSeekable", self.isSeekable() print "self.timeshift_enabled", self.timeshift_enabled if not self.isSeekable() and self.timeshift_enabled: enabled = True print "timeshift activate:", enabled self["TimeshiftActivateActions"].setEnabled(enabled)
def stopTimeshift(self): print "disable timeshift" ts = self.getTimeshift() if ts is None: return ts.stopTimeshift() self.tshack = 0
24298d4fbc8394d154053cc4d6c4bdfbd50e4233 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/6652/24298d4fbc8394d154053cc4d6c4bdfbd50e4233/InfoBarGenerics.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2132, 10694, 76, 2136, 12, 2890, 4672, 1172, 315, 8394, 4124, 76, 2136, 6, 3742, 273, 365, 18, 588, 10694, 76, 2136, 1435, 309, 3742, 353, 599, 30, 327, 3742, 18, 5681, 10694, 76, 2136...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2132, 10694, 76, 2136, 12, 2890, 4672, 1172, 315, 8394, 4124, 76, 2136, 6, 3742, 273, 365, 18, 588, 10694, 76, 2136, 1435, 309, 3742, 353, 599, 30, 327, 3742, 18, 5681, 10694, 76, 2136...
os.path.exists(downloaded_pkg) and os.remove(downloaded_pkg)
self._ClearLocalDownloadState(downloaded_pkg)
def testDeclineDangerousDownload(self): """Verify that we can decline dangerous downloads""" file_path = self._GetDangerousDownload() file_url = self.GetFileURLForPath(file_path) downloaded_pkg = os.path.join(self.GetDownloadDirectory().value(), os.path.basename(file_path)) os.path.exists(downloaded_pkg) and os.remove(downloaded_pkg)
f9dc9fce765fa4077269f1ad3dee544fc6c3dcdf /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9392/f9dc9fce765fa4077269f1ad3dee544fc6c3dcdf/downloads.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 1799, 1369, 40, 11455, 1481, 7109, 12, 2890, 4672, 3536, 8097, 716, 732, 848, 3496, 558, 27308, 1481, 23011, 8395, 585, 67, 803, 273, 365, 6315, 967, 40, 11455, 1481, 7109, 1435, 5...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1842, 1799, 1369, 40, 11455, 1481, 7109, 12, 2890, 4672, 3536, 8097, 716, 732, 848, 3496, 558, 27308, 1481, 23011, 8395, 585, 67, 803, 273, 365, 6315, 967, 40, 11455, 1481, 7109, 1435, 5...
omit = [os.path.normcase(os.path.abspath(os.path.realpath(p))) for p in omit]
def command_line(self, argv, help_fn=None): import getopt help_fn = help_fn or self.help settings = {} optmap = { '-a': 'annotate', '-c': 'collect', '-d:': 'directory=', '-e': 'erase', '-h': 'help', '-i': 'ignore-errors', '-m': 'show-missing', '-p': 'parallel-mode', '-r': 'report', '-x': 'execute', '-o:': 'omit=', } short_opts = string.join(map(lambda o: o[1:], optmap.keys()), '') long_opts = optmap.values() options, args = getopt.getopt(argv, short_opts, long_opts) for o, a in options: if o in optmap: settings[optmap[o]] = 1 elif o + ':' in optmap: settings[optmap[o + ':']] = a elif o[2:] in long_opts: settings[o[2:]] = 1 elif o[2:] + '=' in long_opts: settings[o[2:]+'='] = a else: #pragma: no cover pass # Can't get here, because getopt won't return anything unknown.
6554c74cd9574cf89b8acd0a0333651afacbfa8e /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/11312/6554c74cd9574cf89b8acd0a0333651afacbfa8e/coverage.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1296, 67, 1369, 12, 2890, 16, 5261, 16, 2809, 67, 4293, 33, 7036, 4672, 1930, 336, 3838, 2809, 67, 4293, 273, 2809, 67, 4293, 578, 365, 18, 5201, 1947, 273, 2618, 2153, 1458, 273, 288,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1296, 67, 1369, 12, 2890, 16, 5261, 16, 2809, 67, 4293, 33, 7036, 4672, 1930, 336, 3838, 2809, 67, 4293, 273, 2809, 67, 4293, 578, 365, 18, 5201, 1947, 273, 2618, 2153, 1458, 273, 288,...
info.append("Rule title changed")
info.append(i18n._("Rule title changed"))
def _form_rule_titledesc (form): title = getval(form, 'rule_title') if not title: error.append("Empty rule title") return if title!=currule.title: currule.title = title info.append("Rule title changed") desc = getval(form, 'rule_description') if desc!=currule.desc: currule.desc = desc info.append("Rule description changed")
9ad2312d756ee18c5d8cc9bb1f58ad01a1c25b45 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3948/9ad2312d756ee18c5d8cc9bb1f58ad01a1c25b45/filterconfig_html.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 687, 67, 5345, 67, 88, 305, 1259, 742, 261, 687, 4672, 2077, 273, 336, 1125, 12, 687, 16, 296, 5345, 67, 2649, 6134, 309, 486, 2077, 30, 555, 18, 6923, 2932, 1921, 1720, 2077, 7...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 687, 67, 5345, 67, 88, 305, 1259, 742, 261, 687, 4672, 2077, 273, 336, 1125, 12, 687, 16, 296, 5345, 67, 2649, 6134, 309, 486, 2077, 30, 555, 18, 6923, 2932, 1921, 1720, 2077, 7...
if self.selection:
if self.selection or self.multiSelection: if self.multiSelection: self.clearMultiSelection() self.assureSingleSelection()
def selectParent(self, ctrl): """ Change the selection to the parent of the currently selected control. """ if self.selection: if ctrl != self: parent = ctrl.GetParent() parentName = parent.GetName() if parentName == self.GetName(): parentName = '' self.inspector.containment.selectName(parentName)
929119b7ba576880ddd09a9ae89e96345b94dae4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/929119b7ba576880ddd09a9ae89e96345b94dae4/Designer.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2027, 3054, 12, 2890, 16, 6414, 4672, 3536, 7576, 326, 4421, 358, 326, 982, 434, 326, 4551, 3170, 3325, 18, 3536, 309, 365, 18, 10705, 578, 365, 18, 7027, 6233, 30, 309, 365, 18, 7027,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2027, 3054, 12, 2890, 16, 6414, 4672, 3536, 7576, 326, 4421, 358, 326, 982, 434, 326, 4551, 3170, 3325, 18, 3536, 309, 365, 18, 10705, 578, 365, 18, 7027, 6233, 30, 309, 365, 18, 7027,...
time.sleep(int(sleep)) if (noQuit == True):
loopguard = loopguard + 1 if (shouldCloseSocket == True):
def sendCMD(self, cmdline, newline = True, sleep = 0): promptre = re.compile('.*\$\>.$')
fd9e385f2805e09156e5ef3c1f5d56e976bc2bf6 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12156/fd9e385f2805e09156e5ef3c1f5d56e976bc2bf6/devicemanager.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1366, 19473, 12, 2890, 16, 22877, 16, 9472, 273, 1053, 16, 5329, 273, 374, 4672, 6866, 266, 273, 283, 18, 11100, 2668, 4509, 14433, 64, 34, 10806, 6134, 2, 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, 0, 0, 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, 1366, 19473, 12, 2890, 16, 22877, 16, 9472, 273, 1053, 16, 5329, 273, 374, 4672, 6866, 266, 273, 283, 18, 11100, 2668, 4509, 14433, 64, 34, 10806, 6134, 2, -100, -100, -100, -100, -100, ...
parent_ids = tuple(self.search(cr, uid, [('parent_id', 'child_of', ids)], context=context)) if parent_ids: cr.execute("""SELECT account_analytic_line.account_id, COALESCE(SUM(amount_currency), 0.0) \
res_final = {} child_ids = tuple(self.search(cr, uid, [('parent_id', 'child_of', ids)], context=context)) for i in child_ids: res[i] = {} for n in [name]: res[i][n] = 0.0 if not child_ids: return res if child_ids: cr.execute("""SELECT account_analytic_line.account_id, COALESCE(SUM(amount), 0.0) \
def _total_cost_calc(self, cr, uid, ids, name, arg, context=None): res = {} parent_ids = tuple(self.search(cr, uid, [('parent_id', 'child_of', ids)], context=context)) if parent_ids: cr.execute("""SELECT account_analytic_line.account_id, COALESCE(SUM(amount_currency), 0.0) \ FROM account_analytic_line \ JOIN account_analytic_journal \ ON account_analytic_line.journal_id = account_analytic_journal.id \ WHERE account_analytic_line.account_id IN %s \ AND amount<0 \ GROUP BY account_analytic_line.account_id""",(parent_ids,)) for account_id, sum in cr.fetchall(): res[account_id] = round(sum,2) return self._compute_currency_for_level_tree(cr, uid, ids, parent_ids, res, context=context)
4b09311a7342151ec794c610eafc2ea578fd49b9 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7397/4b09311a7342151ec794c610eafc2ea578fd49b9/account_analytic_analysis.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 4963, 67, 12398, 67, 12448, 12, 2890, 16, 4422, 16, 4555, 16, 3258, 16, 508, 16, 1501, 16, 819, 33, 7036, 4672, 400, 273, 2618, 400, 67, 6385, 273, 2618, 1151, 67, 2232, 273, 31...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 4963, 67, 12398, 67, 12448, 12, 2890, 16, 4422, 16, 4555, 16, 3258, 16, 508, 16, 1501, 16, 819, 33, 7036, 4672, 400, 273, 2618, 400, 67, 6385, 273, 2618, 1151, 67, 2232, 273, 31...
self.record_74_hd = '''<table border="0" width="100%"><tr class="blocknote"><td valign="left">
self.record_74_hd = '''<table border="0" width="100%%"><tr class="blocknote"><td valign="left">
def setUp(self): """Prepare some ideal outputs""" self.record_74_hd = '''<table border="0" width="100%"><tr class="blocknote"><td valign="left">
8e9466aff4b3b55478b17bc559b21d034ec18350 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/2763/8e9466aff4b3b55478b17bc559b21d034ec18350/bibformat_regression_tests.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 24292, 12, 2890, 4672, 3536, 7543, 2690, 23349, 6729, 8395, 365, 18, 3366, 67, 5608, 67, 22057, 273, 9163, 32, 2121, 5795, 1546, 20, 6, 1835, 1546, 6625, 9, 14050, 313, 667, 1546, 2629, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 24292, 12, 2890, 4672, 3536, 7543, 2690, 23349, 6729, 8395, 365, 18, 3366, 67, 5608, 67, 22057, 273, 9163, 32, 2121, 5795, 1546, 20, 6, 1835, 1546, 6625, 9, 14050, 313, 667, 1546, 2629, ...
def getInterfacesDataAvail(self, data):
def getInterfacesFinished(self, data):
def checkInterfaceCB(self,callback,iface): if callback is not None: if callback is True: iNetwork.getInterfaces(self.getInterfacesDataAvail)
d6e258a761abb1074a1157d17b9c42b7f28959ce /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/6652/d6e258a761abb1074a1157d17b9c42b7f28959ce/NetworkWizard.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 866, 1358, 8876, 12, 2890, 16, 3394, 16, 31479, 4672, 309, 1348, 353, 486, 599, 30, 309, 1348, 353, 1053, 30, 277, 3906, 18, 588, 10273, 12, 2890, 18, 588, 10273, 751, 3769, 671, 13, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 866, 1358, 8876, 12, 2890, 16, 3394, 16, 31479, 4672, 309, 1348, 353, 486, 599, 30, 309, 1348, 353, 1053, 30, 277, 3906, 18, 588, 10273, 12, 2890, 18, 588, 10273, 751, 3769, 671, 13, ...
h = miso_lfilter(ar, ma, etax, useic=self._icetax))[0]
h = miso_lfilter(ar, ma, etax, useic=self._icetax)[0]
def geth(self, params): '''
5fee506463be936463dec78e1ed27be41902db14 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12658/5fee506463be936463dec78e1ed27be41902db14/mle.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 76, 12, 2890, 16, 859, 4672, 9163, 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...
[ 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 76, 12, 2890, 16, 859, 4672, 9163, 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, ...
return
return
def setElement(self, elt): # element specified as element number global elementSelectorWin self.Element = elt if self.activePartWindow() is not None: # Is this condition on self.activePartWindow() needed? [bruce 071009 question] currentCommand = self.currentCommand if currentCommand.modename == 'DEPOSIT': currentCommand.update_selection_filter_list() # depositMode.update_selection_filter_list() line = eCCBtab2[elt] #self.elemChangeComboBox.setCurrentIndex(line) ###k does this send the signal, or not (if not that might cause bug 690)? #bruce 050706 fix bug 690 by calling the same slot that elemChangeComboBox.setCurrentIndex should have called # (not sure in principle that this is always safe or always a complete fix, but it seems to work) self.elemChange(line) #k arg is a guess, but seems to work return
c25263540add024396d4bcf7631292f1fd2d50bb /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/11221/c25263540add024396d4bcf7631292f1fd2d50bb/MWsemantics.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 26692, 12, 2890, 16, 11572, 4672, 468, 930, 1269, 487, 930, 1300, 2552, 930, 4320, 18049, 225, 365, 18, 1046, 273, 11572, 225, 309, 365, 18, 3535, 1988, 3829, 1435, 353, 486, 599, 30, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 26692, 12, 2890, 16, 11572, 4672, 468, 930, 1269, 487, 930, 1300, 2552, 930, 4320, 18049, 225, 365, 18, 1046, 273, 11572, 225, 309, 365, 18, 3535, 1988, 3829, 1435, 353, 486, 599, 30, ...
% (styles.colors[styles.ST_LOG], msg, styles.colors[styles.ST_NO]) )
% (colors[ST_LOG], msg, colors[ST_NO]) )
def test_message(msg): """ display a message to stderr. """ sys.stderr.write("%s>>> %s%s\n" % (styles.colors[styles.ST_LOG], msg, styles.colors[styles.ST_NO]) )
07cb13c975b820cb15074a8378ec89357e5846f4 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7650/07cb13c975b820cb15074a8378ec89357e5846f4/core.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 67, 2150, 12, 3576, 4672, 3536, 2562, 279, 883, 358, 4514, 18, 3536, 2589, 18, 11241, 18, 2626, 27188, 87, 23012, 738, 87, 9, 87, 64, 82, 6, 738, 261, 10218, 18, 9724, 63, 1021...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1842, 67, 2150, 12, 3576, 4672, 3536, 2562, 279, 883, 358, 4514, 18, 3536, 2589, 18, 11241, 18, 2626, 27188, 87, 23012, 738, 87, 9, 87, 64, 82, 6, 738, 261, 10218, 18, 9724, 63, 1021...
valid_dns_list.append(dns)
valid_dns_list.append("nameserver %s\n" % dns)
def SetDNS(self, dns1=None, dns2=None, dns3=None, dns_dom=None, search_dom=None): """ Set the DNS of the system to the specified DNS servers.
4d33a308bca248bd330b68c292b9cb1e0a6e594d /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12280/4d33a308bca248bd330b68c292b9cb1e0a6e594d/wnettools.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1000, 11602, 12, 2890, 16, 6605, 21, 33, 7036, 16, 6605, 22, 33, 7036, 16, 6605, 23, 33, 7036, 16, 6605, 67, 9859, 33, 7036, 16, 1623, 67, 9859, 33, 7036, 4672, 3536, 1000, 326, 8858...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1000, 11602, 12, 2890, 16, 6605, 21, 33, 7036, 16, 6605, 22, 33, 7036, 16, 6605, 23, 33, 7036, 16, 6605, 67, 9859, 33, 7036, 16, 1623, 67, 9859, 33, 7036, 4672, 3536, 1000, 326, 8858...
y = self.__submodule(x) else: y = x return self.ambient_hecke_module()(y)
if not z.element() in self.__submodule: raise TypeError, "x does not coerce to an element of this Hecke module" return z
def __call__(self, x, check=False): """ Coerce x into the ambient module and checks that x is in this submodule. """ if check: y = self.__submodule(x) else: y = x return self.ambient_hecke_module()(y)
b31a133b0c57be0703dd6f4ae8b99f608ad78a3f /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9890/b31a133b0c57be0703dd6f4ae8b99f608ad78a3f/submodule.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 1991, 972, 12, 2890, 16, 619, 16, 866, 33, 8381, 4672, 3536, 7695, 2765, 619, 1368, 326, 13232, 1979, 1605, 471, 4271, 716, 619, 353, 316, 333, 27314, 18, 3536, 309, 866, 30, 677...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1991, 972, 12, 2890, 16, 619, 16, 866, 33, 8381, 4672, 3536, 7695, 2765, 619, 1368, 326, 13232, 1979, 1605, 471, 4271, 716, 619, 353, 316, 333, 27314, 18, 3536, 309, 866, 30, 677...
for cachename, cache in self._dset_caches:
for cachename, cache in self._dset_caches.items():
def _draw_drawingsets(self): """ Using info collected in self.csdl_collector, update our cached DrawingSets for this frame; then draw them. """ ### REVIEW: move inside csdl_collector? # or into some new cooperating object, which keeps the DrawingSets?
ccbaef83f2fcdeb7cbd4ae8ab1d6678d88bd1e04 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/11221/ccbaef83f2fcdeb7cbd4ae8ab1d6678d88bd1e04/GLPane_drawingset_methods.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 9446, 67, 9446, 310, 4424, 12, 2890, 4672, 3536, 11637, 1123, 12230, 316, 365, 18, 2143, 5761, 67, 21356, 16, 1089, 3134, 3472, 10184, 310, 2785, 364, 333, 2623, 31, 1508, 3724, 218...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 67, 9446, 310, 4424, 12, 2890, 4672, 3536, 11637, 1123, 12230, 316, 365, 18, 2143, 5761, 67, 21356, 16, 1089, 3134, 3472, 10184, 310, 2785, 364, 333, 2623, 31, 1508, 3724, 218...
config.add_data_files('numpy/')
config.add_data_files('numpy/*')
def configuration(parent_package='',top_path=None): from numpy.distutils.misc_util import Configuration config = Configuration('numarray',parent_package,top_path) config.add_data_files('numpy/') config.add_extension('_capi', sources=['_capi.c'], ) return config
988678cf6d0eb8459588e1067dd3a91468cbaa2d /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/14925/988678cf6d0eb8459588e1067dd3a91468cbaa2d/setup.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1664, 12, 2938, 67, 5610, 2218, 2187, 3669, 67, 803, 33, 7036, 4672, 628, 3972, 18, 4413, 5471, 18, 23667, 67, 1367, 1930, 4659, 642, 273, 4659, 2668, 2107, 1126, 2187, 2938, 67, 5610, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1664, 12, 2938, 67, 5610, 2218, 2187, 3669, 67, 803, 33, 7036, 4672, 628, 3972, 18, 4413, 5471, 18, 23667, 67, 1367, 1930, 4659, 642, 273, 4659, 2668, 2107, 1126, 2187, 2938, 67, 5610, ...
class NBzNSNodeStatusResponse(Packet):
class NBNSNodeStatusResponse(Packet):
def post_build(self, p): if self.len is None: l = len(p)-14 p = p[:10]+struct.pack("!H", l)+p[12:] return p
c075f2131fa1df6fcde4745180a9582d7ceecb64 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/7311/c075f2131fa1df6fcde4745180a9582d7ceecb64/scapy.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1603, 67, 3510, 12, 2890, 16, 293, 4672, 309, 365, 18, 1897, 353, 599, 30, 328, 273, 562, 12, 84, 24950, 3461, 293, 273, 293, 10531, 2163, 3737, 1697, 18, 2920, 2932, 5, 44, 3113, 32...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1603, 67, 3510, 12, 2890, 16, 293, 4672, 309, 365, 18, 1897, 353, 599, 30, 328, 273, 562, 12, 84, 24950, 3461, 293, 273, 293, 10531, 2163, 3737, 1697, 18, 2920, 2932, 5, 44, 3113, 32...
Populates `self.page_breaks` with id based XPath selectors (for elements that don't
Populates `self.page_breaks` with id based XPath selectors (for elements that don't
def find_page_breaks(self, stylesheets, root): ''' Find all elements that have either page-break-before or page-break-after set. Populates `self.page_breaks` with id based XPath selectors (for elements that don't have ids, an id is created). ''' page_break_selectors = set([]) for rule in rules(stylesheets): before = getattr(rule.style.getPropertyCSSValue('page-break-before'), 'cssText', '').strip().lower() after = getattr(rule.style.getPropertyCSSValue('page-break-after'), 'cssText', '').strip().lower() try: if before and before != 'avoid': page_break_selectors.add((CSSSelector(rule.selectorText), True)) except: pass try: if after and after != 'avoid': page_break_selectors.add((CSSSelector(rule.selectorText), False)) except: pass page_breaks = set([]) for selector, before in page_break_selectors: for elem in selector(root): elem.pb_before = before page_breaks.add(elem) for i, elem in enumerate(root.iter()): elem.pb_order = i page_breaks = list(page_breaks) page_breaks.sort(cmp=lambda x,y : cmp(x.pb_order, y.pb_order)) self.page_break_ids = [] for i, x in enumerate(page_breaks): x.set('id', x.get('id', 'calibre_pb_%d'%i)) id = x.get('id') self.page_breaks.append((XPath('//*[@id="%s"]'%id), x.pb_before)) self.page_break_ids.append(id)
e869684a299f6ee49985cfc2ed305b42306b26d6 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9125/e869684a299f6ee49985cfc2ed305b42306b26d6/split.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1104, 67, 2433, 67, 29292, 12, 2890, 16, 30163, 16, 1365, 4672, 9163, 4163, 777, 2186, 716, 1240, 3344, 1363, 17, 8820, 17, 5771, 578, 1363, 17, 8820, 17, 5205, 444, 18, 10264, 17099, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 67, 2433, 67, 29292, 12, 2890, 16, 30163, 16, 1365, 4672, 9163, 4163, 777, 2186, 716, 1240, 3344, 1363, 17, 8820, 17, 5771, 578, 1363, 17, 8820, 17, 5205, 444, 18, 10264, 17099, ...
'CFLAGS' , 'CXXFLAGS'
'CFLAGS' , 'CXXFLAGS',
def options (self): """Returns a dictionnary with project build options.""" prj = self
9279d150df4f3fccd31a2f0459c08623f1c80f44 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/8002/9279d150df4f3fccd31a2f0459c08623f1c80f44/project.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 702, 261, 2890, 4672, 3536, 1356, 279, 302, 2228, 82, 814, 598, 1984, 1361, 702, 12123, 27378, 273, 365, 2, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 702, 261, 2890, 4672, 3536, 1356, 279, 302, 2228, 82, 814, 598, 1984, 1361, 702, 12123, 27378, 273, 365, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
d = utils.getProcessValue(exe, [scriptFile])
d = utils.getProcessValue(exe, ['-u', scriptFile])
def testValue(self): exe = sys.executable scriptFile = self.makeSourceFile([ "import sys", "sys.exit(1)" ])
7b89bf4800a4c444036d44c6ab146adc71bc9395 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12595/7b89bf4800a4c444036d44c6ab146adc71bc9395/test_iutils.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 620, 12, 2890, 4672, 15073, 273, 2589, 18, 17751, 2728, 812, 273, 365, 18, 6540, 31150, 3816, 315, 5666, 2589, 3113, 315, 9499, 18, 8593, 12, 21, 2225, 308, 13, 2, 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, 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, 620, 12, 2890, 4672, 15073, 273, 2589, 18, 17751, 2728, 812, 273, 365, 18, 6540, 31150, 3816, 315, 5666, 2589, 3113, 315, 9499, 18, 8593, 12, 21, 2225, 308, 13, 2, -100, -100, -1...
if isNewShare:
if not share.exists():
def onShareItemEvent (self, event): """ Share an ItemCollection. """ itemCollection = event.arguments ['item']
2cdd17726b32faf1edbc4d50d26071249602b9b2 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9228/2cdd17726b32faf1edbc4d50d26071249602b9b2/Main.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 603, 9535, 1180, 1133, 261, 2890, 16, 871, 4672, 3536, 25805, 392, 4342, 2532, 18, 3536, 761, 2532, 273, 871, 18, 7099, 10228, 1726, 3546, 2, 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, 0, 0, 0, 0, 0, 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, 9535, 1180, 1133, 261, 2890, 16, 871, 4672, 3536, 25805, 392, 4342, 2532, 18, 3536, 761, 2532, 273, 871, 18, 7099, 10228, 1726, 3546, 2, -100, -100, -100, -100, -100, -100, -100, -1...
def adjust_positions(self, old, new):
def adjust_positions(self, old, new):
def adjust_positions(self, old, new): p1, p2 = old[self.indices] d = p2 - p1 p = sqrt(npy.dot(d, d)) q1, q2 = new[self.indices] d = q2 - q1 q = sqrt(npy.dot(d, d)) d *= 0.5 * (p - q) / q new[self.indices] = (q1 - d, q2 + d)
71f1c7648ed99f55f1c67487ad0b55b1f9c29b7d /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/1380/71f1c7648ed99f55f1c67487ad0b55b1f9c29b7d/constraints.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 5765, 67, 12388, 12, 2890, 16, 1592, 16, 394, 4672, 293, 21, 16, 293, 22, 273, 1592, 63, 2890, 18, 6836, 65, 302, 273, 293, 22, 300, 293, 21, 293, 273, 5700, 12, 82, 2074, 18, 9811...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 5765, 67, 12388, 12, 2890, 16, 1592, 16, 394, 4672, 293, 21, 16, 293, 22, 273, 1592, 63, 2890, 18, 6836, 65, 302, 273, 293, 22, 300, 293, 21, 293, 273, 5700, 12, 82, 2074, 18, 9811...
self.server.join()
self.join()
def serve_forever(self): if not self: # XXX will this work: server.start(); server.serve_forever() self.start() self.server.join()
81fa06694835ecc7ee9138cee236db8a22b30d2c /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/10423/81fa06694835ecc7ee9138cee236db8a22b30d2c/server.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 12175, 67, 1405, 502, 12, 2890, 4672, 309, 486, 365, 30, 468, 11329, 903, 333, 1440, 30, 1438, 18, 1937, 5621, 1438, 18, 30104, 67, 1405, 502, 1435, 365, 18, 1937, 1435, 365, 18, 3567,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 12175, 67, 1405, 502, 12, 2890, 4672, 309, 486, 365, 30, 468, 11329, 903, 333, 1440, 30, 1438, 18, 1937, 5621, 1438, 18, 30104, 67, 1405, 502, 1435, 365, 18, 1937, 1435, 365, 18, 3567,...
iflogging = StmtIf(ExprCall( ExprVar('PR_GetEnv'), args=[ ExprLiteral.String('MOZ_IPC_MESSAGE_LOG') ]))
iflogging = StmtIf(ExprCall(ExprVar('mozilla::ipc::LoggingEnabled')))
def _ifLogging(stmts): iflogging = StmtIf(ExprCall( ExprVar('PR_GetEnv'), args=[ ExprLiteral.String('MOZ_IPC_MESSAGE_LOG') ])) iflogging.addifstmts(stmts) return iflogging
389b9a17d65f6d1954aac1863a87790100fc08a9 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/11102/389b9a17d65f6d1954aac1863a87790100fc08a9/lower.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 430, 7735, 12, 25659, 4672, 309, 11167, 273, 13751, 2047, 12, 4742, 1477, 12, 4742, 1537, 2668, 8683, 15990, 2866, 625, 71, 2866, 7735, 1526, 11, 20349, 309, 11167, 18, 1289, 430, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 430, 7735, 12, 25659, 4672, 309, 11167, 273, 13751, 2047, 12, 4742, 1477, 12, 4742, 1537, 2668, 8683, 15990, 2866, 625, 71, 2866, 7735, 1526, 11, 20349, 309, 11167, 18, 1289, 430, 2...
if issubclass(t, numpy.string):
if issubclass(t, numpy.string_):
def getType(a): t = a.dtype.type if issubclass(t, numpy.bool_): return bool if issubclass(t, numpy.int64): # catch 64-bit integers... return long if issubclass(t, numpy.integer): # ...before proceeding to smaller ones return int if issubclass(t, numpy.floating): return float if issubclass(t, numpy.complexfloating): return complex if issubclass(t, numpy.string): return str raise ValueError("unkown type %s" % a.dtype.name)
dbdc6fcdb42a095230dca98e217558ae353ee454 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12687/dbdc6fcdb42a095230dca98e217558ae353ee454/compiler.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3130, 12, 69, 4672, 268, 273, 279, 18, 8972, 18, 723, 309, 14664, 12, 88, 16, 3972, 18, 6430, 67, 4672, 327, 1426, 309, 14664, 12, 88, 16, 3972, 18, 474, 1105, 4672, 225, 468, 1044, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3130, 12, 69, 4672, 268, 273, 279, 18, 8972, 18, 723, 309, 14664, 12, 88, 16, 3972, 18, 6430, 67, 4672, 327, 1426, 309, 14664, 12, 88, 16, 3972, 18, 474, 1105, 4672, 225, 468, 1044, ...
elif type(paths) == types.ListType:
elif type(path) == types.ListType:
def getDirectorySize(self, path): if type(path) == types.StringType: paths = [path] elif type(paths) == types.ListType: paths = path else: return S_ERROR('LFCClient.getDirectoryReplicas: Must supply a path or list of paths') # If we have less than three lfns to query a session doesn't make sense if len(paths) > 2: self.__openSession() failed = {} successful = {} for path in paths: res = self.__getDirectoryContents(path) if res['OK']: pathDict = {'Files':0,'TotalSize':0,'SiteUsage':{}} files = res['Value']['Files'] for lfn in files.keys(): fileSize = files[lfn]['MetaData']['Size'] pathDict['Files'] += 1 pathDict['TotalSize'] += fileSize repDict = files[lfn]['Replicas'] for se in repDict.keys(): if not pathDict['SiteUsage'].has_key(se): pathDict['SiteUsage'][se] = 0 pathDict['SiteUsage'][se] += fileSize successful[path] = pathDict else: failed[path] = res['Message'] if self.session: self.__closeSession() resDict = {'Failed':failed,'Successful':successful} return S_OK(resDict)
24878006a97fc6c0a40ff01095f00d930f79b1e6 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/12864/24878006a97fc6c0a40ff01095f00d930f79b1e6/LcgFileCatalogClient.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 19831, 1225, 12, 2890, 16, 589, 4672, 309, 618, 12, 803, 13, 422, 1953, 18, 780, 559, 30, 2953, 273, 306, 803, 65, 1327, 618, 12, 803, 13, 422, 1953, 18, 19366, 30, 2953, 273, 589, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 19831, 1225, 12, 2890, 16, 589, 4672, 309, 618, 12, 803, 13, 422, 1953, 18, 780, 559, 30, 2953, 273, 306, 803, 65, 1327, 618, 12, 803, 13, 422, 1953, 18, 19366, 30, 2953, 273, 589, ...
class DlvyInst(CharField): __swig_setmethods__ = {} for _s in [CharField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, DlvyInst, name, value) __swig_getmethods__ = {} for _s in [CharField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, DlvyInst, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_DlvyInst(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_DlvyInst __del__ = lambda self : None; DlvyInst_swigregister = _quickfix.DlvyInst_swigregister DlvyInst_swigregister(DlvyInst) class BrokerOfCredit(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, BrokerOfCredit, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, BrokerOfCredit, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_BrokerOfCredit(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_BrokerOfCredit __del__ = lambda self : None; BrokerOfCredit_swigregister = _quickfix.BrokerOfCredit_swigregister BrokerOfCredit_swigregister(BrokerOfCredit) class ClientID(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, ClientID, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, ClientID, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_ClientID(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_ClientID __del__ = lambda self : None; ClientID_swigregister = _quickfix.ClientID_swigregister ClientID_swigregister(ClientID) class CxlType(CharField): __swig_setmethods__ = {} for _s in [CharField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, CxlType, name, value) __swig_getmethods__ = {} for _s in [CharField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, CxlType, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_CxlType(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_CxlType __del__ = lambda self : None; CxlType_swigregister = _quickfix.CxlType_swigregister CxlType_swigregister(CxlType) class SettlLocation(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, SettlLocation, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, SettlLocation, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_SettlLocation(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_SettlLocation __del__ = lambda self : None; SettlLocation_swigregister = _quickfix.SettlLocation_swigregister SettlLocation_swigregister(SettlLocation) class SettlDepositoryCode(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, SettlDepositoryCode, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, SettlDepositoryCode, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_SettlDepositoryCode(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_SettlDepositoryCode __del__ = lambda self : None; SettlDepositoryCode_swigregister = _quickfix.SettlDepositoryCode_swigregister SettlDepositoryCode_swigregister(SettlDepositoryCode) class SettlBrkrCode(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, SettlBrkrCode, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, SettlBrkrCode, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_SettlBrkrCode(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_SettlBrkrCode __del__ = lambda self : None; SettlBrkrCode_swigregister = _quickfix.SettlBrkrCode_swigregister SettlBrkrCode_swigregister(SettlBrkrCode) class SettlInstCode(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, SettlInstCode, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, SettlInstCode, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_SettlInstCode(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_SettlInstCode __del__ = lambda self : None; SettlInstCode_swigregister = _quickfix.SettlInstCode_swigregister SettlInstCode_swigregister(SettlInstCode) class SecuritySettlAgentName(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, SecuritySettlAgentName, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, SecuritySettlAgentName, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_SecuritySettlAgentName(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_SecuritySettlAgentName __del__ = lambda self : None; SecuritySettlAgentName_swigregister = _quickfix.SecuritySettlAgentName_swigregister SecuritySettlAgentName_swigregister(SecuritySettlAgentName) class SecuritySettlAgentCode(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, SecuritySettlAgentCode, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, SecuritySettlAgentCode, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_SecuritySettlAgentCode(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_SecuritySettlAgentCode __del__ = lambda self : None; SecuritySettlAgentCode_swigregister = _quickfix.SecuritySettlAgentCode_swigregister SecuritySettlAgentCode_swigregister(SecuritySettlAgentCode) class SecuritySettlAgentAcctNum(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, SecuritySettlAgentAcctNum, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, SecuritySettlAgentAcctNum, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_SecuritySettlAgentAcctNum(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_SecuritySettlAgentAcctNum __del__ = lambda self : None; SecuritySettlAgentAcctNum_swigregister = _quickfix.SecuritySettlAgentAcctNum_swigregister SecuritySettlAgentAcctNum_swigregister(SecuritySettlAgentAcctNum) class SecuritySettlAgentAcctName(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, SecuritySettlAgentAcctName, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, SecuritySettlAgentAcctName, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_SecuritySettlAgentAcctName(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_SecuritySettlAgentAcctName __del__ = lambda self : None; SecuritySettlAgentAcctName_swigregister = _quickfix.SecuritySettlAgentAcctName_swigregister SecuritySettlAgentAcctName_swigregister(SecuritySettlAgentAcctName) class SecuritySettlAgentContactName(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, SecuritySettlAgentContactName, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, SecuritySettlAgentContactName, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_SecuritySettlAgentContactName(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_SecuritySettlAgentContactName __del__ = lambda self : None; SecuritySettlAgentContactName_swigregister = _quickfix.SecuritySettlAgentContactName_swigregister SecuritySettlAgentContactName_swigregister(SecuritySettlAgentContactName) class SecuritySettlAgentContactPhone(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, SecuritySettlAgentContactPhone, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, SecuritySettlAgentContactPhone, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_SecuritySettlAgentContactPhone(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_SecuritySettlAgentContactPhone __del__ = lambda self : None; SecuritySettlAgentContactPhone_swigregister = _quickfix.SecuritySettlAgentContactPhone_swigregister SecuritySettlAgentContactPhone_swigregister(SecuritySettlAgentContactPhone) class CashSettlAgentName(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, CashSettlAgentName, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, CashSettlAgentName, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_CashSettlAgentName(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_CashSettlAgentName __del__ = lambda self : None; CashSettlAgentName_swigregister = _quickfix.CashSettlAgentName_swigregister CashSettlAgentName_swigregister(CashSettlAgentName) class CashSettlAgentCode(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, CashSettlAgentCode, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, CashSettlAgentCode, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_CashSettlAgentCode(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_CashSettlAgentCode __del__ = lambda self : None; CashSettlAgentCode_swigregister = _quickfix.CashSettlAgentCode_swigregister CashSettlAgentCode_swigregister(CashSettlAgentCode) class CashSettlAgentAcctNum(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, CashSettlAgentAcctNum, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, CashSettlAgentAcctNum, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_CashSettlAgentAcctNum(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_CashSettlAgentAcctNum __del__ = lambda self : None; CashSettlAgentAcctNum_swigregister = _quickfix.CashSettlAgentAcctNum_swigregister CashSettlAgentAcctNum_swigregister(CashSettlAgentAcctNum) class CashSettlAgentAcctName(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, CashSettlAgentAcctName, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, CashSettlAgentAcctName, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_CashSettlAgentAcctName(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_CashSettlAgentAcctName __del__ = lambda self : None; CashSettlAgentAcctName_swigregister = _quickfix.CashSettlAgentAcctName_swigregister CashSettlAgentAcctName_swigregister(CashSettlAgentAcctName) class CashSettlAgentContactName(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, CashSettlAgentContactName, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, CashSettlAgentContactName, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_CashSettlAgentContactName(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_CashSettlAgentContactName __del__ = lambda self : None; CashSettlAgentContactName_swigregister = _quickfix.CashSettlAgentContactName_swigregister CashSettlAgentContactName_swigregister(CashSettlAgentContactName) class CashSettlAgentContactPhone(StringField): __swig_setmethods__ = {} for _s in [StringField]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{})) __setattr__ = lambda self, name, value: _swig_setattr(self, CashSettlAgentContactPhone, name, value) __swig_getmethods__ = {} for _s in [StringField]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{})) __getattr__ = lambda self, name: _swig_getattr(self, CashSettlAgentContactPhone, name) __repr__ = _swig_repr def __init__(self, *args): this = _quickfix.new_CashSettlAgentContactPhone(*args) try: self.this.append(this) except: self.this = this __swig_destroy__ = _quickfix.delete_CashSettlAgentContactPhone __del__ = lambda self : None; CashSettlAgentContactPhone_swigregister = _quickfix.CashSettlAgentContactPhone_swigregister CashSettlAgentContactPhone_swigregister(CashSettlAgentContactPhone)
def __init__(self, *args): this = _quickfix.new_AllocShares(*args) try: self.this.append(this) except: self.this = this
b195a30ce1679e0269bc776f2f6e3591488def1f /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/8819/b195a30ce1679e0269bc776f2f6e3591488def1f/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, 8763, 24051, 30857, 1968, 13, 775, 30, 365, 18, 2211, 18, 6923, 12, 2211, 13, 1335, 30, 365, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 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, 8763, 24051, 30857, 1968, 13, 775, 30, 365, 18, 2211, 18, 6923, 12, 2211, 13, 1335, 30, 365, ...
leader = content[0:insertionpoint] ui.debug('imap', 'savemessage_addheader: leader = %s' % repr(leader)) trailer = content[insertionpoint:] ui.debug('imap', 'savemessage_addheader: trailer = ' + repr(trailer)) return leader + "\r\n" + newline + trailer
newline = "\r\n" newline += "%s: %s" % (headername, headervalue) ui.debug('imap', 'savemessage_addheader: newline = ' + repr(newline)) trailer = content[insertionpoint:] ui.debug('imap', 'savemessage_addheader: trailer = ' + repr(trailer)) return leader + newline + trailer
def savemessage_addheader(self, content, headername, headervalue): ui = UIBase.getglobalui() ui.debug('imap', 'savemessage_addheader: called to add %s: %s' % (headername, headervalue)) newline = "%s: %s" % (headername, headervalue) ui.debug('imap', 'savemessage_addheader: newline = ' + repr(newline))
35c7b668622c302359035198fd5d5bb9ae1d88ce /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/5335/35c7b668622c302359035198fd5d5bb9ae1d88ce/IMAP.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4087, 351, 615, 67, 1289, 3374, 12, 2890, 16, 913, 16, 1446, 529, 16, 1446, 1132, 4672, 5915, 273, 6484, 2171, 18, 588, 10581, 700, 77, 1435, 5915, 18, 4148, 2668, 12161, 2187, 296, 87...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 4087, 351, 615, 67, 1289, 3374, 12, 2890, 16, 913, 16, 1446, 529, 16, 1446, 1132, 4672, 5915, 273, 6484, 2171, 18, 588, 10581, 700, 77, 1435, 5915, 18, 4148, 2668, 12161, 2187, 296, 87...
return Dec_n1
return _Dec_n1
def compare_total(self, other): """Compares self to other using the abstract representations.
7ea2d399fb15e34ed3695ca0160f84f982b9194c /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/8125/7ea2d399fb15e34ed3695ca0160f84f982b9194c/decimal.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3400, 67, 4963, 12, 2890, 16, 1308, 4672, 3536, 19199, 365, 358, 1308, 1450, 326, 8770, 27851, 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,...
[ 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3400, 67, 4963, 12, 2890, 16, 1308, 4672, 3536, 19199, 365, 358, 1308, 1450, 326, 8770, 27851, 18, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
libraries, extradirs, extraexportsymbols)
libraries, extradirs, extraexportsymbols, outputdir)
def genpluginproject(architecture, module, project=None, projectdir=None, sources=[], sourcedirs=[], libraries=[], extradirs=[], extraexportsymbols=[], outputdir=":::Lib:lib-dynload"): if architecture == "all": # For the time being we generate two project files. Not as nice as # a single multitarget project, but easier to implement for now. genpluginproject("ppc", module, project, projectdir, sources, sourcedirs, libraries, extradirs, extraexportsymbols) genpluginproject("carbon", module, project, projectdir, sources, sourcedirs, libraries, extradirs, extraexportsymbols) return templatename = "template-%s" % architecture targetname = "%s.%s" % (module, architecture) dllname = "%s.%s.slb" % (module, architecture) if not project: if architecture != "ppc": project = "%s.%s.mcp"%(module, architecture) else: project = "%s.mcp"%module if not projectdir: projectdir = PROJECTDIR if not sources: sources = [module + 'module.c'] if not sourcedirs: for moduledir in MODULEDIRS: if '%' in moduledir: moduledir = moduledir % module fn = os.path.join(projectdir, os.path.join(moduledir, sources[0])) if os.path.exists(fn): moduledir, sourcefile = os.path.split(fn) sourcedirs = [relpath(projectdir, moduledir)] sources[0] = sourcefile break else: print "Warning: %s: sourcefile not found: %s"%(module, sources[0]) sourcedirs = [] if architecture == "carbon": prefixname = "mwerks_carbonplugin_config.h" else: prefixname = "mwerks_plugin_config.h" dict = { "sysprefix" : relpath(projectdir, sys.prefix), "sources" : sources, "extrasearchdirs" : sourcedirs + extradirs, "libraries": libraries, "mac_outputdir" : outputdir, "extraexportsymbols" : extraexportsymbols, "mac_targetname" : targetname, "mac_dllname" : dllname, "prefixname" : prefixname, } mkcwproject.mkproject(os.path.join(projectdir, project), module, dict, force=FORCEREBUILD, templatename=templatename)
579f673323af12f7aa8ee186776b73f9976097f9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12029/579f673323af12f7aa8ee186776b73f9976097f9/genpluginprojects.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3157, 4094, 4406, 12, 991, 18123, 16, 1605, 16, 1984, 33, 7036, 16, 1984, 1214, 33, 7036, 16, 5550, 22850, 6487, 1084, 8291, 22850, 6487, 14732, 22850, 6487, 7582, 361, 10539, 22850, 6487,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3157, 4094, 4406, 12, 991, 18123, 16, 1605, 16, 1984, 33, 7036, 16, 1984, 1214, 33, 7036, 16, 5550, 22850, 6487, 1084, 8291, 22850, 6487, 14732, 22850, 6487, 7582, 361, 10539, 22850, 6487,...
folder = cls(reference)
folder = cls(uri)
def get_handler(self, reference, cls=None): uri = cwd.get_reference(reference)
70692c38f19264d6c79a01a29c313074df6197a3 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12681/70692c38f19264d6c79a01a29c313074df6197a3/database.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 4176, 12, 2890, 16, 2114, 16, 2028, 33, 7036, 4672, 2003, 273, 7239, 18, 588, 67, 6180, 12, 6180, 13, 2, 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, 0, 0, 0, 0, 0, 0, 0, 0, 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, 4176, 12, 2890, 16, 2114, 16, 2028, 33, 7036, 4672, 2003, 273, 7239, 18, 588, 67, 6180, 12, 6180, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
raise ValueError("unknown protocol: %s" % o.scheme)
raise ValueError("unknown protocol: %s" % o_scheme)
def fetch(self, url): o = urlparse.urlparse(url) if o.port: port = int(o.port) else: port = 80 if o.query: path = o.path + '?' + o.query else: path = o.path if o.fragment: self.fragment = o.fragment if self.fragment: path += '#' + self.fragment if not path: path = '/' self.sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM) if o.scheme == 'http': self.sock.connect((o.hostname,port)) elif o.scheme == 'https': ctx = OpenSSL.SSL.Context(OpenSSL.SSL.SSLv23_METHOD) self.sock = OpenSSL.SSL.Connection(ctx, sock) else: raise ValueError("unknown protocol: %s" % o.scheme) if self.debug: log('>> HEAD %s HTTP/1.1' % path) log('>> Host: %s' % o.hostname) self.sock.send('HEAD %s HTTP/1.1\n' % path) self.sock.send('Host: %s\n' % o.hostname) self.sock.send('\n') data = self.read() self.sock.close() return data
444b609184a8825cf6ec712d4c0c553b3e23c70c /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/8937/444b609184a8825cf6ec712d4c0c553b3e23c70c/integrity.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2158, 12, 2890, 16, 880, 4672, 320, 273, 15185, 18, 718, 2670, 12, 718, 13, 309, 320, 18, 655, 30, 1756, 273, 509, 12, 83, 18, 655, 13, 469, 30, 1756, 273, 8958, 309, 320, 18, 2271...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2158, 12, 2890, 16, 880, 4672, 320, 273, 15185, 18, 718, 2670, 12, 718, 13, 309, 320, 18, 655, 30, 1756, 273, 509, 12, 83, 18, 655, 13, 469, 30, 1756, 273, 8958, 309, 320, 18, 2271...
(func.name, command_id))
(func.name, _CMD_ID_TABLE[func.name]))
def WriteCommandIdTest(self, filename): """Writes the command id test.""" file = CWriter(filename) self.WriteLicense(file) file.Write("// This file contains unit tests for gles2 commmand ids\n") file.Write("\n") file.Write("#include \"tests/common/win/testing_common.h\"\n") file.Write("#include \"gpu/command_buffer/common/gles2_cmd_format.h\"\n") file.Write("\n")
ba3176a8f0a18527c0af5896f9d595d866e5ceeb /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9392/ba3176a8f0a18527c0af5896f9d595d866e5ceeb/build_gles2_cmd_buffer.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2598, 2189, 548, 4709, 12, 2890, 16, 1544, 4672, 3536, 8368, 326, 1296, 612, 1842, 12123, 585, 273, 385, 2289, 12, 3459, 13, 365, 18, 3067, 13211, 12, 768, 13, 585, 18, 3067, 2932, 759...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2598, 2189, 548, 4709, 12, 2890, 16, 1544, 4672, 3536, 8368, 326, 1296, 612, 1842, 12123, 585, 273, 385, 2289, 12, 3459, 13, 365, 18, 3067, 13211, 12, 768, 13, 585, 18, 3067, 2932, 759...
if self.options["session_restore"][1]:
if self.options["url_history"][1]:
def list_files(self): # browser cache cache_base = None if sys.platform == 'linux2': cache_base = self.profile_dir if sys.platform == 'win32': cache_base = "$USERPROFILE\\Local Settings\\Application Data\\Mozilla\\Firefox\\Profiles\\*" if self.options["cache"][1]: dirs = FileUtilities.expand_glob_join(cache_base, "Cache*") dirs += FileUtilities.expand_glob_join(cache_base, "OfflineCache") for dirname in dirs: for filename in children_in_directory(dirname, False): yield filename files = [] # cookies if self.options["cookies"][1]: files += FileUtilities.expand_glob_join(self.profile_dir, "cookies.txt") files += FileUtilities.expand_glob_join(self.profile_dir, "cookies.sqlite") # download history if self.options["download_history"][1]: # Firefox version 1 files += FileUtilities.expand_glob_join(self.profile_dir, "downloads.rdf") # Firefox version 3 files += FileUtilities.expand_glob_join(self.profile_dir, "downloads.sqlite") # forms if self.options["forms"][1]: files += FileUtilities.expand_glob_join(self.profile_dir, "formhistory.dat") files += FileUtilities.expand_glob_join(self.profile_dir, "formhistory.sqlite") # passwords if self.options["passwords"][1]: files += FileUtilities.expand_glob_join(self.profile_dir, "signons.txt") files += FileUtilities.expand_glob_join(self.profile_dir, "signons[2-3].txt") # places database if self.options["places"][1]: # Firefox version 3 files += FileUtilities.expand_glob_join(self.profile_dir, "places.sqlite") files += FileUtilities.expand_glob_join(self.profile_dir, "places.sqlite-journal") files += FileUtilities.expand_glob_join(self.profile_dir, "bookmarkbackups/*ookmark*json") # see also option 'url_history' # session restore if self.options["session_restore"][1]: files += FileUtilities.expand_glob_join(self.profile_dir, "sessionstore.js") # URL history if self.options["session_restore"][1]: # Firefox version 1 files += FileUtilities.expand_glob_join(self.profile_dir, "history.dat") # see also function other_cleanup() # finish for filename in files: yield filename
170e35e8a777578e4dbf851cadc49c5fe2b91366 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/7853/170e35e8a777578e4dbf851cadc49c5fe2b91366/CleanerBackend.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 666, 67, 2354, 12, 2890, 4672, 468, 4748, 1247, 1247, 67, 1969, 273, 599, 309, 2589, 18, 9898, 422, 296, 20132, 22, 4278, 1247, 67, 1969, 273, 365, 18, 5040, 67, 1214, 309, 2589, 18, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 666, 67, 2354, 12, 2890, 4672, 468, 4748, 1247, 1247, 67, 1969, 273, 599, 309, 2589, 18, 9898, 422, 296, 20132, 22, 4278, 1247, 67, 1969, 273, 365, 18, 5040, 67, 1214, 309, 2589, 18, ...
tsumufs.nfsAvailable.notifyAll()
def setxattr(self, path, name, value, size): self._debug(('opcode: setxattr | path: %s | name: %s | ' 'value: %s | size: %d') % (path, name, value, size))
0e3153c7d5770544ad6708e7951dbc33a2653269 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/10739/0e3153c7d5770544ad6708e7951dbc33a2653269/fusethread.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 444, 92, 1747, 12, 2890, 16, 589, 16, 508, 16, 460, 16, 963, 4672, 365, 6315, 4148, 12, 2668, 556, 710, 30, 444, 92, 1747, 571, 589, 30, 738, 87, 571, 508, 30, 738, 87, 571, 296, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 444, 92, 1747, 12, 2890, 16, 589, 16, 508, 16, 460, 16, 963, 4672, 365, 6315, 4148, 12, 2668, 556, 710, 30, 444, 92, 1747, 571, 589, 30, 738, 87, 571, 508, 30, 738, 87, 571, 296, ...
elif line.category_id.contribute and line.category_id.include_in_salary and line.category_id.amount_type == 'fix':
elif line.category_id.contribute and line.category_id.amount_type == 'fix':
def compute_sheet(self, cr, uid, ids, context={}): emp_pool = self.pool.get('hr.employee') slip_pool = self.pool.get('hr.payslip') func_pool = self.pool.get('hr.employee.grade') slip_line_pool = self.pool.get('hr.payslip.line') holiday_pool = self.pool.get('hr.holidays') vals = self.read(cr, uid, ids)[0] emp_ids = ids for slip in self.browse(cr, uid, ids): allow = 0.0 #for emp in emp_pool.browse(cr, uid, [vals['employee_id'][0]]): emp = slip.employee_id sql_req= ''' SELECT c.id as id, c.wage as wage, function as function FROM hr_contract c LEFT JOIN hr_employee emp on (c.employee_id=emp.id) LEFT JOIN hr_contract_wage_type cwt on (cwt.id = c.wage_type_id) LEFT JOIN hr_contract_wage_type_period p on (cwt.period_id = p.id) WHERE (emp.id=%s) AND (date_start <= %s) AND (date_end IS NULL OR date_end >= %s) LIMIT 1 ''' cr.execute(sql_req, (emp.id, vals['date'], vals['date'])) contract_id = cr.dictfetchone() if not contract_id: continue contract = self.pool.get('hr.contract').browse(cr, uid, contract_id['id']) sal_type = contract.wage_type_id.type function = contract.function.id lines = [] if function: func = func_pool.read(cr, uid, function, ['line_ids']) lines = slip_line_pool.browse(cr, uid, func['line_ids'])
9cefb7520803ded7f648633ccca30e623a0dd192 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7339/9cefb7520803ded7f648633ccca30e623a0dd192/hr_payroll.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3671, 67, 8118, 12, 2890, 16, 4422, 16, 4555, 16, 3258, 16, 819, 12938, 4672, 801, 84, 67, 6011, 273, 365, 18, 6011, 18, 588, 2668, 7256, 18, 351, 2817, 1340, 6134, 272, 3169, 67, 60...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3671, 67, 8118, 12, 2890, 16, 4422, 16, 4555, 16, 3258, 16, 819, 12938, 4672, 801, 84, 67, 6011, 273, 365, 18, 6011, 18, 588, 2668, 7256, 18, 351, 2817, 1340, 6134, 272, 3169, 67, 60...
self.req.hdf.setValue('title', 'Create New Report')
if action == 'commit': self.req.hdf.setValue('title', 'Edit Report {%d} %s' % (id, row['title'])) else: self.req.hdf.setValue('title', 'Create New Report')
def render_report_editor(self, id, action='commit', copy=0): self.perm.assert_permission(perm.REPORT_MODIFY) cursor = self.db.cursor()
e624f0941bef517457d4c7b25a6fe026584c51d2 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2831/e624f0941bef517457d4c7b25a6fe026584c51d2/Report.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1743, 67, 6006, 67, 9177, 12, 2890, 16, 612, 16, 1301, 2218, 7371, 2187, 1610, 33, 20, 4672, 365, 18, 12160, 18, 11231, 67, 9827, 12, 12160, 18, 22710, 67, 6720, 12096, 13, 3347, 273, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1743, 67, 6006, 67, 9177, 12, 2890, 16, 612, 16, 1301, 2218, 7371, 2187, 1610, 33, 20, 4672, 365, 18, 12160, 18, 11231, 67, 9827, 12, 12160, 18, 22710, 67, 6720, 12096, 13, 3347, 273, ...
Returns the Hasse invariant of an elliptic curve over a field of positive characteristic, which is an element of the field.
Returns the Hasse invariant of this elliptic curve. OUTPUT: The Hasse invariant of this elliptic curve, as an element of the base field. This is only defined over fields of positive characteristic, and is an element of the field which is zero if and only if the curve is supersingular. Over a field of characteristic zero, where the Hasse invariant is undefined, a ``ValueError`` is returned.
def hasse_invariant(self): r""" Returns the Hasse invariant of an elliptic curve over a field of positive characteristic, which is an element of the field.
b1a55647e46d9dcd8c484ebfc1b922d27e4b0a44 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9890/b1a55647e46d9dcd8c484ebfc1b922d27e4b0a44/ell_field.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 711, 307, 67, 267, 8688, 12, 2890, 4672, 436, 8395, 2860, 326, 4393, 307, 22514, 434, 392, 415, 549, 21507, 8882, 1879, 279, 652, 434, 6895, 23158, 16, 1492, 353, 392, 930, 434, 326, 6...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 711, 307, 67, 267, 8688, 12, 2890, 4672, 436, 8395, 2860, 326, 4393, 307, 22514, 434, 392, 415, 549, 21507, 8882, 1879, 279, 652, 434, 6895, 23158, 16, 1492, 353, 392, 930, 434, 326, 6...
print("sf: %s" % (repr(newsharedfiles))) print("") print("st: %s" % (repr(newsharedfilesstreams))) print("") print("wi: %s" % (repr(newwordindex))) print("") print("fi: %s" % (repr(newfileindex))) print("") print("mt: %s" % (newmtimes))
def rescandirs(self, shared_directories, oldmtimes, oldfiles, sharedfilesstreams, yieldfunction, progress=None, name="", rebuild=False): """ Check for modified or new files via OS's last mtime on a directory, or, if rebuild is True, all directories """ #returns dict in format: { Directory : mtime, ... } gobject.idle_add(progress.set_text, _("Checking for changes")) gobject.idle_add(progress.show) gobject.idle_add(progress.set_fraction, 0) self.logMessage("Rescanning: Checking %(num)s directories" % {"num": len(oldmtimes)}) if win32: newmtimes = self.getDirsMtimesUnicode(shared_directories, yieldfunction) else: newmtimes = self.getDirsMtimes(shared_directories, yieldfunction) self.logMessage("Rescanning: Found %(num)s directories" % {"num": len(newmtimes)}) gobject.idle_add(progress.set_text, _("Scanning %s") % name) # Get list of files # returns dict in format { Directory : { File : metadata, ... }, ... } if win32: newsharedfiles = self.getFilesListUnicode(newmtimes, oldmtimes, oldfiles, yieldfunction, progress, rebuild) else: newsharedfiles = self.getFilesList(newmtimes, oldmtimes, oldfiles, yieldfunction, progress, rebuild) # Pack shares data # returns dict in format { Directory : hex string of files+metadata, ... } gobject.idle_add(progress.set_text, _("Building DataBase")) if win32: newsharedfilesstreams = self.getFilesStreamsUnicode(newmtimes, oldmtimes, sharedfilesstreams, newsharedfiles, yieldfunction) else: newsharedfilesstreams = self.getFilesStreams(newmtimes, oldmtimes, sharedfilesstreams, newsharedfiles, yieldfunction) # Update Search Index # newwordindex is a dict in format {word: [num, num, ..], ... } with num matching # keys in newfileindex # newfileindex is a dict in format { num: (path, size, (bitrate, vbr), length), ... } gobject.idle_add(progress.set_text, _("Building Index")) gobject.idle_add(progress.set_fraction, 0.0) newwordindex, newfileindex = self.getFilesIndex(newmtimes, oldmtimes, shared_directories, newsharedfiles, yieldfunction, progress) gobject.idle_add(progress.set_fraction, 1.0) print("sf: %s" % (repr(newsharedfiles))) print("") print("st: %s" % (repr(newsharedfilesstreams))) print("") print("wi: %s" % (repr(newwordindex))) print("") print("fi: %s" % (repr(newfileindex))) print("") print("mt: %s" % (newmtimes)) return newsharedfiles, newsharedfilesstreams, newwordindex, newfileindex, newmtimes
248d148627dbd13f6fee32b155836315e29084ea /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/8738/248d148627dbd13f6fee32b155836315e29084ea/shares.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 400, 71, 464, 10539, 12, 2890, 16, 5116, 67, 15121, 16, 1592, 1010, 4485, 16, 1592, 2354, 16, 7433, 2180, 1449, 16320, 16, 2824, 915, 16, 4007, 33, 7036, 16, 508, 1546, 3113, 13419, 33...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 400, 71, 464, 10539, 12, 2890, 16, 5116, 67, 15121, 16, 1592, 1010, 4485, 16, 1592, 2354, 16, 7433, 2180, 1449, 16320, 16, 2824, 915, 16, 4007, 33, 7036, 16, 508, 1546, 3113, 13419, 33...
if not os.path.isdir(f) and not os.path.isfile(f):
path = os.path.join(dirpath, f) if not os.path.isdir(path) and not os.path.isfile(path):
def rmTmp(statusObj, status): statusObj.logger.debug("\tremoving tmpdir") for (dirpath, dirnames, filenames) in os.walk(statusObj.tmpdir): for f in filenames + dirnames: if not os.path.isdir(f) and not os.path.isfile(f): continue path = os.path.join(dirpath, f) oldmode = stat.S_IMODE(os.stat(path)[stat.ST_MODE]) os.chmod(path, oldmode | stat.S_IRWXU) shutil.rmtree(statusObj.tmpdir)
e1873d6275822cc7fec90c74682081a5a926fea4 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/36/e1873d6275822cc7fec90c74682081a5a926fea4/extract_common.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 6692, 9161, 12, 2327, 2675, 16, 1267, 4672, 1267, 2675, 18, 4901, 18, 4148, 31458, 88, 2764, 13767, 20213, 7923, 364, 261, 1214, 803, 16, 1577, 1973, 16, 9066, 13, 316, 1140, 18, 11348, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 6692, 9161, 12, 2327, 2675, 16, 1267, 4672, 1267, 2675, 18, 4901, 18, 4148, 31458, 88, 2764, 13767, 20213, 7923, 364, 261, 1214, 803, 16, 1577, 1973, 16, 9066, 13, 316, 1140, 18, 11348, ...
screen.fill ((0, 0, 0))
screen.fill ((255, 255, 255))
def show (image): screen.fill ((0, 0, 0)) screen.blit (image, (0, 0)) pygame.display.flip () while 1: event = pygame.event.wait () if event.type == pygame.QUIT: raise SystemExit if event.type == pygame.MOUSEBUTTONDOWN: break
b2d6a7c2571a0cd93ed24bc9ab389385a6e20a1b /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/1298/b2d6a7c2571a0cd93ed24bc9ab389385a6e20a1b/pixelarray.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2405, 261, 2730, 4672, 5518, 18, 5935, 14015, 10395, 16, 4561, 16, 4561, 3719, 5518, 18, 3083, 305, 261, 2730, 16, 261, 20, 16, 374, 3719, 2395, 13957, 18, 5417, 18, 12357, 1832, 1323, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2405, 261, 2730, 4672, 5518, 18, 5935, 14015, 10395, 16, 4561, 16, 4561, 3719, 5518, 18, 3083, 305, 261, 2730, 16, 261, 20, 16, 374, 3719, 2395, 13957, 18, 5417, 18, 12357, 1832, 1323, ...
_sys.stderr.write("Exception in thread %s:\n%s\n" % (self.getName(), _format_exc()))
if _sys: _sys.stderr.write("Exception in thread %s:\n%s\n" % (self.getName(), _format_exc())) else: exc_type, exc_value, exc_tb = self.__exc_info() try: print>>self.__stderr, ( "Exception in thread " + self.getName() + " (most likely raised during interpreter shutdown):") print>>self.__stderr, ( "Traceback (most recent call last):") while exc_tb: print>>self.__stderr, ( ' File "%s", line %s, in %s' % (exc_tb.tb_frame.f_code.co_filename, exc_tb.tb_lineno, exc_tb.tb_frame.f_code.co_name)) exc_tb = exc_tb.tb_next print>>self.__stderr, ("%s: %s" % (exc_type, exc_value)) finally: del exc_type, exc_value, exc_tb
def __bootstrap(self): try: self.__started = True _active_limbo_lock.acquire() _active[_get_ident()] = self del _limbo[self] _active_limbo_lock.release() if __debug__: self._note("%s.__bootstrap(): thread started", self)
f19394c50b0e4e0f769fd0130d8072c788c15d8c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12029/f19394c50b0e4e0f769fd0130d8072c788c15d8c/threading.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 12722, 12, 2890, 4672, 775, 30, 365, 16186, 14561, 273, 1053, 389, 3535, 67, 7091, 1075, 67, 739, 18, 1077, 1039, 1435, 389, 3535, 63, 67, 588, 67, 6392, 1435, 65, 273, 365, 1464...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 12722, 12, 2890, 4672, 775, 30, 365, 16186, 14561, 273, 1053, 389, 3535, 67, 7091, 1075, 67, 739, 18, 1077, 1039, 1435, 389, 3535, 63, 67, 588, 67, 6392, 1435, 65, 273, 365, 1464...
image.thumbnail((keys['width'],keys['height']), pilfilter)
image.thumbnail((keys['width'],keys['height']))
def scale(self,data,w,h): """ scale image (with material from ImageTag_Hotfix)""" #make sure we have valid int's keys = {'height':int(h), 'width':int(w)}
6c49241026527d58ec33dad69b98fdf197a65ae4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12165/6c49241026527d58ec33dad69b98fdf197a65ae4/Field.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3159, 12, 2890, 16, 892, 16, 91, 16, 76, 4672, 3536, 3159, 1316, 261, 1918, 9390, 628, 3421, 1805, 67, 25270, 904, 15574, 468, 6540, 3071, 732, 1240, 923, 509, 1807, 1311, 273, 13666, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3159, 12, 2890, 16, 892, 16, 91, 16, 76, 4672, 3536, 3159, 1316, 261, 1918, 9390, 628, 3421, 1805, 67, 25270, 904, 15574, 468, 6540, 3071, 732, 1240, 923, 509, 1807, 1311, 273, 13666, ...
doc = minidom.parseString(response)
doc = minidom.parseString(response.encode("utf-8"))
def _check_response_for_errors(self, response): """Checks the response for errors and raises one if any exists.""" doc = minidom.parseString(response) e = doc.getElementsByTagName('lfm')[0] if e.getAttribute('status') != "ok": e = doc.getElementsByTagName('error')[0] status = e.getAttribute('code') details = e.firstChild.data.strip() raise ServiceException(status, details)
8d8063afe8067477accae5bef5e470a4a3cbfa5d /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9926/8d8063afe8067477accae5bef5e470a4a3cbfa5d/pylast.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 1893, 67, 2740, 67, 1884, 67, 4324, 12, 2890, 16, 766, 4672, 3536, 4081, 326, 766, 364, 1334, 471, 14183, 1245, 309, 1281, 1704, 12123, 225, 997, 273, 1131, 350, 362, 18, 2670, 78...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1893, 67, 2740, 67, 1884, 67, 4324, 12, 2890, 16, 766, 4672, 3536, 4081, 326, 766, 364, 1334, 471, 14183, 1245, 309, 1281, 1704, 12123, 225, 997, 273, 1131, 350, 362, 18, 2670, 78...
iv = self.db._db.getas('_%s[k:S,i:I]' % self.classname)
iv = self.db._db.getas('_%s[k:S,i:I]' % tablename)
def setkey(self, propname): '''Select a String property of this class to be the key property.
edfb0422e5d47b84bd404fb037ad8914f3d11fc1 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/1906/edfb0422e5d47b84bd404fb037ad8914f3d11fc1/back_metakit.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 444, 856, 12, 2890, 16, 2270, 529, 4672, 9163, 3391, 279, 514, 1272, 434, 333, 667, 358, 506, 326, 498, 1272, 18, 2, 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, 0, 0, 0, 0, 0, 0, 0, 0, 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, 444, 856, 12, 2890, 16, 2270, 529, 4672, 9163, 3391, 279, 514, 1272, 434, 333, 667, 358, 506, 326, 498, 1272, 18, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -...
for child in self.children: if child != self.selection: behaviour.apply(0, [child])
behaviour.apply(0, self.items.children)
def behave(self, behaviour, *args, **kwargs): """ Add behaviour to be used for widgets covered by the selection
b47bb145b9afab8cd03f9ba37d4dcd175be8f666 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/11702/b47bb145b9afab8cd03f9ba37d4dcd175be8f666/grid.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 31085, 12, 2890, 16, 14273, 16, 380, 1968, 16, 2826, 4333, 4672, 3536, 1436, 14273, 358, 506, 1399, 364, 10965, 18147, 635, 326, 4421, 2, 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, 0, 0, 0, 0, 0, 0, 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, 31085, 12, 2890, 16, 14273, 16, 380, 1968, 16, 2826, 4333, 4672, 3536, 1436, 14273, 358, 506, 1399, 364, 10965, 18147, 635, 326, 4421, 2, -100, -100, -100, -100, -100, -100, -100, -100, ...
raise omero.ClientError("No session avaliable")
raise omero.ClientError("No session available")
def getSession(self): """ Returns the current active session or throws an exception if none has been created since the last closeSession() """ self.__lock.acquire() try: sf = self.__sf if not sf: raise omero.ClientError("No session avaliable") return sf finally: self.__lock.release()
ed80c4f0b891a7659071b735a08435d4be5647bb /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12409/ed80c4f0b891a7659071b735a08435d4be5647bb/clients.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 7183, 12, 2890, 4672, 3536, 2860, 326, 783, 2695, 1339, 578, 1216, 392, 1520, 309, 6555, 711, 2118, 2522, 3241, 326, 1142, 27578, 1435, 3536, 365, 16186, 739, 18, 1077, 1039, 1435, 775, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 7183, 12, 2890, 4672, 3536, 2860, 326, 783, 2695, 1339, 578, 1216, 392, 1520, 309, 6555, 711, 2118, 2522, 3241, 326, 1142, 27578, 1435, 3536, 365, 16186, 739, 18, 1077, 1039, 1435, 775, ...
debugOutput ("kill "+str(pid)+" "+str(signal.SIGKILL))
debugOutput ("kill "+str(pid))
def func (): global gLog result = True
9a13fc78c38b554162109d47862641b7215d28f8 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/11382/9a13fc78c38b554162109d47862641b7215d28f8/worker.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1326, 1832, 30, 2552, 314, 1343, 563, 273, 1053, 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, ...
[ 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1326, 1832, 30, 2552, 314, 1343, 563, 273, 1053, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
os.system("python generatekeys.py %s %s %s"%(username, 20, "keys"))
def genkey(username): """ <Purpose> Internal method to generate keys for users <Arguments> username: the user who we want to generate key for <Returns> the key for the user """ # write keys to the file os.system("python generatekeys.py %s %s %s"%(username, 20, "keys")) # read the public key from file f = open("/keys/%s.public"%(username), 'r') key = f.read() f.close() return key
7c4e103ddf899adaa494e41bfa14992d7084ad6c /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/7995/7c4e103ddf899adaa494e41bfa14992d7084ad6c/views.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3157, 856, 12, 5053, 4672, 3536, 411, 10262, 4150, 34, 3186, 707, 358, 2103, 1311, 364, 3677, 411, 4628, 34, 2718, 30, 326, 729, 10354, 732, 2545, 358, 2103, 498, 364, 411, 1356, 34, 3...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3157, 856, 12, 5053, 4672, 3536, 411, 10262, 4150, 34, 3186, 707, 358, 2103, 1311, 364, 3677, 411, 4628, 34, 2718, 30, 326, 729, 10354, 732, 2545, 358, 2103, 498, 364, 411, 1356, 34, 3...
if multiline and len(vstr) > self._variable_linelen:
if len(vstr) > self._variable_linelen:
def pprint_pyval(self, pyval, multiline=True, summary_linelen=0): # Handle the most common cases first. The following types # will never need any line wrapping, etc; and they cover most # variable values (esp int, for constants). I leave out # LongType on purpose, since long values may need line- # wrapping. if (type(pyval) is types.IntType or type(pyval) is types.FloatType or type(pyval) is types.NoneType or type(pyval) is types.ComplexType): # none of these should contain '&', '<' or '>'. vstr = repr(pyval) return vstr + '&nbsp;' * (self._variable_linelen-len(vstr))
5c410b5b6e25df3bdbc6da266f7773518165cb02 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3512/5c410b5b6e25df3bdbc6da266f7773518165cb02/html.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 18771, 67, 2074, 1125, 12, 2890, 16, 2395, 1125, 16, 19431, 33, 5510, 16, 4916, 67, 7511, 292, 275, 33, 20, 4672, 468, 5004, 326, 4486, 2975, 6088, 1122, 18, 225, 1021, 3751, 1953, 468...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 18771, 67, 2074, 1125, 12, 2890, 16, 2395, 1125, 16, 19431, 33, 5510, 16, 4916, 67, 7511, 292, 275, 33, 20, 4672, 468, 5004, 326, 4486, 2975, 6088, 1122, 18, 225, 1021, 3751, 1953, 468...
a = "file:../perl/dc.rdf"
a = "file:../data/dc.rdf"
def testParseAsStream(self): a = "file:../perl/dc.rdf" for s in self.parser.parse_as_stream(a): self.model.append(s) self.assert_(len(self.model) == 3,"dc.rdf should have 3 statements")
a61b7fbb628fcd9ecf6f0a1eb3d595671b166459 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/14754/a61b7fbb628fcd9ecf6f0a1eb3d595671b166459/redlandtest.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 3201, 17052, 12, 2890, 4672, 279, 273, 315, 768, 30, 6216, 892, 19, 7201, 18, 19299, 6, 364, 272, 316, 365, 18, 4288, 18, 2670, 67, 345, 67, 3256, 12, 69, 4672, 365, 18, 2284, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1842, 3201, 17052, 12, 2890, 4672, 279, 273, 315, 768, 30, 6216, 892, 19, 7201, 18, 19299, 6, 364, 272, 316, 365, 18, 4288, 18, 2670, 67, 345, 67, 3256, 12, 69, 4672, 365, 18, 2284, ...
if sterr:
if stderr:
def collapse (a,keepcols,collapsecols,stderr=0,ns=0,cfcn=None): """Averages data in collapsecol, keeping all unique items in keepcols (using unique, which keeps unique LISTS of column numbers), retaining the unique sets of values in keepcols, the mean for each. If the sterr or N of the mean are desired, set either or both parameters to 1. Returns: unique 'conditions' specified by the contents of columns specified by keepcols, abutted with the mean(s) of column(s) specified by collapsecols """ if cfcn is None: cfcn = stats.mean a = asarray(a) if keepcols == []: avgcol = colex(a,collapsecols) means = cfcn(avgcol) return means else: if type(keepcols) not in [ListType,TupleType,N.ArrayType]: keepcols = [keepcols] values = colex(a,keepcols) # so that "item" can be appended (below) uniques = unique(values) # get a LIST, so .sort keeps rows intact uniques.sort() newlist = [] for item in uniques: if type(item) not in [ListType,TupleType,N.ArrayType]: item =[item] tmprows = linexand(a,keepcols,item) for col in collapsecols: avgcol = colex(tmprows,col) item.append(cfcn(avgcol)) if sterr: if len(avgcol)>1: item.append(stats.sterr(avgcol)) else: item.append('N/A') if ns: item.append(len(avgcol)) newlist.append(item) try: new_a = N.array(newlist) except TypeError: new_a = N.array(newlist,'O') return new_a
9212912c52a95c6d6e2e12c52450ef94bffd1759 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12971/9212912c52a95c6d6e2e12c52450ef94bffd1759/_support.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 13627, 261, 69, 16, 10102, 6842, 16, 21405, 6842, 16, 11241, 33, 20, 16, 2387, 33, 20, 16, 71, 7142, 82, 33, 7036, 4672, 3536, 37, 502, 1023, 501, 316, 13627, 1293, 16, 19966, 777, 3...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 13627, 261, 69, 16, 10102, 6842, 16, 21405, 6842, 16, 11241, 33, 20, 16, 2387, 33, 20, 16, 71, 7142, 82, 33, 7036, 4672, 3536, 37, 502, 1023, 501, 316, 13627, 1293, 16, 19966, 777, 3...
self.dispatch(t.stararg)
self.dispatch(t.starargs)
def _Call(self, t): self.dispatch(t.func) self.write("(") comma = False for e in t.args: if comma: self.write(", ") else: comma = True self.dispatch(e) for e in t.keywords: if comma: self.write(", ") else: comma = True self.dispatch(e) if t.starargs: if comma: self.write(", ") else: comma = True self.write("*") self.dispatch(t.stararg) if t.kwargs: if comma: self.write(", ") else: comma = True self.write("**") self.dispatch(t.stararg) self.write(")")
652266b90a3285ed5c943454dddd1ea5476a9f35 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12029/652266b90a3285ed5c943454dddd1ea5476a9f35/unparse.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 1477, 12, 2890, 16, 268, 4672, 365, 18, 10739, 12, 88, 18, 644, 13, 365, 18, 2626, 2932, 2932, 13, 8716, 273, 1083, 364, 425, 316, 268, 18, 1968, 30, 309, 8716, 30, 365, 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, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 1477, 12, 2890, 16, 268, 4672, 365, 18, 10739, 12, 88, 18, 644, 13, 365, 18, 2626, 2932, 2932, 13, 8716, 273, 1083, 364, 425, 316, 268, 18, 1968, 30, 309, 8716, 30, 365, 18, 2...
javascript = [LocalJSLink('bkr', '/static/javascript/reserve_workflow_v2.js')]
javascript = [LocalJSLink('bkr', '/static/javascript/reserve_workflow_v3.js')]
def update_params(self,d): log.debug(d) if 'value' in d: if 'distro_ids' in d['value']: if(isinstance(d['value']['distro_ids'],list)): for distro_id in d['value']['distro_ids']: d['hidden_fields'] = [HiddenField(name='distro_id',attrs = {'value' : distro_id})] + d['hidden_fields'][0:]
d7ec98483e709317a4cc2329f7a9e86a07d353bd /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/14755/d7ec98483e709317a4cc2329f7a9e86a07d353bd/widgets.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1089, 67, 2010, 12, 2890, 16, 72, 4672, 613, 18, 4148, 12, 72, 13, 309, 296, 1132, 11, 316, 302, 30, 309, 296, 4413, 303, 67, 2232, 11, 316, 302, 3292, 1132, 3546, 30, 309, 12, 291...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1089, 67, 2010, 12, 2890, 16, 72, 4672, 613, 18, 4148, 12, 72, 13, 309, 296, 1132, 11, 316, 302, 30, 309, 296, 4413, 303, 67, 2232, 11, 316, 302, 3292, 1132, 3546, 30, 309, 12, 291...
print ' %s %s\n => %s %s' % (cmd, args, typ, dat)
_mesg(' %s %s\n => %s %s' % (cmd, args, typ, dat))
def run(cmd, args): typ, dat = apply(eval('M.%s' % cmd), args) print ' %s %s\n => %s %s' % (cmd, args, typ, dat) return dat
b10c0e30e74484a3863b7dcd5a9fd8e9e5849364 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3187/b10c0e30e74484a3863b7dcd5a9fd8e9e5849364/imaplib.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1086, 12, 4172, 16, 833, 4672, 3815, 16, 1150, 273, 2230, 12, 8622, 2668, 49, 7866, 87, 11, 738, 1797, 3631, 833, 13, 389, 26244, 75, 2668, 738, 87, 738, 87, 64, 82, 225, 516, 738, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1086, 12, 4172, 16, 833, 4672, 3815, 16, 1150, 273, 2230, 12, 8622, 2668, 49, 7866, 87, 11, 738, 1797, 3631, 833, 13, 389, 26244, 75, 2668, 738, 87, 738, 87, 64, 82, 225, 516, 738, ...
comparefiles = os.listdir(gsconf.comparefiledir)
comparefiles = os.listdir(gsconf.comparefiledir)
def addTests(suite, gsroot, **args): # get a list of test files comparefiles = os.listdir(gsconf.comparefiledir) for f in comparefiles: if f[-3:] == '.ps' or f[-4:] == '.pdf' or f[-4:] == '.eps': for params in gsparamsets.pdftestparamsets: add_compare_test(suite, f, params.device, params.resolution, params.banding)
089187a98986c96b1c6d26275643f8fc00b8bb52 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/675/089187a98986c96b1c6d26275643f8fc00b8bb52/gscheck_pdfwrite.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 527, 14650, 12, 30676, 16, 10763, 3085, 16, 2826, 1968, 4672, 468, 336, 279, 666, 434, 1842, 1390, 3400, 2354, 273, 1140, 18, 1098, 1214, 12, 564, 3923, 18, 9877, 768, 1214, 13, 225, 3...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 527, 14650, 12, 30676, 16, 10763, 3085, 16, 2826, 1968, 4672, 468, 336, 279, 666, 434, 1842, 1390, 3400, 2354, 273, 1140, 18, 1098, 1214, 12, 564, 3923, 18, 9877, 768, 1214, 13, 225, 3...
self.eb("connection lost")
self.deferred.armAndErrback("connection lost")
def connectionLost(self): if not self.term: self.term = 1 del self.broker self.eb("connection lost")
c0bc4b7519b791390c8aeed1e0a20caf9fb64d14 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12595/c0bc4b7519b791390c8aeed1e0a20caf9fb64d14/pb.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1459, 19024, 12, 2890, 4672, 309, 486, 365, 18, 6408, 30, 365, 18, 6408, 273, 404, 1464, 365, 18, 21722, 365, 18, 24008, 2932, 4071, 13557, 7923, 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, 0, 0, 0, 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, 1459, 19024, 12, 2890, 4672, 309, 486, 365, 18, 6408, 30, 365, 18, 6408, 273, 404, 1464, 365, 18, 21722, 365, 18, 24008, 2932, 4071, 13557, 7923, 2, -100, -100, -100, -100, -100, -100, ...
resultArchive = '%s.tag.gz' % folderToArchive
resultArchive = '%s.tar.gz' % folderToArchive
def renameDataFiles(directory):
9da3d5ab7a9dc600d1e4835cda86f34679789f07 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/1488/9da3d5ab7a9dc600d1e4835cda86f34679789f07/feedback_report.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 6472, 751, 2697, 12, 5149, 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,...
[ 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 6472, 751, 2697, 12, 5149, 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, -1...
return print "Processing:", file
return 1 print "Index:", file
def process(file, list): print "-"*70 if not list: sys.stderr.write("no division warnings for %s\n" % file) return try: fp = open(file) except IOError, msg: sys.stderr.write("can't open: %s\n" % msg) return print "Processing:", file f = FileContext(fp) list.sort() index = 0 # list[:index] has been processed, list[index:] is still to do orphans = [] # subset of list for which no / operator was found unknown = [] # lines with / operators for which no warnings were seen g = tokenize.generate_tokens(f.readline) while 1: startlineno, endlineno, slashes = lineinfo = scanline(g) if startlineno is None: break assert startlineno <= endlineno is not None while index < len(list) and list[index][0] < startlineno: orphans.append(list[index]) index += 1 warnings = [] while index < len(list) and list[index][0] <= endlineno: warnings.append(list[index]) index += 1 if not slashes and not warnings: pass elif slashes and not warnings: report(slashes, "Unexecuted code") elif warnings and not slashes: reportphantomwarnings(warnings, f) else: if len(slashes) > 1: report(slashes, "More than one / operator") else: (row, col), line = slashes[0] line = chop(line) if line[col:col+1] != "/": print "*** Can't find the / operator in line %d:" % row print "*", line continue intlong = [] floatcomplex = [] bad = [] for lineno, what in warnings: if what in ("int", "long"): intlong.append(what) elif what in ("float", "complex"): floatcomplex.append(what) else: bad.append(what) if bad: print "*** Bad warning for line %d:" % row, bad print "*", line elif intlong and not floatcomplex: print "%dc%d" % (row, row) print "<", line print "---" print ">", line[:col] + "/" + line[col:] elif floatcomplex and not intlong: print "True division / operator at line %d:" % row print "=", line fp.close()
30e743a5e4c7f456d77c77d6dcb354479fa040bc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8125/30e743a5e4c7f456d77c77d6dcb354479fa040bc/fixdiv.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1207, 12, 768, 16, 666, 4672, 1172, 7514, 14, 7301, 309, 486, 666, 30, 2589, 18, 11241, 18, 2626, 2932, 2135, 16536, 5599, 364, 738, 87, 64, 82, 6, 738, 585, 13, 327, 775, 30, 4253, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1207, 12, 768, 16, 666, 4672, 1172, 7514, 14, 7301, 309, 486, 666, 30, 2589, 18, 11241, 18, 2626, 2932, 2135, 16536, 5599, 364, 738, 87, 64, 82, 6, 738, 585, 13, 327, 775, 30, 4253, ...
return self.__executeSingleReplicaStorageElementOperation(storageElementName,lfn,'getAccessUrl') else: return self.__executeReplicaStorageElementOperation(storageElementName,lfn,'getAccessUrl') def getReplicaMetadata(self,lfn,storageElementName,singleFile=False):
return self.__executeSingleReplicaStorageElementOperation( storageElementName, lfn, 'getAccessUrl' ) else: return self.__executeReplicaStorageElementOperation( storageElementName, lfn, 'getAccessUrl' ) def getReplicaMetadata( self, lfn, storageElementName, singleFile=False ):
def getReplicaAccessUrl(self,lfn,storageElementName,singleFile=False): """ Obtain the access url for lfns at the supplied StorageElement 'lfn' is the file(s) for which to obtain access URLs 'storageElementName' is the target Storage Element """ if singleFile: return self.__executeSingleReplicaStorageElementOperation(storageElementName,lfn,'getAccessUrl') else: return self.__executeReplicaStorageElementOperation(storageElementName,lfn,'getAccessUrl')
9fabceb719d19d46d8b75011d2932552dbe360f9 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12864/9fabceb719d19d46d8b75011d2932552dbe360f9/ReplicaManager.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 5561, 6996, 1862, 1489, 12, 2890, 16, 80, 4293, 16, 5697, 30584, 16, 7526, 812, 33, 8381, 4672, 3536, 24850, 326, 2006, 880, 364, 18594, 2387, 622, 326, 4580, 5235, 1046, 225, 296, 80, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 5561, 6996, 1862, 1489, 12, 2890, 16, 80, 4293, 16, 5697, 30584, 16, 7526, 812, 33, 8381, 4672, 3536, 24850, 326, 2006, 880, 364, 18594, 2387, 622, 326, 4580, 5235, 1046, 225, 296, 80, ...
self.config.remove_section(essid_key)
def write_script_ent(prof, script): if not self.config.has_option(prof, script): self.config.set(prof, script, None)
7e264d5df56d1374eba37362ff6971dc8a9f8879 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/353/7e264d5df56d1374eba37362ff6971dc8a9f8879/wicd-daemon.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1045, 67, 4263, 67, 319, 12, 16121, 16, 2728, 4672, 309, 486, 365, 18, 1425, 18, 5332, 67, 3482, 12, 16121, 16, 2728, 4672, 365, 18, 1425, 18, 542, 12, 16121, 16, 2728, 16, 599, 13, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1045, 67, 4263, 67, 319, 12, 16121, 16, 2728, 4672, 309, 486, 365, 18, 1425, 18, 5332, 67, 3482, 12, 16121, 16, 2728, 4672, 365, 18, 1425, 18, 542, 12, 16121, 16, 2728, 16, 599, 13, ...
print 'Woop', session.uid
def login(self, request, session, creds, segments): """Called to check the credentials of a user.
f52c91b64c170484942fcadf870dc4af79989662 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/6980/f52c91b64c170484942fcadf870dc4af79989662/websession.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3925, 12, 2890, 16, 590, 16, 1339, 16, 12534, 16, 5155, 4672, 3536, 8185, 358, 866, 326, 4448, 434, 279, 729, 18, 2, 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, 0, 0, 0, 0, 0, 0, 0, 0, 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, 3925, 12, 2890, 16, 590, 16, 1339, 16, 12534, 16, 5155, 4672, 3536, 8185, 358, 866, 326, 4448, 434, 279, 729, 18, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -...
jend = (j==1 and labels.shape[0]-1) or labels.shape[0]
jend = (j==1 and labels.shape[1]-1) or labels.shape[1]
def calculate_perimeters(labels, indexes): """Count the distances between adjacent pixels in the perimeters of the labels""" # # Create arrays that tell whether a pixel is like its neighbors. # index = 0 is the pixel -1,-1 from the pixel of interest, 1 is -1,0, etc. # m=np.zeros((labels.shape[0],labels.shape[1]),int) exponent = 0 for i in range(-1,2): ilow = (i==-1 and 1) or 1 iend = (i==1 and labels.shape[0]-1) or labels.shape[0] for j in range(-1,2): jlow = (j==-1 and 1) or 1 jend = (j==1 and labels.shape[0]-1) or labels.shape[0] m[ilow:iend,jlow:jend] = \ (m[ilow:iend,jlow:jend] + (labels[ilow:iend,jlow:jend] == labels[ilow+i:iend+i,jlow+j:jend+j])*2**exponent) exponent += 1 pixel_score = __perimeter_scoring[m] return fixup_scipy_ndimage_result(scind.sum(pixel_score, labels, indexes))
3119d18e22bfd5f853863ed41b48b076a659689e /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/2870/3119d18e22bfd5f853863ed41b48b076a659689e/cpmorphology.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4604, 67, 457, 381, 1032, 12, 5336, 16, 5596, 4672, 3536, 1380, 326, 12491, 3086, 16335, 8948, 316, 326, 1534, 381, 1032, 434, 326, 3249, 8395, 468, 468, 1788, 5352, 716, 9276, 2856, 279...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 4604, 67, 457, 381, 1032, 12, 5336, 16, 5596, 4672, 3536, 1380, 326, 12491, 3086, 16335, 8948, 316, 326, 1534, 381, 1032, 434, 326, 3249, 8395, 468, 468, 1788, 5352, 716, 9276, 2856, 279...
self.journal_name
self.journal_name = journal_name
def __init__(self, language, journal_name, recid): """ Initialisation. """ self.language = language self.journal_name self.recid = recid
d627e6c45c40d98e4cb9a9b7103e950684051bf8 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/12027/d627e6c45c40d98e4cb9a9b7103e950684051bf8/webjournal_config.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 2653, 16, 13001, 67, 529, 16, 1950, 350, 4672, 3536, 10188, 10742, 18, 3536, 365, 18, 4923, 273, 2653, 365, 18, 22644, 67, 529, 273, 13001, 67, 529, 365,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 2653, 16, 13001, 67, 529, 16, 1950, 350, 4672, 3536, 10188, 10742, 18, 3536, 365, 18, 4923, 273, 2653, 365, 18, 22644, 67, 529, 273, 13001, 67, 529, 365,...
return self._checkIntVariable('bulk')
return bool(self._checkIntVariable("bulk"))
def useBulk(self): """Check if the request specifies bulk querying.
b939de4662e970c7e0ce8af7bfdf4acc06369b74 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7542/b939de4662e970c7e0ce8af7bfdf4acc06369b74/baserlib.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 999, 13112, 12, 2890, 4672, 3536, 1564, 309, 326, 590, 11470, 8280, 23936, 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, ...
[ 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 999, 13112, 12, 2890, 4672, 3536, 1564, 309, 326, 590, 11470, 8280, 23936, 18, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
name="Presence" if not v.get_type() or v.get_type()=="available": value="Available"
name = "Presence" if not v.get_type() or v.get_type() == "available": value = "Available" value += " (prio=%i)" % (v.get_priority(), )
def info_presence(self,k,v): if not v: return None
ed2720a863a0afcf460f4a25be432bee15507f8c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12768/ed2720a863a0afcf460f4a25be432bee15507f8c/presence.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1123, 67, 21731, 12, 2890, 16, 79, 16, 90, 4672, 309, 486, 331, 30, 327, 599, 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,...
[ 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1123, 67, 21731, 12, 2890, 16, 79, 16, 90, 4672, 309, 486, 331, 30, 327, 599, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -...
artype = Float
artype = Num.Float
def lp2bs(b,a,wo=1,bw=1): """Return a band-stop filter with center frequency wo and bandwidth bw from a low-pass filter prototype with unity cutoff frequency. """ a,b = map(r1array,(a,b)) D = len(a) - 1 N = len(b) - 1 artype = b.typecode() if artype not in ['F','D','f','d']: artype = Float M = max([N,D]) Np = M + M Dp = M + M bprime = zeros(Np+1,artype) aprime = zeros(Dp+1,artype) wosq = wo*wo for j in range(Np+1): val = 0.0 for i in range(0,N+1): for k in range(0,M-i+1): if i+2*k == j: val += comb(M-i,k)*b[N-i]*(wosq)**(M-i-k) * bw**i bprime[Np-j] = val for j in range(Dp+1): val = 0.0 for i in range(0,D+1): for k in range(0,M-i+1): if i+2*k == j: val += comb(M-i,k)*a[D-i]*(wosq)**(M-i-k) * bw**i aprime[Dp-j] = val return normalize(bprime, aprime)
78dbcc11384c4361dd850305b138d97d4c6ff715 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12971/78dbcc11384c4361dd850305b138d97d4c6ff715/filter_design.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 12423, 22, 2038, 12, 70, 16, 69, 16, 6933, 33, 21, 16, 70, 91, 33, 21, 4672, 3536, 990, 279, 8937, 17, 5681, 1034, 598, 4617, 8670, 341, 83, 471, 20508, 12986, 628, 279, 4587, 17, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 12423, 22, 2038, 12, 70, 16, 69, 16, 6933, 33, 21, 16, 70, 91, 33, 21, 4672, 3536, 990, 279, 8937, 17, 5681, 1034, 598, 4617, 8670, 341, 83, 471, 20508, 12986, 628, 279, 4587, 17, ...
Return the subgroup of elements of that commute with every element
Return the subgroup of elements that commute with every element
def center(self): """ Return the subgroup of elements of that commute with every element of this group. EXAMPLES:: sage: G = PermutationGroup([[(1,2,3,4)]]) sage: G.center() Permutation Group with generators [(1,2,3,4)] sage: G = PermutationGroup([[(1,2,3,4)], [(1,2)]]) sage: G.center() Permutation Group with generators [()] """ C = self._gap_().Center() return PermutationGroup(gap_group=C)
1a05983ebb3835bbd44e7ffd0287f6bbaee2ac36 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9890/1a05983ebb3835bbd44e7ffd0287f6bbaee2ac36/permgroup.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4617, 12, 2890, 4672, 3536, 2000, 326, 720, 1655, 434, 2186, 716, 1543, 624, 598, 3614, 930, 434, 333, 1041, 18, 225, 5675, 8900, 11386, 2866, 225, 272, 410, 30, 611, 273, 13813, 9245, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 4617, 12, 2890, 4672, 3536, 2000, 326, 720, 1655, 434, 2186, 716, 1543, 624, 598, 3614, 930, 434, 333, 1041, 18, 225, 5675, 8900, 11386, 2866, 225, 272, 410, 30, 611, 273, 13813, 9245, ...
DIDL.Resource(mimetype=asset['mimetype'], ref=asset['url'])
DIDL.Resource(mimetype=asset['mimetype'][0], ref=asset['url'][0])
def __call__(self, element, metadata): data = metadata.record DIDL = ElementMaker(namespace=self.ns['didl'], nsmap=self.ns) DII = ElementMaker(namespace=self.ns['dii']) DIP = ElementMaker(namespace=self.ns['dip']) DCTERMS = ElementMaker(namespace=self.ns['dcterms'])
6fefa1b046b037c2e5ae0cea04fe166937c8d4c7 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/14691/6fefa1b046b037c2e5ae0cea04fe166937c8d4c7/dare_didl.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 1991, 972, 12, 2890, 16, 930, 16, 1982, 4672, 501, 273, 1982, 18, 3366, 225, 463, 734, 48, 273, 3010, 12373, 12, 4937, 33, 2890, 18, 2387, 3292, 14044, 80, 17337, 3153, 1458, 33,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1991, 972, 12, 2890, 16, 930, 16, 1982, 4672, 501, 273, 1982, 18, 3366, 225, 463, 734, 48, 273, 3010, 12373, 12, 4937, 33, 2890, 18, 2387, 3292, 14044, 80, 17337, 3153, 1458, 33,...