Skip to content

Commit

Permalink
Merge pull request #221 from TheJacksonLaboratory/release-v1.0.2
Browse files Browse the repository at this point in the history
Release v1.0.2
  • Loading branch information
ielis authored Aug 1, 2022
2 parents 95ca362 + 11b4fcb commit 41ea5f2
Show file tree
Hide file tree
Showing 16 changed files with 143 additions and 102 deletions.
13 changes: 13 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,19 @@
Changelog
=========

------
latest
------

------
v1.0.2
------

- ``SvAnna``
- update dependency versions.
- ``svanna-core``
- Fix bug that assigned wrong score to multi-gene inversions based on promoter overlap.

------
v1.0.1
------
Expand Down
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@
# The short X.Y version.
version = u'1.0'
# The full version, including alpha/beta/rc tags.
release = u'1.0.1'
release = u'1.0.2'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
125 changes: 51 additions & 74 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,20 +9,20 @@
<module>svanna-model</module>
<module>svanna-core</module>
<module>svanna-io</module>
<module>svanna-ingest</module>
<module>svanna-db</module>
<module>svanna-ingest</module>
<module>svanna-configuration</module>
<module>svanna-cli</module>
<module>svanna-benchmark</module>
</modules>
<groupId>org.monarchinitiative.svanna</groupId>
<version>1.0.1</version>
<version>1.0.2</version>
<name>SvAnna</name>

<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.6.7</version>
<version>2.6.10</version>
</parent>

<properties>
Expand All @@ -33,16 +33,8 @@
<maven.compiler.target>${java.version}</maven.compiler.target>

<phenol.version>2.0.0-RC2</phenol.version>
<phenopacket.version>2.0.0</phenopacket.version>
<protobuf.version>3.14.0</protobuf.version>
<silent.genes.version>0.2.0</silent.genes.version>
<htsjdk.version>2.23.0</htsjdk.version>
<spring-boot-starter.version>2.5.1</spring-boot-starter.version>
<svart.version>2.0.0-RC1</svart.version>
<commons-io.version>2.8.0</commons-io.version>
<commons-csv.version>1.7</commons-csv.version>
<commons-compress.version>1.21</commons-compress.version>
<commons-net.version>3.8.0</commons-net.version>
<h2.version>1.4.200</h2.version>
</properties>

<developers>
Expand All @@ -69,38 +61,10 @@

<dependencyManagement>
<dependencies>
<dependency>
<groupId>info.picocli</groupId>
<artifactId>picocli</artifactId>
<version>4.5.2</version>
</dependency>
<dependency>
<groupId>org.monarchinitiative.svart</groupId>
<artifactId>svart</artifactId>
<version>${svart.version}</version>
</dependency>
<dependency>
<groupId>de.charite.compbio</groupId>
<artifactId>jannovar-core</artifactId>
<version>${jannovar.version}</version>
<exclusions>
<exclusion>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
</exclusion>
<exclusion>
<groupId>org.apache.commons</groupId>
<artifactId>commons-compress</artifactId>
</exclusion>
<exclusion>
<groupId>org.testing</groupId>
<artifactId>testing</artifactId>
</exclusion>
<exclusion>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-slf4j-impl</artifactId>
</exclusion>
</exclusions>
<version>2.0.0-RC1</version>
</dependency>
<dependency>
<groupId>org.monarchinitiative.phenol</groupId>
Expand Down Expand Up @@ -137,66 +101,71 @@
<artifactId>silent-genes-io</artifactId>
<version>${silent.genes.version}</version>
</dependency>
<dependency>
<groupId>com.github.samtools</groupId>
<artifactId>htsjdk</artifactId>
<version>${htsjdk.version}</version>
<exclusions>
<exclusion>
<groupId>org.tukaani</groupId>
<artifactId>xz</artifactId>
</exclusion>
</exclusions>
</dependency>

<dependency>
<groupId>org.phenopackets</groupId>
<artifactId>phenopacket-schema</artifactId>
<version>${phenopacket.version}</version>
<exclusions>
<exclusion>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
</exclusion>
</exclusions>
<version>2.0.2</version>
</dependency>
<dependency>
<groupId>com.google.protobuf</groupId>
<artifactId>protobuf-java-util</artifactId>
<version>${protobuf.version}</version>
<version>3.20.1</version>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>31.1-jre</version>
</dependency>
<dependency>
<groupId>com.google.errorprone</groupId>
<artifactId>error_prone_annotations</artifactId>
<version>2.11.0</version>
</dependency>
<dependency>
<groupId>com.github.samtools</groupId>
<artifactId>htsjdk</artifactId>
<version>2.23.0</version>
<exclusions>
<exclusion>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<groupId>org.tukaani</groupId>
<artifactId>xz</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>${commons-io.version}</version>
</dependency>

<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-csv</artifactId>
<version>${commons-csv.version}</version>
<version>1.7</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-compress</artifactId>
<version>${commons-compress.version}</version>
<version>1.21</version>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.8.0</version>
</dependency>
<dependency>
<groupId>commons-net</groupId>
<artifactId>commons-net</artifactId>
<version>${commons-net.version}</version>
<version>3.8.0</version>
</dependency>
<dependency>
<groupId>info.picocli</groupId>
<artifactId>picocli</artifactId>
<version>4.5.2</version>
</dependency>
</dependencies>
</dependencyManagement>

<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-logging</artifactId>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
Expand Down Expand Up @@ -228,13 +197,21 @@
<artifactId>maven-assembly-plugin</artifactId>
<version>3.3.0</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>versions-maven-plugin</artifactId>
<version>2.8.1</version>
<configuration>
<generateBackupPoms>false</generateBackupPoms>
</configuration>
</plugin>
</plugins>
</pluginManagement>

<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<groupId>org.codehaus.mojo</groupId>
<artifactId>versions-maven-plugin</artifactId>
</plugin>
</plugins>
</build>
Expand Down
2 changes: 1 addition & 1 deletion svanna-benchmark/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<parent>
<artifactId>SvAnna</artifactId>
<groupId>org.monarchinitiative.svanna</groupId>
<version>1.0.1</version>
<version>1.0.2</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down
2 changes: 1 addition & 1 deletion svanna-cli/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<parent>
<artifactId>SvAnna</artifactId>
<groupId>org.monarchinitiative.svanna</groupId>
<version>1.0.1</version>
<version>1.0.2</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>svanna-cli</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
footer = Main.FOOTER)
public class Main implements Callable<Integer> {

public static final String VERSION = "svanna-cli v1.0.1";
public static final String VERSION = "svanna-cli v1.0.2";

public static final int WIDTH = 120;

Expand Down
37 changes: 37 additions & 0 deletions svanna-cli/src/test/resources/multigene-inversion.vcf
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
##fileformat=VCFv4.2
##fileDate=2021-01-01T00:00:00.000Z
##INFO=<ID=SVTYPE,Number=1,Type=String,Description="Type of structural variant">
##INFO=<ID=SVLEN,Number=.,Type=Integer,Description="Difference in length between REF and ALT alleles">
##INFO=<ID=END,Number=1,Type=Integer,Description="End position of the structural variant described in this record">
##INFO=<ID=CIPOS,Number=2,Type=Integer,Description="Confidence interval around POS for imprecise variants">
##INFO=<ID=CIEND,Number=2,Type=Integer,Description="Confidence interval around END for imprecise variants">
##INFO=<ID=IMPRECISE,Number=0,Type=Flag,Description="Imprecise structural variation">
##FORMAT=<ID=GT,Number=1,Type=String,Description="Genotype">
##FORMAT=<ID=AD,Number=R,Type=Integer,Description="Read depth per allele">
##FORMAT=<ID=DP,Number=1,Type=Integer,Description="Read depth at this position for this sample">
##contig=<ID=CM000663.2,length=248956422>
##contig=<ID=CM000664.2,length=242193529>
##contig=<ID=CM000665.2,length=198295559>
##contig=<ID=CM000666.2,length=190214555>
##contig=<ID=CM000667.2,length=181538259>
##contig=<ID=CM000668.2,length=170805979>
##contig=<ID=CM000669.2,length=159345973>
##contig=<ID=CM000670.2,length=145138636>
##contig=<ID=CM000671.2,length=138394717>
##contig=<ID=CM000672.2,length=133797422>
##contig=<ID=CM000673.2,length=135086622>
##contig=<ID=CM000674.2,length=133275309>
##contig=<ID=CM000675.2,length=114364328>
##contig=<ID=CM000676.2,length=107043718>
##contig=<ID=CM000677.2,length=101991189>
##contig=<ID=CM000678.2,length=90338345>
##contig=<ID=CM000679.2,length=83257441>
##contig=<ID=CM000680.2,length=80373285>
##contig=<ID=CM000681.2,length=58617616>
##contig=<ID=CM000682.2,length=64444167>
##contig=<ID=CM000683.2,length=46709983>
##contig=<ID=CM000684.2,length=50818468>
##contig=<ID=CM000685.2,length=156040895>
##contig=<ID=CM000686.2,length=57227415>
#CHROM POS ID REF ALT QUAL FILTER INFO FORMAT Sample
chr12 25803195 Something N <INV> 1000 PASS SVTYPE=INV;END=125316602;SVLEN=0 GT:DP:AD 0/1:10:5,5
2 changes: 1 addition & 1 deletion svanna-configuration/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<parent>
<artifactId>SvAnna</artifactId>
<groupId>org.monarchinitiative.svanna</groupId>
<version>1.0.1</version>
<version>1.0.2</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down
2 changes: 1 addition & 1 deletion svanna-core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<parent>
<artifactId>SvAnna</artifactId>
<groupId>org.monarchinitiative.svanna</groupId>
<version>1.0.1</version>
<version>1.0.2</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ private static List<PaddedExon> mapToPaddedExons(Transcript tx, int cdsStart, in
@Override
public double projectImpact(Projection<Gene> projection) {
List<Transcript> transcripts = projection.source().transcriptStream()
.collect(Collectors.toUnmodifiableList());
.collect(Collectors.toList());
double promoterImpact = checkPromoter(projection.route().segments(), transcripts);

double geneImpact = projection.isIntraSegment()
Expand All @@ -134,29 +134,43 @@ public double noImpact() {
return geneFactor;
}

private double checkPromoter(List<Segment> segments, Collection<Transcript> transcripts) {
Set<Segment> nonGapSegments = segments.stream()
.filter(s -> s.event() != Event.GAP)
.collect(Collectors.toSet());
private double checkPromoter(Collection<Segment> segments, Iterable<Transcript> transcripts) {
Iterable<Segment> nonGapSegments = segments.stream()
.filter(s -> !Event.GAP.equals(s.event()))
.collect(Collectors.toList());

double score = Double.NaN;
for (Transcript tx : transcripts) {
int txStart = tx.start();
int promoterStart = txStart - promoterLength;
int promoterStart = Math.max(txStart - promoterLength, 0); // Let's not allow negative start coordinate.
int promoterEnd = txStart + Coordinates.endDelta(tx.coordinateSystem());

for (Segment nonGapSegment : nonGapSegments) {
int segmentStart = nonGapSegment.startOnStrand(tx.strand());
int segmentEnd = nonGapSegment.endOnStrand(tx.strand());
if (Coordinates.overlap(tx.coordinateSystem(), promoterStart, promoterEnd,
nonGapSegment.coordinateSystem(), segmentStart, segmentEnd)) {
double fitness = fitnessWithEvent.get(nonGapSegment.event());
double fitness;
if (Event.INVERSION.equals(nonGapSegment.event())) {
if (Coordinates.aContainsB(CS, segmentStart, segmentEnd, CS, promoterStart, promoterEnd))
// Inversion of an entire promoter is not considered deleterious.
fitness = 1;
else
// The promoter is disrupted by the inversion boundary, hence deleterious.
fitness = fitnessWithEvent.get(Event.INVERSION);
} else {
// All other events are scored using default scoring scheme.
fitness = fitnessWithEvent.get(nonGapSegment.event());
}

// In theory, `fitness + geneFactor * promoterFitnessGain` can be above 1, which does not make sense.
// Let's not allow that to happen.
double bla = Math.min(fitness + geneFactor * promoterFitnessGain, 1.);
fitness = Math.min(bla, geneFactor);
if (Double.isNaN(score) || fitness < score)
score = fitness;
double maxAllowedFitness = Math.min(fitness + geneFactor * promoterFitnessGain, 1.);
fitness = Math.min(maxAllowedFitness, geneFactor);

score = Double.isNaN(score)
? fitness
: Math.min(fitness, score);
}
}
}
Expand Down
2 changes: 1 addition & 1 deletion svanna-db/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<parent>
<artifactId>SvAnna</artifactId>
<groupId>org.monarchinitiative.svanna</groupId>
<version>1.0.1</version>
<version>1.0.2</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down
Loading

0 comments on commit 41ea5f2

Please sign in to comment.