Argument error when running

Member Site Forums PyRosetta PyRosetta – General Argument error when running

Viewing 2 reply threads
  • Author
    • #1946


        I am trying to run sample script with the provided test_lig.pdb and ATP.params. I have placed the ATP.params file into (in PyRosetta main directory) /rosetta_database/chemical/residue_type_sets/fa_standard/residue_types and added the path of the ATP.params file to the file /rosetta_database/chemical/residue_type_sets/fa_standard/residue_types.txt. When I run the script (in ipython – run I get the following error message.

        In [21]: run
        PYROSETTA_DATABASE environment variable was set to: /home/herath/Research/PyR/rosetta_database; using it….
        PyRosetta 2014 [Rosetta 2014 56891:56891:6efc58f8abb54611ace5a6cdd7e69e6c970a01ef] retrieved from:
        (C) Copyright Rosetta Commons Member Institutions.
        Created in JHU by Sergey Lyskov and PyRosetta Team.

        core.init: Rosetta version from
        core.init: command: PyRosetta -ex1 -ex2aro -constant_seed -database /home/herath/Research/PyR/rosetta_database
        core.init: Constant seed mode, seed=1111111 seed_offset=0 real_seed=1111111
        core.init.random: RandomGenerator:init: Normal mode, seed=1111111 RG_type=mt19937

        ArgumentError Traceback (most recent call last)
        /usr/lib/python2.7/dist-packages/IPython/utils/py3compat.pyc in execfile(fname, *where)
        202 else:
        203 filename = fname
        –> 204 __builtin__.execfile(filename, *where)

        /home/herath/Research/PyR/demo/ in ()
        319 #/rosetta_database/chemical/residue_type_sets/fa_standard/residue_types
        –> 321 sample_ligand_interface(pdb_filename, partners, ligand_params, jobs, job_output)

        /home/herath/Research/PyR/demo/ in sample_ligand_interface(pdb_filename, partners, ligand_params, jobs, job_output)
        108 if ligand_params[0]: # the params list has contents
        109 ligand_params = Vector1(ligand_params)
        –> 110 new_res_set = generate_nonstandard_residue_set(ligand_params)
        111 pose_from_pdb(pose, new_res_set, pdb_filename)
        112 else:

        /home/herath/Research/PyR/demo/ in generate_nonstandard_residue_set(params_list)
        234 # of read_files
        235 elements = ChemicalManager.get_instance().element_set(‘default’)
        –> 236 res_set.read_files(params_list, atoms, elements, mm_atoms, orbitals)
        238 return res_set

        ArgumentError: Python argument types in
        ResidueTypeSet.read_files(ResidueTypeSet, vector1_string, AtomTypeSetCAP, ElementSetCAP, MMAtomTypeSetCAP, OrbitalTypeSetCAP)
        did not match C++ signature:
        read_files(core::chemical::ResidueTypeSet {lvalue}, utility::vector1 > filenames)

        Any help to resolve this would be greatly appreciated.

      • #10156

          The ResidueTypeSet.read_files() method changed signature recently. As the ResidueType set already contains information about the AtomTypeSet, ElementSet, MMAtomTypeSet, and OrbitalTypeSet to use, those parameters were redundant and have been removed.

          So go into and in line 236, change “res_set.read_files(params_list, atoms, elements, mm_atoms, orbitals)” to “res_set.read_files(params_list)”

        • #10163

            Thanks!! It worked.

            I also have a few other questions about using to protein-ligand docking.

            I used protein_ligand.pdb file (attached below) as an input and ran script. It ran without any errors but gave some warnings like
   [ WARNING ] discarding 6 atoms at position 371 in file 2BG9_ChainA.clean.pdb. Best match rsd_type: ASP:NtermProteinFull
   [ WARNING ] discarding 3 atoms at position 372 in file 2BG9_ChainA.clean.pdb. Best match rsd_type: ALA ….

            Also in the terminal it says
            core.pack.task: Packer task: initialize from command line()
            core.pack.interaction_graph.interaction_graph_factory: Instantiating DensePDInteractionGraph
            core.pack.pack_rotamers: built 0 rotamers at 0 positions.
            core.pack.pack_rotamers: IG: 480 bytes
            protocols.geometry.RB_geometry: centroids_by_jump_int called but no interface detected!!
            protocols.geometry.RB_geometry: calling centroids_by_jump…
            core.pack.task: Packer task: initialize from command line()
            protocols.geometry.RB_geometry: centroids_by_jump_int called but no interface detected!!
            protocols.geometry.RB_geometry: calling centroids_by_jump…
            core.pack.task: Packer task: initialize from command line() …….

            I would appreciate any explanations about those warnings and “centroids_by_jump_int called but no interface detected!!” problem and would like to know if there’s any way to solve those. I also attached the complete terminal output when I ran script with protein_ligand.pdb for 1 trajectory.

            One more question. In it says it will output the lowest scoring pose for each trajectory as a PDB file. How can I access other poses for each trajectory (not just the lowest scoring pose) and save them as pdb files or get score values?

            Any suggestions would be greatly appreciated.

          • #10164

              “The discarding … atoms at position” warnings are telling you that Rosetta can’t recognize certain atoms in the input PDB. I’m guessing that it’s the hydrogen atoms in your file. Rosetta currently uses a slightly different (older) atom nomenclature than the PDB does, so it doesn’t always recognize hydrogen atoms. It should be fine, though – Rosetta will rebuild any missing hydrogen atoms from their ideal geometry.

              The “centroids_by_jump_int called but no interface detected” message is due to the fact that Rosetta is having a hard time determining how to split the pose up into two parts partners for docking. How did you set the partners option?

              There isn’t an easy way to access the intermediate poses with as it’s currently set up. What you would have to do is recapitulate the DockMCMProtocol mover (and potentially other movers, depending on what exactly you wanted to output) on the Python level, and add your own output facilities for the intermediate poses.

              A final point I’ll make is that the script was written for small molecule docking. (Generally when we say “ligand” in Rosetta we’re referring to small molecule ligands.) You can possibly re-use it for peptide docking, but it’s not going to be doing as much internal sampling of ligand conformations as might be necessary for good docking results. You may want to look into FlexPepDock protocols, but I don’t know if there’s an example Python script which makes use of that protocol.

            • #10168


                I set the partners option as ‘A_X’. A is the protein chain and X is the ligand chain. I attached the script that I used.

              • #10170

                  Taking a closer look at it, the reason you’re seeing the “centroids_by_jump_int called but no interface detected” is because the protein is getting split up into the two docking partners appropriately, but there’s no interface – the chains are too far apart, so it can’t find any residues where the two partners are touching.

                  As I mentioned, the script is intended to be used for small (non-peptide) molecule docking, where the small molecule has already been placed roughly in the binding pocket of the protein. Rosetta is not currently set up for binding site detection for small molecules.

                  Rosetta *can* do binding site detection of protein-protein interactions, though, but that’s a different protocol/script. Take a look at the script instead, particularly the “low resolution”/”centroid” stage, which does the binding site/binding orientation search between two proteins.

              Viewing 2 reply threads
              • You must be logged in to reply to this topic.