Website in-development for a Quantum Computer
See demo here
git clone thisrepo
virtualenv TestQuantumDjangoEnv -p python3.9
source TestQuantumDjangoEnv/bin/activate
cd TestWebGui
pip3 install -r requirements.txt
- Install redis and mongodb dockers
a. docker run -p 6379:6379 -d redis:5
b. docker run -p 27017:27017 --name mymongo -d mongo
cd myworld
python manage.py collectstatic
- Run seperate processes starting from TestWebGui/myworld:
Terminal 1
a. source TestQuantumDjangoEnv/bin/activate
b. python3 manage.py shell
c. import os
d. os.system("python3 HardwareSubscriber.py")
Terminal 2
a. source TestQuantumDjangoEnv/bin/activate
b. python3 manage.py runserver
Terminal 3
a. source TestQuantumDjangoEnv/bin/activate
b. python3 manage.py shell
c. import os
d. os.system("python3 dummy\_dds\_zmq.py")
Terminal 4
a. source TestQuantumDjangoEnv/bin/activate
b. cd ../Dummies/
c. python3 HardwareDummy.py
Note: In file TestQuantumDjangoEnv/lib/python3.9/site-packages/redis/client.py
, change the function def parse_zadd(response, **options):
to the following:
def parse_zadd(response, **options):
if response is None:
return None
if options.get("as_score"):
try:
return float(response)
except TypeError:
return response
try:
return int(response)
except TypeError:
return response