SEGMENTING VIDEO STREAM FRAMES

The present invention extends to methods, systems, and computer program products for segmenting video stream frames. In one aspect, video stream frames are segmented into more relevant segments (e.g., including roadway) and less relevant segments (e.g., not including roadway). Different segments can be handled differently. For example, more relevant segments can be processed to identify vehicles, identify events, etc. and less relevant segments may be ignored. Accordingly, resources can be utilized more efficiently. In one aspect, a binary mask is generated from object data in one or more frames. The binary mask is applied to further frames blocking out less relevant frame segments in the further frames.

BACKGROUND

1. Background and Relevant Art

Entities (e.g., parents, guardians, friends, relatives, teachers, social workers, first responders, hospitals, delivery services, media outlets, government entities, etc.) may desire to be made aware of relevant events (e.g., fires, accidents, police presence, shootings, etc.) as close as possible to the events' occurrence. However, entities typically are not made aware of an event until after a person observes the event (or the event aftermath) and calls authorities.

In general, techniques that attempt to automate event detection are unreliable. Some techniques have attempted to mine social media data to detect the planning of events and forecast when events might occur. However, events can occur without prior planning and/or may not be detectable using social media data. Further, these techniques are not capable of meaningfully processing available data nor are these techniques capable of differentiating false data (e.g., hoax social media posts)

Other techniques use textual comparisons to compare textual content (e.g., keywords) in a data stream to event templates in a database. If text in a data stream matches keywords in an event template, the data stream is labeled as indicating an event.

Additional techniques use event specific sensors to detect specified types of event. For example, earthquake detectors can be used to detect earthquakes.

It may be that evidence of an event is contained in video. Video may be recorded video, for example, captured at a smart phone camera, that is uploaded in some way for viewing by others. Alternately, video can be live streaming video, for example, streaming from a smart phone camera, a traffic camera, another other public camera, or a private camera.

BRIEF SUMMARY

Examples extend to methods, systems, and computer program products for segmenting video stream frames.

A frame is accessed from a camera video stream. A first object color mask is generated from the contents of the frame. Generating a first object color mask includes detecting objects of a plurality of different object types in the frame. The detected objects include a first instance of an object type and a first instance of another object type. Generating a first object color mask includes assigning a different color to different objects in the frame based on object type. Assigning different colors includes assigning a first color to the first instance of the object type and assigning a second color to the first instance of the other object type.

Generating a first object color mask includes determining the first instance of the object type is within the first instance of the other object type. Generating a first object color mask includes re-assigning the second color to the first instance of the object type.

Another frame is accessed from the camera video stream. A second object color mask is generated from contents of the other frame. Generating a second object color mask includes detecting other objects of the plurality of the different object types in the other frame. The detected objects include a second instance of the object type and a second instance of the other object type. Generating a second object color mask includes assigning a different color to different objects in the other frame based on the object type. Assigning different colors includes assigning the first color to the second instance of the object type and assigning a second color to the second instance of the other object type.

Generating a second object color mask includes determining the second instance of the object type is within the second instance of the other object type. Generating a second object color mask includes re-assigning the second color to the second instance of the object type.

The first object color mask and the second object color mask are combined into an aggregate color mask. A binary mask is computed from the aggregate color mask. Computing the binary mask includes assigning a binary value of one to portions of the aggregate color mask having the second color value and assigning a binary value of zero to portions of the aggregate color mask having other color values. The binary mask is applied to a further frame from the camera video stream highlighting instances of the other object type in the further frame.

Additional features and advantages will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by practice. The features and advantages may be realized and obtained by means of the instruments and combinations particularly pointed out in the appended claims. These and other features and advantages will become more fully apparent from the following description and appended claims, or may be learned by practice as set forth hereinafter.

DETAILED DESCRIPTION

Examples extend to methods, systems, and computer program products for segmenting video stream frames.

When considering a video stream, it may be that some portions of the video stream are less relevant (and possibly irrelevant). For example, in a traffic camera video stream, portions including roadway may be more relevant and portions not including roadway may be less relevant. However, full frames of the video stream may none the less be processed even through portions of the frames are of limited (if any) relevance. Processing portions of a video stream having limited relevance is an inefficient use of resources. Processing portions of a video stream having limited relevance also makes tasks (e.g., event detection) more complex/difficult as there is more information to process and understand.

As such, aspects of the invention segment video stream frames. In one aspect, video stream frames are segmented into more relevant segments (e.g., including roadway) and less relevant segments (e.g., not including roadway). Different segments can be handled differently. For example, more relevant segments can be processed to identify vehicles, identify events, etc. and less relevant segments may be ignored. Accordingly, resources can be utilized more efficiently.

Implementations can comprise or utilize a special purpose or general-purpose computer including computer hardware, such as, for example, one or more computer and/or hardware processors (including any of Central Processing Units (CPUs), and/or Graphical Processing Units (GPUs), general-purpose GPUs (GPGPUs), Field Programmable Gate Arrays (FPGAs), application specific integrated circuits (ASICs), Tensor Processing Units (TPUs)) and system memory, as discussed in greater detail below. Implementations also include physical and other computer-readable media for carrying or storing computer-executable instructions and/or data structures. Such computer-readable media can be any available media that can be accessed by a general purpose or special purpose computer system. Computer-readable media that store computer-executable instructions are computer storage media (devices). Computer-readable media that carry computer-executable instructions are transmission media. Thus, by way of example, and not limitation, implementations can comprise at least two distinctly different kinds of computer-readable media: computer storage media (devices) and transmission media.

In one aspect, one or more processors are configured to execute instructions (e.g., computer-readable instructions, computer-executable instructions, etc.) to perform any of a plurality of described operations. The one or more processors can access information from system memory and/or store information in system memory. The one or more processors can (e.g., automatically) transform information between different formats, such as, for example, between any of: raw signals, social signals, Web signals, streaming signals, normalized signals, events, search terms, geo cell data, geo cell subsets, event notifications, video streams, frames, objects, objects types, assigned colors, color mappings, color masks, defined object relationships, object subsets, reassigned colors, aggregate color masks, binary masks, masked frames, etc.

System memory can be coupled to the one or more processors and can store instructions (e.g., computer-readable instructions, computer-executable instructions, etc.) executed by the one or more processors. The system memory can also be configured to store any of a plurality of other types of data generated and/or transformed by the described components, such as, for example, raw signals, social signals, Web signals, streaming signals, normalized signals, events, search terms, geo cell data, geo cell subsets, event notifications, video streams, frames, objects, objects types, assigned colors, color mappings, color masks, defined object relationships, object subsets, reassigned colors, aggregate color masks, binary masks, masked frames, etc.

Further, where appropriate, functions described herein can be performed in one or more of: hardware, software, firmware, digital components, or analog components. For example, one or more Field Programmable Gate Arrays (FPGAs) and/or one or more application specific integrated circuits (ASICs) and/or one or more Tensor Processing Units (TPUs) can be programmed to carry out one or more of the systems and procedures described herein. Hardware, software, firmware, digital components, or analog components can be specifically tailor-designed for a higher speed detection or artificial intelligence that can enable signal processing. In another example, computer code is configured for execution in one or more processors, and may include hardware logic/electrical circuitry controlled by the computer code. These example devices are provided herein purposes of illustration, and are not intended to be limiting. Embodiments of the present disclosure may be implemented in further types of devices.

A cloud computing model can be composed of various characteristics such as, for example, on-demand self-service, broad network access, resource pooling, rapid elasticity, measured service, and so forth. A cloud computing model can also expose various service models, such as, for example, Software as a Service (“SaaS”), Platform as a Service (“PaaS”), and Infrastructure as a Service (“IaaS”). A cloud computing model can also be deployed using different deployment models such as private cloud, community cloud, public cloud, hybrid cloud, and so forth. In this description and in the following claims, a “cloud computing environment” is an environment in which cloud computing is employed.

In this description and the following claims, a “geo cell” is defined as a piece of “cell” in a grid in any form. In one aspect, geo cells are arranged in a hierarchical structure. Cells of different geometries can be used.

A “geohash” is an example of a “geo cell”.

In this description and the following claims, “geohash” is defined as a geocoding system which encodes a geographic location into a short string of letters and digits. Geohash is a hierarchical spatial data structure which subdivides space into buckets of grid shape (e.g., a square). Geohashes offer properties like arbitrary precision and the possibility of gradually removing characters from the end of the code to reduce its size (and gradually lose precision). As a consequence of the gradual precision degradation, nearby places will often (but not always) present similar prefixes. The longer a shared prefix is, the closer the two places are. geo cells can be used as a unique identifier and to represent point data (e.g., in databases).

In one aspect, a “geohash” is used to refer to a string encoding of an area or point on the Earth. The area or point on the Earth may be represented (among other possible coordinate systems) as a latitude/longitude or Easting/Northing—the choice of which is dependent on the coordinate system chosen to represent an area or point on the Earth. geo cell can refer to an encoding of this area or point, where the geo cell may be a binary string comprised of 0s and 1s corresponding to the area or point, or a string comprised of 0s, 1s, and a ternary character (such as X)—which is used to refer to a don't care character (0 or 1). A geo cell can also be represented as a string encoding of the area or point, for example, one possible encoding is base-32, where every 5 binary characters are encoded as an ASCII character.

Depending on latitude, the size of an area defined at a specified geo cell precision can vary. In one example, as shown in Table 1. the areas defined at various geo cell precisions are approximately:

Other geo cell geometries can include hexagonal tiling, triangular tiling, and/or any other suitable geometric shape tiling. For example, the H3 geospatial indexing system can be a multi-precision hexagonal tiling of a sphere (e.g., the Earth) indexed with hierarchical linear indexes.

In another aspect, geo cells are a hierarchical decomposition of a sphere (such as the Earth) into representations of regions or points based a Hilbert curve (e.g., the S2 hierarchy or other hierarchies). Regions/points of the sphere can be projected into a cube and each face of the cube includes a quad-tree where the sphere point is projected into. After that, transformations can be applied and the space discretized. The geo cells are then enumerated on a Hilbert Curve (a space-filling curve that converts multiple dimensions into one dimension and preserves the approximate locality).

Due to the hierarchical nature of geo cells, any signal, event, entity, etc., associated with a geo cell of a specified precision is by default associated with any less precise geo cells that contain the geo cell. For example, if a signal is associated with a geo cell of precision 9, the signal is by default also associated with corresponding geo cells of precisions 1, 2, 3, 4, 5, 6, 7, and 8. Similar mechanisms are applicable to other tiling and geo cell arrangements. For example, S2 has a cell level hierarchy ranging from level zero (85,011,012 km2) to level 30 (between 0.48 cm2to 0.96 cm2).

Signal Ingestion and Normalization

Signal ingestion modules can ingest a variety of raw structured and/or raw unstructured signals on an on going basis and in essentially real-time. Raw signals can include social posts, live broadcasts, traffic camera feeds, other camera feeds (e.g., from other public cameras or from CCTV cameras), listening device feeds, 911 calls, weather data, planned events, IoT device data, crowd sourced traffic and road information, satellite data, air quality sensor data, smart city sensor data, public radio communication (e.g., among first responders and/or dispatchers, between air traffic controllers and pilots), subscription data services, etc.

Raw signals can include different data media types and different data formats, including social signals, Web signals, and streaming signals. Data media types can include audio, video, image, and text. Different formats can include text in XML, text in JavaScript Object Notation (JSON), text in RSS feed, plain text, video stream in Dynamic Adaptive Streaming over HTTP (DASH), video stream in HTTP Live Streaming (HLS), video stream in Real-Time Messaging Protocol (RTMP), other Multipurpose Internet Mail Extensions (MIME) types, etc. Handling different types and formats of data introduces inefficiencies into subsequent event detection processes, including when determining if different signals relate to the same event.

Accordingly, signal ingestion modules can normalize (e.g., prepare or pre-process) raw signals into normalized signals to increase efficiency and effectiveness of subsequent computing activities, such as, event detection, event notification, etc., that utilize the normalized signals. For example, signal ingestion modules can normalize raw signals into normalized signals having a Time, Location, and Context (TLC) dimensions. An event detection infrastructure can use the Time, Location, and Content dimensions to more efficiently and effectively detect events.

A Time (T) dimension can include a time of origin or alternatively a “event time” of a signal. A Location (L) dimension can include a location anywhere across a geographic area, such as, a country (e.g., the United States), a State, a defined area, an impacted area, an area defined by a geo cell, an address, etc.

A Context (C) dimension indicates circumstances surrounding formation/origination of a raw signal in terms that facilitate understanding and assessment of the raw signal. The Context (C) dimension of a raw signal can be derived from express as well as inferred signal features of the raw signal.

Per signal type and signal content, different normalization modules can be used to extract, derive, infer, etc. Time, Location, and Context dimensions from/for a raw signal. For example, one set of normalization modules can be configured to extract/derive/infer Time, Location and Context dimensions from/for social signals. Another set of normalization modules can be configured to extract/derive/infer Time, Location and Context dimensions from/for Web signals. A further set of normalization modules can be configured to extract/derive/infer Time, Location and Context dimensions from/for streaming signals.

Normalization modules for extracting/deriving/inferring Time, Location, and Context dimensions can include text processing modules, NLP modules, image processing modules, video processing modules, etc. The modules can be used to extract/derive/infer data representative of Time, Location, and Context dimensions for a signal. Time, Location, and Context dimensions for a signal can be extracted/derived/inferred from metadata and/or content of the signal.

For example, NLP modules can analyze metadata and content of a sound clip to identify a time, location, and keywords (e.g., fire, shooter, etc.). An acoustic listener can also interpret the meaning of sounds in a sound clip (e.g., a gunshot, vehicle collision, etc.) and convert to relevant context. Live acoustic listeners can determine the distance and direction of a sound. Similarly, image processing modules can analyze metadata and pixels in an image to identify a time, location and keywords (e.g., fire, shooter, etc.). Image processing modules can also interpret the meaning of parts of an image (e.g., a person holding a gun, flames, a store logo, etc.) and convert to relevant context. Other modules can perform similar operations for other types of content including text and video.

Per signal type, each set of normalization modules can differ but may include at least some similar modules or may share some common modules. For example, similar (or the same) image analysis modules can be used to extract named entities from social signal images and public camera feeds. Likewise, similar (or the same) NLP modules can be used to extract named entities from social signal text and web text.

In some aspects, an ingested signal includes sufficient expressly defined time, location, and context information upon ingestion. The expressly defined time, location, and context information is used to determine Time, Location, and Context dimensions for the ingested signal. In other aspects, an ingested signal lacks expressly defined location information or expressly defined location information is insufficient (e.g., lacks precision) upon ingestion. In these other aspects, Location dimension or additional Location dimension can be inferred from features of an ingested signal and/or through references to other data sources. In further aspects, an ingested signal lacks expressly defined context information or expressly defined context information is insufficient (e.g., lacks precision) upon ingestion. In these further aspects, Context dimension or additional Context dimension can be inferred from features of an ingested signal and/or through reference to other data sources.

In further aspects, time information may not be included, or included time information may not be given with high enough precision and Time dimension is inferred. For example, a user may post an image to a social network which had been taken some indeterminate time earlier.

Normalization modules can use named entity recognition and reference to a geo cell database to infer Location dimension. Named entities can be recognized in text, images, video, audio, or sensor data. The recognized named entities can be compared to named entities in geo cell entries. Matches indicate possible signal origination in a geographic area defined by a geo cell.

As such, a normalized signal can include a Time dimension, a Location dimension, a Context dimension (e.g., single source probabilities and probability details), a signal type, a signal source, and content.

A single source probability can be calculated by single source classifiers (e.g., machine learning models, artificial intelligence, neural networks, statistical models, etc.) that consider hundreds, thousands, or even more signal features (dimensions) of a signal. Single source classifiers can be based on binary models and/or multi-class models.

FIG. 1Adepicts part of computer architecture100that facilitates ingesting and normalizing signals. As depicted, computer architecture100includes signal ingestion modules101, social signals171, Web signals172, and streaming signals173. Signal ingestion modules101, social signals171, Web signals172, and streaming signals173can be connected to (or be part of) a network, such as, for example, a system bus, a Local Area Network (“LAN”), a Wide Area Network (“WAN”), and even the Internet. Accordingly, signal ingestion modules101, social signals171, Web signals172, and streaming signals173as well as any other connected computer systems and their components can create and exchange message related data (e.g., Internet Protocol (“IP”) datagrams and other higher layer protocols that utilize IP datagrams, such as, Transmission Control Protocol (“TCP”), Hypertext Transfer Protocol (“HTTP”), Simple Mail Transfer Protocol (“SMTP”), Simple Object Access Protocol (SOAP), etc. or using other non-datagram protocols) over the network.

Signal ingestion module(s)101can ingest raw signals121, including social signals171, web signals172, and streaming signals173, on an on going basis and in essentially real-time. Raw signals121can include social posts, recorded videos, streaming videos, traffic camera feeds, other camera feeds, listening device feeds, 911 calls, weather data, planned events, IoT device data, crowd sourced traffic and road information, satellite data, air quality sensor data, smart city sensor data, public radio communication, subscription data service data, etc. As such, potentially thousands, millions or even billions of unique raw signals, each with unique characteristics, are can be ingested and used determine event characteristics, such as, event truthfulness, event severity, event category or categories, etc.

Signal ingestion module(s)101include social content ingestion modules174, web content ingestion modules176, stream content ingestion modules176, and signal formatter180. Signal formatter180further includes social signal processing module181, web signal processing module182, and stream signal processing modules183.

For each type of signal, a corresponding ingestion module and signal processing module can interoperate to normalize the signal into a Time, Location, Context (TLC) dimensions. For example, social content ingestion modules174and social signal processing module181can interoperate to normalize social signals171into TLC dimensions. Similarly, web content ingestion modules176and web signal processing module182can interoperate to normalize web signals172into TLC dimensions. Likewise, stream content ingestion modules176and stream signal processing modules183can interoperate to normalize streaming signals173into TLC dimensions.

In one aspect, signal content exceeding specified size requirements (e.g., audio or video) is cached upon ingestion. Signal ingestion modules101include a URL or other identifier to the cached content within the context for the signal.

In one aspect, signal formatter180includes modules for determining a single source probability as a ratio of signals turning into events based on the following signal properties: (1) event class (e.g., fire, accident, weather, etc.), (2) media type (e.g., text, image, audio, etc.), (3) source (e.g., twitter, traffic camera, first responder radio traffic, etc.), and (4) geo type (e.g., geo cell, region, or non-geo). Probabilities can be stored in a lookup table for different combinations of the signal properties. Features of a signal can be derived and used to query the lookup table. For example, the lookup table can be queried with terms (“accident”, “image”, “twitter”, “region”). The corresponding ratio (probability) can be returned from the table.

In another aspect, signal formatter180includes a plurality of single source classifiers (e.g., artificial intelligence, machine learning modules, neural networks, etc.). Each single source classifier can consider hundreds, thousands, or even more signal features (dimensions) of a signal. Signal features of a signal can be derived and submitted to a signal source classifier. The single source classifier can return a probability that a signal indicates a type of event. Single source classifiers can be binary classifiers or multi-source classifiers.

Raw classifier output can be adjusted to more accurately represent a probability that a signal is a “true positive”. For example, 1,000 signals whose raw classifier output is 0.9 may include 80% as true positives. Thus, probability can be adjusted to 0.8 to reflect true probability of the signal being a true positive. “Calibration” can be done in such a way that for any “calibrated score” this score reflects the true probability of a true positive outcome.

Signal ingestion modules101can insert one or more single source probabilities and corresponding probability details into a normalized signal to represent a Context (C) dimension. Probability details can indicate a probabilistic model and features used to calculate the probability. In one aspect, a probabilistic model and signal features are contained in a hash field.

Signal ingestion modules101can access “transdimensionality” transformations structured and defined in a “TLC” dimensional model. Signal ingestion modules101can apply the “transdimensionality” transformations to generic source data in raw signals to re-encode the source data into normalized data having lower dimensionality. Dimensionality reduction can include reducing dimensionality (e.g., hundreds, thousands, or even more signal features (dimensions)) of a raw signal into a normalized signal including a T vector, an L vector, and a C vector. At lower dimensionality, the complexity of measuring “distances” between dimensional vectors across different normalized signals is reduced.

Thus, in general, any received raw signals can be normalized into normalized signals including a Time (T) dimension, a Location (L) dimension, a Context (C) dimension, signal source, signal type, and content. Signal ingestion modules101can send normalized signals122to event detection infrastructure103.

FIG. 2illustrates a flow chart of an example method200for normalizing ingested signals. Method200will be described with respect to the components and data in computer architecture100.

Method200includes ingesting a raw signal including a time stamp, an indication of a signal type, an indication of a signal source, and content (201). For example, signal ingestion modules101can ingest a raw signal121from one of: social signals171, web signals172, or streaming signals173.

Method200includes forming a normalized signal from characteristics of the raw signal (202). For example, signal ingestion modules101can form a normalized signal122A from the ingested raw signal121.

Forming a normalized signal includes forwarding the raw signal to ingestion modules matched to the signal type and/or the signal source (203). For example, if ingested raw signal121is from social signals171, raw signal121can be forwarded to social content ingestion modules174and social signal processing modules181. If ingested raw signal121is from web signals172, raw signal121can be forwarded to web content ingestion modules175and web signal processing modules182. If ingested raw signal121is from streaming signals173, raw signal121can be forwarded to streaming content ingestion modules176and streaming signal processing modules183.

Forming a normalized signal includes determining a time dimension associated with the raw signal from the time stamp (204). For example, signal ingestion modules101can determine time123A from a time stamp in ingested raw signal121.

Forming a normalized signal includes determining a location dimension associated with the raw signal from one or more of: location information included in the raw signal or from location annotations inferred from signal characteristics (205). For example, signal ingestion modules101can determine location124A from location information included in raw signal121or from location annotations derived from characteristics of raw signal121(e.g., signal source, signal type, signal content).

Forming a normalized signal includes determining a context dimension associated with the raw signal from one or more of: context information included in the raw signal or from context signal annotations inferred from signal characteristics (206). For example, signal ingestion modules101can determine context126A from context information included in raw signal121or from context annotations derived from characteristics of raw signal121(e.g., signal source, signal type, signal content).

Forming a normalized signal includes inserting the time dimension, the location dimension, and the context dimension in the normalized signal (207). For example, signal ingestion modules101can insert time123A, location124A, and context126A in normalized signal122. Method200includes sending the normalized signal to an event detection infrastructure (208). For example, signal ingestion modules101can send normalized signal122A to event detection infrastructure103.

FIGS. 3A, 3B, and 3Cdepict other example components that can be included in signal ingestion modules101. Signal ingestion modules101can include signal transformers for different types of signals including signal transformer301A (for TLC signals), signal transformer301B (for TL signals), and signal transformer301C (for T signals). In one aspect, a single module combines the functionality of multiple different signal transformers.

Signal ingestion modules101can also include location services302, classification tag service306, signal aggregator308, context inference module312, and location inference module316. Location services302, classification tag service306, signal aggregator308, context inference module312, and location inference module316or parts thereof can interoperate with and/or be integrated into any of ingestion modules174, web content ingestion modules176, stream content ingestion modules176, social signal processing module181, web signal processing module182, and stream signal processing modules183. Location services302, classification tag service306, signal aggregator308, context inference module312, and location inference module316can interoperate to implement “transdimensionality” transformations to reduce raw signal dimensionality into normalized TLC signals.

Signal ingestion modules101can also include storage for signals in different stages of normalization, including TLC signal storage307, TL signal storage311, T signal storage313, TC signal storage314, and aggregated TLC signal storage309. In one aspect, data ingestion modules101implement a distributed messaging system. Each of signal storage307,309,311,313, and314can be implemented as a message container (e.g., a topic) associated with a type of message.

FIG. 4illustrates a flow chart of an example method400for normalizing an ingested signal including time information, location information, and context information. Method400will be described with respect to the components and data inFIG. 3A.

Method400includes accessing a raw signal including a time stamp, location information, context information, an indication of a signal type, an indication of a signal source, and content (401). For example, signal transformer301A can access raw signal221A. Raw signal221A includes timestamp231A, location information232A (e.g., lat/lon, GPS coordinates, etc.), context information233A (e.g., text expressly indicating a type of event), signal type227A (e.g., social media, 911 communication, traffic camera feed, etc.), signal source228A (e.g., Facebook, twitter, Waze, etc.), and signal content229A (e.g., one or more of: image, video, text, keyword, locale, etc.).

Method400includes determining a Time dimension for the raw signal (402). For example, signal transformer301A can determine time223A from timestamp231A.

Method400includes determining a Location dimension for the raw signal (403). For example, signal transformer301A sends location information232A to location services302. Geo cell service303can identify a geo cell corresponding to location information232A. Market service304can identify a designated market area (DMA) corresponding to location information232A. Location services302can include the identified geo cell and/or DMA in location224A. Location services302return location224A to signal transformer301.

Method400includes determining a Context dimension for the raw signal (404). For example, signal transformer301A sends context information233A to classification tag service306. Classification tag service306identifies one or more classification tags226A (e.g., fire, police presence, accident, natural disaster, etc.) from context information233A. Classification tag service306returns classification tags226A to signal transformer301A.

Method400includes inserting the Time dimension, the Location dimension, and the Context dimension in a normalized signal (405). For example, signal transformer301A can insert time223A, location224A, and tags226A in normalized signal222A (a TLC signal). Method400includes storing the normalized signal in signal storage (406). For example, signal transformer301A can store normalized signal222A in TLC signal storage307. (Although not depicted, timestamp231A, location information232A, and context information233A can also be included (or remain) in normalized signal222A).

Method400includes storing the normalized signal in aggregated storage (406). For example, signal aggregator308can aggregate normalized signal222A along with other normalized signals determined to relate to the same event. In one aspect, signal aggregator308forms a sequence of signals related to the same event. Signal aggregator308stores the signal sequence, including normalized signal222A, in aggregated TLC storage309and eventually forwards the signal sequence to event detection infrastructure103.

FIG. 5illustrates a flow chart of an example method500for normalizing an ingested signal including time information and location information. Method500will be described with respect to the components and data inFIG. 3B.

Method500includes determining a Time dimension for the raw signal (502). For example, signal transformer301B can determine time223B from timestamp231B.

Method500includes determining a Location dimension for the raw signal (503). For example, signal transformer301B sends location information232B to location services302. Geo cell service303can be identify a geo cell corresponding to location information232B. Market service304can identify a designated market area (DMA) corresponding to location information232B. Location services302can include the identified geo cell and/or DMA in location224B. Location services302returns location224B to signal transformer301.

Method500includes inserting the Time dimension and Location dimension into a signal (504). For example, signal transformer301B can insert time223B and location224B into TL signal236B. (Although not depicted, timestamp231B and location information232B can also be included (or remain) in TL signal236B). Method500includes storing the signal, along with the determined Time dimension and Location dimension, to a Time, Location message container (505). For example, signal transformer301B can store TL signal236B to TL signal storage311. Method500includes accessing the signal from the Time, Location message container (506). For example, signal aggregator308can access TL signal236B from TL signal storage311.

Method500includes inferring context annotations based on characteristics of the signal (507). For example, context inference module312can access TL signal236B from TL signal storage311. Context inference module312can infer context annotations241from characteristics of TL signal236B, including one or more of: time223B, location224B, type227B, source228B, and content229B. In one aspect, context inference module312includes one or more of: NLP modules, audio analysis modules, image analysis modules, video analysis modules, etc. Context inference module312can process content229B in view of time223B, location224B, type227B, source228B, to infer context annotations241(e.g., using machine learning, artificial intelligence, neural networks, machine classifiers, etc.). For example, if content229B is an image that depicts flames and a fire engine, context inference module312can infer that content229B is related to a fire. Context inference312module can return context annotations241to signal aggregator308.

Method500includes appending the context annotations to the signal (508). For example, signal aggregator308can append context annotations241to TL signal236B. Method500includes looking up classification tags corresponding to the classification annotations (509). For example, signal aggregator308can send context annotations241to classification tag service306. Classification tag service306can identify one or more classification tags226B (a Context dimension) (e.g., fire, police presence, accident, natural disaster, etc.) from context annotations241. Classification tag service306returns classification tags226B to signal aggregator308.

Method500includes inserting the classification tags in a normalized signal (510). For example, signal aggregator308can insert tags226B (a Context dimension) into normalized signal222B (a TLC signal). Method500includes storing the normalized signal in aggregated storage (511). For example, signal aggregator308can aggregate normalized signal222B along with other normalized signals determined to relate to the same event. In one aspect, signal aggregator308forms a sequence of signals related to the same event. Signal aggregator308stores the signal sequence, including normalized signal222B, in aggregated TLC storage309and eventually forwards the signal sequence to event detection infrastructure103. (Although not depicted, timestamp231B, location information232C, and context annotations241can also be included (or remain) in normalized signal222B).

FIG. 6illustrates a flow chart of an example method600for normalizing an ingested signal including time information and location information. Method600will be described with respect to the components and data inFIG. 3C.

Method600includes accessing a raw signal including a time stamp, an indication of a signal type, an indication of a signal source, and content (601). For example, signal transformer301C can access raw signal221C. Raw signal221C includes timestamp231C, signal type227C (e.g., social media, 911 communication, traffic camera feed, etc.), signal source228C (e.g., Facebook, twitter, Waze, etc.), and signal content229C (e.g., one or more of: image, video, text, keyword, locale, etc.).

Method600includes determining a Time dimension for the raw signal (602). For example, signal transformer301C can determine time223C from timestamp231C. Method600includes inserting the Time dimension into a T signal (603). For example, signal transformer301C can insert time223C into T signal234C. (Although not depicted, timestamp231C can also be included (or remain) in T signal234C).

Method600includes storing the T signal, along with the determined Time dimension, to a Time message container (604). For example, signal transformer301C can store T signal236C to T signal storage313. Method600includes accessing the T signal from the Time message container (605). For example, signal aggregator308can access T signal234C from T signal storage313.

Method600includes inferring context annotations based on characteristics of the T signal (606). For example, context inference module312can access T signal234C from T signal storage313. Context inference module312can infer context annotations242from characteristics of T signal234C, including one or more of: time223C, type227C, source228C, and content229C. As described, context inference module312can include one or more of: NLP modules, audio analysis modules, image analysis modules, video analysis modules, etc. Context inference module312can process content229C in view of time223C, type227C, source228C, to infer context annotations242(e.g., using machine learning, artificial intelligence, neural networks, machine classifiers, etc.). For example, if content229C is a video depicting two vehicles colliding on a roadway, context inference module312can infer that content229C is related to an accident. Context inference312module can return context annotations242to signal aggregator308.

Method600includes appending the context annotations to the T signal (607). For example, signal aggregator308can append context annotations242to T signal234C. Method600includes looking up classification tags corresponding to the classification annotations (608). For example, signal aggregator308can send context annotations242to classification tag service306. Classification tag service306can identify one or more classification tags226C (a Context dimension) (e.g., fire, police presence, accident, natural disaster, etc.) from context annotations242. Classification tag service306returns classification tags226C to signal aggregator308.

Method600includes inserting the classification tags into a TC signal (609). For example, signal aggregator308can insert tags226C into TC signal237C. Method600includes storing the TC signal to a Time, Context message container (610). For example, signal aggregator308can store TC signal237C in TC signal storage314. (Although not depicted, timestamp231C and context annotations242can also be included (or remain) in normalized signal237C).

Method600includes inferring location annotations based on characteristics of the TC signal (611). For example, location inference module316can access TC signal237C from TC signal storage314. Location inference module316can include one or more of: NLP modules, audio analysis modules, image analysis modules, video analysis modules, etc. Location inference module316can process content229C in view of time223C, type227C, source228C, and classification tags226C (and possibly context annotations242) to infer location annotations243(e.g., using machine learning, artificial intelligence, neural networks, machine classifiers, etc.). For example, if content229C is a video depicting two vehicles colliding on a roadway, the video can include a nearby street sign, business name, etc. Location inference module316can infer a location from the street sign, business name, etc. Location inference module316can return location annotations243to signal aggregator308.

Method600includes appending the location annotations to the TC signal with location annotations (612). For example, signal aggregator308can append location annotations243to TC signal237C. Method600determining a Location dimension for the TC signal (613). For example, signal aggregator308can send location annotations243to location services302. Geo cell service303can identify a geo cell corresponding to location annotations243. Market service304can identify a designated market area (DMA) corresponding to location annotations243. Location services302can include the identified geo cell and/or DMA in location224C. Location services302returns location224C to signal aggregation services308.

Method600includes inserting the Location dimension into a normalized signal (614). For example, signal aggregator308can insert location224C into normalized signal222C. Method600includes storing the normalized signal in aggregated storage (615). For example, signal aggregator308can aggregate normalized signal222C along with other normalized signals determined to relate to the same event. In one aspect, signal aggregator308forms a sequence of signals related to the same event. Signal aggregator308stores the signal sequence, including normalized signal222C, in aggregated TLC storage309and eventually forwards the signal sequence to event detection infrastructure103. (Although not depicted, timestamp231B, context annotations241, and location annotations24, can also be included (or remain) in normalized signal222B).

In another aspect, a Location dimension is determined prior to a Context dimension when a T signal is accessed. A Location dimension (e.g., geo cell and/or DMA) and/or location annotations are used when inferring context annotations.

Accordingly, location services302can identify a geo cell and/or DMA for a signal from location information in the signal and/or from inferred location annotations. Similarly, classification tag service306can identify classification tags for a signal from context information in the signal and/or from inferred context annotations.

Signal aggregator308can concurrently handle a plurality of signals in a plurality of different stages of normalization. For example, signal aggregator308can concurrently ingest and/or process a plurality T signals, a plurality of TL signals, a plurality of TC signals, and a plurality of TLC signals. Accordingly, aspects of the invention facilitate acquisition of live, ongoing forms of data into an event detection system with signal aggregator308acting as an “air traffic controller” of live data. Signals from multiple sources of data can be aggregated and normalized for a common purpose (e.g., of event detection). Data ingestion, event detection, and event notification can process data through multiple stages of logic with concurrency.

As such, a unified interface can handle incoming signals and content of any kind. The interface can handle live extraction of signals across dimensions of time, location, and context. In some aspects, heuristic processes are used to determine one or more dimensions. Acquired signals can include text and images as well as live-feed binaries, including live media in audio, speech, fast still frames, video streams, etc.

Signal normalization enables the world's live signals to be collected at scale and analyzed for detection and validation of live events happening globally. A data ingestion and event detection pipeline aggregates signals and combines detections of various strengths into truthful events. Thus, normalization increases event detection efficiency facilitating event detection closer to “live time” or at “moment zero”.

Event Detection

Turning back toFIG. 1B, computer architecture100also includes components that facilitate detecting events. As depicted, computer architecture100includes geo cell database111and event notification116. Geo cell database111and event notification116can be connected to (or be part of) a network with signal ingestion modules101and event detection infrastructure103. As such, geo cell database111and even notification116can create and exchange message related data over the network.

As described, in general, on an ongoing basis, concurrently with signal ingestion (and also essentially in real-time), event detection infrastructure103detects different categories of (planned and unplanned) events (e.g., fire, police response, mass shooting, traffic accident, natural disaster, storm, active shooter, concerts, protests, etc.) in different locations (e.g., anywhere across a geographic area, such as, the United States, a State, a defined area, an impacted area, an area defined by a geo cell, an address, etc.), at different times from Time, Location, and Context dimensions included in normalized signals. Since, normalized signals are normalized to include Time, Location, and Context dimensions, event detection infrastructure103can handle normalized signals in a more uniform manner increasing event detection efficiency and effectiveness.

Event detection infrastructure103can also determine an event truthfulness, event severity, and an associated geo cell. In one aspect, a Context dimension in a normalized signal increases the efficiency and effectiveness of determining truthfulness, severity, and an associated geo cell.

Generally, an event truthfulness indicates how likely a detected event is actually an event (vs. a hoax, fake, misinterpreted, etc.). Truthfulness can range from less likely to be true to more likely to be true. In one aspect, truthfulness is represented as a numerical value, such as, for example, from 1 (less truthful) to 10 (more truthful) or as percentage value in a percentage range, such as, for example, from 0% (less truthful) to 100% (more truthful). Other truthfulness representations are also possible. For example, truthfulness can be a dimension or represented by one or more vectors.

Generally, an event severity indicates how severe an event is (e.g., what degree of badness, what degree of damage, etc. is associated with the event). Severity can range from less severe (e.g., a single vehicle accident without injuries) to more severe (e.g., multi vehicle accident with multiple injuries and a possible fatality). As another example, a shooting event can also range from less severe (e.g., one victim without life threatening injuries) to more severe (e.g., multiple injuries and multiple fatalities). In one aspect, severity is represented as a numerical value, such as, for example, from 1 (less severe) to 5 (more severe). Other severity representations are also possible. For example, severity can be a dimension or represented by one or more vectors.

In general, event detection infrastructure103can include a geo determination module including modules for processing different kinds of content including location, time, context, text, images, audio, and video into search terms. The geo determination module can query a geo cell database with search terms formulated from normalized signal content. The geo cell database can return any geo cells having matching supplemental information. For example, if a search term includes a street name, a subset of one or more geo cells including the street name in supplemental information can be returned to the event detection infrastructure.

Event detection infrastructure103can use the subset of geo cells to determine a geo cell associated with an event location. Events associated with a geo cell can be stored back into an entry for the geo cell in the geo cell database. Thus, over time an historical progression of events within a geo cell can be accumulated.

As such, event detection infrastructure103can assign an event ID, an event time, an event location, an event category, an event description, an event truthfulness, and an event severity to each detected event. Detected events can be sent to relevant entities, including to mobile devices, to computer systems, to APIs, to data storage, etc.

Event detection infrastructure103detects events from information contained in normalized signals122. Event detection infrastructure103can detect an event from a single normalized signal122or from multiple normalized signals122. In one aspect, event detection infrastructure103detects an event based on information contained in one or more normalized signals122. In another aspect, event detection infrastructure103detects a possible event based on information contained in one or more normalized signals122. Event detection infrastructure103then validates the potential event as an event based on information contained in one or more other normalized signals122.

As depicted, event detection infrastructure103includes geo determination module104, categorization module106, truthfulness determination module107, and severity determination module108.

Generally, geo determination module104can include NLP modules, image analysis modules, etc. for identifying location information from a normalized signal. Geo determination module104can formulate (e.g., location) search terms141by using NLP modules to process audio, using image analysis modules to process images and video frames, etc. Search terms can include street addresses, building names, landmark names, location names, school names, image fingerprints, etc. Event detection infrastructure103can use a URL or identifier to access cached content when appropriate.

Generally, categorization module106can categorize a detected event into one of a plurality of different categories (e.g., fire, police response, mass shooting, traffic accident, natural disaster, storm, active shooter, concerts, protests, etc.) based on the content of normalized signals used to detect and/or otherwise related to an event.

Generally, truthfulness determination module107can determine the truthfulness of a detected event based on one or more of: source, type, age, and content of normalized signals used to detect and/or otherwise related to the event. Some signal types may be inherently more reliable than other signal types. For example, video from a live traffic camera feed may be more reliable than text in a social media post. Some signal sources may be inherently more reliable than others. For example, a social media account of a government agency may be more reliable than a social media account of an individual. The reliability of a signal can decay over time.

Generally, severity determination module108can determine the severity of a detected event based on or more of: location, content (e.g., dispatch codes, keywords, etc.), and volume of normalized signals used to detect and/or otherwise related to an event. Events at some locations may be inherently more severe than events at other locations. For example, an event at a hospital is potentially more severe than the same event at an abandoned warehouse. Event category can also be considered when determining severity. For example, an event categorized as a “Shooting” may be inherently more severe than an event categorized as “Police Presence” since a shooting implies that someone has been injured.

Geo cell database111includes a plurality of geo cell entries. Each geo cell entry is included in a geo cell defining an area and corresponding supplemental information about things included in the defined area. The corresponding supplemental information can include latitude/longitude, street names in the area defined by and/or beyond the geo cell, businesses in the area defined by the geo cell, other Areas of Interest (AOIs) (e.g., event venues, such as, arenas, stadiums, theaters, concert halls, etc.) in the area defined by the geo cell, image fingerprints derived from images captured in the area defined by the geo cell, and prior events that have occurred in the area defined by the geo cell. For example, geo cell entry151includes geo cell152, lat/lon153, streets154, businesses155, AOIs156, and prior events157. Each event in prior events157can include a location (e.g., a street address), a time (event occurrence time), an event category, an event truthfulness, an event severity, and an event description. Similarly, geo cell entry161includes geo cell162, lat/lon163, streets164, businesses165, AOIs166, and prior events167. Each event in prior events167can include a location (e.g., a street address), a time (event occurrence time), an event category, an event truthfulness, an event severity, and an event description.

Other geo cell entries can include the same or different (more or less) supplemental information, for example, depending on infrastructure density in an area. For example, a geo cell entry for an urban area can contain more diverse supplemental information than a geo cell entry for an agricultural area (e.g., in an empty field).

Geo cell database111can store geo cell entries in a hierarchical arrangement based on geo cell precision. As such, geo cell information of more precise geo cells is included in the geo cell information for any less precise geo cells that include the more precise geo cell.

Geo determination module104can query geo cell database111with search terms141. Geo cell database111can identify any geo cells having supplemental information that matches search terms141. For example, if search terms141include a street address and a business name, geo cell database111can identify geo cells having the street name and business name in the area defined by the geo cell. Geo cell database111can return any identified geo cells to geo determination module104in geo cell subset142.

Geo determination module can use geo cell subset142to determine the location of event135and/or a geo cell associated with event135. As depicted, event135includes event ID132, time133, location137, description136, category137, truthfulness138, and severity139.

Event detection infrastructure103can also determine that event135occurred in an area defined by geo cell162(e.g., a geohash having precision of level 7 or level 9). For example, event detection infrastructure103can determine that location134is in the area defined by geo cell162. As such, event detection infrastructure103can store event135in events167(i.e., historical events that have occurred in the area defined by geo cell162).

Event detection infrastructure103can also send event135to event notification module116. Event notification module116can notify one or more entities about event135.

Segmenting Video Stream Frames

FIGS. 7A-7Edepict a computer architecture700that facilitates segmenting video stream frames. As depicted, computer architecture700includes color mask generator701, color mask aggregator707, binary mask generator708, and binary mask application module709. Color mask generator701further includes object detector702, color assignment module703, subset detector704, and color reassignment module706.

In general, color mask generator101is configured to receive a video stream frame and generate a corresponding video stream frame color mask. Object detector702can detect object types in a video stream frame including but not limited to: roadway portions, vehicles, trees, bushes, guard rails, signs, walls, buildings, sky, etc. Each object type can be associated with a corresponding different defined color. Color assignment module703can assign defined colors to identified objects based on object type. For example, color assignment module703can assign one color to vehicles, a another color to roadway portions, a further color to the sky, etc.

Subset detector704can detect subsets of one object type that have a defined relationship with another object type. For example, subset detector704can detect one or more vehicles within a roadway portion. Color reassignment module706can reassign colors of an object type based on a defined relationship. For example, for any vehicles within a roadway, color reassignment module706can reassign a color assigned to vehicles to a color assigned to a roadway. That is, vehicles in a roadway can be assigned the same color as the roadway.

Color mask aggregator707can aggregate a plurality of video stream frame color masks into an aggregate (e.g., average) color mask. Binary mask generator can generate a binary mask for a video stream from an aggregate color mask. In one aspect, any pixels assigned the color of a particular object type (e.g., roadway portions) are assigned a “1” and pixels assigned colors of any other object type are assigned a “0” (absence of information).

Binary mask application module709can apply a binary mask to subsequent video stream frames to mask out objects other than the particular object type (e.g., that is more likely to be relevant during further processing). For example, a binary mask can be applied to a video stream frame to mask out objects other than roadways. Subsequent processing of the video stream frame can be limited to the particular object type. (e.g., to the roadway). As such, resources are not consumed processing parts of video stream frames unlikely to yield meaningful (e.g., relevant) results.

FIGS. 7B-7Emore specifically depict using the modules of computer architecture700to segment video stream frames.FIG. 8is a flow chart of an example method800for segmenting a video stream frame. Method800will be described with respect to the components and data in computer architecture700.

Method800includes accessing a plurality of frames from a video stream (801). Camera721(e.g., a traffic camera or other public camera) can stream video stream731. Color mask generator701can access frames732A,732B, . . .732m, etc. from video stream731.

Color mask generator701can process video stream731on a per frame basis. As such, for each of the plurality of frames, method800includes detecting a plurality of different object types in the frame (802). For example, inFIG. 7B, object detector702can detect objects711A and711B in frame732A. Object detector702can determine that object711A is of object type712(e.g., a roadway or roadway portion). Object detector702can determine that object711B is of object type713(e.g., a vehicle, such as, a truck, a car, a bus, a van, a motorcycle, etc.)

For each of the plurality of frames, method800includes assigning colors to objects in the frame based on detected object type (803). Color assignment module703can refer to color mappings717. Color mappings717can define mappings between object types and corresponding colors. For example, a roadway object type can be mapped to gray, a vehicle object type can be mapped to darker blue, a sky object type can be mapped to lighter blue, tree and bush object types can be mapped to green, etc. Accordingly, color assignment module703can assign color714(e.g., gray) to object711A and can assign color716(e.g., darker blue) to object711B.

For each of the plurality of frames, method800includes generating an object color mask from contents of the frame based on the assigned colors (804). For example, color mask generator701can generate color mask728A (a color mask corresponding to video stream731), including objects711A,712A, etc. In one aspect, color mask728A is sent to color mask aggregator707. In another aspect, color mask728A is sent to subset detector704.

Similarly, turning toFIG. 7C, object detector702can detect objects711C and711D in frame732B. Object detector702can determine that object711C is of object type712(e.g., a roadway or roadway portion). Object detector702can determine that object711D is of object type713(e.g., a vehicle, such as, a truck, a car, a bus, a van, a motorcycle, etc.). Color assignment module703can assign color714(e.g., gray) to object711C and can assign color716(e.g., darker blue) to object711D. Color mask generator701can generate color mask728B (a color mask corresponding to video stream731), including objects711C and711D. In one aspect, color mask728B is sent to color mask aggregator707. In another aspect, color mask728B is sent to subset detector704.

For at least one frame included in the plurality of frames, method800includes assigning a first color to a first object in the frame based on a detected object type of the first object (805). For example, as described with respect toFIG. 7B, color assignment module703can assign color714to object711A based on type712. For the at least one frame included in the plurality of frames, method800includes assigning a second color to a different object in the frame based on another detected object type of the different object (806). Similarly, as described with respect toFIG. 7B, color assignment module703can assign color716to object711B based on type713.

Further, as described with respect toFIG. 7C, color assignment module703can assign color714to object711C based on type712. Similarly, as described with respect toFIG. 7C, color assignment module703can assign color716to object711D based on type713.

For the at least one frame included in the plurality of frames, method800includes determining that the detected object type and the other detected object type match a defined relationship (807). One or both of color mask728A (corresponding to frame732A) and color mask728B (corresponding to frame732B) can be sent to subset detector704. Subset detector704can refer to object type relationships718. Object type relationships718can define relationships between different object types. For example, object type relationships718can define relationship718A between vehicles and roadways. Relationship718A can define that vehicles detected within a roadway are to be considered (or re-typed for coloring, as opposed to object detection, as) part of the roadway. Relationships718can also define relationships between other combinations of described objects types, including between any of: roadway portions, vehicles, trees, bushes, guard rails, signs, walls, buildings, sky, etc.

As such, subset detector704can determine that object711A (roadway) and object711B (vehicle) match relationship718A. For example, subset detector104can detect that object711B (a vehicle object type) is within object711A (a roadway portion object type). Thus, based on relationship718A, subset detector704can determine that object711B is to be assigned the color of object711A. Subset detector704can alter a field value and/or attach an additional field to object711B to indicate that color716is to be re-assigned to color714. Subset detector704can include object711B in subset733A (a subset of objects that are to have colors re-assigned). Subset detector704can send subset733A to color reassignment module706.

In another aspect, subset detector704can determine that object711C (roadway) and object711D (vehicle) match relationship718A. For example, subset detector704can detect that object711D (a vehicle object type) is within object711C (a roadway portion object type). Thus, subset detector704can determine that object711D is to be assigned the color of object711C. Subset detector104can alter a field value and/or attach an additional field to object711D to indicate that color716is to be re-assigned to color714. Subset detector704can include object711D in subset733B (a subset of objects that are to have colors re-assigned). Subset detector704can send subset733B to color reassignment module106.

For the at least one frame included in the plurality of frames, method800includes based on matching the predefined relationship, re-assigning the second color to the first object in the object color mask for the at least one frame (808). For example, inFIG. 7B, color reassignment module706receives subset733A from subset detector704. Referring to color mappings717color reassignment module706re-assigns colors to objects included in subset733A. In one aspect, color reassignment module706accesses fields attached by subset detector704. Color reassignment module706re-assigns colors to objects in accordance with the attached fields. For example, color reassignment module706can reassign color714to object711B based on a field attached to object711B by subset detector704. Color mask generator701can output color mask722B. As depicted, color mask722A indicates that color714is assigned to both objects711A and711B.

InFIG. 7C, color reassignment module706receives subset733B from subset detector704. Referring to color mappings717color reassignment module706re-assigns colors to objects included in subset733B. In one aspect, color reassignment module706accesses fields attached by subset detector704. Color reassignment module706re-assigns colors to objects in accordance with the attached fields. For example, color reassignment module706can reassign color714to object711D based on a field attached to object711D by subset detector704. Color mask generator701can output color mask722B. As depicted, color mask722B indicates that color714is assigned to both objects711C and711D.

Method800includes aggregating the respective generated object color masks from the at least two frames of video into an aggregate color mask (809). For example, turning toFIG. 7D, color mask aggregator707can aggregate color mask722A (with color reassignments) (or728A without color reassignments), color mask722B (with color reassignments) (or728B without color reassignments), and possibly additional color masks791(e.g., corresponding to additional frames of video stream731) into aggregate color mask723. Thus, one or more color masks including re-assigned colors can be aggregated with one another as well as with one or more other color masks. Color mask aggregator707can send aggregate color mask723to binary mask generator708.

In one aspect, at least two color masks including objects with reassigned colors (e.g., color mask722A and color mask722B) (and potentially along with one or more other color masks, which may or may not include objects with reassigned colors) are aggregated into an aggregate color mask. In another aspect, one color mask including objects with reassigned colors (e.g., color mask722A) is aggregated along with one or more other color masks (e.g., color mask728B) (which may or may not have reassigned colors) into an aggregate color mask.

In one aspect, aggregating color masks includes averaging colors across color masks. Thus, when color masks corresponding to a sufficient number of frames are combined, roadway portion objects as well as other objects can be more efficiently distinguished.

Method800includes deriving a binary mask from the aggregate color mask (810). For example, binary mask generator708can generate binary mask724from aggregate color mask723. Binary mask724can include a “1” or “0” per pixel of aggregate color mask723. Generating binary mask724can include assigning a “1” to pixels assigned a specific color and assigning a “0” to pixels assigned all other colors. In one aspect, portions of aggregate color mask723assigned gray color (and, for example, thus corresponding to roadway portions) are assigned “1” and all other portions of aggregate color mask723are assigned “0”. Binary mask generator708can make binary mask724available to binary mask application module709. In one aspect, binary mask724is stored in durable storage.

InFIGS. 7B and 7C, vehicles in a roadway are reassigned to a color defined for the roadway (e.g., gray). As such, the roadway can be more uniformly masked. That is, vehicles in the roadway cause little, if any, interruption in masking the roadway relative to other objects in frames732A,732B, etc.

Method800includes applying the binary mask to a further frame of the video stream to highlight roadway objects in the further image (811). For example, turning toFIG. 7E, binary masked application module709can access additional frames from video stream731, such as, frames732mthrough732n(e.g.,732ncan be received sometime after frame732m). Binary mask application module709can also access binary mask724(e.g., from durable storage). Binary mask application module709can apply binary mask724to a frame732(e.g.,732n) to derive masked frame726. Pixels of the frame (e.g.,732n) corresponding “1” in binary mask724can be depicted in masked frame726. On the other hand, pixels of frame732corresponding “0” in binary mask724can be obscured (e.g., blacked out) in masked frame726. Masked frame726can be sent to vehicle detector systems792(which may be included in an event detection infrastructure, such as, event detection infrastructure103inFIG. 1B).

In one aspect, all objects in a frame except those colored as roadway are obscured.

Although vehicles can be recolored for purposes of masking, vehicles can be considered based on initial coloring for purposes of vehicle detection. Vehicle detection systems792can receive masked frame726from binary mask application module709. Vehicle detection systems792may ignore masked out portions of masked frame726when attempting to detect vehicles in frame732n. Thus, less than all of the frame (e.g.,732n) is processed, conserving resources relative to processing an entire frame.

Thus, during binary mask derivation for a video stream, when an object of one object type is detected within another object of another object type the color assigned to the other object type is also assigned to the object type. For example, when a vehicle object is detected within a roadway object, the color assigned to the roadway object can also be assigned to the vehicle object. As such, a derived binary mask can better approximate the area of the other object type within one or more frames. For example, when deriving a binary mask for frames that include a roadway, vehicles on the roadway are considered part of the roadway. Thus, a derived binary mask better approximates the area of the roadway within the frames. For example, there are no “holes” in the binary mask due to vehicles detected in a roadway being assigned a different color than the roadway.

When the binary mask is applied to subsequent frames of the video stream, the area of the other object type can be more appropriately represented. Detecting objects of the object type can be focused on areas highlighted by the binary mask (e.g., areas assigned a binary ‘1’). For example, an area of a roadway can be more appropriately represented, and vehicle detection focused on the roadway. Focusing detection on portions of a frame highlighted by a binary mask conserves resources relative to processing an entire frame. For example, a binary mask can be applied to frames of a roadway environment to focus vehicle detection on a roadway and away from other portions of frames that are unlikely to include vehicles (e.g., the sky, bushes, trees, buildings, etc.).

An inverse binary mask can be used to present everything in a frame except objects assigned to specified color, for example, roads. An inverse binary mask can be used a reference frame to understand a camera's PTZ value. As such, if a camera configuration is altered, for example, zooms in, zooms out, rotates, changes angle, etc., the background would change, and fames may provide unusual detection values (relative to values prior to the configuration change). When camera configuration changes, the current background in the frame can be compared to the reference background image created by the inverse mask to identify a PTZ change. A PTZ change can trigger calibration modules to calibrate a camera accordingly.

In another aspect, color mask aggregator707includes the functionality of subset detector704and color reassignment module706. Color mask aggregator707can identify subsets of objects in an aggregate color mask. Color mask aggregator707can refer to color mappings717to re-assign colors to objects. Reassigning colors in an aggregate color mask reduces the number of times color reassignment is performed. Further, aggregated color masks may include overlapping colors from multiple frames. When overlapping colors are re-assigned once, resources are conserved (relative to re-assigned colors per color mask).

The components in computer architecture700can be connected to (or be part of) a network, such as, for example, a system bus, a Local Area Network (“LAN”), a Wide Area Network (“WAN”), and even the Internet, along with components of computer architecture100. Accordingly, the components as well as any other connected computer systems and their components can create and exchange data (e.g., Internet Protocol (“IP”) datagrams and other higher layer protocols that utilize IP datagrams, such as, Transmission Control Protocol (“TCP”), Hypertext Transfer Protocol (“HTTP”), Simple Mail Transfer Protocol (“SMTP”), Simple Object Access Protocol (SOAP), etc. or using other non-datagram protocols) over the network. As such, components in computer architectures700can interoperate with (or even be included in) components in computer architecture100to implement aspects of the invention.