Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Creating Spectral Libraries for Skyline #26

Open
Cyan-00FFF opened this issue Feb 1, 2023 · 6 comments
Open

Creating Spectral Libraries for Skyline #26

Cyan-00FFF opened this issue Feb 1, 2023 · 6 comments
Assignees
Labels
bug Something isn't working enhancement New feature or request

Comments

@Cyan-00FFF
Copy link

Cyan-00FFF commented Feb 1, 2023

Hi, I have a problem with generating spectral library from lipids other than Lipid Mediators. When I try to export the spectral library of for example SMs and send it to skyline / or even export and import manually, it's either empty or half empty.

In general, I need only precursor peaks (m, m+1 and m+2) and I managed to generate a library with these ions (through error messages) but when I import any raw file, it crashes with a report that the library is empty (although I see that these three ions are present).
I got this errors :

FIRST ERROR


Skyline version: 22.2.0.351-28f9b9301 (64-bit)
Installation ID: 65ccb65e-31f1-4508-aef5-8a24be1c7ce4
Exception type: Exception
Error message: Failed loading library 'C:\Users\admin\AppData\Local\Apps\2.0\54Y9TB26.H5C\JKRJ99XD.B21\skyl..tion_e4141a2a22107248_0016.0002_6388bc76fc4672e2\Tools\LipidCreator..\Temp\test.blib'.
Specified cast is not valid.
Format: BiblioSpec
FileRevision: 0
SchemaVersion: 0
FilePath: Generated By LipidCreator


System.Exception: Failed loading library 'C:\Users\admin\AppData\Local\Apps\2.0\54Y9TB26.H5C\JKRJ99XD.B21\skyl..tion_e4141a2a22107248_0016.0002_6388bc76fc4672e2\Tools\LipidCreator..\Temp\test.blib'.
Specified cast is not valid.
Format: BiblioSpec
FileRevision: 0
SchemaVersion: 0
FilePath: Generated By LipidCreator ---> System.InvalidCastException: Specified cast is not valid.
at System.Data.SQLite.SQLiteDataReader.VerifyType(Int32 i, DbType typ)
at System.Data.SQLite.SQLiteDataReader.GetInt32(Int32 i)
at pwiz.Skyline.Model.Lib.BiblioSpecLiteLibrary.CreateCache(ILoadMonitor loader, IProgressStatus status, Int32 percent) in C:\proj\skyline_22_2\pwiz_tools\Skyline\Model\Lib\BiblioSpecLite.cs:line 624
at pwiz.Skyline.Model.Lib.BiblioSpecLiteLibrary.Load(ILoadMonitor loader, IProgressStatus status, Boolean cached) in C:\proj\skyline_22_2\pwiz_tools\Skyline\Model\Lib\BiblioSpecLite.cs:line 1034
--- End of inner exception stack trace ---
at pwiz.Skyline.Model.Lib.BiblioSpecLiteLibrary.Load(ILoadMonitor loader, IProgressStatus status, Boolean cached) in C:\proj\skyline_22_2\pwiz_tools\Skyline\Model\Lib\BiblioSpecLite.cs:line 1200
at pwiz.Skyline.Model.Lib.BiblioSpecLiteLibrary.Load(ILoadMonitor loader) in C:\proj\skyline_22_2\pwiz_tools\Skyline\Model\Lib\BiblioSpecLite.cs:line 995
at pwiz.Skyline.Model.Lib.BiblioSpecLiteLibrary.Load(BiblioSpecLiteSpec spec, ILoadMonitor loader) in C:\proj\skyline_22_2\pwiz_tools\Skyline\Model\Lib\BiblioSpecLite.cs:line 150
at pwiz.Skyline.Model.Lib.LibraryManager.LoadLibrary(LibrarySpec spec, Func`1 getMonitor) in C:\proj\skyline_22_2\pwiz_tools\Skyline\Model\Lib\Library.cs:line 298
at pwiz.Skyline.Model.Lib.LibraryManager.LoadBackground(IDocumentContainer container, SrmDocument document, SrmDocument docCurrent) in C:\proj\skyline_22_2\pwiz_tools\Skyline\Model\Lib\Library.cs:line 123
at pwiz.Skyline.Model.BackgroundLoader.OnLoadBackground(IDocumentContainer container, SrmDocument document) in C:\proj\skyline_22_2\pwiz_tools\Skyline\Model\BackgroundLoader.cs:line 130
Exception caught at:
at pwiz.Skyline.Model.BackgroundLoader.OnLoadBackground(IDocumentContainer container, SrmDocument document) in C:\proj\skyline_22_2\pwiz_tools\Skyline\Model\BackgroundLoader.cs:line 130
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading.ThreadHelper.ThreadStart()

SECOND ERROR

Skyline

An error occurred attempting to import the test library.
Failed loading library 'C:\Users\admin\AppData\Local\Apps\2.0\54Y9TB26.H5C\JKRJ99XD.B21\skyl..tion_e4141a2a22107248_0016.0002_6388bc76fc4672e2\Tools\LipidCreator..\Temp\test.blib'.
Specified cast is not valid.
Format: BiblioSpec
FileRevision: 0
SchemaVersion: 0
FilePath: Generated By LipidCreator

I looked for solution everywhere and could not find help.

I contacted Skyline support, they told me that problem is that .blib file is empty.
They wrote me this :
I see that the value in the "NumSpectra" column is NULL, which causes problems for Skyline. I should probably contact the Lipid Creator programmers and tell them to fix this. The .blib file does not contain any spectra, so, even if you were able to get it to work with Skyline, it would not be useful because it is empty. It might be that there is a different problem going on which is causing that .blib file to be empty.

Let me know if you could help me with this.
Otherwise, this is a great and useful piece of software ! Thank you :)
Dominika

@nilshoffmann
Copy link
Member

nilshoffmann commented Feb 1, 2023

Hi Dominika,
thanks for reporting this issue. I am not completely sure why this would happen at the moment.
May I ask you for some additional information in order to narrow this down, please?
How many transitions were generated in the export / library creation?

From the logs I see that you are running Skyline 22.2 64 Bit. Is this on Windows 10 or 11?
Could you please also provide the version of LipidCreator you are using? You can find the full version under "Help" -> "About", first line in the text box.
Also, please check if there is any log output on the LipidCreator side when you export the library ("Help" -> "Log messages") and paste it here.

Finally, could you please create a minimally reproducible example transition list using LipidCreator (potentially just one lipid) that creates the broken blib, export the project ("File" -> "Export Project") and share it with me? This allows me to run LipidCreator with the exact settings you used.

@Cyan-00FFF
Copy link
Author

Hi Nils, thank you for your response.
Concerning the number of transitions, I tried everything, I started with hundreds, but when I got stuck I tried to generate only 2-5 lipids for simplicity. I also tried to generate lists with only precursors and p + fragments.

I work on Win11, but I tried it also on Win10 with the same result.
Skyline is 22.2.0.351 64bit
LipidCreator version : LipidCreator 1.2.1.787 (built from revision 7458c1f (master) on 2021-08-30 13:33:09Z)
I updated both Skyline and LipidCreator recently.

I am attaching here the exported project and .docx file with printscreens and detailed problem report.
problem report.zip

@Cyan-00FFF
Copy link
Author

These are the log messages :

2023-02-01 14:17:33,564 [1] INFO LipidCreator.LipidCreator - LipidCreator is connected to Skyline version '22,2,0,351'. Project file: ''
2023-02-01 14:17:33,577 [1] INFO LipidCreator.LipidCreator - Running LipidCreator version 1.2.1.787 in skyline tool mode on Win32NT
2023-02-01 14:17:33,577 [1] INFO LipidCreator.LipidCreator - Using C:\Users\admin\AppData\Local\Apps\2.0\54Y9TB26.H5C\JKRJ99XD.B21\skyl..tion_e4141a2a22107248_0016.0002_6388bc76fc4672e2\Tools\LipidCreator as base directory for relative resource lookup. Resolved executing assembly location: C:\Users\admin\AppData\Local\Apps\2.0\54Y9TB26.H5C\JKRJ99XD.B21\skyl..tion_e4141a2a22107248_0016.0002_6388bc76fc4672e2\Tools\LipidCreator\LipidCreator.exe
2023-02-01 14:17:33,578 [4] INFO LipidCreator.LipidCreator - Opening connection to Skyline through pipe 470ea9d6-8338-4be5-a4fd-58349f0ac0d4
2023-02-01 14:17:33,578 [4] INFO LipidCreator.LipidCreator - Connected to Skyline through pipe 470ea9d6-8338-4be5-a4fd-58349f0ac0d4
2023-02-01 14:20:35,932 [1] ERROR LipidCreator.LipidCreator - MoleculeGroup,PrecursorName,PrecursorFormula,PrecursorAdduct,PrecursorMz,PrecursorCharge,ProductName,ProductFormula,ProductAdduct,ProductMz,ProductCharge,Note,PrecursorCE
"PC","PC 12:0-12:0","C32H64NO8P","[M+H]1+",622.4442,+1,"precursor","C32H64NO8P","[M+H]1+",622.4442,+1,"",""
"PC","PC 12:0-12:0","C32H64NO8P","[M+H]1+",622.4442,+1,"HG(PC,184)","C5H14NO4P","[M+H]1+",184.0733,+1,"",""

@Cyan-00FFF
Copy link
Author

I have an update. I realized that part of the problem is that I have got one older broken library open in skyline (called test.blib) and this was causing all the errors. I deleted this empty library and now it seems to be working.

I also found that problem was that in LipidCreator I set Filter -> Precursor Filter -> Compute only precursor transitions.
This created that broken empty test.blib, which got stuck and would not let me import new libraries.

@nilshoffmann
Copy link
Member

Thanks for the phenomenal bug report :-). Glad that you were able to spot and work around the issue. I think we may need to add additional checks for the export concerning the CE module being active but unsupported lipids being included in the transition list. Also avoiding export of empty libraries should also be checked on our side. We will schedule to fix this in the next minor release.

@nilshoffmann nilshoffmann self-assigned this Feb 1, 2023
@nilshoffmann nilshoffmann added bug Something isn't working enhancement New feature or request labels Feb 1, 2023
@nilshoffmann nilshoffmann added this to the LipidCreator 1.2.2 milestone Feb 1, 2023
@Cyan-00FFF
Copy link
Author

Thanks and good luck with your work :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants