Skip to content

Commit 46e6942

Browse files
committed
Correct references.
1 parent 631ece9 commit 46e6942

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

vision/google/cloud/vision/annotations.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ def _make_entity_from_pb(annotations):
131131
132132
:type annotations:
133133
:class:`~google.cloud.grpc.vision.v1.image_annotator_pb2.EntityAnnotation`
134-
:param annotations: gRPC instance of ``EntityAnnotation``.
134+
:param annotations: protobuf instance of ``EntityAnnotation``.
135135
136136
:rtype: list
137137
:returns: List of ``EntityAnnotation``.

vision/google/cloud/vision/geometry.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -102,17 +102,18 @@ def from_api_repr(cls, location_info):
102102
return cls(latitude, longitude)
103103

104104
@classmethod
105-
def from_pb(cls, response):
105+
def from_pb(cls, location_info):
106106
"""Factory: construct location information from Vision gRPC response.
107107
108-
:type response: :class:`~google.cloud.vision.v1.LocationInfo`
109-
:param response: gRPC response of ``LocationInfo``.
108+
:type location_info: :class:`~google.cloud.vision.v1.LocationInfo`
109+
:param location_info: gRPC response of ``LocationInfo``.
110110
111111
:rtype: :class:`~google.cloud.vision.geometry.LocationInformation`
112112
:returns: ``LocationInformation`` with populated latitude and
113113
longitude.
114114
"""
115-
return cls(response.lat_lng.latitude, response.lat_lng.longitude)
115+
return cls(location_info.lat_lng.latitude,
116+
location_info.lat_lng.longitude)
116117

117118
@property
118119
def latitude(self):

0 commit comments

Comments
 (0)