This repository has been archived by the owner on Sep 30, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 127
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #55 from ravenscroftj/feature/gpu_layers
WIP: Integrate more direct GPU support
- Loading branch information
Showing
18 changed files
with
519 additions
and
20 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
build/ | ||
models/ |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,12 @@ | ||
[submodule "ggml"] | ||
path = extern/ggml | ||
url = git@github.com:ravenscroftj/ggml.git | ||
url = git@github.com:ggerganov/ggml.git | ||
[submodule "extern/argparse"] | ||
path = extern/argparse | ||
url = https://github.com/p-ranav/argparse.git | ||
[submodule "extern/sbdlog"] | ||
path = extern/spdlog | ||
url = https://github.com/gabime/spdlog.git | ||
[submodule "extern/ggml"] | ||
path = extern/ggml | ||
url = https://github.com/ggerganov/ggml |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{ | ||
"configurations": [ | ||
{ | ||
"name": "Linux", | ||
"includePath": [ | ||
"${workspaceFolder}/**", | ||
"${workspaceFolder}/extern/crow/include", | ||
"${workspaceFolder}/include", | ||
"${workspaceFolder}/include" | ||
], | ||
"defines": [], | ||
"compilerPath": "/usr/bin/gcc", | ||
"cStandard": "c17", | ||
"cppStandard": "gnu++17", | ||
"intelliSenseMode": "linux-gcc-x64", | ||
"configurationProvider": "ms-vscode.cmake-tools" | ||
} | ||
], | ||
"version": 4 | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
{ | ||
// Use IntelliSense to learn about possible attributes. | ||
// Hover to view descriptions of existing attributes. | ||
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"name": "(gdb) Launch TBP", | ||
"type": "cppdbg", | ||
"request": "launch", | ||
"program": "/home/james/workspace/rafael-llm/turbopilot/build/bin/turbopilot", | ||
"args": [ | ||
//TBP ARGS | ||
"-v", | ||
"-f", | ||
"/home/james/Downloads/replit-code-v1-3b-q4_0.bin", | ||
"-m", | ||
"replit", | ||
], | ||
"stopAtEntry": false, | ||
"cwd": "${workspaceFolder}", | ||
"environment": [], | ||
"externalConsole": false, | ||
"MIMode": "gdb", | ||
"setupCommands": [ | ||
{ | ||
"description": "Enable pretty-printing for gdb", | ||
"text": "-enable-pretty-printing", | ||
"ignoreFailures": true | ||
}, | ||
{ | ||
"description": "Set Disassembly Flavor to Intel", | ||
"text": "-gdb-set disassembly-flavor intel", | ||
"ignoreFailures": true | ||
} | ||
] | ||
}, | ||
{ | ||
"name": "(gdb) Launch Replut", | ||
"type": "cppdbg", | ||
"request": "launch", | ||
"program": "/home/james/workspace/rafael-llm/turbopilot/extern/ggml/build/bin/replit", | ||
"args": [ | ||
// REPLIT ARGS | ||
"-m", | ||
"/home/james/Downloads/replit-code-v1-3b-q4_0.bin", | ||
"-f", | ||
"/home/james/workspace/rafael-llm/turbopilot/test.txt" | ||
], | ||
"stopAtEntry": false, | ||
"cwd": "${workspaceFolder}", | ||
"environment": [], | ||
"externalConsole": false, | ||
"MIMode": "gdb", | ||
"setupCommands": [ | ||
{ | ||
"description": "Enable pretty-printing for gdb", | ||
"text": "-enable-pretty-printing", | ||
"ignoreFailures": true | ||
}, | ||
{ | ||
"description": "Set Disassembly Flavor to Intel", | ||
"text": "-gdb-set disassembly-flavor intel", | ||
"ignoreFailures": true | ||
} | ||
] | ||
}, | ||
|
||
] | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{ | ||
"tasks": [ | ||
{ | ||
"type": "cppbuild", | ||
"label": "C/C++: g++ build active file", | ||
"command": "/usr/bin/g++", | ||
"args": [ | ||
"-fdiagnostics-color=always", | ||
"-g", | ||
"${file}", | ||
"-o", | ||
"${fileDirname}/${fileBasenameNoExtension}" | ||
], | ||
"options": { | ||
"cwd": "${fileDirname}" | ||
}, | ||
"problemMatcher": [ | ||
"$gcc" | ||
], | ||
"group": { | ||
"kind": "build", | ||
"isDefault": true | ||
}, | ||
"detail": "Task generated by Debugger." | ||
} | ||
], | ||
"version": "2.0.0" | ||
} |
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
Submodule ggml
updated
61 files
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
#!/bin/sh | ||
|
||
/app/turbopilot -t $THREADS -m $MODEL_TYPE -f $MODEL | ||
if [ -z "$GPU_LAYERS" ]; then | ||
/app/turbopilot -t $THREADS -m $MODEL_TYPE -f $MODEL | ||
else | ||
/app/turbopilot -t $THREADS -m $MODEL_TYPE -f $MODEL --ngl $GPU_LAYERS | ||
fi |
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
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
Oops, something went wrong.