Inference Model Preemption at Boundaries

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

The process of deactivating and reactivating lower-priority inference models in favor of higher-priority models in embedded systems is resource-intensive, consuming memory and processing cycles due to the need to save and reload context data, especially when preempted at layers with large context sizes.

Innovation Solution

Implementing a method to preempt and resume inference models at optimal boundaries, where minimal data needs to be stored off-chip, by determining preemptable boundaries based on layer statistics and breathing times to minimize resource usage.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Reliability

If a lower-priority inference model is deactivated in favor of a higher-priority model, then the higher-priority model can execute, but the deactivated model's context must be saved to memory, consuming valuable memory and processing cycles

Engineering Contradiction:
Improvepriority model executionVSAvoidmemory consumption
Core Design Contradiction:
ReliabilityVSQuantity of substance

Solution Approach 1:

The system performs preliminary identification of preemptable boundaries within the inference model execution flow. By pre-determining where preemptions can occur without disrupting critical operations, the system prepares the execution context in advance, allowing for efficient saving and restoration of state when preemptions are necessary.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The system dynamically changes execution parameters by identifying specific boundary points in the inference model where preemption is safe. These boundaries represent optimal points where the model's internal state can be saved with minimal memory overhead and where resumption can occur without loss of computational integrity.

Inventive Principle:
Principle #35Parameter changes

2Adaptability or versatility

If context is saved to memory when an inference model is preempted, then the model can be restarted, but this reduces the amount of memory available to other processes

Engineering Contradiction:
Improvemodel resumptionVSAvoidavailable memory
Core Design Contradiction:
Adaptability or versatilityVSQuantity of substance

Solution Approach 1:

The system extracts only the essential context information needed for model resumption at preemptable boundaries. By identifying minimal state requirements at these boundaries, the system saves only what is necessary, leaving maximum memory available for other processes while maintaining the ability to resume execution.

Inventive Principle:
Principle #2Taking out (Extraction)

3Reliability

If preemption occurs at a layer with large context size, then the higher-priority model can execute, but the saving and restoration of context consumes valuable processing cycles

Engineering Contradiction:
Improvepriority model executionVSAvoidprocessing cycle overhead
Core Design Contradiction:
ReliabilityVSLoss of time

Solution Approach 1:

The system performs preliminary identification of preemptable boundaries that minimize context size. By analyzing the inference model structure in advance, the system identifies points where the computational state is smallest, allowing for rapid saving and restoration operations that minimize processing cycle overhead.

Inventive Principle:
Principle #10Preliminary action

Solution Approach 2:

The system applies different preemption strategies at different locations within the inference model. By identifying local boundaries with favorable characteristics (smaller context sizes, natural synchronization points), the system optimizes the preemption process at each specific location rather than using a uniform approach.

Inventive Principle:
Principle #3Local quality

Data Source

PatentUS20230252328A1Scheduling of inference models based on preemptable boundaries
Publication Date: 2023.08.10 TEXAS INSTRUMENTS INC
  • US20230252328A1 patent drawing
  • US20230252328A1 patent drawing
  • US20230252328A1 patent drawing

AI summary

Disclosed herein are systems and methods for inference model scheduling of a multi priority inference model system. A processor determines an interrupt flag has been set indicative of a request to interrupt execution of a first inference model in favor of a second inference model. In response to determining that the interrupt flag has been set, the processor determines a state of the execution of the first inference model based on one or more factors. In response to determining the state of the execution is at a preemptable boundary, the processor deactivates the first inference model and activates the second inference model.