32 Commits

Author SHA1 Message Date
Layla b9af93c74b Add percentile PTQ method in ncnn2table (#6854) 2026-10-09 10:33:34 +08:00
Layla 3724d10fc8 tools:Move Embed/MHA/RNN/LSTM/GRU weight scale generation to ncnn2table (#6688)
Co-authored-by: nihui <nihuini@tencent.com>
2026-05-18 19:38:07 +08:00
nihui 171b9d1bba use spdx license header, copyright Tencent (#6152) 2025-07-08 11:01:29 +08:00
shacon wang 701f53794d add read npy for ncnn2table (#5930)
* add read npy for ncnn2table

* optimize npy to mat to avoid non-contiguous memory data

* add create the calibration table from npy

* add catch exception
2025-03-18 16:50:36 +08:00
nihui 1e4daff075 fix ncnn tools crash with compound layer creation, write gemm weight data (#5416)
* fix ncnn tools crash with compound layer creation

* write gemm weight data
2024-04-10 15:09:08 +08:00
nihui 5400028e12 fix ncnn2table crash in lightmode (#3898)
* fix crash in ncnn2table for missing weight data in lightmode

* Update modelwriter.h
2022-06-08 19:26:44 +08:00
lsdustc fd1d5bb2ba Update ncnn2table.cpp (#3081)
修正eq 校准中imagelists错误的索引
2021-07-14 16:24:00 +08:00
Jimmy 8fad97cc68 [ncnn2table]do not always resize image (#3023)
* it's possible not to resize image
2021-06-24 19:48:47 +08:00
Jimmy e47ab30cf5 fix ncnn2table specification (#3006) 2021-06-17 10:38:20 +08:00
nihui 71bc617a05 better ncnn2table multithreading, print parsed parameters, print progress 2021-05-29 21:43:29 +08:00
nihuini 312c7372c1 fix norm parsing for long decimal 2021-05-28 17:19:27 +08:00
nihuini 00b0094b2f copy-pasta makes msvc happy 2021-05-20 19:23:36 +08:00
nihuini 9a12597dff build ncnn quantization tool even opencv not found 2021-05-20 17:51:56 +08:00
nihuini 34bd5ef161 update eq quant info 2021-04-29 10:44:08 +08:00
nihuini d021079cd3 implement ncnn2table eq method 2021-04-28 15:51:58 +08:00
nihui 7d10e5593b fix build 2021-04-27 23:22:16 +08:00
nihuini 45e548e342 rewrite ncnn2table tool, with better multithreading processing 2021-04-27 19:35:46 +08:00
nihui 54c0a13b9f build shared library (#2525)
* build shared lib and enable lto

* reserved for layer and option

* allocator pimpl

* datareader pimpl

* paramdict pimpl, disable copy assign for allocator and datareader

* modelbin pimpl

* net extractor pimpl

* gpu pimple

* disable copy assign vulkandevice, code format

* command pimpl, dummy image readonly

* pipeline pipelinecache pimpl, export platform class

* code format, export simple family

* update ci

* disable lto on android armv7, merge webassembly ci

* link libgcc, fix macos dylib version

* pipeline pimpl, gpu info pimpl

* destroy gpu info after vulkan device

* ignore msvc stl class warning

* fix ncnn_paramdict_get_float return type

* fix vktransfer upload fp16 without flatten, add command test
2021-01-01 22:55:10 +08:00
zchrissirhcz b80b84fda5 fix #1542; fix avx2 uint16_t including (#1968)
* fix #1542; fix avx2 uint16_t including

for #1542, it is for compatibility for opencv 2.x, such as on ubuntu 16.04 apt installed opencv
2020-07-27 18:39:39 +08:00
nihui 3ef995ed1e format code style and setup restyled.io (#1840) 2020-06-13 22:17:51 +08:00
nihui c089ddb3c2 fix build with opencv 2.4 2020-02-21 21:52:30 +08:00
kalcohol 90f8359961 revise more understandable help info (#1520)
* revise more understandable help info

* try update ubuntu system before apt-get install

* remove upgrade
2020-02-04 14:57:24 +08:00
nihui 05ab6813f5 c++03 compiler happy 2020-01-23 14:36:47 +08:00
kalcohol 6916f45237 fix quantize tools cross platform issues (#1505)
* 1. for cross platform, use cv::CommandLineParser instead of getopt.h
2. use cv::glob to search folder instead of dirent.h
3. fix some other warnings of function from cstdlib
4. add some const and some auto

* 1. fix some other warnings of function from cstdlib
2. add some const and some auto
3. i forgot...

* switch quantize tools default on

* check OpenCV first, if not found, disable quantize tools

* add _CRT_SECURE_NO_DEPRECATE for msvc and remove *_s functions

* add _CRT_SECURE_NO_DEPRECATE for msvc and remove *_s functions

* keep the one line style block

* folding bracket

* dynamic_cast -> static_cast
2020-01-22 16:31:44 +08:00
HuSong 3cec1e6376 Fix ncnn2table coredump (#1410)
* fix compile error of yolov3detectionoutput layer

* fix ncnn2table coredump when [Input] layer not found in ncnn.param
2019-11-29 18:48:17 +08:00
chenyang fda1c8c530 fix return of get_input_names (#1373) 2019-11-13 07:09:40 +08:00
Guoxia Wang 4336cc15f7 fix bug that MemoryData as multi operations input (#1357)
* fix onnx2ncnn MemoryData dims problem #1330

* fix ncnn2int8 bug (see #1336)

* fix bug that MemoryData as multi operations input

* fix ncnn2table find_blob_index_by_name data failed bug, see #1338

* fix ncnn2table find_blob_index_by_name data failed bug, see #1338, fix change requested
2019-11-05 15:53:22 +08:00
ShuangLiu1992 396b057248 fix opencv compatibility issue with major verion > 2 for the quantisation tool (#1302)
* Update CMakeLists.txt

enable quant

* fix opencv compatibility issue with major higher than 2
2019-10-15 06:41:55 +08:00
nihuini 56acc25df8 set QuantNet option, fix #1223 2019-09-06 14:13:30 +08:00
MambaWong 997e96a490 add swapRB flag (#1211) 2019-08-26 17:03:12 +08:00
BUG1989 f79fa87dca Add the readme file of quantization tools (#1198) 2019-08-20 20:46:04 +08:00
BUG1989 bcfe9f453f initial the ncnn post training quantization tools (#1067)
* initial the ncnn post training quantization tools

* clear some comments of tools

* fix the Travis ci compiler error
2019-06-26 21:33:02 +08:00