V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
imn1
V2EX  ›  Python

dnn/knn 样本变化后是要重新训练么?

  •  
  •   imn1 · Aug 10, 2020 · 2564 views
    This topic created in 2085 days ago, the information mentioned may be changed or developed.
    读取前面的训练结果(pickle),然后对新样本训练,前面的训练结果就没了
    能否增量,或者有其他方案可以增量吗?

    不太懂其中算法,如果是要各个节点互相计算,这就难办了……
    Supplement 1  ·  Aug 11, 2020
    搜了一下
    https://scikit-learn.org/stable/tutorial/basic/tutorial.html

    Refitting and updating parameters
    Hyper-parameters of an estimator can be updated after it has been constructed via the set_params() method. Calling fit() more than once will overwrite what was learned by any previous fit():

    overwrite,难怪,看样子要用其他方案……
    4 replies    2020-08-11 08:32:56 +08:00
    Rivers7
        1
    Rivers7  
       Aug 10, 2020   ❤️ 1
    dnn 模型保存 继续训练
    wy
        2
    wy  
       Aug 10, 2020 via Android   ❤️ 1
    如果样本的特征没变,分布情况没变,等同于又多了点训练数据,那模型是可以继续训练的。
    imn1
        3
    imn1  
    OP
       Aug 11, 2020
    @wy
    @Rivers7
    看样子还是没读懂程序,看人家写的 train 就是两个 sklearn.SVC.fid ,然后保存 object
    我就把 object load 出来,fid 新数据,再保存
    第二次保存后,第一次测试正确的图片全部失败……
    Rivers7
        4
    Rivers7  
       Aug 11, 2020
    torch 和 tf 这些深度学习库是可以保存参数,下次训练重新 load 模型加入新样本继续训练的
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   958 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 32ms · UTC 22:46 · PVG 06:46 · LAX 15:46 · JFK 18:46
    ♥ Do have faith in what you're doing.