Giter VIP home page Giter VIP logo

gdsc-iiit-kalyani / raksha Goto Github PK

View Code? Open in Web Editor NEW

This project forked from salonisingh1601/raksha

0.0 0.0 3.0 7.94 MB

Estimates human pose using a webcam and mediapipe and analyzes the pose in order to give a score and performance based review. This framework aims at teaching self defense to users. Then features are extracted and the poses aligned in the temporal domain.

License: MIT License

Python 100.00%

raksha's People

Contributors

akshitadixit avatar aslmanasa avatar ayushi25jaiswal avatar isha307 avatar salonisingh1601 avatar

raksha's Issues

AttributeError: '_UserObject' object has no attribute 'add_slot'

The entire error message goes on like this:

(tf) plastic@lenovo-ideapad-slim5:~/dev/temp$ python app.py
Traceback (most recent call last):
  File "/home/plastic/dev/temp/app.py", line 13, in 
    from scoring import get_score
  File "/home/plastic/dev/temp/scoring.py", line 13, in 
    model = tf.saved_model.load('./model/')
  File "/home/plastic/miniconda3/envs/tf/lib/python3.9/site-packages/tensorflow/python/saved_model/load.py", line 864, in load
    result = load_internal(export_dir, tags, options)["root"]
  File "/home/plastic/miniconda3/envs/tf/lib/python3.9/site-packages/tensorflow/python/saved_model/load.py", line 902, in load_internal
    loader = loader_cls(object_graph_proto, saved_model_proto, export_dir,
  File "/home/plastic/miniconda3/envs/tf/lib/python3.9/site-packages/tensorflow/python/saved_model/load.py", line 162, in __init__
    self._load_all()
  File "/home/plastic/miniconda3/envs/tf/lib/python3.9/site-packages/tensorflow/python/saved_model/load.py", line 259, in _load_all
    self._load_nodes()
  File "/home/plastic/miniconda3/envs/tf/lib/python3.9/site-packages/tensorflow/python/saved_model/load.py", line 448, in _load_nodes
    slot_variable = optimizer_object.add_slot(
AttributeError: '_UserObject' object has no attribute 'add_slot'

cause due to the line model = tf.saved_model.load('./model/')

Due to recent upgrades in tensorflow and keras, changing the imports and this line of code to the following fixes the error:

import imageio
import keras
import os
import cv2
import numpy as np
import random
#from tensorflow_docs.vis import embed

MAX_SEQ_LENGTH = 100
NUM_FEATURES = 2048
IMG_SIZE = 224
model = keras.models.load_model('./model/')

Lines to be changed are importing keras directly, removing tensorflow imports, removing keras api imports and changing tf.keras.saved_model.load("path") to keras.models.load_model("path")

Login UI

Correct the UI of login page.

Update requirements.txt

The following packages are used in the repo but missing from the requirements.txt file, hence throwing errors with the setup.

  • flask_bootstrap
  • flask_sqlalchemy
  • flask_wtf
  • flask_ckeditor

Changes needed in the quiz page

image

  • submit button needs to be fixed
  • the input box allows user to change scores using arrow buttons, the type of input box used to display final score needs to be changed, could be simply kept as a label

Blog

Add one blog feature to the website.

Helpline Section

Add the helpline section where safety guidelines and helpline numbers is present.

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.