Giter Site home page Giter Site logo

recski / brise-plandok Goto Github PK

View Code? Open in Web Editor NEW
6.0 6.0 2.0 44.76 MB

Information extraction from text documents of the zoning plan of the City of Vienna

License: MIT License

Python 59.59% Shell 2.11% Jupyter Notebook 7.13% Dockerfile 0.12% TeX 31.04%

brise-plandok's People

Contributors

adaamko avatar eszti avatar recski avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

Forkers

adaamko eszti

brise-plandok's Issues

potato/create_dataset fails unexpectedly if target data files exist

This command works fine if data/gold* files don't exist:

python create_dataset.py -d ~/sandbox/brise-nlp/annotation/2021_09/full_data -g fourlang -o -n gold

But if I rerun it to regenerate the graphs, the same command fails with this error:

/home/recski/miniconda3/envs/brise/lib/python3.7/site-packages/pandas/core/indexing.py:845: SettingWithCopyWarning: 
A value is trying to be set on a copy of a slice from a DataFrame.
Try using .loc[row_indexer,col_indexer] = value instead

See the caveats in the documentation: https://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy
  self.obj[key] = _infer_fill_value(value)
/home/recski/miniconda3/envs/brise/lib/python3.7/site-packages/pandas/core/indexing.py:966: SettingWithCopyWarning: 
A value is trying to be set on a copy of a slice from a DataFrame.
Try using .loc[row_indexer,col_indexer] = value instead

See the caveats in the documentation: https://pandas.pydata.org/pandas-docs/stable/user_guide/indexing.html#returning-a-view-versus-a-copy
  self.obj[item] = s

Emptying the data folder solves the problem.

@Eszti please have a look when you can

convert.py does not open stream for -of other than xlsx

NOTE: this issue was detected on dev

Executing

python brise_plandok/convert.py \
    -i XLSX \
    -if ~/research/data/brise/ann/$1.xlsx \
    -o JSON \
    -of ~/research/data/brise/ann/$1.json

results in

Traceback (most recent call last):
  File "/home/eszter/research/brise-plandok/brise_plandok/convert.py", line 391, in <module>
    main()
  File "/home/eszter/research/brise-plandok/brise_plandok/convert.py", line 387, in main
    converter.convert(input_stream, output_stream)
  File "/home/eszter/research/brise-plandok/brise_plandok/convert.py", line 358, in convert
    self.write(doc, output_stream)
  File "/home/eszter/research/brise-plandok/brise_plandok/convert.py", line 348, in write
    self.write_json(doc, stream)
  File "/home/eszter/research/brise-plandok/brise_plandok/convert.py", line 324, in write_json
    stream.write(json.dumps(doc))
AttributeError: 'str' object has no attribute 'write'

plandok.py leaves sections.sens.text null if cache is used

The following preprocessing step leaves the sections.sens.text attribute null if nlp_cache.json is used.

python brise_plandok/plandok.py sample_data/txt/*.txt > sample_data/json/sample.jsonl

If the cache file is deleted, and therefore regenerated on the next run, the json output is complete.

Install puts 'export ALTO_JAR' 3 times into bash_profile invalid

After executing pip install . I have the following line in my .bash_profile:

export ALTO_JAR=/home/eszter/tuw_nlp_resources/alto-2.3.6-SNAPSHOT-all.jarexport ALTO_JAR=/home/eszter/tuw_nlp_resources/alto-2.3.6-SNAPSHOT-all.jarexport ALTO_JAR=/home/eszter/tuw_nlp_resources/alto-2.3.6-SNAPSHOT-all.jar

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.