|
1 | 1 | package org.labkey.panoramapublic.model.validation; |
2 | 2 |
|
| 3 | +import org.apache.commons.lang3.StringUtils; |
3 | 4 | import org.jetbrains.annotations.NotNull; |
4 | 5 | import org.jetbrains.annotations.Nullable; |
5 | 6 | import org.labkey.panoramapublic.model.speclib.SpecLibInfo; |
@@ -197,7 +198,7 @@ public String getStatusString() |
197 | 198 | } |
198 | 199 | if (isPrositLibrary()) |
199 | 200 | { |
200 | | - return "Prosit Library"; |
| 201 | + return "Prosit / Koina Library"; |
201 | 202 | } |
202 | 203 | if (hasSpectrumFiles() && foundSpectrumFiles() && hasIdFiles() && foundIdFiles()) |
203 | 204 | { |
@@ -301,12 +302,20 @@ public List<String> getMissingIdFileNames() |
301 | 302 |
|
302 | 303 | public boolean isPrositLibrary() |
303 | 304 | { |
304 | | - // For a library based on Prosit we expect only one row in the SpectrumSourceFiles table, |
305 | | - // We expect idFileName to be blank and the value in the fileName column to be "Prositintensity_prosit_publication_v1". |
306 | | - // The value in the fileName column may be different in Skyline 21.1. This code will be have to be updated then. |
| 305 | + // For a library based on Prosit/Koina we expect only one row in the SpectrumSourceFiles table, |
| 306 | + // We expect idFileName to be blank. |
| 307 | + // The value in the fileName column is "Prositintensity_prosit_publication_v1" for versions of Skyline that built |
| 308 | + // the library using the legacy Prosit server. |
| 309 | + // Skyline switched from Prosit to the new Koina framework (https://github.com/ProteoWizard/pwiz/pull/2900). |
| 310 | + // Skyline now prefixes "Koina-" to the model names in the SpectrumSourceFiles.fileName column. |
| 311 | + // For example: Koina-Prosit_2020_intensity_HCD-Prosit_2019_irt where |
| 312 | + // Prosit_2020_intensity_HCD is the intensity model and Prosit_2019_irt is the retention time model. Skyline |
| 313 | + // supports multiple Koina models. |
307 | 314 | if(isBibliospecLibrary() && getSpectrumFiles().size() == 1 && getIdFiles().size() == 0) |
308 | 315 | { |
309 | | - return "Prositintensity_prosit_publication_v1".equals(getSpectrumFiles().get(0).getName()); |
| 316 | + String modelName = getSpectrumFiles().get(0).getName(); |
| 317 | + return "Prositintensity_prosit_publication_v1".equals(modelName) |
| 318 | + || StringUtils.startsWith(modelName, "Koina-"); |
310 | 319 | } |
311 | 320 | return false; |
312 | 321 | } |
|
0 commit comments