ssbio icon indicating copy to clipboard operation
ssbio copied to clipboard

Issues running the tutorial

Open bkellman opened this issue 6 years ago • 1 comments

https://github.com/SBRG/ssbio/blob/6f41652f716681a64f2f57aa3cc47eb1953e4ae4/docs/tutorials.ipynb#L7

There are two issues I've found running this code:

  1. I think shutil.which is only availible for python3 but the ipython notbook defaults to opening in python2. I switched to using subprocess and it works fine
def check_path(path):
    """Check if the specified program is in the PATH and can be run in a shell."""
    import subprocess
    
    checker = subprocess.check_output(['which',path])
    if checker:
        print('SUCCESS: {} found!'.format(path))
        return checker
    else:
        raise OSError('FAILURE: unable to find {}'.format(path))
  1. fatcat and scratch install instructions do not create mononyms for these programs. This is easily resolved:
sudo ln -s /<path>/biojava-protein-comparison-tool-4.0.0/runFATCAT.sh /usr/bin/fatcat
sudo ln -s /media/<path>/SCRATCH-1D_1.1/bin/run_SCRATCH-1D_predictors.sh /usr/bin/scratch

bkellman avatar Apr 30 '18 22:04 bkellman

Thanks! Will implement that

nmih avatar May 10 '18 23:05 nmih