Code Monkey home page Code Monkey logo

datnet's Introduction

DATNet

This is TensorFlow implementation for paper (* indicates equal contributions):

overview

Requirements

  • python 3.x with package tensorflow-gpu (1.13.1), tensorflow_hub, ujson, emoji, matplotlib, tqdm, seqeval, scikit-learn

Usage

You can download pre-processed datasets from Box Drive (datasets), and save them to ./datasets/ folder.

Run baseline model on CoNLL-2003 English NER task using adversarial training (--at true). More parameters setting in run_baseline.py.

python run_baseline.py --train true --elmo false --task conll03_en_ner --at true

Run DATNet-P model on CoNLL-2003 English NER (OntoNotes NER as source) using ELMo (--elmo true), adversarial training (--at true), share word embeddings (--share_word true). More parameters setting in run_datnetp.py.

python run_datnetp.py --src_task ontonotes_ner --tgt_task conll03_en_ner --elmo true --at ture \
                      --share_word true

Similarly, run DATNet-F model on CoNLL-2003 English NER (OntoNotes NER as source) using ELMo (--elmo true), adversarial training (--at true), share word embeddings (--share_word true). More parameters setting in run_datnetf.py.

python run_datnetf.py --src_task ontonotes_ner --tgt_task conll03_en_ner --elmo true --at ture \
                      --share_word true

Note: to obtain the main results of Table 2 in "Dual Adversarial Neural Transfer for Low-Resource Named Entity Recognition", you can download the DATNet codes (init version) and trained weights, which are available on Box Drive (DATNet), and following the provided instructions to do evaluations. The pre-trained word embeddings are available here.

Citation

If you feel this project helpful to your research, please cite our work.

@inproceedings{zhou2019dual,
    title = {Dual Adversarial Neural Transfer for Low-Resource Named Entity Recognition},
    author = {Zhou, Joey Tianyi and Zhang, Hao and Jin, Di and Zhu, Hongyuan and Fang, Meng and Goh, Rick Siow Mong and Kwok, Kenneth},
    booktitle = {Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics},
    year = {2019},
    address = {Florence, Italy},
    publisher = {Association for Computational Linguistics},
    url = {https://www.aclweb.org/anthology/P19-1336},
    doi = {10.18653/v1/P19-1336},
    pages = {3461--3471}
}

and

@article{8778733,
  author={J. T. {Zhou} and H. {Zhang} and D. {Jin} and X. {Peng}},
  journal={IEEE Transactions on Pattern Analysis and Machine Intelligence}, 
  title={Dual Adversarial Transfer for Sequence Labeling}, 
  year={2021},
  volume={43},
  number={2},
  pages={434-446},
  doi={10.1109/TPAMI.2019.2931569}
}

datnet's People

Contributors

26hzhang avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.