Contents:
digraph model_graph { // Dotfile by Django-Extensions graph_models // Created: 2025-01-28 09:42 // Cli Options: --output ./source/logical-data-model/scaling.dot scaling --exclude-models ModelBase --rankdir BT --group-models --disable-sort-fields --theme=nmd fontname = "Helvetica" fontsize = 18 splines = true rankdir = "TB" newrank = true ranksep = 1 colorscheme = "greens9" size = 500 label = <<B>Logical Data Model</B>> labelloc = "t" splines = true rankdir = "BT" node [ colorscheme = "greens9" fontname = "Helvetica" fontsize = 8 shape = "plaintext" labelloc = "c" width = 2.5 color = 9 fillcolor = 3 ] edge [ fontname = "Helvetica" fontsize = 8 arrowhead = normal arrowtail = none headport = "_" tailport = "_" arrowhead = none; labeldistance = 1.5; labelangle = -45; ] // Labels subgraph cluster_scaling { label = "scaling"; fontsize = 12; color = 1; style = "filled"; colorscheme = "greens9"; labelloc="t"; scaling_models_Scaling [label=<<TABLE BGCOLOR="#FFFFFF" BORDER="1" BORDERCOLOR="#00441b" CELLBORDER="0" CELLSPACING="0" WIDTH="200"><TR><TD COLSPAN="2" CELLPADDING="5" ALIGN="CENTER" BGCOLOR="#c7e9c0" WIDTH="100%"><FONT FACE="Helvetica" COLOR="#000" POINT-SIZE="10"><B>Scaling</B></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><I><B><FONT>id</FONT></B></I></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><I><B><FONT>UUIDField</FONT></B></I></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT COLOR="#7B7B7B" FACE="Helvetica"><I><FONT>created_at</FONT></I></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT COLOR="#7B7B7B" FACE="Helvetica"><I><FONT>DateTimeField</FONT></I></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT COLOR="#7B7B7B" FACE="Helvetica"><I><FONT>updated_at</FONT></I></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT COLOR="#7B7B7B" FACE="Helvetica"><I><FONT>DateTimeField</FONT></I></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><B><FONT>environmental_profile</FONT></B></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><B><FONT>OneToOneField (id)</FONT></B></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>formula</FONT></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>CharField</FONT></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>parameters</FONT></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>ArrayField</FONT></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT COLOR="#7B7B7B" FACE="Helvetica"><FONT>reference_input</FONT></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT COLOR="#7B7B7B" FACE="Helvetica"><FONT>ArrayField</FONT></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT COLOR="#7B7B7B" FACE="Helvetica"><FONT>reference_output</FONT></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT COLOR="#7B7B7B" FACE="Helvetica"><FONT>ArrayField</FONT></FONT></TD></TR></TABLE>>] scaling_models_Dimension [label=<<TABLE BGCOLOR="#FFFFFF" BORDER="1" BORDERCOLOR="#00441b" CELLBORDER="0" CELLSPACING="0" WIDTH="200"><TR><TD COLSPAN="2" CELLPADDING="5" ALIGN="CENTER" BGCOLOR="#c7e9c0" WIDTH="100%"><FONT FACE="Helvetica" COLOR="#000" POINT-SIZE="10"><B>Dimension</B></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><I><B><FONT>id</FONT></B></I></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><I><B><FONT>UUIDField</FONT></B></I></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT COLOR="#7B7B7B" FACE="Helvetica"><I><FONT>created_at</FONT></I></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT COLOR="#7B7B7B" FACE="Helvetica"><I><FONT>DateTimeField</FONT></I></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT COLOR="#7B7B7B" FACE="Helvetica"><I><FONT>updated_at</FONT></I></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT COLOR="#7B7B7B" FACE="Helvetica"><I><FONT>DateTimeField</FONT></I></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><B><FONT>scaling</FONT></B></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><B><FONT>ForeignKey (id)</FONT></B></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>title</FONT></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>CharField</FONT></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><B><FONT>unit</FONT></B></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><B><FONT>ForeignKey (id)</FONT></B></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>minimum</FONT></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>FloatField</FONT></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>maximum</FONT></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>FloatField</FONT></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>inspected_value</FONT></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>FloatField</FONT></FONT></TD></TR><TR><TD ALIGN="LEFT" BORDER="0" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>ordering</FONT></FONT></TD><TD ALIGN="LEFT" WIDTH="100" CELLPADDING="2"><FONT FACE="Helvetica"><FONT>PositiveIntegerField</FONT></FONT></TD></TR></TABLE>>] } // Relations profiles_models_EnvironmentalProfile [label=< <TABLE BGCOLOR="#fdd0a2" BORDER="0" BORDERCOLOR="#7f2704" CELLBORDER="0" CELLSPACING="0"> <TR><TD COLSPAN="2" CELLPADDING="4" ALIGN="CENTER" BGCOLOR="#fdd0a2"> <FONT FACE="Helvetica" POINT-SIZE="12" COLOR="#000">EnvironmentalProfile</FONT> </TD></TR> </TABLE> >] scaling_models_Scaling -> profiles_models_EnvironmentalProfile [label=" environmental_profile (scaling)"] [arrowhead=none, arrowtail=none, dir=both, taillabel="1", headlabel="1"]; scaling_models_Dimension -> scaling_models_Scaling [label=" scaling (dimensions)"] [arrowhead=none, arrowtail=none, taillabel="0..n", headlabel="1" dir=both]; measurement_systems_models_Unit [label=< <TABLE BGCOLOR="#fdd0a2" BORDER="0" BORDERCOLOR="#7f2704" CELLBORDER="0" CELLSPACING="0"> <TR><TD COLSPAN="2" CELLPADDING="4" ALIGN="CENTER" BGCOLOR="#fdd0a2"> <FONT FACE="Helvetica" POINT-SIZE="12" COLOR="#000">Unit</FONT> </TD></TR> </TABLE> >] scaling_models_Dimension -> measurement_systems_models_Unit [label=" unit (dimension)"] [arrowhead=none, arrowtail=none, taillabel="0..n", headlabel="1" dir=both]; }
Fig. 11 Schematic overview of logical data model for Scaling¶
Scaling can be performed using one or more dimensions. Each dimension will have an inspected (reference) value and minimum and maximum value.
id (UUIDField) – Primary key: Id
created_at (DateTimeField) – Created at
updated_at (DateTimeField) – Updated at
title (CharField) – Title
minimum (FloatField) – Minimum
maximum (FloatField) – Maximum
inspected_value (FloatField) – Inspected value
ordering (PositiveIntegerField) – Sorteer op
Relationship fields:
scaling (ForeignKey to Scaling) – Scaling (related name: dimensions)
ForeignKey
Scaling
dimensions
unit (ForeignKey to Unit) – Unit (related name: dimension)
Unit
dimension
Reverse relationships:
legacydimension (Reverse OneToOneField from LegacyDimension) – The legacy dimension of this Dimension (related name of dimension_ptr)
OneToOneField
LegacyDimension
dimension_ptr
Scaling on environmental data is performed using a formula and its parameters. The scaling is always done with respect to a given reference input.
The options for scaling formulas are:
linear power log exp
linear
power
log
exp
formula (CharField) – Formula
parameters (ArrayField) – Parameters
reference_input (ArrayField) – Reference input
reference_output (ArrayField) – Reference output
environmental_profile (OneToOneField to EnvironmentalProfile) – Impact analysis (related name: scaling)
EnvironmentalProfile
scaling
legacyscaling (Reverse OneToOneField from LegacyScaling) – The legacy scaling of this Scaling (related name of scaling_ptr)
LegacyScaling
scaling_ptr
dimensions (Reverse ForeignKey from Dimension) – All dimensions of this Scaling (related name of scaling)
Dimension
An enumeration.