ts2epg.write(tmppath + bctype + "epgdata.xml", chdb.bctypesearch(bctype)['ch'])
xml2db.xml2db(tmppath + bctype + "epgdata.xml", bctype)
shutil.copyfile(tmppath + bctype + "epgdata.xml", tmppath + bctype + "epgdata.bak.xml")
ts2epg.write(tmppath + bctype + "epgdata.xml", chdb.bctypesearch(bctype)['ch'])
xml2db.xml2db(tmppath + bctype + "epgdata.xml", bctype)
shutil.copyfile(tmppath + bctype + "epgdata.xml", tmppath + bctype + "epgdata.bak.xml")
for chtxtt, title, start, stop ,exp,longexp,category in d:
#print chtxtt+":"+title+":"+start+":"+stop
p = n_gram.bigram(titletxt, title)
for chtxtt, title, start, stop ,exp,longexp,category in d:
#print chtxtt+":"+title+":"+start+":"+stop
p = n_gram.bigram(titletxt, title)
beforetime = time.strftime("%Y%m%d%H%M%S")
aftertime = time + datetime.timedelta(hours=deltatime)
aftertime = aftertime.strftime("%Y%m%d%H%M%S")
beforetime = time.strftime("%Y%m%d%H%M%S")
aftertime = time + datetime.timedelta(hours=deltatime)
aftertime = aftertime.strftime("%Y%m%d%H%M%S")
for chtxtt, title, start, stop ,exp,longexp,category in d:
btime = start
btime = btime[0:4] + "-" + btime[4:6] + "-" + btime[6:8] + " " + btime[8:10] + ":" + btime[10:12] + ":00"
for chtxtt, title, start, stop ,exp,longexp,category in d:
btime = start
btime = btime[0:4] + "-" + btime[4:6] + "-" + btime[6:8] + " " + btime[8:10] + ":" + btime[10:12] + ":00"