Skip to main content

IProgressMonitor

Struct IProgressMonitor 

Source
pub struct IProgressMonitor { /* private fields */ }

Implementations§

Source§

impl IProgressMonitor

Source

pub fn getInterfaceInfo<'a>( self: &'a IProgressMonitor, ) -> impl New<Output = InterfaceInfo> + 'a

Return version information associated with this interface. Applications must not override this method.

Source

pub unsafe fn phaseStart( self: Pin<&mut IProgressMonitor>, phaseName: *const c_char, parentPhase: *const c_char, nbSteps: i32, )

Signal that a phase of the optimizer has started.

  • phaseName The name of this phase for tracking purposes.
  • parentPhase The parent phase that this phase belongs to, or nullptr if there is no parent.
  • nbSteps The number of steps that are involved in this phase.

The phaseStart function signals to the application that the current phase is beginning, and that it has a certain number of steps to perform. If phaseParent is nullptr, then the phaseStart is beginning an independent phase, and if phaseParent is specified, then the current phase, specified by phaseName, is within the scope of the parent phase. nbSteps will always be a positive number. The phaseStart function implies that the first step is being executed. TensorRT will signal when each step is complete.

Phase names are human readable English strings which are unique within a single phase hierarchy but which can be reused once the previous instance has completed. Phase names and their hierarchies may change between versions of TensorRT.

See [phaseFinish]

Source

pub unsafe fn stepComplete( self: Pin<&mut IProgressMonitor>, phaseName: *const c_char, step: i32, ) -> bool

Signal that a step of an optimizer phase has finished.

  • phaseName The name of the innermost phase being executed.
  • step The step number that was completed.

The stepComplete function signals to the application that TensorRT has finished the current step for the phase phaseName, and will move onto the next step if there is one. The application can return false for TensorRT to exit the build early. The step value will increase on subsequent calls in the range [0, nbSteps).

true to continue to the next step or false to stop the build.

Source

pub unsafe fn phaseFinish( self: Pin<&mut IProgressMonitor>, phaseName: *const c_char, )

Signal that a phase of the optimizer has finished.

  • phaseName The name of the phase that has finished.

The phaseFinish function signals to the application that the phase is complete. This function may be called before all steps in the range [0, nbSteps) have been reported to stepComplete. This scenario can be triggered by error handling, internal optimizations, or when stepComplete returns false to request cancellation of the build.

See [phaseStart]

Trait Implementations§

Source§

impl AsRef<IVersionedInterface> for IProgressMonitor

Source§

fn as_ref(self: &IProgressMonitor) -> &IVersionedInterface

Converts this type into a shared reference of the (usually inferred) input type.
Source§

impl Drop for IProgressMonitor

Source§

fn drop(self: &mut IProgressMonitor)

Executes the destructor for this type. Read more
Source§

impl ExternType for IProgressMonitor

Source§

type Kind = Opaque

Source§

type Id

A type-level representation of the type’s C++ namespace and type name. Read more
Source§

impl MakeCppStorage for IProgressMonitor

Source§

unsafe fn allocate_uninitialized_cpp_storage() -> *mut IProgressMonitor

Allocates heap space for this type in C++ and return a pointer to that space, but do not initialize that space (i.e. do not yet call a constructor). Read more
Source§

unsafe fn free_uninitialized_cpp_storage(arg0: *mut IProgressMonitor)

Frees a C++ allocation which has not yet had a constructor called. Read more
Source§

impl SharedPtrTarget for IProgressMonitor

Source§

impl UniquePtrTarget for IProgressMonitor

Source§

impl WeakPtrTarget for IProgressMonitor

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.