neherlab / pan-genome-analysis

Processing pipeline for pan-genome visulization and exploration
http://pangenome.de
GNU General Public License v3.0
134 stars 38 forks source link

Issue with visualization #12

Open pavlo888 opened 5 years ago

pavlo888 commented 5 years ago

So I know this is not the GitHub repository for the pan-genome-visualization package but I am super lost regarding how to make the visualization work.

What exactly are the arguments to be used for the link-to-server.py script???? I understand that argument -s needs to be the folder containing the files from the output of pan-genome-analysis. However, I do not know what the argument should be for -v. I have tried the absolute path of the pan-genome-visualization package, the relative path of the local host server 800, but to no avail.

Could you please help me out with this one? Thanks in advance.

Cheers, Pablo

rneher commented 5 years ago

The -v argument is the path the folder of the visualization. All this script does is to copy the files generated by panX to the visualization such that they end up in pan-genome-visualization/public/dataset/species_name.

In addition, you need to create routes and views via the add-new-pages.py script:

https://github.com/neherlab/pan-genome-visualization/blob/master/add-new-pages.py

pavlo888 commented 5 years ago

Hi Richard,

Thanks a lot for your answer. I seem to be still lost. I am using this command:

/Users/pablovargas/pan-genome-analysis/link-to-server.py -s /Users/pablovargas/pan-genome-analysis/data/TestSet -v /Users/pablovargas/pan-genome-analysis/pan-genome-visualization

The TestSet folder contains all the output from a pan-genome-analysis run. and the argument for -v is the location of the pan-genome-visualization folder. However, there seems to be an error because I get this when I run the command:

rsync: link_stat "/Users/pablovargas/pan-genome-analysis/pan-genome-visualization/./data//Users/pablovargas/pan-genome-analysis/data/TestSet/vis/." failed: No such file or directory (2) rsync: mkdir "/Users/pablovargas/pan-genome-analysis/pan-genome-visualization/public/dataset//Users/pablovargas/pan-genome-analysis/data/TestSet" failed: No such file or directory (2) rsync error: error in file IO (code 11) at /BuildRoot/Library/Caches/com.apple.xbs/Sources/rsync/rsync-52/rsync/main.c(545) [receiver=2.6.9] rsync: connection unexpectedly closed (8 bytes received so far) [sender] rsync error: error in rsync protocol data stream (code 12) at /BuildRoot/Library/Caches/com.apple.xbs/Sources/rsync/rsync-52/rsync/io.c(453) [sender=2.6.9]

Then I check my localhost server http://localhost:8000/ and cannot find my data.

Do you have any idea what I am doing wrong??????

Thanks a lot for your help.

Cheers, Pablo

rneher commented 5 years ago

The problem is that the -s flag is only supposed to be the name of your run, i.e. TestSet in your case. cd into /Users/pablovargas/pan-genome-analysis and then execute ./link-to-server.py -s TestSet -v /Users/pablovargas/pan-genome-analysis/pan-genome-visualization

pavlo888 commented 5 years ago

Hi Richard,

I am very sorry to bother you again but I still cannot make it work. I have followed your indications and those from the pan-genome-visualization GitHub website and it is just not working for me.

This is what I do, sequentially,

  1. Open the terminal
  2. cd to pan-genome-analysis and then cd to pan-genome-visualization
  3. Run the bash file > bash add-new-pages-repo.sh TestSet
  4. cd to pan-genome-analysis and run the python file > python link-to-server.py -s TestSet -v /Users/pablovargas/pan-genome-analysis/pan-genome-visualization
  5. cd to pan-genome-visualization
  6. Run the command > npm start
  7. Go to my local server and then check if I can find the entry TestSet but I cannot find it.

I have checked that the TestSet directory is located in pan-genome-analysis/pan-genome-visualiation/public/dataset/ and that all the permissions to all the files in the TestSet directory are in order, i.e. I changed all the files permissions with chmod 777.

I am running all this process in a Mac terminal. Please let me know if there is anything other detail you would need from me. I really want to make this work. I find your pipeline very complete and would like to try it on a real set of genomes I have.

Thank you very much in advance.

Best regards, Pablo

On Sun, Dec 9, 2018 at 5:41 PM Richard Neher notifications@github.com wrote:

The problem is that the -s flag is only supposed to be the name of your run, i.e. TestSet in your case. cd into /Users/pablovargas/pan-genome-analysis and then execute ./link-to-server.py -s TestSet -v /Users/pablovargas/pan-genome-analysis/pan-genome-visualization

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/neherlab/pan-genome-analysis/issues/12#issuecomment-445552163, or mute the thread https://github.com/notifications/unsubscribe-auth/ArlZEvhq4uv_VjGEKSxOojJQjh4jblmWks5u3T1PgaJpZM4ZJShT .

stheil15 commented 5 years ago

Same problem here !

rneher commented 5 years ago

Please check the following:

The latter two are created from the TestSet.js and TestSet.jade templates in the respective folders. The former should be a copy of the vis folder from the pan-genome-analysis output -- the link-to-server.py script does that copying but you can copy it yourself as well.

stheil15 commented 5 years ago

Works for me now. I was expecting the TestSet to appear in the list of organisms. But I scroll down to your FAQ part and I saw that I need to type : localhost:8000/TestSet to visualise my data. Thank for your answer.

stheil15 commented 5 years ago

After the TestSet, i've tried to launch it on a part of my own data. The pan-analysis seems to be ok. but when I link it to the pan-visualization and I log into the localhost:8000/my_specie, everything is empty: image

In the chrome dev tool, i see this errors : image

And surprisingly, the file is filled with html code when visualized in Chrome, but with java code when open from the file system (pan-genome-visualization/public/dataset/my_specie/metaConfiguration.js)

rneher commented 5 years ago

that's weird. check which file the browser is actually requesting (and hit ctrl-U to check the exact path of the script -- somewhere at the bottom).

rneher commented 5 years ago

when you open the file in your browser and it doesn't exist, you'll the the server's error page which is html.