[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ccp4bb]: CCP4 4.0x AMoRe FITFUN CONV bug



***  For details on how to be removed from this list visit the  ***
***    CCP4 home page http://www.dl.ac.uk/CCP/CCP4/main.html    ***

hi,

i found a bug in CCP4 4.0x AMoRe.

since installing CCP4 4.0 (and now at 4.0.1) my AMoRe rigid body fitting
(FITFUN) scripts are failing.  these identical scripts ran fine before
4.0.  my script and output are below, the error message indicates that the
parser is choking on the number following the "CONV" keyword in the FITFUN
line.

i looked at the code and found the problem, and i can work around it, but
it is not clear to me which direction you will want to go with the
permanent fix. the problem is that
a) the keywords for TRAFUN and FITFUN are handled in the same loop
and
b) a new TRAFUN keyword "CB" | "CO" has been added.  the test for the "CO"
keyword comes before the test for the "CONV" keyword.  as you can see
in the code excerpt below, the "CO" test checks only the first 2
characters of the keyword so it is eating my "CONV".

in amore.f:
.....
      CALL CCPUPC(KEY)
      IF (KEY(1:2).EQ.'CB'.OR.KEY(1:2).EQ.'CO'.OR.KEY(1:3).EQ.'C-O') 
     +    THEN
        TRATYP='CO'
        SCDT = 0.0
.....
      ELSE IF (KEY.EQ.'CONV') THEN
         ITOK = ITOK + 1
        CALL GTPREA(ITOK,EPSNF,NTOK,ITYP,FVALUE)
.....

this could be fixed in a number of ways, here are some possibilities:

1) drop the "CO" keyword, since it seems to be synonymous with "CB" (and
oddly enough with the undocumented "C-O"). i think this would be the best,
although it means retraction of a feature which has already appeared in
the software and documentation. (i.e. you'll have to admit someone screwed
up)

2) change the order of the code. this will mess up the organization of the
keyword testing, since the FITFUN-specific keywords are together at the
end, and there is the possibility of someone in the future neatening it up
again and restoring the bug.

3) make the test for "CO" more specific, perhaps by testing for the length
of the keyword, or see if ITRA = 1.  workable but less than elegant.

4) separate the keyword handling for TRAFUN and FITFUN to 2 separate
loops.

=======================================================================
It is characteristic of thoughtful people that they don't understand some
things that to others are as plain as a pikestaff.  -  A. G. Cairns-Smith
=======================================================================
                        David J. Schuller
                        modern man in a post-modern world
                        University of California-Irvine
                        schuller@uci.edu

-------- script ----------------
#!/bin/csh -f

#####################################################
#    fiting run: 
#####################################################
#
#
amore  \
TABLE1 ../ala5.tab \
hklpck0 ../native5.hkl  \
> fit1001.out <<EOF
FITFUN   NMOL 1   RESO 20 5  ITER 20   CONV  1.E-3
SYMMETRY 4
CRYSTAL  ORTH  1  FLIMI 0 1.E7   SHARP 0.0

REFSOL   AL BE GA  X Z   

 SOLUTIONTF1  1  263.53   42.20   56.24  0.4265  0.0000  0.4792 24.8 57.2   1
EOF
#

------------ output file ---------------
<!--SUMMARY_BEGIN-->




1##########################################################
 ##########################################################
 ##########################################################
 ### CCP PROGRAM SUITE: AMORE       VERSION 4.0: 09/02/00##
 ##########################################################
 User: schuller  Run date: 14/ 2/00  Run time:14:37:00


 Please reference: Collaborative Computational Project, Number 4. 1994.
 "The CCP4 Suite: Programs for Protein Crystallography". Acta Cryst. D50, 760-763.

 as well as any specific reference in the program write-up.


<!--SUMMARY_END-->

 $TEXT:Reference1: $$ comment $$  "AMoRe: an Automated Package for Molecular Replacement",
 J. Navaza (1994).  Acta. Cryst. 50, 157-163.

 $$
 $SUMMARY :Reference1:  $$ Amore: $$
 :TEXT:Reference1: $$
 Data line--- FITFUN   NMOL 1   RESO 20 5  ITER 20   CONV  1.E-3
<!--SUMMARY_BEGIN-->
 AMORE:  Invalid keyword: 1.E-
 Times: User:       0.0s System:    0.0s Elapsed:    0:00
<!--SUMMARY_END-->