Floor method of discrimination, device, electronic equipment and storage medium
Technical field
The present invention relates to security against fire field, specially a kind of floor method of discrimination, device, electronic equipment and storage are situated between
Matter.
Background technique
In the event of a fire in a high-rise building, since various pipe-lines interlock in length and breadth, fire smoke, which can be spread rapidly, to be caused
Limited view when fireman participates in rescue will cause rescue situs ambiguus to delay rescue once fireman gets into a difficult position
Work causes fireman's life to be on the hazard, and then urgent need one kind can position fireman in floor
Algorithm.Existing indoor positioning technologies mainly build network topology structure indoors, find distance according to the location of people
The position of nearest network node, the node is equivalent to the location of people.This cyberspace location technology needs mention
It is preceding to arrange a large amount of network node indoors, it higher cost and is easy to be influenced by environment, when generation fire, caused by flame
Temperature is easy to damage network node, to influence rescue work.
Summary of the invention
It is an object of that present invention to provide a kind of floor method of discrimination, device, electronic equipment and storage mediums.The floor differentiates
Method only needs inertial navigator and barometer that the accurate differentiation to floor locating for itself can be completed, and structure is simple, is convenient for
It carries.
In order to achieve the above object, technical solution of the present invention has:
A kind of floor method of discrimination comprising following steps:
Receive the track data and barometrical altitude data of inertial navigator, the inertial navigator and air pressure
It counts co-located;
Ordinate in the track data is replaced with into the altitude data, replaced track data is defined
For running track figure;
The inflection point of floor is obtained according to the running track figure;
The position of destination is determined according to the quantity of initial floor and inflection point.
Further, the inertial navigator and barometer are respectively positioned on fireman.
Further, the inflection point that floor is obtained according to the running track figure, comprising:
The operation trend of running track figure before and after a certain position is on the contrary, then a certain position is inflection point.
Further, the inflection point that floor is obtained according to the running track figure, comprising:
The operation trend of running track figure before and after a certain position is on the contrary, then a certain position is denoted as doubtful inflection point:
The doubtful inflection point is confirmed: when the distance between the doubtful inflection point of target doubtful inflection point adjacent thereto is not small
When threshold value, then the doubtful inflection point of the target is inflection point.
Further, the distance between the doubtful inflection point of the target doubtful inflection point adjacent thereto is mesh in running track figure
Mark the difference between the corresponding altitude data of the doubtful inflection point corresponding altitude data of doubtful inflection point adjacent thereto
Absolute value.
Further, the threshold value is H/ (n+1) -0.5m, wherein difference in height of the H between contiguous floors, n are
Inflection point quantity between contiguous floors.
Further, the position of destination is determined according to the quantity of initial floor and inflection point, comprising:
The number of floor levels of initial floor and the height above sea level degree of initial floor and destination are determined according to running track figure
According to;
Initial floor and destination are confirmed according to the size between initial floor and the altitude data of destination
Between positional relationship;
The inflection point quantity between initial floor and destination is obtained according to running track figure;
According to the positional relationship and the inflection point between the number of floor levels, initial floor and destination of the initial floor
Quantity determines the number of floor levels of destination.
A kind of floor discriminating gear comprising:
Receiving module, it is described used for receiving the track data and barometrical altitude data of inertial navigator
Property navigator and barometer are co-located;
Replacement module, for the ordinate in the track data to be replaced with the altitude data, after replacement
Track data be defined as running track figure;
Module is obtained, for obtaining the inflection point of floor according to the running track figure;
Determining module, for determining the position of destination according to the quantity of initial floor and inflection point.
A kind of electronic equipment comprising processor, storage medium and computer program, the computer program are stored in
In storage medium, the computer program realizes above-mentioned floor method of discrimination when being executed by processor.
A kind of computer readable storage medium, is stored thereon with computer program, and the computer program is held by processor
Above-mentioned floor method of discrimination is realized when row.
A kind of floor method of discrimination, device, electronic equipment and storage medium of the invention, compared with the existing technology, this
Invention has following technical effect that
1, without carrying out the laying of network node and free from the influence of the external environment in target building in advance, need to only disappear
Anti- member carries inertial navigator and barometer can be completed the differentiation to floor locating for itself (especially have can not be pre- for fire
The property surveyed, data have stronger adaptability by the algorithm that the equipment carried with fireman provides, are not influenced by external condition).
2, structure is simple, easy to carry, is widely portable to existing fire-fighting and rescue work.Inertia entrained by fireman
Navigator is rectangular cubic, and size only cellular li-ion battery size, being embedded in will not be to fire-fighting in designed Special shoe pad
Member causes any added burden.
3, there is better stability.Due to the network equipment that under Fire Conditions, the prior art is powered by external power supply
It is easy to run out of steam, signal transmission can not be carried out, and hardware device used in the present invention is fire-fighting special equipment, it is not easy to by
It is influenced to external temperature environment.
Detailed description of the invention
Fig. 1 is the flow chart of the floor method of discrimination of the embodiment of the present invention one;
Fig. 2 is the effect picture of running track figure;
Fig. 3 is the dog-leg path figure in floor;
Fig. 4 is the structural block diagram of the floor discriminating gear of the embodiment of the present invention two;
Fig. 5 is the structural block diagram of the electronic equipment of the embodiment of the present invention three.
Specific embodiment
A kind of floor method of discrimination of the invention, device, electronic equipment and storage medium is described with reference to the drawings to carry out in detail
Thin description, protection scope of the present invention to be explained and illustrated.
Embodiment one
It please refers to shown in Fig. 1, a kind of floor method of discrimination comprising following steps:
110, receive inertial navigator track data and barometrical altitude data, the inertial navigator with
Barometer is co-located.
The track data of inertial navigator output is the point set of X, Y, Z coordinate formation, and barometer can export certain point
Altitude data, i.e. ordinate data.Inertial navigator and barometer is co-located both refers in the same fire-fighting
With member.Inertial navigator and barometer are all made of fire-fighting special equipment, these equipment are not easily susceptible to the shadow of external temperature environment
It rings, and small in size, can be carried by fireman, inertial navigator is rectangular cubic, and only cellular li-ion battery is big for size
Small, any added burden will not be caused to fireman by being embedded in designed Special shoe pad.
Receiving locus data and the equipment (referred to as receiving device) of altitude data can be intelligent terminal, such as hand
The mobile devices such as machine, PDA, plate are also possible to fireman's special-purpose terminal, can receive inertial navigator wirelessly
And barometrical related data.Receiving device can be fireman and carry, and be also possible to remote command center or scene
It is placed at command centre.
120, the ordinate in the track data is replaced with into the altitude data, by replaced track data
It is defined as running track figure.
After receiving device receives above-mentioned data, it is pre-processed.Due to the longitudinal movement height of inertial navigator
It is inaccurate, is replaced with barometrical data, therefore, pretreatment is exactly that the ordinate in track data is replaced with institute
Altitude data is stated, i.e., the altitude data of barometer output is replaced into the ordinate in track data, retouched for convenience
It states, replaced track data is defined as running track figure, running track figure is equivalent to the track data of inertial navigator more
It is accurate to add.
Finally, after pretreatment, receiving device can show running track figure, what display renderings were read
The track data of inertial navigator is shown as shown in Fig. 2, the number in Fig. 2 is the height above sea level of barometer mark.It needs to illustrate
, in order to ensure that receiving device receives inertial navigator and barometrical synchronism, can by inertial navigator with it is barometrical
Data transmission frequency is set as identical, such as average output per second is primary, it is of course also possible to be pre-processed according to acquisition time
Operation.
130, the inflection point of floor is obtained according to the running track figure.
People can generate dog-leg path shown in Fig. 3 in upper go downstairs, and when occurring such track in data, that is, can determine whether
Fireman reaches a certain layer.Therefore, it is necessary to identify inflection point all in track, inflection point here refers to the intermediate point of broken line.
Under normal circumstances, when the data of a string of same movement trend occur with movement tendency opposite before, then should
Point is inflection point.In other words, the movement tendency in the running track figure before and after inflection point is opposite, in fact stricti jurise and
It is opposite that speech, which is the motion track of X-axis,.For upstairs, the X axis coordinate of one section of lower section is gradually increased in Fig. 3, and on
The X axis coordinate of one section of side gradually decreases, therefore regarding as the point between two sections is inflection point.Certainly, if inflection point long enough,
On the basis of can then being changed by Y-axis, i.e., if X-axis or the data of Z axis persistently change, and the data of Y-axis continue 2s even with
On, then it is assumed that these points are inflection point.
In the case where setting acquisition X-axis every time or the data variation of Z axis in preferred embodiments of the present invention, corresponding Y
The value of axis is also to continue variation.Since the subtle movement of fireman is also possible to generate the different data of two sections of movement tendencies,
Therefore, inflection point is screened, avoids false judgment caused by above situation.
Point between above-mentioned different trend is first regarded as into doubtful inflection point, is then made the following judgment again: when target is doubtful
When the distance between inflection point doubtful inflection point adjacent thereto is not less than threshold value, then the doubtful inflection point of the target is inflection point.Wherein
The distance between the doubtful inflection point of target doubtful inflection point adjacent thereto is the corresponding height above sea level of the doubtful inflection point of target in running track figure
The absolute value of difference between the altitude information corresponding altitude data of doubtful inflection point adjacent thereto, threshold value here is pre-
If value is obtained by the quantity of input story height and floor gap inflection point, threshold value is H/ (n+1) -0.5m, wherein the H is phase
Difference in height between adjacent floors, inflection point quantity of the n between contiguous floors.
140, the position of destination is determined according to the quantity of initial floor and inflection point.
Specifically, the number of floor levels of initial floor and the height above sea level of initial floor and destination are determined according to running track figure
Altitude information;
Initial floor and destination are confirmed according to the size between initial floor and the altitude data of destination
Between positional relationship;
The inflection point quantity between initial floor and destination is obtained according to running track figure;
According to the positional relationship and the inflection point between the number of floor levels, initial floor and destination of the initial floor
Quantity determines the number of floor levels of destination.
Determine that the number of floor levels of destination can use following calculation formula:
N1=N0± ceil (m/ (n+1)), wherein N1For the number of floor levels of destination, N0For the number of floor levels of initial floor,
Fireman is needed to be inputted in advance according to place floor, it generally can be based on 1 layer.± it is to be selected as the case may be, such as
Fruit ± take plus, then illustrate downside of the initial floor between destination, if ± take and subtract, illustrate initial floor in target building
Upside between layer.Inflection point quantity of the m between initial floor and destination, ceil () are to round up.N is adjacent building
Inflection point quantity between layer generally has an inflection point between adjacent two floor, other do not have inflection point or setting multiple certainly
The case where inflection point, is also possible that.
For example, work as N0=5, n=1, m=1, and the altitude data of initial floor is less than the height above sea level of destination
Altitude information, then, and N1=6, similarly, when m=2, N16 are still equal to, is to reach layer 6 building when the difference of the two is m=1
Starting point (and terminal of layer 5), when m=2 are to reach layer 6 building.
By above embodiment, so that do not need to be laid with a large amount of network node in advance before fire-fighting and rescue, i.e., it is full
The instantaneity and unpredictability of sufficient fire-fighting and rescue, meanwhile, fireman only need carry a mobile device, Portable pneumatic meter and
Insole of the wearing containing inertial navigator is the floor that may know where oneself, and additional burden will not be brought to fireman.
Embodiment two
Embodiment two discloses a kind of floor discriminating gear of corresponding above-described embodiment, is the virtual bench of above-described embodiment
Structure, it is shown referring to figure 4., comprising:
Receiving module 210, it is described for receiving the track data and barometrical altitude data of inertial navigator
Inertial navigator is co-located with barometer;
Replacement module 220 will be replaced for the ordinate in the track data to be replaced with the altitude data
Track data afterwards is defined as running track figure;
Module 230 is obtained, for obtaining the inflection point of floor according to the running track figure;
Determining module 240, for determining the position of destination according to the quantity of initial floor and inflection point.
Further, the inertial navigator and barometer are respectively positioned on fireman.
As an implementation, the operation trend that module 230 includes: the running track figure before and after a certain position is obtained
On the contrary, then a certain position is inflection point.
As another embodiment, the operation that module 230 includes: the running track figure before and after a certain position is obtained to become
Gesture is on the contrary, then a certain position is denoted as doubtful inflection point;The doubtful inflection point is confirmed: when the doubtful inflection point of target is adjacent thereto
The distance between doubtful inflection point when being not less than threshold value, then the doubtful inflection point of the target is inflection point.Wherein, the target is doubtful
The distance between inflection point doubtful inflection point adjacent thereto is the corresponding altitude data of the doubtful inflection point of target in running track figure
The absolute value of difference between the corresponding altitude data of doubtful inflection point adjacent thereto;The threshold value is H/ (n+1)-
0.5m, wherein difference in height of the H between contiguous floors, inflection point quantity of the n between contiguous floors.
Further, it is determined that module 240, comprising: determine the number of floor levels of initial floor and initial according to running track figure
The altitude data of floor and destination;It is true according to the size between initial floor and the altitude data of destination
Recognize the positional relationship between initial floor and destination;It is obtained between initial floor and destination according to running track figure
Inflection point quantity;According to the positional relationship between the number of floor levels, initial floor and destination of the initial floor and described turn
Point quantity determines the number of floor levels of destination.
Embodiment three
Fig. 5 is the structural schematic diagram for a kind of electronic equipment that the embodiment of the present invention three provides, as shown in figure 5, the electronics is set
Standby includes processor 310, memory 320, input unit 330 and output device 340;The number of processor 310 in computer equipment
It measures and can be one or more, in Fig. 5 by taking a processor 310 as an example;Processor 310, memory 320 in electronic equipment,
Input unit 330 can be connected with output device 340 by bus or other modes, in Fig. 5 for being connected by bus.
Memory 320 is used as a kind of computer readable storage medium, can be used for storing software program, journey can be performed in computer
Sequence and module, if the corresponding program instruction/module of floor method of discrimination in the embodiment of the present invention is (for example, floor differentiates dress
Receiving module 210, replacement module 220, acquisition module 230 and determining module 240 in setting).Processor 310 passes through operation storage
Software program, instruction and module in memory 320, at the various function application and data of electronic equipment
Reason, that is, realize above-mentioned floor method of discrimination.
Memory 320 can mainly include storing program area and storage data area, wherein storing program area can store operation system
Application program needed for system, at least one function;Storage data area, which can be stored, uses created data etc. according to terminal.This
Outside, memory 320 may include high-speed random access memory, can also include nonvolatile memory, for example, at least one
Disk memory, flush memory device or other non-volatile solid state memory parts.In some instances, memory 320 can be into one
Step includes the memory remotely located relative to processor 310, these remote memories can be set by network connection to electronics
It is standby.The example of above-mentioned network includes but is not limited to internet, intranet, local area network, mobile radio communication and combinations thereof.
Input unit 330 can be used for receiving the subscriber identity information and primary data such as story height, floor of input
Between inflection point quantity etc..Output device 340 may include that display screen etc. shows equipment.
Example IV
The embodiment of the present invention four also provides a kind of storage medium comprising computer executable instructions, and the computer can be held
Row instruction is used to execute a kind of floor method of discrimination when being executed by computer processor, this method comprises:
Receive the track data and barometrical altitude data of inertial navigator, the inertial navigator and air pressure
It counts co-located;
Ordinate in the track data is replaced with into the altitude data, replaced track data is defined
For running track figure;
The inflection point of floor is obtained according to the running track figure;
The position of destination is determined according to the quantity of initial floor and inflection point.
Certainly, a kind of storage medium comprising computer executable instructions, computer provided by the embodiment of the present invention
The method operation that executable instruction is not limited to the described above can also be performed provided by any embodiment of the invention based on floor
Relevant operation in method of discrimination.
By the description above with respect to embodiment, it is apparent to those skilled in the art that, the present invention
It can be realized by software and required common hardware, naturally it is also possible to which by hardware realization, but in many cases, the former is more
Good embodiment.Based on this understanding, technical solution of the present invention substantially in other words contributes to the prior art
Part can be embodied in the form of software products, which can store in computer readable storage medium
In, floppy disk, read-only memory (Read-Only Memory, ROM), random access memory (Random such as computer
Access Memory, RAM), flash memory (FLASH), hard disk or CD etc., including some instructions use so that an electronic equipment
(can be mobile phone, personal computer, server or the network equipment etc.) executes method described in each embodiment of the present invention.
It is worth noting that, included each unit and module are only in the above-mentioned embodiment based on floor discriminating gear
It is to be divided according to the functional logic, but be not limited to the above division, as long as corresponding functions can be realized;Separately
Outside, the specific name of each functional unit is also only for convenience of distinguishing each other, the protection scope being not intended to restrict the invention.
According to the disclosure and teachings of the above specification, those skilled in the art in the invention can also be to above-mentioned embodiment party
Formula is changed and is modified.Therefore, the invention is not limited to the specific embodiments disclosed and described above, to of the invention
Some modifications and changes should also be as falling into the scope of the claims of the present invention.In addition, although being used in this specification
Some specific terms, these terms are merely for convenience of description, does not limit the present invention in any way.