pub struct KvCacheEstimate {
pub total_gpu_capacity_bytes: u64,
pub total_kv_size_bytes: u64,
pub kv_size_per_token_bytes: u64,
pub total_kv_size_tokens: u64,
pub source: EstimateSource,
pub memory_breakdown: Option<MemoryBreakdown>,
pub tolerance_adjusted: Option<KvCacheEstimateAdjusted>,
}Expand description
KV-cache memory estimate.
Fields§
§total_gpu_capacity_bytes: u64§total_kv_size_bytes: u64§kv_size_per_token_bytes: u64§total_kv_size_tokens: u64§source: EstimateSource§memory_breakdown: Option<MemoryBreakdown>Some on the native path; None on the naive fallback.
tolerance_adjusted: Option<KvCacheEstimateAdjusted>Some iff tolerance_fraction set; None for the raw estimate.
Trait Implementations§
Source§impl Clone for KvCacheEstimate
impl Clone for KvCacheEstimate
Source§fn clone(&self) -> KvCacheEstimate
fn clone(&self) -> KvCacheEstimate
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for KvCacheEstimate
impl Debug for KvCacheEstimate
Source§impl<'de> Deserialize<'de> for KvCacheEstimate
impl<'de> Deserialize<'de> for KvCacheEstimate
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for KvCacheEstimate
impl PartialEq for KvCacheEstimate
Source§impl Serialize for KvCacheEstimate
impl Serialize for KvCacheEstimate
impl StructuralPartialEq for KvCacheEstimate
Auto Trait Implementations§
impl Freeze for KvCacheEstimate
impl RefUnwindSafe for KvCacheEstimate
impl Send for KvCacheEstimate
impl Sync for KvCacheEstimate
impl Unpin for KvCacheEstimate
impl UnsafeUnpin for KvCacheEstimate
impl UnwindSafe for KvCacheEstimate
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more