AI-Riksarkivet / htrflow_app

This repo work as a sandbox enviroment for htrflow.
https://huggingface.co/spaces/Riksarkivet/htr_demo
European Union Public License 1.2
28 stars 6 forks source link

traffic_demo_data #1

Closed patrikwm closed 1 year ago

patrikwm commented 1 year ago

Hi!

Trying to start the app.py but I get an error with

fatal: Authentication failed for 'https://huggingface.co/datasets/Riksarkivet/traffic_demo_data/'

seems to be the helper/utils.py that tries to clone it.

Im no expert in AI or huggingface so I dont kno'w if its a real 404 or if privileges are just missing.

/Patrik

patrikwm commented 1 year ago

I change the repo in helper/utils.py and now it starts.

Borg93 commented 1 year ago

Glad it was solved! Actually, you could also just remove these lines:

https://github.com/Riksarkivet/HTRFLOW/blob/7bad9994bfc9520d0ecb3b2d0663539b69d5c957/app.py#L36 https://github.com/Riksarkivet/HTRFLOW/blob/7bad9994bfc9520d0ecb3b2d0663539b69d5c957/tabs/htr_tool.py#L280 https://github.com/Riksarkivet/HTRFLOW/blob/7bad9994bfc9520d0ecb3b2d0663539b69d5c957/tabs/stepwise_htr_tool.py#L384

TrafficDataHandler is just a temporary solution for demo release to get some metrics.. i.e that part will be removed soon!

patrikwm commented 1 year ago

I didn't know what it was first so I change the _repo in utils.py and sent In my own repo in HF_DATA_REPO variable

    _repo = huggingface_hub.Repository(
        local_dir="data",
        repo_type="dataset",
        clone_from=os.environ.get("HF_DATA_REPO", "Riksarkivet/traffic_demo_data"),
        use_auth_token=_TOKEN
    )