Giter Club home page Giter Club logo

containerized-app-exercise-team10's Introduction

Containerized App Exercise

Machine Learning Client

Containerized App Server CI

Handscribe

Handscribe is an online tool that uses the handprint package to extract text from pdf, png, jpg, and jpeg images.

Installation

1. Docker

This application uses Docker to containerize its parts. You must have Docker installed on your machine to run this.

2. Download files

Download the files from GitHub
Create a new directory on your machine where you want to run the app and extract the files there.

3. Run containers

Navigate to said directory and run the containers together using:

$ docker compose up

This should begin building the containers. Wait for this process to finish.

4. Start app

When the console shows the app running on localhost, click the link that appears to open the app, or navigate to https://localhost:3000.

app  |  Server running on port https://localhost:3000

5. App is ready for use

From here, just interact with the form on the homepage, and extract your text from your images!

Run Unit Tests

1. Activate virtual environment

If you are currently running the docker containers from your terminal, stop them with CTRL+C

Set up and activate a virtual environment in the root directory with:

python3 -m venv env

source env/bin/activate

2. Install testing dependencies

Once you have activated your virtual environment, install the requisite testing packages with:

pip install -r requirements.txt

3. Navigate to testing directory

If you want to test the machine learning client code, execute:

cd machine-learning-client

Or, if you want to test the web app code, execute:

cd web-app

3. Run tests

To run tests with coverage reports, execute in your terminal:

coverage run -m pytest

coverage report -m

Sample coverage report output:

Name                Stmts   Miss  Cover
---------------------------------------
app.py                 63     20    68%
tests/__init__.py       0      0   100%
tests/ml_test.py       72      0   100%
---------------------------------------
TOTAL                 135     20    85%

Machine learning client code coverage: 57%

Web app code coverage: 80%

Authors

Sarah Al-Towaity
Rachel Andoh
Brian Lee
Danilo Montes
Bhavig Pointi
Misha Seo

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.