GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — document_rating/preprocess_imdb.py at master · abc3436645/document_rating Expand file tree/ Copy pathpreprocess_imdb.pyMore file actions 16 lines (12 loc) · 374 Bytes / Copy pathpreprocess_imdb.pyFile metadata and controls16 lines (12 loc) · 374 Bytes 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 __author__ = 'NLP-PC' from string import punctuation def clean_str(sentence): """ Tokenization/string cleaning for dataset Every dataset is lower cased except """ for p in list(punctuation): sentence = sentence.replace(p, '') return sentence.strip().lower() if __name__ == '__main__': print(clean_str('we ok and you? AFE and Who a')) |
| You are visitor 01402792 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |