def id2token(id): global rev_ixi if not rev_ixi: rev_ixi = ainodex.ixicon(0) return ainodex.ixicon_entry(rev_ixi, id)
def show_best_ix(layers): top = ainodex.top_ixemes(layers, 100) snip = "<br>".join(map(lambda x: "%s %2.3f" % (ainodex.ixicon_entry(rixicon, x[0]), x[1]), top)) return "Top-100 tokens", "#", "#", snip
def show_best_ix(layers): top = ainodex.top_ixemes(layers, 100) snip = "<br>".join( map(lambda x: "%s %2.3f" % (ainodex.ixicon_entry(rixicon, x[0]), x[1]), top)) return "Top-100 tokens", "#", "#", snip