|
@@ -1,6 +1,6 @@
|
|
|
import sys
|
|
|
sys.path.append("wrappers")
|
|
|
-from modelverse import *
|
|
|
+from modelverse_coded import *
|
|
|
import os
|
|
|
import json
|
|
|
|
|
@@ -61,14 +61,12 @@ def json_service(port):
|
|
|
json_str = service_get(port)
|
|
|
json_data = json.loads(json_str)
|
|
|
print_out_json(json_data)
|
|
|
- print("Decoded %s" % json_str)
|
|
|
|
|
|
elif mode == "encode":
|
|
|
service_set(port, "OK")
|
|
|
json_data = fetch_data()
|
|
|
json_str = json.dumps(json_data)
|
|
|
service_set(port, json_str)
|
|
|
- print("Encoded %s" % json_str)
|
|
|
|
|
|
else:
|
|
|
raise Exception("No such mode: " + mode)
|