Skip to main content

DTOs

Classes with Dto at the end are so called Data Transfer Objects and are classes that are created to hold certain type of data. These classes usually do not provide any functionality other than containing data of a specific type.

Usually these classes are not to be used directly, but in some cases methods will return a Dto class.

In many cases these classes can be used interchangeably with their non-Dto counterpart. F.ex. when creating a SimulationDefinition you can supply a ModelDto or ModelObj for the model parameter.

Reference

CancelSimulationDto

PropertyTypeDescriptionExample value
resultStatusResultStatusDto
simulationIdstringThe unique identifier if the simulation
simulationNamestringSimulation name.
simulationStatusstringSimulation status, See treble.SimulationStatus for values."Created"
cancelledTasksList[CancelTaskDto]List of cancelled tasks.

CancelTaskDto

PropertyTypeDescriptionExample value
sourceIdstring'380a3980-721a-4e80-95df-484f519c525c'
sourceLabelstring
taskTypestring
taskStatusstring
simulationIdstring

CategoryInfoDto

Contains name and number of elements in category.

PropertyTypeDescriptionExample value
namestringName of category.
countintNumber of elements in category.

DeviceDto

Contains information on Device.

PropertyTypeDescriptionExample value
idstringIdentifier of device'380a3980-721a-4e80-95df-484f519c525c'
namestring
descriptionstring
createdAtstring'2023-09-06 10:39:24'
updatedAtstring'2023-09-06 10:39:24'
projectIdstringIdentifier of project this device belongs to.'380a3980-721a-4e80-95df-484f519c525c'
uploadedBystringIdentifier of user that created this device.'380a3980-721a-4e80-95df-484f519c525c'
filenamestring
filesizeint

GeometryObjectInfoDto

PropertyTypeDescriptionExample value
idstring
groupTypeint
surfaceAreafloat
layerNamestring

MaterialDto

PropertyTypeDescriptionExample value
idstring'380a3980-721a-4e80-95df-484f519c525c'
namestring
descriptionstring
categorystring
materialJsonstring
materialMetadataJsonstring
defaultScatteringfloat
userIdstringIdentifier of user that create this material if it's user created.'380a3980-721a-4e80-95df-484f519c525c'
organizationIdstringProvided if material is owned by an organization.'380a3980-721a-4e80-95df-484f519c525c'

MaterialAssignmentDto

PropertyTypeDescriptionExample value
materialIdstring'380a3980-721a-4e80-95df-484f519c525c'
materialNamestring
layerIdstring'380a3980-721a-4e80-95df-484f519c525c'
layerNamestring
scatteringCoefficientfloat

MeshInfoDto

ParameterTypeDescriptionExample value
idstring
taskInfoIdstring
modelDefinitionIdstring
createdAtstring
taskSuccessbool
crossoverFrequencyint
elementCountint
elementsPerWavelengthfloat
basisOrderint
faceCountint
nodeCountint
elementMinLengthfloat
elementMaxLengthfloat
elementMeanLengthfloat
elementStdLengthfloat
volumefloat
smallestElementsstring
meshQualityPercentagefloat
meshQualityIndicatorint
fileDownloadInfoDict

ModelDto

PropertyTypeDescriptionExample value
idstr'380a3980-721a-4e80-95df-484f519c525c'
namestr
descriptionstr
createdAtstr'2023-09-06 10:39:24'
statusstr
statusMessagestr
projectIdstr'380a3980-721a-4e80-95df-484f519c525c'
uploadedBystr'380a3980-721a-4e80-95df-484f519c525c'
filenamestr
filesizeint
geometryLibraryIdstr'380a3980-721a-4e80-95df-484f519c525c'
taskInfoIdstr'380a3980-721a-4e80-95df-484f519c525c'
layersList[ModelLayerDto]
geometryObjectInfoDict[GeometryObjectInfoDto]
geometryGroupTypeToVolumeDict[int, float]

ModelLayerDto

PropertyTypeDescriptionExample value
idstring'380a3980-721a-4e80-95df-484f519c525c'
namestring
model_definition_idstring'380a3980-721a-4e80-95df-484f519c525c'

ProjectEstimateDto

Contains information on estimated runtime and cost of a Project.

PropertyTypeDescriptionExample value
projectIdstr
totalEstimatedRuntimeHoursfloat
totalEstimatedCostInTokensfloat
simulationEstimatesSimulationEstimateDto
resultStatusResultStatusDto

ProjectProgressDto

PropertyTypeDescriptionExample value
projectIdstring'380a3980-721a-4e80-95df-484f519c525c'
projectNamestring
statusstring
projectProgressPercentagefloat
simulationsList[SimulationProgressDto]

ReceiverDto

PropertyTypeDescriptionExample value
receiverTypestring
labelstring
xfloat
yfloat
zfloat
idstring'380a3980-721a-4e80-95df-484f519c525c'
receiverPropertiesReceiverPropertiesDto

ReceiverPropertiesDto

PropertyTypeDescriptionExample value
deviceIdstrUnique identifier of device if receiver is of type Device.'380a3980-721a-4e80-95df-484f519c525c'
azimuthAnglefloatOptional, azimuth angle of receiver, defaults to 0.
elevationAnglefloatOptional, elevation angle of receiver, defaults to 0.
rollAnglefloatOptional, roll angle of receiver, defaults to 0.
spatialRadiusfloatOptional, radius og spatial receivers position, defaults to 0.1m

SdkVersionDto

PropertyTypeDescriptionExample value
updateAvailablebool
majorVersionint
minorVersionint
patchLevelint
changelogstr

SimulationDto

PropertyTypeDescriptionExample value
namestringName of simulation
simulationTypestringType of simulation, DG, GA or Hybrid
impulseLengthSecfloatImpulse response length
crossoverFrequencyintCrossover frequency of simulation.
modelDefinitionIdstring'380a3980-721a-4e80-95df-484f519c525c'
onTaskErrorstringOn task error behaviour if set.
receiversList[ReceiverDto]List of receivers.
sourcesList[SourceDto]List of sources
layerMaterialAssignmentsList[MaterialAssignmentDto]
descriptionstringSimulation description if provided.
energyDecayThresholdEDC threshold if set.
simulationSettingsSimulationSettingsDtoAdvanced simulation settings if provided.
resultStatusResultStatusDto
gpuAllocationStrategystringSimulation GpuAllocationStrategy

SimulationSettingsDto

PropertyTypeDescriptionExample value
speedOfSoundfloatOptional, Speed of sound in the medium, defaults to 343.0.
gaSettingsGaSettingsDtoOptional, settings for the geometrical acoustics solver.
dgSettingsDgSettingsDtoOptional, settings for the wavebased solver.
ambisonicsOrderintAmbisonics order of spatial receivers. allowed values are 0, 1, 2, 4, 6, 8 and 16.
advancedSettingsDict[str, str]Optional, dictionary of advanced settings provided.

GaSettingsDto

PropertyTypeDescriptionExample value
numberOfRaysintNumber of rays to use in raytracer. Default is 25000.
ismOrderintSet order for Image Source Method. Default is 2.
isAirAbsorptionActiveboolEnable or disable air absorption.
ismRayCountintImage Source Method ray count, default is 500.000.
writeOutIsmRayPathsboolOptional, if set as true all ray path data is included in the GA results. This is an advanced setting and can cause the results files to become very large.

DgSettingsDto

PropertyTypeDescriptionExample value
polynomialOrderintSets polynomial order of simulation. Default is 4. This is an advanced setting and should not be changed unless getting advice from Treble first.

SimulationProgressDto

PropertyTypeDescriptionExample value
simulationIdstring'380a3980-721a-4e80-95df-484f519c525c'
simulationNamestring
simulationStatusstring
simulationProgressPercentagefloat
sourcesSourceDto

SimulationEstimateDto

Contains information on estimated runtime and cost of a simulation.

PropertyTypeDescriptionExample value
simulationIdstringIdentifier of simulation'380a3980-721a-4e80-95df-484f519c525c'
simulationNamestring
totalEstimatedRuntimeHoursfloatTotal estimated runtime hours for simulation.
totalEstimatedCostInTokensfloatTotal estimated cost of simulation in tokens.
estimatePerSourceSourceEstimateDtoEstimated broken down by simulation sources.
resultStatusResultStatusDto
meshQualityPercentagefloatSimulation model mesh quality indicator, lower quality usually indicates problems with the model that may increase the runtime and cost.
simulationStatusstring

SimulationResultDto

PropertyTypeDescriptionExample value
simulationIdstr'380a3980-721a-4e80-95df-484f519c525c'
namestr
descriptionstr
sourceResultsListSourceResultDto]
createdAtstr'2023-09-06 10:39:24'
updatedAtstr'2023-09-06 10:39:24'
simulationTypestr

SolveTaskResultDto

PropertyTypeDescriptionExample value
idstring'380a3980-721a-4e80-95df-484f519c525c'
createdAtstring'2023-09-06 10:39:24'
taskTypestringDG, GA, Hybrid,...
subTypestring
sourceIdstring'380a3980-721a-4e80-95df-484f519c525c'
dataFileUrlstringSigned url to the simulation task result IRs as a .zip archive, signed urls have expire within a few hours.
jsonFileUrlstringSigned url to the simulation task results parameters as json, signed urls have expire within a few hours.
resultJsonstring

SourceDto

PropertyTypeDescriptionExample value
sourceTypestring
labelstring
xfloat
yfloat
zfloat
idstring'380a3980-721a-4e80-95df-484f519c525c'
sourcePropertiesSourcePropertiesDto
tasksTaskInfoDto

SourcePropertiesDto

PropertyTypeDescriptionExample value
azimuthAnglefloat
elevationAnglefloat
sourceDirectivityIdstring'380a3980-721a-4e80-95df-484f519c525c'

SourceResultDto

PropertyTypeDescriptionExample value
sourceInfoSourceDto
resultsSolveTaskResultDto

SourceEstimateDto

PropertyTypeDescriptionExample value
sourceIdstring
sourceLabelstring
estimatedRuntimeHoursfloat
estimatedCostInTokensfloat
estimatedGpusAllocatedintEstimated number of GPUs required to run the wave-based part simulation if applicable.

StartProjectDto

PropertyTypeDescriptionExample value
startedList[SimulationDto]
alreadyStartedList[SimulationDto]
alreadyInEndStateList[SimulationDto]

TaskInfoDto

PropertyTypeDescriptionExample value
idstring'380a3980-721a-4e80-95df-484f519c525c'
namestring
taskTypestring
statusstring
createdAtstring'2023-09-06 10:39:24'
startedAtstring'2023-09-06 10:39:24'
completedAtstring'2023-09-06 10:39:24'
progressPercentagefloat
statusMessagestring
taskSubTypestring

ResultStatusDto

When available this object contains information whether the operation attempted was successful. For information on available result codes see Appendix I - ResultCode

PropertyTypeDescriptionExample value
result_codeintResult code, if not 0 then the operation did not complete successfully.
result_code_namestringName of the project
messagestringDescription of project given by the user

Appendix

Appendix I - ResultCode

CodeNameDescription
0Ok
100SimulationNotReady
110SimulationLocked
115SimulationEndState
101SourceDirectivityNotReady
116SourceDirectivityEndState
200InvalidMaterialAssignment
201UnableToValidateMaterialAssignment
202TooManyMeshElementsError
500Error