Failed attempting to reintegrate peaks. The index 7 must be between 0 and 6

support
Failed attempting to reintegrate peaks. The index 7 must be between 0 and 6 moe  2016-12-16
 
Hi skyline team,

After I trained a peak scoring model I chose "only integrate significant q values" (set to 0.05)and received the below error message.
Could you please advise on how to deal with this issue?

System.Reflection.TargetInvocationException: The index 7 must be between 0 and 6 ---> System.Reflection.TargetInvocationException: The index 7 must be between 0 and 6 ---> System.IndexOutOfRangeException: The index 7 must be between 0 and 6
   at pwiz.Skyline.Model.Results.ChromatogramInfo.GetPeak(Int32 peakIndex) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Model\Results\ChromHeaderInfo.cs:line 2894
   at pwiz.Skyline.Model.TransitionGroupDocNode.UpdateResults(SrmSettings settingsNew, SrmSettingsDiff diff, PeptideDocNode nodePep, TransitionGroupDocNode nodePrevious) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Model\TransitionGroupDocNode.cs:line 1243
   at pwiz.Skyline.Model.TransitionGroupDocNode.ChangeSettings(SrmSettings settingsNew, PeptideDocNode nodePep, ExplicitMods mods, SrmSettingsDiff diff) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Model\TransitionGroupDocNode.cs:line 921
   at pwiz.Skyline.Model.PeptideDocNode.ChangeSettings(SrmSettings settingsNew, SrmSettingsDiff diff, Boolean recurse) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Model\PeptideDocNode.cs:line 817
   at pwiz.Skyline.Model.SrmDocument.<>c__DisplayClass45.<ChangeSettingsInternal>b__35(Int32 i) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Model\SrmDocument.cs:line 926
   at System.Threading.Tasks.Parallel.<>c__DisplayClass17_0`1.<ForWorker>b__1()
   at System.Threading.Tasks.Task.InnerInvokeWithArg(Task childTask)
   at System.Threading.Tasks.Task.<>c__DisplayClass176_0.<ExecuteSelfReplicating>b__0(Object )
   --- End of inner exception stack trace ---
   at pwiz.Skyline.Util.Helpers.WrapAndThrowException(Exception x) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Util\Util.cs:line 1594
   at pwiz.Skyline.Util.ParallelEx.LoopWithExceptionHandling(Action loop, Action`1 catchClause) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Util\Util.cs:line 1783
   at pwiz.Skyline.Model.SrmDocument.ChangeSettingsInternal(SrmSettings settingsNew, SrmSettingsChangeMonitor progressMonitor) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Model\SrmDocument.cs:line 923
   at pwiz.Skyline.Model.MProphetResultsHandler.ChangePeaks(IProgressMonitor progressMonitor) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Model\MProphetResultsHandler.cs:line 140
   at pwiz.Skyline.EditUI.ReintegrateDlg.<>c__DisplayClass7.<OkDialog>b__2(IProgressMonitor pm) in c:\proj\pwiz_x64\pwiz_tools\Skyline\EditUI\ReintegrateDlg.cs:line 103
   at pwiz.Skyline.Controls.LongWaitDlg.RunWork(Action`1 performWork) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Controls\LongWaitDlg.cs:line 228
   --- End of inner exception stack trace ---
   at pwiz.Skyline.Util.Helpers.WrapAndThrowException(Exception x) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Util\Util.cs:line 1594
   at pwiz.Skyline.Controls.LongWaitDlg.PerformWork(Control parent, Int32 delayMillis, Action`1 performWork) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Controls\LongWaitDlg.cs:line 176
   at pwiz.Skyline.Controls.LongWaitDlg.PerformWork(Control parent, Int32 delayMillis, Action`1 performWork) in c:\proj\pwiz_x64\pwiz_tools\Skyline\Controls\LongWaitDlg.cs:line 130
   at pwiz.Skyline.EditUI.ReintegrateDlg.OkDialog() in c:\proj\pwiz_x64\pwiz_tools\Skyline\EditUI\ReintegrateDlg.cs:line 105
 
 
Nick Shulman responded:  2016-12-16
That looks like a bug in Skyline.
I am able to get this error to happen when I try to reintegrate one of my own Skyline documents.
I will try to figure out what is going wrong.
 
Nick Shulman responded:  2016-12-16
It looks like I am able to fix the problem with my Skyline document by doing:
Edit > Manage Results > Rescore

The Skyline document I was looking at was created a few years ago, back when Skyline was less consistent in terms of how many candidate peaks it looked for for each transition, and that inconsistency could cause this error when Skyline later tried to reintegrate.

I can also think of a way that you might be able to get this bug to happen with just the current version of Skyline if you did something tricky involving going into:
Settings > Peptide Settings > Modifications
and then if you change one of your "Isotope Modifications" so that the "Relative Retention Time" is "Unknown", and then later changing it back.

I know that you are already in the process of sending us your data files.

If this bug that you are running into is happening with a different Skyline document than the one you are already sending me, then, if it's not too much trouble, maybe you could send this one along too.

In Skyline, use the menu item:
File > Share > Complete
to create a .zip file containing the Skyline document and supporting files including extracted chromatograms.
 
moe responded:  2016-12-18
Thanks Nick,

I am in the process of trying Edit > Manage Results > Rescore.
It's been running for about 24 hours and still going.

I'm also still uploading my skyline file. The connection has timed out several times (at about 20-30 GB) so I have now split the 64GB file into files of 4.5GB in 7zip and am uploading now. And yes, this is the same document as from my previous post:)

With regard to isotope modification: I added heavy peptides manually via inserting the modified sequence in insert > peptides.


Cheers
Moe
 
moe responded:  2016-12-19
Hi Nick,

Files are uploaded :)
Edit > Manage REsults > rescore worked without error.

After rescoring was done I removed all modifications from peptide settings and tried reintegrating my data again but got the same index error as described above.

Quick question: Is Edit - Manage Results - Rescore equivalent to Edit - Refine- Reintegrate or what does rescoring do?
Cheers
Moe
 
Nick Shulman responded:  2016-12-19
"Rescore" looks at the chromatograms, and figures out where the candidate peaks are based on the shape of the curve. Then, it calculates the "detail scores" which are later used by the peak scoring model to pick the best peak-- these are the scores such as "peak shape" or "coelution" which require looking at the entire chromatogram curve.
You should use "rescore" when you have made a change to your settings which affects peak picking, but you do not need to extract the chromatogram again.
If you are working with a very old Skyline document, you could use "rescore" because more recent versions of Skyline have more scores that they calculate.
When you do "Rescore", Skyline also does a "reintegrate" using the "default" peak scoring model.

You can also do a "reintegrate" after that using some other model that you have trained.

The error that you were running into ("The index 7 must be between 0 and 6") is probably caused by some of your transitions in the same peptide having a different number of candidate peaks. I thought that maybe you had simply used a buggy version of Skyline in the past.

Thanks for sending your data. I will take a look at it and figure out what is going wrong.
 
Nick Shulman responded:  2016-12-20
It looks like the reason that Skyline is having trouble with your data is that the peptide "QSPDPNLWTAVADPYK" appears twice in your document.
One of those peptides has two precursors under it, and the other has only one.

When Skyline goes looking for peaks in the chromatograms, Skyline makes sure that each precursor in a given peptide has the same number of candidate peaks. However, because of the way that the peptide appears twice, with different precursors, this does not work correctly.

This later causes problems when you try to do "reintegrate".

This is definitely a bug in Skyline, and we will figure out how to fix it.
For now, you should just delete the duplicate peptides in your document, or make sure that they have the exact same precursors under them.

Thank you so much for sending me this data. This is an important bug that needs fixing.