Comments (9)
Hello, are you referring to the CRF learner itself, or either of the CRF layers in the BiLSTM and BERT?
If the former, we are using the sklearn's CRF implementation (see here), so it may be up to what functionality their implementation supports.
from medacy.
I'm referring to the CRF layer in the BiLSTM and BERT
from medacy.
They both use the CRF implemented in pytorch-crf. Does it appear to natively support what you are trying to do?
from medacy.
They both use the CRF implemented in pytorch-crf. Does it appear to natively support what you are trying to do?
I don't think it is support what I want to do, in pytorch-crf package, the author initialized the transition matrix without any constraint (I think)
from medacy.
They both use the CRF implemented in pytorch-crf. Does it appear to natively support what you are trying to do?
I wonder in pytorch-crf, the row index represents the current state and column index represents the next state in CRF transition matrix? or the other way around? I'm actually very confused about that.
from medacy.
I am not sure. If you create or obtain a torch-compatible CRF implementation that does what you need, I may be able to discuss with you how to use it in medaCy, or at least point out where in the code base things would need to be changed.
from medacy.
I am not sure. If you create or obtain a torch-compatible CRF implementation that does what you need, I may be able to discuss with you how to use it in medaCy, or at least point out where in the code base things would need to be changed.
Thank you, but in the medaCy crf layer, there is no constraint on the transition matrix, right? But If I want to enforce such constraint, where should I modify the code?
from medacy.
None of the CRFs used in medaCy are implemented within medaCy, so the only changes one would make to medaCy code would be replacing the CRF implementations imported from its dependencies with one that does what is wanted.
In other words, you would probably have to modify the pytorch-crf code.
If you are able to get that far, please let me know and we can discuss how to switch that alternative CRF with those used in medaCy.
from medacy.
None of the CRFs used in medaCy are implemented within medaCy, so the only changes one would make to medaCy code would be replacing the CRF implementations imported from its dependencies with one that does what is wanted.
In other words, you would probably have to modify the pytorch-crf code.
If you are able to get that far, please let me know and we can discuss how to switch that alternative CRF with those used in medaCy.
Yea, I'm currently trying to use medaCy to do NER task on my dataset, but results not quite good. And I saw some cases like O -> I in the prediction. So I wanna use CRF with some constraint so that I can further improve the performance. I think I'm going to modify the pytorch-crf code, but I just not quite sure how to do it and confused about the index. Hope you can help, thank you in advance.
from medacy.
Related Issues (20)
- Cant install medacy (torch version 1.2.0 error) HOT 2
- Problem in installing clinical notes model
- Only drug and duration extracted HOT 4
- pytorch error while install medaCy's clinical model HOT 3
- Module Not Found Error (medacy.ner) HOT 1
- nanomedicine_drug_labels model not found HOT 1
- object 'Dataset' has no attribute 'load_external' HOT 1
- Can i able to train the model with custom dataset [FEATURE REQUEST] HOT 1
- Consider supporting Python 3.6 until official support ends [FEATURE REQUEST] HOT 2
- Improve the error message when loading a model with an incompatible pipeline
- Convert the config JSON to a YAML file HOT 3
- Support for Python 2.7 HOT 1
- Models page not accessible, Not able to download models HOT 2
- Request for information about models and annotation formats HOT 4
- Compatibility with newer spaCy versions HOT 9
- Not sure where I am going wrong here. HOT 2
- Not able to install HOT 1
- Broken link on the README.md HOT 1
- medaCy's clinical model
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from medacy.