@@ -134,7 +134,7 @@ def detect_faces(self, limit=10):
134134 """
135135 features = [Feature (FeatureTypes .FACE_DETECTION , limit )]
136136 annotations = self ._detect_annotation (features )
137- return annotations .faces
137+ return annotations [ 0 ] .faces
138138
139139 def detect_labels (self , limit = 10 ):
140140 """Detect labels that describe objects in an image.
@@ -147,7 +147,7 @@ def detect_labels(self, limit=10):
147147 """
148148 features = [Feature (FeatureTypes .LABEL_DETECTION , limit )]
149149 annotations = self ._detect_annotation (features )
150- return annotations .labels
150+ return annotations [ 0 ] .labels
151151
152152 def detect_landmarks (self , limit = 10 ):
153153 """Detect landmarks in an image.
@@ -161,7 +161,7 @@ def detect_landmarks(self, limit=10):
161161 """
162162 features = [Feature (FeatureTypes .LANDMARK_DETECTION , limit )]
163163 annotations = self ._detect_annotation (features )
164- return annotations .landmarks
164+ return annotations [ 0 ] .landmarks
165165
166166 def detect_logos (self , limit = 10 ):
167167 """Detect logos in an image.
@@ -175,7 +175,7 @@ def detect_logos(self, limit=10):
175175 """
176176 features = [Feature (FeatureTypes .LOGO_DETECTION , limit )]
177177 annotations = self ._detect_annotation (features )
178- return annotations .logos
178+ return annotations [ 0 ] .logos
179179
180180 def detect_properties (self , limit = 10 ):
181181 """Detect the color properties of an image.
@@ -189,7 +189,7 @@ def detect_properties(self, limit=10):
189189 """
190190 features = [Feature (FeatureTypes .IMAGE_PROPERTIES , limit )]
191191 annotations = self ._detect_annotation (features )
192- return annotations .properties
192+ return annotations [ 0 ] .properties
193193
194194 def detect_safe_search (self , limit = 10 ):
195195 """Retreive safe search properties from an image.
@@ -203,7 +203,7 @@ def detect_safe_search(self, limit=10):
203203 """
204204 features = [Feature (FeatureTypes .SAFE_SEARCH_DETECTION , limit )]
205205 annotations = self ._detect_annotation (features )
206- return annotations .safe_searches
206+ return annotations [ 0 ] .safe_searches
207207
208208 def detect_text (self , limit = 10 ):
209209 """Detect text in an image.
@@ -217,4 +217,4 @@ def detect_text(self, limit=10):
217217 """
218218 features = [Feature (FeatureTypes .TEXT_DETECTION , limit )]
219219 annotations = self ._detect_annotation (features )
220- return annotations .texts
220+ return annotations [ 0 ] .texts
0 commit comments