-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix!: return an error if vec_y contains negative value (#52)
- Loading branch information
Showing
8 changed files
with
76 additions
and
32 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
use crate::linalg::LinalgError; | ||
use thiserror::Error; | ||
|
||
#[derive(Error, Debug, Eq, PartialEq)] | ||
pub enum GaussianError { | ||
/// Given y_vec contains a negative value | ||
#[error("Given y_vec contains a negative value")] | ||
GivenYVecContainsNegativeValue, | ||
/// Given y_vec contains a negative value | ||
#[error("Given x_vec has no element")] | ||
/// Given x_vec has no element | ||
GivenXVecHasNoElement, | ||
/// Error from [`crate::linalg::LinalgError`] | ||
#[error("Linalg error: {0:?}")] | ||
Linalg(#[from] LinalgError), | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -45,7 +45,6 @@ | |
//! ``` | ||
//! | ||
pub mod error; | ||
pub mod gaussian; | ||
pub mod linalg; | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters