Skip to content
This repository has been archived by the owner on Nov 3, 2022. It is now read-only.

CRF layer as hidden layer #542

Open
phquanta opened this issue Jul 5, 2020 · 0 comments
Open

CRF layer as hidden layer #542

phquanta opened this issue Jul 5, 2020 · 0 comments

Comments

@phquanta
Copy link

phquanta commented Jul 5, 2020

Just curious, if it is possible to capture inter-dependencies in hidden states by using CRF as middle layer i.e.Model: "sequential_1"
as shown below without introducing extra energies and other factors ?
Layer (type) Output Shape Param #
lstm_1 (LSTM) (None, None, 256) 358400
crf_1 (CRF) (None, None, 256) 131840
lstm_2 (LSTM) (None, None, 256) 525312
dense_1 (Dense) (None, None, 93) 23901

I need to use it as middle layer for LSTM not to lose its char-based generative ability, otherwise if you use as last layer it easily learns that you need to shift whole sentence to the left.

With Best Regards, Andrei Buin.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant