Giter VIP home page Giter VIP logo

bs-bulletin-parser's Introduction

bs-bulletin-parser

Parses text of daily bulleting from Canton BS for covid19 data for the following data:

https://www.gd.bs.ch/medienseite/medienmitteilungen.html

NUMCUL_CONF_RESIDENTS
DAILY_DECEASED
DAILY_CONF
NUMCUL_RELEASED
NUMCUL_DECEASED
NUMCUL_CONF
NUMCUL_HOSP
NUMCUL_HOSP_RESIDENTS
NUMCUL_ICU
NUMCUL_CONFIRMED_NON_RESIDENT
NUMCUL_CONF

Copy daily bulletin text into an ascii file (or run example below) and run as follows:

python main.py --filename fixtures/test-1.txt

which then prints the results on the screen

>> WARNING:root:Error parsing: 61-jähriger

>> NUMCUL_CONF_RESIDENTS         : 691
>> NUMCUL_RELEASED               : 323
>> DAILY_DECEASED                : 2
>> NUMCUL_CONF                   : 1095
>> NUMCUL_HOSP_RESIDENTS         : 88
>> NUMCUL_HOSP                   : 108
>> NUMCUL_ICU                    : 16
>> NUMCUL_CONFIRMED_NON_RESIDENT : 404
>> NINST_HOSP_NON_RESIDENT       : 20

There is some basic text preprocessing where all german number words like "zwei", "hundert" etc. are replaced by their numerical values before actual parsing. Some edge cases are also converted such as "ein", "eine", "einen" -> 1 This works for all numbers up to 100 plus a few common cases such as "tausend"

Implementation Detail

Parsing is performed by using a custom trained named-entity-recognition model in spacy. (nlp/*)

Latest training data update: 2020-04-01

bs-bulletin-parser's People

Contributors

abieler avatar

Watchers

James Cloos 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.