Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Align with llama.cpp b1488 #249

Merged
merged 3 commits into from
Nov 6, 2023

Conversation

SignalRT
Copy link
Collaborator

@SignalRT SignalRT commented Nov 5, 2023

Align with the latest llama.cpp binaries.

@martindevans
Copy link
Member

@SignalRT I've started a GitHub action run to build the binaries for all platforms (currently running here). I'll PR them into this branch once the run has finished.

@SignalRT
Copy link
Collaborator Author

SignalRT commented Nov 5, 2023

@martindevans , see this other PR #241 because it includes the Intel build, and maybe should be included. It will enable to pass the test on GitHub con MacOS intel before they allow to run the test on MacOS arm.

@martindevans
Copy link
Member

Related to that other PR, I just opened up this issue: #251

@martindevans
Copy link
Member

I just pushed binaries into this PR. To be honest I expected to have to open up a PR into your fork, I didn't expect to be able to push them directly!

I added all the binaries from this run except for the MacOS ones. Those can be added too if you want, but I'll leave it up to you.

@SignalRT
Copy link
Collaborator Author

SignalRT commented Nov 5, 2023

@martindevans I added the MacOS binaries from the same run and passed all the test manually successfully.

@lexxsoft
Copy link

lexxsoft commented Nov 5, 2023

In response of @martindevans #245 (comment) request, I have checked out https://github.com/SignalRT/LLamaSharp/tree/Align-Current-Binaries and build them. Then I have referenced LLamaSharp.dll and libllama-cuda12.dll on my test code, but I am getting

TypeInitializationException: The type initializer for 'LLama.Native.NativeApi' threw an exception.

while if I reference libllama.dll everything is fine, so I do not know how to properly test Cuda12 backend.
What else am I missing?

@martindevans
Copy link
Member

What else am I missing?

You probably need to rename libllama-cuda12.dll to libllama.dll

@lexxsoft
Copy link

lexxsoft commented Nov 6, 2023

@martindevans ok, I did not realize this is p/invoke. Rename helped.

version time
v0.5.1 Cuda12 14.696
v0.7.0 Cuda12 1:09.663
https://github.com/SignalRT/LLamaSharp/tree/Align-Current-Binaries Cuda12 12.972

And as a bonus the newest version is consistently faster than v0.5.1.

@martindevans
Copy link
Member

Thanks for all your help with testing @lexxsoft ❤️

@SignalRT With that testing done I think this is ready to merge?

@martindevans martindevans merged commit 6334f25 into SciSharp:master Nov 6, 2023
6 checks passed
@AsakusaRinne
Copy link
Collaborator

After this PR has been merge, is everything about binary ok to publish a new release? Because of the performance problem in 0.7.0, I think we should add a release 0.7.1.

@martindevans
Copy link
Member

If possible can we wait for the Intel macos PR (#258) because that will act as a test case for the runtime feature detection.

@AsakusaRinne
Copy link
Collaborator

If possible can we wait for the Intel macos PR (#258) because that will act as a test case for the runtime feature detection.

Sure :)

@SignalRT SignalRT deleted the Align-Current-Binaries branch November 11, 2023 12:46
@lexxsoft
Copy link

@SignalRT , @martindevans, has 0.8.0 Cuda12 been tested on Windows?
When I try to add LLamaSharp.Backend.Cuda12 to the project I am getting Warning: No compatible assemblies found in package 'LLamaSharp.Backend.Cuda12'. Maybe this is only me?

@martindevans
Copy link
Member

I believe @AsakusaRinne tested them?

@lexxsoft
Copy link

I believe @AsakusaRinne tested them?

Hm, this is fine on Rider, however LINQPad 7 returns that Warning: No compatible assemblies found in package 'LLamaSharp.Backend.Cuda12', fails to install the package, and throws runtime exception of missing backend.

@AsakusaRinne
Copy link
Collaborator

I tested with VS and it worked fine. Have you ever had problem when using previous versions of LLamaSharp with LinqPad?

@lexxsoft
Copy link

@AsakusaRinne, no, older package versions work just fine

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants