nyuvis / patient-viz

Visualization of electronic medical records or other sequence event data.
MIT License
90 stars 29 forks source link

'No file list found' when connecting to OMOP postgres db #61

Open rpeys opened 5 years ago

rpeys commented 5 years ago

Hi! I am trying to use this tool to visualize OMOP data in Postgres.

Set up seemed to have gone well, but then I run server.py:

rpeyser@k80:~/GitHub/patient-viz$ ./server.py -p 8083
config exists: True file: '/home/rpeyser/GitHub/patient-viz/config.txt'
exists: True file: u'/home/rpeyser/GitHub/patient-viz/code/ccs/multi_diag.txt'
exists: True file: u'/home/rpeyser/GitHub/patient-viz/code/ccs/multi_proc.txt'
/home/rpeyser/GitHub/patient-viz/.venv/local/lib/python2.7/site-packages/psycopg2/__init__.py:144: UserWarning: The psycopg2 wheel package will be renamed from release 2.8; in order to keep installing from binary please use "pip install psycopg2-binary" instead. For details see: <http://initd.org/psycopg/docs/install.html#binary-install-from-pypi>.
  """)
server.py (137): starting server at localhost:8083
config exists: True file: '/home/rpeyser/GitHub/patient-viz/config.txt'
exists: True file: u'/home/rpeyser/GitHub/patient-viz/code/ccs/multi_diag.txt'
exists: True file: u'/home/rpeyser/GitHub/patient-viz/code/ccs/multi_proc.txt'
/home/rpeyser/GitHub/patient-viz/.venv/local/lib/python2.7/site-packages/psycopg2/__init__.py:144: UserWarning: The psycopg2 wheel package will be renamed from release 2.8; in order to keep installing from binary please use "pip install psycopg2-binary" instead. For details see: <http://initd.org/psycopg/docs/install.html#binary-install-from-pypi>.
  """)
server.py (137): starting server at localhost:8083
> quick_server.pyc (820):    0.693ms [2019-02-20 14:19:46] code 404, message No permission to list directory
quick_server.pyc (820): [2019-02-20 14:19:46] "GET / HTTP/1.1" 404
quick_server.pyc (820):    3.370ms [2019-02-20 14:19:48] 13.6 kB "GET /patient-viz/ HTTP/1.1" 304
quick_server.pyc (820):    0.457ms [2019-02-20 14:19:48] "GET /patient-viz/patients.txt HTTP/1.1" 304
quick_server.pyc (820):    1.580ms [2019-02-20 14:19:48] 107 kB "GET /patient-viz/lib/jk-js/lib/bootstrap/css/bootstrap.min.css HTTP/1.1" 304
quick_server.pyc (820):    1.819ms [2019-02-20 14:19:48] 5.64 kB "GET /patient-viz/lib/jk-js/jkjs/zui.js HTTP/1.1" 304
quick_server.pyc (820):    2.551ms [2019-02-20 14:19:48] 682 B "GET /patient-viz/lib/jk-js/jkjs/time.js HTTP/1.1" 304
quick_server.pyc (820):    4.201ms [2019-02-20 14:19:48] 5.28 kB "GET /patient-viz/lib/jk-js/jkjs/text.js HTTP/1.1" 304
quick_server.pyc (820):    4.796ms [2019-02-20 14:19:48] 3.49 kB "GET /patient-viz/lib/jk-js/jkjs/busy.js HTTP/1.1" 304
quick_server.pyc (820):    6.954ms [2019-02-20 14:19:48] 143 kB "GET /patient-viz/lib/jk-js/lib/d3/d3.min.js HTTP/1.1" 304
quick_server.pyc (820):    3.813ms [2019-02-20 14:19:48] 18.5 kB "GET /patient-viz/lib/colorbrewer/colorbrewer.js HTTP/1.1" 304
quick_server.pyc (820):    1.123ms [2019-02-20 14:19:48] 1.36 kB "GET /patient-viz/style.css HTTP/1.1" 304
quick_server.pyc (820):    1.946ms [2019-02-20 14:19:48] 2.89 kB "GET /patient-viz/lib/jk-js/jkjs/path.js HTTP/1.1" 304
quick_server.pyc (820):    1.680ms [2019-02-20 14:19:48] 17.5 kB "GET /patient-viz/lib/jk-js/jkjs/stat.js HTTP/1.1" 304
quick_server.pyc (820):    1.776ms [2019-02-20 14:19:48] 12.7 kB "GET /patient-viz/lib/jk-js/jkjs/util.js HTTP/1.1" 304
quick_server.pyc (820):    2.540ms [2019-02-20 14:19:48] 34.2 kB "GET /patient-viz/js/typepool.js HTTP/1.1" 304
quick_server.pyc (820):    6.553ms [2019-02-20 14:19:48] 7.65 kB "GET /patient-viz/js/event.js HTTP/1.1" 304
quick_server.pyc (820):    9.640ms [2019-02-20 14:19:48] 14.3 kB "GET /patient-viz/js/type.js HTTP/1.1" 304
quick_server.pyc (820):    7.321ms [2019-02-20 14:19:48] 12.6 kB "GET /patient-viz/js/typeview.js HTTP/1.1" 304
quick_server.pyc (820):    9.668ms [2019-02-20 14:19:48] 2.55 kB "GET /patient-viz/js/overview.js HTTP/1.1" 304
quick_server.pyc (820):    9.589ms [2019-02-20 14:19:48] 4.26 kB "GET /patient-viz/js/eventview.js HTTP/1.1" 304
quick_server.pyc (820):    8.020ms [2019-02-20 14:19:48] 4.14 kB "GET /patient-viz/js/histogram.js HTTP/1.1" 304
quick_server.pyc (820):    5.555ms [2019-02-20 14:19:48] 18 kB "GET /patient-viz/js/shared.js HTTP/1.1" 304
quick_server.pyc (820):    4.469ms [2019-02-20 14:19:48] 10.6 kB "GET /patient-viz/js/labels.js HTTP/1.1" 304
quick_server.pyc (820):    6.625ms [2019-02-20 14:19:48] 3.26 kB "GET /patient-viz/js/cluster.js HTTP/1.1" 304
quick_server.pyc (820):    5.820ms [2019-02-20 14:19:48] 2.38 kB "GET /patient-viz/js/linechart.js HTTP/1.1" 304
quick_server.pyc (820):    3.697ms [2019-02-20 14:19:49] 7.19 kB "GET /patient-viz/lib/jk-js/jkjs/img/busy.gif HTTP/1.1" 304
quick_server.pyc (820):    3.623ms [2019-02-20 14:19:49] 1.64 kB "GET /patient-viz/lib/jk-js/jkjs/img/warning.png HTTP/1.1" 304

When I open a browser window and type http://localhost:2222/patient-viz/ I see No file list found image

my patients.txt file contains a list of 100 json files listed (1 per row), starting with json/1.0.json and the json directory only contains one file called dictionary.json that has {} written inside it.

JosuaKrause commented 5 years ago

there shouldn't be a need to preprocess data for OMOP. do the lines in patients.txt match the patient IDs in your table? is this issue related to #62 ? I'll have a closer look in a bit

rpeys commented 5 years ago

Thanks for responding! I don't believe this is related to issue #62 . patients.txt contains text like

json/1.0.json
json/100.0.json
json/101.0.json
json/102.0.json
json/103.0.json
json/104.0.json
json/105.0.json
json/106.0.json
json/107.0.json
json/108.0.json

whereas the person_id field in my OMOP person table contains integers. The integer version of the id's in patients.txt do appear in my person table.

I don't think this is a bug: I think patients.txt is set to record 'persons_source_value' -- as per 'show_old_ids' argument in line 60 of server.py omop.list_patients(patients, prefix=json_dir, limit=max_num, show_old_ids=True) -- and these do match those