mirror of
https://github.com/wassname/IndicoIo-python.git
synced 2026-07-20 12:10:41 +08:00
ADD: Tests for accepting filename and b64 inputs
This commit is contained in:
@@ -24,6 +24,7 @@ def facial_features(image, cloud=None, batch=False, api_key=None, **kwargs):
|
||||
:type image: list of lists
|
||||
:rtype: List containing feature responses
|
||||
"""
|
||||
image = image_preprocess(image, batch=batch)
|
||||
return api_handler(image, cloud=cloud, api="facialfeatures", batch=batch, api_key=api_key, **kwargs)
|
||||
|
||||
def image_features(image, cloud=None, batch=False, api_key=None, **kwargs):
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import requests
|
||||
|
||||
from indicoio.utils import api_handler
|
||||
from indicoio.utils import api_handler, image_preprocess
|
||||
import indicoio.config as config
|
||||
|
||||
def fer(image, cloud=None, batch=False, api_key=None, **kwargs):
|
||||
@@ -26,5 +26,5 @@ def fer(image, cloud=None, batch=False, api_key=None, **kwargs):
|
||||
:type image: list of lists
|
||||
:rtype: Dictionary containing emotion probability pairs
|
||||
"""
|
||||
|
||||
image = image_preprocess(image, batch=batch)
|
||||
return api_handler(image, cloud=cloud, api="fer", batch=batch, api_key=api_key, **kwargs)
|
||||
|
||||
Reference in New Issue
Block a user