Giter VIP home page Giter VIP logo

Comments (5)

vkuzmin-uber avatar vkuzmin-uber commented on May 17, 2024

I see "multiprocess" reported error, so OPE (Out Of Process execution is used, this is set by RuntimeOptions.use_ope).

I actually can see use_ope=True

  File "/home/app/miniconda3/envs/tf1x/lib/python3.7/site-packages/neuropod/loader.py", line 117, in __init__
    neuropod_path, _REGISTERED_BACKENDS, use_ope=True, **kwargs

In this case model is executed by "worker".

I can advise 2 options:

  1. Check for neuropod_multiprocess_worker binary file (it should be in "bin" directory) and add it to your path. For example, how I used it recently:
    PATH=$PATH:bin/ DYLD_LIBRARY_PATH=lib "command here"
  2. set RuntimeOptions.use_ope=false to not use OPE (but it doesn't look that this is available option in your example).

from neuropod.

yapus avatar yapus commented on May 17, 2024

Thanks for your reply. But that didn't help though....

  1. adding neuropod_multiprocess_worker container folder to PATH doesn't change anything
$ which neuropod_multiprocess_worker >/dev/null && echo 'OK'
OK

as i told before - there's no file named libneuropod_tensorflow_backend.so at my PC now for sure

  1. How to set RuntimeOptions in python? as i can see from the neuropod/loader.py - the use_ope=True is always set and if i provide that option again in "runtime options" that is args of load_neuropod like:
with load_neuropod(PATH_TO_MODEL, use_ope=False, visible_gpu=None) as neuropod:

i get another error:

TypeError: pybind11_type object got multiple values for keyword argument 'use_ope'

from neuropod.

VivekPanyam avatar VivekPanyam commented on May 17, 2024

Hi @yapus,

Thanks for the issue! Did you follow the instructions at https://neuropod.ai/installing/#python?

Specifically

To run models, you must also install packages for "backends". These are fully self-contained packages that let Neuropod run models with specific versions of frameworks regardless of the version installed in your python environment.

The page linked above includes instructions for installing backends. Based on the info in your initial comment, you probably want to run

pip install neuropod-backend-tensorflow-1-14-0-cpu -f https://download.neuropod.ai/whl/stable.html

Fixes

  1. The error that's supposed to be thrown in this situation is a bit more informative:

// Don't have anything that matches
NEUROPOD_ERROR("The model being loaded requires a Neuropod backend for type '{}' and version range '{}'. However, "
"a backend satisfying these requirements was not found. See the installation instructions "
"at https://neuropod.ai to install a backend. Retry with log level TRACE for more information.",
type,
target_version_range);

It looks like we hit another error first though. I'll put up a PR to clean this up.

  1. I'll modify the Issue template to make this more clear:

Using OPE: no (not sure what it is...)

Question

Is this phrasing in the installation instructions clear?

To run models, you must also install packages for "backends".

If test data is provided during packaging, Neuropod runs a test on the model immediately after export. In this situation, packaging a model also causes the model to be run. Do you think the sentence quoted above is misleading?

Would it be more clear to just say something like "To use Neuropod, you must also have at least one backend installed"?

from neuropod.

yapus avatar yapus commented on May 17, 2024

@VivekPanyam oh sorry, totally my bad, i really missed that part
after installing neuropod-backend-tensorflow-1-14-0-cpu it works as expected, at least that very basic test don't fail any more. I should really RTFM more mindfully.

Is a backend module required to package neuropod model? It is strange though - you mention that i should have faced same error during packaging the model as i do have test input & output data defined and passed to create_tensorflow_neuropod method, but the model was packaged without any errors, though at that time i didn't have any backend modules installed

from neuropod.

tomzhang avatar tomzhang commented on May 17, 2024

should we create a helper scripts to automatic resolve this kind of problem .
like if we can create a script which will auto install specific backend (tensorflow,pytorch, etc) with explicit recommendation on the terminal

from neuropod.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.