Skip to content

Unable to load a saved model #16

Description

@lucas-vizru

I am trying to load a saved model so that I can avoid wasting time building the index each time I run my code.

An example that produces the error is attached.

I found that following your save examples works fine it's just when trying to combine the first search example with a saved model that things seem to go awry.

`numba.core.errors.TypingError: Failed in nopython mode pipeline (step: nopython frontend)
Cannot bind 'args=(Array(int32, 1, 'C', True, aligned=True), Array(float32, 1, 'C', True, aligned=True), Array(int32, 1, 'C', False, aligned=True), Array(float32, 1, 'C', False, aligned=True)) kws={}' to signature '(x, y)' due to "TypeError: too many positional arguments".
During: resolving callee type: type(CPUDispatcher(<function alternative_cosine at 0x10a169ee0>))
During: typing of call at /Users/lucas/K8_Projects/GameLauncher/.venv/lib/python3.13/site-packages/pynndescent/pynndescent_.py (1560)

File ".venv/lib/python3.13/site-packages/pynndescent/pynndescent_.py", line 1560:
def search_closure(

d = np.float32(
dist(
^

During: Pass nopython_type_inference`

failExample.py.txt

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions