Ajay P. answered 07/14/22
helping to turn ideas to startups
you can use pyscript like Javascript or else you can use any python framework like dajngo , flask framework.
if you find any difficulty i like to help you
Sriram S.
asked 03/03/19Friends, I have a python program which runs html program to create box as follows which runs on wamp server:
**box.py:**
#!C:/python27/python.exe -u
print "Content-type: text/html\n"
print('''\
<html>
<head>
<title>FACE</title>
<style>
div {
width: 500px;
height: 450px;
border: 15px solid blue;
padding: 25px;
margin: 70px;
}
h1{
color:red;
font-size: 1.875em;
font-family: "Times New Roman";
}
</style>
</head>
<body bgcolor="lightblue">
<center><h1>PLEASE SHOW US YOUR FACE</h1></center>
<center><div>
how are you?
</div></center>
</body>
</html>
''')
This creates box when running using localhost/cgi-bin/box.py.
But I also have "just cam.py" program which reads webcam which code is as follows,
**just cam.py:**
import cv2
import numpy as np
cap = cv2.VideoCapture(0)
while True:
_, frame= cap.read()
gray = cv2.cvtColor(frame , cv2.COLOR_BGR2GRAY)
cv2.imshow('Face', frame)
k=cv2.waitKey(1)
if k == 27:
break
cv2.destroyAllWindows()
cap.release()
How to run the above mentioned "just cam.py" inside box created in "box.py"? Please help me friends
Ajay P. answered 07/14/22
helping to turn ideas to startups
you can use pyscript like Javascript or else you can use any python framework like dajngo , flask framework.
if you find any difficulty i like to help you
Get a free answer to a quick problem.
Most questions answered within 4 hours.
Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.