Skip to content

Commit

Permalink
Site updated: 2023-08-09 15:47:28
Browse files Browse the repository at this point in the history
  • Loading branch information
leafy-lee committed Aug 9, 2023
1 parent bfd017f commit da05cf0
Show file tree
Hide file tree
Showing 15 changed files with 28 additions and 19 deletions.
2 changes: 1 addition & 1 deletion 2023/07/21/Baseline阅读与修改/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
可以发现数据中尺寸总体只有以下几种形式:
{(168, 168, 82, 1), (128, 128, 47, 1), (256, 256, 207, 1), (256, 256, 81, 1), (400, 400, 109, 1), (128, 128, 540, 1), (128, 128, 63, 1), (1.."><meta name="generator" content="Hexo 5.4.2"><link rel="alternate" href="/atom.xml" title="Hexo" type="application/atom+xml">
</head><body class="is-flex is-flex-direction-column"><header class="header-widget is-flex-shrink-0 is-hidden-mobile"><div class="container is-fullhd is-flex is-justify-content-space-between is-align-items-center is-full-height"><section class="is-hidden-mobile is-flex-shrink-0"><h2><a href="/">leafy's blog</a></h2></section><h3 class="is-hidden-mobile is-family-serif is-full-height is-flex is-align-items-center is-flex-shrink-0"><div class="is-full-height" id="postTopic"><p class="is-full-height is-flex-shrink-0 is-flex is-align-items-center is-justify-content-center">Baseline阅读与修改</p><p class="is-full-height is-flex-shrink-0 is-flex is-align-items-center is-justify-content-center">Click back to the top</p></div></h3><aside class="is-flex-shrink-0"><h3 class="is-inline-block"><a href="/">Home</a></h3><h3 class="is-inline-block"><a href="/about">About</a></h3><h3 class="is-inline-block"><a href="/archives">Archives</a></h3></aside></div></header><header class="is-flex header-widget is-flex-shrink-0 is-align-items-center is-justify-content-center is-hidden-tablet"><h3 class="is-inline-block"><a href="/">Home</a></h3><h3 class="is-inline-block"><a href="/about">About</a></h3><h3 class="is-inline-block"><a href="/archives">Archives</a></h3></header><main><main class="container is-max-widescreen content section post-page pt-4 px-4"><div class="columns is-flex-desktop is-justify-content-center is-flex-direction-row-reverse"><div class="column is-3 is-hidden-mobile"><ol class="toc"><li class="toc-item toc-level-2"><a class="toc-link" href="#Baseline%E9%83%A8%E5%88%86"><span class="toc-text">Baseline部分</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%95%B0%E6%8D%AE%E9%9B%86%E5%A4%84%E7%90%86"><span class="toc-text">数据集处理</span></a><ol class="toc-child"><li class="toc-item toc-level-4"><a class="toc-link" href="#%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90"><span class="toc-text">数据分析</span></a></li></ol></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%A8%A1%E5%9E%8B%E5%BB%BA%E7%AB%8B"><span class="toc-text">模型建立</span></a><ol class="toc-child"><li class="toc-item toc-level-5"><a class="toc-link" href="#2D-ResNet"><span class="toc-text">2D-ResNet</span></a></li><li class="toc-item toc-level-5"><a class="toc-link" href="#3D-ResNet"><span class="toc-text">3D-ResNet</span></a></li></ol></li></ol></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%A8%A1%E5%9E%8B%E8%AE%AD%E7%BB%83%E4%B8%8E%E9%AA%8C%E8%AF%81"><span class="toc-text">模型训练与验证</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%A8%A1%E5%9E%8B%E9%A2%84%E6%B5%8B%E4%B8%8E%E6%8F%90%E4%BA%A4"><span class="toc-text">模型预测与提交</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E8%A2%AB%E6%8F%90%E9%97%AE%E5%88%B0%E7%9A%84%E9%85%8D%E7%BD%AE%E9%97%AE%E9%A2%98"><span class="toc-text">被提问到的配置问题</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#Set-ExecutionPolicy"><span class="toc-text">Set-ExecutionPolicy</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Jupyter-notebook-%E8%BF%90%E8%A1%8C%E6%97%A0%E5%8F%8D%E5%BA%94%E6%88%96-conda-init-%E5%A4%B1%E8%B4%A5"><span class="toc-text">Jupyter notebook 运行无反应或 conda init 失败</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#GBK-%E7%BC%96%E7%A0%81%E9%97%AE%E9%A2%98"><span class="toc-text">GBK 编码问题</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E4%B8%80%E4%BA%9B%E5%B0%8FTrick"><span class="toc-text">一些小Trick</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#Test-Time-Augment%EF%BC%88TTA%EF%BC%89"><span class="toc-text">Test-Time-Augment(TTA)</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E9%99%84%E5%BD%95%EF%BC%9AA"><span class="toc-text">附录:A</span></a></li></ol></div><div class="column is-9"><header class="my-4"><a href="/tags/Datawhale%20Related"><i class="tag post-item-tag">Datawhale Related</i></a></header><h1 class="mt-0 mb-1 is-family-serif" id="postTitle">Baseline阅读与修改</h1><time class="has-text-grey" datetime="2023-07-21T09:09:59.000Z">2023-07-21</time><article class="mt-2 post-content"><h2 id="Baseline部分"><a href="#Baseline部分" class="headerlink" title="Baseline部分"></a>Baseline部分</h2><h3 id="数据集处理"><a href="#数据集处理" class="headerlink" title="数据集处理"></a>数据集处理</h3><h4 id="数据分析"><a href="#数据分析" class="headerlink" title="数据分析"></a>数据分析</h4><pre><code class="python">sizeSet = set()
</head><body class="is-flex is-flex-direction-column"><header class="header-widget is-flex-shrink-0 is-hidden-mobile"><div class="container is-fullhd is-flex is-justify-content-space-between is-align-items-center is-full-height"><section class="is-hidden-mobile is-flex-shrink-0"><h2><a href="/">leafy's blog</a></h2></section><h3 class="is-hidden-mobile is-family-serif is-full-height is-flex is-align-items-center is-flex-shrink-0"><div class="is-full-height" id="postTopic"><p class="is-full-height is-flex-shrink-0 is-flex is-align-items-center is-justify-content-center">Baseline阅读与修改</p><p class="is-full-height is-flex-shrink-0 is-flex is-align-items-center is-justify-content-center">Click back to the top</p></div></h3><aside class="is-flex-shrink-0"><h3 class="is-inline-block"><a href="/">Home</a></h3><h3 class="is-inline-block"><a href="/about">About</a></h3><h3 class="is-inline-block"><a href="/archives">Archives</a></h3></aside></div></header><header class="is-flex header-widget is-flex-shrink-0 is-align-items-center is-justify-content-center is-hidden-tablet"><h3 class="is-inline-block"><a href="/">Home</a></h3><h3 class="is-inline-block"><a href="/about">About</a></h3><h3 class="is-inline-block"><a href="/archives">Archives</a></h3></header><main><main class="container is-max-widescreen content section post-page pt-4 px-4"><div class="columns is-flex-desktop is-justify-content-center is-flex-direction-row-reverse"><div class="column is-3 is-hidden-mobile"><ol class="toc"><li class="toc-item toc-level-2"><a class="toc-link" href="#Baseline%E9%83%A8%E5%88%86"><span class="toc-text">Baseline部分</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%95%B0%E6%8D%AE%E9%9B%86%E5%A4%84%E7%90%86"><span class="toc-text">数据集处理</span></a><ol class="toc-child"><li class="toc-item toc-level-4"><a class="toc-link" href="#%E6%95%B0%E6%8D%AE%E5%88%86%E6%9E%90"><span class="toc-text">数据分析</span></a></li></ol></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%A8%A1%E5%9E%8B%E5%BB%BA%E7%AB%8B"><span class="toc-text">模型建立</span></a><ol class="toc-child"><li class="toc-item toc-level-5"><a class="toc-link" href="#2D-ResNet"><span class="toc-text">2D-ResNet</span></a></li><li class="toc-item toc-level-5"><a class="toc-link" href="#3D-ResNet"><span class="toc-text">3D-ResNet</span></a></li></ol></li></ol></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%A8%A1%E5%9E%8B%E8%AE%AD%E7%BB%83%E4%B8%8E%E9%AA%8C%E8%AF%81"><span class="toc-text">模型训练与验证</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#%E6%A8%A1%E5%9E%8B%E9%A2%84%E6%B5%8B%E4%B8%8E%E6%8F%90%E4%BA%A4"><span class="toc-text">模型预测与提交</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E8%A2%AB%E6%8F%90%E9%97%AE%E5%88%B0%E7%9A%84%E9%85%8D%E7%BD%AE%E9%97%AE%E9%A2%98"><span class="toc-text">被提问到的配置问题</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#Set-ExecutionPolicy"><span class="toc-text">Set-ExecutionPolicy</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#Jupyter-notebook-%E8%BF%90%E8%A1%8C%E6%97%A0%E5%8F%8D%E5%BA%94%E6%88%96-conda-init-%E5%A4%B1%E8%B4%A5"><span class="toc-text">Jupyter notebook 运行无反应或 conda init 失败</span></a></li><li class="toc-item toc-level-3"><a class="toc-link" href="#GBK-%E7%BC%96%E7%A0%81%E9%97%AE%E9%A2%98"><span class="toc-text">GBK 编码问题</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E4%B8%80%E4%BA%9B%E5%B0%8FTrick"><span class="toc-text">一些小Trick</span></a><ol class="toc-child"><li class="toc-item toc-level-3"><a class="toc-link" href="#Test-Time-Augment%EF%BC%88TTA%EF%BC%89"><span class="toc-text">Test-Time-Augment(TTA)</span></a></li></ol></li><li class="toc-item toc-level-2"><a class="toc-link" href="#%E9%99%84%E5%BD%95%EF%BC%9AA"><span class="toc-text">附录:A</span></a></li></ol></div><div class="column is-9"><header class="my-4"><a href="/tags/Datawhale-Related"><i class="tag post-item-tag">Datawhale-Related</i></a></header><h1 class="mt-0 mb-1 is-family-serif" id="postTitle">Baseline阅读与修改</h1><time class="has-text-grey" datetime="2023-07-21T09:09:59.000Z">2023-07-21</time><article class="mt-2 post-content"><h2 id="Baseline部分"><a href="#Baseline部分" class="headerlink" title="Baseline部分"></a>Baseline部分</h2><h3 id="数据集处理"><a href="#数据集处理" class="headerlink" title="数据集处理"></a>数据集处理</h3><h4 id="数据分析"><a href="#数据分析" class="headerlink" title="数据分析"></a>数据分析</h4><pre><code class="python">sizeSet = set()
for path in trainPath:
image = nib.load(path)
imgShape = image.dataobj.shape
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions 2023/08/06/行人身份识别/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ <h3 id="1-2-赛事任务"><a href="#1-2-赛事任务" class="headerlink" title="
<h3 id="1-3-评价指标"><a href="#1-3-评价指标" class="headerlink" title="1.3 评价指标"></a>1.3 评价指标</h3><p>本模型依据提交的结果文件,采用Macro-F1进行评价,其中Macro-F1的一种定义如下:</p>
<p><img src="/2023/08/06/%E8%A1%8C%E4%BA%BA%E8%BA%AB%E4%BB%BD%E8%AF%86%E5%88%AB/image-20230806212241289.png" alt="image-20230806212241289"></p>
<p>在“Training algorithms for linear text classifiers( Lewis, David D., et al. “Training algorithms for linear text classifiers.” SIGIR. Vol. 96. 1996.)”中,作者指出,第一种方式对错误的分布不太敏感。,Macro-F1应当是所有类中F1-score的平均值,即第二种方式才是Macro-F1的计算方式,因此我们使用第二种计算方式。</p>
<h2 id="2-任务分析"><a href="#2-任务分析" class="headerlink" title="2 任务分析"></a>2 任务分析</h2><p><img src="/image-20230809144608958.png" alt="image-20230809144608958"></p>
<h2 id="2-任务分析"><a href="#2-任务分析" class="headerlink" title="2 任务分析"></a>2 任务分析</h2><p><img src="/2023/08/06/%E8%A1%8C%E4%BA%BA%E8%BA%AB%E4%BB%BD%E8%AF%86%E5%88%AB/image-20230809144608958.png" alt="image-20230809144608958"></p>
<ol>
<li><p>可以观察到,这里的图像都是上下顶格的,考虑到边缘在CNN卷积的过程中会存在padding的情况,我们可以考试适当放缩图片,为边缘补充zero padding,保证图像效果。</p>
</li>
Expand Down Expand Up @@ -128,7 +128,7 @@ <h3 id="2-模型建立"><a href="#2-模型建立" class="headerlink" title="2.
</code></pre>
<ol start="2">
<li><p>采用学习率的梯度下降,在最小值点提供更小的学习率,防止不收敛。之前同学们提到的0.2-0.5突然震荡回0.8就可能是这种情况。这里我的损失收敛到了0.05-0.12左右。使用了paddle的stepdecay策略,梯度下降学习率。</p>
<p><img src="/image-20230806223356737.png" alt="image-20230806223356737"></p>
<p> <img src="/2023/08/06/%E8%A1%8C%E4%BA%BA%E8%BA%AB%E4%BB%BD%E8%AF%86%E5%88%AB/image-20230806223356737.png" alt="image-20230806223356737"></p>
<pre><code class="python">model = XunFeiNet()
model = model
criterion = nn.CrossEntropyLoss(soft_label=True)
Expand Down
2 changes: 1 addition & 1 deletion archives/2023/07/index.html
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<!DOCTYPE html><html class="appearance-auto" lang="en"><head><meta charset="UTF-8"><title>leafy's blog</title><meta name="description" content="The instinct of a man is to pursue everything that flies from him, and to fly from all that pursue him."><meta name="viewport" content="width=device-width, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no, initial-scale=1"><!-- Google Analytics --><!-- End Google Analytics -->
<!-- Baidu Analytics --><!-- End Baidu Analytics --><link rel="icon" href="/images/favicon.ico"><link rel="stylesheet" href="/style/common/bulma.css"><link rel="stylesheet" href="/style/base.css"><link rel="stylesheet" href="/style/common/helper.css"><script src="/js/common.js"></script><link rel="stylesheet" href="/style/widget-post-list.css"><meta name="generator" content="Hexo 5.4.2"><link rel="alternate" href="/atom.xml" title="Hexo" type="application/atom+xml">
</head><body class="is-flex is-flex-direction-column"><header class="header-widget is-flex-shrink-0 is-hidden-mobile"><div class="container is-fullhd is-flex is-justify-content-space-between is-align-items-center is-full-height"><section class="is-hidden-mobile is-flex-shrink-0"><h2><a href="/">leafy's blog</a></h2></section><h3 class="is-hidden-mobile is-family-serif is-full-height is-flex is-align-items-center is-flex-shrink-0"><span>Archives · 2023</span></h3><aside class="is-flex-shrink-0"><h3 class="is-inline-block"><a href="/">Home</a></h3><h3 class="is-inline-block"><a href="/about">About</a></h3><h3 class="is-inline-block"><a href="/archives">Archives</a></h3></aside></div></header><header class="is-flex header-widget is-flex-shrink-0 is-align-items-center is-justify-content-center is-hidden-tablet"><h3 class="is-inline-block"><a href="/">Home</a></h3><h3 class="is-inline-block"><a href="/about">About</a></h3><h3 class="is-inline-block"><a href="/archives">Archives</a></h3></header><main><article class="post-container is-flex is-justify-content-center section container is-max-widescreen pt-4 px-2"><div class="columns is-variable is-1-tablet is-3-desktop-only is-2-widescreen is-full-width"><section class="column"><article class="post-item-card"><section class="content post-card-content p-4 pb-5"><header><a href="/tags/Datawhale%20Related"><i class="tag post-item-tag">Datawhale Related</i></a></header><h2 class="mt-4 mb-0 is-family-serif"><a href="/2023/07/21/Baseline%E9%98%85%E8%AF%BB%E4%B8%8E%E4%BF%AE%E6%94%B9/">Baseline阅读与修改</a></h2><time class="has-text-grey" datetime="2023-07-21T09:09:59.000Z">2023-07-21</time><p class="is-flex-grow-2 mt-2">Baseline部分数据集处理数据分析sizeSet = set()
</head><body class="is-flex is-flex-direction-column"><header class="header-widget is-flex-shrink-0 is-hidden-mobile"><div class="container is-fullhd is-flex is-justify-content-space-between is-align-items-center is-full-height"><section class="is-hidden-mobile is-flex-shrink-0"><h2><a href="/">leafy's blog</a></h2></section><h3 class="is-hidden-mobile is-family-serif is-full-height is-flex is-align-items-center is-flex-shrink-0"><span>Archives · 2023</span></h3><aside class="is-flex-shrink-0"><h3 class="is-inline-block"><a href="/">Home</a></h3><h3 class="is-inline-block"><a href="/about">About</a></h3><h3 class="is-inline-block"><a href="/archives">Archives</a></h3></aside></div></header><header class="is-flex header-widget is-flex-shrink-0 is-align-items-center is-justify-content-center is-hidden-tablet"><h3 class="is-inline-block"><a href="/">Home</a></h3><h3 class="is-inline-block"><a href="/about">About</a></h3><h3 class="is-inline-block"><a href="/archives">Archives</a></h3></header><main><article class="post-container is-flex is-justify-content-center section container is-max-widescreen pt-4 px-2"><div class="columns is-variable is-1-tablet is-3-desktop-only is-2-widescreen is-full-width"><section class="column"><article class="post-item-card"><section class="content post-card-content p-4 pb-5"><header><a href="/tags/Datawhale-Related"><i class="tag post-item-tag">Datawhale-Related</i></a></header><h2 class="mt-4 mb-0 is-family-serif"><a href="/2023/07/21/Baseline%E9%98%85%E8%AF%BB%E4%B8%8E%E4%BF%AE%E6%94%B9/">Baseline阅读与修改</a></h2><time class="has-text-grey" datetime="2023-07-21T09:09:59.000Z">2023-07-21</time><p class="is-flex-grow-2 mt-2">Baseline部分数据集处理数据分析sizeSet = set()
for path in trainPath:
image = nib.load(path)
imgShape = image.dataobj.shape
Expand Down
Loading

0 comments on commit da05cf0

Please sign in to comment.