Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterTextRecognitionAsyncServiceServer(s grpc.ServiceRegistrar, srv TextRecognitionAsyncServiceServer)
- func RegisterTextRecognitionServiceServer(s grpc.ServiceRegistrar, srv TextRecognitionServiceServer)
- type Angle
- type Block
- func (*Block) Descriptor() ([]byte, []int)deprecated
- func (x *Block) GetBoundingBox() *Polygon
- func (x *Block) GetLanguages() []*Block_DetectedLanguage
- func (x *Block) GetLines() []*Line
- func (x *Block) GetTextSegments() []*TextSegments
- func (*Block) ProtoMessage()
- func (x *Block) ProtoReflect() protoreflect.Message
- func (x *Block) Reset()
- func (m *Block) SetBoundingBox(v *Polygon)
- func (m *Block) SetLanguages(v []*Block_DetectedLanguage)
- func (m *Block) SetLines(v []*Line)
- func (m *Block) SetTextSegments(v []*TextSegments)
- func (x *Block) String() string
- type Block_DetectedLanguage
- func (*Block_DetectedLanguage) Descriptor() ([]byte, []int)deprecated
- func (x *Block_DetectedLanguage) GetLanguageCode() string
- func (*Block_DetectedLanguage) ProtoMessage()
- func (x *Block_DetectedLanguage) ProtoReflect() protoreflect.Message
- func (x *Block_DetectedLanguage) Reset()
- func (m *Block_DetectedLanguage) SetLanguageCode(v string)
- func (x *Block_DetectedLanguage) String() string
- type Entity
- func (*Entity) Descriptor() ([]byte, []int)deprecated
- func (x *Entity) GetName() string
- func (x *Entity) GetText() string
- func (*Entity) ProtoMessage()
- func (x *Entity) ProtoReflect() protoreflect.Message
- func (x *Entity) Reset()
- func (m *Entity) SetName(v string)
- func (m *Entity) SetText(v string)
- func (x *Entity) String() string
- type GetRecognitionRequest
- func (*GetRecognitionRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetRecognitionRequest) GetOperationId() string
- func (*GetRecognitionRequest) ProtoMessage()
- func (x *GetRecognitionRequest) ProtoReflect() protoreflect.Message
- func (x *GetRecognitionRequest) Reset()
- func (m *GetRecognitionRequest) SetOperationId(v string)
- func (x *GetRecognitionRequest) String() string
- type Line
- func (*Line) Descriptor() ([]byte, []int)deprecated
- func (x *Line) GetBoundingBox() *Polygon
- func (x *Line) GetOrientation() Angle
- func (x *Line) GetText() string
- func (x *Line) GetTextSegments() []*TextSegments
- func (x *Line) GetWords() []*Word
- func (*Line) ProtoMessage()
- func (x *Line) ProtoReflect() protoreflect.Message
- func (x *Line) Reset()
- func (m *Line) SetBoundingBox(v *Polygon)
- func (m *Line) SetOrientation(v Angle)
- func (m *Line) SetText(v string)
- func (m *Line) SetTextSegments(v []*TextSegments)
- func (m *Line) SetWords(v []*Word)
- func (x *Line) String() string
- type Polygon
- type RecognizeTextRequest
- func (*RecognizeTextRequest) Descriptor() ([]byte, []int)deprecated
- func (x *RecognizeTextRequest) GetContent() []byte
- func (x *RecognizeTextRequest) GetLanguageCodes() []string
- func (x *RecognizeTextRequest) GetMimeType() string
- func (x *RecognizeTextRequest) GetModel() string
- func (m *RecognizeTextRequest) GetSource() isRecognizeTextRequest_Source
- func (*RecognizeTextRequest) ProtoMessage()
- func (x *RecognizeTextRequest) ProtoReflect() protoreflect.Message
- func (x *RecognizeTextRequest) Reset()
- func (m *RecognizeTextRequest) SetContent(v []byte)
- func (m *RecognizeTextRequest) SetLanguageCodes(v []string)
- func (m *RecognizeTextRequest) SetMimeType(v string)
- func (m *RecognizeTextRequest) SetModel(v string)
- func (m *RecognizeTextRequest) SetSource(v RecognizeTextRequest_Source)
- func (x *RecognizeTextRequest) String() string
- type RecognizeTextRequest_Content
- type RecognizeTextRequest_Source
- type RecognizeTextResponse
- func (*RecognizeTextResponse) Descriptor() ([]byte, []int)deprecated
- func (x *RecognizeTextResponse) GetPage() int64
- func (x *RecognizeTextResponse) GetTextAnnotation() *TextAnnotation
- func (*RecognizeTextResponse) ProtoMessage()
- func (x *RecognizeTextResponse) ProtoReflect() protoreflect.Message
- func (x *RecognizeTextResponse) Reset()
- func (m *RecognizeTextResponse) SetPage(v int64)
- func (m *RecognizeTextResponse) SetTextAnnotation(v *TextAnnotation)
- func (x *RecognizeTextResponse) String() string
- type Table
- func (*Table) Descriptor() ([]byte, []int)deprecated
- func (x *Table) GetBoundingBox() *Polygon
- func (x *Table) GetCells() []*TableCell
- func (x *Table) GetColumnCount() int64
- func (x *Table) GetRowCount() int64
- func (*Table) ProtoMessage()
- func (x *Table) ProtoReflect() protoreflect.Message
- func (x *Table) Reset()
- func (m *Table) SetBoundingBox(v *Polygon)
- func (m *Table) SetCells(v []*TableCell)
- func (m *Table) SetColumnCount(v int64)
- func (m *Table) SetRowCount(v int64)
- func (x *Table) String() string
- type TableCell
- func (*TableCell) Descriptor() ([]byte, []int)deprecated
- func (x *TableCell) GetBoundingBox() *Polygon
- func (x *TableCell) GetColumnIndex() int64
- func (x *TableCell) GetColumnSpan() int64
- func (x *TableCell) GetRowIndex() int64
- func (x *TableCell) GetRowSpan() int64
- func (x *TableCell) GetText() string
- func (x *TableCell) GetTextSegments() []*TextSegments
- func (*TableCell) ProtoMessage()
- func (x *TableCell) ProtoReflect() protoreflect.Message
- func (x *TableCell) Reset()
- func (m *TableCell) SetBoundingBox(v *Polygon)
- func (m *TableCell) SetColumnIndex(v int64)
- func (m *TableCell) SetColumnSpan(v int64)
- func (m *TableCell) SetRowIndex(v int64)
- func (m *TableCell) SetRowSpan(v int64)
- func (m *TableCell) SetText(v string)
- func (m *TableCell) SetTextSegments(v []*TextSegments)
- func (x *TableCell) String() string
- type TextAnnotation
- func (*TextAnnotation) Descriptor() ([]byte, []int)deprecated
- func (x *TextAnnotation) GetBlocks() []*Block
- func (x *TextAnnotation) GetEntities() []*Entity
- func (x *TextAnnotation) GetFullText() string
- func (x *TextAnnotation) GetHeight() int64
- func (x *TextAnnotation) GetRotate() Angle
- func (x *TextAnnotation) GetTables() []*Table
- func (x *TextAnnotation) GetWidth() int64
- func (*TextAnnotation) ProtoMessage()
- func (x *TextAnnotation) ProtoReflect() protoreflect.Message
- func (x *TextAnnotation) Reset()
- func (m *TextAnnotation) SetBlocks(v []*Block)
- func (m *TextAnnotation) SetEntities(v []*Entity)
- func (m *TextAnnotation) SetFullText(v string)
- func (m *TextAnnotation) SetHeight(v int64)
- func (m *TextAnnotation) SetRotate(v Angle)
- func (m *TextAnnotation) SetTables(v []*Table)
- func (m *TextAnnotation) SetWidth(v int64)
- func (x *TextAnnotation) String() string
- type TextRecognitionAsyncServiceClient
- type TextRecognitionAsyncServiceServer
- type TextRecognitionAsyncService_GetRecognitionClient
- type TextRecognitionAsyncService_GetRecognitionServer
- type TextRecognitionServiceClient
- type TextRecognitionServiceServer
- type TextRecognitionService_RecognizeClient
- type TextRecognitionService_RecognizeServer
- type TextSegments
- func (*TextSegments) Descriptor() ([]byte, []int)deprecated
- func (x *TextSegments) GetLength() int64
- func (x *TextSegments) GetStartIndex() int64
- func (*TextSegments) ProtoMessage()
- func (x *TextSegments) ProtoReflect() protoreflect.Message
- func (x *TextSegments) Reset()
- func (m *TextSegments) SetLength(v int64)
- func (m *TextSegments) SetStartIndex(v int64)
- func (x *TextSegments) String() string
- type UnimplementedTextRecognitionAsyncServiceServer
- type UnimplementedTextRecognitionServiceServer
- type UnsafeTextRecognitionAsyncServiceServer
- type UnsafeTextRecognitionServiceServer
- type Vertex
- func (*Vertex) Descriptor() ([]byte, []int)deprecated
- func (x *Vertex) GetX() int64
- func (x *Vertex) GetY() int64
- func (*Vertex) ProtoMessage()
- func (x *Vertex) ProtoReflect() protoreflect.Message
- func (x *Vertex) Reset()
- func (m *Vertex) SetX(v int64)
- func (m *Vertex) SetY(v int64)
- func (x *Vertex) String() string
- type Word
- func (*Word) Descriptor() ([]byte, []int)deprecated
- func (x *Word) GetBoundingBox() *Polygon
- func (x *Word) GetEntityIndex() int64
- func (x *Word) GetText() string
- func (x *Word) GetTextSegments() []*TextSegments
- func (*Word) ProtoMessage()
- func (x *Word) ProtoReflect() protoreflect.Message
- func (x *Word) Reset()
- func (m *Word) SetBoundingBox(v *Polygon)
- func (m *Word) SetEntityIndex(v int64)
- func (m *Word) SetText(v string)
- func (m *Word) SetTextSegments(v []*TextSegments)
- func (x *Word) String() string
Constants ¶
const ( TextRecognitionAsyncService_Recognize_FullMethodName = "/yandex.cloud.ai.ocr.v1.TextRecognitionAsyncService/Recognize" TextRecognitionAsyncService_GetRecognition_FullMethodName = "/yandex.cloud.ai.ocr.v1.TextRecognitionAsyncService/GetRecognition" )
const (
TextRecognitionService_Recognize_FullMethodName = "/yandex.cloud.ai.ocr.v1.TextRecognitionService/Recognize"
)
Variables ¶
var ( Angle_name = map[int32]string{ 0: "ANGLE_UNSPECIFIED", 1: "ANGLE_0", 2: "ANGLE_90", 3: "ANGLE_180", 4: "ANGLE_270", } Angle_value = map[string]int32{ "ANGLE_UNSPECIFIED": 0, "ANGLE_0": 1, "ANGLE_90": 2, "ANGLE_180": 3, "ANGLE_270": 4, } )
Enum value maps for Angle.
var File_yandex_cloud_ai_ocr_v1_ocr_proto protoreflect.FileDescriptor
var File_yandex_cloud_ai_ocr_v1_ocr_service_proto protoreflect.FileDescriptor
var TextRecognitionAsyncService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "yandex.cloud.ai.ocr.v1.TextRecognitionAsyncService", HandlerType: (*TextRecognitionAsyncServiceServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "Recognize", Handler: _TextRecognitionAsyncService_Recognize_Handler, }, }, Streams: []grpc.StreamDesc{ { StreamName: "GetRecognition", Handler: _TextRecognitionAsyncService_GetRecognition_Handler, ServerStreams: true, }, }, Metadata: "yandex/cloud/ai/ocr/v1/ocr_service.proto", }
TextRecognitionAsyncService_ServiceDesc is the grpc.ServiceDesc for TextRecognitionAsyncService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
var TextRecognitionService_ServiceDesc = grpc.ServiceDesc{ ServiceName: "yandex.cloud.ai.ocr.v1.TextRecognitionService", HandlerType: (*TextRecognitionServiceServer)(nil), Methods: []grpc.MethodDesc{}, Streams: []grpc.StreamDesc{ { StreamName: "Recognize", Handler: _TextRecognitionService_Recognize_Handler, ServerStreams: true, }, }, Metadata: "yandex/cloud/ai/ocr/v1/ocr_service.proto", }
TextRecognitionService_ServiceDesc is the grpc.ServiceDesc for TextRecognitionService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterTextRecognitionAsyncServiceServer ¶
func RegisterTextRecognitionAsyncServiceServer(s grpc.ServiceRegistrar, srv TextRecognitionAsyncServiceServer)
func RegisterTextRecognitionServiceServer ¶
func RegisterTextRecognitionServiceServer(s grpc.ServiceRegistrar, srv TextRecognitionServiceServer)
Types ¶
type Angle ¶
type Angle int32
func (Angle) Descriptor ¶
func (Angle) Descriptor() protoreflect.EnumDescriptor
func (Angle) EnumDescriptor
deprecated
func (Angle) Number ¶
func (x Angle) Number() protoreflect.EnumNumber
func (Angle) Type ¶
func (Angle) Type() protoreflect.EnumType
type Block ¶
type Block struct { // Area on the page where the text block is located. BoundingBox *Polygon `protobuf:"bytes,1,opt,name=bounding_box,json=boundingBox,proto3" json:"bounding_box,omitempty"` // Recognized lines in this block. Lines []*Line `protobuf:"bytes,2,rep,name=lines,proto3" json:"lines,omitempty"` // A list of detected languages Languages []*Block_DetectedLanguage `protobuf:"bytes,3,rep,name=languages,proto3" json:"languages,omitempty"` // Block position from full_text string. TextSegments []*TextSegments `protobuf:"bytes,4,rep,name=text_segments,json=textSegments,proto3" json:"text_segments,omitempty"` // contains filtered or unexported fields }
func (*Block) Descriptor
deprecated
func (*Block) GetBoundingBox ¶
func (*Block) GetLanguages ¶
func (x *Block) GetLanguages() []*Block_DetectedLanguage
func (*Block) GetTextSegments ¶
func (x *Block) GetTextSegments() []*TextSegments
func (*Block) ProtoMessage ¶
func (*Block) ProtoMessage()
func (*Block) ProtoReflect ¶
func (x *Block) ProtoReflect() protoreflect.Message
func (*Block) SetBoundingBox ¶
func (*Block) SetLanguages ¶
func (m *Block) SetLanguages(v []*Block_DetectedLanguage)
func (*Block) SetTextSegments ¶
func (m *Block) SetTextSegments(v []*TextSegments)
type Block_DetectedLanguage ¶
type Block_DetectedLanguage struct { // Detected language code. LanguageCode string `protobuf:"bytes,1,opt,name=language_code,json=languageCode,proto3" json:"language_code,omitempty"` // contains filtered or unexported fields }
func (*Block_DetectedLanguage) Descriptor
deprecated
func (*Block_DetectedLanguage) Descriptor() ([]byte, []int)
Deprecated: Use Block_DetectedLanguage.ProtoReflect.Descriptor instead.
func (*Block_DetectedLanguage) GetLanguageCode ¶
func (x *Block_DetectedLanguage) GetLanguageCode() string
func (*Block_DetectedLanguage) ProtoMessage ¶
func (*Block_DetectedLanguage) ProtoMessage()
func (*Block_DetectedLanguage) ProtoReflect ¶
func (x *Block_DetectedLanguage) ProtoReflect() protoreflect.Message
func (*Block_DetectedLanguage) Reset ¶
func (x *Block_DetectedLanguage) Reset()
func (*Block_DetectedLanguage) SetLanguageCode ¶
func (m *Block_DetectedLanguage) SetLanguageCode(v string)
func (*Block_DetectedLanguage) String ¶
func (x *Block_DetectedLanguage) String() string
type Entity ¶
type Entity struct { // Entity name. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Recognized entity text. Text string `protobuf:"bytes,2,opt,name=text,proto3" json:"text,omitempty"` // contains filtered or unexported fields }
func (*Entity) Descriptor
deprecated
func (*Entity) ProtoMessage ¶
func (*Entity) ProtoMessage()
func (*Entity) ProtoReflect ¶
func (x *Entity) ProtoReflect() protoreflect.Message
type GetRecognitionRequest ¶
type GetRecognitionRequest struct { // Operation ID of async recognition request. OperationId string `protobuf:"bytes,1,opt,name=operation_id,json=operationId,proto3" json:"operation_id,omitempty"` // contains filtered or unexported fields }
func (*GetRecognitionRequest) Descriptor
deprecated
func (*GetRecognitionRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetRecognitionRequest.ProtoReflect.Descriptor instead.
func (*GetRecognitionRequest) GetOperationId ¶
func (x *GetRecognitionRequest) GetOperationId() string
func (*GetRecognitionRequest) ProtoMessage ¶
func (*GetRecognitionRequest) ProtoMessage()
func (*GetRecognitionRequest) ProtoReflect ¶
func (x *GetRecognitionRequest) ProtoReflect() protoreflect.Message
func (*GetRecognitionRequest) Reset ¶
func (x *GetRecognitionRequest) Reset()
func (*GetRecognitionRequest) SetOperationId ¶
func (m *GetRecognitionRequest) SetOperationId(v string)
func (*GetRecognitionRequest) String ¶
func (x *GetRecognitionRequest) String() string
type Line ¶
type Line struct { // Area on the page where the line is located. BoundingBox *Polygon `protobuf:"bytes,1,opt,name=bounding_box,json=boundingBox,proto3" json:"bounding_box,omitempty"` // Recognized text. Text string `protobuf:"bytes,2,opt,name=text,proto3" json:"text,omitempty"` // Recognized words. Words []*Word `protobuf:"bytes,3,rep,name=words,proto3" json:"words,omitempty"` // Line position from full_text string. TextSegments []*TextSegments `protobuf:"bytes,4,rep,name=text_segments,json=textSegments,proto3" json:"text_segments,omitempty"` // Angle of rotate line Orientation Angle `protobuf:"varint,5,opt,name=orientation,proto3,enum=yandex.cloud.ai.ocr.v1.Angle" json:"orientation,omitempty"` // contains filtered or unexported fields }
func (*Line) Descriptor
deprecated
func (*Line) GetBoundingBox ¶
func (*Line) GetOrientation ¶
func (*Line) GetTextSegments ¶
func (x *Line) GetTextSegments() []*TextSegments
func (*Line) ProtoMessage ¶
func (*Line) ProtoMessage()
func (*Line) ProtoReflect ¶
func (x *Line) ProtoReflect() protoreflect.Message
func (*Line) SetBoundingBox ¶
func (*Line) SetOrientation ¶
func (*Line) SetTextSegments ¶
func (m *Line) SetTextSegments(v []*TextSegments)
type Polygon ¶
type Polygon struct { // The bounding polygon vertices. Vertices []*Vertex `protobuf:"bytes,1,rep,name=vertices,proto3" json:"vertices,omitempty"` // contains filtered or unexported fields }
func (*Polygon) Descriptor
deprecated
func (*Polygon) GetVertices ¶
func (*Polygon) ProtoMessage ¶
func (*Polygon) ProtoMessage()
func (*Polygon) ProtoReflect ¶
func (x *Polygon) ProtoReflect() protoreflect.Message
func (*Polygon) SetVertices ¶
type RecognizeTextRequest ¶
type RecognizeTextRequest struct { // Types that are assignable to Source: // // *RecognizeTextRequest_Content Source isRecognizeTextRequest_Source `protobuf_oneof:"source"` // Specifications of the ([MIME type](https://en.wikipedia.org/wiki/Media_type)). Each specification contains the file to analyze and features to use for analysis. Restrictions: // * Supported file formats: `JPEG`, `PNG`, `PDF`. // * Maximum file size: 20 MB. // * Image size should not exceed 20M pixels (length x width). // * The number of pages in a PDF file should not exceed 200 (each page counts as 1 request). MimeType string `protobuf:"bytes,2,opt,name=mime_type,json=mimeType,proto3" json:"mime_type,omitempty"` // List of the languages to recognize text. // Specified in [ISO 639-1](https://en.wikipedia.org/wiki/ISO_639-1) format (for example, `ru`). LanguageCodes []string `protobuf:"bytes,3,rep,name=language_codes,json=languageCodes,proto3" json:"language_codes,omitempty"` // Model to use for text detection. Model string `protobuf:"bytes,4,opt,name=model,proto3" json:"model,omitempty"` // contains filtered or unexported fields }
func (*RecognizeTextRequest) Descriptor
deprecated
func (*RecognizeTextRequest) Descriptor() ([]byte, []int)
Deprecated: Use RecognizeTextRequest.ProtoReflect.Descriptor instead.
func (*RecognizeTextRequest) GetContent ¶
func (x *RecognizeTextRequest) GetContent() []byte
func (*RecognizeTextRequest) GetLanguageCodes ¶
func (x *RecognizeTextRequest) GetLanguageCodes() []string
func (*RecognizeTextRequest) GetMimeType ¶
func (x *RecognizeTextRequest) GetMimeType() string
func (*RecognizeTextRequest) GetModel ¶
func (x *RecognizeTextRequest) GetModel() string
func (*RecognizeTextRequest) GetSource ¶
func (m *RecognizeTextRequest) GetSource() isRecognizeTextRequest_Source
func (*RecognizeTextRequest) ProtoMessage ¶
func (*RecognizeTextRequest) ProtoMessage()
func (*RecognizeTextRequest) ProtoReflect ¶
func (x *RecognizeTextRequest) ProtoReflect() protoreflect.Message
func (*RecognizeTextRequest) Reset ¶
func (x *RecognizeTextRequest) Reset()
func (*RecognizeTextRequest) SetContent ¶
func (m *RecognizeTextRequest) SetContent(v []byte)
func (*RecognizeTextRequest) SetLanguageCodes ¶
func (m *RecognizeTextRequest) SetLanguageCodes(v []string)
func (*RecognizeTextRequest) SetMimeType ¶
func (m *RecognizeTextRequest) SetMimeType(v string)
func (*RecognizeTextRequest) SetModel ¶
func (m *RecognizeTextRequest) SetModel(v string)
func (*RecognizeTextRequest) SetSource ¶
func (m *RecognizeTextRequest) SetSource(v RecognizeTextRequest_Source)
func (*RecognizeTextRequest) String ¶
func (x *RecognizeTextRequest) String() string
type RecognizeTextRequest_Content ¶
type RecognizeTextRequest_Content struct { // Bytes with data Content []byte `protobuf:"bytes,1,opt,name=content,proto3,oneof"` }
type RecognizeTextRequest_Source ¶
type RecognizeTextRequest_Source = isRecognizeTextRequest_Source
type RecognizeTextResponse ¶
type RecognizeTextResponse struct { // Recognized text blocks in this page or text from entities. TextAnnotation *TextAnnotation `protobuf:"bytes,1,opt,name=text_annotation,json=textAnnotation,proto3" json:"text_annotation,omitempty"` // Page number in PDF file. Page int64 `protobuf:"varint,2,opt,name=page,proto3" json:"page,omitempty"` // contains filtered or unexported fields }
func (*RecognizeTextResponse) Descriptor
deprecated
func (*RecognizeTextResponse) Descriptor() ([]byte, []int)
Deprecated: Use RecognizeTextResponse.ProtoReflect.Descriptor instead.
func (*RecognizeTextResponse) GetPage ¶
func (x *RecognizeTextResponse) GetPage() int64
func (*RecognizeTextResponse) GetTextAnnotation ¶
func (x *RecognizeTextResponse) GetTextAnnotation() *TextAnnotation
func (*RecognizeTextResponse) ProtoMessage ¶
func (*RecognizeTextResponse) ProtoMessage()
func (*RecognizeTextResponse) ProtoReflect ¶
func (x *RecognizeTextResponse) ProtoReflect() protoreflect.Message
func (*RecognizeTextResponse) Reset ¶
func (x *RecognizeTextResponse) Reset()
func (*RecognizeTextResponse) SetPage ¶
func (m *RecognizeTextResponse) SetPage(v int64)
func (*RecognizeTextResponse) SetTextAnnotation ¶
func (m *RecognizeTextResponse) SetTextAnnotation(v *TextAnnotation)
func (*RecognizeTextResponse) String ¶
func (x *RecognizeTextResponse) String() string
type Table ¶
type Table struct { // Area on the page where the table is located. BoundingBox *Polygon `protobuf:"bytes,1,opt,name=bounding_box,json=boundingBox,proto3" json:"bounding_box,omitempty"` // Number of rows in table. RowCount int64 `protobuf:"varint,2,opt,name=row_count,json=rowCount,proto3" json:"row_count,omitempty"` // Number of columns in table. ColumnCount int64 `protobuf:"varint,3,opt,name=column_count,json=columnCount,proto3" json:"column_count,omitempty"` // Table cells. Cells []*TableCell `protobuf:"bytes,4,rep,name=cells,proto3" json:"cells,omitempty"` // contains filtered or unexported fields }
func (*Table) Descriptor
deprecated
func (*Table) GetBoundingBox ¶
func (*Table) GetColumnCount ¶
func (*Table) GetRowCount ¶
func (*Table) ProtoMessage ¶
func (*Table) ProtoMessage()
func (*Table) ProtoReflect ¶
func (x *Table) ProtoReflect() protoreflect.Message
func (*Table) SetBoundingBox ¶
func (*Table) SetColumnCount ¶
func (*Table) SetRowCount ¶
type TableCell ¶
type TableCell struct { // Area on the page where the table cell is located. BoundingBox *Polygon `protobuf:"bytes,1,opt,name=bounding_box,json=boundingBox,proto3" json:"bounding_box,omitempty"` // Row index. RowIndex int64 `protobuf:"varint,2,opt,name=row_index,json=rowIndex,proto3" json:"row_index,omitempty"` // Column index. ColumnIndex int64 `protobuf:"varint,3,opt,name=column_index,json=columnIndex,proto3" json:"column_index,omitempty"` // Column span. ColumnSpan int64 `protobuf:"varint,4,opt,name=column_span,json=columnSpan,proto3" json:"column_span,omitempty"` // Row span. RowSpan int64 `protobuf:"varint,5,opt,name=row_span,json=rowSpan,proto3" json:"row_span,omitempty"` // Text in cell. Text string `protobuf:"bytes,6,opt,name=text,proto3" json:"text,omitempty"` // Table cell position from full_text string. TextSegments []*TextSegments `protobuf:"bytes,7,rep,name=text_segments,json=textSegments,proto3" json:"text_segments,omitempty"` // contains filtered or unexported fields }
func (*TableCell) Descriptor
deprecated
func (*TableCell) GetBoundingBox ¶
func (*TableCell) GetColumnIndex ¶
func (*TableCell) GetColumnSpan ¶
func (*TableCell) GetRowIndex ¶
func (*TableCell) GetRowSpan ¶
func (*TableCell) GetTextSegments ¶
func (x *TableCell) GetTextSegments() []*TextSegments
func (*TableCell) ProtoMessage ¶
func (*TableCell) ProtoMessage()
func (*TableCell) ProtoReflect ¶
func (x *TableCell) ProtoReflect() protoreflect.Message
func (*TableCell) SetBoundingBox ¶
func (*TableCell) SetColumnIndex ¶
func (*TableCell) SetColumnSpan ¶
func (*TableCell) SetRowIndex ¶
func (*TableCell) SetRowSpan ¶
func (*TableCell) SetTextSegments ¶
func (m *TableCell) SetTextSegments(v []*TextSegments)
type TextAnnotation ¶
type TextAnnotation struct { // Page width in pixels. Width int64 `protobuf:"varint,1,opt,name=width,proto3" json:"width,omitempty"` // Page height in pixels. Height int64 `protobuf:"varint,2,opt,name=height,proto3" json:"height,omitempty"` // Recognized text blocks in this page. Blocks []*Block `protobuf:"bytes,3,rep,name=blocks,proto3" json:"blocks,omitempty"` // Recognized entities. Entities []*Entity `protobuf:"bytes,4,rep,name=entities,proto3" json:"entities,omitempty"` Tables []*Table `protobuf:"bytes,5,rep,name=tables,proto3" json:"tables,omitempty"` // Full text recognized from image. FullText string `protobuf:"bytes,6,opt,name=full_text,json=fullText,proto3" json:"full_text,omitempty"` // Angle of rotate image Rotate Angle `protobuf:"varint,7,opt,name=rotate,proto3,enum=yandex.cloud.ai.ocr.v1.Angle" json:"rotate,omitempty"` // contains filtered or unexported fields }
func (*TextAnnotation) Descriptor
deprecated
func (*TextAnnotation) Descriptor() ([]byte, []int)
Deprecated: Use TextAnnotation.ProtoReflect.Descriptor instead.
func (*TextAnnotation) GetBlocks ¶
func (x *TextAnnotation) GetBlocks() []*Block
func (*TextAnnotation) GetEntities ¶
func (x *TextAnnotation) GetEntities() []*Entity
func (*TextAnnotation) GetFullText ¶
func (x *TextAnnotation) GetFullText() string
func (*TextAnnotation) GetHeight ¶
func (x *TextAnnotation) GetHeight() int64
func (*TextAnnotation) GetRotate ¶
func (x *TextAnnotation) GetRotate() Angle
func (*TextAnnotation) GetTables ¶
func (x *TextAnnotation) GetTables() []*Table
func (*TextAnnotation) GetWidth ¶
func (x *TextAnnotation) GetWidth() int64
func (*TextAnnotation) ProtoMessage ¶
func (*TextAnnotation) ProtoMessage()
func (*TextAnnotation) ProtoReflect ¶
func (x *TextAnnotation) ProtoReflect() protoreflect.Message
func (*TextAnnotation) Reset ¶
func (x *TextAnnotation) Reset()
func (*TextAnnotation) SetBlocks ¶
func (m *TextAnnotation) SetBlocks(v []*Block)
func (*TextAnnotation) SetEntities ¶
func (m *TextAnnotation) SetEntities(v []*Entity)
func (*TextAnnotation) SetFullText ¶
func (m *TextAnnotation) SetFullText(v string)
func (*TextAnnotation) SetHeight ¶
func (m *TextAnnotation) SetHeight(v int64)
func (*TextAnnotation) SetRotate ¶
func (m *TextAnnotation) SetRotate(v Angle)
func (*TextAnnotation) SetTables ¶
func (m *TextAnnotation) SetTables(v []*Table)
func (*TextAnnotation) SetWidth ¶
func (m *TextAnnotation) SetWidth(v int64)
func (*TextAnnotation) String ¶
func (x *TextAnnotation) String() string
type TextRecognitionAsyncServiceClient ¶
type TextRecognitionAsyncServiceClient interface { // To send the image for asynchronous text recognition. Recognize(ctx context.Context, in *RecognizeTextRequest, opts ...grpc.CallOption) (*operation.Operation, error) // To get recognition results. GetRecognition(ctx context.Context, in *GetRecognitionRequest, opts ...grpc.CallOption) (TextRecognitionAsyncService_GetRecognitionClient, error) }
TextRecognitionAsyncServiceClient is the client API for TextRecognitionAsyncService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewTextRecognitionAsyncServiceClient ¶
func NewTextRecognitionAsyncServiceClient(cc grpc.ClientConnInterface) TextRecognitionAsyncServiceClient
type TextRecognitionAsyncServiceServer ¶
type TextRecognitionAsyncServiceServer interface { // To send the image for asynchronous text recognition. Recognize(context.Context, *RecognizeTextRequest) (*operation.Operation, error) // To get recognition results. GetRecognition(*GetRecognitionRequest, TextRecognitionAsyncService_GetRecognitionServer) error }
TextRecognitionAsyncServiceServer is the server API for TextRecognitionAsyncService service. All implementations should embed UnimplementedTextRecognitionAsyncServiceServer for forward compatibility
type TextRecognitionAsyncService_GetRecognitionClient ¶
type TextRecognitionAsyncService_GetRecognitionClient interface { Recv() (*RecognizeTextResponse, error) grpc.ClientStream }
type TextRecognitionAsyncService_GetRecognitionServer ¶
type TextRecognitionAsyncService_GetRecognitionServer interface { Send(*RecognizeTextResponse) error grpc.ServerStream }
type TextRecognitionServiceClient ¶
type TextRecognitionServiceClient interface { // To send the image for text recognition. Recognize(ctx context.Context, in *RecognizeTextRequest, opts ...grpc.CallOption) (TextRecognitionService_RecognizeClient, error) }
TextRecognitionServiceClient is the client API for TextRecognitionService service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewTextRecognitionServiceClient ¶
func NewTextRecognitionServiceClient(cc grpc.ClientConnInterface) TextRecognitionServiceClient
type TextRecognitionServiceServer ¶
type TextRecognitionServiceServer interface { // To send the image for text recognition. Recognize(*RecognizeTextRequest, TextRecognitionService_RecognizeServer) error }
TextRecognitionServiceServer is the server API for TextRecognitionService service. All implementations should embed UnimplementedTextRecognitionServiceServer for forward compatibility
type TextRecognitionService_RecognizeClient ¶
type TextRecognitionService_RecognizeClient interface { Recv() (*RecognizeTextResponse, error) grpc.ClientStream }
type TextRecognitionService_RecognizeServer ¶
type TextRecognitionService_RecognizeServer interface { Send(*RecognizeTextResponse) error grpc.ServerStream }
type TextSegments ¶
type TextSegments struct { // Start character position from full_text string. StartIndex int64 `protobuf:"varint,1,opt,name=start_index,json=startIndex,proto3" json:"start_index,omitempty"` // Text segment length. Length int64 `protobuf:"varint,2,opt,name=length,proto3" json:"length,omitempty"` // contains filtered or unexported fields }
func (*TextSegments) Descriptor
deprecated
func (*TextSegments) Descriptor() ([]byte, []int)
Deprecated: Use TextSegments.ProtoReflect.Descriptor instead.
func (*TextSegments) GetLength ¶
func (x *TextSegments) GetLength() int64
func (*TextSegments) GetStartIndex ¶
func (x *TextSegments) GetStartIndex() int64
func (*TextSegments) ProtoMessage ¶
func (*TextSegments) ProtoMessage()
func (*TextSegments) ProtoReflect ¶
func (x *TextSegments) ProtoReflect() protoreflect.Message
func (*TextSegments) Reset ¶
func (x *TextSegments) Reset()
func (*TextSegments) SetLength ¶
func (m *TextSegments) SetLength(v int64)
func (*TextSegments) SetStartIndex ¶
func (m *TextSegments) SetStartIndex(v int64)
func (*TextSegments) String ¶
func (x *TextSegments) String() string
type UnimplementedTextRecognitionAsyncServiceServer ¶
type UnimplementedTextRecognitionAsyncServiceServer struct { }
UnimplementedTextRecognitionAsyncServiceServer should be embedded to have forward compatible implementations.
func (UnimplementedTextRecognitionAsyncServiceServer) GetRecognition ¶
func (UnimplementedTextRecognitionAsyncServiceServer) Recognize ¶
func (UnimplementedTextRecognitionAsyncServiceServer) Recognize(context.Context, *RecognizeTextRequest) (*operation.Operation, error)
type UnimplementedTextRecognitionServiceServer ¶
type UnimplementedTextRecognitionServiceServer struct { }
UnimplementedTextRecognitionServiceServer should be embedded to have forward compatible implementations.
type UnsafeTextRecognitionAsyncServiceServer ¶
type UnsafeTextRecognitionAsyncServiceServer interface {
// contains filtered or unexported methods
}
UnsafeTextRecognitionAsyncServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TextRecognitionAsyncServiceServer will result in compilation errors.
type UnsafeTextRecognitionServiceServer ¶
type UnsafeTextRecognitionServiceServer interface {
// contains filtered or unexported methods
}
UnsafeTextRecognitionServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to TextRecognitionServiceServer will result in compilation errors.
type Vertex ¶
type Vertex struct { // X coordinate in pixels. X int64 `protobuf:"varint,1,opt,name=x,proto3" json:"x,omitempty"` // Y coordinate in pixels. Y int64 `protobuf:"varint,2,opt,name=y,proto3" json:"y,omitempty"` // contains filtered or unexported fields }
func (*Vertex) Descriptor
deprecated
func (*Vertex) ProtoMessage ¶
func (*Vertex) ProtoMessage()
func (*Vertex) ProtoReflect ¶
func (x *Vertex) ProtoReflect() protoreflect.Message
type Word ¶
type Word struct { // Area on the page where the word is located. BoundingBox *Polygon `protobuf:"bytes,1,opt,name=bounding_box,json=boundingBox,proto3" json:"bounding_box,omitempty"` // Recognized word value. Text string `protobuf:"bytes,2,opt,name=text,proto3" json:"text,omitempty"` // ID of the recognized word in entities array. EntityIndex int64 `protobuf:"varint,3,opt,name=entity_index,json=entityIndex,proto3" json:"entity_index,omitempty"` // Word position from full_text string. TextSegments []*TextSegments `protobuf:"bytes,4,rep,name=text_segments,json=textSegments,proto3" json:"text_segments,omitempty"` // contains filtered or unexported fields }
func (*Word) Descriptor
deprecated
func (*Word) GetBoundingBox ¶
func (*Word) GetEntityIndex ¶
func (*Word) GetTextSegments ¶
func (x *Word) GetTextSegments() []*TextSegments
func (*Word) ProtoMessage ¶
func (*Word) ProtoMessage()
func (*Word) ProtoReflect ¶
func (x *Word) ProtoReflect() protoreflect.Message
func (*Word) SetBoundingBox ¶
func (*Word) SetEntityIndex ¶
func (*Word) SetTextSegments ¶
func (m *Word) SetTextSegments(v []*TextSegments)