Giter Site home page Giter Site logo

problem about NACL about nnpack HOT 7 CLOSED

maratyszcza avatar maratyszcza commented on May 20, 2024
problem about NACL

from nnpack.

Comments (7)

zhaishengfu avatar zhaishengfu commented on May 20, 2024

i have change the browser to google and change the configuration of nnpack.nmf, now it changes to "Waiting for NNPACK module", i also see google native client tutorialm, but still dont know how to start the program. as i know, it is waiting for "load" and "progress" event, but how can i generate those events to make the html listen??

from nnpack.

Maratyszcza avatar Maratyszcza commented on May 20, 2024
  1. You have to use Google Chrome. Other browsers don't support this technology.
  2. The Web demo you are trying to use was switched to PNaCl, rather than NaCl. Unlike NaCl, PNaCl is enabled by default in the Google Chrome. Unfortunately, it is also about 4x slower than NaCl.
  3. You need to serve the Web demo through a Web server. Opening the HTML file locally wouldn't work. If you just want to look at performance of PNaCl implementation on your machine, try this demo page

from nnpack.

zhaishengfu avatar zhaishengfu commented on May 20, 2024

Thanks to your reply!!
I know it should be chrome , after change to chrome, the error is as below:
000

but why can't NACI?? i found that under /bin directory there are many .nexe compiled files(each with original compiled programming),
000

Are they all of no use????besides, i want to use NACI because i want accurate c/c++ running time and i think this tool is convenient for me to change the parameters and see the time. If i can only use PNaCI and it is slower than NaCI, does the web time have any meaning???as you said, i think the only method for me to have the accurate time of runing will be Command line as below:
000
if this is the case, why you said in ReadME as following:

  • Configure NNPACK with --host=x86_64-nacl-glibc or --host=x86_64-nacl-newlib (recommended) option.
    I used the recommended command with --host=x86_64-nacl-newlib.

So , Do I misunderstand your meaning??with my understanding, your meaning is:

  1. I can't use NACI and can only use PNACI.
  2. PNacI is alwalys slower than the actual pure c/c++ programming running. So , what can the time shown in your web demo illustrate?? My meaning is that PNACI may add some google native client time to it so it can't tell us anything about the real and accurate c/c++ runing time
  3. Your code don't offer the ability to build a Web server for the html to run. I need extra work to run your html sample

from nnpack.

Maratyszcza avatar Maratyszcza commented on May 20, 2024

Do you actually need to use NNPACK inside a Web browser? If no, just build the native binary for your system (./configure.py && ninja), and use command-line programs from bin directory to benchmark. They let you change parameters via command-line arguments.

from nnpack.

zhaishengfu avatar zhaishengfu commented on May 20, 2024

ok. I just think your web demo is convenient to change the parameter.
Thanks to your patient answer.

from nnpack.

Maratyszcza avatar Maratyszcza commented on May 20, 2024

The Web demo is intended to demonstrate working NNPACK inside a Web browser. It is not intended to be a convenient interface for benchmarking for two reasons:

  1. NNPACK running inside a Web browser is slower than native version, because of special sandboxing the code needs to do to satisfy security constraints of a browser. For convolution, the slowdown is about 2x when using NaCl and about 8x when using PNaCl.
  2. Modern browsers run many extra threads in background, which interfere with parallelization inside NNPACK, and make time measurements noisy.

If you goal is not to run inside a web browser, don't. The command-line programs in the bin directory provide a convenient way to benchmark NNPACK at full speed. There is also benchmark.py script which tests typical layer configurations.

from nnpack.

zhaishengfu avatar zhaishengfu commented on May 20, 2024

Thank you very much. Now I know more about google native client and your NNPACK. You are really helpful and patient.

from nnpack.

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.