From 057f47dd4b542c5ba167ff4d98e395ad3bda63e5 Mon Sep 17 00:00:00 2001 From: Yuxuan Sun Date: Mon, 18 Mar 2024 13:17:14 +0800 Subject: [PATCH] edit --- _posts/2024-02-15-blog-paper-002.md | 84 +++++++++---------------- _posts/2024-03-01-blog-algorithm-001.md | 65 +++++++++++++++++++ 2 files changed, 95 insertions(+), 54 deletions(-) create mode 100644 _posts/2024-03-01-blog-algorithm-001.md diff --git a/_posts/2024-02-15-blog-paper-002.md b/_posts/2024-02-15-blog-paper-002.md index bf0127e..6809854 100644 --- a/_posts/2024-02-15-blog-paper-002.md +++ b/_posts/2024-02-15-blog-paper-002.md @@ -14,16 +14,17 @@ Original paper: O’Sullivan, Hannah, et al. "Integrating terrestrial laser scan This is a record of the reading process, aimed at personal learning, reading and writing practicing. -- [Abstract](#abstract) - [1 Introduction](#1-introduction) - [1.1 Related Work](#11-related-work) - [1.1.1 Methods in Computational Forestry producing QSMs of the Branching Structure](#111-methods-in-computational-forestry-producing-qsms-of-the-branching-structure) - [1.1.2 Methods in Computer Vision producing QSMs of the Branching Structure](#112-methods-in-computer-vision-producing-qsms-of-the-branching-structure) - [1.1.3 Further Open Source Tree Modelling Software and Point Cloud Processing Libraries](#113-further-open-source-tree-modelling-software-and-point-cloud-processing-libraries) - - [1.2 Relevance of the Presented Work in the State of the Art](#12-relevance-of-the-presented-work-in-the-state-of-the-art) + - [1.2 Relevance of the Presented Work in the State of the Art](#12-relevance-of-the-presented-work-in-the-state-of-the-art) - [1.3 Structure of the Manuscript](#13-structure-of-the-manuscript) - [2 Software—SimpleTree](#2-softwaresimpletree) - - [2.1. Filter and Clustering Routines](#21-filter-and-clustering-routines) + - [2.1 Filter and Clustering Routines](#21-filter-and-clustering-routines) + - [2.2 Tree Modeling](#22-tree-modeling) + - [2.3 Point Cloud Processing](#23-point-cloud-processing) Abstract ------ @@ -32,19 +33,19 @@ Abstract * All important functionalities, accessible in the software via buttons and dialogues, are described including the explanation of all necessary input parameters. -## 1 Introduction +# 1 Introduction >The proposed approach results in geometrical models **describing the complete above-ground woody tree components in an hierarchical order**. Such models can be referred to as **Quantitative Structure Models (QSMs)**. [8–11] >The SimpleTree method described here produces **topologically ordered cylinder parameters (size, orientation)** for all branches resolved by the LiDAR data, which can be of the order of thousands of branches per tree. -### 1.1 Related Work +## 1.1 Related Work >Yao et al. [25] predict AGB on plot level utilizing the Diameter at Breast Height (DBH) as an input variable for the following allometric equation: $$ AGB = a \times DBH^b \quad (1) $$ -#### 1.1.1 Methods in Computational Forestry producing QSMs of the Branching Structure +### 1.1.1 Methods in Computational Forestry producing QSMs of the Branching Structure >* In Côté et al. [42] TLS points are subdivided into **wood** and **foliage** components. >* Then **Dijkstra’s algorithm** is applied on the wood points to calculate a skeleton representing the stem and the major branches. @@ -52,11 +53,11 @@ $$ AGB = a \times DBH^b \quad (1) $$ >* Radii for cylinder estimations from the final skeleton are estimated from the **pipe model theory** [43]. >* Finally, foliage is added to the models. -#### 1.1.2 Methods in Computer Vision producing QSMs of the Branching Structure +### 1.1.2 Methods in Computer Vision producing QSMs of the Branching Structure >Here the idea of using sphere-surface cuts with point clouds of trees is utilized. This idea is based on Jayaratna [66] in the field of computer vision. -#### 1.1.3 Further Open Source Tree Modelling Software and Point Cloud Processing Libraries +### 1.1.3 Further Open Source Tree Modelling Software and Point Cloud Processing Libraries >* Computree [70] is an open source platform utilizing TLS clouds. >* Some of the algorithms implemented in Computree are described in detail in Othmani et al. and Ravaglia et al. [71,72]. @@ -67,7 +68,7 @@ $$ AGB = a \times DBH^b \quad (1) $$ >QSMs though have the beneficial potential to model also AGB distributions **within a single tree individual**, see Section 6. -### 1.3 Structure of the Manuscript +## 1.3 Structure of the Manuscript >* **Section 2** describes the functionalities of the presented software. SimpleTree results are compared to the results of the software tool relying on Raumonen et al. [49]. >* In **Section 3** this comparison method is described. @@ -78,59 +79,34 @@ $$ AGB = a \times DBH^b \quad (1) $$ -## 2 Software—SimpleTree +# 2 Software—SimpleTree >* The presented version of software SimpleTree is written in C++. >* The **PCL** library [74] provides efficient functions for the implementation of the method. PCL’s mathematical operations are based on the linear algebra library **Eigen** [79]. k-nearest neighbour searches are performed by the **Fast Library for Approximate Nearest Neighbours (FLANN)** [80]. PCL also ships with its own visualization library based on **VTK (the Visualization Toolkit)** [81]. +## 2.1 Filter and Clustering Routines +>Methodname (a, b) is here-on a wild-card for a method with name Methodname, utilizing input parameters a and b. -### 2.1. Filter and Clustering Routines >* Radius Outlier Removal (r, k) [83], Statistical Outlier Removal (sdMult, k) [83], Voxel Grid Filtering (cellsize) [83] >* **Curvature Filtering** (min1, max1, min2, max2, min3, max3): >* A PCA is performed for each point’s neighbourhood. $\lambda_1$, $\lambda_2$ and $\lambda_3$ denote the normalized Eigenvalues for each point. For all $\lambda_1$ minimum $\text{min}$ and maximum $\text{max}$ value are computed. $\text{min}_1$ and $\text{max}_1$ are percentage numbers. A point is considered an outlier, if its $\lambda_1$ is smaller than $\text{min} + (\text{max} - \text{min})/100 \times \text{min}_1$ or larger than $\text{min} + (\text{max} - \text{min})/100 \times \text{max}_1$. $\lambda_2$ and $\lambda_3$ are processed in the same manner. The thresholds are adjusted with a slider and before the removal-confirmation all noise points are marked via transparency and colourisation in real time according to the slider values (Figure 3). >* 对每个点的邻域执行主成分分析(PCA)。$\lambda_1$、$\lambda_2$ 和 $\lambda_3$ 表示每个点的归一化特征值。对于所有 $\lambda_1$,计算最小值 $\text{min}$ 和最大值 $\text{max}$。$\text{min}_1$ 和 $\text{max}_1$ 是百分比数。如果一个点的 $\lambda_1$ 小于 $\text{min} + (\text{max} - \text{min})/100 \times \text{min}_1$ 或大于 $\text{min} + (\text{max} - \text{min})/100 \times \text{max}_1$,则认为它是一个异常值。$\lambda_2$ 和 $\lambda_3$ 以相同的方式处理。阈值随滑块调整,在移除确认之前,根据滑块值实时通过透明度和着色标记所有噪声点(图3)。 - -* PCA(主成分分析)是一种用于降维和数据可视化的技术,它通过线性变换将数据投影到一个新的坐标系中,以便使得数据的方差在新坐标系下被最大化。 -* $\lambda_1$、$\lambda_2$ 和 $\lambda_3$ 表示每个点在主成分分析中得到的归一化特征值。 -* $\text{min}$ 和 $\text{max}$ 分别表示所有点的特征值中的最小值和最大值。 -* $\text{min}_1$ 和 $\text{max}_1$ 是百分比数,用于设定异常值的阈值。 -* 如果一个点的特征值 $\lambda_1$ 小于 $\text{min} + (\text{max} - \text{min})/100 \times \text{min}_1$ 或大于 $\text{min} + (\text{max} - \text{min})/100 \times \text{max}_1$,则认为它是一个异常值。 -* 类似地,$\lambda_2$ 和 $\lambda_3$ 也按照相同的方式处理。 - -**主成分分析(PCA)** - **基本原理:** - - PCA的基本思想是将原始数据投影到一个新的坐标系中,使得投影后的数据在各个坐标轴上的方差尽可能大,从而保留数据中的大部分信息。具体步骤如下: - - 1. 计算数据的协方差矩阵。 - 2. 对协方差矩阵进行特征值分解,得到特征值和对应的特征向量。 - 3. 将特征向量按照特征值大小降序排列,选取其中方差最大的前几个特征向量作为新的坐标轴。 - 4. 将原始数据投影到选取的特征向量构成的新的低维空间中。 - - **应用:** - - - 降维:PCA可以用于降低数据的维度,保留数据中的主要信息,从而减少计算量和存储空间。 - - 数据可视化:通过将高维数据映射到二维或三维空间中,可以更容易地对数据进行可视化分析。 - - 去噪:PCA可以帮助去除数据中的噪声,保留数据中的信号部分。 - - 特征提取:PCA可以用于提取数据中的主要特征,从而更好地理解数据的结构和特点。 - - **算法步骤:** - - 1. 标准化数据:将原始数据按列进行标准化处理,使得每个特征的均值为0,方差为1。 - 2. 计算协方差矩阵:对标准化后的数据计算协方差矩阵。 - 3. 特征值分解:对协方差矩阵进行特征值分解,得到特征值和对应的特征向量。 - 4. 选取主成分:根据特征值的大小,选取前几个特征向量作为主成分。 - 5. 数据投影:将原始数据投影到选取的主成分构成的新的低维空间中。 - - **注意:** - - - 数据的标准化对PCA的结果影响很大,需要在进行PCA之前对数据进行标准化处理。 - - PCA对数据的线性关系敏感,如果数据存在非线性关系,PCA可能无法有效提取数据的结构信息。 - - 选择合适的主成分数量是一个重要的问题,通常可以通过保留一定比例的方差来确定主成分的数量。 - - - - - + >* [Algorithm: Principal components analysis (PCA)](_posts\2024-03-01-blog-algorithm-001.md) +>* Intensity Filtering (min, max) +>* Crop Sphere | Crop Box (radius) +>* **Euclidean Clustering** (clusterTolerance, minPts, numCluster) [83] + >* A simple but fast spatial clustering operation is applied. The output cloud will contain the numCluster largest clusters containing at least minPts points. If only a smaller number of clusters exists, numCluster is set automatically to this number. Points are separated into two clusters if the distance between the closest point pair exceeds clusterTolerance. This operation is faster than the Density-Based Spatial Clustering of Applications with Noise (DBSCAN) [84], which was used in Hackenberg et al. [10,12]. + >* 应用了一个简单但快速的空间聚类操作。输出云将包含至少包含minPts个点的numCluster个最大的聚类。如果存在较小数量的聚类,则numCluster会自动设置为该数量。如果最近点对之间的距离超过clusterTolerance,则将点分成两个聚类。此操作比密度基空间聚类与噪声应用(DBSCAN)[84]更快,后者在Hackenberg等人的研究中使用[10,12]。 + >* [Euclidean Clustering] + +## 2.2 Tree Modeling + +>* Stem Point Detection [10] () +>* Spherefollowing Method [10,12] (sphereMultiplier, epsClusterStem, epsClusterBranch, epsSphere, minPtsRansacStem, minPtsRansacBranch, minPtsClusterStem, minPtsClusterBranch, minRadiusSphereStem, minRadiusSphereBranch) +>* Parameter Optimization (iterations, criterion, seeds) +>* Allometric improvement (a, b, fac, minRad) +>* Crown Computation (α) + +## 2.3 Point Cloud Processing diff --git a/_posts/2024-03-01-blog-algorithm-001.md b/_posts/2024-03-01-blog-algorithm-001.md new file mode 100644 index 0000000..e377e48 --- /dev/null +++ b/_posts/2024-03-01-blog-algorithm-001.md @@ -0,0 +1,65 @@ +--- +title: 'Algorithm: Principal components analysis (PCA)' +date: 2024-03-01 +permalink: /posts/2024/03/blog-algorithm-001/ +author_profile: true +tags: + - Point Cloud + - Algorithm +--- + +Original paper: Hotelling, Harold. "Analysis of a complex of statistical variables into principal components." Journal of educational psychology 24.6 (1933): 417. [https://doi.org/10.1037/h0071325](https://doi.org/10.1037/h0071325) + +This is a record of the reading process, aimed at personal learning, reading and writing practicing. + +- [Abstract](#abstract) +- [1 Introduction](#1-introduction) + - [1.1 Related Work](#11-related-work) + - [1.1.1 Methods in Computational Forestry producing QSMs of the Branching Structure](#111-methods-in-computational-forestry-producing-qsms-of-the-branching-structure) + - [1.1.2 Methods in Computer Vision producing QSMs of the Branching Structure](#112-methods-in-computer-vision-producing-qsms-of-the-branching-structure) + - [1.1.3 Further Open Source Tree Modelling Software and Point Cloud Processing Libraries](#113-further-open-source-tree-modelling-software-and-point-cloud-processing-libraries) + - [1.2 Relevance of the Presented Work in the State of the Art](#12-relevance-of-the-presented-work-in-the-state-of-the-art) + - [1.3 Structure of the Manuscript](#13-structure-of-the-manuscript) +- [2 Software—SimpleTree](#2-softwaresimpletree) + - [2.1. Filter and Clustering Routines](#21-filter-and-clustering-routines) + + +* PCA(主成分分析)是一种用于降维和数据可视化的技术,它通过线性变换将数据投影到一个新的坐标系中,以便使得数据的方差在新坐标系下被最大化。 + + +**主成分分析(PCA)** + **基本原理:** + + PCA的基本思想是将原始数据投影到一个新的坐标系中,使得投影后的数据在各个坐标轴上的方差尽可能大,从而保留数据中的大部分信息。具体步骤如下: + + 1. 计算数据的协方差矩阵。 + 2. 对协方差矩阵进行特征值分解,得到特征值和对应的特征向量。 + 3. 将特征向量按照特征值大小降序排列,选取其中方差最大的前几个特征向量作为新的坐标轴。 + 4. 将原始数据投影到选取的特征向量构成的新的低维空间中。 + + **应用:** + + - 降维:PCA可以用于降低数据的维度,保留数据中的主要信息,从而减少计算量和存储空间。 + - 数据可视化:通过将高维数据映射到二维或三维空间中,可以更容易地对数据进行可视化分析。 + - 去噪:PCA可以帮助去除数据中的噪声,保留数据中的信号部分。 + - 特征提取:PCA可以用于提取数据中的主要特征,从而更好地理解数据的结构和特点。 + + **算法步骤:** + + 1. 标准化数据:将原始数据按列进行标准化处理,使得每个特征的均值为0,方差为1。 + 2. 计算协方差矩阵:对标准化后的数据计算协方差矩阵。 + 3. 特征值分解:对协方差矩阵进行特征值分解,得到特征值和对应的特征向量。 + 4. 选取主成分:根据特征值的大小,选取前几个特征向量作为主成分。 + 5. 数据投影:将原始数据投影到选取的主成分构成的新的低维空间中。 + + **注意:** + + - 数据的标准化对PCA的结果影响很大,需要在进行PCA之前对数据进行标准化处理。 + - PCA对数据的线性关系敏感,如果数据存在非线性关系,PCA可能无法有效提取数据的结构信息。 + - 选择合适的主成分数量是一个重要的问题,通常可以通过保留一定比例的方差来确定主成分的数量。 + + + + + +