diff --git a/pwgissues/issue74/change_0a.txt b/pwgissues/issue74/change_0a.txt new file mode 100644 index 0000000..1d85069 --- /dev/null +++ b/pwgissues/issue74/change_0a.txt @@ -0,0 +1,135 @@ +; 18911-0139aDarmaa/Darma +16038 old 8, 381. 1, 29. 81. 2, 206. 3, 11. 4, 171-174. 6, 64. 8, 12. 14. 18. 24. 122. 304. 353. 9, 249. 10, 106. 11, 228. 229. 12, 20. 21. 23. 118. R. 1, 2, 17. 2, 12, 33. BRĀHMAṆ. 2, 34. BHAG. 18, 32. ŚĀK. 71, 4. {#aDarmajYa#} +; +16038 new 8, 381. 1, 29. 81. 2, 206. 3, 11. 4, 171-174. 6, 64. 8, 12. 14. 18. 24. 122. 304. 353. 9, 249. 10, 106. 11, 228. 229. 12, 20. 21. 23. 118. R. 1, 2, 17. 2, 12, 33. BRĀHMAṆ. 2, 34. BHAG. 18, 32. ŚĀK. 71, 4. {#aDarmajYa#} +;--------------------------------------------------- +; 21401-0160aDyAyaaDyAya/ +18226 old M. 2, 105. 106. 4, 103. 104. 106-108. 117. 118. 126. du. 4, 102. 127. pl. 101. +; +18226 new M. 2, 105. 106. 4, 103. 104. 106-108. 117. 118. 126. du. 4, 102. 127. pl. 101. +;--------------------------------------------------- +; 25671-0187anAryaanArya +21466 old 10, 57. {#anAryamAryakarmARamAryaM cAnAryakarmiRam#} +; +21466 new 10, 57. {#anAryamAryakarmARamAryaM cAnAryakarmiRam#} +;--------------------------------------------------- +; 25671-0187anAryaanArya +21467 old 73. {#anAryAsu - AyogavIzu#} +; +21467 new 73. {#anAryAsu - AyogavIzu#} +;--------------------------------------------------- +; 25671-0187anAryaanArya +21468 old 35. {#anAryAyAM samutpanno brAhmaRAt#} +; +21468 new 35. {#anAryAyAM samutpanno brAhmaRAt#} +;--------------------------------------------------- +; 25671-0187anAryaanArya +21469 old 66. {#jAto nAryAmanAryAyAmAryAdAryo BavedguREH . jAto 'pyanAryAdAryAyAmanArya iti niScayaH ..#} +; +21469 new 66. {#jAto nAryAmanAryAyAmAryAdAryo BavedguREH . jAto 'pyanAryAdAryAyAmanArya iti niScayaH ..#} +;--------------------------------------------------- +; 25671-0187anAryaanArya +21470 old 67. {#anArya iti mAmAryAH - vikarizyanti raTyAsu surApaM brAhmaRaM yaTA#} +; +21470 new 67. {#anArya iti mAmAryAH - vikarizyanti raTyAsu surApaM brAhmaRaM yaTA#} +;--------------------------------------------------- +; 35231-0261anyaanya/ +29847 old 6, 51. {#matsyAnAM pakziRAM cEva tElasya ca Gftasya ca . mAMsasya maDunaScEva yaccAnyatpaSusaMBavam ..#} +; +29847 new 6, 51. {#matsyAnAM pakziRAM cEva tElasya ca Gftasya ca . mAMsasya maDunaScEva yaccAnyatpaSusaMBavam ..#} +;--------------------------------------------------- +; 35231-0261anyaanya/ +29848 old 8, 328. {#fziBirbAlaKilyESca jApahomaparAyaREH . anyErvEKAnasEScEva#} +; +29848 new 8, 328. {#fziBirbAlaKilyESca jApahomaparAyaREH . anyErvEKAnasEScEva#} +;--------------------------------------------------- +; 76261-0570ahana/han +66008 old ŚAT. BR. 1, 1, 2, 21. 3, 5, 9. 3, 4, 3, 22. +; +66008 new ŚAT. BR. 1, 1, 2, 21. 3, 5, 9. 3, 4, 3, 22. +;--------------------------------------------------- +; 87121-0649ApAp +75618 old 4, 14. 6, 96. 8, 420. 12, 116. 126. {#yaSaH, suKam#} +; +75618 new 4, 14. 6, 96. 8, 420. 12, 116. 126. {#yaSaH, suKam#} +;--------------------------------------------------- +; 92971-0696AryaA/rya +80949 old KĀTY. ŚR. 13, 3, 7. 8. 4, 14, 1. {#muKabAhUrupajjAnAM yA loke jAtayo bahiH . mlecCavAcAScAryavAcaH sarve te dasyavaH smftAH ..#} +; +80949 new KĀTY. ŚR. 13, 3, 7. 8. 4, 14, 1. {#muKabAhUrupajjAnAM yA loke jAtayo bahiH . mlecCavAcAScAryavAcaH sarve te dasyavaH smftAH ..#} +;--------------------------------------------------- +; 103731-0823iziz3 +93869 old M. 8, 366. 378. 412. 9, 328. +; +93869 new M. 8, 366. 378. 412. 9, 328. +;--------------------------------------------------- +; 118851-0958upapAtakaupapAtaka +109251 old 59-66. YĀJÑ. 2, 210. 3, 225. 242. +; +109251 new 59-66. YĀJÑ. 2, 210. 3, 225. 242. +;--------------------------------------------------- +; 501024-1098prasAdakaprasAdaka +495573 old Spr. 1931 (M.). {%erheiternd%}: {#gurucitta°#} +; +495573 new Spr. 1931 (M.). {%erheiternd%}: {#gurucitta°#} +;--------------------------------------------------- +; 533775-0135brahmanbra/hman1 +525683 old 110. 111. {#brahmEvAByasate#} +; +525683 new 110. 111. {#brahmEvAByasate#} +;--------------------------------------------------- +; 533775-0135brahmanbra/hman1 +525684 old 149. 11, 84. 97. {#rahasyaM brahmasaMmitam#} +; +525684 new 149. 11, 84. 97. {#rahasyaM brahmasaMmitam#} +;--------------------------------------------------- +; 962986-1444vyapadeSavyapadeSa +905123 old VEDĀNTAS. (Allah.) No. 23. KULL. zu M. 1, 4 (am Ende). 49. 58. 7, 158. 9, 178. 10, 37. MUIR, ST. 4, 219, 9. {#tannASe AtmA nazwa iti vyapadeSamAtram#} +; +905123 new VEDĀNTAS. (Allah.) No. 23. KULL. zu M. 1, 4 (am Ende). 49. 58. 7, 158. 9, 178. 10, 37. MUIR, ST. 4, 219, 9. {#tannASe AtmA nazwa iti vyapadeSamAtram#} +;--------------------------------------------------- +; 963826-1452vyavasAyinvyavasAyin +906027 old KṚṢIS. 8, 4. SUŚR. 1, 123, 17. Spr. (II) 113 (M.). 1926. 2150. 2584. KATHĀS. 87, 23. 123, 154. MĀRK. P. 20, 36. SĀH. D. 179, 10. BHĀG. P. 11, 16, 31. PAÑCAT. 134, 10. 138, 7. {#a°#} +; +906027 new KṚṢIS. 8, 4. SUŚR. 1, 123, 17. Spr. (II) 113 (M.). 1926. 2150. 2584. KATHĀS. 87, 23. 123, 154. MĀRK. P. 20, 36. SĀH. D. 179, 10. BHĀG. P. 11, 16, 31. PAÑCAT. 134, 10. 138, 7. {#a°#} +;--------------------------------------------------- +; 964506-1459vyasaninvyasanin +906810 old KĀM. NĪTIS. 4, 56. 13, 19. 59. Spr. (II) 23. 639. 1801. 2715. (I) 2901. 3298. 5041 (M.). VARĀH. BṚH. S. 101, 13. KATHĀS. 15, 56. 16, 21. 24, 58. 26, 199. 93, 41. DAŚAR. 2, 8. SĀH. D. 159. PAÑCAT. 163, 14. {#ati°#} +; +906810 new KĀM. NĪTIS. 4, 56. 13, 19. 59. Spr. (II) 23. 639. 1801. 2715. (I) 2901. 3298. 5041 (M.). VARĀH. BṚH. S. 101, 13. KATHĀS. 15, 56. 16, 21. 24, 58. 26, 199. 93, 41. DAŚAR. 2, 8. SĀH. D. 159. PAÑCAT. 163, 14. {#ati°#} +;--------------------------------------------------- +; 977607-0060SapSap +919653 old Spr. (II) 2407 (M.). {#nEnamanvAgamizyAmi kadAcicCapetsa mAm#} +; +919653 new Spr. (II) 2407 (M.). {#nEnamanvAgamizyAmi kadAcicCapetsa mAm#} +;--------------------------------------------------- +; 997827-0210SiSuSi/Su +938805 old 151. fg. 8, 66. {#BrAtA ca me SiSuH#} +; +938805 new 151. fg. 8, 66. {#BrAtA ca me SiSuH#} +;--------------------------------------------------- +; 1052457-0679samaYjasasamaYjasa +995710 old Spr. (II) 6838 (M.). {#SAstra#} +; +995710 new Spr. (II) 6838 (M.). {#SAstra#} +;--------------------------------------------------- +; 1076147-0868sahastasahasta +1018983 old Spr. (II) 2258 (M.). BHĀG. P. 1, 13, 44. +; +1018983 new Spr. (II) 2258 (M.). BHĀG. P. 1, 13, 44. +;--------------------------------------------------- +; 1097647-1031sukftinsukftin +1039383 old Spr. (II) 203. 2743. 5736 (M.). 6039. 6818. 7263. KATHĀS. 16, 117. 22, 55. 255. 45, 146. RĀJA-TAR. 1, 107. 347. 3, 290. 320. 4, 362. PRAB. 70, 3. BHĀG. P. 9, 10, 23. +; +1039383 new Spr. (II) 203. 2743. 5736 (M.). 6039. 6818. 7263. KATHĀS. 16, 117. 22, 55. 255. 45, 146. RĀJA-TAR. 1, 107. 347. 3, 290. 320. 4, 362. PRAB. 70, 3. BHĀG. P. 9, 10, 23. +;--------------------------------------------------- +; 1137057-1270stenaystenay +1072857 old Spr. (II) 6027 (M.). +; +1072857 new Spr. (II) 6027 (M.). +;--------------------------------------------------- +; 1142687-1348snAyinsnAyin +1081618 old M., 11, 214. {#nitya°#} +; +1081618 new M. 11, 214. {#nitya°#} +;--------------------------------------------------- diff --git a/pwgissues/issue74/linksort_debug.py b/pwgissues/issue74/linksort_debug.py new file mode 100644 index 0000000..11903ba --- /dev/null +++ b/pwgissues/issue74/linksort_debug.py @@ -0,0 +1,360 @@ +# coding=utf-8 +""" linksort.py +""" +from __future__ import print_function +import sys, re,codecs +import digentry + +def read_lines(filein): + with codecs.open(filein,encoding='utf-8',mode='r') as f: + lines = [x.rstrip('\r\n') for x in f] + return lines + +def write_lines(fileout,outarr): + with codecs.open(fileout,"w","utf-8") as f: + for out in outarr: + f.write(out+'\n') + print(len(outarr),"cases written to",fileout) + +def get_links1(entries): + recs = [] + regex1raw = r'M\..*?' + regex2raw = r'.*?' + regex1 = re.compile(regex1raw) + regex2 = re.compile(regex2raw) + for ientry,entry in enumerate(entries): + text = ' '.join(entry.datalines) + a1 = re.findall(regex1,text) + a2 = re.findall(regex2,text) + for x in a1: + recs.append(x) + for x in a2: + recs.append(x) + return recs + +def get_standard_regexes(): + regex1raw = r'M\. ([0-9]+), ([0-9]+)\.?' + regex2raw = r'([0-9]+)\.?' + regex3raw = r'([0-9]+), ([0-9]+)\.?' + regex4raw = r'M\.' + regex5raw = r'M\. ([0-9]+), ([0-9]+)\. fgg?\.' + regex6raw = r'([0-9]+)\. fgg?\.' + regex7raw = r'([0-9]+), ([0-9]+)\. fgg?\.' + regex1 = re.compile(regex1raw) + regex2 = re.compile(regex2raw) + regex3 = re.compile(regex3raw) + regex4 = re.compile(regex4raw) + regex5 = re.compile(regex5raw) + regex6 = re.compile(regex6raw) + regex7 = re.compile(regex7raw) + regexes = (regex1,regex2,regex3,regex4,regex5,regex6,regex7) + return regexes + +def get_links2_debug(entry,iregex,m,v): + vdbgs = [(1,144), (1,180), (1,4116), + (2,317), + (3,628), (3,6028), (3,12484), + (4,348), + (5,195), + (6,162), (6,165),(6,183), + (7,2498), + (8,787), + (10,158), (10,181), + (11,286),(11,576),(11,747), + (11,331), # twice + (12,179),(12,212),(12,226), + (12,917),(12,921),(12,1321),(12,1825), + #problems with adhyaya also + (13,63), (13,1659),(40,53),(51,5),(70,95), + (70,97),(87,11),(87,18),(125,210), + + + ] + + if v in vdbgs: + v1,v2 = v + meta = re.sub(r'.*$','',entry.metaline) + out = '(%s,%s) %s %s' %(v1,v2,meta,m.group(0)) + print(out) + +def get_links2(entries): + recs = [] + regexes = get_standard_regexes() + d = {} + for ientry,entry in enumerate(entries): + text = ' '.join(entry.datalines) + for iregex,regex in enumerate(regexes): + for m in re.finditer(regex,text): + if iregex == 3: + v = (0,0) # no parameters + else: + v1 = int(m.group(1)) + v2 = int(m.group(2)) + v = (v1,v2) + if v not in d: + d[v] = 0 + d[v] = d[v] + 1 + get_links2_debug(entry,iregex,m,v) + keys = sorted(d.keys()) + ntot = 0 + for v in keys: + n = d[v] + recs.append('%s,%s (%s)'%(v[0],v[1],n)) + ntot = ntot + n + print(ntot,"total number of 'regular' links") + return recs + +def test(): + regexes = get_standard_regexes() + text = '150.' + texts = [text] + for text in texts: + for iregex,regex in enumerate(regexes): + for m in re.finditer(regex,text): + if iregex == 3: + v = (0,0) # no parameters + else: + v1 = int(m.group(1)) + v2 = int(m.group(2)) + v = (v1,v2) + #if v not in d: + # d[v] = 0 + #d[v] = d[v] + 1 + if True: # dbg + #if v == (2,0): + print('chk',iregex, m.group(0), m.group(1), m.group(2)) + exit(1) + +#test() + +def get_links3(entries): + recs1 = [] + recs2 = [] + # standard links + sregexes = get_standard_regexes() + # any link see get_links1 + regex1raw = r'M\..*?' + regex2raw = r'.*?' + regex1 = re.compile(regex1raw) + regex2 = re.compile(regex2raw) + + d = {} + for ientry,entry in enumerate(entries): + text = ' '.join(entry.datalines) + a1 = re.findall(regex1,text) + a2 = re.findall(regex2,text) + for x in a1: + standard = False + for sregex in sregexes: + if re.search(sregex,x): + standard = True + break + if not standard: + recs1.append(x) + for x in a2: + standard = False + for sregex in sregexes: + if re.search(sregex,x): + standard = True + break + if not standard: + recs2.append(x) + print(len(recs1),"non-standard of type1") + print(len(recs2),"non-standard of type2") + return recs1,recs2 + +def get_links4(entries): + recs1 = [] + # standard links + sregexes = get_standard_regexes() + # any link see get_links1 + regex1raw = r'M\..*?' + regex2raw = r'.*?' + regex1 = re.compile(regex1raw) + regex2 = re.compile(regex2raw) + regex0raw = r'' # ALL ls - not only M + regex0 = re.compile(regex0raw) + + d = {} + for ientry,entry in enumerate(entries): + text = ' '.join(entry.datalines) + a = re.findall(regex0,text) + b = [] + for x in a: + standard = False + t = -1 # taranga + for isregex,sregex in enumerate(sregexes): + m = re.search(sregex,x) + if m != None: + if len(m.groups()) == 2: + standard = True + t = m.group(1) + break + b.append((standard,t,x)) + for i,y in enumerate(b): + standard,t,x = y + if standard: + continue + # x is non-standard. generate a record + if not (re.search(regex1,x) or re.search(regex2,x)): + continue + recdefault = (x,'-1','NA') + if i == 0: + rec = recdefault + else: + y0 = b[i-1] + standard0,t0,x0 = y0 + if standard0: + rec = (x,t0,x0) + else: + rec = (x,-1,x0) + recs1.append(rec) + if False and (len(recs1) == 1) : # dbg + x,t,x0 = rec + print('chk: x=',x) + print(' t=',t) + print(' x0=',x0) + exit(1) + print(len(recs1),"non-standard records") + return recs1 + +def get_links5(entries): + # almost same as links4. Returns also metaline in each record + recs1 = [] + # standard links + sregexes = get_standard_regexes() + # any link see get_links1 + regex1raw = r'M\..*?' + regex2raw = r'.*?' + regex1 = re.compile(regex1raw) + regex2 = re.compile(regex2raw) + regex0raw = r'' # ALL ls - not only M + regex0 = re.compile(regex0raw) + + d = {} + for ientry,entry in enumerate(entries): + metaline = entry.metaline + text = ' '.join(entry.datalines) + a = re.findall(regex0,text) + b = [] + for x in a: + standard = False + t = -1 # taranga + for isregex,sregex in enumerate(sregexes): + m = re.search(sregex,x) + if m != None: + if len(m.groups()) == 2: + standard = True + t = m.group(1) + break + b.append((standard,t,x,metaline)) + for i,y in enumerate(b): + standard,t,x,meta = y + if standard: + continue + # x is non-standard. generate a record + if not (re.search(regex1,x) or re.search(regex2,x)): + continue + recdefault = (x,'-1','NA',metaline) + if i == 0: + rec = recdefault + else: + y0 = b[i-1] + standard0,t0,x0,metaline = y0 + if standard0: + rec = (x,t0,x0,metaline) + else: + rec = (x,-1,x0,metaline) + recs1.append(rec) + if False and (len(recs1) == 1) : # dbg + x,t,x0 = rec + print('chk: x=',x) + print(' t=',t) + print(' x0=',x0) + exit(1) + print(len(recs1),"non-standard records") + return recs1 + +def option_5_helper(recs,lines): + # first, get metaline map + d = {} + for rec in recs: + (x,t,x0,meta) = rec + if meta not in d: + d[meta] = [] + d[meta].append(rec) + + newlines = [] + metaline = None + for iline,line in enumerate(lines): + if line.startswith(''): + metaline = line + imeta = iline + newlines.append(line) + continue + if line.startswith(''): + metaline = None + if newlines[imeta].startswith('* '): + newline = '* ' + line + else: + newline = line + newlines.append(newline) + continue + if metaline == None: + newlines.append(line) + continue + # a normal dataline. + # Search for matching recs + if metaline not in d: + newlines.append(line) + continue + recsmatch = d[metaline] + newline = line + for rec in recsmatch: + x,t,x0,meta = rec + newline = newline.replace(x,'** '+x) + newlines.append(newline) + # also mark metaline * is for emacs org + oldmeta = newlines[imeta] + if oldmeta.startswith('* '): + pass # nothing to do + else: + newmeta = '* TODO ' + oldmeta + newlines[imeta] = newmeta + return newlines + +if __name__=="__main__": + option = sys.argv[1] + filein = sys.argv[2] # xxx.txt + fileout = sys.argv[3] # + entries = digentry.init(filein) + if option == '1': + recs = get_links1(entries) + recs1 = sorted(recs) + write_lines(fileout,recs1) + elif option == '2': + recs_sorted = get_links2(entries) + write_lines(fileout,recs_sorted) + elif option == '3': + recs1,recs2 = get_links3(entries) + recs1_sort = sorted(recs1) + recs2_sort = sorted(recs2) + recs = recs1_sort + recs2_sort + write_lines(fileout,recs) + elif option == '4': + recs1= get_links4(entries) + recs1_sort = sorted(recs1,key = lambda x: x[0]) + recs = recs1_sort + outarr = ['%s\t%s\t%s' % (x,t,x0) for x,t,x0 in recs] + write_lines(fileout,outarr) + elif option == '5': + recs1= get_links5(entries) # + # recs1_sort = sorted(recs1,key = lambda x: x[0]) + lines = read_lines(filein) + newlines = option_5_helper(recs1,lines) + #outarr = ['%s\t%s\t%s' % (x,t,x0) for x,t,x0 in recs] + write_lines(fileout,newlines) + else: + print('ERROR option unknown:',option) + exit(1) + diff --git a/pwgissues/issue74/linksorta.py b/pwgissues/issue74/linksorta.py new file mode 100644 index 0000000..b0ffc5c --- /dev/null +++ b/pwgissues/issue74/linksorta.py @@ -0,0 +1,311 @@ +# coding=utf-8 +""" linksort.py +""" +from __future__ import print_function +import sys, re,codecs +import digentry + +def read_lines(filein): + with codecs.open(filein,encoding='utf-8',mode='r') as f: + lines = [x.rstrip('\r\n') for x in f] + return lines + +def write_lines(fileout,outarr): + with codecs.open(fileout,"w","utf-8") as f: + for out in outarr: + f.write(out+'\n') + print(len(outarr),"cases written to",fileout) + +def get_links1(entries): + recs = [] + regex1raw = r'M\..*?' + regex2raw = r'.*?' + regex1 = re.compile(regex1raw) + regex2 = re.compile(regex2raw) + for ientry,entry in enumerate(entries): + text = ' '.join(entry.datalines) + a1 = re.findall(regex1,text) + a2 = re.findall(regex2,text) + for x in a1: + recs.append(x) + for x in a2: + recs.append(x) + return recs + +def get_standard_regexes(): + # 09-12-2024. Corrected + regex1raw = r'M\. ([0-9]+), ([0-9]+)\.?' + regex2raw = r'([0-9]+)\.?' + regex3raw = r'([0-9]+), ([0-9]+)\.?' + regex4raw = r'M\.' + regex5raw = r'M\. ([0-9]+), ([0-9]+)\. fgg?\.' + regex6raw = r'([0-9]+)\. fgg?\.' + regex7raw = r'([0-9]+), ([0-9]+)\. fgg?\.' + regex1 = re.compile(regex1raw) + regex2 = re.compile(regex2raw) + regex3 = re.compile(regex3raw) + regex4 = re.compile(regex4raw) + regex5 = re.compile(regex5raw) + regex6 = re.compile(regex6raw) + regex7 = re.compile(regex7raw) + regexes = (regex1,regex2,regex3,regex4,regex5,regex6,regex7) + return regexes + +def get_links2(entries): + recs = [] + regexes = get_standard_regexes() + d = {} + for ientry,entry in enumerate(entries): + text = ' '.join(entry.datalines) + for iregex,regex in enumerate(regexes): + for m in re.finditer(regex,text): + if iregex == 3: + v = (0,0) # no parameters + else: + v1 = int(m.group(1)) + v2 = int(m.group(2)) + v = (v1,v2) + if v not in d: + d[v] = 0 + d[v] = d[v] + 1 + + keys = sorted(d.keys()) + ntot = 0 + for v in keys: + n = d[v] + recs.append('%s,%s (%s)'%(v[0],v[1],n)) + ntot = ntot + n + print(ntot,"total number of 'regular' links") + return recs + +def get_links3(entries): + recs1 = [] + recs2 = [] + # standard links + sregexes = get_standard_regexes() + # any link see get_links1 + regex1raw = r'M\..*?' + regex2raw = r'.*?' + regex1 = re.compile(regex1raw) + regex2 = re.compile(regex2raw) + + d = {} + for ientry,entry in enumerate(entries): + text = ' '.join(entry.datalines) + a1 = re.findall(regex1,text) + a2 = re.findall(regex2,text) + for x in a1: + standard = False + for sregex in sregexes: + if re.search(sregex,x): + standard = True + break + if not standard: + recs1.append(x) + for x in a2: + standard = False + for sregex in sregexes: + if re.search(sregex,x): + standard = True + break + if not standard: + recs2.append(x) + print(len(recs1),"non-standard of type1") + print(len(recs2),"non-standard of type2") + return recs1,recs2 + +def get_links4(entries): + recs1 = [] + # standard links + sregexes = get_standard_regexes() + # any link see get_links1 + regex1raw = r'M\..*?' + regex2raw = r'.*?' + regex1 = re.compile(regex1raw) + regex2 = re.compile(regex2raw) + regex0raw = r'' # ALL ls - not only M + regex0 = re.compile(regex0raw) + + d = {} + for ientry,entry in enumerate(entries): + text = ' '.join(entry.datalines) + a = re.findall(regex0,text) + b = [] + for x in a: + standard = False + t = -1 # taranga + for isregex,sregex in enumerate(sregexes): + m = re.search(sregex,x) + if m != None: + if len(m.groups()) == 2: + standard = True + t = m.group(1) + break + b.append((standard,t,x)) + for i,y in enumerate(b): + standard,t,x = y + if standard: + continue + # x is non-standard. generate a record + if not (re.search(regex1,x) or re.search(regex2,x)): + continue + recdefault = (x,'-1','NA') + if i == 0: + rec = recdefault + else: + y0 = b[i-1] + standard0,t0,x0 = y0 + if standard0: + rec = (x,t0,x0) + else: + rec = (x,-1,x0) + recs1.append(rec) + if False and (len(recs1) == 1) : # dbg + x,t,x0 = rec + print('chk: x=',x) + print(' t=',t) + print(' x0=',x0) + exit(1) + print(len(recs1),"non-standard records") + return recs1 + +def get_links5(entries): + # almost same as links4. Returns also metaline in each record + recs1 = [] + # standard links + sregexes = get_standard_regexes() + # any link see get_links1 + regex1raw = r'M\..*?' + regex2raw = r'.*?' + regex1 = re.compile(regex1raw) + regex2 = re.compile(regex2raw) + regex0raw = r'' # ALL ls - not only M + regex0 = re.compile(regex0raw) + + d = {} + for ientry,entry in enumerate(entries): + metaline = entry.metaline + text = ' '.join(entry.datalines) + a = re.findall(regex0,text) + b = [] + for x in a: + standard = False + t = -1 # taranga + for isregex,sregex in enumerate(sregexes): + m = re.search(sregex,x) + if m != None: + if len(m.groups()) == 2: + standard = True + t = m.group(1) + break + b.append((standard,t,x,metaline)) + for i,y in enumerate(b): + standard,t,x,meta = y + if standard: + continue + # x is non-standard. generate a record + if not (re.search(regex1,x) or re.search(regex2,x)): + continue + recdefault = (x,'-1','NA',metaline) + if i == 0: + rec = recdefault + else: + y0 = b[i-1] + standard0,t0,x0,metaline = y0 + if standard0: + rec = (x,t0,x0,metaline) + else: + rec = (x,-1,x0,metaline) + recs1.append(rec) + if False and (len(recs1) == 1) : # dbg + x,t,x0 = rec + print('chk: x=',x) + print(' t=',t) + print(' x0=',x0) + exit(1) + print(len(recs1),"non-standard records") + return recs1 + +def option_5_helper(recs,lines): + # first, get metaline map + d = {} + for rec in recs: + (x,t,x0,meta) = rec + if meta not in d: + d[meta] = [] + d[meta].append(rec) + + newlines = [] + metaline = None + for iline,line in enumerate(lines): + if line.startswith(''): + metaline = line + imeta = iline + newlines.append(line) + continue + if line.startswith(''): + metaline = None + if newlines[imeta].startswith('* '): + newline = '* ' + line + else: + newline = line + newlines.append(newline) + continue + if metaline == None: + newlines.append(line) + continue + # a normal dataline. + # Search for matching recs + if metaline not in d: + newlines.append(line) + continue + recsmatch = d[metaline] + newline = line + for rec in recsmatch: + x,t,x0,meta = rec + newline = newline.replace(x,'** '+x) + newlines.append(newline) + # also mark metaline * is for emacs org + oldmeta = newlines[imeta] + if oldmeta.startswith('* '): + pass # nothing to do + else: + newmeta = '* TODO ' + oldmeta + newlines[imeta] = newmeta + return newlines + +if __name__=="__main__": + option = sys.argv[1] + filein = sys.argv[2] # xxx.txt + fileout = sys.argv[3] # + entries = digentry.init(filein) + if option == '1': + recs = get_links1(entries) + recs1 = sorted(recs) + write_lines(fileout,recs1) + elif option == '2': + recs_sorted = get_links2(entries) + write_lines(fileout,recs_sorted) + elif option == '3': + recs1,recs2 = get_links3(entries) + recs1_sort = sorted(recs1) + recs2_sort = sorted(recs2) + recs = recs1_sort + recs2_sort + write_lines(fileout,recs) + elif option == '4': + recs1= get_links4(entries) + recs1_sort = sorted(recs1,key = lambda x: x[0]) + recs = recs1_sort + outarr = ['%s\t%s\t%s' % (x,t,x0) for x,t,x0 in recs] + write_lines(fileout,outarr) + elif option == '5': + recs1= get_links5(entries) # + # recs1_sort = sorted(recs1,key = lambda x: x[0]) + lines = read_lines(filein) + newlines = option_5_helper(recs1,lines) + #outarr = ['%s\t%s\t%s' % (x,t,x0) for x,t,x0 in recs] + write_lines(fileout,newlines) + else: + print('ERROR option unknown:',option) + exit(1) + diff --git a/pwgissues/issue74/linksorta2_3.txt b/pwgissues/issue74/linksorta2_3.txt new file mode 100644 index 0000000..2552458 --- /dev/null +++ b/pwgissues/issue74/linksorta2_3.txt @@ -0,0 +1,2723 @@ +0,0 (30) +1,1 (13) +1,2 (15) +1,3 (12) +1,4 (17) +1,5 (17) +1,6 (14) +1,7 (12) +1,8 (14) +1,9 (11) +1,10 (13) +1,11 (14) +1,12 (7) +1,13 (10) +1,14 (11) +1,15 (9) +1,16 (11) +1,17 (11) +1,18 (12) +1,19 (12) +1,20 (9) +1,21 (13) +1,22 (10) +1,23 (14) +1,24 (12) +1,25 (10) +1,26 (9) +1,27 (15) +1,28 (8) +1,29 (12) +1,30 (10) +1,31 (13) +1,32 (7) +1,33 (9) +1,34 (8) +1,35 (11) +1,36 (9) +1,37 (12) +1,38 (12) +1,39 (9) +1,40 (10) +1,41 (9) +1,42 (10) +1,43 (8) +1,44 (10) +1,45 (12) +1,46 (16) +1,47 (9) +1,48 (13) +1,49 (11) +1,50 (11) +1,51 (10) +1,52 (10) +1,53 (11) +1,54 (10) +1,55 (8) +1,56 (11) +1,57 (12) +1,58 (12) +1,59 (8) +1,60 (8) +1,61 (11) +1,62 (8) +1,63 (14) +1,64 (13) +1,65 (8) +1,66 (11) +1,67 (10) +1,68 (12) +1,69 (10) +1,70 (4) +1,71 (11) +1,72 (7) +1,73 (11) +1,74 (12) +1,75 (8) +1,76 (12) +1,77 (10) +1,78 (11) +1,79 (9) +1,80 (10) +1,81 (12) +1,82 (10) +1,83 (12) +1,84 (9) +1,85 (11) +1,86 (10) +1,87 (11) +1,88 (9) +1,89 (7) +1,90 (10) +1,91 (9) +1,92 (8) +1,93 (10) +1,94 (10) +1,95 (7) +1,96 (9) +1,97 (8) +1,98 (8) +1,99 (8) +1,100 (9) +1,101 (7) +1,102 (8) +1,103 (8) +1,104 (12) +1,105 (12) +1,106 (9) +1,107 (7) +1,108 (9) +1,109 (10) +1,110 (7) +1,111 (10) +1,112 (11) +1,113 (7) +1,114 (10) +1,115 (11) +1,116 (9) +1,117 (8) +1,118 (9) +1,119 (8) +1,144 (1) +1,180 (1) +1,4116 (1) +2,1 (16) +2,2 (13) +2,3 (11) +2,4 (10) +2,5 (11) +2,6 (14) +2,7 (10) +2,8 (11) +2,9 (14) +2,10 (10) +2,11 (12) +2,12 (10) +2,13 (10) +2,14 (11) +2,15 (11) +2,16 (9) +2,17 (10) +2,18 (9) +2,19 (9) +2,20 (8) +2,21 (10) +2,22 (12) +2,23 (9) +2,24 (9) +2,25 (8) +2,26 (10) +2,27 (10) +2,28 (8) +2,29 (10) +2,30 (11) +2,31 (7) +2,32 (16) +2,33 (13) +2,34 (10) +2,35 (8) +2,36 (9) +2,37 (10) +2,38 (10) +2,39 (9) +2,40 (10) +2,41 (10) +2,42 (15) +2,43 (11) +2,44 (9) +2,45 (11) +2,46 (9) +2,47 (10) +2,48 (11) +2,49 (10) +2,50 (11) +2,51 (11) +2,52 (9) +2,53 (10) +2,54 (10) +2,55 (12) +2,56 (9) +2,57 (11) +2,58 (11) +2,59 (13) +2,60 (13) +2,61 (14) +2,62 (9) +2,63 (12) +2,64 (10) +2,65 (7) +2,66 (9) +2,67 (12) +2,68 (9) +2,69 (10) +2,70 (11) +2,71 (9) +2,72 (8) +2,73 (10) +2,74 (9) +2,75 (8) +2,76 (12) +2,77 (8) +2,78 (8) +2,79 (14) +2,80 (9) +2,81 (8) +2,82 (9) +2,83 (13) +2,84 (7) +2,85 (9) +2,86 (7) +2,87 (9) +2,88 (6) +2,89 (8) +2,90 (13) +2,91 (6) +2,92 (8) +2,93 (10) +2,94 (5) +2,95 (8) +2,96 (8) +2,97 (9) +2,98 (12) +2,99 (9) +2,100 (11) +2,101 (13) +2,102 (8) +2,103 (4) +2,104 (11) +2,105 (11) +2,106 (8) +2,107 (10) +2,108 (7) +2,109 (12) +2,110 (9) +2,111 (5) +2,112 (13) +2,113 (11) +2,114 (8) +2,115 (6) +2,116 (8) +2,117 (12) +2,118 (11) +2,119 (8) +2,120 (10) +2,121 (4) +2,122 (8) +2,123 (10) +2,124 (11) +2,125 (16) +2,126 (7) +2,127 (9) +2,128 (12) +2,129 (13) +2,130 (6) +2,131 (11) +2,132 (9) +2,133 (9) +2,134 (10) +2,135 (5) +2,136 (5) +2,137 (9) +2,138 (12) +2,139 (7) +2,140 (10) +2,141 (8) +2,142 (8) +2,143 (10) +2,144 (9) +2,145 (5) +2,146 (10) +2,147 (8) +2,148 (9) +2,149 (10) +2,150 (10) +2,151 (12) +2,152 (6) +2,153 (9) +2,154 (3) +2,155 (4) +2,156 (2) +2,157 (4) +2,158 (6) +2,159 (9) +2,160 (11) +2,161 (7) +2,162 (3) +2,163 (6) +2,164 (6) +2,165 (11) +2,166 (8) +2,167 (14) +2,168 (13) +2,169 (10) +2,170 (10) +2,171 (11) +2,172 (9) +2,173 (8) +2,174 (8) +2,175 (7) +2,176 (11) +2,177 (11) +2,178 (11) +2,179 (7) +2,180 (9) +2,181 (11) +2,182 (12) +2,183 (10) +2,184 (8) +2,185 (11) +2,186 (9) +2,187 (9) +2,188 (8) +2,189 (12) +2,190 (6) +2,191 (6) +2,192 (9) +2,193 (9) +2,194 (9) +2,195 (9) +2,196 (8) +2,197 (8) +2,198 (7) +2,199 (8) +2,200 (8) +2,201 (10) +2,202 (12) +2,203 (7) +2,204 (13) +2,205 (6) +2,206 (12) +2,207 (7) +2,208 (10) +2,209 (8) +2,210 (6) +2,211 (8) +2,212 (8) +2,213 (8) +2,214 (10) +2,215 (5) +2,216 (8) +2,217 (7) +2,218 (4) +2,219 (12) +2,220 (14) +2,221 (8) +2,222 (9) +2,223 (9) +2,224 (9) +2,225 (7) +2,226 (6) +2,227 (4) +2,228 (4) +2,229 (5) +2,230 (7) +2,231 (11) +2,232 (10) +2,233 (8) +2,234 (5) +2,235 (9) +2,236 (8) +2,237 (6) +2,238 (5) +2,239 (5) +2,240 (3) +2,241 (10) +2,242 (10) +2,243 (12) +2,244 (9) +2,245 (8) +2,246 (9) +2,247 (10) +2,248 (8) +2,249 (8) +2,317 (1) +3,1 (12) +3,2 (12) +3,3 (10) +3,4 (12) +3,5 (10) +3,6 (8) +3,7 (17) +3,8 (12) +3,9 (12) +3,10 (14) +3,11 (11) +3,12 (9) +3,13 (5) +3,14 (7) +3,15 (12) +3,16 (12) +3,17 (8) +3,18 (11) +3,19 (7) +3,20 (11) +3,21 (12) +3,22 (7) +3,23 (10) +3,24 (6) +3,25 (7) +3,26 (11) +3,27 (13) +3,28 (9) +3,29 (9) +3,30 (8) +3,31 (8) +3,32 (8) +3,33 (12) +3,34 (12) +3,35 (8) +3,36 (4) +3,37 (10) +3,38 (6) +3,39 (8) +3,40 (12) +3,41 (9) +3,42 (7) +3,43 (9) +3,44 (9) +3,45 (18) +3,46 (8) +3,47 (6) +3,48 (7) +3,49 (10) +3,50 (9) +3,51 (8) +3,52 (8) +3,53 (17) +3,54 (6) +3,55 (6) +3,56 (6) +3,57 (6) +3,58 (6) +3,59 (8) +3,60 (6) +3,61 (11) +3,62 (6) +3,63 (7) +3,64 (10) +3,65 (7) +3,66 (9) +3,67 (9) +3,68 (10) +3,69 (8) +3,70 (13) +3,71 (9) +3,72 (6) +3,73 (7) +3,74 (12) +3,75 (7) +3,76 (9) +3,77 (9) +3,78 (9) +3,79 (9) +3,80 (8) +3,81 (14) +3,82 (9) +3,83 (5) +3,84 (9) +3,85 (6) +3,86 (6) +3,87 (12) +3,88 (11) +3,89 (10) +3,90 (8) +3,91 (7) +3,92 (10) +3,93 (5) +3,94 (8) +3,95 (5) +3,96 (10) +3,97 (7) +3,98 (7) +3,99 (8) +3,100 (11) +3,101 (7) +3,102 (7) +3,103 (7) +3,104 (8) +3,105 (12) +3,106 (7) +3,107 (9) +3,108 (10) +3,109 (11) +3,110 (4) +3,111 (6) +3,112 (9) +3,113 (6) +3,114 (7) +3,115 (7) +3,116 (9) +3,117 (12) +3,118 (8) +3,119 (12) +3,120 (9) +3,121 (7) +3,122 (10) +3,123 (7) +3,124 (9) +3,125 (9) +3,126 (7) +3,127 (12) +3,128 (6) +3,129 (7) +3,130 (8) +3,131 (8) +3,132 (4) +3,133 (13) +3,134 (6) +3,135 (9) +3,136 (2) +3,137 (8) +3,138 (6) +3,139 (3) +3,140 (8) +3,141 (11) +3,142 (7) +3,143 (5) +3,144 (12) +3,145 (9) +3,146 (6) +3,147 (12) +3,148 (8) +3,149 (6) +3,150 (9) +3,151 (9) +3,152 (15) +3,153 (8) +3,154 (11) +3,155 (6) +3,156 (10) +3,157 (8) +3,158 (16) +3,159 (13) +3,160 (12) +3,161 (10) +3,162 (14) +3,163 (13) +3,164 (10) +3,165 (9) +3,166 (7) +3,167 (7) +3,168 (10) +3,169 (10) +3,170 (7) +3,171 (7) +3,172 (8) +3,173 (7) +3,174 (9) +3,175 (9) +3,176 (8) +3,177 (10) +3,178 (10) +3,179 (10) +3,180 (9) +3,181 (11) +3,182 (14) +3,183 (11) +3,184 (7) +3,185 (14) +3,186 (8) +3,187 (8) +3,188 (7) +3,189 (6) +3,190 (10) +3,191 (13) +3,192 (11) +3,193 (7) +3,194 (6) +3,195 (5) +3,196 (11) +3,197 (5) +3,198 (6) +3,199 (7) +3,200 (8) +3,201 (7) +3,202 (9) +3,203 (7) +3,204 (7) +3,205 (7) +3,206 (9) +3,207 (8) +3,208 (11) +3,209 (5) +3,210 (6) +3,211 (8) +3,212 (6) +3,213 (9) +3,214 (9) +3,215 (7) +3,216 (11) +3,217 (12) +3,218 (7) +3,219 (7) +3,220 (7) +3,221 (7) +3,222 (11) +3,223 (9) +3,224 (10) +3,225 (9) +3,226 (11) +3,227 (6) +3,228 (7) +3,229 (8) +3,230 (10) +3,231 (8) +3,232 (10) +3,233 (8) +3,234 (9) +3,235 (10) +3,236 (10) +3,237 (4) +3,238 (8) +3,239 (8) +3,240 (6) +3,241 (16) +3,242 (11) +3,243 (9) +3,244 (10) +3,245 (8) +3,246 (9) +3,247 (7) +3,248 (6) +3,249 (11) +3,250 (10) +3,251 (13) +3,252 (9) +3,253 (8) +3,254 (11) +3,255 (13) +3,256 (7) +3,257 (8) +3,258 (9) +3,259 (8) +3,260 (8) +3,261 (10) +3,262 (10) +3,263 (10) +3,264 (8) +3,265 (8) +3,266 (9) +3,267 (10) +3,268 (8) +3,269 (7) +3,270 (7) +3,271 (12) +3,272 (14) +3,273 (10) +3,274 (10) +3,275 (7) +3,276 (9) +3,277 (11) +3,278 (7) +3,279 (10) +3,280 (13) +3,281 (10) +3,282 (11) +3,283 (7) +3,284 (9) +3,285 (10) +3,286 (9) +3,323 (1) +3,327 (1) +3,628 (1) +3,6028 (1) +3,12484 (1) +4,1 (7) +4,2 (7) +4,3 (9) +4,4 (9) +4,5 (13) +4,6 (10) +4,7 (16) +4,8 (7) +4,9 (7) +4,10 (6) +4,11 (11) +4,12 (2) +4,13 (12) +4,14 (8) +4,15 (10) +4,16 (4) +4,17 (8) +4,18 (10) +4,19 (13) +4,20 (8) +4,21 (7) +4,22 (9) +4,23 (8) +4,24 (9) +4,25 (9) +4,26 (12) +4,27 (8) +4,28 (10) +4,29 (8) +4,30 (12) +4,31 (8) +4,32 (6) +4,33 (13) +4,34 (9) +4,35 (11) +4,36 (10) +4,37 (14) +4,38 (8) +4,39 (9) +4,40 (9) +4,41 (9) +4,42 (8) +4,43 (13) +4,44 (10) +4,45 (9) +4,46 (11) +4,47 (11) +4,48 (9) +4,49 (11) +4,50 (11) +4,51 (10) +4,52 (9) +4,53 (11) +4,54 (9) +4,55 (9) +4,56 (10) +4,57 (12) +4,58 (7) +4,59 (10) +4,60 (11) +4,61 (11) +4,62 (11) +4,63 (10) +4,64 (10) +4,65 (11) +4,66 (9) +4,67 (13) +4,68 (10) +4,69 (12) +4,70 (10) +4,71 (12) +4,72 (12) +4,73 (10) +4,74 (9) +4,75 (9) +4,76 (6) +4,77 (10) +4,78 (11) +4,79 (9) +4,80 (9) +4,81 (7) +4,82 (11) +4,83 (10) +4,84 (11) +4,85 (6) +4,86 (7) +4,87 (10) +4,88 (7) +4,89 (8) +4,90 (6) +4,91 (5) +4,92 (9) +4,93 (9) +4,94 (8) +4,95 (11) +4,96 (8) +4,97 (8) +4,98 (9) +4,99 (11) +4,100 (7) +4,101 (7) +4,102 (12) +4,103 (10) +4,104 (10) +4,105 (7) +4,106 (10) +4,107 (7) +4,108 (8) +4,109 (9) +4,110 (10) +4,111 (8) +4,112 (10) +4,113 (9) +4,114 (8) +4,115 (12) +4,116 (11) +4,117 (12) +4,118 (8) +4,119 (9) +4,120 (13) +4,121 (10) +4,122 (9) +4,123 (8) +4,124 (8) +4,125 (9) +4,126 (8) +4,127 (7) +4,128 (8) +4,129 (11) +4,130 (7) +4,131 (8) +4,132 (10) +4,133 (9) +4,134 (6) +4,135 (7) +4,136 (6) +4,137 (6) +4,138 (4) +4,139 (6) +4,140 (10) +4,141 (13) +4,142 (9) +4,143 (8) +4,144 (6) +4,145 (12) +4,146 (5) +4,147 (6) +4,148 (8) +4,149 (12) +4,150 (8) +4,151 (9) +4,152 (7) +4,153 (7) +4,154 (10) +4,155 (10) +4,156 (9) +4,157 (9) +4,158 (8) +4,159 (4) +4,160 (2) +4,161 (3) +4,162 (3) +4,163 (8) +4,164 (11) +4,165 (8) +4,166 (9) +4,167 (7) +4,168 (11) +4,169 (7) +4,170 (5) +4,171 (5) +4,172 (10) +4,173 (6) +4,174 (6) +4,175 (10) +4,176 (8) +4,177 (8) +4,178 (9) +4,179 (9) +4,180 (7) +4,181 (9) +4,182 (7) +4,183 (8) +4,184 (11) +4,185 (9) +4,186 (9) +4,187 (5) +4,188 (6) +4,189 (10) +4,190 (9) +4,191 (8) +4,192 (5) +4,193 (8) +4,194 (7) +4,195 (5) +4,196 (10) +4,197 (6) +4,198 (7) +4,199 (7) +4,200 (7) +4,201 (7) +4,202 (9) +4,203 (8) +4,204 (9) +4,205 (8) +4,206 (8) +4,207 (11) +4,208 (7) +4,209 (9) +4,210 (9) +4,211 (7) +4,212 (11) +4,213 (8) +4,214 (7) +4,215 (11) +4,216 (8) +4,217 (10) +4,218 (11) +4,219 (9) +4,220 (7) +4,221 (10) +4,222 (12) +4,223 (8) +4,224 (8) +4,225 (13) +4,226 (5) +4,227 (12) +4,228 (8) +4,229 (13) +4,230 (8) +4,231 (13) +4,232 (13) +4,233 (6) +4,234 (6) +4,235 (7) +4,236 (7) +4,237 (6) +4,238 (4) +4,239 (5) +4,240 (3) +4,241 (5) +4,242 (5) +4,243 (9) +4,244 (8) +4,245 (8) +4,246 (13) +4,247 (10) +4,248 (9) +4,249 (5) +4,250 (13) +4,251 (10) +4,252 (8) +4,253 (7) +4,254 (6) +4,255 (6) +4,256 (3) +4,257 (9) +4,258 (7) +4,259 (9) +4,260 (7) +4,348 (1) +5,1 (12) +5,2 (8) +5,3 (10) +5,4 (7) +5,5 (9) +5,6 (11) +5,7 (13) +5,8 (10) +5,9 (12) +5,10 (12) +5,11 (7) +5,12 (11) +5,13 (11) +5,14 (7) +5,15 (6) +5,16 (13) +5,17 (10) +5,18 (11) +5,19 (11) +5,20 (10) +5,21 (7) +5,22 (10) +5,23 (11) +5,24 (12) +5,25 (7) +5,26 (8) +5,27 (9) +5,28 (6) +5,29 (7) +5,30 (9) +5,31 (8) +5,32 (8) +5,33 (5) +5,34 (8) +5,35 (9) +5,36 (7) +5,37 (11) +5,38 (10) +5,39 (8) +5,40 (5) +5,41 (8) +5,42 (10) +5,43 (7) +5,44 (6) +5,45 (9) +5,46 (11) +5,47 (6) +5,48 (5) +5,49 (7) +5,50 (9) +5,51 (12) +5,52 (8) +5,53 (8) +5,54 (6) +5,55 (9) +5,56 (7) +5,57 (9) +5,58 (7) +5,59 (11) +5,60 (16) +5,61 (12) +5,62 (7) +5,63 (12) +5,64 (13) +5,65 (8) +5,66 (12) +5,67 (9) +5,68 (12) +5,69 (7) +5,70 (13) +5,71 (8) +5,72 (9) +5,73 (8) +5,74 (11) +5,75 (10) +5,76 (10) +5,77 (9) +5,78 (6) +5,79 (10) +5,80 (7) +5,81 (8) +5,82 (8) +5,83 (7) +5,84 (18) +5,85 (9) +5,86 (10) +5,87 (12) +5,88 (10) +5,89 (9) +5,90 (10) +5,91 (4) +5,92 (8) +5,93 (8) +5,94 (8) +5,95 (8) +5,96 (13) +5,97 (7) +5,98 (8) +5,99 (10) +5,100 (4) +5,101 (7) +5,102 (8) +5,103 (10) +5,104 (10) +5,105 (7) +5,106 (4) +5,107 (9) +5,108 (9) +5,109 (4) +5,110 (8) +5,111 (6) +5,112 (8) +5,113 (9) +5,114 (10) +5,115 (12) +5,116 (7) +5,117 (8) +5,118 (5) +5,119 (5) +5,120 (9) +5,121 (10) +5,122 (10) +5,123 (11) +5,124 (6) +5,125 (8) +5,126 (11) +5,127 (6) +5,128 (12) +5,129 (10) +5,130 (6) +5,131 (7) +5,132 (9) +5,133 (10) +5,134 (13) +5,135 (14) +5,136 (9) +5,137 (6) +5,138 (7) +5,139 (7) +5,140 (8) +5,141 (10) +5,142 (8) +5,143 (8) +5,144 (11) +5,145 (9) +5,146 (5) +5,147 (4) +5,148 (4) +5,149 (2) +5,150 (7) +5,151 (5) +5,152 (9) +5,153 (10) +5,154 (4) +5,155 (5) +5,156 (6) +5,157 (13) +5,158 (9) +5,159 (7) +5,160 (3) +5,161 (7) +5,162 (8) +5,163 (7) +5,164 (7) +5,165 (8) +5,166 (7) +5,167 (9) +5,168 (7) +5,169 (9) +5,195 (1) +6,1 (12) +6,2 (11) +6,3 (8) +6,4 (11) +6,5 (9) +6,6 (12) +6,7 (8) +6,8 (11) +6,9 (9) +6,10 (12) +6,11 (9) +6,12 (8) +6,13 (9) +6,14 (12) +6,15 (11) +6,16 (7) +6,17 (12) +6,18 (7) +6,19 (9) +6,20 (9) +6,21 (11) +6,22 (13) +6,23 (10) +6,24 (6) +6,25 (10) +6,26 (11) +6,27 (5) +6,28 (8) +6,29 (6) +6,30 (5) +6,31 (13) +6,32 (10) +6,33 (9) +6,34 (10) +6,35 (7) +6,36 (6) +6,37 (6) +6,38 (12) +6,39 (5) +6,40 (7) +6,41 (10) +6,42 (7) +6,43 (10) +6,44 (8) +6,45 (8) +6,46 (5) +6,47 (4) +6,48 (9) +6,49 (14) +6,50 (9) +6,51 (9) +6,52 (10) +6,53 (11) +6,54 (9) +6,55 (9) +6,56 (11) +6,57 (10) +6,58 (8) +6,59 (9) +6,60 (8) +6,61 (10) +6,62 (9) +6,63 (10) +6,64 (9) +6,65 (8) +6,66 (4) +6,67 (7) +6,68 (8) +6,69 (12) +6,70 (8) +6,71 (8) +6,72 (9) +6,73 (8) +6,74 (8) +6,75 (10) +6,76 (13) +6,77 (11) +6,78 (6) +6,79 (11) +6,80 (8) +6,81 (8) +6,82 (8) +6,83 (6) +6,84 (7) +6,85 (6) +6,86 (8) +6,87 (6) +6,88 (9) +6,89 (7) +6,90 (8) +6,91 (5) +6,92 (14) +6,93 (7) +6,94 (8) +6,95 (12) +6,96 (9) +6,97 (5) +6,162 (1) +6,165 (1) +6,183 (1) +7,1 (9) +7,2 (8) +7,3 (8) +7,4 (9) +7,5 (9) +7,6 (9) +7,7 (7) +7,8 (5) +7,9 (6) +7,10 (11) +7,11 (3) +7,12 (10) +7,13 (6) +7,14 (7) +7,15 (8) +7,16 (9) +7,17 (9) +7,18 (7) +7,19 (7) +7,20 (8) +7,21 (5) +7,22 (6) +7,23 (11) +7,24 (5) +7,25 (12) +7,26 (9) +7,27 (8) +7,28 (5) +7,29 (9) +7,30 (11) +7,31 (13) +7,32 (11) +7,33 (12) +7,34 (13) +7,35 (8) +7,36 (7) +7,37 (8) +7,38 (9) +7,39 (8) +7,40 (5) +7,41 (10) +7,42 (9) +7,43 (10) +7,44 (11) +7,45 (11) +7,46 (8) +7,47 (12) +7,48 (13) +7,49 (5) +7,50 (8) +7,51 (10) +7,52 (12) +7,53 (4) +7,54 (9) +7,55 (9) +7,56 (9) +7,57 (8) +7,58 (7) +7,59 (7) +7,60 (10) +7,61 (9) +7,62 (11) +7,63 (11) +7,64 (10) +7,65 (8) +7,66 (5) +7,67 (11) +7,68 (7) +7,69 (16) +7,70 (13) +7,71 (7) +7,72 (11) +7,73 (7) +7,74 (4) +7,75 (7) +7,76 (11) +7,77 (12) +7,78 (6) +7,79 (7) +7,80 (9) +7,81 (6) +7,82 (7) +7,83 (6) +7,84 (6) +7,85 (9) +7,86 (5) +7,87 (9) +7,88 (6) +7,89 (11) +7,90 (13) +7,91 (12) +7,92 (9) +7,93 (12) +7,94 (9) +7,95 (9) +7,96 (9) +7,97 (7) +7,98 (7) +7,99 (5) +7,100 (6) +7,101 (7) +7,102 (7) +7,103 (3) +7,104 (10) +7,105 (6) +7,106 (7) +7,107 (7) +7,108 (7) +7,109 (7) +7,110 (5) +7,111 (10) +7,112 (5) +7,113 (10) +7,114 (5) +7,115 (8) +7,116 (10) +7,117 (8) +7,118 (8) +7,119 (10) +7,120 (8) +7,121 (12) +7,122 (4) +7,123 (5) +7,124 (8) +7,125 (10) +7,126 (17) +7,127 (12) +7,128 (7) +7,129 (6) +7,130 (7) +7,131 (10) +7,132 (7) +7,133 (8) +7,134 (6) +7,135 (11) +7,136 (7) +7,137 (9) +7,138 (6) +7,139 (3) +7,140 (6) +7,141 (13) +7,142 (6) +7,143 (7) +7,144 (6) +7,145 (10) +7,146 (7) +7,147 (9) +7,148 (8) +7,149 (13) +7,150 (7) +7,151 (8) +7,152 (8) +7,153 (12) +7,154 (14) +7,155 (6) +7,156 (4) +7,157 (14) +7,158 (7) +7,159 (7) +7,160 (7) +7,161 (5) +7,162 (2) +7,163 (9) +7,164 (7) +7,165 (6) +7,166 (6) +7,167 (11) +7,168 (7) +7,169 (11) +7,170 (6) +7,171 (10) +7,172 (7) +7,173 (7) +7,174 (6) +7,175 (5) +7,176 (8) +7,177 (9) +7,178 (7) +7,179 (8) +7,180 (11) +7,181 (10) +7,182 (13) +7,183 (10) +7,184 (10) +7,185 (13) +7,186 (10) +7,187 (10) +7,188 (10) +7,189 (5) +7,190 (12) +7,191 (8) +7,192 (14) +7,193 (9) +7,194 (8) +7,195 (9) +7,196 (7) +7,197 (11) +7,198 (9) +7,199 (5) +7,200 (12) +7,201 (5) +7,202 (7) +7,203 (8) +7,204 (10) +7,205 (7) +7,206 (9) +7,207 (9) +7,208 (9) +7,209 (9) +7,210 (11) +7,211 (9) +7,212 (11) +7,213 (3) +7,214 (12) +7,215 (8) +7,216 (9) +7,217 (14) +7,218 (8) +7,219 (9) +7,220 (8) +7,221 (6) +7,222 (7) +7,223 (11) +7,224 (6) +7,225 (9) +7,226 (7) +7,2498 (1) +8,1 (8) +8,2 (11) +8,3 (9) +8,4 (9) +8,5 (8) +8,6 (8) +8,7 (9) +8,8 (8) +8,9 (4) +8,10 (12) +8,11 (5) +8,12 (5) +8,13 (4) +8,14 (6) +8,15 (1) +8,16 (5) +8,17 (6) +8,18 (7) +8,19 (9) +8,20 (8) +8,21 (8) +8,22 (12) +8,23 (7) +8,24 (10) +8,25 (11) +8,26 (9) +8,27 (10) +8,28 (10) +8,29 (7) +8,30 (10) +8,31 (6) +8,32 (6) +8,33 (10) +8,34 (11) +8,35 (7) +8,36 (7) +8,37 (7) +8,38 (9) +8,39 (7) +8,40 (5) +8,41 (10) +8,42 (7) +8,43 (9) +8,44 (8) +8,45 (6) +8,46 (4) +8,47 (8) +8,48 (6) +8,49 (7) +8,50 (6) +8,51 (8) +8,52 (9) +8,53 (11) +8,54 (9) +8,55 (10) +8,56 (6) +8,57 (8) +8,58 (7) +8,59 (13) +8,60 (10) +8,61 (8) +8,62 (13) +8,63 (8) +8,64 (10) +8,65 (9) +8,66 (10) +8,67 (11) +8,68 (6) +8,69 (9) +8,70 (7) +8,71 (12) +8,72 (7) +8,73 (9) +8,74 (8) +8,75 (10) +8,76 (11) +8,77 (10) +8,78 (8) +8,79 (9) +8,80 (6) +8,81 (9) +8,82 (12) +8,83 (4) +8,84 (4) +8,85 (5) +8,86 (9) +8,87 (7) +8,88 (8) +8,89 (10) +8,90 (8) +8,91 (3) +8,92 (7) +8,93 (15) +8,94 (13) +8,95 (13) +8,96 (3) +8,97 (7) +8,98 (4) +8,99 (2) +8,100 (5) +8,101 (7) +8,102 (7) +8,103 (10) +8,104 (13) +8,105 (9) +8,106 (12) +8,107 (6) +8,108 (10) +8,109 (9) +8,110 (7) +8,111 (5) +8,112 (9) +8,113 (7) +8,114 (10) +8,115 (9) +8,116 (12) +8,117 (4) +8,118 (6) +8,119 (7) +8,120 (8) +8,121 (10) +8,122 (6) +8,123 (5) +8,124 (7) +8,125 (8) +8,126 (7) +8,127 (11) +8,128 (7) +8,129 (13) +8,130 (7) +8,131 (10) +8,132 (10) +8,133 (6) +8,134 (8) +8,135 (7) +8,136 (7) +8,137 (4) +8,138 (8) +8,139 (10) +8,140 (10) +8,141 (4) +8,142 (7) +8,143 (12) +8,144 (9) +8,145 (9) +8,146 (9) +8,147 (6) +8,148 (9) +8,149 (10) +8,150 (10) +8,151 (12) +8,152 (8) +8,153 (12) +8,154 (8) +8,155 (6) +8,156 (8) +8,157 (11) +8,158 (8) +8,159 (9) +8,160 (7) +8,161 (9) +8,162 (6) +8,163 (10) +8,164 (11) +8,165 (7) +8,166 (8) +8,167 (9) +8,168 (6) +8,169 (7) +8,170 (6) +8,171 (6) +8,172 (8) +8,173 (11) +8,174 (7) +8,175 (5) +8,176 (6) +8,177 (9) +8,178 (8) +8,179 (12) +8,180 (8) +8,181 (7) +8,182 (8) +8,183 (5) +8,184 (8) +8,185 (9) +8,186 (4) +8,187 (9) +8,188 (7) +8,189 (5) +8,190 (9) +8,191 (7) +8,192 (6) +8,193 (9) +8,194 (8) +8,195 (7) +8,196 (7) +8,197 (8) +8,198 (11) +8,199 (5) +8,200 (7) +8,201 (7) +8,202 (10) +8,203 (10) +8,204 (9) +8,205 (9) +8,206 (5) +8,207 (4) +8,208 (4) +8,209 (14) +8,210 (11) +8,211 (4) +8,212 (6) +8,213 (9) +8,214 (9) +8,215 (8) +8,216 (10) +8,217 (4) +8,218 (7) +8,219 (7) +8,220 (9) +8,221 (5) +8,222 (10) +8,223 (8) +8,224 (7) +8,225 (9) +8,226 (9) +8,227 (10) +8,228 (7) +8,229 (6) +8,230 (6) +8,231 (11) +8,232 (10) +8,233 (9) +8,234 (10) +8,235 (12) +8,236 (10) +8,237 (10) +8,238 (9) +8,239 (12) +8,240 (12) +8,241 (10) +8,242 (10) +8,243 (8) +8,244 (5) +8,245 (12) +8,246 (11) +8,247 (10) +8,248 (9) +8,249 (7) +8,250 (13) +8,251 (9) +8,252 (9) +8,253 (6) +8,254 (10) +8,255 (7) +8,256 (10) +8,257 (8) +8,258 (5) +8,259 (7) +8,260 (10) +8,261 (6) +8,262 (9) +8,263 (7) +8,264 (9) +8,265 (8) +8,266 (8) +8,267 (7) +8,268 (5) +8,269 (5) +8,270 (9) +8,271 (11) +8,272 (8) +8,273 (9) +8,274 (12) +8,275 (8) +8,276 (9) +8,277 (11) +8,278 (8) +8,279 (8) +8,280 (9) +8,281 (13) +8,282 (10) +8,283 (8) +8,284 (10) +8,285 (7) +8,286 (7) +8,287 (8) +8,288 (6) +8,289 (9) +8,290 (7) +8,291 (12) +8,292 (9) +8,293 (10) +8,294 (6) +8,295 (8) +8,296 (10) +8,297 (7) +8,298 (12) +8,299 (10) +8,300 (9) +8,301 (9) +8,302 (6) +8,303 (5) +8,304 (3) +8,305 (7) +8,306 (6) +8,307 (10) +8,308 (3) +8,309 (8) +8,310 (9) +8,311 (8) +8,312 (8) +8,313 (10) +8,314 (7) +8,315 (10) +8,316 (8) +8,317 (12) +8,318 (5) +8,319 (10) +8,320 (9) +8,321 (7) +8,322 (11) +8,323 (6) +8,324 (9) +8,325 (4) +8,326 (9) +8,327 (7) +8,328 (4) +8,329 (7) +8,330 (9) +8,331 (8) +8,332 (7) +8,333 (5) +8,334 (8) +8,335 (4) +8,336 (7) +8,337 (5) +8,338 (5) +8,339 (8) +8,340 (9) +8,341 (11) +8,342 (12) +8,343 (7) +8,344 (9) +8,345 (6) +8,346 (7) +8,347 (8) +8,348 (6) +8,349 (7) +8,350 (9) +8,351 (11) +8,352 (10) +8,353 (8) +8,354 (7) +8,355 (6) +8,356 (6) +8,357 (9) +8,358 (6) +8,359 (8) +8,360 (6) +8,361 (6) +8,362 (9) +8,363 (6) +8,364 (9) +8,365 (8) +8,366 (9) +8,367 (9) +8,368 (10) +8,369 (5) +8,370 (7) +8,371 (8) +8,372 (8) +8,373 (7) +8,374 (8) +8,375 (8) +8,376 (7) +8,377 (7) +8,378 (8) +8,379 (5) +8,380 (8) +8,381 (7) +8,382 (4) +8,383 (5) +8,384 (5) +8,385 (6) +8,386 (14) +8,387 (6) +8,388 (6) +8,389 (5) +8,390 (6) +8,391 (8) +8,392 (7) +8,393 (4) +8,394 (8) +8,395 (8) +8,396 (9) +8,397 (8) +8,398 (8) +8,399 (8) +8,400 (10) +8,401 (9) +8,402 (7) +8,403 (8) +8,404 (9) +8,405 (11) +8,406 (11) +8,407 (7) +8,408 (8) +8,409 (9) +8,410 (9) +8,411 (5) +8,412 (7) +8,413 (7) +8,414 (7) +8,415 (10) +8,416 (4) +8,417 (9) +8,418 (7) +8,419 (9) +8,420 (6) +8,787 (1) +9,1 (7) +9,2 (6) +9,3 (3) +9,4 (3) +9,5 (4) +9,6 (6) +9,7 (4) +9,8 (7) +9,9 (7) +9,10 (9) +9,11 (12) +9,12 (9) +9,13 (6) +9,14 (3) +9,15 (7) +9,16 (10) +9,17 (9) +9,18 (5) +9,19 (11) +9,20 (6) +9,21 (7) +9,22 (4) +9,23 (8) +9,24 (7) +9,25 (7) +9,26 (10) +9,27 (10) +9,28 (9) +9,29 (8) +9,30 (9) +9,31 (7) +9,32 (9) +9,33 (9) +9,34 (9) +9,35 (6) +9,36 (6) +9,37 (6) +9,38 (9) +9,39 (9) +9,40 (8) +9,41 (11) +9,42 (8) +9,43 (9) +9,44 (9) +9,45 (10) +9,46 (7) +9,47 (6) +9,48 (8) +9,49 (12) +9,50 (9) +9,51 (10) +9,52 (8) +9,53 (6) +9,54 (9) +9,55 (7) +9,56 (10) +9,57 (5) +9,58 (5) +9,59 (6) +9,60 (7) +9,61 (8) +9,62 (6) +9,63 (7) +9,64 (5) +9,65 (8) +9,66 (6) +9,67 (10) +9,68 (9) +9,69 (8) +9,70 (12) +9,71 (6) +9,72 (10) +9,73 (8) +9,74 (10) +9,75 (9) +9,76 (7) +9,77 (10) +9,78 (7) +9,79 (9) +9,80 (7) +9,81 (11) +9,82 (8) +9,83 (7) +9,84 (6) +9,85 (8) +9,86 (8) +9,87 (10) +9,88 (8) +9,89 (13) +9,90 (8) +9,91 (5) +9,92 (6) +9,93 (8) +9,94 (10) +9,95 (7) +9,96 (8) +9,97 (7) +9,98 (5) +9,99 (5) +9,100 (12) +9,101 (6) +9,102 (6) +9,103 (7) +9,104 (7) +9,105 (6) +9,106 (5) +9,107 (12) +9,108 (5) +9,109 (6) +9,110 (6) +9,111 (7) +9,112 (8) +9,113 (5) +9,114 (9) +9,115 (8) +9,116 (6) +9,117 (5) +9,118 (5) +9,119 (7) +9,120 (6) +9,121 (6) +9,122 (7) +9,123 (10) +9,124 (7) +9,125 (3) +9,126 (7) +9,127 (8) +9,128 (8) +9,129 (9) +9,130 (6) +9,131 (8) +9,132 (8) +9,133 (5) +9,134 (6) +9,135 (4) +9,136 (8) +9,137 (7) +9,138 (8) +9,139 (10) +9,140 (5) +9,141 (8) +9,142 (7) +9,143 (9) +9,144 (8) +9,145 (5) +9,146 (3) +9,147 (10) +9,148 (6) +9,149 (5) +9,150 (8) +9,151 (8) +9,152 (6) +9,153 (6) +9,154 (7) +9,155 (5) +9,156 (6) +9,157 (4) +9,158 (12) +9,159 (6) +9,160 (8) +9,161 (10) +9,162 (7) +9,163 (6) +9,164 (8) +9,165 (7) +9,166 (6) +9,167 (9) +9,168 (6) +9,169 (6) +9,170 (7) +9,171 (5) +9,172 (9) +9,173 (7) +9,174 (8) +9,175 (6) +9,176 (6) +9,177 (6) +9,178 (8) +9,179 (5) +9,180 (8) +9,181 (7) +9,182 (4) +9,183 (6) +9,184 (7) +9,185 (5) +9,186 (8) +9,187 (8) +9,188 (8) +9,189 (7) +9,190 (8) +9,191 (3) +9,192 (9) +9,193 (5) +9,194 (9) +9,195 (5) +9,196 (9) +9,197 (5) +9,198 (9) +9,199 (5) +9,200 (7) +9,201 (10) +9,202 (6) +9,203 (7) +9,204 (5) +9,205 (6) +9,206 (6) +9,207 (6) +9,208 (7) +9,209 (7) +9,210 (6) +9,211 (7) +9,212 (8) +9,213 (4) +9,214 (5) +9,215 (7) +9,216 (7) +9,217 (4) +9,218 (7) +9,219 (12) +9,220 (7) +9,221 (4) +9,222 (7) +9,223 (4) +9,224 (5) +9,225 (10) +9,226 (7) +9,227 (9) +9,228 (8) +9,229 (11) +9,230 (11) +9,231 (8) +9,232 (14) +9,233 (6) +9,234 (6) +9,235 (7) +9,236 (7) +9,237 (11) +9,238 (8) +9,239 (6) +9,240 (6) +9,241 (4) +9,242 (8) +9,243 (4) +9,244 (8) +9,245 (5) +9,246 (8) +9,247 (7) +9,248 (11) +9,249 (8) +9,250 (8) +9,251 (4) +9,252 (10) +9,253 (10) +9,254 (9) +9,255 (7) +9,256 (6) +9,257 (10) +9,258 (10) +9,259 (9) +9,260 (10) +9,261 (13) +9,262 (7) +9,263 (8) +9,264 (11) +9,265 (11) +9,266 (10) +9,267 (8) +9,268 (6) +9,269 (8) +9,270 (8) +9,271 (9) +9,272 (8) +9,273 (10) +9,274 (14) +9,275 (8) +9,276 (9) +9,277 (8) +9,278 (9) +9,279 (8) +9,280 (9) +9,281 (8) +9,282 (8) +9,283 (11) +9,284 (9) +9,285 (8) +9,286 (11) +9,287 (9) +9,288 (9) +9,289 (10) +9,290 (9) +9,291 (9) +9,292 (8) +9,293 (10) +9,294 (11) +9,295 (7) +9,296 (8) +9,297 (7) +9,298 (7) +9,299 (7) +9,300 (4) +9,301 (6) +9,302 (10) +9,303 (8) +9,304 (2) +9,305 (6) +9,306 (7) +9,307 (7) +9,308 (7) +9,309 (6) +9,310 (7) +9,311 (4) +9,312 (6) +9,313 (11) +9,314 (6) +9,315 (6) +9,316 (4) +9,317 (5) +9,318 (10) +9,319 (9) +9,320 (7) +9,321 (13) +9,322 (12) +9,323 (6) +9,324 (7) +9,325 (6) +9,326 (7) +9,327 (4) +9,328 (6) +9,329 (10) +9,330 (9) +9,331 (9) +9,332 (6) +9,333 (6) +9,334 (6) +9,335 (11) +9,336 (8) +10,1 (6) +10,2 (4) +10,3 (7) +10,4 (5) +10,5 (9) +10,6 (10) +10,7 (8) +10,8 (9) +10,9 (11) +10,10 (1) +10,11 (5) +10,12 (8) +10,13 (9) +10,14 (6) +10,15 (7) +10,16 (7) +10,17 (5) +10,18 (8) +10,19 (8) +10,20 (8) +10,21 (6) +10,22 (8) +10,23 (6) +10,24 (5) +10,25 (7) +10,26 (7) +10,27 (5) +10,28 (6) +10,29 (5) +10,30 (5) +10,31 (6) +10,32 (10) +10,33 (13) +10,34 (12) +10,35 (10) +10,36 (10) +10,37 (9) +10,38 (7) +10,39 (8) +10,40 (6) +10,41 (5) +10,42 (6) +10,43 (7) +10,44 (13) +10,45 (8) +10,46 (4) +10,47 (9) +10,48 (15) +10,49 (11) +10,50 (8) +10,51 (9) +10,52 (10) +10,53 (7) +10,54 (7) +10,55 (10) +10,56 (6) +10,57 (14) +10,58 (7) +10,59 (9) +10,60 (8) +10,61 (9) +10,62 (7) +10,63 (8) +10,64 (11) +10,65 (3) +10,66 (7) +10,67 (4) +10,68 (7) +10,69 (7) +10,70 (5) +10,71 (8) +10,72 (8) +10,73 (8) +10,74 (6) +10,75 (6) +10,76 (3) +10,77 (3) +10,78 (4) +10,79 (10) +10,80 (5) +10,81 (6) +10,82 (13) +10,83 (9) +10,84 (7) +10,85 (13) +10,86 (10) +10,87 (9) +10,88 (10) +10,89 (8) +10,90 (8) +10,91 (10) +10,92 (9) +10,93 (7) +10,94 (13) +10,95 (12) +10,96 (5) +10,97 (6) +10,98 (8) +10,99 (8) +10,100 (4) +10,101 (8) +10,102 (11) +10,103 (9) +10,104 (10) +10,105 (9) +10,106 (11) +10,107 (11) +10,108 (9) +10,109 (8) +10,110 (3) +10,111 (7) +10,112 (11) +10,113 (11) +10,114 (8) +10,115 (9) +10,116 (13) +10,117 (7) +10,118 (8) +10,119 (7) +10,120 (10) +10,121 (7) +10,122 (6) +10,123 (6) +10,124 (9) +10,125 (7) +10,126 (4) +10,127 (12) +10,128 (11) +10,129 (6) +10,130 (6) +10,131 (7) +10,158 (1) +10,181 (1) +11,1 (10) +11,2 (7) +11,3 (9) +11,4 (6) +11,5 (8) +11,6 (5) +11,7 (9) +11,8 (7) +11,9 (12) +11,10 (5) +11,11 (6) +11,12 (7) +11,13 (3) +11,14 (7) +11,15 (8) +11,16 (6) +11,17 (9) +11,18 (10) +11,19 (4) +11,20 (8) +11,21 (5) +11,22 (7) +11,23 (7) +11,24 (6) +11,25 (9) +11,26 (9) +11,27 (10) +11,28 (6) +11,29 (7) +11,30 (9) +11,31 (4) +11,32 (3) +11,33 (8) +11,34 (6) +11,35 (9) +11,36 (8) +11,37 (5) +11,38 (7) +11,39 (6) +11,40 (11) +11,41 (9) +11,42 (6) +11,43 (9) +11,44 (6) +11,45 (7) +11,46 (8) +11,47 (5) +11,48 (6) +11,49 (10) +11,50 (10) +11,51 (11) +11,52 (9) +11,53 (11) +11,54 (10) +11,55 (7) +11,56 (9) +11,57 (9) +11,58 (10) +11,59 (12) +11,60 (5) +11,61 (7) +11,62 (8) +11,63 (11) +11,64 (7) +11,65 (10) +11,66 (11) +11,67 (8) +11,68 (10) +11,69 (9) +11,70 (15) +11,71 (5) +11,72 (11) +11,73 (9) +11,74 (11) +11,75 (9) +11,76 (7) +11,77 (14) +11,78 (10) +11,79 (10) +11,80 (7) +11,81 (7) +11,82 (11) +11,83 (6) +11,84 (8) +11,85 (7) +11,86 (11) +11,87 (6) +11,88 (7) +11,89 (7) +11,90 (10) +11,91 (6) +11,92 (12) +11,93 (6) +11,94 (7) +11,95 (18) +11,96 (8) +11,97 (8) +11,98 (8) +11,99 (7) +11,100 (5) +11,101 (9) +11,102 (8) +11,103 (13) +11,104 (9) +11,105 (8) +11,106 (8) +11,107 (8) +11,108 (7) +11,109 (9) +11,110 (10) +11,111 (9) +11,112 (9) +11,113 (9) +11,114 (9) +11,115 (6) +11,116 (7) +11,117 (6) +11,118 (9) +11,119 (12) +11,120 (8) +11,121 (8) +11,122 (10) +11,123 (9) +11,124 (7) +11,125 (10) +11,126 (10) +11,127 (6) +11,128 (9) +11,129 (5) +11,130 (5) +11,131 (11) +11,132 (11) +11,133 (9) +11,134 (9) +11,135 (8) +11,136 (9) +11,137 (8) +11,138 (7) +11,139 (9) +11,140 (9) +11,141 (7) +11,142 (12) +11,143 (8) +11,144 (11) +11,145 (10) +11,146 (11) +11,147 (9) +11,148 (6) +11,149 (9) +11,150 (9) +11,151 (5) +11,152 (8) +11,153 (8) +11,154 (11) +11,155 (7) +11,156 (10) +11,157 (7) +11,158 (5) +11,159 (10) +11,160 (12) +11,161 (7) +11,162 (7) +11,163 (6) +11,164 (8) +11,165 (7) +11,166 (9) +11,167 (10) +11,168 (9) +11,169 (9) +11,170 (9) +11,171 (6) +11,172 (9) +11,173 (7) +11,174 (8) +11,175 (5) +11,176 (6) +11,177 (8) +11,178 (5) +11,179 (7) +11,180 (10) +11,181 (4) +11,182 (8) +11,183 (9) +11,184 (7) +11,185 (6) +11,186 (9) +11,187 (8) +11,188 (5) +11,189 (8) +11,190 (9) +11,191 (6) +11,192 (6) +11,193 (5) +11,194 (8) +11,195 (10) +11,196 (8) +11,197 (7) +11,198 (9) +11,199 (11) +11,200 (9) +11,201 (11) +11,202 (8) +11,203 (9) +11,204 (9) +11,205 (7) +11,206 (6) +11,207 (8) +11,208 (6) +11,209 (6) +11,210 (6) +11,211 (7) +11,212 (10) +11,213 (6) +11,214 (7) +11,215 (9) +11,216 (10) +11,217 (9) +11,218 (8) +11,219 (4) +11,220 (8) +11,221 (8) +11,222 (10) +11,223 (9) +11,224 (10) +11,225 (3) +11,226 (6) +11,227 (7) +11,228 (6) +11,229 (4) +11,230 (5) +11,231 (10) +11,232 (6) +11,233 (7) +11,234 (5) +11,235 (5) +11,236 (8) +11,237 (7) +11,238 (9) +11,239 (6) +11,240 (9) +11,241 (8) +11,242 (6) +11,243 (3) +11,244 (5) +11,245 (9) +11,246 (10) +11,247 (5) +11,248 (10) +11,249 (8) +11,250 (9) +11,251 (8) +11,252 (7) +11,253 (5) +11,254 (9) +11,255 (8) +11,256 (10) +11,257 (8) +11,258 (8) +11,259 (8) +11,260 (6) +11,261 (10) +11,262 (8) +11,263 (9) +11,264 (4) +11,265 (7) +11,286 (1) +11,331 (2) +11,576 (1) +11,747 (1) +12,1 (5) +12,2 (7) +12,3 (9) +12,4 (7) +12,5 (9) +12,6 (8) +12,7 (6) +12,8 (6) +12,9 (10) +12,10 (7) +12,11 (9) +12,12 (7) +12,13 (7) +12,14 (7) +12,15 (6) +12,16 (7) +12,17 (5) +12,18 (12) +12,19 (6) +12,20 (9) +12,21 (6) +12,22 (5) +12,23 (7) +12,24 (10) +12,25 (7) +12,26 (9) +12,27 (9) +12,28 (7) +12,29 (8) +12,30 (7) +12,31 (8) +12,32 (11) +12,33 (10) +12,34 (5) +12,35 (2) +12,36 (5) +12,37 (5) +12,38 (6) +12,39 (4) +12,40 (10) +12,41 (7) +12,42 (9) +12,43 (8) +12,44 (6) +12,45 (11) +12,46 (7) +12,47 (10) +12,48 (8) +12,49 (5) +12,50 (6) +12,51 (4) +12,52 (7) +12,53 (7) +12,54 (8) +12,55 (12) +12,56 (9) +12,57 (7) +12,58 (9) +12,59 (12) +12,60 (6) +12,61 (8) +12,62 (9) +12,63 (9) +12,64 (11) +12,65 (11) +12,66 (7) +12,67 (10) +12,68 (11) +12,69 (7) +12,70 (8) +12,71 (10) +12,72 (7) +12,73 (9) +12,74 (8) +12,75 (6) +12,76 (9) +12,77 (8) +12,78 (7) +12,79 (9) +12,80 (9) +12,81 (5) +12,82 (8) +12,83 (6) +12,84 (4) +12,85 (8) +12,86 (5) +12,87 (9) +12,88 (8) +12,89 (9) +12,90 (7) +12,91 (6) +12,92 (7) +12,93 (5) +12,94 (6) +12,95 (8) +12,96 (10) +12,97 (7) +12,98 (8) +12,99 (6) +12,100 (4) +12,101 (9) +12,102 (13) +12,103 (4) +12,104 (4) +12,105 (8) +12,106 (9) +12,107 (6) +12,108 (7) +12,109 (7) +12,110 (7) +12,111 (9) +12,112 (6) +12,113 (4) +12,114 (9) +12,115 (7) +12,116 (5) +12,117 (8) +12,118 (7) +12,119 (4) +12,120 (12) +12,121 (10) +12,122 (9) +12,123 (8) +12,124 (7) +12,125 (6) +12,126 (13) +12,179 (1) +12,212 (1) +12,226 (1) +12,917 (1) +12,921 (1) +12,1321 (1) +12,1825 (1) +13,63 (1) +13,1659 (1) +40,53 (1) +51,5 (1) +70,95 (1) +70,97 (1) +87,11 (1) +87,18 (1) +125,210 (1) diff --git a/pwgissues/issue74/ls_M_invalid.txt b/pwgissues/issue74/ls_M_invalid.txt new file mode 100644 index 0000000..aad938c --- /dev/null +++ b/pwgissues/issue74/ls_M_invalid.txt @@ -0,0 +1,37 @@ +(1,144) 2901-0023aKila M. 1, 144. +(12,917) 12891-0095atiTin M. 12, 917. +(12,921) 12891-0095atiTin 921. +(11,286) 39591-0294apaveDa M. 11, 286. +(1,4116) 59351-0439ard M. 1, 4116. +(6,183) 72571-0538as M. 6, 183. +(11,331) 73731-0551asAra M. 11, 331. +(87,11) 99901-0780icCA 87, 11. +(3,628) 203152-0549kzip M. 3, 628. +(13,63) 228442-0779gfDra 13, 63. +(2,317) 236752-0852grahaRa M. 2, 317. +(8,787) 249022-0952car 8, 787. +(12,1321) 250282-0975carmAvakarttar M. 12, 1321. +(11,576) 258822-1054cela 576 +(51,5) 263063-0001ja 51, 5. +(125,210) 279773-0159jyEzWya 125, 210. +(12,179) 350153-0778doza 179. +(3,12484) 384384-0110nABivarDana M. 3, 12484. +(10,181) 445184-0661pApapuruza M. 10, 181. +(5,195) 479424-0927prajA 195. +(12,226) 539735-0195Badraka M. 12, 226. +(70,97) 568465-0480madya 97. +(70,95) 568465-0480madya 70, 95. +(13,1659) 608835-0810muc 13, 1659. +(12,212) 612175-0849mUtra 12, 212. +(11,331) 658815-1079asAra M. 11, 331 +(4,348) 850426-0392ruD M. 4, 348. +(10,158) 866366-0578loka 10, 158. +(3,6028) 896316-0904vARijaka 6028. +(87,18) 906696-0972vAstu 87, 18. +(7,2498) 920536-1092vinirgama M. 7, 2498. +(40,53) 964036-1454vyavahAra 40, 53. +(1,180) 979027-0076Sam 1, 180. +(12,1825) 1052277-0678samagra 12, 1825. +(6,165) 1082177-0913sADu 165. +(6,162) 1082177-0913sADu 6, 162. +(11,747) 1112627-1114surA M. 11, 747. diff --git a/pwgissues/issue74/readme.txt b/pwgissues/issue74/readme.txt index 1ccb24e..d00a022 100644 --- a/pwgissues/issue74/readme.txt +++ b/pwgissues/issue74/readme.txt @@ -343,10 +343,56 @@ cp /c/xampp/htdocs/sanskrit-lexicon/PWG/pwg_ls2/ak/lsextract_all.py . cp /c/xampp/htdocs/cologne/csl-pywork/v02/distinctfiles/pwg/pywork/pwgauth/pwgbib_input.txt . python lsextract_all.py temp_pwg_3.txt pwgbib_input.txt lsextract_all.txt -compare to Amarakosha (AK.) done exactly 2 years ago. +compare to https://github.com/sanskrit-lexicon/PWG/blob/master/pwg_ls2/ak/lsextract_pwg_1.txt done exactly 2 years ago. ---------------------------------- sync this repo to github +---------------------------------- +09-12-2024 reopen for a few changes + +------------------------ +# generate change_0a file: +python diff_to_changes_dict.py temp_pwg_0.txt temp_pwg_0a.txt change_0a.txt +27 changes written to change_0a.txt + +---------------------------------- +# remove un-needed work file +rm temp_pwg_3_work.txt + +---------------------------------- +# 4 ls unknowns +Ref: https://github.com/sanskrit-lexicon/PWG/issues/74#issuecomment-2345495387 +cp temp_pwg_3.txt temp_pwg_4.txt +manual edit temp_pwg_4.txt + +---------------------------------- +# discover bug in linksort.py (in get_standard_regexes) +# linksorta.py corrects the bug +# +python linksorta.py 2 temp_pwg_3.txt linksorta2_3.txt +22557 total number of 'regular' links +2723 cases written to linksorta2_3.txt + +The correction does not affect the total number of regular links. +It does increase the number of cases, from 2659 to 2723. +------------------------------------------------------- + +---------------------------------- +compare linksort2_3.txt with +c:/xampp/htdocs/sanskrit-lexicon/PWG/pwgissues/issue73/Manu.Deslongchamps.index.txt +Based on the index, there are 37 invalid adhyAya,shlokas. + These are identified in file ls_M_invalid.txt + +Note: program used to find some info (metaline, ) of invalid items. +python linksort_debug.py 2 temp_pwg_3.txt ls_M_invalid.txt + +---------------------------------- + +---------------------------------- + +---------------------------------- +---------------------------------- +---------------------------------- ---------------------------------- THE END