摘要: | 近十年來智慧型手機的發展迅速,隨著軟硬體的提升,應用也跟著多元化。本篇論文將應用智慧型手機上的感測器(加速度器, 陀螺儀, 和重力計等等)來收集資料,並且使用機器語言來分析資料以達到偵測使用者是否處於室內或戶外。使用的機器語言演算法包含kNN, Naive Bayes, ANN和SVM。方法上首先會使用收集到的一部分資料來學習並建構模型; 另一部分的資料會套用這些演算法的模型來顯示預測室內戶外的準確率。接下來會針對可以調整參數的演算法,像是kNN的k值, ANN的隱藏層數量做進一步的效能調校。另一方面也會使用k-fold cross validation 和AUC來驗證建構模型是否過適(overfitting)。最後的實驗結果我們得到SVM在4個演算法中能產生穩定的建構模型與高度準確度。;The indoor/outdoor detection for smartphones has many potential applications. In this thesis, the practice of indoor/outdoor detection is treated as the supervised learning problem. The data are collected from different time and places, which contain features from IMU sensors (i.e., accelerometers, gyroscope, and gravity and so on). A number of machine learning algorithms, including kNN, Naive Bayes, ANN, and SVM, are adopted to build the prediction model using the training dataset, and the performance of different models are verified using the test dataset. The parameters in some models are tuned, such as k value in kNN and the number of hidden layers in ANN, in order to obtain the best prediction performance. On the other hand, 10-fold cross validation and AUC are used to verify if any model overfits the training dataset. At the end, we have identified that SVM with linear kernel has the best and most stable performance for smartphone indoor/outdoor detection among all different learning algorithms. |