gpt2-tokenizer / index.html
julien-c's picture
julien-c HF staff
minimal example Pyodide
c174bab verified
raw
history blame
550 Bytes
<!DOCTYPE html>
<html>
<head>
<script src="https://cdn.jsdelivr.net/pyodide/v0.19.1/full/pyodide.js"></script>
</head>
<body>
Pyodide test page <br>
Open your browser console to see Pyodide output
<script type="text/javascript">
(async function main(){
const pyodide = await loadPyodide({
indexURL : "https://cdn.jsdelivr.net/pyodide/v0.19.1/full/"
});
console.log(pyodide.runPython(`
import sys
sys.version
`));
console.log(pyodide.runPython("print(1 + 2)"));
})();
</script>
</body>
</html>