You are here

Error about rifdocking step 15

5 posts / 0 new
Last post
Error about rifdocking step 15
#1

I am still working on the Cao protocol. And I ran into another problem. When I ran step 15: Motif extraction. I ran the following command:
/home/gaon/cao_protocol/cao_2021_protocol/motif_extraction.py -in:file:silent /home/gaon/cao_protocol/protocol_test_E/input/rifdock_out/fd_output_splits/xaa.silent -ref_pdb /home/gaon/cao_protocol/protocol_test_E/input/output/rif_64_output_sca0.8_noKR.rif.gz_target_chainchanged.pdb -out_prefix mot_

It reported this error:
core.conformation.Conformation: Found disulfide between residues 117 145
length of the binder 65
basic.io.database: Database file opened: scoring/score_functions/elec_cp_reps.dat
core.scoring.elec.util: Read 40 countpair representative atoms
core.pack.dunbrack.RotamerLibrary: shapovalov_lib_fixes_enable option is true.
core.pack.dunbrack.RotamerLibrary: Binary rotamer library selected: /home/gaon/miniconda3/lib/python3.11/site-packages/pyrosetta/database/rotamer/beta_nov2016/Dunbrack10.lib.bin
core.pack.dunbrack.RotamerLibrary: Using Dunbrack library binary file '/home/gaon/miniconda3/lib/python3.11/site-packages/pyrosetta/database/rotamer/beta_nov2016/Dunbrack10.lib.bin'.
core.pack.dunbrack.RotamerLibrary: Dunbrack 2010 library took 0.169196 seconds to load from binary
total score of the complex: -442.187
Traceback (most recent call last):
  File "/home/gaon/cao_protocol/cao_2021_protocol/motif_extraction.py", line 302, in <module>
    graph = get_my_interface_graph(pose)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/gaon/cao_protocol/cao_2021_protocol/motif_extraction.py", line 94, in get_my_interface_graph
    edge = it.__mul__()
           ^^^^^^^^^^
AttributeError: 'pyrosetta.rosetta.utility.graph.EdgeListConstItera' object has no attribute '__mul__'. Did you mean: '__module__'?

Could anyone please help me solve this problem? 

Category: 
Post Situation: 
Sun, 2024-01-21 16:30
ng98

Having a `it.__mul__()` method was a bug that has since been fixed.

Edit the script to use `it.dereference()` instead.

Mon, 2024-01-22 11:02
rmoretti

Hi!I edit the script to use “it.dereference()” instead, but another problem was reported.

core.pack.dunbrack.RotamerLibrary: Binary rotamer library selected: /home/gaon/miniconda3/lib/python3.11/site-packages/pyrosetta/database/rotamer/beta_nov2016/Dunbrack10.lib.bin
core.pack.dunbrack.RotamerLibrary: Using Dunbrack library binary file '/home/gaon/miniconda3/lib/python3.11/site-packages/pyrosetta/database/rotamer/beta_nov2016/Dunbrack10.lib.bin'.
core.pack.dunbrack.RotamerLibrary: Dunbrack 2010 library took 0.17178 seconds to load from binary
total score of the complex: -442.187
Traceback (most recent call last):
  File "/home/gaon/cao_protocol/cao_2021_protocol/motif_extraction.py", line 302, in <module>
    graph = get_my_interface_graph(pose)
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/gaon/cao_protocol/cao_2021_protocol/motif_extraction.py", line 95, in get_my_interface_graph
    it.plus_plus()
    ^^^^^^^^^^^^
AttributeError: 'pyrosetta.rosetta.utility.graph.EdgeListConstItera' object has no attribute 'plus_plus'

Could you please help me with that? Thank you!

And are there any other words needed to be fixed in this module?
 


def get_my_interface_graph(pose):
    energy_graph = pose.energies().energy_graph()

    graph = np.zeros((pose.size()+1, pose.size()+1), float)

    weights = scorefxn.weights()

    it = energy_graph.const_edge_list_begin()
    while it.valid():
        edge = it.dereference()
        it.plus_plus()
        assert( not edge is None )

        low_node = edge.get_first_node_ind()
        high_node = edge.get_second_node_ind()
        if ( pose.chain(low_node) == pose.chain(high_node ) ):
            continue

        assert( low_node < high_node )

        score = edge.dot( weights )

        graph[low_node, high_node] = score

    return graph

Thank you for your help!
 

Mon, 2024-01-22 16:17
ng98

I believe you should replace `it.plus_plus()` with `it.pre_increment()`

I think that should be all you need to do, but I can't say for certain.

Tue, 2024-01-23 07:47
rmoretti

It worked now!Thank you for your answer!

 

Tue, 2024-01-23 16:09
ng98