Skip to content

Commit

Permalink
fix: set default bounds to (-4, 4)
Browse files Browse the repository at this point in the history
  • Loading branch information
MArpogaus committed Jul 18, 2024
1 parent 9ad122e commit 00c83f8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/bernstein_flow/activations/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# author : Marcel Arpogaus <znepry.necbtnhf@tznvy.pbz>
#
# created : 2024-07-12 15:12:18 (Marcel Arpogaus)
# changed : 2024-07-12 15:39:47 (Marcel Arpogaus)
# changed : 2024-07-18 13:00:56 (Marcel Arpogaus)

# %% License ###################################################################
# Copyright 2024 Marcel Arpogaus
Expand Down Expand Up @@ -37,7 +37,7 @@

# %% functions #################################################################
def get_thetas_constrain_fn(
bounds: Tuple[Union[float, None], Union[float, None]] = (None, None),
bounds: Tuple[Union[float, None], Union[float, None]] = (-4, 4),
smooth_bounds: bool = True,
allow_flexible_bounds: bool = False,
fn=tf.math.softplus,
Expand Down

2 comments on commit 00c83f8

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Old Faithful

Learning Curve

Metrics

Min of loss: -0.7479396462440491

Parameter Vector

a1 = array([1.3380579], dtype=float32)
b1 = array([-0.19125363], dtype=float32)
thetas = array([-4.        , -2.1807203 , -0.36144066, -0.3586541 , -0.35852876,
   -0.35848394, -0.3584523 , -0.35841766, -0.35833538, -0.35726658,
    1.9167742 ,  2.9583821 ,  3.99999   ], dtype=float32)

Flow

Results

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bimodal Model

Learning Curve

Learning Curve

Metrics

loss: -0.7282336950302124
val_loss: -0.7441359162330627

Results

Parameter Vector for x = 1

BernsteinFlow:
invert_chain_of_bernstein_bijector_of_scale1_of_shift1:
chain_of_bernstein_bijector_of_scale1_of_shift1:
bernstein_bijector: [-3.0001397 -2.0765703 -1.1530008 -0.24226487 0.02106735 0.21018237
0.21019238 0.21020238 0.21021238 0.21022238 0.21023238 0.21024238
0.21025237 0.21026237 0.21028037 0.2103768 0.2106272 7.0669303
13.923233 ]
scale1: 0.4942110776901245
shift1: 0.5386273264884949

Flow



Bijector


Please sign in to comment.