diff --git a/.nojekyll b/.nojekyll index 6716880..72a261d 100644 --- a/.nojekyll +++ b/.nojekyll @@ -1 +1 @@ -6c4ea43a \ No newline at end of file +b43917ff \ No newline at end of file diff --git a/goals (Felix Herrmann's conflicted copy 2024-01-29).html b/goals (Felix Herrmann's conflicted copy 2024-01-29).html new file mode 100644 index 0000000..b910e13 --- /dev/null +++ b/goals (Felix Herrmann's conflicted copy 2024-01-29).html @@ -0,0 +1,621 @@ + + + + + + + + + +Digital Twins for Physical Systems + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+ +
+ + +
+ + + +
+ + + + +
+

Goal

+

The overall goal of this course is to bring you to where the current literature is regarding the use of Digital Twins to

+
    +
  • monitor physical systems from indirect measurements
  • +
  • assess uncertainty
  • +
  • control the system
  • +
+

The course will start with introducing topics from traditional Data Assimilation (DA) and Bayesian inference and will make it through to the latest developments in Differential Programming (DP), Simulation-Based Inference (SBI), recursive Bayesian Inference (RBI), and learned RBI through the use of Generative AI.

+
+
+

Course outline

+
    +
  • Introduction +
      +
    • welcome
    • +
    • overview Digital Twins
    • +
  • +
  • Inverse Problems +
      +
    • ill-posedness
    • +
    • Tikhonov regularization
    • +
    • General Formulation
    • +
    • Discrepancy principle
    • +
    • Cross-validation
    • +
  • +
  • Basic Data Assimilation +
      +
    • introduction
    • +
    • adjoint state method
    • +
    • variational data assimilation
    • +
  • +
  • Statistical Inverse Problems

  • +
  • differential programming +
      +
    • reverse-mode = adjoint state
    • +
  • +
  • Advanced Data Assimilation
  • +
  • Neural Density Estimation +
      +
    • generative Networks
    • +
    • Normalizing Flows
    • +
    • conditional Normalizing Flows
    • +
  • +
  • Simulation-based inference +
      +
    • introduction scientific ML
    • +
    • Bayesian inference
    • +
  • +
  • Surrogate Modeling +
      +
    • Fourier Neural Operators FNOs
    • +
  • +
  • Learned Data Assimilation

  • +
+
+
+

Topics

+
+
+

Learning goals

+ + +
+ +
+ +
+ + + + + \ No newline at end of file diff --git a/goals.qmd b/goals.qmd deleted file mode 100644 index cc1390f..0000000 --- a/goals.qmd +++ /dev/null @@ -1,45 +0,0 @@ -# Goal - -The overall goal of this course is to bring you to where the current literature is regarding the use of Digital Twins to - -- monitor physical systems from indirect measurements -- assess uncertainty -- control the system - -The course will start with introducing topics from traditional Data Assimilation (DA) and Bayesian inference and will make it through to the latest developments in Differential Programming (DP), Simulation-Based Inference (SBI), recursive Bayesian Inference (RBI), and learned RBI through the use of Generative AI. - -# Course outline {#sec-outline} - -- Introduction - - welcome - - overview Digital Twins -- Inverse Problems - - ill-posedness - - Tikhonov regularization - - General Formulation - - Discrepancy principle - - Cross-validation -- Basic Data Assimilation - - introduction - - adjoint state method - - variational data assimilation -- Statistical Inverse Problems - - -- differential programming - - reverse-mode = adjoint state -- Advanced Data Assimilation -- Neural Density Estimation - - generative Networks - - Normalizing Flows - - conditional Normalizing Flows -- Simulation-based inference - - introduction scientific ML - - Bayesian inference -- Surrogate Modeling - - Fourier Neural Operators FNOs -- Learned Data Assimilation - - - -# Topics {#sec-topics} - -# Learning goals {#sec-goals} diff --git a/hw/w2-hw01 (Felix Herrmann's conflicted copy 2024-01-29).html b/hw/w2-hw01 (Felix Herrmann's conflicted copy 2024-01-29).html new file mode 100644 index 0000000..ec759b8 --- /dev/null +++ b/hw/w2-hw01 (Felix Herrmann's conflicted copy 2024-01-29).html @@ -0,0 +1,577 @@ + + + + + + + + + + +Digital Twins for Physical Systems - HW 01: Pet Names + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+ +
+ + +
+ + + +
+ +
+
+

HW 01: Pet Names

+
+
Homework
+
+
+ + + +
+ + +
+
Published
+
+

September 14, 2022

+
+
+ + +
+ + + +
+ + +

Add instructions for assignment.

+ + + +
+ +
+ + + + + \ No newline at end of file diff --git a/hw/w3-hw02 (Felix Herrmann's conflicted copy 2024-01-29).html b/hw/w3-hw02 (Felix Herrmann's conflicted copy 2024-01-29).html new file mode 100644 index 0000000..5eac8d9 --- /dev/null +++ b/hw/w3-hw02 (Felix Herrmann's conflicted copy 2024-01-29).html @@ -0,0 +1,577 @@ + + + + + + + + + + +Digital Twins for Physical Systems - HW 02: Data visualization + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+ +
+ + +
+ + + +
+ +
+
+

HW 02: Data visualization

+
+
Homework
+
+
+ + + +
+ + +
+
Published
+
+

September 21, 2022

+
+
+ + +
+ + + +
+ + +

Add instructions for assignment.

+ + + +
+ +
+ + + + + \ No newline at end of file diff --git a/index (Felix Herrmann's conflicted copy 2024-01-29).html b/index (Felix Herrmann's conflicted copy 2024-01-29).html new file mode 100644 index 0000000..ec507e8 --- /dev/null +++ b/index (Felix Herrmann's conflicted copy 2024-01-29).html @@ -0,0 +1,633 @@ + + + + + + + + + +Digital Twins for Physical Systems - Digital Twins for Physical Systems Course Website + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+ +
+ + +
+ + + +
+ +
+
+

Digital Twins for Physical Systems Course Website

+
+ + + +
+ + + + +
+ + + +
+ + +
+

Course overview

+

Course overview from CSE : Digital Twins for Physical Systems

+

IBM defines “A digital twin is a virtual representation of an object or system that spans its lifecycle, is updated from real-time data, and uses simulation, machine learning and reasoning to help decision-making.” During this course, we will explore these concepts and their significance in addressing the challenges of monitoring and control of physical systems described by partial-differential equations. After introducing deterministic & statistical data assimilation techniques, the course switches gears towards scientific machine learning to introduce the technique of simulation-based inference, during which uncertainty is captured with generative conditional neural networks, and neural operators where Fourier Neural Operators act as surrogates for solutions of partial-differential equations. The course concludes by incorporating these techniques into uncertainty-aware Digital Twins that can be used to monitor and control complicated processes such as underground storage of CO2 or management of batteries.

+ +
+
+

Class meetings

+ + + + + + + + + + + + + + + +
MeetingLocationTime
LectureHowey Physics N210Mon & Wed 5:00 - 6:15PM
+
+
+

Prerequisites

+

Numerical Linear Algebra, Statistics, Machine Learning, Experience w/ Python, or Julia

+
+
+

Teaching team

+ + + + + + + + + + + + + + + + + + + + +
NameOffice hoursLocation
Felix J. Herrmann (Instructor)TBDZoom
Rafael Orozco (TA)TBDZoom
+
+
+

Access to Piazza

+

Students are encouraged to post their questions on Piazza on Canvas or Piazza direct, which will be monitored by Rafael Orozco.

+ + +
+ +
+ +
+ + + + + \ No newline at end of file diff --git a/labs/01intro/underfitting_overfitting (Felix Herrmann's conflicted copy 2024-01-29).html b/labs/01intro/underfitting_overfitting (Felix Herrmann's conflicted copy 2024-01-29).html new file mode 100644 index 0000000..2680743 --- /dev/null +++ b/labs/01intro/underfitting_overfitting (Felix Herrmann's conflicted copy 2024-01-29).html @@ -0,0 +1,679 @@ + + + + + + + + + +Digital Twins for Physical Systems + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ +
+ +
+ + +
+ + + +
+ + + + +
+
%matplotlib inline
+
+

============================ Underfitting vs. Overfitting ============================

+

This example shows how underfitting and overfitting arise when using polynomial regression to approximate a nonlinear function, \(y =1.5 \cos (\pi x).\)

+

The plots shows the function \(y(x)\) and the estimated curves of of different degrees.

+

We observe the following:

+ +

We evaluate quantitatively overfitting / underfitting by using cross-validation and then calculating the mean squared error (MSE) on the validation set. The higher the value, the less likely the model generalizes correctly from the training data since it is brittle.

+
+
import numpy as np
+import matplotlib.pyplot as plt
+from sklearn.pipeline import Pipeline
+from sklearn.preprocessing import PolynomialFeatures
+from sklearn.linear_model import LinearRegression
+from sklearn.model_selection import cross_val_score
+
+def true_fun(X):
+    return np.cos(1.5 * np.pi * X)
+
+np.random.seed(0)
+
+n_samples = 30
+degrees = [1, 4, 10, 15]
+
+X = np.sort(np.random.rand(n_samples))
+y = true_fun(X) + np.random.randn(n_samples) * 0.1
+
+plt.figure(figsize=(14, 10))
+for i in range(len(degrees)):
+    ax = plt.subplot(2, 2, i + 1) 
+    plt.setp(ax, xticks=(), yticks=())
+    polynomial_features = PolynomialFeatures(degree=degrees[i],                                            include_bias=False)
+    linear_regression = LinearRegression()
+    pipeline = Pipeline([("polynomial_features", polynomial_features),
+                         ("linear_regression", linear_regression)])
+    pipeline.fit(X[:, np.newaxis], y)
+
+    # Evaluate the models using cross-validation
+    scores = cross_val_score(pipeline, X[:, np.newaxis], y,
+                             scoring="neg_mean_squared_error", cv=10)
+
+    X_test = np.linspace(0, 1, 100)
+    plt.plot(X_test, pipeline.predict(X_test[:, np.newaxis]), label="Model")
+    plt.plot(X_test, true_fun(X_test), label="True function")
+    plt.scatter(X, y, edgecolor='b', s=20, label="Samples")
+    plt.xlabel("x")
+    plt.ylabel("y")
+    plt.xlim((0, 1))
+    plt.ylim((-2, 2))
+    plt.legend(loc="best")
+    plt.title("Degree {}\nMSE = {:.2e}(+/- {:.2e})".format(
+        degrees[i], -scores.mean(), scores.std()))
+plt.show()
+
+
+
+

+
+
+
+
+ + + +
+ +
+ + + + + \ No newline at end of file diff --git a/labs/01intro/underfitting_overfitting-preview.html b/labs/01intro/underfitting_overfitting-preview.html index 2822482..44763f5 100644 --- a/labs/01intro/underfitting_overfitting-preview.html +++ b/labs/01intro/underfitting_overfitting-preview.html @@ -1,7 +1,7 @@ - + @@ -218,7 +218,7 @@
Intro