-
Notifications
You must be signed in to change notification settings - Fork 182
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merge segmenter_lstm with segmenter #2087
Merge segmenter_lstm with segmenter #2087
Conversation
9010803
to
8e10cf6
Compare
Notice: the branch changed across the force-push!
~ Your Friendly Jira-GitHub PR Checker Bot |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me.
@sffc it would be great if you can take another look. Thanks!
@@ -22,7 +22,6 @@ experimental/collator/ @hsivonen @echeran | |||
experimental/normalizer/ @hsivonen @echeran | |||
experimental/provider_ppucd/ @echeran | |||
experimental/segmenter/ @aethanyc @makotokato |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sffc, could I add you to this?
@@ -168,3 +169,94 @@ impl Lstm { | |||
bies | |||
} | |||
} | |||
|
|||
#[cfg(test)] | |||
mod tests { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
question: I assume these tests within this mod
are adapted from lstm_test.rs
without any change to the logic. If not, please let me know.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lstm_structs
and 'lstm_bies' are private module now. So I move
lstm_test.rsto to
lstm_bies.rs`.
@@ -157,6 +157,14 @@ extern crate lazy_static; | |||
// Use the LSTM when the feature is enabled. | |||
#[cfg(feature = "lstm")] | |||
mod lstm; | |||
#[cfg(feature = "lstm")] | |||
mod lstm_bies; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit (for later): it would be cleaner to nest these under the lstm
module.
serde = { version = "1.0", default-features = false, features = ["derive", "alloc"], optional = true } | ||
serde_json = { version = "1.0", default-features = false, features = ["alloc"] } | ||
lazy_static = { version = "1.0", features = ["spin_no_std"] } | ||
zerovec = { version = "0.7", path = "../../utils/zerovec", features = ["yoke"] } | ||
databake = { version = "0.4", path = "../../utils/databake", optional = true, features = ["derive"] } | ||
litemap = { version = "0.4.0", path = "../../utils/litemap", optional = true, features = ["serde"] } | ||
ndarray = { git = "https://github.com/rust-ndarray/ndarray", rev = "31244100631382bb8ee30721872a928bfdf07f44", default-features = false, optional = true, features = ["serde"] } | ||
unicode-segmentation = { version = "1.3.0", optional = true } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reminder: we hope to get rid of this dependency.
litemap = { version = "0.4.0", path = "../../utils/litemap", optional = true, features = ["serde"] } | ||
ndarray = { git = "https://github.com/rust-ndarray/ndarray", rev = "31244100631382bb8ee30721872a928bfdf07f44", default-features = false, optional = true, features = ["serde"] } | ||
unicode-segmentation = { version = "1.3.0", optional = true } | ||
num-traits = { version = "0.2", optional = true } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Request: See if you can get rid of this dependency as well.
See the proposal #2087 (comment)
For #1654