You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi there, when tying to run CSpred.py I am getting a ValueError.
It was very tricky for me to install the package - this is what I ended up doing:
For system packages i had to install cmake, openblas and gcc-fortran - these are needed for scipy.
I also had to install reduce, as in the first execution it would give me an error: which: no reduce in $PATH
Installation:
# clone repository
git clone https://github.com/THGLab/CSpred
cd CSpred
git checkout SideChain
# setup python env
python3.8 -m venv .venv # does not work on 3.9+source .venv/bin/activate
pip install -r requirements.txt
# download models
mkdir models/
cd models/
## datadryad needs the `user-agent` to resolve the link
wget --user-agent="Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36" \
-O models.tgz \
"https://datadryad.org/stash/downloads/file_stream/242856"
tar -zxvf models.tgz
rm models.tgz
cd ..
# put the binaries in the `PATH`export PATH=$PATH:`pwd`/bins:`pwd`/bins/mTM-align:`pwd`/bins/ncbi-blast-2.9.0+/bin
# get a model from pdb
wget -O 1ccn.pdb "https://files.rcsb.org/download/1CCN.pdb"# execute
python CSpred.py 1ccn.pdb
Error log
python CSpred.py 1ccn.pdb
Calculating UCBShift-Y predictions ...
Calculating using 4 references with maximal identity 1.00
Generating features ...
Warning! No hydrogen atoms found in the structure. Using a structure without hydrogen atoms will significantly detoriate the performance!!!
Hbond KeyError at ('A', (' ', 1, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 2, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 3, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 4, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 5, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 6, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 7, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 8, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 9, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 10, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 11, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 12, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 13, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 14, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 15, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 16, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 17, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 18, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 19, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 20, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 21, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 22, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 23, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 24, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 25, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 26, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 27, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 28, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 29, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 30, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 31, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 32, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 33, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 34, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 35, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 36, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 37, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 38, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 39, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 40, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 41, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 42, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 43, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 44, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 45, ' ')). Skipping this residue
Hbond KeyError at ('A', (' ', 46, ' ')). Skipping this residue
Calculating UCBShift-X predictions for C ...
Traceback (most recent call last):
File "CSpred.py", line 222, in <module>
preds = calc_sing_pdb(args.input, args.pH, TP=not args.shiftx_only, ML=not args.shifty_only, test=args.test)
File "CSpred.py", line 162, in calc_sing_pdb
r0_pred = r0.predict(atom_feats.values)
File "/home/rodrigo/repos/CSpred/.venv/lib/python3.8/site-packages/sklearn/ensemble/_forest.py", line 766, in predict
X = self._validate_X_predict(X)
File "/home/rodrigo/repos/CSpred/.venv/lib/python3.8/site-packages/sklearn/ensemble/_forest.py", line 412, in _validate_X_predict
return self.estimators_[0]._validate_X_predict(X, check_input=True)
File "/home/rodrigo/repos/CSpred/.venv/lib/python3.8/site-packages/sklearn/tree/_classes.py", line 380, in _validate_X_predict
X = check_array(X, dtype=DTYPE, accept_sparse="csr")
File "/home/rodrigo/repos/CSpred/.venv/lib/python3.8/site-packages/sklearn/utils/validation.py", line 567, in check_array
raise ValueError("Found array with %d sample(s) (shape=%s) while a"
ValueError: Found array with 0 sample(s) (shape=(0, 275)) while a minimum of 1 is required.
The error message is not very clear (and I'm not a NMR expert) - could it be that I am providing the wrong input molecule?
The text was updated successfully, but these errors were encountered:
Hi there, when tying to run
CSpred.py
I am getting aValueError
.It was very tricky for me to install the package - this is what I ended up doing:
For system packages i had to install
cmake
,openblas
andgcc-fortran
- these are needed for scipy.I also had to install
reduce
, as in the first execution it would give me an error:which: no reduce in $PATH
Installation:
Error log
The error message is not very clear (and I'm not a NMR expert) - could it be that I am providing the wrong input molecule?
The text was updated successfully, but these errors were encountered: