You are on page 1of 6

Go, change the world

RV College of
Engineering

CFDI Assignment
from keras.models import load_model
from keras.preprocessing import image
from keras.applications.resnet50 import preprocess_input

18CS7G2
import numpy as np

model = load_model('model_resnet.h5')
img = image.load_img('Datasets/val/tumour/Y258.jpg',target_size=(224,224))
#img = image.load_img('Datasets/val/NORMAL/no19.jpg',target_size=(224,224))
x = image.img_to_array(img)
x = np.expand_dims(x,axis=0)
img_data = preprocess_input(x)
classes = model.predict(img_data)

Face Recgontion with CUDA and OpenCV


print("\n#########OUTPUT#########\n")
print("\nClass Array: ",classes)
x = classes[0]
if(x[0]>x[1]):
print("\nThe person is normal\n")
else:

Viraj Aurora 1RV18CS189


print("\nThe person has pneumonia\n")

Rituraj Kaundilya 1RV18IM043


RV College of
Engineering Introduction Go, change the world

Evolution has led to us having great power in technology.


People can breach access to devices and gadgets with
computer hacking.
This needs to be stopped and one of the few ways to secure
ourselves is by using something unique to us. Our Faces.
RV College of
Engineering Working Go, change the world

The Face Recognition using OpenCV and CUDA.

1) Recognizes Faces Accurately.


2) Demonstrates also how using CUDA will benefit us rather than
using our CPU for computing.
RV College of
Engineering CUDA Go, change the world

• CUDA is a general purpose programming platform than


allows graphical parallel computation.
• It using the power of the GPU for image processing
operations.
• It is also aided by an extension called cudNN which is an
additional libraries that have optimised implementations of
operations like pooling, convolutions, and normalization.
RV College of
Engineering OpenCV Go, change the world

• OpenCV (Open Source Computer Vision Library) is a library of


programming functions mainly aimed at real-time computer
vision.
• OpenCV is the huge open-source library for the computer
vision, machine learning, and image processing and now it
plays a major role in real-time operation which is very important
in today’s systems.
RV College of
Engineering Recognition Model Go, change the world

• Here we use a model, that was previously trained by a neural


network and exported.
• This model can be used as a separate downloadable model.

You might also like