示例#1
0
async def count_images(table_name: str = None):
    # Returns the total number of questions in the system
    try:
        num = do_count(table_name, MILVUS_CLI)
        LOGGER.info("Successfully count the number of questions!")
        return num
    except Exception as e:
        LOGGER.error(e)
        return {'status': False, 'msg': e}, 400
示例#2
0
async def count_video(table_name: str = None):
    # Returns the total number of images in the system
    try:
        num = do_count(table_name, MILVUS_CLI, MYSQL_CLI)
        LOGGER.info("Successfully count the number:{} of images!".format(num))
        return num
    except Exception as e:
        LOGGER.error(e)
        return {'status': False, 'msg': e}, 400