rdk / p2rank

P2Rank: Protein-ligand binding site prediction tool based on machine learning. Stand-alone command line program / Java library for predicting ligand binding pockets from protein structure.

Home Page:https://rdk.github.io/p2rank/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Make p2rank behave more like a standard unix program by default (wrt output location and working directory)

rdk opened this issue · comments

commented
  • Program behaves weirdly when not executed from distro root directory.
  • Output location cannot be overridden on the command line. (#50, now fixed)
  • Default output location should be inside working directory.

Hi,

could you please specify what you mean by Program behaves weirdly...? I am currently using prank as, e.g., ./p2rank_2.2/prank predict datasets/coach420.ds -c default.groovy -o out/, i.e., not from the "distro root" directory, and nothing seems off as far as I can tell.

Also, Output location cannot be overridden... is probably resolved with the option -o, or does this refer to something else?

If I can make a suggestion related to the topic from a new user's perspective here, I think it would be useful if:

  1. all file and path definitions were either absolute or relative to the current working directory (as is customary in UNIX programs). For example, the configuration file is currently taken to be relative to config/, conservation directories relative to the dataset file, etc., which I think is a bit confusing and can lead easily to errors.
  2. I think that it would be useful if p2rank did not write to the "distro root" directory as it is being used. Currently, even when the option -o is used (as above), the file log/prank.log, and possibly others, are created. This prohibits putting the program into /opt/ or other system directories, as is common on servers. The output directory would then have to be a required argument.

David

commented

Also, Output location cannot be overridden... is probably resolved with the option -o, or does this refer to something else?

Yes this is what I meant, -o wasn't working properly. Problem is described in #50, which is now fixed.

could you please specify what you mean by Program behaves weirdly...? I am currently using prank as, e.g., ./p2rank_2.2/prank predict datasets/coach420.ds -c default.groovy -o out/, i.e., not from the "distro root" directory, and nothing seems off as far as I can tell.

I have also experienced some issues when running the program via symlink.

By Program behaves weirdly I meant some surprising behaviour that happens when program is being used as standard unix utility ... which I didn't have time to investigate.

I agree with the suggestions.

This might be a bit of a stretch, but it would also be nice to be able to read a file from standard input and print the .csv with scores to the standard output. Thanks for this amazing program anyways!