콘테스트 프로젝트 진행 상황
각 Quest를 단계적으로 완성하는 프로젝트입니다.
Quest 1: 개발 환경 구축
2022.08.05
1. MCU 선정
STM32L475VGTx MCU를 선택

2. 소프트웨어 팩 선택
-X cube AI 설정

3.MCU 설정 및 소프트웨어 팩 설정

4. Analyuze 시료
Analyzing model
C:/Users/kjh14/STM32Cube/Repository/Packs/STMicroelectronics/X-CUBE-AI/7.1.0/Utilities/windows/stm32ai analyze --name network -m F:/Util/Software tool/STM/en.fp-ai-sensing1/STM32CubeFunctionPack_SENSING1_V4.0.3/Utilities/AI_Ressources/models/cnn_gmp.h5 --type keras --compression 1 --verbosity 1 --workspace C:\Users\kjh14\AppData\Local\Temp\mxAI_workspace169198008605006123145192526529961 --output C:\Users\kjh14\.stm32cubemx\network_output
Neural Network Tools for STM32AI v1.6.0 (STM.ai v7.1.0-RC3)
Exec/report summary (analyze)
------------------------------------------------------------------------------------------------------------------------
model file : F:\Util\Software tool\STM\en.fp-ai-sensing1\STM32CubeFunctionPack_SENSING1_V4.0.3\Utilities\AI_Ressources\models\cnn_gmp.h5
type : keras
c_name : network
compression : None
workspace dir : C:\Users\kjh14\AppData\Local\Temp\mxAI_workspace169198008605006123145192526529961
output dir : C:\Users\kjh14\.stm32cubemx\network_output
model_name : cnn_gmp
model_hash : 954164d0a35496bd293bb6b3429c6a79
input 1/1 : 'input_0'
72 items, 288 B, ai_float, float, (1,24,3,1), domain:user/
output 1/1 : 'softmax_1'
5 items, 20 B, ai_float, float, (1,1,1,5), domain:user/
params # : 1,477 items (5.77 KiB)
macc : 68,928
weights (ro) : 5,908 B (5.77 KiB) (1 segment)
activations (rw) : 6,976 B (6.81 KiB) (1 segment)
ram (total) : 7,284 B (7.11 KiB) = 6,976 + 288 + 20
Model name - cnn_gmp ['input_0'] ['softmax_1']
-------------------------------------------------------------------------------------------------------------------------------------------------
id layer (type) oshape param/size macc connected to | c_size c_macc c_type
-------------------------------------------------------------------------------------------------------------------------------------------------
0 input_0 (Input) (None,24,3,1) |
quantize_1_conv2d (Conv2D) (None,20,3,16) 96/384 4,816 input_0 | +960(+19.9%) conv2d()[0]
quantize_1 (Nonlinearity) (None,20,3,16) 960 quantize_1_conv2d | -960(-100.0%)
-------------------------------------------------------------------------------------------------------------------------------------------------
1 quantize_2_conv2d (Conv2D) (None,16,3,16) 1,296/5,184 61,456 quantize_1 | +1,536(+2.5%) optimized_conv2d()[1]
quantize_2 (Nonlinearity) (None,16,3,16) 768 quantize_2_conv2d | -768(-100.0%)
-------------------------------------------------------------------------------------------------------------------------------------------------
2 quantize_3 (Pool) (None,1,1,16) 768 quantize_2 | -768(-100.0%)
-------------------------------------------------------------------------------------------------------------------------------------------------
3 quantize_4_dense (Dense) (None,1,1,5) 85/340 85 quantize_3 | dense()[2]
-------------------------------------------------------------------------------------------------------------------------------------------------
4 softmax_1 (Nonlinearity) (None,1,1,5) 75 quantize_4_dense | nl()/o[3]
-------------------------------------------------------------------------------------------------------------------------------------------------
model/c-model: macc=68,928/68,928 weights=5,908/5,908 activations=--/6,976 io=--/308
Complexity report per layer - macc=68,928 weights=5,908 act=6,976 ram_io=308
----------------------------------------------------------------------------------
id name c_macc c_rom c_id
----------------------------------------------------------------------------------
0 quantize_1_conv2d || 8.4% || 6.5% [0]
1 quantize_2_conv2d |||||||||||||||| 91.4% |||||||||||||||| 87.7% [1]
3 quantize_4_dense | 0.1% | 5.8% [2]
4 softmax_1 | 0.1% | 0.0% [3]
Creating txt report file C:\Users\kjh14\.stm32cubemx\network_output\network_analyze_report.txt
elapsed time (analyze): 0.577s
Analyze complete on AI model
5. Network

개발환경 구축 완료
Quest 2: Neural Network Model 생성 개발 환경 구축
2022.08.09
참 어렵네요.....










Analyzing model
C:/Users/kjh14/STM32Cube/Repository/Packs/STMicroelectronics/X-CUBE-AI/7.2.0/Utilities/windows/stm32ai analyze --name network -m C:/Users/kjh14/Desktop/STM32cubeMX.AI/STM32_Quest_AI_Milli_2022/HAR/results/2022_Aug_09_23_46_05/har_IGN.h5 --type keras --compression none --verbosity 1 --workspace C:\Users\kjh14\AppData\Local\Temp\mxAI_workspace5494684707150012727319829777482021 --output C:\Users\kjh14\.stm32cubemx\network_output --allocate-inputs --allocate-outputs
Neural Network Tools for STM32AI v1.6.0 (STM.ai v7.2.0-RC5)
Exec/report summary (analyze)
------------------------------------------------------------------------------------------------------------------------
model file : C:\Users\kjh14\Desktop\STM32cubeMX.AI\STM32_Quest_AI_Milli_2022\HAR\results\2022_Aug_09_23_46_05\har_IGN.h5
type : keras
c_name : network
compression : none
allocator strategy : ['allocate-inputs', 'allocate-outputs']
workspace dir : C:\Users\kjh14\AppData\Local\Temp\mxAI_workspace5494684707150012727319829777482021
output dir : C:\Users\kjh14\.stm32cubemx\network_output
model_name : har_IGN
model_hash : bc22c207ac4187c769cf17ddb0da61e1
input 1/1 : 'input_0'
72 items, 288 B, ai_float, float, (1,24,3,1), domain:activations/**default**
output 1/1 : 'dense_2'
4 items, 16 B, ai_float, float, (1,1,1,4), domain:activations/**default**
params # : 3,064 items (11.97 KiB)
macc : 14,404
weights (ro) : 12,256 B (11.97 KiB) (1 segment)
activations (rw) : 2,016 B (1.97 KiB) (1 segment) *
ram (total) : 2,016 B (1.97 KiB) = 2,016 + 0 + 0
(*) input/output buffers can be used from the activations buffer
Model name - har_IGN ['input_0'] ['dense_2']
------------------------------------------------------------------------------------------------------
id layer (original) oshape param/size macc connected to
------------------------------------------------------------------------------------------------------
0 input_0 (None) [b:None,h:24,w:3,c:1]
conv2d_1_conv2d (Conv2D) [b:None,h:9,w:3,c:24] 408/1,632 10,392 input_0
conv2d_1 (Conv2D) [b:None,h:9,w:3,c:24] 648 conv2d_1_conv2d
------------------------------------------------------------------------------------------------------
1 max_pooling2d_1 (MaxPooling2D) [b:None,h:3,w:3,c:24] 648 conv2d_1
------------------------------------------------------------------------------------------------------
2 flatten_1 (Flatten) [b:None,c:216] max_pooling2d_1
------------------------------------------------------------------------------------------------------
3 dense_1_dense (Dense) [b:None,c:12] 2,604/10,416 2,604 flatten_1
------------------------------------------------------------------------------------------------------
5 dense_2_dense (Dense) [b:None,c:4] 52/208 52 dense_1_dense
dense_2 (Dense) [b:None,c:4] 60 dense_2_dense
------------------------------------------------------------------------------------------------------
model/c-model: macc=14,404/14,404 weights=12,256/12,256 activations=--/2,016 io=--/0
Number of operations per c-layer
-----------------------------------------------------------------------------------
c_id m_id name (type) #op (type)
-----------------------------------------------------------------------------------
0 1 conv2d_1_conv2d (optimized_conv2d) 11,688 (smul_f32_f32)
1 3 dense_1_dense (dense) 2,604 (smul_f32_f32)
2 5 dense_2_dense (dense) 52 (smul_f32_f32)
3 5 dense_2 (nl) 60 (op_f32_f32)
-----------------------------------------------------------------------------------
total 14,404
Number of operation types
---------------------------------------------
smul_f32_f32 14,344 99.6%
op_f32_f32 60 0.4%
Complexity report (model)
------------------------------------------------------------------------------------
m_id name c_macc c_rom c_id
------------------------------------------------------------------------------------
1 max_pooling2d_1 |||||||||||||||| 81.1% ||| 13.3% [0]
3 dense_1_dense |||| 18.1% |||||||||||||||| 85.0% [1]
5 dense_2_dense | 0.8% | 1.7% [2, 3]
------------------------------------------------------------------------------------
macc=14,404 weights=12,256 act=2,016 ram_io=0
Creating txt report file C:\Users\kjh14\.stm32cubemx\network_output\network_analyze_report.txt
elapsed time (analyze): 2.309s
Getting Flash and Ram size used by the library
Model file: har_IGN.h5
Total Flash: 29984 B (29.28 KiB)
Weights: 12256 B (11.97 KiB)
Library: 17728 B (17.31 KiB)
Total Ram: 4000 B (3.91 KiB)
Activations: 2016 B (1.97 KiB)
Library: 1984 B (1.94 KiB)
Input: 288 B (included in Activations)
Output: 16 B (included in Activations)
Done
Analyze complete on AI model
프로젝트 갤러리
프로젝트 제작 과정과 최종 결과물을 담은 이미지 갤러리입니다.








프로젝트 자료실
프로젝트를 재현하거나 학습하는데 필요한 모든 자료를 제공합니다.
등록된 자료가 없습니다.
프로젝트 소개
아직 등록된 프로젝트 소개가 없습니다.
코드 & 회로도
등록된 코드/회로 자료가 없습니다.
댓글 0개
아직 댓글이 없습니다. 첫 댓글을 남겨보세요!
