Skip to content

Commit

Permalink
merged in master
Browse files Browse the repository at this point in the history
  • Loading branch information
nbollis committed Sep 4, 2024
2 parents 0abcd9b + dd5e3b2 commit f9030f9
Show file tree
Hide file tree
Showing 37 changed files with 1,394 additions and 744 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net

name: Build

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]

jobs:
build:
runs-on: ${{ matrix.os }}
name: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
include:
- os: ubuntu-latest
configuration: UbuntuMac
- os: macos-latest
configuration: UbuntuMac
- os: windows-latest
configuration: Release

steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.204
- name: Restore dependencies
run: dotnet restore ./MetaMorpheus/MetaMorpheus.sln
- name: Build
run: dotnet build --no-restore ./MetaMorpheus/MetaMorpheus.sln --configuration ${{ matrix.configuration }}
2 changes: 1 addition & 1 deletion MetaMorpheus/CMD/CMD.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
<PackageReference Include="Microsoft.ML.CpuMath" Version="3.0.1" />
<PackageReference Include="Microsoft.ML.FastTree" Version="3.0.1" />
<PackageReference Include="Microsoft.NETCore.App" Version="2.2.8" />
<PackageReference Include="mzLib" Version="1.0.550" />
<PackageReference Include="mzLib" Version="1.0.551" />
<PackageReference Include="Nett" Version="0.15.0" />
</ItemGroup>

Expand Down
2 changes: 1 addition & 1 deletion MetaMorpheus/EngineLayer/CommonParameters.cs
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ public int DeconvolutionMaxAssumedChargeState
/// This parameter determines which PSMs/Peptides will be used as postive training examples
/// when training the GBDT model for PEP.
/// </summary>
public double QValueCutoffForPepCalculation { get; private set; }
public double QValueCutoffForPepCalculation { get; set; }
public DigestionParams DigestionParams { get; private set; }
public bool ReportAllAmbiguity { get; private set; }
public int? NumberOfPeaksToKeepPerWindow { get; private set; }
Expand Down
2 changes: 1 addition & 1 deletion MetaMorpheus/EngineLayer/EngineLayer.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
<PackageReference Include="Microsoft.ML.CpuMath" Version="3.0.1" />
<PackageReference Include="Microsoft.ML.FastTree" Version="3.0.1" />
<PackageReference Include="Microsoft.NETCore.App" Version="2.2.8" />
<PackageReference Include="mzLib" Version="1.0.550" />
<PackageReference Include="mzLib" Version="1.0.551" />
<PackageReference Include="NETStandard.Library" Version="2.0.3" />
<PackageReference Include="Nett" Version="0.15.0" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
Expand Down
26 changes: 17 additions & 9 deletions MetaMorpheus/EngineLayer/FdrAnalysis/FdrAnalysisEngine.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using System;
using EngineLayer.CrosslinkSearch;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
Expand Down Expand Up @@ -275,18 +276,25 @@ public static void PepQValueInverted(List<SpectralMatch> psms, bool peptideLevel

public void Compute_PEPValue(FdrAnalysisResults myAnalysisResults, List<SpectralMatch> psms)
{
if (psms[0].DigestionParams.Protease.Name == "top-down")
string searchType;
// Currently, searches of mixed data (bottom-up + top-down) are not supported
// PEP will be calculated based on the search type of the first file/PSM in the list, which isn't ideal
// This will be addressed in a future release
switch(psms[0].DigestionParams.Protease.Name)
{
myAnalysisResults.BinarySearchTreeMetrics = PEP_Analysis_Cross_Validation.ComputePEPValuesForAllPSMsGeneric(psms, "top-down", this.FileSpecificParameters, this.OutputFolder);
case "top-down":
searchType = "top-down";
break;
default:
searchType = "standard";
break;
}
else if (psms[0].DigestionParams.Protease.Name == "crosslink")
if (psms[0] is CrosslinkSpectralMatch)
{
myAnalysisResults.BinarySearchTreeMetrics = PEP_Analysis_Cross_Validation.ComputePEPValuesForAllPSMsGeneric(psms, "crosslink", this.FileSpecificParameters, this.OutputFolder);
}
else
{
myAnalysisResults.BinarySearchTreeMetrics = PEP_Analysis_Cross_Validation.ComputePEPValuesForAllPSMsGeneric(psms, "standard", this.FileSpecificParameters, this.OutputFolder);
searchType = "crosslink";
}
myAnalysisResults.BinarySearchTreeMetrics = new PepAnalysisEngine(psms, searchType, FileSpecificParameters, OutputFolder).ComputePEPValuesForAllPSMs();

}

/// <summary>
Expand Down
Loading

0 comments on commit f9030f9

Please sign in to comment.