commit f8d232e793b81d159f92e7e7ea6e46a5bb85e614
parent 73dfbb62270c6a6d5948be7cb8a7e3cc1b8bc352
Author: ling0x <ling0x@users.noreply.github.com>
Date: Fri, 12 Jun 2026 11:30:44 +0100
knowledge
Diffstat:
4 files changed, 109 insertions(+), 41 deletions(-)
diff --git a/async_programming/async_futures.md b/async_programming/async_futures.md
@@ -1,4 +1,4 @@
-# Async Futures
+# Coroutines and async/await
These two signatures are functionally equivalent — `async fn` is just syntactic
sugar that the compiler desugars into the explicit `impl Future` form.
@@ -15,47 +15,18 @@ trait T {
}
```
-### Question: whats the different between:
+Similar to how JavaScript rewrites an await function into a normal function with
+promises, when you write this in Rust:
```rust
-fn create_user(user: NewUser, pool: &Pool<Postgres>) -> impl std::future::Future<Output = sqlx::Result<User>> + Send;
+async fn run() -> () {...}
```
-and
+It becomes:
```rust
-async fn create_user(user: NewUser, pool: &Pool<Postgres>) -> sqlx::Result<User>;
+Fn run() -> impl Future<Ouput = ()>
```
-## What the compiler does
-
-When you write:
-
-```rust
-async fn create_user(user: NewUser, pool: &Pool<Postgres>) -> sqlx::Result<User>
-```
-
-The compiler automatically rewrites it to something like:
-(rust-lang)[https://blog.rust-lang.org/inside-rust/2022/11/17/async-fn-in-trait-nightly.html]
-
-```rust
-fn create_user(user: NewUser, pool: &Pool<Postgres>) -> impl Future<Output = sqlx::Result<User>> + '_
-```
-
-So the first signature in your example is just the explicit version of what
-async fn does implicitly.
-
-The + Send detail The most important practical difference in your specific
-example is the explicit `+ Send` bound on the first signature. This guarantees
-the returned future is safe to send across threads, which is required when
-spawning tasks with `tokio::spawn`. With `async fn`, whether the future is
-`Send` is inferred from the function body — if any non-`Send` type is held
-across an .await` point, the compiler will reject it without giving you an
-explicit contract.
-[rust-lang](https://rust-lang.github.io/async-book/part-guide/more-async-await.html)
-
-
-So the explicit form is useful when you're writing trait objects, function
-pointers, or want to enforce `Send` as part of a public API contract, while
-`async
-fn` is preferred for everyday use.
+The Rust futures we use today have a lot in common with how `async/await` works
+in JavaScript.
diff --git a/linear_algebra/geometry/links.md b/linear_algebra/geometry/links.md
@@ -0,0 +1,13 @@
+# Tesseract
+
+https://en.wikipedia.org/wiki/Tesseract
+
+# Geometric Continuity
+
+C1, G1 Surfaces, etc.:
+
+https://en.wikipedia.org/wiki/Smoothness#Geometric_continuity
+
+# Mobius Strip
+
+https://en.wikipedia.org/wiki/M%C3%B6bius_strip
diff --git a/machine_learning/concepts.md b/machine_learning/concepts.md
@@ -1,15 +1,49 @@
# Concepts
-## Concepts
-
-### ONNX
+## ONNX
Machine learning data are often stored in `.onnx` format
[ONNX Documentation](https://onnx.ai/onnx/index.html)
-### Image processing kernal
+## Image processing kernal
They are basically matrices
[Image processing kernel](https://en.wikipedia.org/wiki/Kernel_(image_processing))
+
+## VAE (Variational autoencoder)
+
+https://en.wikipedia.org/wiki/Variational_autoencoder
+
+Input -> Encoder -> Latent Space -> Decoder -> Output
+
+## Vector database
+
+The vector set of 3D models is the same as the vector database
+
+https://en.wikipedia.org/wiki/Vector_database
+
+if you convert a word, mesh or other object into a vector, you can use classic
+trig to calculate how alike two objects are:
+
+such as Cosine Similarity
+
+```
+Sim(A,B) = cos(θ) = A ⋅ B / ||A|| ||B||
+```
+
+so when we convert meshes to vectors it enables us to classify different meshes.
+
+It's a sequence of simple steps pipelined into each other.
+
+## Loss function
+
+AI is essentially taking small steps to make a small loss function:
+
+https://en.wikipedia.org/wiki/Loss_function
+
+The loss function can be built around things like wind drag, so the cost
+function gets larger the more drag, so the AI takes steps to alter the
+parameters to reduce the drag, but we can also make other loss functions for
+anything, like architecture, etc.
diff --git a/machine_learning/variational_autoencoders.md b/machine_learning/variational_autoencoders.md
@@ -0,0 +1,50 @@
+# VAE
+
+https://en.wikipedia.org/wiki/Variational_autoencoder
+
+## Difference between Variational Autoencoder and 3d morphing in traditional animation:
+
+3D object morphing is a traditional graphics technique that creates animations
+by linearly interpolating vertex positions between manually created 3D meshes.
+In contrast, a Variational Autoencoder (VAE) is a deep learning generative model
+that learns underlying data distributions to synthesize entirely new 3D shapes
+or procedural animations.
+
+- 3D Object Morphing (3D face mesh refinements)
+
+https://en.wikipedia.org/wiki/Morph_target_animation
+
+Morphing, utilizing morph targets or blend shapes, changes the geometry of a
+base object by saving the positional differences of its individual vertices.
+Animators blend these predefined target meshes using weight values, making the
+technique highly effective for precise, repeatable movements like character
+facial expressions.
+
+This traditional method strictly requires all target meshes to share the exact
+same number of vertices and underlying topology to calculate the interpolation
+properly.
+
+- Variational Autoencoders
+
+https://en.wikipedia.org/wiki/Variational_autoencoder
+
+A VAE is a neural network architecture used in machine learning to
+probabilistically encode 3D objects, videos, or motion capture data into a
+continuous latent space. By sampling from this mathematical space, the model can
+generate novel 3D shapes, predict missing structural parts, or create procedural
+animations.
+
+Unlike traditional morphing, VAEs learn from massive datasets to generate
+complex outputs without relying on manual, one-to-one vertex matching.
+
+# Variational Autoencoders (VAEs) in AI Generation
+
+In a generative AI pipeline, a VAE is used to encode complex 3D structures (like
+meshes or voxel data) into a compressed, continuous mathematical "latent space".
+Because this latent space is continuous and probabilistic, an AI model can pick
+a random point between encoded data points and decode it into a brand-new,
+structurally coherent 3D object that never existed in the training data. VAEs
+are commonly paired with diffusion models or Generative Adversarial Networks
+(GANs) to generate 3D assets, character animations, or even full indoor scene
+layouts. Recent architectures like the Multi-scale 3D VQVAE can even generate
+high-quality 3D objects autoregressively in under a second.