# How to use MHC Epitope energy (mhc_epitope) to deimmunize a protein structure?

6 posts / 0 new
How to use MHC Epitope energy (mhc_epitope) to deimmunize a protein structure?
#1

Dear all,

The MHC Epitope energy (mhc_epitope) alogrithm  (https://www.rosettacommons.org/docs/latest/rosetta_basics/scoring/MHCEpitopeEnergy) is for deimmunization of epitopes. However I cannot understand how to use it.

I used the pdb file 2b3p.pdb and the score controlling script in the introduction webpage as the inputs and run the following command:

rosetta_scripts.default.linuxgccrelease -s 2b3p.pdb -parser:protocol epitope.xml

The content of the "epitope.xml" is:

<ROSETTASCRIPTS>
<SCOREFXNS>
<ScoreFunction name="ref_deimm" weights="ref2015.wts">
<Reweight scoretype="mhc_epitope" weight="1"/>
<Set mhc_epitope_setup_file="propred8_5.mhc"/>
</ScoreFunction>
</SCOREFXNS>
<RESIDUE_SELECTORS>
</RESIDUE_SELECTORS>
<PACKER_PALETTES>
</PACKER_PALETTES>
<MOVE_MAP_FACTORIES>
</MOVE_MAP_FACTORIES>
<SIMPLE_METRICS>
</SIMPLE_METRICS>
<FILTERS>
</FILTERS>
<MOVERS>
</MOVERS>
<PROTOCOLS>
</PROTOCOLS>
<OUTPUT />
</ROSETTASCRIPTS>

I got two files as the output: a "score.sc" file and a "2b3p_0001.pdb" The score.sc file gives various energy terms, but none of them is related to MHC-epitope interaction energy (such as IC50, etc.). And the  2b3p_0001.pdb is exactly the same with the input structure.

As I understand, a deimmunization alogrithm can first predict all epitopes restricted by various MHC alleles in a protein and give the predicted IC50 of these epitopes, and then introduce mutaions in these epitopes so as to reduce the IC50 of the native epitopes. Could anyone tell me how to realize these functions with ROSETTA?

I will appreciate any help!

Best regards.

Category:
Post Situation:
Sun, 2020-11-08 08:07
Sunyp_IM

Hello,

RosettaScripts re-scores using the standard scoring function at the end of the run UNLESS you have placed a scorefunction in the OUTPUT tag. In other words, there is no assumption about the scoring function the user intended and the application does not store the last-used or any other score function information from the xml. To remedy this, put your custom score function which was defined in the  SCOREFXNS block in the OUTPUT tag.

<OUTPUT scorefxn="ref_deimm"/>

Your score file should now have a score term called "mhc_epitope". If this score is non-zero then everything is set up properly for scoring. If it is zero then you'll probably need to revisit the generation of the mhc_epitope_setup_file, especially if this is custom.

From there, you need to add movers in order to design the protein. The PackRotamersMover and FastDesign are the most commonly used for design, but not always. You'll want to add in appropriate TASKOPERATIONS or SELECTORS in order to better control the design process. DesignRestrictions is a task operation which is very useful in this context. Looking at the docs, if you have only a few epitopes that you want to remove then the AddMHCEpitopeConstraintMover would be useful.

Hope that helps.

Mon, 2020-11-09 07:22
nannemdp

Hello nannemdp,

Thank you. you are right. by adding the score function in the OUTPUT tag results in the "mhc_epitope" appearing in the score.sc, which is equal to 72.

However, I tried to use the "AddMHCEpitopeConstraintMover" as introduced in the webpage with the following script:

<ROSETTASCRIPTS>
<SCOREFXNS>
<ScoreFunction name="ref_deimm" weights="ref2015.wts">
<Reweight scoretype="mhc_epitope" weight="1"/>
</ScoreFunction>
</SCOREFXNS>
<RESIDUE_SELECTORS>
<Chain name="chA" chains="A"/>
</RESIDUE_SELECTORS>
<PACKER_PALETTES>
</PACKER_PALETTES>
<MOVE_MAP_FACTORIES>
</MOVE_MAP_FACTORIES>
<SIMPLE_METRICS>
</SIMPLE_METRICS>
<FILTERS>
</FILTERS>
<MOVERS>
</MOVERS>
<PROTOCOLS>
</PROTOCOLS>
<OUTPUT scorefxn="ref_deimm"/>
</ROSETTASCRIPTS>

The "mhc_epitope" value in the score.sc file became 0. I thought that this "AddMHCEpitopeConstraintMover" constrain the mhc_energy calculate to the selected residues, which is chain A here. The input structure has only one chain, the chain A, so I expected the "mhc_epitope" should be also 72. So could you tell me what's wrong here?

Best regards.

Tue, 2020-11-10 07:03
Sunyp_IM

Hello!

Glad that first change helped. The objects in the top-level MOVERS tag are merely definitions (similar to the scorefunctions defined in the SCOREFXNS tag) and they need to be specified in the PROTOCOLS section, like below.

<PROTOCOLS>
</PROTOCOLS>

You might take a look at this tutorial on rosetta_scripts: https://www.rosettacommons.org/demos/latest/tutorials/scripting_with_rosettascripts/scripting_with_rosettascripts. The main page for RosettaScripts is also very useful (https://www.rosettacommons.org/docs/latest/scripting_documentation/RosettaScripts/RosettaScripts) and I do find myself returning to find the correct syntax in certain cases. (Funnily enough OUTPUT is one of those I have to look up regularly :) RosettaScripts is an incredibly flexible piece of software so the reading can become quite lengthy but on the plus side there is a plethora of documentation!

Tue, 2020-11-10 08:14
nannemdp

The concept of deimmunization can be found in a PNAS paper (https://doi.org/10.1073/pnas.1321126111).  The paper introduced a supportive vector machine for predicting T cell epitopes, which is implemented in ROSETTA.  The paper provided a script for deimmunization like the following (I made some revision to the original script becasue it is outdated for the recent ROSETTA version):

<ROSETTASCRIPTS>

<InitializeFromCommandline name="t_init"/>
<IncludeCurrent name="t_useinputsc"/>
<LimitAromaChi2 name="arochi2"/>
<DisallowIfNonnative name="notaa" resnum="0" disallow_aas="CH"/>

<SCOREFXNS>
<ScoreFunction name="ref_deimm" weights="ref2015">
<Reweight scoretype="nmer_ref" weight="3.5"/>
<Reweight scoretype="nmer_svm" weight="2.0"/>
</ScoreFunction>
</SCOREFXNS>

<FILTERS>
<ScoreType name="ref2015" scorefxn="ref_deimm" score_type="total_score" threshold="0" confidence="0"/>
<ScoreType name="total_score_raw" scorefxn="ref_deimm" score_type="total_score" threshold="0" confidence="0"/>
<NMerSVMEnergy name="nmer_svm" dump_table="1" threshold="0" confidence="0"/>
<NetCharge name="chrg" confidence="0"/>
<Delta name="dchrg" filter="chrg" confidence="0"/>
<Operator name="abdchrg" filters="dchrg" operation="ABS" confidence="0"/>
<CombinedValue name="total_score" confidence="0">
</CombinedValue>

</FILTERS>

<MOVERS>
<FavorSequenceProfile name="natcst" use_starting="1" matrix="MATCH" weight="0.2" scorefxns="ref_deimm"/>
<GreedyOptMutationMover name="mut" task_operations="t_useinputsc,t_init,arochi2,notaa,t_dz" filter="total_score" filter_delta="2.0" shuffle_order="1" scorefxn="ref_deimm" relax_mover="min" dump_table="1" parallel="0"/>
</MOVERS>

<PROTOCOLS>
</PROTOCOLS>
<OUTPUT scorefxn="ref_deimm"/>

</ROSETTASCRIPTS>

In table 1 of this PNAS paper, the predicted IC50 of several peptides before and after design. I have tried to use the 2b3p.pdb as the input for running the above script. I indeed found that some residues was mutated in the output structure. However, I only find one energy term related to the script, the "ref_deimmu", which is 0. I wonder wonder whether this value is correct or this is any error in the sripts.

More importantly, I wish to know how to get the predicted IC50 values, the Rosetta energy in table 1 of the PNAS paper, and more than energy values related to the epitopes. Could they be output by just revising the above scripts?

Best regards

Fri, 2020-11-13 07:45
Sunyp_IM

Hi Sunyp_IM.  I am one of the developers of MHCEpitopeEnergy/mhc_epitope.  Thanks for your interest in using it.  I am a bit unclear as to what your scientific problem is, so it is a little bit tricky to make suggestions as to your best course of action.

The paper you mention in your latests post uses "nmer," which is somewhat separate from mhc_epitope.  They both try to accomplish the same thing, but nmer (because of the era when it was written) is not as flexible.  If you want to use the SVM-based predictor, I believe the script you pasted is the one to use.  I am not sure how you would extract IC50 values for individual peptides using nmer as they do in the paper, but I suspect to do that, you would need to use the underlying classes in PyRosetta or C++.

If your goal is to de-immunize a protein using a more generalizable strategy, we designed mhc_epitope for that purpose.  We will hopefully soon have a published article for you to look at, but in the mean time, the pages you linked in your first post are the best resource.  In addition to that, you can also look at a few scripts in the Rosetta repository to see how you might use it.  For example:

Rosetta/main/tests/integration/tests/mhc_epitope/inputs/mhc_epitope.xml

Rosetta/main/tests/scientific/tests/mhc_epitope_energy/mhc_epitope_energy.xml

These are somewhat complicated and require you to set up files related to your specific protein (which I recommend you do), but a minimal example could be something like this:

<ROSETTASCRIPTS>
<SCOREFXNS>
<ScoreFunction name="ref_deimm" weights="ref2015.wts">
<Reweight scoretype="mhc_epitope" weight="1"/>
<Set mhc_epitope_setup_file="propred8_5.mhc"/>
</ScoreFunction>
</SCOREFXNS>

<InitializeFromCommandline name="init"/>
<IncludeCurrent name="inccurrent"/>

<MOVERS>
<FavorSequenceProfile name="favour_native" weight="1.5" use_current="true" matrix="IDENTITY"/>
<ParsedProtocol name="fixedbb" mode="sequence">
</ParsedProtocol>
</MOVERS>

<PROTOCOLS>
</PROTOCOLS>
<OUTPUT scorefxn="ref_deimm"/>
</ROSETTASCRIPTS>

This example should deimmunize a generic protein using ProPred as the predictor for immunogenicity (http://crdd.osdd.net/raghava/propred/).

If you are really interested in extracting detailed IC50 values and that type of thing from a specific design, we also created a few python tools that can be used for that purpose.  You can find them here:

Rosetta/main/tools/mhc_energy_tools/, particularly mhc_score.py

You have to install NetMHCII in order to get the best use out of this.  You can also run NetMHCII (which is a state of the art epitope predictor, but won't de-immunize your protein for you) using their online interface: http://www.cbs.dtu.dk/services/NetMHCII/

Hopefully that helps.  I will try to check back again if you run into trouble or want to provide more details on how to approach this.

Brahm

Wed, 2020-11-18 17:21
Brahm Yachnin