CN109636713A - Localization method, device, equipment and medium - Google Patents
Localization method, device, equipment and medium Download PDFInfo
- Publication number
- CN109636713A CN109636713A CN201811504710.2A CN201811504710A CN109636713A CN 109636713 A CN109636713 A CN 109636713A CN 201811504710 A CN201811504710 A CN 201811504710A CN 109636713 A CN109636713 A CN 109636713A
- Authority
- CN
- China
- Prior art keywords
- target
- label point
- spherical model
- target label
- angle
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 40
- 230000004807 localization Effects 0.000 title claims abstract description 24
- 238000004590 computer program Methods 0.000 claims description 3
- 238000010586 diagram Methods 0.000 description 8
- 230000003287 optical effect Effects 0.000 description 5
- 230000006870 function Effects 0.000 description 4
- 230000005291 magnetic effect Effects 0.000 description 4
- 238000004891 communication Methods 0.000 description 3
- 230000009286 beneficial effect Effects 0.000 description 2
- 230000008450 motivation Effects 0.000 description 2
- 230000002093 peripheral effect Effects 0.000 description 2
- 230000001133 acceleration Effects 0.000 description 1
- 230000005611 electricity Effects 0.000 description 1
- 239000013307 optical fiber Substances 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T3/00—Geometric image transformations in the plane of the image
- G06T3/04—Context-preserving transformations, e.g. by using an importance map
Landscapes
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Processing Or Creating Images (AREA)
Abstract
The embodiment of the invention discloses a kind of localization method, device, equipment and media, are related to panorama and show field.This method comprises: determining relative position coordinates of the target label point in the target image according to the Pixel Dimensions of target label point pixel coordinate in the target image and the target image;Coordinate depending on that relative position determines yaw angle and pitch angle of the target label point in target 3D spherical model;According to the radius of yaw angle and pitch angle and the target 3D spherical model of the target label point in target 3D spherical model, three-dimensional coordinate of the target label point in the target 3D spherical model is determined.The embodiment of the present invention provides a kind of localization method, device, equipment and medium, to realize in the case where the practical latitude and longitude coordinates without obtaining mark point, by positioning of the arbitrary mark point in target image in the 3D spherical model of arbitrary dimension.
Description
Technical field
The present embodiments relate to panoramas to show field more particularly to a kind of localization method, device, equipment and medium.
Background technique
Panorama displaying at present is all that panorama 2D picture is carried out textures in the 3D spherical model that WebGL is created, and creates field
It needs to show mark point on 3D spherical model after scape.
Solve in the prior art how by arbitrary mark point the method for orientation problem is in spherical model, based on label
Practical latitude and longitude coordinates determine Mercator's coordinate of mark point, according to the transformational relation of Mercator's coordinate and 3D modulus type, determine
The three-dimensional coordinate of mark point.
Inventor has found that this method relies on the practical latitude and longitude coordinates of mark point in the implementation of the present invention.However,
The practical latitude and longitude coordinates of mark point are not easy to obtain in many cases.For example, mark point is located at interior.
Summary of the invention
The embodiment of the present invention provides a kind of localization method, device, equipment and medium, to realize without obtaining mark point
In the case where practical latitude and longitude coordinates, by the determining in the 3D spherical model of arbitrary dimension of the arbitrary mark point in target image
Position.
In a first aspect, the embodiment of the invention provides a kind of localization methods, this method comprises:
According to the Pixel Dimensions of target label point pixel coordinate in the target image and the target image, determine described in
Relative position coordinates of the target label point in the target image;
Coordinate depending on that relative position determines yaw angle and pitching of the target label point in target 3D spherical model
Angle;
According to yaw angle of the target label point in target 3D spherical model and pitch angle and the target 3D ball mould
The radius of type determines three-dimensional coordinate of the target label point in the target 3D spherical model.
Second aspect, the embodiment of the invention also provides a kind of positioning device, which includes:
Two-dimensional coordinate determining module, for the pixel coordinate and the target figure according to target label point in the target image
The Pixel Dimensions of picture determine relative position coordinates of the target label point in the target image;
Angle-determining module determines the target label point in target 3D ball mould for coordinate depending on that relative position
Yaw angle and pitch angle in type;
Three-dimensional coordinate determining module, for the yaw angle and pitching according to the target label point in target 3D spherical model
The radius of angle and the target 3D spherical model determines three-dimensional seat of the target label point in the target 3D spherical model
Mark.
The third aspect, the embodiment of the invention also provides a kind of localization methods, this method comprises:
According to the three-dimensional coordinate of the radius of target 3D spherical model and target label point in the target 3D spherical model, determine
Yaw angle and pitch angle of the target label point in target 3D spherical model;
According to yaw angle and pitch angle of the target label point in target 3D spherical model, the target label point is determined
Relative position coordinates in the target image;
According to the relative position coordinates of the Pixel Dimensions of the target image and target label point in the target image,
Determine the pixel coordinate of the target label point in the target image.
Fourth aspect, the embodiment of the invention also provides a kind of positioning device, which includes:
Deflection determining module, for the radius and target label point according to target 3D spherical model in the target 3D ball mould
Three-dimensional coordinate in type determines yaw angle and pitch angle of the target label point in target 3D spherical model;
Position coordinates determining module, for the yaw angle and pitching according to the target label point in target 3D spherical model
Angle determines the relative position coordinates of the target label point in the target image;
Pixel coordinate determining module, for the Pixel Dimensions and target label point according to the target image in target
Relative position coordinates in image determine the pixel coordinate of the target label point in the target image.
5th aspect, the embodiment of the invention also provides one kind, the equipment includes:
One or more processors;
Storage device, for storing one or more programs,
When one or more of programs are executed by one or more of processors, so that one or more of processing
Device realizes the localization method as described in any in the embodiment of the present invention.
6th aspect, the embodiment of the invention also provides a kind of computer readable storage mediums, are stored thereon with computer
Program realizes the localization method as described in any in the embodiment of the present invention when program is executed by processor.
The embodiment of the present invention passes through according to target label point pixel coordinate in the target image and the target image
Pixel Dimensions determine yaw angle and pitch angle of the target label point in target 3D spherical model;According to the target label
The radius of yaw angle and pitch angle and the target 3D spherical model of the point in target 3D spherical model, determines the target mark
Three-dimensional coordinate of the note point in the target 3D spherical model.To realize according to two-dimensional pixel coordinate pair target label point in target
Positioning in 3D spherical model.
Detailed description of the invention
Fig. 1 is a kind of flow chart for localization method that the embodiment of the present invention one provides;
Fig. 2 is three-dimensional coordinate schematic diagram of the target label point of the offer of the embodiment of the present invention one in target 3D spherical model;
Fig. 3 is a kind of structural schematic diagram of positioning device provided by Embodiment 2 of the present invention;
Fig. 4 is a kind of flow chart for localization method that the embodiment of the present invention three provides;
Fig. 5 is a kind of structural schematic diagram for positioning device that the embodiment of the present invention four provides;
Fig. 6 is a kind of structural schematic diagram for equipment that the embodiment of the present invention five provides.
Specific embodiment
The present invention is described in further detail with reference to the accompanying drawings and examples.It is understood that this place is retouched
The specific embodiment stated is used only for explaining the present invention rather than limiting the invention.It also should be noted that in order to just
Only the parts related to the present invention are shown in description, attached drawing rather than entire infrastructure.
Embodiment one
Fig. 1 is a kind of flow chart for localization method that the embodiment of the present invention one provides.The present embodiment is applicable to target
The case where mark point positions in target 3D spherical model.This method can be executed by a kind of positioning device, which can be by
The mode of software and/or hardware is realized.Referring to Fig. 1, localization method provided in this embodiment includes:
S110, according to the Pixel Dimensions of target label point pixel coordinate in the target image and the target image, really
Fixed relative position coordinates of the target label point in the target image.
Wherein, the target image can be random two-dimensional image, and the typically described target image can be the room of shooting
Interior or outdoor panoramic picture.
The Pixel Dimensions of target image refer to the width and height of target image.
Relative position coordinates indicate the coordinate of the relative position of target label point in the target image.
Specifically, the pixel coordinate according to target label point in the target image of acquisition and the target image
Pixel Dimensions determine relative position coordinates of the target label point in the target image, comprising:
By pixel coordinate value each in the pixel coordinate of target label point, divided by target image associated by each pixel coordinate value
It is wide or high, generate relative position coordinates of the target label point in the target image.
For example, the wide of target image is 100, Gao Shi 200 if the pixel coordinate of target label point is (50,50), then it is described
Relative position coordinates of the target label point in the target image be (50 divided by 100,50 divided by 200), namely (0.5,
0.25).Wherein the above-mentioned unit being respectively worth can be pixel, be also possible to centimetre.
S120, depending on that relative position coordinate determine yaw angle of the target label point in target 3D spherical model
And pitch angle.
Wherein, yaw angle refers to the horizontal view angle in 3D spherical model;Pitch angle refers to the vertical angle of view in 3D spherical model.It is logical
The position of horizontal view angle and vertical angle of view adjustment camera is crossed, to show a certain specified region of panorama sketch.
Specifically, the coordinate depending on that relative position is determined from default yaw angular region and default pitch range
Yaw angle and pitch angle of the target label point in target 3D spherical model, comprising:
According to the siding-to-siding block length with the associated relative position coordinates value of yaw angle and yaw angle, the target mark is determined
Yaw angle of the note point in target 3D spherical model;
According to the associated relative position coordinates value of pitch angle, the siding-to-siding block length and interval range of pitch angle determine institute
State pitch angle of the target label point in target 3D spherical model.
Wherein, the siding-to-siding block length and interval range of yaw angle and pitch angle can be set according to actual needs.It is typical
Ground, the siding-to-siding block length of yaw angle are 360, and interval range is 0 degree to 360 degree.The siding-to-siding block length of pitch angle is 180, interval range
It is 90 degree to 0 degree and 0 degree to minus 90 degree.
For example, if the relative position coordinates of target label point in the target image are (0.5,0.25), then yaw angle are as follows:
0.5 × 360=180 degree, pitch angle are as follows: minus 45 degree of 0.25 × 180-90=.
S130, according to yaw angle of the target label point in target 3D spherical model and pitch angle and the target
The radius of 3D spherical model determines three-dimensional coordinate of the target label point in the target 3D spherical model.
Wherein, the radius of target 3D spherical model can be set as needed.
Specifically, the yaw angle and pitch angle according to the target label point in target 3D spherical model, Yi Jisuo
The radius for stating target 3D spherical model determines three-dimensional coordinate of the target label point in the target 3D spherical model, comprising:
Three-dimensional coordinate of the target label point in the target 3D spherical model is determined according to following formula,
X=r × cos β × cos α
Y=r × sin β
Z=r × cos β × sin α
Wherein, X, Y and Z are the three-dimensional coordinates of the target label point, and r is the radius of the target 3D spherical model, and α is indicated
Pitch angle, β indicate yaw angle.
Referring to fig. 2, three-dimensional coordinate of the target label point in target 3D spherical model is p.
The technical solution of the embodiment of the present invention, by according to target label point pixel coordinate in the target image and described
The Pixel Dimensions of target image determine yaw angle and pitch angle of the target label point in target 3D spherical model;According to institute
The radius of yaw angle and pitch angle and the target 3D spherical model of the target label point in target 3D spherical model is stated, is determined
Three-dimensional coordinate of the target label point in the target 3D spherical model.To realize according to two-dimensional pixel coordinate pair target mark
Positioning of the note point in target 3D spherical model.
It should be noted that by the technical teaching of the present embodiment, those skilled in the art have motivation by above-described embodiment
Described in any embodiment carry out the combination of scheme, to realize positioning of the target label point in 3D spherical model.
Embodiment two
Fig. 3 is a kind of structural schematic diagram of positioning device provided by Embodiment 2 of the present invention.Referring to Fig. 3, the present embodiment is mentioned
The positioning device of confession includes: two-dimensional coordinate determining module 10, angle-determining module 20 and three-dimensional coordinate determining module 30.
Wherein, two-dimensional coordinate determining module 10, for according to target label point pixel coordinate in the target image and institute
The Pixel Dimensions for stating target image determine relative position coordinates of the target label point in the target image;
Angle-determining module 20 determines the target label point in target 3D ball for coordinate depending on that relative position
Yaw angle and pitch angle in model;
Three-dimensional coordinate determining module 30, for according to yaw angle of the target label point in target 3D spherical model and bowing
The radius of the elevation angle and the target 3D spherical model determines three-dimensional of the target label point in the target 3D spherical model
Coordinate.
The technical solution of the embodiment of the present invention, by according to target label point pixel coordinate in the target image and described
The Pixel Dimensions of target image determine yaw angle and pitch angle of the target label point in target 3D spherical model;According to institute
The radius of yaw angle and pitch angle and the target 3D spherical model of the target label point in target 3D spherical model is stated, is determined
Three-dimensional coordinate of the target label point in the target 3D spherical model.To realize according to two-dimensional pixel coordinate pair target mark
Positioning of the note point in target 3D spherical model.
Further, the two-dimensional coordinate determining module, comprising: two-dimensional coordinate determination unit.
Wherein, two-dimensional coordinate determination unit, for by pixel coordinate value each in the pixel coordinate of target label point, divided by each
The width or height of target image associated by pixel coordinate value generate relative position of the target label point in the target image
Coordinate.
Further, the angle-determining module, comprising: yaw angle determination unit and pitch angle determination unit.
Wherein, yaw angle determination unit, for according to the associated relative position coordinates value of yaw angle and yaw angle
Siding-to-siding block length determines yaw angle of the target label point in target 3D spherical model;
Pitch angle determination unit, for basis and the associated relative position coordinates value of pitch angle, the siding-to-siding block length of pitch angle
And interval range, determine pitch angle of the target label point in target 3D spherical model.
Further, the three-dimensional coordinate determining module, comprising: three-dimensional coordinate determination unit.
Wherein, three-dimensional coordinate determination unit, for determining the target label point in the target 3D according to following formula
Three-dimensional coordinate in spherical model,
X=r × cos β × cos α
Y=r × sin β
Z=r × cos β × sin α
Wherein, X, Y and Z are the three-dimensional coordinates of the target label point, and r is the radius of the target 3D spherical model, and α is indicated
Pitch angle, β indicate yaw angle.
Localization method provided by any embodiment of the invention can be performed in positioning device provided by the embodiment of the present invention, tool
The standby corresponding functional module of execution method and beneficial effect.
Embodiment three
Fig. 4 is a kind of flow chart for localization method that the embodiment of the present invention three provides.The present embodiment is in above-described embodiment
On the basis of, a kind of three-dimensional coordinate suitable for according to target label point 3D spherical model of proposition determines target label point
The optinal plan of two-dimensional pixel coordinate in the target image.Referring to fig. 4, localization method provided in this embodiment includes:
S210, the three-dimensional seat according to the radius and target label point of target 3D spherical model in the target 3D spherical model
Mark, determines yaw angle and pitch angle of the target label point in target 3D spherical model.
Specifically, the radius and target label point according to target 3D spherical model in the target 3D spherical model three
Coordinate is tieed up, determines yaw angle and pitch angle of the target label point in target 3D spherical model, comprising:
Yaw angle and pitch angle of the target label point in target 3d spherical model are determined according to following formula,
β=arcsin (y/r)
α=arctan (z/x)
Wherein, X, Y and Z are the three-dimensional coordinates of the target label point, and r is the radius of the target 3D spherical model, and α is indicated
Pitch angle, β indicate yaw angle.
S220, yaw angle and pitch angle according to the target label point in target 3D spherical model, determine the target
The relative position coordinates of mark point in the target image.
Specifically, the yaw angle and pitch angle according to the target label point in target 3D spherical model, determines institute
State the relative position coordinates of target label point in the target image, comprising:
According to the siding-to-siding block length of yaw angle and yaw angle of the target label point in target 3D spherical model, determine
With the associated relative position coordinates value of yaw angle;
According to pitch angle of the target label point in target 3D spherical model, the siding-to-siding block length and section model of pitch angle
It encloses, the determining and associated relative position coordinates value of pitch angle.
For example, pitch angle is negative 45 degree if yaw angle is 180 degree, the siding-to-siding block length of yaw angle is 360, the area of pitch angle
Between length be 180, the interval range of pitch angle is 90 degree to 0 degree and 0 degree to 90 degree, then the relative position of target label point
In coordinate with the associated coordinate value of yaw angle are as follows: 180 ÷ 360=0.5, with the associated coordinate value of pitch angle are as follows: (- 45+90) ÷
The relative position coordinates of 180=0.25 namely target label point are (0.5,0.25).
S230, the relative position according to the Pixel Dimensions and target label point of the target image in the target image
Coordinate determines the pixel coordinate of the target label point in the target image.
For example, the relative position coordinates of a height of 200 pixel, target label point are if the width of target image is 100 pixels
(0.5,0.25), then the pixel coordinate of target label point in the target image be (0.5 × 100,0.25 × 200), namely (50,
50)。
The technical solution of the embodiment of the present invention, by the radius and target label point according to target 3D spherical model in the mesh
The three-dimensional coordinate in 3D spherical model is marked, determines yaw angle and pitch angle of the target label point in target 3D spherical model;Root
According to yaw angle and pitch angle of the target label point in target 3D spherical model, determine the target label point in target image
In relative position coordinates;According to the Pixel Dimensions of the target image and target label point in the target image opposite
Position coordinates determine the pixel coordinate of the target label point in the target image.To realize according to target label point in 3D
Three-dimensional location coordinates in spherical model, to the positioning of target label point in the target image.
It should be noted that by the technical teaching of the present embodiment, those skilled in the art have motivation by above-described embodiment
Described in any embodiment carry out the combination of scheme, to realize positioning of the target label point in 3D spherical model.
Example IV
Fig. 5 is a kind of structural schematic diagram for positioning device that the embodiment of the present invention four provides.Referring to Fig. 5, the present embodiment is mentioned
The positioning device of confession includes: deflection determining module 40, position coordinates determining module 50 and pixel coordinate determining module 60.
Wherein, deflection determining module 40, for the radius and target label point according to target 3D spherical model in the mesh
The three-dimensional coordinate in 3D spherical model is marked, determines yaw angle and pitch angle of the target label point in target 3D spherical model;
Position coordinates determining module 50, for according to yaw angle of the target label point in target 3D spherical model and bowing
The elevation angle determines the relative position coordinates of the target label point in the target image;
Pixel coordinate determining module 60, for the Pixel Dimensions and target label point according to the target image in mesh
Relative position coordinates in logo image determine the pixel coordinate of the target label point in the target image.
The technical solution of the embodiment of the present invention, by the radius and target label point according to target 3D spherical model in the mesh
The three-dimensional coordinate in 3D spherical model is marked, determines yaw angle and pitch angle of the target label point in target 3D spherical model;Root
According to yaw angle and pitch angle of the target label point in target 3D spherical model, determine the target label point in target image
In relative position coordinates;According to the Pixel Dimensions of the target image and target label point in the target image opposite
Position coordinates determine the pixel coordinate of the target label point in the target image.To realize according to target label point in 3D
Three-dimensional location coordinates in spherical model, to the positioning of target label point in the target image.
Further, the deflection determining module, comprising: deflection determination unit.
Wherein, deflection determination unit, for determining the target label point in target 3d spherical model according to following formula
In yaw angle and pitch angle,
β=arcsin (y/r)
α=arctan (z/x)
Wherein, X, Y and Z are the three-dimensional coordinates of the target label point, and r is the radius of the target 3D spherical model, and α is indicated
Pitch angle, β indicate yaw angle.
Further, the position coordinates determining module, comprising: the first coordinate determination unit and the second coordinate determine list
Member.
First coordinate determination unit, for the yaw angle according to the target label point in target 3D spherical model, and
The siding-to-siding block length of yaw angle, the determining and associated relative position coordinates value of yaw angle;
Second coordinate determination unit, for the pitch angle according to the target label point in target 3D spherical model, pitching
The siding-to-siding block length and interval range at angle, the determining and associated relative position coordinates value of pitch angle.
Localization method provided by any embodiment of the invention can be performed in positioning device provided by the embodiment of the present invention, tool
The standby corresponding functional module of execution method and beneficial effect.
Embodiment five
Fig. 6 is a kind of structural schematic diagram for equipment that the embodiment of the present invention five provides.Fig. 6, which is shown, to be suitable for being used to realizing this
The block diagram of the example devices 12 of invention embodiment.The equipment 12 that Fig. 6 is shown is only an example, should not be to of the invention real
The function and use scope for applying example bring any restrictions.
As shown in fig. 6, equipment 12 is showed in the form of universal computing device.The component of equipment 12 may include but unlimited
In one or more processor or processing unit 16, system storage 28, connecting different system components, (including system is deposited
Reservoir 28 and processing unit 16) bus 18.
Bus 18 indicates one of a few class bus structures or a variety of, including memory bus or Memory Controller,
Peripheral bus, graphics acceleration port, processor or the local bus using any bus structures in a variety of bus structures.It lifts
For example, these architectures include but is not limited to industry standard architecture (ISA) bus, microchannel architecture (MAC)
Bus, enhanced isa bus, Video Electronics Standards Association (VESA) local bus and peripheral component interconnection (PCI) bus.
Equipment 12 typically comprises a variety of computer system readable media.These media can be it is any can be by equipment 12
The usable medium of access, including volatile and non-volatile media, moveable and immovable medium.
System storage 28 may include the computer system readable media of form of volatile memory, such as arbitrary access
Memory (RAM) 30 and/or cache memory 32.Equipment 12 may further include it is other it is removable/nonremovable,
Volatile/non-volatile computer system storage medium.Only as an example, storage system 34 can be used for reading and writing irremovable
, non-volatile magnetic media (Fig. 6 do not show, commonly referred to as " hard disk drive ").Although being not shown in Fig. 6, use can be provided
In the disc driver read and write to removable non-volatile magnetic disk (such as " floppy disk "), and to removable anonvolatile optical disk
The CD drive of (such as CD-ROM, DVD-ROM or other optical mediums) read-write.In these cases, each driver can
To be connected by one or more data media interfaces with bus 18.Memory 28 may include at least one program product,
The program product has one group of (for example, at least one) program module, these program modules are configured to perform each implementation of the invention
The function of example.
Program/utility 40 with one group of (at least one) program module 42 can store in such as memory 28
In, such program module 42 include but is not limited to operating system, one or more application program, other program modules and
It may include the realization of network environment in program data, each of these examples or certain combination.Program module 42 is usual
Execute the function and/or method in embodiment described in the invention.
Equipment 12 can also be communicated with one or more external equipments 14 (such as keyboard, sensing equipment, display 24 etc.),
Can also be enabled a user to one or more equipment interacted with the equipment 12 communication, and/or with enable the equipment 12 with
One or more of the other any equipment (such as network interface card, modem etc.) communication for calculating equipment and being communicated.It is this logical
Letter can be carried out by input/output (I/O) interface 22.Also, equipment 12 can also by network adapter 20 and one or
The multiple networks of person (such as local area network (LAN), wide area network (WAN) and/or public network, such as internet) communication.As shown,
Network adapter 20 is communicated by bus 18 with other modules of equipment 12.It should be understood that although not shown in the drawings, can combine
Equipment 12 use other hardware and/or software module, including but not limited to: microcode, device driver, redundant processing unit,
External disk drive array, RAID system, tape drive and data backup storage system etc..
Processing unit 16 by the program that is stored in system storage 28 of operation, thereby executing various function application and
Data processing, such as realize localization method provided by the embodiment of the present invention.
Embodiment six
The embodiment of the present invention six additionally provides a kind of computer readable storage medium, is stored thereon with computer program, should
The localization method as described in any in the embodiment of the present invention is realized when program is executed by processor, this method comprises:
According to the Pixel Dimensions of target label point pixel coordinate in the target image and the target image, determine described in
Relative position coordinates of the target label point in the target image;
Coordinate depending on that relative position determines yaw angle and pitching of the target label point in target 3D spherical model
Angle;
According to yaw angle of the target label point in target 3D spherical model and pitch angle and the target 3D ball mould
The radius of type determines three-dimensional coordinate of the target label point in the target 3D spherical model.And/or
According to the three-dimensional coordinate of the radius of target 3D spherical model and target label point in the target 3D spherical model, determine
Yaw angle and pitch angle of the target label point in target 3D spherical model;
According to yaw angle and pitch angle of the target label point in target 3D spherical model, the target label point is determined
Relative position coordinates in the target image;
According to the relative position coordinates of the Pixel Dimensions of the target image and target label point in the target image,
Determine the pixel coordinate of the target label point in the target image.
The computer storage medium of the embodiment of the present invention, can be using any of one or more computer-readable media
Combination.Computer-readable medium can be computer-readable signal media or computer readable storage medium.It is computer-readable
Storage medium for example may be-but not limited to-the system of electricity, magnetic, optical, electromagnetic, infrared ray or semiconductor, device or
Device, or any above combination.The more specific example (non exhaustive list) of computer readable storage medium includes: tool
There are electrical connection, the portable computer diskette, hard disk, random access memory (RAM), read-only memory of one or more conducting wires
(ROM), erasable programmable read only memory (EPROM or flash memory), optical fiber, portable compact disc read-only memory (CD-
ROM), light storage device, magnetic memory device or above-mentioned any appropriate combination.In this document, computer-readable storage
Medium can be any tangible medium for including or store program, which can be commanded execution system, device or device
Using or it is in connection.
Computer-readable signal media may include in a base band or as carrier wave a part propagate data-signal,
Wherein carry computer-readable program code.The data-signal of this propagation can take various forms, including but unlimited
In electromagnetic signal, optical signal or above-mentioned any appropriate combination.Computer-readable signal media can also be that computer can
Any computer-readable medium other than storage medium is read, which can send, propagates or transmit and be used for
By the use of instruction execution system, device or device or program in connection.
The program code for including on computer-readable medium can transmit with any suitable medium, including --- but it is unlimited
In wireless, electric wire, optical cable, RF etc. or above-mentioned any appropriate combination.
The computer for executing operation of the present invention can be write with one or more programming languages or combinations thereof
Program code, described program design language include object oriented program language-such as Java, Smalltalk, C++,
Further include conventional procedural programming language-such as " C " language or similar programming language.Program code can be with
It fully executes, partly execute on the user computer on the user computer, being executed as an independent software package, portion
Divide and partially executes or executed on a remote computer or server completely on the remote computer on the user computer.?
Be related in the situation of remote computer, remote computer can pass through the network of any kind --- including local area network (LAN) or
Wide area network (WAN)-be connected to subscriber computer, or, it may be connected to outer computer (such as mentioned using Internet service
It is connected for quotient by internet).
Note that the above is only a better embodiment of the present invention and the applied technical principle.It will be appreciated by those skilled in the art that
The invention is not limited to the specific embodiments described herein, be able to carry out for a person skilled in the art it is various it is apparent variation,
It readjusts and substitutes without departing from protection scope of the present invention.Therefore, although being carried out by above embodiments to the present invention
It is described in further detail, but the present invention is not limited to the above embodiments only, without departing from the inventive concept, also
It may include more other equivalent embodiments, and the scope of the invention is determined by the scope of the appended claims.
Claims (16)
1. a kind of localization method characterized by comprising
According to the Pixel Dimensions of target label point pixel coordinate in the target image and the target image, the target is determined
Relative position coordinates of the mark point in the target image;
Coordinate depending on that relative position determines yaw angle and pitch angle of the target label point in target 3D spherical model;
According to yaw angle of the target label point in target 3D spherical model and pitch angle and the target 3D spherical model
Radius determines three-dimensional coordinate of the target label point in the target 3D spherical model.
2. the method according to claim 1, wherein it is described according to target label point in the target image of acquisition
Pixel coordinate and the target image Pixel Dimensions, determine opposite position of the target label point in the target image
Set coordinate, comprising:
By pixel coordinate value each in the pixel coordinate of target label point, divided by target image associated by each pixel coordinate value width or
Height generates relative position coordinates of the target label point in the target image.
3. the method according to claim 1, wherein the coordinate depending on that relative position is from default yaw angle
Yaw angle and pitch angle of the target label point in target 3D spherical model, packet are determined in range and default pitch range
It includes:
According to the siding-to-siding block length with the associated relative position coordinates value of yaw angle and yaw angle, the target label point is determined
Yaw angle in target 3D spherical model;
According to the associated relative position coordinates value of pitch angle, the siding-to-siding block length and interval range of pitch angle determine the mesh
Mark pitch angle of the mark point in target 3D spherical model.
4. the method according to claim 1, wherein it is described according to the target label point in target 3D spherical model
In yaw angle and pitch angle and the target 3D spherical model radius, determine the target label point in the target 3D
Three-dimensional coordinate in spherical model, comprising:
Three-dimensional coordinate of the target label point in the target 3D spherical model is determined according to following formula,
X=r × cos β × cos α
Y=r × sin β
Z=r × cos β × sin α
Wherein, X, Y and Z are the three-dimensional coordinates of the target label point, and r is the radius of the target 3D spherical model, and α indicates pitching
Angle, β indicate yaw angle.
5. a kind of positioning device characterized by comprising
Two-dimensional coordinate determining module, for according to target label point pixel coordinate in the target image and the target image
Pixel Dimensions determine relative position coordinates of the target label point in the target image;
Angle-determining module determines the target label point in target 3D spherical model for coordinate depending on that relative position
Yaw angle and pitch angle;
Three-dimensional coordinate determining module, for the yaw angle and pitch angle according to the target label point in target 3D spherical model,
And the radius of the target 3D spherical model, determine three-dimensional coordinate of the target label point in the target 3D spherical model.
6. device according to claim 5, which is characterized in that the two-dimensional coordinate determining module, comprising:
Two-dimensional coordinate determination unit, for by pixel coordinate value each in the pixel coordinate of target label point, divided by each pixel coordinate
It is worth the width or height of associated target image, generates relative position coordinates of the target label point in the target image.
7. device according to claim 5, which is characterized in that the angle-determining module, comprising:
Yaw angle determination unit is used for the siding-to-siding block length of basis and the associated relative position coordinates value of yaw angle and yaw angle,
Determine yaw angle of the target label point in target 3D spherical model;
Pitch angle determination unit, for according to and the associated relative position coordinates value of pitch angle, the siding-to-siding block length of pitch angle and
Interval range determines pitch angle of the target label point in target 3D spherical model.
8. device according to claim 5, which is characterized in that the three-dimensional coordinate determining module, comprising:
Three-dimensional coordinate determination unit, for determining the target label point in the target 3D spherical model according to following formula
Three-dimensional coordinate,
X=r × cos β × cos α
Y=r × sin β
Z=r × cos β × sin α
Wherein, X, Y and Z are the three-dimensional coordinates of the target label point, and r is the radius of the target 3D spherical model, and α indicates pitching
Angle, β indicate yaw angle.
9. a kind of localization method characterized by comprising
According to the three-dimensional coordinate of the radius of target 3D spherical model and target label point in the target 3D spherical model, determine described in
Yaw angle and pitch angle of the target label point in target 3D spherical model;
According to yaw angle and pitch angle of the target label point in target 3D spherical model, determine the target label point in mesh
Relative position coordinates in logo image;
According to the relative position coordinates of the Pixel Dimensions of the target image and target label point in the target image, determine
The pixel coordinate of the target label point in the target image.
10. according to the method described in claim 9, it is characterized in that, the radius and target mark according to target 3D spherical model
Three-dimensional coordinate of the note point in the target 3D spherical model, determines yaw angle of the target label point in target 3D spherical model
And pitch angle, comprising:
Yaw angle and pitch angle of the target label point in target 3d spherical model are determined according to following formula,
β=arcsin (y/r)
α=arctan (z/x)
Wherein, X, Y and Z are the three-dimensional coordinates of the target label point, and r is the radius of the target 3D spherical model, and α indicates pitching
Angle, β indicate yaw angle.
11. according to the method described in claim 9, it is characterized in that, it is described according to the target label point in target 3D ball mould
Yaw angle and pitch angle in type determine the relative position coordinates of the target label point in the target image, comprising:
It is determining and inclined according to the siding-to-siding block length of yaw angle and yaw angle of the target label point in target 3D spherical model
The relative position coordinates value of boat angular correlation;
According to pitch angle of the target label point in target 3D spherical model, the siding-to-siding block length and interval range of pitch angle,
The determining and associated relative position coordinates value of pitch angle.
12. a kind of positioning device characterized by comprising
Deflection determining module, for the radius and target label point according to target 3D spherical model in the target 3D spherical model
Three-dimensional coordinate, determine yaw angle and pitch angle of the target label point in target 3D spherical model;
Position coordinates determining module, for the yaw angle and pitch angle according to the target label point in target 3D spherical model,
Determine the relative position coordinates of the target label point in the target image;
Pixel coordinate determining module, for the Pixel Dimensions and target label point according to the target image in target image
In relative position coordinates, determine the pixel coordinate of the target label point in the target image.
13. device according to claim 12, which is characterized in that the deflection determining module, comprising:
Deflection determination unit, for determining yaw angle of the target label point in target 3d spherical model according to following formula
And pitch angle,
β=arcsin (y/r)
α=arctan (z/x)
Wherein, X, Y and Z are the three-dimensional coordinates of the target label point, and r is the radius of the target 3D spherical model, and α indicates pitching
Angle, β indicate yaw angle.
14. device according to claim 9, which is characterized in that the position coordinates determining module, comprising:
First coordinate determination unit, for the yaw angle according to the target label point in target 3D spherical model, and yaw
The siding-to-siding block length at angle, the determining and associated relative position coordinates value of yaw angle;
Second coordinate determination unit, for the pitch angle according to the target label point in target 3D spherical model, pitch angle
Siding-to-siding block length and interval range, the determining and associated relative position coordinates value of pitch angle.
15. a kind of equipment, which is characterized in that the equipment includes:
One or more processors;
Storage device, for storing one or more programs,
When one or more of programs are executed by one or more of processors, so that one or more of processors are real
The now localization method as described in any in claim 1-4 or claim 9-11.
16. a kind of computer readable storage medium, is stored thereon with computer program, which is characterized in that the program is by processor
The localization method as described in any in claim 1-4 or claim 9-11 is realized when execution.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811504710.2A CN109636713A (en) | 2018-12-10 | 2018-12-10 | Localization method, device, equipment and medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811504710.2A CN109636713A (en) | 2018-12-10 | 2018-12-10 | Localization method, device, equipment and medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN109636713A true CN109636713A (en) | 2019-04-16 |
Family
ID=66072600
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811504710.2A Pending CN109636713A (en) | 2018-12-10 | 2018-12-10 | Localization method, device, equipment and medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109636713A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110148173A (en) * | 2019-05-21 | 2019-08-20 | 北京百度网讯科技有限公司 | The method and apparatus of target positioning, electronic equipment, computer-readable medium |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103035016A (en) * | 2012-11-28 | 2013-04-10 | 无锡羿飞科技有限公司 | Processing method of projector spherical display and rotary output image |
CN106303417A (en) * | 2016-08-12 | 2017-01-04 | 长沙冰眼电子科技有限公司 | Enhancing overall view monitoring method for unmanned platform |
CN106570905A (en) * | 2016-11-02 | 2017-04-19 | 北京控制工程研究所 | Initial attitude verification method of non-cooperative target point cloud |
US20170256072A1 (en) * | 2016-03-07 | 2017-09-07 | Ricoh Company, Ltd. | Information processing system, information processing method, and non-transitory computer-readable storage medium |
CN108830894A (en) * | 2018-06-19 | 2018-11-16 | 亮风台(上海)信息科技有限公司 | Remote guide method, apparatus, terminal and storage medium based on augmented reality |
-
2018
- 2018-12-10 CN CN201811504710.2A patent/CN109636713A/en active Pending
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103035016A (en) * | 2012-11-28 | 2013-04-10 | 无锡羿飞科技有限公司 | Processing method of projector spherical display and rotary output image |
US20170256072A1 (en) * | 2016-03-07 | 2017-09-07 | Ricoh Company, Ltd. | Information processing system, information processing method, and non-transitory computer-readable storage medium |
CN106303417A (en) * | 2016-08-12 | 2017-01-04 | 长沙冰眼电子科技有限公司 | Enhancing overall view monitoring method for unmanned platform |
CN106570905A (en) * | 2016-11-02 | 2017-04-19 | 北京控制工程研究所 | Initial attitude verification method of non-cooperative target point cloud |
CN108830894A (en) * | 2018-06-19 | 2018-11-16 | 亮风台(上海)信息科技有限公司 | Remote guide method, apparatus, terminal and storage medium based on augmented reality |
Non-Patent Citations (2)
Title |
---|
BIGWHITESHARK(云飞扬): "uv纹理坐标设定与贴图规则", 《HTTPS://WWW.CNBLOGS.COM/JENRY/P/4083415.HTML》 * |
程序园: "球面点三维坐标到纹理二维坐标的转换", 《HTTP://WWW.VOIDCN.COM/ARTICLE/P-MXDNCCIQ-NB.HTML》 * |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110148173A (en) * | 2019-05-21 | 2019-08-20 | 北京百度网讯科技有限公司 | The method and apparatus of target positioning, electronic equipment, computer-readable medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109300159A (en) | Method for detecting position, device, equipment, storage medium and vehicle | |
CN108450058B (en) | Real-time automatic vehicle-mounted camera calibration | |
CN109242903A (en) | Generation method, device, equipment and the storage medium of three-dimensional data | |
CN108805979B (en) | Three-dimensional reconstruction method, device, equipment and storage medium for dynamic model | |
CN109242913A (en) | Scaling method, device, equipment and the medium of collector relative parameter | |
CN110095752A (en) | Localization method, device, equipment and medium | |
CN109191554B (en) | Super-resolution image reconstruction method, device, terminal and storage medium | |
CN110163903A (en) | The acquisition of 3-D image and image position method, device, equipment and storage medium | |
US20130176337A1 (en) | Device and Method For Information Processing | |
US8803880B2 (en) | Image-based lighting simulation for objects | |
KR20190125526A (en) | Method and apparatus for displaying an image based on user motion information | |
CN109961522A (en) | Image projecting method, device, equipment and storage medium | |
TW200912512A (en) | Augmenting images for panoramic display | |
CN109040736A (en) | A kind of scaling method, device, equipment and the storage medium of eye space position | |
CN113077548B (en) | Collision detection method, device, equipment and storage medium for object | |
CN111161398B (en) | Image generation method, device, equipment and storage medium | |
CN112529097B (en) | Sample image generation method and device and electronic equipment | |
WO2017113729A1 (en) | 360-degree image loading method and loading module, and mobile terminal | |
CN115439528B (en) | Method and equipment for acquiring image position information of target object | |
CN108090212B (en) | Method, device and equipment for showing interest points and storage medium | |
CN109636713A (en) | Localization method, device, equipment and medium | |
CN113112412B (en) | Method and device for generating vertical correction matrix and computer readable storage medium | |
JP7375149B2 (en) | Positioning method, positioning device, visual map generation method and device | |
CN113763478A (en) | Unmanned vehicle camera calibration method, device, equipment, storage medium and system | |
CN109949396A (en) | A kind of rendering method, device, equipment and medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20190416 |
|
RJ01 | Rejection of invention patent application after publication |