-
Notifications
You must be signed in to change notification settings - Fork 61.6k
/
Copy pathmatched_snippets.csv
We can make this file beautiful and searchable if this error is corrected: Illegal quoting in line 2.
3408 lines (3185 loc) · 213 KB
/
matched_snippets.csv
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
;example_id;matching_part_of_suggestion;number_of_tokens_in_matching_part_of_suggestion;number_of_matches;link_to_example_match;number_of_lines_of_context
1;efa667297f49ca5065e12e0a9743445e00ebd1c2;"x, y, u, v = 0, 1, 1, 0
while a != 0:
q, r = b // a, b % a
m, n = x - u * q, y - v * q
b, a, x, y, u, v = a, r, u, v, m, n";71;2;https://github.com/remifuhriman/numerical_computing/blob/master/Labs/RSA/solutions.py;2
2;c101dc6dd83eca9260fbfc0369979a7965240df4;\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\;97;1;https://github.com/lucamassarelli/AMFC-BRCT/blob/master/core/MetricsCollector.py;>7
3;c101dc6dd83eca9260fbfc0369979a7965240df4;\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+;99;1;https://github.com/lucamassarelli/AMFC-BRCT/blob/master/core/MetricsCollector.py;>7
4;c101dc6dd83eca9260fbfc0369979a7965240df4;\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\d+\s+\;100;1;https://github.com/lucamassarelli/AMFC-BRCT/blob/master/core/MetricsCollector.py;>7
5;7f55777d22c616ae337c2f440e38ddb311907824;\s+([0-9.]+)\s+([0-9.]+)\s+([0-9.]+)\s+([0-9.]+)\s+([0-9.]+)\s+([0-9.]+)\s+([0-9.]+)\s+([0-9.]+)',;98;1;https://github.com/dvdylus/treeCl/blob/master/bin/fast_run_raxml.py;>7
6;5d7d7b9e5d18d271ba8065b57b63c11aa62650e4;")
def forward(self, x):
x = self.pool(F.relu(self.conv1(x)))
x = self.pool(F.relu(self.conv2(x)))
x = x.view(-1, 16 * 5 * 5)
x = F.relu(self.fc1(x))
x =";75;6;https://github.com/strongio/cerbero/blob/master/examples/cifar10_example/cifar10_multitask.py;4
7;5d7d7b9e5d18d271ba8065b57b63c11aa62650e4;")
def forward(self, x):
x = self.pool(F.relu(self.conv1(x)))
x = self.pool(F.relu(self.conv2(x)))
x = x.view(-1, 16 * 5 * 5)
x = F.relu(self.fc1(x))
x =";75;6;https://github.com/strongio/cerbero/blob/master/examples/cifar10_example/cifar10_multitask.py;4
8;8fe8dc24f5255aaa660568e64cf3489b795ed621;")
stock_data = []
split_source = source_code.split('\n')
for line in split_source:
split_line = line.split(',')
if len(split_line) == 6:
if 'values' not in line and 'labels' not in line:
stock_data.append(line)";61;2;https://github.com/DIS17JTH/displayPiProject/blob/master/data_from_internet.py;>7
9;f72768d35a1bfee78c27a8c920ca4a80b27f719b;of the following questions (which you may assume is evaluated independently of the previous questions, so that testList has the value indicated above), provide an expression using applyToEach, so that after evaluation testList has the indicated value. You may need to write a simple procedure in each question to help with this process.;60;1;https://github.com/kd-nguyen/guttag/blob/master/6.00.1x/w5-apply_to_each.py;1
10;13af40cbffd29607178688e4f935be6af655d203;B/C/D/E/F/G/H/I/J/K/L/M/N/O/P/Q/R/S/T/U/V/W/X/Y/Z/0/1/2/3/4/5/6/7/8/9/;70;2;https://github.com/IronLanguages/ironpython3/blob/master/Tests/test_stdmodules.py;1
11;9ceada1552a2619b2ecd33e07321e0e5e45663b8;", cv2.COLOR_BGR2GRAY)
gray = cv2.GaussianBlur(gray, (21, 21), 0)
# if the first frame is None, initialize it
if firstFrame is None:
firstFrame = gray
continue
# compute the absolute difference between the current frame and
# first frame
frameDelta = cv2.absdiff(firstFrame, gray)
thresh = cv2.threshold(frameDelta, 25, 255, cv2.THRESH_BINARY)[1]
# dilate the thresholded image to fill in holes, then find contours
# on thresholded image
thresh = cv2.dilate(thresh, None, iterations=2)
cnts = cv2.findContours(thresh.copy(), cv2.RETR_EXTERNAL,
cv2.CHAIN_APPROX_SIMPLE)
cnts = cnts[0] if imutils.is_cv2() else cnts[1]
# loop over the contours
for c in cnts:
# if the contour is too small, ignore it
if cv2.contourArea(c) < args[""min_area""]:
continue
# compute the bounding box for the contour, draw it on the frame,
# and update the text
(x, y, w, h) = cv2.boundingRect(c)
cv2.rectangle(frame, (x, y), (x + w, y + h), (0, 255, 0), 2)
text = """;257;16;https://github.com/nishantpoorswani/motion_detection/blob/master/motion_detector.py;1
12;10035a5ef46e05f698fced88ff6a520b1fda6943;"k, a, b, a1, b1 = 2, 4, 1, 12, 4
while True:
p, q, k = k*k, 2*k+1, k+1
a, b, a1, b1 = a1, b1, p*a+q*a1, p*b+q*b1
d, d1 = a/";74;3;https://github.com/fmasanori/PPZ/blob/master/pi generator.py;>7
13;10035a5ef46e05f698fced88ff6a520b1fda6943;"k, a, b, a1, b1 = 2, 4, 1, 12, 4
while True:
p, q, k = k*k, 2*k+1, k+1
a, b, a1, b1 = a1, b1, p*a+q*a1, p*b+q*b1
d, d1 = a/";74;3;https://github.com/fmasanori/PPZ/blob/master/pi generator.py;>7
14;10035a5ef46e05f698fced88ff6a520b1fda6943;"k, a, b, a1, b1 = 2, 4, 1, 12, 4
while True:
p, q, k = k*k, 2*k+1, k+1
a, b, a1, b1 = a1, b1, p*a+q*a1, p*b+q*b1
d, d1 = a/";74;3;https://github.com/fmasanori/PPZ/blob/master/pi generator.py;>7
15;87d22e982aec01dbba1e64a84b0937cad199bda8;q, r, t, k, m, x = 10*q, 10*(r-m*t), t, k, (10*(3*q+r))//t - 10*m, x;50;1;https://github.com/steven-cutting/maths/blob/master/maths/otherpie.py;>7
16;87d22e982aec01dbba1e64a84b0937cad199bda8;q, r, t, k, m, x = q*k, (2*q+r)*x, t*x, k+1, (q*(7*k+2)+r*x)//(t*x), x+2;60;1;https://github.com/steven-cutting/maths/blob/master/maths/otherpie.py;>7
17;a4c3d2c979c489e47c250f5fd3402328044f19fa;"""""""
Calculate the great circle distance between two points
on the earth (specified in decimal degrees)
""""""
# convert decimal degrees to radians
lon1, lat1, lon2, lat2 = map(radians, [lon1, lat1, lon2, lat2])
# haversine formula
dlon = lon2 - lon1
dlat = lat2 - lat1
a = sin(dlat / 2) ** 2 + cos(lat1) * cos(lat2) * sin(dlon / 2) ** 2
c = 2 * asin(sqrt(a))
km = 6367 * c
return km";113;5;https://github.com/NervosaX/reparser/blob/master/modules/gmaps.py;6
18;2c50c483254cf60b00a276cd01eb5a5f4ae91bdc;"dlat = radians(lat2 - lat1)
dlon = radians(lon2 - lon1)
a = sin(dlat / 2) * sin(dlat / 2) + cos(radians(lat1)) * cos(radians(lat2)) * sin(dlon / 2) * sin(dlon / 2)
c = 2 * atan2(sqrt(a), sqrt(1 - a))";79;3;https://github.com/kyb3r/majorproject/blob/master/server/core/route_generation.py;6
19;8c76f07cfbfa90928d72dcf76029b44d8e9eb21c;"""""""
Calculate the great circle distance between two points
on the earth (specified in decimal degrees)
""""""
# convert decimal degrees to radians
lon1, lat1, lon2, lat2 = map(radians, [lon1, lat1, lon2, lat2])
# haversine formula
dlon = lon2 - lon1
dlat = lat2 - lat1
a = sin(dlat/2)**2 + cos(lat1) * cos(lat2) * sin(dlon/2)**2
c = 2 * asin(sqrt(a))
r = 6371 # Radius of earth in kilometers. Use 3956 for miles
return c * r";124;6;https://github.com/sarbjot-14/SFU/blob/master/cmpt353/e3/GPS_Tracks/calc_distance.py;6
20;a4c3d2c979c489e47c250f5fd3402328044f19fa;"""""""
Calculate the great circle distance between two points
on the earth (specified in decimal degrees)
""""""
# convert decimal degrees to radians
lon1, lat1, lon2, lat2 = map(radians, [lon1, lat1, lon2, lat2])
# haversine formula
dlon = lon2 - lon1
dlat = lat2 - lat1
a = sin(dlat/2)**2 + cos(lat1) * cos(lat2) * sin(dlon/2)**2
c = 2 * asin(sqrt(a))
km = 6367 * c
return km";113;5;https://github.com/NervosaX/reparser/blob/master/modules/gmaps.py;6
21;8c76f07cfbfa90928d72dcf76029b44d8e9eb21c;"""""""
Calculate the great circle distance between two points
on the earth (specified in decimal degrees)
""""""
# convert decimal degrees to radians
lon1, lat1, lon2, lat2 = map(radians, [lon1, lat1, lon2, lat2])
# haversine formula
dlon = lon2 - lon1
dlat = lat2 - lat1
a = sin(dlat / 2) ** 2 + cos(lat1) * cos(lat2) * sin(dlon / 2) ** 2
c = 2 * asin(sqrt(a))
r = 6371 # Radius of earth in kilometers. Use 3956 for miles
return c * r";124;6;https://github.com/sarbjot-14/SFU/blob/master/cmpt353/e3/GPS_Tracks/calc_distance.py;6
22;f18b0ee37075e4e0d5c31dbe7255ecca66830b10;"resp = requests.get('http://en.wikipedia.org/wiki/List_of_S%26P_500_companies')
soup = bs4.BeautifulSoup(resp.text, 'lxml')
table = soup.find('table', {'class': 'wikitable sortable'})
tickers = []
for row in table.findAll('tr')[1:]:
ticker = row.findAll('td')[0].text";94;3;https://github.com/hfk97/edgar_scraping/blob/master/menu.py;>7
23;f18b0ee37075e4e0d5c31dbe7255ecca66830b10;"resp = requests.get('http://en.wikipedia.org/wiki/List_of_S%26P_500_companies')
soup = bs4.BeautifulSoup(resp.text, 'lxml')
table = soup.find('table', {'class': 'wikitable sortable'})
tickers = []
for row in table.findAll('tr')[1:]:
ticker = row.findAll('td')[0].text";94;3;https://github.com/hfk97/edgar_scraping/blob/master/menu.py;>7
24;f18b0ee37075e4e0d5c31dbe7255ecca66830b10;"resp = requests.get('http://en.wikipedia.org/wiki/List_of_S%26P_500_companies')
soup = bs4.BeautifulSoup(resp.text,'lxml')
table = soup.find('table',{'class':'wikitable sortable'})
tickers = []
for row in table.findAll('tr')[1:]:
ticker = row.findAll('td')[0].text";94;3;https://github.com/hfk97/edgar_scraping/blob/master/menu.py;>7
25;023ba10b2acf76024e495c08ef92741a5c95480b;"print(16)
print(17)
print(18)
print(19)
print(20)
print(21)
print(22)
print(23)
print(24)
print(25)
print(26)
print(27)
print(28)
print(29)
print(30)";60;1;https://github.com/raoniteixeira/algoritmos_te/blob/master/unidade_4/2.py;>7
26;16be96e3c6cc6ac83349eee9632bb7f9765e99e8;"a = 1
b = 2
c = 3
d = 4
e = 5
f = 6
g = 7
h = 8
i = 9
j = 10
k = 11
l = 12
m = 13
n = 14
o = 15
p = 16
q = 17
r = 18
s = 19
t = 20
u = 21
v = 22
w = 23
x = 24
y = 25
z = 26";78;2;https://github.com/Wisetorsk/INF-200-Notes/blob/master/Python/ENIGMA_ord.py;>7
27;16be96e3c6cc6ac83349eee9632bb7f9765e99e8;"a = 1
b = 2
c = 3
d = 4
e = 5
f = 6
g = 7
h = 8
i = 9
j = 10
k = 11
l = 12
m = 13
n = 14
o = 15
p = 16
q = 17
r = 18
s = 19
t = 20
u = 21
v = 22
w = 23
x = 24
y = 25
z = 26";78;2;https://github.com/Wisetorsk/INF-200-Notes/blob/master/Python/ENIGMA_ord.py;>7
28;8ea4e63c0d203860c4f59de75d87344671a383ec;/query.yahooapis.com/v1/public/yql?q=select%20*%20from%20weather.forecast%20where%20woeid%20in%20(select%20woeid%20from%20geo.places(1)%20where%20text%3D%22nome%2C%20ak%22)&format=json&env=store%3A%;72;2;https://github.com/sirinenisaikiran/Python/blob/master/Traning/PyQs-master/PyQs-master/python-initial-reference/ToBeShared/reference/Code/web/flask/weather.py;>7
29;6b5df31137bd436722936c6357a8dfe955215a86;"Return a list of all items in this linked list.
Best and worst case running time: Theta(n) for n items in the list
because we always need to loop through all n nodes.""""""
# Create an empty list of results
result = [] # Constant time to create a new list
# Start at the head node
node = self.head # Constant time";75;2;https://github.com/asha952/cs-1.3_algorithms/blob/master/linked_list.py;2
30;6b5df31137bd436722936c6357a8dfe955215a86;"Return a list of all items in this linked list.
Best and worst case running time: Theta(n) for n items in the list
because we always need to loop through all n nodes.""""""
# Create an empty list of results
result = [] # Constant time to create a new list
# Start at the head node
node = self.head";72;2;https://github.com/asha952/cs-1.3_algorithms/blob/master/linked_list.py;4
31;5d1cabb5ea56ef3ac8607c9ea420c56678ae6e7b;,5,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,3,;81;2;https://github.com/JulienAndres/p_androidKilobot/blob/master/mEDEA/stats_robot/test.py;>7
32;aa914b233c39f2bba9f9ca3425eb0adb631a43fc;")
response.raise_for_status()
analysis = response.json()
# Extract the word bounding boxes and text.
line_infos = [region[""lines""] for region in analysis[""regions""]]
word_infos = []
for line in line_infos:
for word_metadata in line:
for word_info in word_metadata[""words""]:
word_infos.append(word_info)";71;5;https://github.com/pziajski/ZRecognition/blob/master/AzureImageRecognition.py;>7
33;c94cf9a0235e7137f88385ab5c88ae6369e736c8;"headers = {'Ocp-Apim-Subscription-Key': subscription_key, 'Content-Type': 'application/octet-stream'}
params = {'language': 'unk', 'detectOrientation ': 'true'}
data = {'url': image_url}
response = requests.post(";63;3;https://github.com/aayushvats/med_id/blob/master/ocr.py;>7
34;00f38ab64ac06074049b0dde2efdba6d52214313;"image_data = open(image_path, ""rb"").read()
headers = {'Ocp-Apim-Subscription-Key': subscription_key,
'Content-Type': 'application/octet-stream'}
params = {'visualFeatures': 'Categories,Description,Color'}
response = requests.post(analyze_url, headers=headers, params=params, data=image_data)
response.raise_for_status()
# The 'analysis' object contains various fields that describe the image. The most
# relevant caption for the image is obtained from the 'description' property.
analysis = response.json()
image_caption = analysis[""description""][""captions""][0][""text""].capitalize()";146;6;https://github.com/vishnoitanuj/Azure-tutorials/blob/master/Video_Analysis.py;>7
35;910dc45b477682df33a75979ecb8932612776c35;"""
image_data = open(image_path, ""rb"").read()
headers = {'Ocp-Apim-Subscription-Key': subscription_key,
'Content-Type': 'application/octet-stream'}
params = {'visualFeatures': 'Categories,Description,Color'}
response = requests.post(
analyze_url, headers=headers, params=params, data=image_data)
response.raise_for_status()
analysis = response.json()";91;4;https://github.com/nrjvarshney/QuoteFromPic/blob/master/quotesServer/quotesServer/quoteapi/views.py;>7
36;f0bc867888c48e59d98da85a88da423465d13d10;"vision_base_url = ""https://westcentralus.api.cognitive.microsoft.com/vision/v2.0/""
ocr_url = vision_base_url + ""ocr""
headers = {'Ocp-Apim-Subscription-Key': subscription_key, 'Content-Type': 'application/octet-stream'}
params = {'language': 'unk', 'detectOrientation': 'true'}";79;3;https://github.com/Ujjwal0501/hallucinators/blob/master/Text_Gen.py;>7
37;02fce827f849a37fd59ba18a70852fa1bca546af;")
response.raise_for_status()
analysis = response.json()
# Extract the word bounding boxes and text.
line_infos = [region[""lines""] for region in analysis[""regions""]]
word_infos = []
for line in line_infos:
for word_metadata in line:
for word_info in word_metadata[""words""]:
word_infos.append(word_info)";71;3;https://github.com/WeiShi78/Xbuyer/blob/master/test/Test.py;>7
38;910dc45b477682df33a75979ecb8932612776c35;"assert subscription_key
vision_base_url = ""https://westcentralus.api.cognitive.microsoft.com/vision/v2.0/""
analyze_url = vision_base_url + ""analyze""
image_data = open(image_path, ""rb"").read()
headers = {'Ocp-Apim-Subscription-Key': subscription_key,
'Content-Type': 'application/octet-stream'}
params = {'visualFeatures': 'Categories,Description,Color'}
response = requests.post(analyze_url, headers=headers, params=params, data=image_data)
response.raise_for_status()
analysis = response.json()";123;5;https://github.com/nrjvarshney/QuoteFromPic/blob/master/quotesServer/quotesServer/quoteapi/views.py;>7
39;f75875be86f0f17fc3e9aae98f743f02982e444a;"= [""2000"", ""2001"", ""2002"", ""2003"", ""2004"", ""2005"", ""2006"", ""2007"", ""2008"", ""2009"", ""2010"", ""2011"", ""2012"", ""2013"",
""2014"", ""2015"", ""2016"", ""2017""]";74;2;https://github.com/DaviPolita/Dashboards/blob/master/Plotly_Graphs/Animated_Scatter/gender_ineq.py;>7
40;876ad13e615cda2592f907c2739e09faa21477d4;"""2016"", ""2015"", ""2014"", ""2013"", ""2012"", ""2011"", ""2010"", ""2009"", ""2008"", ""2007"", ""2006"", ""2005"", ""2004"", ""2003"", ""2002"", ""2001"", ""2000"", ""1999"", ""1998"", ""1997""";79;2;https://github.com/abhinavbansal19961996/Advocatefinal/blob/master/update.py;>7
41;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";77;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;2
42;47081907e60f9f9cab0effee35db245a5b7003a6;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;2
43;5e9c280ba82bbe9237fe3f8dff0c82dce3bdcf5e;"):
less = []
equal = []
greater = []
if len(array) > 1:
pivot = array[0]
for x in array:
if x < pivot:
less.append(x)
if x == pivot:
equal.append(x)
if x > pivot:
greater.append(x)
return";68;2;https://github.com/morganhowell95/Algorithms/blob/master/Comparison-Sorts/quick_sort.py;2
44;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";77;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;2
45;47081907e60f9f9cab0effee35db245a5b7003a6;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;2
46;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";77;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;2
47;47081907e60f9f9cab0effee35db245a5b7003a6;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;2
48;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";77;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;2
49;21f646e28b5aa5d074688a587f8cc16d2d05a5b0;"a):
if len(a) <= 1:
return a
pivot = a[len(a) // 2]
left = [x for x in a if x < pivot]
middle = [x for x in a if x == pivot]
right = [x for x in a if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;2;https://github.com/chitn/Algorithms-illustrated-by-Python/blob/master/example/quick_sort.py;2
50;2edbc61bf0f23c785b94c3dd6b178bbc94127f35;"lista):
if len(lista) <= 1:
return lista
pivo = lista[0]
iguais = [x for x in lista if x == pivo]
menores = [x for x in lista if x < pivo]
maiores = [x for x in lista if x > pivo]
return quicksort(menores) +";66;3;https://github.com/AAMergulhao/Sort_Algorithms/blob/master/algorithms.py;2
51;7457f881c1b82d80957b8acf1859a4a73a7e88b4;"array):
if len(array) <= 1:
return array
pivot = array[len(array) // 2]
left = [x for x in array if x < pivot]
middle = [x for x in array if x == pivot]
right = [x for x in array if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;4;https://github.com/fali007/basic-programming/blob/master/sorting/quicksort.py;2
52;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";77;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;2
53;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";77;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;2
54;7457f881c1b82d80957b8acf1859a4a73a7e88b4;"array):
if len(array) <= 1:
return array
pivot = array[len(array) // 2]
left = [x for x in array if x < pivot]
middle = [x for x in array if x == pivot]
right = [x for x in array if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;4;https://github.com/fali007/basic-programming/blob/master/sorting/quicksort.py;2
55;d730f06e052b92b5241b0feb5b7436ad708f79b1;"arr):
if len(arr) <= 1:
return arr
else:
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";79;6;https://github.com/yvprashanth/python-google-tutorial/blob/master/basic/quicksort.py;2
56;47081907e60f9f9cab0effee35db245a5b7003a6;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;2
57;47081907e60f9f9cab0effee35db245a5b7003a6;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;2
58;be05fb926bf6d0f5b10addd65a7bd26bf41a466e;"# Plot the decision boundary. For that, we will assign a color to each
# point in the mesh [x_min, x_max]x[y_min, y_max].
x_min, x_max = X[:, 0].min() - .5, X[:, 0].max() + .5
y_min, y_max = X[:, 1].min() - .5, X[:, 1].";89;2;https://github.com/mszhai/nlp_algo/blob/master/test/pd.py;1
59;c054698149636d13ae8ad1ed97459812d0d1ebbc;"fig = plt.figure()
ax = fig.add_subplot(111, projection='3d')
n = 100
for c, m, zl, zh in [('r', 'o', -50, -25), ('b', '^', -30, -5)]:
xs = randrange(n, 23, 32)
ys = randrange(n, 0, 100)
zs = randrange(n, zl, zh)
ax.scatter(xs, ys, zs, c=c, marker=m)";115;5;https://github.com/afding/mylab/blob/master/algrithm/3dplot.demo.py;0
60;f4e6dcf3008410acb9d95b2ba78645b12f5eebf8;"]x[y_min, y_max].
x_min, x_max = X[:, 0].min() - .5, X[:, 0].max() + .5
y_min, y_max = X[:, 1].min() - .5, X[:, 1].max() + .5
xx, yy = np.meshgrid(np.arange(x_min, x_max, h), np.arange(y_min, y_max, h))
Z = clf.predict(np.c_[xx.ravel(), yy.ravel()])
# Put the result into a color plot
Z = Z.reshape(xx.shape)
pl.figure(1, figsize=(4, 3))
pl.pcolormesh(xx, yy, Z, cmap=pl.cm.Paired)
# Plot also the training points
pl.scatter(X[:, 0], X[:, 1], c=Y,
⋯
, cmap=pl.cm.Paired)
pl.xlabel('Sepal length')
pl.ylabel('Sepal width')
pl.xlim(xx.min(), xx.max())
pl.ylim(yy.min(), yy.max())
pl.xticks(())
pl.yticks(())
pl.show()";279;14;https://github.com/v3ss0n/scikit-learn/blob/master/examples/svm/plot_svm_iris.py;0
61;a80fef7436689974cff2664b4a0e8160c74a06a2;"from matplotlib import rc
rc('font',**{'family':'sans-serif','sans-serif':['Helvetica']})
## for Palatino and other serif fonts use:
#rc('font',**{'family':'serif','serif':['Palatino']})
rc('text', usetex=True)";85;5;https://github.com/kmandli/ML-python-code-without-LIBRARIES/blob/master/linear_regression_cost_function.py;0
62;c690d3284caf91996572b047fbe5425c93d8e25e;"')
# Data for three-dimensional scattered points
zdata = 15 * np.random.random(100)
xdata = np.sin(zdata) + 0.1 * np.random.randn(100)
ydata = np.cos(zdata) + 0.1 * np.random.randn(100)
ax.scatter3D(xdata, ydata, zdata, c=zdata, cmap='";81;3;https://github.com/TheRealMarcusChiu/PythonMasterExample/blob/master/src/third-party/03_graphs/3d/scatter.py;0
63;9303cf4b43f8b33a958f1b0025bd2a07f2798e80;"# Importing the dataset
dataset = pd.read_csv('Social_Network_Ads.csv')
X = dataset.iloc[:, [2, 3]].values
y = dataset.iloc[:, 4].values
# Splitting the dataset into the Training set and Test set
from sklearn.cross_validation import train_test_split
X_train, X_test, y_train, y_test = train_test_split(X, y, test_size = 0.25, random_state = 0)
# Feature Scaling
from sklearn.preprocessing import StandardScaler
sc = StandardScaler()
X_train = sc.fit_transform(X_train)
X_test = sc.transform(X_test)
# Fitting classifier to the Training set
from sklearn.svm import SVC
classifier = SVC(kernel = 'linear', random_state = 0)
classifier.fit(X_train, y_train)
# Predicting the Test set results
y_pred = classifier.predict(X_test)
# Making the Confusion Matrix
from sklearn.metrics import confusion_matrix
cm = confusion_matrix(y_test, y_pred)
# Visualising the Training set results
from matplotlib.colors import ListedColormap
X_set, y_set = X_train, y_train
X1, X2 = np.meshgrid(np.arange(start = X_set[:, 0].min() - 1, stop = X_set[:, 0].max() + 1, step = 0.01),
np.arange(start = X_set[:, 1].min() - 1, stop = X_set[:, 1].max() + 1, step = 0.01))
plt.contourf(X1, X2, classifier.predict(np.array([X1.ravel(), X2.ravel()]).T).reshape(X1.shape),
alpha = 0.75, cmap =";341;22;https://github.com/ranasingh-gkp/Machine-Learning/blob/master/Part 3 - Classification/Section 16 - Support Vector Machine (SVM)/Python_SVM.py;0
64;5e9c280ba82bbe9237fe3f8dff0c82dce3bdcf5e;"):
less = []
equal = []
greater = []
if len(array) > 1:
pivot = array[0]
for x in array:
if x < pivot:
less.append(x)
if x == pivot:
equal.append(x)
if x > pivot:
greater.append(x)
return";68;2;https://github.com/morganhowell95/Algorithms/blob/master/Comparison-Sorts/quick_sort.py;2
65;47081907e60f9f9cab0effee35db245a5b7003a6;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;2
66;47081907e60f9f9cab0effee35db245a5b7003a6;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;2
67;68813c1284352872db9a5abdaaaabf8c8e21c16d;['MMM','AXP','AAPL','BA','CAT','CVX','CSCO','KO','DIS','DWDP','XOM','GE','GS','HD','IBM','INTC','JNJ','JPM','MCD','MRK','MSFT','NKE','PFE','PG','TRV','UTX',';106;3;https://github.com/parsa3000/SE18/blob/master/stockgame2/home/listofstockscrypto.py;>7
68;6bcafa51129e5a18509ab485a4623450ff916b71;"get('https://en.wikipedia.org/wiki/List_of_S%26P_500_companies')
soup = bs4.BeautifulSoup(resp.text, 'lxml')
table = soup.find('table', {'class': 'wikitable sortable'})
tickers = []
for row in table.findAll('tr')[1:]:
ticker = row.findAll('td')[0].text";90;2;https://github.com/juliennassar/stock-analyser/blob/master/server/server.py;>7
69;3a162697d1abaa9ffb4d3f14ff97828c642ea427;= ['MMM','AXP','AAPL','BA','CAT','CVX','CSCO','KO','DIS','DD','XOM','GE','GS','HD','IBM','INTC','JNJ','JPM','MCD','MRK','MSFT','NKE','PFE','PG',';99;2;https://github.com/quentintruong/Stocks-Scraper/blob/master/stocks/spiders/stocks_spider.py;>7
70;4992ed94b48a8e1e5d77f8c13a21258f20e616bb;= ['MMM','AXP','AAPL','BA','CAT','CVX','CSCO','KO','DIS','XOM','GE','GS','HD','IBM','INTC','JNJ','JPM','MCD','MRK','MSFT','NKE','PFE','PG','UTX','UNH','VZ',';107;3;https://github.com/jiewwantan/StarTrader/blob/master/compare.py;>7
71;fba9c49e384d6e3bb736c3f5c161afd2f0d1506d;= ['MMM','AXP','AAPL','BA','CAT','CVX','CSCO','KO','DIS','XOM','GE','GS','HD','IBM','INTC','JNJ','JPM','MCD','MRK','MSFT','NKE','PFE','PG','TRV','UTX','UNH','VZ',';111;4;https://github.com/1kc2/Minimal-Correlation-Portfolio/blob/master/stocks.py;>7
72;4992ed94b48a8e1e5d77f8c13a21258f20e616bb;= ['MMM','AXP','AAPL','BA','CAT','CVX','CSCO','KO','DIS','XOM','GE','GS','HD','IBM','INTC','JNJ','JPM','MCD','MRK','MSFT','NKE','PFE','PG','UTX','UNH','VZ',';107;3;https://github.com/jiewwantan/StarTrader/blob/master/compare.py;>7
73;886bc47941eadd52a758206094854c8505d85410;', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z';101;5;https://github.com/andrewmagis/docker/blob/master/ipython-dev/Qiime/qiime/split_libraries_fastq.py;0
74;5b2bf24b4ae3a8c68dc4e52c1e5bdca89af216c4;= {0:0, 1:1, 2:2, 3:3, 4:4, 5:5, 6:6, 7:7, 8:8, 9:9, 10:10, 11:11, 12:12, 13:13, 14:14, 15:15, 16:16, 17:17, 18:18, 19:19, 20:20, 21:21, 22:22, 23:23, 24:;100;3;https://github.com/cnrat/dec-eve-serenity/blob/master/client/encodings/cp864.py;1
75;5b2bf24b4ae3a8c68dc4e52c1e5bdca89af216c4;= {0:0, 1:1, 2:2, 3:3, 4:4, 5:5, 6:6, 7:7, 8:8, 9:9, 10:10, 11:11, 12:12, 13:13, 14:14, 15:15, 16:16, 17:17, 18:18, 19:19, 20:20, 21:21, 22:22, 23:23, 24:;100;3;https://github.com/cnrat/dec-eve-serenity/blob/master/client/encodings/cp864.py;1
76;971a5155a320a23115a41d16f14b6ccc6ffe9801;1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48,;96;3;https://github.com/peruzzim/cmg-cmssw/blob/master/HLTrigger/Configuration/test/OnLine_HLT_PRef.py;>7
77;af4b00fee4953dec519c7e35e3163f60609466dc;s[0],s[1],s[2],s[3],s[4],s[5],s[6],s[7],s[8],s[9],s[10],s[11],s[12],s[13],s[14],s[15],s[16],s[17];89;4;https://github.com/wjwainwright/Capstone/blob/master/IsoFitv18.py;>7
78;eb3ae194c4c2eb8719db5c353485c3e31831f1ac;"VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)"",
tuple(";64;4;https://github.com/labopvlab/PythonDataAnalyzer/blob/master/apps/mergingDBs_v1.py;>7
79;8f0abf15d48fe3c7357ed453ba8bb45dbd536d07;"lon1, lat1, lon2, lat2 = map(radians, [lon1, lat1, lon2, lat2])
dlon = lon2 - lon1
dlat = lat2 - lat1
a = sin(dlat / 2) ** 2 + cos(lat1) * cos(lat2) * sin(dlon / 2) ** 2
c = 2 * asin(sqrt(a))
r = 6371
return c * r * 1000";83;6;https://github.com/TimothyLx/Mining-method-based-on-semantic-trajectory-frequent-pattern-and-carpooling-application/blob/master/distance_calculate.py;6
80;a4c3d2c979c489e47c250f5fd3402328044f19fa;"""""""
Calculate the great circle distance between two points
on the earth (specified in decimal degrees)
""""""
# convert decimal degrees to radians
lon1, lat1, lon2, lat2 = map(radians, [lon1, lat1, lon2, lat2])
# haversine formula
dlon = lon2 - lon1
dlat = lat2 - lat1
a = sin(dlat/2)**2 + cos(lat1) * cos(lat2) * sin(dlon/2)**2
c = 2 * asin(sqrt(a))
km = 6367 * c
return km";113;5;https://github.com/NervosaX/reparser/blob/master/modules/gmaps.py;6
81;a4c3d2c979c489e47c250f5fd3402328044f19fa;"""""""
Calculate the great circle distance between two points
on the earth (specified in decimal degrees)
""""""
# convert decimal degrees to radians
lon1, lat1, lon2, lat2 = map(radians, [lon1, lat1, lon2, lat2])
# haversine formula
dlon = lon2 - lon1
dlat = lat2 - lat1
a = sin(dlat/2)**2 + cos(lat1) * cos(lat2) * sin(dlon/2)**2
c = 2 * asin(sqrt(a))
km = 6367 * c
return km";113;5;https://github.com/NervosaX/reparser/blob/master/modules/gmaps.py;6
82;8c76f07cfbfa90928d72dcf76029b44d8e9eb21c;"# convert decimal degrees to radians
lon1, lat1, lon2, lat2 = map(radians, [lon1, lat1, lon2, lat2])
# haversine formula
dlon = lon2 - lon1
dlat = lat2 - lat1
a = sin(dlat / 2) ** 2 + cos(lat1) * cos(lat2) * sin(dlon / 2) ** 2
c = 2 * asin(sqrt(a))
r = 6371 # Radius of earth in kilometers. Use 3956 for miles
return c * r";101;5;https://github.com/sarbjot-14/SFU/blob/master/cmpt353/e3/GPS_Tracks/calc_distance.py;6
83;b3326f25c405bab05ae8898a978dcd1bb27358b0;"parser = argparse.ArgumentParser(description='PyTorch CIFAR10 Training')
parser.add_argument('--lr', default=0.1, type=float, help='learning rate')
parser.add_argument('--resume', '-r', action='store_true', help='resume from checkpoint')
args = parser.parse_args()";77;5;https://github.com/THULimy/pytorch-Hscore/blob/master/cifar-resnet.py;1
84;21f646e28b5aa5d074688a587f8cc16d2d05a5b0;"a):
if len(a) <= 1:
return a
pivot = a[len(a) // 2]
left = [x for x in a if x < pivot]
middle = [x for x in a if x == pivot]
right = [x for x in a if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;2;https://github.com/chitn/Algorithms-illustrated-by-Python/blob/master/example/quick_sort.py;1
85;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";77;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;1
86;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";77;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;1
87;47081907e60f9f9cab0effee35db245a5b7003a6;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;1
88;47081907e60f9f9cab0effee35db245a5b7003a6;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;1
89;fde8fae9d13625d97b7d39342bbc9100a42cf8d9;= ['Date/Time', 'Temp (°C)', 'Dew Point Temp (°C)', 'Rel Hum (%)', 'Wind Dir (10s deg)', 'Wind Spd (km/h)', 'Visibility (km)', 'Stn Press (kPa)', ';69;4;https://github.com/patrickacheung/weather-tod-predictor/blob/master/clean_weather.py;>7
90;f2ed15c0121fc4d4ab8d3c0c87c3c745aa05853f;= ['Date/Time', 'Year', 'Month', 'Day', 'Time', 'Data Quality', 'Temp (°C)', 'Temp Flag', 'Dew Point Temp (°C)', 'Dew Point Temp Flag', 'Rel Hum (%)', 'Rel Hum Flag', 'Wind Dir;76;3;https://github.com/iss4e/webike-toolchain/blob/master/webike/data/WeatherGC.py;>7
91;8288745b3d457294b33551ac7a3d6d8d391c44fa;"headers = {
'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.77 Safari/537.36'
}
response = requests.get(url, headers=headers)";65;2;https://github.com/ZhekunInc/football-wiki/blob/master/src/scraping/management/commands/fifa_country.py;4
92;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";77;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;1
93;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";77;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;1
94;47081907e60f9f9cab0effee35db245a5b7003a6;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;1
95;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr)/2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";77;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;1
96;47081907e60f9f9cab0effee35db245a5b7003a6;"arr):
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";78;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;1
97;47081907e60f9f9cab0effee35db245a5b7003a6;":
if len(arr) <= 1 :
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";76;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;1
98;47081907e60f9f9cab0effee35db245a5b7003a6;":
if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";76;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;1
99;47081907e60f9f9cab0effee35db245a5b7003a6;":
if len(arr) <= 1 :
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";76;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;1
100;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"if len(arr) <= 1:
return arr
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";74;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;1
101;47081907e60f9f9cab0effee35db245a5b7003a6;"if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";75;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;1
102;47081907e60f9f9cab0effee35db245a5b7003a6;"if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";75;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;1
103;47081907e60f9f9cab0effee35db245a5b7003a6;"if len(arr) <= 1:
return arr
pivot = arr[len(arr) // 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";75;3;https://github.com/Tryking/DeepLearning/blob/master/cs231n/assignment1/1_python_numpy_tutorial/1_python.py;1
104;4118a938ea514437331aa7c8b9a9e0e1a398d8d7;"if len(arr) <= 1:
return arr
pivot = arr[len(arr) / 2]
left = [x for x in arr if x < pivot]
middle = [x for x in arr if x == pivot]
right = [x for x in arr if x > pivot]
return quicksort(left) + middle + quicksort(right)";74;6;https://github.com/Muzijiajian/AppliedMathmaticsForComputer/blob/master/hw0/python_tutorial.py;1
105;971a5155a320a23115a41d16f14b6ccc6ffe9801;1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49;97;3;https://github.com/peruzzim/cmg-cmssw/blob/master/HLTrigger/Configuration/test/OnLine_HLT_PRef.py;4
106;43d142060c012adf5436e71991f17b8e81168311;[-1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,;439;1;https://github.com/youngminpark2559/temp_for_study/blob/master/study_huggingface_NLP/examples/My_test/Test_BERT_LM_model.py;1
107;9ebe0da4eabfbbd56a5cdd9704fb6c3872162936;"Config(object):
SECRET_KEY = os.environ.get('SECRET_KEY') or 'you-will-never-guess'
SQLALCHEMY_DATABASE_URI = os.environ.get('DATABASE_URL') or \
'sqlite:///' + os.path.join(basedir, 'app.db')
SQLALCHEMY_TRACK_MODIFICATIONS = False
MAIL_SERVER = os.environ.get('MAIL_SERVER')
MAIL_PORT = int(os.environ.get('MAIL_PORT') or 25)
MAIL_USE_TLS = os.environ.get('MAIL_USE_TLS') is not None
MAIL_USERNAME = os.environ.get('MAIL_USERNAME')
MAIL_PASSWORD = os.environ.get(";130;4;https://github.com/vitalii-levko/microblog/blob/master/microblog/config.py;2
108;9ebe0da4eabfbbd56a5cdd9704fb6c3872162936;"Config(object):
SECRET_KEY = os.environ.get('SECRET_KEY') or 'you-will-never-guess'
SQLALCHEMY_DATABASE_URI = os.environ.get('DATABASE_URL') or \
'sqlite:///' + os.path.join(basedir, 'app.db')
SQLALCHEMY_TRACK_MODIFICATIONS = False
MAIL_SERVER = os.environ.get('MAIL_SERVER')
MAIL_PORT = int(os.environ.get('MAIL_PORT') or 25)
MAIL_USE_TLS = os.environ.get('MAIL_USE_TLS') is not None
MAIL_USERNAME = os.environ.get('MAIL_USERNAME')
MAIL_PASSWORD = os.environ.get(";130;4;https://github.com/vitalii-levko/microblog/blob/master/microblog/config.py;2
109;59b316cdb58c43d28de33d284ed7b8ac9bab06ba;if y != '0' and y != '1' and y != '2' and y != '3' and y != '4' and y != '5' and y != '6' and y != '7' and y != '8' and y != '9' and y != ';75;2;https://github.com/duongd08/CECS-174-Spring-2018/blob/master/Uno.py;>7
110;8b515e8a34021fe09632bd8387ef3a9734bb1c1b;', 'AMD', 'AES', 'AET', 'AMG', 'AFL', 'A', 'APD', 'AKAM', 'ALK', 'ALB', 'ARE', 'ALXN', 'ALGN', 'ALLE', 'AGN', 'ADS', 'LNT;68;2;https://github.com/rorygwozdz/coding/blob/master/finance/gcg/image_creator.py;>7
111;7ebb786cd066594187910cfba3b3e58c3603b02d;', 'AES', 'AET', 'AMG', 'AFL', 'A', 'APD', 'AKAM', 'ALK', 'ALB', 'ARE', 'ALXN', 'ALGN', 'ALLE', 'AGN', 'ADS', 'LNT', 'ALL', 'GOOGL', 'GOOG', 'MO', 'AMZN', 'AEE', 'AAL', 'AEP', 'AXP', 'AIG', 'AMT', 'AWK', 'AMP', 'ABC', 'AME', 'AMGN', 'APH', 'APC', 'ADI', 'ANDV', 'ANSS', 'ANTM', 'AON', 'AOS', 'APA', 'AIV', 'AAPL', 'AMAT', 'APTV', 'ADM', 'ARNC', 'AJG', 'AIZ', 'T', 'ADSK', 'ADP', 'AZO', 'AVB', 'AVY', ';223;15;https://github.com/Shiva-gs/Project3/blob/master/stock_data.py;>7
112;7ebb786cd066594187910cfba3b3e58c3603b02d;', 'ALL', 'GOOGL', 'GOOG', 'MO', 'AMZN', 'AEE', 'AAL', 'AEP', 'AXP', 'AIG', 'AMT', 'AWK', 'AMP', 'ABC', 'AME', 'AMGN', 'APH', 'APC', 'ADI', 'ANDV', 'ANSS', 'ANTM', 'AON', 'AOS', 'APA', 'AIV', 'AAPL', 'AMAT', 'APTV', 'ADM', 'ARNC', 'AJG', 'AIZ', 'T', 'ADSK', 'ADP', 'AZO', 'AVB', 'AVY', 'BHGE', 'BLL', 'BAC', 'BK', 'BAX', 'BBT', 'BDX', 'BRK.B', 'BBY', 'BIIB', 'BLK', 'HRB', 'BA', 'BWA', 'BXP', 'BSX',;224;10;https://github.com/Shiva-gs/Project3/blob/master/stock_data.py;>7
113;7ebb786cd066594187910cfba3b3e58c3603b02d;', 'AES', 'AET', 'AMG', 'AFL', 'A', 'APD', 'AKAM', 'ALK', 'ALB', 'ARE', 'ALXN', 'ALGN', 'ALLE', 'AGN', 'ADS', 'LNT', 'ALL', 'GOOGL', 'GOOG', 'MO', 'AMZN', 'AEE', 'AAL', 'AEP', 'AXP', 'AIG', 'AMT', 'AWK', 'AMP', 'ABC', 'AME', 'AMGN', 'APH', 'APC', 'ADI', 'ANDV', 'ANSS', 'ANTM', 'AON', 'AOS', 'APA', 'AIV', 'AAPL', 'AMAT', 'APTV', 'ADM', 'ARNC', 'AJG', 'AIZ', 'T', 'ADSK', 'ADP', 'AZO', 'AVB', 'AVY', 'BHGE', 'BLL', 'BAC', 'BK', 'BAX', 'BBT', 'BDX', 'BRK.B', 'BBY', 'BIIB', 'BLK', 'HRB', 'BA', 'BWA', 'BXP', 'BSX', 'BHF', 'BMY', 'AVGO', 'BF.B', 'CHRW', 'CA', 'COG', ';319;19;https://github.com/Shiva-gs/Project3/blob/master/stock_data.py;>7
114;687774b16d0478f4bf1aca760b628253d21d3267;"if n == 1:
return False
elif n < 4:
return True
elif n%2 == 0:
return False
elif n < 9:
return True
elif n%3 == 0:
return False
else:
r = int(n**0.5)
f = 5
while f <= r:
if n%f == 0:
return False";74;3;https://github.com/redmechanic/My-Project-Euler-Solutions/blob/master/Problem 27/prime_quadratic.py;2
115;c61d42e2a6eaf8c9c9b03d4ebc15e6a9ec999768;"print(now.strftime(""%Y-%m-%d %H:%M:%S""))
print(now.strftime(""%Y-%m-%d""))
print(now.strftime(""%H:%M:%S""))";62;2;https://github.com/contsman/pythonweb/blob/master/testpython/Commonly_used_builtin_module.py;>7
116;964357c438769c177a2c14743aa82fa875ac2d80;",
""Intended Audience :: Developers"",
""License :: OSI Approved :: Apache Software License"",
""Operating System :: OS Independent"",
""Programming Language :: Python"",
""Programming Language :: Python :: 2"",
""Programming Language :: Python :: 2.7"",
""Programming Language :: Python :: 3"",
""Programming Language :: Python :: 3.4"",
""Programming Language :: Python :: 3.5"",
""Programming Language :: Python :: 3.6"",
""Programming Language :: Python :: 3.7"",
""Programming Language :: Python :: 3.8"",
""";140;8;https://github.com/da-woods/cython/blob/master/setup.py;>7
117;964357c438769c177a2c14743aa82fa875ac2d80;""",
""Programming Language :: Python :: 2.7"",
""Programming Language :: Python :: 3"",
""Programming Language :: Python :: 3.4"",
""Programming Language :: Python :: 3.5"",
""Programming Language :: Python :: 3.6"",
""Programming Language :: Python :: 3.7"",
""Programming Language :: Python :: 3.8"",
""Programming Language :: Python :: Implementation :: CPython"",
""Programming Language :: Python :: Implementation :: PyPy"",";119;6;https://github.com/da-woods/cython/blob/master/setup.py;>7
118;1324ed920d6ad53fd3322f862703051161d16b4f;"@gmail.com"",
license=""MIT"",
classifiers=[
""Development Status :: 3 - Alpha"",
""Intended Audience :: Developers"",
""Topic :: Software Development :: Build Tools"",
""License :: OSI Approved :: MIT License"",
""Programming Language :: Python :: 3";66;3;https://github.com/ylathouris/glossy/blob/master/setup.py;>7
119;9da3365c7b91281b7073c07c495ff3033dfaa543;"(G, start, end=None):
""""""
Find shortest paths from the start vertex to all
vertices nearer than or equal to the end.
The input graph G is assumed to have the following
representation: A vertex can be any object that can
be used as an index into a dictionary. G is a
dictionary, indexed by vertices. For any vertex v,
G[v] is itself a dictionary, indexed by the neighbors
of v. For any edge v->w, G[v][w] is the length of
the edge. This is related to the representation in
<http://www.python.org/doc/essays/graphs.html>
where Guido van Rossum suggests representing graphs
as dictionaries mapping vertices to lists of neighbors,
however dictionaries of edges have many advantages
over lists: they can store extra information (here,
the lengths), they support fast existence tests,
and they allow easy modification of the graph by edge
insertion and removal. Such modifications are not
needed here but are important in other graph algorithms.
Since dictionaries obey iterator protocol, a graph
represented as described here could be handed without
modification to an algorithm using Guido's representation.
Of course, G and G[v] need not be Python dict objects;
they can be any other object that obeys dict protocol,
for instance a wrapper in which vertices are URLs
and a call to G[v] loads the web page and finds its links.
The output is a pair (D,P) where D[v] is the distance
from start to v and P[v] is the predecessor of v along
the shortest path from s to v.
Dijkstra's algorithm is only guaranteed to work correctly
when all edge lengths are positive. This code does not
verify this property for all edges (only the edges seen
before the end vertex is reached), but will correctly
compute shortest paths even for some graphs with negative
edges, and will raise an exception if it discovers that
a negative edge";396;18;https://github.com/bachiraoun/pdbparser/blob/master/Utilities/Collection.py;2
120;9da3365c7b91281b7073c07c495ff3033dfaa543;"(G, start, end=None):
""""""
Find shortest paths from the start vertex to all
vertices nearer than or equal to the end.
The input graph G is assumed to have the following
representation: A vertex can be any object that can
be used as an index into a dictionary. G is a
dictionary, indexed by vertices. For any vertex v,
G[v] is itself a dictionary, indexed by the neighbors
of v. For any edge v->w, G[v][w] is the length of
the edge. This is related to the representation in
<http://www.python.org/doc/essays/graphs.html>
where Guido van Rossum suggests representing graphs
as dictionaries mapping vertices to lists of neighbors,
however dictionaries of edges have many advantages
over lists: they can store extra information (here,
the lengths), they support fast existence tests,
and they allow easy modification of the graph by edge
insertion and removal. Such modifications are not
needed here but are important in other graph algorithms.
Since dictionaries obey iterator protocol, a graph
represented as described here could be handed without
modification to an algorithm using Guido's representation.
Of course, G and G[v] need not be Python dict objects;
they can be any other object that obeys dict protocol,
for instance a wrapper in which vertices are URLs
and a call to G[v] loads the web page and finds its links.
The output is a pair (D,P) where D[v] is the distance
from start to v and P[v] is the predecessor of v along
the shortest path from s to v.
Dijkstra's algorithm is only guaranteed to work correctly
when all edge lengths are positive. This code does not
verify this property for all edges (only the edges seen
before the end vertex is";367;17;https://github.com/bachiraoun/pdbparser/blob/master/Utilities/Collection.py;2
121;b32657aa5d791091bd6992730a1a48d8b4b1152f;= {'Name':pd.Series(['Tom','James','Ricky','Vin','Steve','Minsu','Jack','Lee','David','Gasper','Betina','Andres']),;61;1;https://github.com/wojiaolds/python-test/blob/master/pandas_test/dataframe_base.py;3
122;209e809060efff74c137c9b7c69d5d5168bff92a;2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 9, 9, 9, 9, 10, 10, 10, 10, 11, 11, 11, 11, 12, 12, 12, 12, 13, 13, 13, 13;91;3;https://github.com/odolan/Game-of-War-Predictor-/blob/master/War Predictor/GameOfWar.py;>7
123;bd0d429e0742b94a8b820221dd64c909f7b47c13;, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,;73;2;https://github.com/rogerkenny/pystuff/blob/master/Solutions.py;>7
124;b32657aa5d791091bd6992730a1a48d8b4b1152f;= {'Name':pd.Series(['Tom','James','Ricky','Vin','Steve','Minsu','Jack','Lee','David','Gasper','Betina','Andres']),;61;1;https://github.com/wojiaolds/python-test/blob/master/pandas_test/dataframe_base.py;3
125;b32657aa5d791091bd6992730a1a48d8b4b1152f;= {'Name':pd.Series(['Tom','James','Ricky','Vin','Steve','Minsu','Jack','Lee','David','Gasper','Betina','Andres']),;61;1;https://github.com/wojiaolds/python-test/blob/master/pandas_test/dataframe_base.py;3
126;eb52f02463b6ed46f0ffbbe2e15a65998cc778d4;\\n\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t\\t;141;2;https://github.com/dbc1040/WeiboCrawler/blob/master/weibocrawler/proc_user_pages.py;1
127;46a01cf8cb75ac9b2b7e223e22f1575d0cf1320d;"object.
Fields:
filter: The standard list filter.
name: The name of the operation's parent resource.
pageSize: The standard list page size.
pageToken: The standard list page token.
""""""
filter = _messages.StringField(1)
name = _messages.StringField(2, required=True)
pageSize = _messages.IntegerField(3, variant=_messages.Variant.INT32)
pageToken = _messages.StringField(4)";86;3;https://github.com/munishgarg-02/GoogleAPI/blob/master/google-cloud-sdk/lib/googlecloudsdk/third_party/apis/dialogflow/v2/dialogflow_v2_messages.py;0
128;971a5155a320a23115a41d16f14b6ccc6ffe9801;1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,;100;3;https://github.com/peruzzim/cmg-cmssw/blob/master/HLTrigger/Configuration/test/OnLine_HLT_PRef.py;0
129;e0dead7e27af4a6122ccff07904c4d91137f59d9;"():
resp = requests.get('https://en.wikipedia.org/wiki/List_of_S%26P_500_companies')
soup = BeautifulSoup(resp.text, 'lxml')
table = soup.find('table', {'class': 'wikitable sortable'})
tickers = []
for row in table.findAll('tr')[1:]:
ticker = row.findAll('td')[0].text
tickers.append(ticker)";101;5;https://github.com/RajputJay41/python-for-finance/blob/master/automating and getting s&p list.py;6
130;971a5155a320a23115a41d16f14b6ccc6ffe9801;1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47;93;3;https://github.com/peruzzim/cmg-cmssw/blob/master/HLTrigger/Configuration/test/OnLine_HLT_PRef.py;>7
131;24657fc9722b450bcb7afda9c2cbfa54d356d80f;"home_dir = os.path.expanduser('~')
credential_dir = os.path.join(home_dir, '.credentials')
if not os.path.exists(credential_dir):
os.makedirs(credential_dir)
credential_path =";46;1;https://github.com/lucaspbordignon/sgbcloud/blob/master/src/nlp.py;>7
132;287df0f319785e386cb64eda635766799a1b731d;"?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)"""""",
(row[0], row[1], row[2], row[3], row[4], row[5], row[6], row[7], row[8], row[9], row[10]";81;2;https://github.com/devichs/Python-Bball-Stats/blob/master/shotStat.py;>7
133;507245517ceb9d0e901a142ad45a421ee0cc008b;"', 'Accept': 'application/json, text/javascript, */*; q=0.01', 'Accept-Language': 'en-US,en;q=0.5', 'Accept-Encoding': 'gzip, deflate', 'X-Requested-With': 'XMLHttpRequest', 'Referer': 'http://";79;3;https://github.com/lianghq7/get_url/blob/master/qunaer/qunaer.py;>7
134;45074562bee9d4f6d264fe9a484446a6ab78dd34;"# Copyright (C) 2010 Google Inc. All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are
# met:
#
# * Redistributions of source code must retain the above copyright
# notice, this list of conditions and the following disclaimer.
# * Redistributions in binary form must reproduce the above
# copyright notice, this list of conditions and the following disclaimer
# in the documentation and/or other materials provided with the
# distribution.
# * Neither the name of Google Inc. nor the names of its
# contributors may be used to endorse or promote products derived from
# this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
# ""AS IS"" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
# OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE