pub struct TensorRf { /* private fields */ }Expand description
TensoRF CP radiance field.
Implementations§
Source§impl TensorRf
impl TensorRf
Sourcepub fn new(cfg: TensorRfConfig, rng: &mut LcgRng) -> NerfResult<Self>
pub fn new(cfg: TensorRfConfig, rng: &mut LcgRng) -> NerfResult<Self>
Create a new TensoRF with small random initialization.
§Errors
Returns TensorDecompError if any dimension is zero.
Sourcepub fn query_density(&self, xyz: [f32; 3]) -> NerfResult<f32>
pub fn query_density(&self, xyz: [f32; 3]) -> NerfResult<f32>
Query density at a 3D point in [-1, 1]^3.
Returns ReLU(Σ_r v_r^X(x) * v_r^Y(y) * v_r^Z(z)).
§Errors
Returns NanEncountered if an NaN occurs.
Sourcepub fn query_color(&self, xyz: [f32; 3]) -> NerfResult<Vec<f32>>
pub fn query_color(&self, xyz: [f32; 3]) -> NerfResult<Vec<f32>>
Query color feature vector at a 3D point in [-1, 1]^3.
Returns [n_color_feat] features.
§Errors
Returns NanEncountered if an NaN occurs.
Sourcepub fn param_count(&self) -> usize
pub fn param_count(&self) -> usize
Total number of parameters.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TensorRf
impl RefUnwindSafe for TensorRf
impl Send for TensorRf
impl Sync for TensorRf
impl Unpin for TensorRf
impl UnsafeUnpin for TensorRf
impl UnwindSafe for TensorRf
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