Giter Site home page Giter Site logo

image_recog_project_geni's Introduction

Image_recog_project_geni

Install instructions

1.Clone the project from Github.

2.Use the rspec file "Image_recog_rspec.xml" to reserve the resource on GENI.

3.Once the slice is ready, find the routable ip by clicking node-1 and node-2, in my case 192.171.20.106 for node-1 and 192.171.20.107 for node-2.

4.Open /DLService/app.py and modify line 53 with your public ip of node-1, in my case:

app.run(host="192.171.20.106")

5.Open /FrontEnd/webpage.html and modify line 19 with your public ip of node-1, in my case:

url:"http://192.171.20.106:5000/predict"

6.Use scp to upload the /DLService folder to node-1 by following steps:

1.Download winscp from https://winscp.net/eng/index.php and open winscp.

2.Choose SCP under File protocol.

3.Find your login information in GENI, for example:[email protected].

4.Enter host name, for example: pcvm3-14.geni.case.edu.

5.Enter User name, for example:songxu.

6.Default port number is 22.

7.Go to Advanced -> SSH -> Authentication -> Private key file.

8.Choose your putty key file(ppk format) and click open -> ok.

9.Upload the /DLService folder to node-1.

7.SSH to node-1 (service node) and run the following commands(might take a few minutes):

    sudo apt update
    sudo apt-get install -y python3 python3-pip
    sudo apt install libjpeg-dev
    python3 -m pip install Pillow
    python3 -m pip install --no-cache-dir torch==1.7.0 torchvision==0.8.1 -f https://download.pytorch.org/whl/torch_stable.html
    python3 -m pip install flask
    python3 -m pip install -U flask-cors
    python3 app.py

8.Use scp to upload the /FrontEnd folder to node-2 as the steps shown above.

9.SSH to node-2 (front-end node) and configure static webpage by following steps:

1.Enter the following commands:
        sudo apt update 
        sudo apt install nginx        
        sudo nano /etc/nginx/nginx.conf
2.Under http part, find the line "default_type application/octet-stream;" and add the following code snippets below the previous line.
        server{
            listen 80;
            server_name <public ip of node-2>;
            root /users/<username>/FrontEnd;
            index webpage.html;
        }
3.Press Ctrl+O and Press enter.

4.Run the following commands:

    sudo nginx -t
    
    sudo systemctl restart nginx

10.Open http://(public ip of node-2) in your browser, in my case http://192.171.20.107

image_recog_project_geni's People

Contributors

yanpengzhao avatar songxu1216 avatar songxu2022 avatar ronan09 avatar r1cardoo avatar

Watchers

 avatar

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.