Thien Hoang Student This is the place I keep notes of what I learnt and what I accomplished.
  • home /
  • gratitude hall /
  • About me /
  • Archive /
  • Categories /
  • support me

12 AUG 2018 • Thoughts / C++
 PINNED POST

A brief overview of Generalized Region Growing, my project at GSoC 2018

So, what I implemented in this package is called “Generalized Region Growing.” You may have heard of Region Growing before. It has a close relationship with Breadth-First Search. This is an excerpted version of the manual of the package Generalized Region Growing, my work at GSoC 2018. I started this package and worked on it during the last three months under the supervision of Dr. Anisimov. I’m very excited to share you what I’ve done this summer!

The authors of this package are me, D. Anisimov, F. Lafarge, and S. Giraudot.


>> Read more

A brief overview of Generalized Region Growing, my project at GSoC 2018 feature image

6 MAR 2021 • Pattern Avoiding Permutations

Inductive proof of the inversion statistic's distribution on permutation set

Greetings, folks. Yes, I’m still alive and I still love writing blogs. Last year (2020) has been a very rough year for me, you know, depression and stuff, but I finally got myself together. I’ll be doing a bachelor thesis on pattern-avoid permutations, particularly trying to prove some equidistributions of some pairs of statistics on two set of PAP. I’m using this blog to take notes of my progress. On the off chance that someone would steal my ideas, I have two things to tell you: 1. I would be very flattered, 2. please don’t do so.

Anyway, when we study Math, it’s important to ask questions and verify what we study. We’re often taught to prove a theorem before going with it. I’m doing the same today: As I was reading Amini’s paper [1], I encountered a very beautiful distribution formula of the inversion statistic, and Dr. Huong Tran, my advisor, told me to prove it. I will present some introductory terminologies first, then present the proof. My proof isn’t very elegant and formal, but it’s pretty intuitive, visual, and intelligible. Hope you’ll like it. :)


>> Read more

15 AUG 2020 • Statistics

Basic Graphing with Matplotlib

I’m reading the book “Probability and Statistics for Engineering and the Sciences” by Jay L. Devore.

Dotplot

Dot plot is a great way to display frequency of values.

Suppose that we have an array of float called data. We will first round all numbers to its nearest integer (round_half_up). This rounding step is to make the graph easy to look.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#%%
data = Utilities.readArray("soundnoise.dat", float)
vround = np.vectorize(Utilities.round_half_up)
data = vround(data)

#%%
def generate_frequency(data):
    result = np.zeros(data.shape, dtype=int)
    cnt = {}
    for i in range(len(data)):
        tmp = cnt.get(data[i])
        if (not tmp):
            tmp = 0
        tmp += 1
        cnt[data[i]] = tmp
        result[i] = tmp
    return result

#%%
y = generate_frequency(data)
fig = plt.figure(figsize=(15,3))
plt.yticks([])
plt.plot(data, y, 'o', color='black')
plt.xlabel("Value")
plt.title("Figure 1.6 A dotplot of the data from Example 1.8")
plt.show()

>> Read more

3 APR 2020 • Algorithm

Manacher's Algorithm

Handwritten notes.


>> Read more

15 MAR 2020 • Machine Learning

Statistical Learning

After a long time of inactivity, I started reading books again. This time my choice is “Introduction to Statistical Learning with Applications in R” (ISLR) by Gareth James et al. I have developed a habit of noting down important points from the book as well as my insights while reading it. This is my notes for Chapter 2.


>> Read more

15 JUL 2019 • MXNET

Automatic Differentiation

Giới thiệu

Trong nhiều bài toán machine learning, chúng ta thường có một hàm để đánh giá xem model của chúng ta đưa ra kết quả chính xác đến mức nào. Hàm đó thường là một hàm đạo hàm được và có output là một số thực.

Một model trong một bài toán machine learning sẽ bao gồm các parameters (tôi được biết chúng còn được gọi là “weights”, nhưng không chắc lắm), với mục đích cố gắng giải thích bộ data có sẵn theo một công thức nào đó. Một hàm mất mát (loss function) sẽ cho chúng ta biết model của chúng ta tốt hay kém. Loss function có output thường có output là một số thực và các parameters nói trên là independent variables. Loss function có thể sử dụng bộ data để tính toán, nhưng bộ data này chỉ được xem là hằng số.

Khi train một model, chúng ta sẽ thay đổi các parameters sao cho model chúng ta fit bộ data đó càng khớp càng tốt, i.e. loss function càng nhỏ càng tốt. Nếu loss function là hàm đạo hàm được, với một giá trị cụ thể của bộ parameters, ta có thể tính được xem loss function tại giá trị đó đang có xu hướng tăng hay giảm và tốc độ thay đổi là bao nhiêu. Đối với một loss function đơn giản, ta có thể tính tay công thức gradient của nó và khi cần tính gradient tại điểm nào thì thay điểm đó vào công thức gradient là ra. Tuy nhiên nếu loss function phức tạp, việc tính toán trở nên cực kỳ khó khăn.


>> Read more

27 MAY 2019 • Health and Medicine

Circulatory System Introduction

Handwritten notes on the Circulatory System of humans.

Page 1

Page 2

Page 3

Page 4

Page 5


>> Read more

16 APR 2019 • Mathematics

1, 2, 3, 4, 5, ...

Notes on the counting techniques (basic and advanced) I learned in the course Discrete Math.


>> Read more

3 APR 2019 • German

Deutsche Grammatik A

Verb

Verb tenses

There are three popular verb tenses:

  • The present tense (Präsens) để miêu tả hiện tại hoặc tương lai
  • The perfect tense (Perfekt) để miêu tả quá khứ, dùng trong văn nói
  • The preterite tense (Präteritum) để miêu tả quá khứ, dùng trong văn viết

>> Read more

9 MAR 2019 • Notes / Topology without Tears

Homeomorphism and Continuous Mapping

A summary of Chapter 4 and 5 of the book “Topology without Tears” by Sidney Morris that I’m reading.


>> Read more

8 MAR 2019 • Notes / Topology without Tears

Limit Points

A summary of Chapter 3 of the book “Topology without Tears” by Sidney Morris that I’m reading.


>> Read more

« Prev 1 2 3 4 5 Next »
© 2021 Thien Hoang.
See this project on GitHub