Skip to content

Commit

Permalink
Merge branch 'main' into 29-missmatching-ego-ids-in-segment-results-i…
Browse files Browse the repository at this point in the history
…n-stackoverflow-exception
  • Loading branch information
dominikmaeckel authored Feb 13, 2024
2 parents 69926b2 + 5d4f063 commit 8d3a578
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -76,10 +76,4 @@ tasks.test {
testLogging { events(FAILED, PASSED, SKIPPED) }
}

kotlin.target.compilations.all {
kotlinOptions {
jvmTarget = "11"
// allWarningsAsErrors = true
freeCompilerArgs = listOf("-Xjsr305=strict", "-Xjvm-default=all")
}
}
kotlin { jvmToolchain(17) }
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,19 @@ import tools.aqua.stars.core.metric.metrics.evaluation.ValidTSCInstancesPerProje
import tools.aqua.stars.core.metric.providers.Loggable
import tools.aqua.stars.core.metric.providers.PostEvaluationMetricProvider
import tools.aqua.stars.core.tsc.TSCMonitorResult
import tools.aqua.stars.core.tsc.node.TSCNode
import tools.aqua.stars.core.tsc.projection.TSCProjection
import tools.aqua.stars.core.types.EntityType
import tools.aqua.stars.core.types.SegmentType
import tools.aqua.stars.core.types.TickDataType

/**
* This metric implements the [PostEvaluationMetricProvider] and tracks the number of failed
* monitors.
* This metric implements the [PostEvaluationMetricProvider] and tracks the formulas specified as
* [TSCNode.monitorFunction]s that evaluate to 'false'.
*
* This class implements the [Loggable] interface. It logs and prints the count of missing Monitors
* for each [TSCProjection]. It logs the missing [TSCMonitorResult]s for each [TSCProjection].
* This class implements the [Loggable] interface. It logs and prints the count and names of all
* failing [TSCNode.monitorFunction]s for each [TSCProjection]. It logs the failing
* [TSCMonitorResult]s for each [TSCProjection].
*/
@Suppress("unused")
class FailedMonitorsMetric<
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,13 @@ fun convertJsonData(
}
val egoTickData = checkNotNull(referenceTickData).map { it.clone() }

// Remove all existing ego flags when useEveryVehicleAsEgo is set
if (useEveryVehicleAsEgo) {
egoTickData.forEach { tickData ->
tickData.actors.filterIsInstance<Vehicle>().forEach { it.egoVehicle = false }
}
}

// Set egoVehicle flag for each TickData
var isTickWithoutEgo = false
egoTickData.forEach { tickData ->
Expand Down

0 comments on commit 8d3a578

Please sign in to comment.