-
Add Graal JIT Compilation to Your JVM Language in 5 Steps, A Tutorial http://stefan-marr.de/2015/11/add-graal-jit-compilation-to-your-jvm-language-in-5-easy-steps-step-1/
-
The SimpleLanguage, an example of using Truffle with great JavaDocs. It is the officle getting-started project: https://github.com/graalvm/simplelanguage
-
Truffle Tutorial, Christan Wimmer, PLDI 2016, 3h recording https://youtu.be/FJY96_6Y3a4 Slides
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Youtube = (function () { | |
'use strict'; | |
var video, results; | |
var getThumb = function (url, size) { | |
if (url === null) { | |
return ''; | |
} | |
size = (size === null) ? 'big' : size; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Each YouTube video has 4 generated images. They are predictably formatted as follows: | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/0.jpg | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/1.jpg | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/2.jpg | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/3.jpg | |
The first one in the list is a full size image and others are thumbnail images. The default thumbnail image (ie. one of 1.jpg, 2.jpg, 3.jpg) is: | |
http://img.youtube.com/vi/<insert-youtube-video-id-here>/default.jpg | |
For the high quality version of the thumbnail use a url similar to this: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# must have miniconda installed | |
# installation for musicgen | |
conda create -n audiocraft python=3.9 | |
conda activate audiocraft | |
brew install ffmpeg (for mac) | |
winget install ffmpeg (for windows) | |
git clone https://github.com/facebookresearch/audiocraft.git | |
cd audiocraft | |
python -m pip install -r requirements.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import ollama | |
import time | |
def read_file(file_path): | |
""" | |
Reads the content of a file and decodes it using the 'latin-1' encoding. | |
Args: | |
file_path (str): The path to the file to be read. | |