Skip to content

Commit 1c69018

Browse files
committed
v1 feature parity
1 parent db7bfde commit 1c69018

File tree

2 files changed

+17
-0
lines changed

2 files changed

+17
-0
lines changed

api.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
from program import ProgramEngine, Program
1616
from config import Config
1717
from coderbotTestUnit import run_test as runCoderbotTestUnit
18+
from cnn_manager import CNNManager
1819
import pigpio
1920
from musicPackages import MusicPackageManager
2021

@@ -291,3 +292,9 @@ def testCoderbot(data):
291292
# taking first JSON key value (varargin)
292293
tests_state = runCoderbotTestUnit(data[list(data.keys())[0]])
293294
return tests_state
295+
296+
def list_cnn_models():
297+
cnn = CNNManager.get_instance()
298+
logging.info("cnn_models_list")
299+
return json.dumps(cnn.get_models())
300+

v2.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -302,3 +302,13 @@ paths:
302302
responses:
303303
200:
304304
description: Sent command to the bot GPIO.
305+
/listCNNModels:
306+
get:
307+
operationId: "api.list_cnn_models"
308+
summary: "list of CNN Models"
309+
tags:
310+
- CNN Models
311+
responses:
312+
200:
313+
description: "CNN Models as JSON Object"
314+

0 commit comments

Comments
 (0)