Update README.md
Browse files50 unmodified lines5152535455565758596061626364656667686970717250 unmodified linesYou must install the Nvidia cuda toolkit first, if you want to do GPU inference.Next, install the `quickmt` python library and download the model:```bashgit clone https://github.com/quickmt/quickmt.gitpip install ./quickmt/quickmt-model-download quickmt/quickmt-en-pl ./quickmt-en-pl```Finally use the model in python:```pythonfrom quickmt import Translator# Auto-detects GPU, set to "cpu" to force CPU inferencet = Translator("./quickmt-en-pl/", device="auto")# Translate - set beam size to 5 for higher quality (but slower speed)sample_text = 'Dr. Ehud Ur, professor of medicine at Dalhousie University in Halifax, Nova Scotia and chair of the clinical and scientific division of the Canadian Diabetes Association cautioned that the research is still in its early days.'50 unmodified lines5152535455565758596061626364656667686970717273747550 unmodified linesYou must install the Nvidia cuda toolkit first, if you want to do GPU inference.Next, install the `quickmt` [python library](github.com/quickmt/quickmt).```bashgit clone https://github.com/quickmt/quickmt.gitpip install ./quickmt/```Finally, use the model in python:```pythonfrom quickmt import Translatorfrom huggingface_hub import snapshot_download# Download Model (if not downloaded already) and return path to local model# Device is either 'auto', 'cpu' or 'cuda't = Translator(snapshot_download("quickmt/quickmt-en-pl", ignore_patterns="eole-model/*"),device="cpu")# Translate - set beam size to 5 for higher quality (but slower speed)sample_text = 'Dr. Ehud Ur, professor of medicine at Dalhousie University in Halifax, Nova Scotia and chair of the clinical and scientific division of the Canadian Diabetes Association cautioned that the research is still in its early days.'
README.md+10-7