- Name: Ravikant Singh
- Organisation: OpenMined
- Project: Implement Fan-Vercauteren Homomorphic Encryption Scheme in PySyft
- Proposal: https://docs.google.com/document/d/14JrXJ9_ddB8Qm-RbnOnA2NL_GxXxKXei56dSJrVumR0/edit?usp=sharing
- Mentor: Ayoub Benaissa
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# empty |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
Usage: | |
Make sure that redis is running on localhost (or adjust the url) | |
Install uvicorn or some other asgi server https://asgi.readthedocs.io/en/latest/implementations.html | |
pip install -u uvicorn | |
Install dependencies |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import multiprocessing | |
from multiprocessing.dummy import Pool as ThreadPool | |
import numpy as np | |
def my_multipro(items, func, max_cpus=12): | |
"""Do an embarrassingly parallel task using multiprocessing. | |
Use this for CPU bound tasks. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cv2 | |
import time | |
import math | |
import numpy as np | |
capture = cv2.VideoCapture(0) | |
print capture.get(cv2.CAP_PROP_FPS) | |
t = 100 | |
w = 640.0 |