ShannonAI / mrc-for-flat-nested-ner

Code for ACL 2020 paper `A Unified MRC Framework for Named Entity Recognition`

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Cannot import TensorMetric

smiles724 opened this issue · comments

Hi, I notice your past reply. However, my current version of lightning is 1.2.10, which is the latest. But I cannot import TensorMetric, can you please give me a solution?
#54 (comment)

@Wufang1997 Hi, please use pytorch-lightning==0.9.0, which is listed in requirements.txt
If you still wanna use latest pytorch-lightning, please refer to their latest documentation to implement metrics in a new way.

@Wufang1997 Hi, please use pytorch-lightning==0.9.0, which is listed in requirements.txt
If you still wanna use latest pytorch-lightning, please refer to their latest documentation to implement metrics in a new way.

Thanks for your reply. By the way, can I ask the reason you choose pytorch-lightning as the base of your approach implementation? I used to adopt pytorch for most of my past projects and it is the first time to utilize pytorch-lightning. Can you give me some hints whether there are some advantages that lightning outweighs other packages? Thx.

@Wufang1997 Good question:) pl team make a thorough explanation on why pl:
https://pytorch-lightning.readthedocs.io/en/latest/starter/introduction_guide.html#why-pytorch-lightning

Interesting. By the way, I am curious about how you preprocessed datasets like MSRA. I noticed that the raw MSRA dataset is in the form of '{phase}.tsv' and has already been splitter into train/dev/test. However, what I downloaded online took the form of 'txt' and only has train/test. Can you tell me where you obtain your MSRA dataset so that I can process it myself?