This file contains hidden or 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 is a batched LSTM forward and backward pass | |
""" | |
import numpy as np | |
import code | |
class LSTM: | |
@staticmethod | |
def init(input_size, hidden_size, fancy_forget_bias_init = 3): |
This file contains hidden or 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
create two directory: `/config/mmseg`, `/plugins/analysis-mmseg` | |
1. got to [`https://github.com/medcl/elasticsearch-rtf/tree/master/config/mmseg`](https://github.com/medcl/elasticsearch-rtf/tree/master/config/mmseg)`, download the files: | |
chars.dic, units.dic, words-my.dic,words.dic, mv them to `/config/mmseg` | |
2. go to [`https://github.com/medcl/elasticsearch-rtf/tree/master/plugins/analysis-mmseg`](https://github.com/medcl/elasticsearch-rtf/tree/master/plugins/analysis-mmseg), download the jar: | |
elasticsearch-analysis-mmseg-1.2.2.jar, mv them to `/plugins/analysis-mmseg` | |
3. add the following configuration to `elasticsearch.yml`: |
This file contains hidden or 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
in elasticsearch.yml add the | |
``` | |
analyzer: | |
ik: | |
alias: | |
- ik_analyzer | |
type: org.elasticsearch.index.analysis.IkAnalyzerProvider | |
ik_max_word: | |
type: ik | |
use_smart: false |
NewerOlder