COE 592Lecture 02المحاضرة 02Part 04الجزء 04
Pooling and what CNN filters learnالتجميع (Pooling) وما تتعلمه مرشحات CNN
Parameter-free downsampling with max and average pooling, the feature hierarchy a CNN learns, and two interactive demos.تقليل الأبعاد بدون معاملات عبر التجميع الأقصى (max) والمتوسط (average)، والتسلسل الهرمي للسمات الذي تتعلمه شبكة CNN، وعرضان تفاعليان.
- Conceptsالمفاهيم
- 4
- Slidesالشرائح
- 21-26
- Readingمدة القراءة
- 24 min24 دقيقة
Why this part mattersلماذا يهمّ هذا الجزء
Pooling is the cheapest layer you will ever deploy: zero parameters, four times fewer activations, and it is therefore the first tool for fitting a CNN into microcontroller SRAM. The feature hierarchy that follows it explains why pruning, quantization and transfer learning treat early and late layers differently.
The two skills this part drills are pure counting: the output shape of a pooling layer and the parameter count of a convolution layer. That same counting is the first step of every embedded model budget, because parameters set flash and activation shapes set SRAM. The two browser demos at the end give you the numbers layer by layer so you can check yourself.
الـ pooling هو أرخص طبقة ستنشرها على الإطلاق: صفر معاملات، وعدد activations أقل بأربع مرات، ولذلك فهو الأداة الأولى لإدخال شبكة CNN في ذاكرة SRAM الخاصة بالمتحكم الدقيق. والتسلسل الهرمي للخصائص الذي يأتي بعده يشرح لماذا تتعامل تقنيات pruning وquantization وtransfer learning مع الطبقات الأولى والأخيرة بطرق مختلفة.
المهارتان اللتان يدرّبك عليهما هذا الجزء عدٌّ خالص: شكل مخرج طبقة pooling، وعدد معاملات طبقة convolution. وهذا العدّ نفسه هو الخطوة الأولى في كل ميزانية لنموذج مدمج، لأن المعاملات تحدد ذاكرة flash وأشكال الـ activations تحدد ذاكرة SRAM. والعرضان التفاعليان في المتصفح في نهاية الجزء يعطيانك الأرقام طبقةً طبقة لتتحقق من نفسك.
By the end you canفي نهاية هذا الجزء ستستطيع
- Compute the output shape of any pooling layer from W1, H1, C, F and S, and state why its parameter count is zero.احسب شكل مخرج أي طبقة pooling انطلاقًا من W1 وH1 وC وF وS، واذكر لماذا يساوي عدد معاملاتها صفرًا.
- Evaluate max and average pooling by hand on a small slice and explain the small translation invariance max pooling brings.طبّق max pooling وaverage pooling يدويًا على شريحة صغيرة، واشرح الثبات التقريبي أمام الإزاحات الصغيرة (translation invariance) الذي يضيفه max pooling.
- Describe the edges, parts, objects feature hierarchy and tie it to receptive-field growth through CONV-RELU-POOL blocks.صِف تسلسل الخصائص الهرمي: حواف ثم أجزاء ثم أجسام كاملة، واربطه بنمو الحقل الاستقبالي (receptive field) عبر كتل CONV-RELU-POOL.
- Count the parameters of a conv layer from its filter shape, including biases, as in the ConvNetJS first layer.احسب عدد معاملات طبقة conv من شكل الـ filter مع إضافة الـ biases، كما في الطبقة الأولى من ConvNetJS.
- Chain shapes through a real small network (CNN Explainer) and separate the layers that cost parameters from those that cost only activations.تتبّع الأشكال عبر شبكة صغيرة حقيقية (CNN Explainer)، وافصل بين الطبقات التي تكلّف معاملات والطبقات التي لا تكلّف إلا activations.
A VGG-style block hands the next layer a volume of 224 x 224 x 64, which is 3,211,264 activations. A 2 x 2 pool with stride 2 returns 112 x 112 x 64, which is 802,816. Nothing was learned, nothing was mixed across channels, and every one of the 64 maps was simply shrunk on its own. That is the whole job of a Pooling layer.
تسلّم كتلة على نمط VGG الطبقة التالية حجمًا قدره 224 x 224 x 64، أي 3,211,264 قيمة activation. وطبقة pool بنافذة 2 x 2 وخطوة 2 تُرجع 112 x 112 x 64، أي 802,816. لم يُتعلَّم شيء، ولم يُمزج شيء عبر القنوات، وكل خريطة من الخرائط الـ 64 صُغّرت ببساطة وحدها. هذه هي وظيفة pooling layer كاملة.
The rule behind the example: a pooling layer applies a fixed summary over a small window of each activation map, one map at a time. Two summaries are common. Max pooling keeps the largest value in the window, and Average pooling keeps the mean. Because the summary is computed inside one Channel and never across channels, the depth of the volume is preserved while the spatial size falls. Pooling is therefore the second Downsampling tool of this lecture, next to Stride, and its output is a smaller Feature map per channel.
القاعدة وراء المثال: طبقة الـ pooling تطبّق تلخيصًا ثابتًا على نافذة صغيرة من كل خريطة activation، خريطةً واحدة في كل مرة. وهناك تلخيصان شائعان: max pooling يحتفظ بأكبر قيمة في النافذة، وaverage pooling يحتفظ بالمتوسط. ولأن التلخيص يُحسب داخل channel واحدة ولا يُحسب أبدًا عبر القنوات، يبقى عمق الحجم محفوظًا بينما يصغر حجمه المكاني. لذلك فالـ pooling هو الأداة الثانية للـ downsampling في هذه المحاضرة إلى جانب stride، ومخرجه feature map أصغر لكل قناة.
Slide 21 pinned as shapesالشريحة 21 مثبّتة على شكل أبعاد
- Inputالمدخل
- 224 x 224 x 64224 x 224 x 64
- Spatial extent F, stride Sالامتداد المكاني F، والخطوة S
- 2, 22, 2
- Outputالمخرج
- 112 x 112 x 64112 x 112 x 64
- Channelsالقنوات
- Unchanged, 64 in and 64 outدون تغيير، 64 تدخل و64 تخرج
- Activationsالـ activations
- 3,211,264 to 802,816 (75% discarded)من 3,211,264 إلى 802,816 (يُستبعد 75%)
- Learned parametersالمعاملات المتعلَّمة
- 00
Why max pooling is the default, and why that is a heuristicلماذا يُعدّ max pooling الخيار الافتراضي، ولماذا هذه قاعدة تجريبية
Pooling of any kind brings an approximate translation invariance, and max pooling shows it most sharply, which is why slide 21 attaches "Introduces spatial invariance" to max pooling. Goodfellow, Bengio and Courville describe pooling in all its forms as making the representation "approximately invariant to small translations of the input": if the input shifts by a pixel, the values of most pooled outputs do not change, because the maximum is still inside its window. Their example is face detection, where the network need not know the location of the eyes with pixel-perfect accuracy, only that there is an eye on each side. They also point out that pooling regions spaced k pixels apart give the next layer roughly k times fewer inputs to process, which is the memory saving your microcontroller will feel.
أي نوع من الـ pooling يضيف ثباتًا تقريبيًا أمام الإزاحة (translation invariance)، وmax pooling يُظهره بأوضح صورة، ولهذا تربط الشريحة 21 عبارة «Introduces spatial invariance» بالـ max pooling. يصف Goodfellow وBengio وCourville الـ pooling بجميع أشكاله بأنه يجعل التمثيل «approximately invariant to small translations of the input»، أي ثابتًا تقريبًا أمام الإزاحات الصغيرة للمدخل: إذا انزاح المدخل بكسلًا واحدًا، فإن قيم معظم مخرجات الـ pooling لا تتغير، لأن القيمة العظمى ما زالت داخل نافذتها. ومثالهم هو كشف الوجوه، حيث لا تحتاج الشبكة إلى معرفة موضع العينين بدقة البكسل، بل يكفيها أن تعرف أن هناك عينًا في كل جانب. ويشيرون أيضًا إلى أن مناطق pooling تفصل بينها k بكسلات تعطي الطبقة التالية مدخلات أقل بنحو k مرة لتعالجها، وهذا هو التوفير في الذاكرة الذي سيشعر به المتحكم الدقيق لديك.
| Max poolingMax pooling | Average poolingAverage pooling | |
|---|---|---|
| What it returnsما يُرجعه | The largest value in the windowأكبر قيمة في النافذة | The mean of all values in the windowمتوسط كل القيم في النافذة |
| What it is sensitive toما يتأثر به | One strong activation anywhere in the windowactivation واحدة قوية في أي مكان داخل النافذة | Every value equally, so a strong spike is dilutedكل قيمة بالتساوي، فتُخفَّف القمة القوية |
| Effect of a one-cell shiftأثر إزاحة بمقدار خلية واحدة | Usually none, if the maximum stays inside the windowعادةً لا أثر، إذا بقيت القيمة العظمى داخل النافذة | Small change, the average moves slightlyتغيّر صغير، إذ يتحرك المتوسط قليلًا |
| Gradient in the backward passالـ gradient في الـ backward pass | Routed to the argmax cell onlyيُوجَّه إلى خلية الـ argmax فقط | Spread equally, 1/F² to every cellيُوزَّع بالتساوي، 1/F² لكل خلية |
| Typical place in a networkموضعه المعتاد في الشبكة | Inside the trunk after a conv blockداخل الجذع (trunk) بعد كتلة conv | Global average pooling as the classifier headglobal average pooling كرأس للتصنيف |
Slide 21 goes further and says max pooling "performs a lot better" because it discards noisy activations. Treat that as the slide's heuristic, not a law. Boureau, Ponce and LeCun analysed the two in 2010 and found that which one wins depends on how sparse the features are and how large the pool is; they note that earlier comparisons had been "purely empirical". CS231n states more cautiously that max pooling "has been shown to work better in practice". And the field has partly moved on: Springenberg et al. showed in 2014 that max pooling "can simply be replaced by a convolutional layer with increased stride without loss in accuracy", and Lin, Chen and Yan's Network in Network replaced the fully connected head with global average pooling, which they found "less prone to overfitting". ResNet and MobileNet families follow that pattern: strided convolutions inside, a single global average pool at the end.
تذهب الشريحة 21 أبعد من ذلك وتقول إن max pooling «performs a lot better»، أي أفضل بكثير، لأنه يتخلص من الـ activations المشوَّشة. تعامل مع هذا على أنه قاعدة تجريبية من الشريحة، لا قانون. فقد حلّل Boureau وPonce وLeCun النوعين عام 2010 ووجدوا أن الفائز يعتمد على مدى تناثر (sparsity) الخصائص وعلى حجم الـ pool؛ ولاحظوا أن المقارنات السابقة كانت «purely empirical»، أي تجريبية بحتة. ويقول CS231n بحذر أكبر إن max pooling «has been shown to work better in practice»، أي ثبت أنه يعمل أفضل عمليًا. وقد تجاوز المجال ذلك جزئيًا: أظهر Springenberg et al. عام 2014 أن max pooling «can simply be replaced by a convolutional layer with increased stride without loss in accuracy»، أي يمكن ببساطة استبداله بطبقة convolution بخطوة أكبر دون خسارة في الدقة، واستبدلت ورقة Network in Network لـ Lin وChen وYan الرأس المتصل بالكامل (fully connected head) بـ global average pooling، ووجدوه «less prone to overfitting»، أي أقل عرضة للـ overfitting. وعائلتا ResNet وMobileNet تتبعان هذا النمط: strided convolutions في الداخل، وglobal average pool واحد في النهاية.
Recall
A 224x224x64 volume passes through max pooling with F = 2 and S = 2. What are the output shape and the number of learned parameters?يمرّ حجم 224x224x64 عبر max pooling مع F = 2 وS = 2. ما شكل المخرج، وما عدد المعاملات المتعلَّمة؟
Quick checkاختبار سريع
A 56x56x128 volume passes through max pooling with a 2x2 window and stride 2. What does it output?يمرّ حجم 56x56x128 عبر max pooling بنافذة 2x2 وخطوة 2. ما مخرجه؟
Take the single depth slice from slide 22, a 4 x 4 grid, and pool it with a 2 x 2 window and Stride 2. The window lands in four places and never overlaps itself, so the four coloured quadrants of the slide are the four windows. Each quadrant becomes one output cell.
خذ شريحة العمق الواحدة من الشريحة 22، وهي شبكة 4 x 4، وطبّق عليها pooling بنافذة 2 x 2 وstride قيمتها 2. تقع النافذة في أربعة مواضع ولا تتداخل مع نفسها أبدًا، لذا فالأرباع الأربعة الملوّنة في الشريحة هي النوافذ الأربع. وكل ربع يصبح خلية واحدة في المخرج.
| Windowالنافذة | Valuesالقيم | MaxMax | MeanMean |
|---|---|---|---|
| Top left (pink on the slide)أعلى اليسار (الوردي في الشريحة) | {1, 1, 5, 6}{1, 1, 5, 6} | 66 | 13 / 4 = 3.2513 / 4 = 3.25 |
| Top right (green)أعلى اليمين (الأخضر) | {2, 4, 7, 8}{2, 4, 7, 8} | 88 | 21 / 4 = 5.2521 / 4 = 5.25 |
| Bottom left (yellow)أسفل اليسار (الأصفر) | {3, 2, 1, 2}{3, 2, 1, 2} | 33 | 8 / 4 = 28 / 4 = 2 |
| Bottom right (blue)أسفل اليمين (الأزرق) | {1, 0, 3, 4}{1, 0, 3, 4} | 44 | 8 / 4 = 28 / 4 = 2 |
Read the two results as grids. Max pooling gives [[6, 8], [3, 4]] and Average pooling gives [[3.25, 5.25], [2, 2]]. Notice what each one threw away. Max kept only the argmax cell of each window (the 6, the 8, the 3, the 4) and forgot the other three values entirely. Mean kept a trace of all four but flattened the 8 down to 5.25.
اقرأ النتيجتين كشبكتين. يعطي max pooling النتيجة [[6, 8], [3, 4]]، ويعطي average pooling النتيجة [[3.25, 5.25], [2, 2]]. لاحظ ما تخلّص منه كل واحد منهما. الـ max احتفظ فقط بخلية الـ argmax في كل نافذة (الـ 6 والـ 8 والـ 3 والـ 4) ونسي القيم الثلاث الأخرى تمامًا. أما الـ mean فاحتفظ بأثر من القيم الأربع كلها لكنه خفّض الـ 8 إلى 5.25.
The general ruleالقاعدة العامة
Let the input be W1 x H1 x C. A Pooling layer needs exactly two hyperparameters, the spatial extent F of the window and the stride S, and it produces W2 x H2 x C.
ليكن المدخل W1 x H1 x C. تحتاج pooling layer إلى معاملين فائقين (hyperparameters) فقط: الامتداد المكاني للنافذة F، والخطوة S، وتُنتج W2 x H2 x C.
The shape formula is the convolution formula from part 03 with p = 0 and the kernel size renamed to F. PyTorch writes the same rule in its general form, H_out = floor((H_in + 2p - d(F - 1) - 1)/S + 1), with the stride defaulting to the kernel size, so MaxPool2d(2) means F = 2, S = 2 (PyTorch docs). The floor matters when the division is not exact, and the second worked example shows why.
صيغة الشكل هي نفسها صيغة الـ convolution من الجزء 03 مع p = 0 وتغيير اسم حجم الـ kernel إلى F. ويكتب PyTorch القاعدة نفسها بصيغتها العامة H_out = floor((H_in + 2p - d(F - 1) - 1)/S + 1)، والخطوة فيه تساوي حجم الـ kernel افتراضيًا، لذا فإن MaxPool2d(2) تعني F = 2, S = 2 (توثيق PyTorch). ويهمّ الـ floor عندما لا تكون القسمة صحيحة، والمثال المحلول الثاني يوضح السبب.
The zero comes from what pooling does in the backward pass. CS231n notes that a pooling layer "introduces zero parameters since it computes a fixed function of the input". Implementations keep the index of the maximum, the "switch", so the gradient is routed to exactly one cell per window in max pooling; in average pooling it is spread as 1/F² to each cell. Either way the layer has no Weight and no Bias, so it adds nothing to the Parameter count.
يأتي الصفر مما يفعله الـ pooling في الـ backward pass. يذكر CS231n أن طبقة الـ pooling «introduces zero parameters since it computes a fixed function of the input»، أي لا تضيف أي معاملات لأنها تحسب دالة ثابتة من المدخل. وتحتفظ التطبيقات بموضع القيمة العظمى، ويُسمّى «switch»، فيُوجَّه الـ gradient إلى خلية واحدة بالضبط في كل نافذة في max pooling؛ أما في average pooling فيُوزَّع بمقدار 1/F² على كل خلية. وفي الحالتين لا تملك الطبقة أي weight ولا أي bias، فلا تضيف شيئًا إلى عدد الـ parameters.
Worked exampleمثال محلول
224 to 112, the slide 21 numbersمن 224 إلى 112، أرقام الشريحة 21
Substitute into the width formulaعوّض في صيغة العرض
W2 = (224 - 2)/2 + 1 = 111 + 1 = 112. The height is identical.W2 = (224 - 2)/2 + 1 = 111 + 1 = 112. والارتفاع مطابق.Carry the depth acrossانقل العمق كما هو
C2 = C1 = 64, because the window only ever looks inside one channel.C2 = C1 = 64، لأن النافذة لا تنظر أبدًا إلا داخل قناة واحدة.Count the activationsاحسب الـ activations
Before: 224 x 224 x 64 = 3,211,264. After: 112 x 112 x 64 = 802,816. Exactly one quarter survives; CS231n phrases it as "discards exactly 75% of the activations in an input volume".قبل: 224 x 224 x 64 = 3,211,264. بعد: 112 x 112 x 64 = 802,816. يبقى الربع بالضبط؛ ويصوغها CS231n بعبارة «discards exactly 75% of the activations in an input volume»، أي يتخلص من 75% بالضبط من الـ activations في حجم المدخل.Resultالنتيجة
Output 112 x 112 x 64, 0 parameters, 75% of runtime memory for that tensor gone.المخرج 112 x 112 x 64، و0 معاملات، وزوال 75% من ذاكرة وقت التشغيل الخاصة بذلك الـ tensor.
Worked exampleمثال محلول
Why F = 3, S = 2 needs careلماذا تحتاج F = 3, S = 2 إلى انتباه
Overlapping pool on 224pool متداخل على 224
(224 - 3)/2 + 1 = 111.5. Not an integer: the last window would hang off the edge. PyTorch floors to 111 by default and rounds up to 112 only with ceil_mode=True.(224 - 3)/2 + 1 = 111.5. ليس عددًا صحيحًا: النافذة الأخيرة ستتدلّى خارج الحافة. يقرّب PyTorch للأسفل إلى 111 افتراضيًا، ولا يقرّب للأعلى إلى 112 إلا مع ceil_mode=True.The AlexNet case that does divideحالة AlexNet التي تنقسم فعلًا
AlexNet pools 55 x 55 maps with F = 3, S = 2: (55 - 3)/2 + 1 = 27, a clean integer, which is why that configuration is famous.يطبّق AlexNet الـ pooling على خرائط 55 x 55 مع F = 3, S = 2: (55 - 3)/2 + 1 = 27، وهو عدد صحيح تمامًا، ولهذا اشتهر هذا الإعداد.Rule of thumbقاعدة عملية
Check that (W1 - F) divides by S. If it does not, state the floor explicitly.تحقّق من أن (W1 - F) يقبل القسمة على S. وإذا لم يكن كذلك، فاذكر التقريب للأسفل (floor) صراحةً.
Changing F and S on the same 4 x 4 slice shows how strongly the two hyperparameters shape the result. The values below are max pooling; the simulator lets you check the means.
تغيير F وS على شريحة 4 x 4 نفسها يُظهر مدى قوة تأثير هذين المعاملين الفائقين في النتيجة. القيم أدناه هي لـ max pooling؛ والمحاكي يتيح لك التحقق من المتوسطات.
| F, SF, S | W2W2 | Outputالمخرج | Valuesالقيم | What happenedماذا حدث |
|---|---|---|---|---|
| F = 2, S = 2F = 2, S = 2 | (4 - 2)/2 + 1 = 2(4 - 2)/2 + 1 = 2 | 2 x 22 x 2 | [[6, 8], [3, 4]][[6, 8], [3, 4]] | Windows tile the input, 75% of activations droppedالنوافذ تغطي المدخل دون تداخل، ويُستبعد 75% من الـ activations |
| F = 2, S = 1F = 2, S = 1 | (4 - 2)/1 + 1 = 3(4 - 2)/1 + 1 = 3 | 3 x 33 x 3 | [[6, 7, 8], [6, 7, 8], [3, 3, 4]][[6, 7, 8], [6, 7, 8], [3, 3, 4]] | Windows overlap, the row 6, 7, 8 appears twiceالنوافذ متداخلة، فيظهر الصف 6، 7، 8 مرتين |
| F = 3, S = 1F = 3, S = 1 | (4 - 3)/1 + 1 = 2(4 - 3)/1 + 1 = 2 | 2 x 22 x 2 | [[7, 8], [7, 8]][[7, 8], [7, 8]] | Nine cells per window, the small values vanishتسع خلايا في كل نافذة، فتختفي القيم الصغيرة |
| F = 3, S = 2F = 3, S = 2 | (4 - 3)/2 + 1 = 1.5(4 - 3)/2 + 1 = 1.5 | 1 x 1 (floored)1 x 1 (مقرّب للأسفل) | [[7]][[7]] | Not an integer, PyTorch floors and drops the last row and columnليس عددًا صحيحًا، فيقرّب PyTorch للأسفل ويُسقط الصف والعمود الأخيرين |
- This windowهذه النافذة
- hover an output cellمرّر المؤشر فوق خلية إخراج
- Input W1 × H1 × C
- 4 × 4 × 1
- Output W2 × H2 × C
- 2 × 2 × 1
- Learned parametersالمعاملات المتعلَّمة
- 0
- Activations in, outالتنشيطات داخلًا وخارجًا
- 16 to 4 (75% discarded)من 16 إلى 4 (يُهمَل 75%)
Recall
Compute max and mean pooling with F = 2, S = 2 on [[1,1,2,4],[5,6,7,8],[3,2,1,0],[1,2,3,4]].احسب max pooling وmean pooling مع F = 2 وS = 2 على [[1,1,2,4],[5,6,7,8],[3,2,1,0],[1,2,3,4]].
Quick checkاختبار سريع
Why does a pooling layer add nothing to a network's parameter count?لماذا لا تضيف طبقة الـ pooling شيئًا إلى عدد معاملات الشبكة؟
The grid on slide 23 comes from Lee, Grosse, Ranganath and Ng (ICML 2009), who learned a first layer of edge detectors from natural images once, then trained the second and third layers of a convolutional deep belief network separately on unlabeled Caltech-101 images of faces, cars, elephants and chairs, and visualized what each layer responds to. Their own summary: the first, second and third layers "learn edge detectors, object parts, and objects respectively". Look at the bottom row of the slide. It is the same across all four columns because that first layer was learned once from natural images: small oriented edges like Gabor patches. The middle row diverges into eyes and noses, wheels and bumpers, tusks and ears, chair legs and backs. The top row shows entire faces, cars, elephants and chairs.
الشبكة في الشريحة 23 مأخوذة من Lee وGrosse وRanganath وNg (ICML 2009)، الذين تعلّموا طبقة أولى من كاشفات الحواف من صور طبيعية مرة واحدة، ثم درّبوا الطبقتين الثانية والثالثة من convolutional deep belief network بشكل منفصل على صور غير معنونة من Caltech-101 للوجوه والسيارات والفيلة والكراسي، وعرضوا بصريًا ما تستجيب له كل طبقة. وملخّصهم هم: الطبقات الأولى والثانية والثالثة «learn edge detectors, object parts, and objects respectively»، أي تتعلم كاشفات الحواف، ثم أجزاء الأجسام، ثم الأجسام، على الترتيب. انظر إلى الصف السفلي في الشريحة. إنه متطابق في الأعمدة الأربعة لأن تلك الطبقة الأولى جرى تعلّمها مرة واحدة من صور طبيعية: حواف صغيرة موجّهة تشبه رقع Gabor. ثم يتفرّع الصف الأوسط إلى عيون وأنوف، وعجلات ومصدّات، وأنياب وآذان، وأرجل كراسٍ وظهورها. ويُظهر الصف العلوي وجوهًا وسيارات وفيلة وكراسي كاملة.
This ladder is the Feature hierarchy, and it is not designed by hand. Every Convolution layer runs the same operation with a small Kernel (filter). What changes with depth is the Receptive field: a first-layer unit sees only its k x k patch of pixels, so the most it can detect is an edge. A second-layer unit sees a k x k patch of first-layer responses, which covers a larger region of the image (L(k - 1) + 1 pixels after L stride-1 layers, faster with stride or pooling), so it can combine edges into a curve or an eye. Deep units cover most of the image and can match a whole face. Zeiler and Fergus confirmed in 2013 that the same ladder appears inside a supervised ImageNet CNN, using a deconvolutional visualization of intermediate layers.
هذا السلّم هو feature hierarchy، ولا يُصمَّم يدويًا. كل convolution layer تنفّذ العملية نفسها بـ kernel صغير. ما يتغير مع العمق هو receptive field: وحدة في الطبقة الأولى لا ترى إلا رقعتها k x k من البكسلات، فأقصى ما يمكنها كشفه حافة. ووحدة في الطبقة الثانية ترى رقعة k x k من استجابات الطبقة الأولى، وهذه تغطي منطقة أكبر من الصورة (L(k - 1) + 1 بكسلًا بعد L طبقات بخطوة 1، وأسرع مع الـ stride أو الـ pooling)، فتستطيع جمع الحواف في منحنى أو عين. أما الوحدات العميقة فتغطي معظم الصورة ويمكنها مطابقة وجه كامل. وقد أكّد Zeiler وFergus عام 2013 أن السلّم نفسه يظهر داخل CNN مُشرَف عليها مدرَّبة على ImageNet، باستخدام عرض بصري بالـ deconvolution للطبقات الوسيطة.
| Tierالمستوى | Layersالطبقات | What the filters respond toما تستجيب له الـ filters | Receptive field, roughlyالحقل الاستقبالي تقريبًا |
|---|---|---|---|
| Low levelالمستوى المنخفض | First convolution layersطبقات الـ convolution الأولى | Oriented edges, bars, blobs, colour opponentsحواف موجّهة، وقضبان، وبقع، وتضادّات لونية | 3 x 3 to 11 x 11 pixels (the first kernel size)من 3 x 3 إلى 11 x 11 بكسلًا (حجم الـ kernel الأول) |
| Mid levelالمستوى المتوسط | Middle layersالطبقات الوسطى | Curves, corners, eyes, wheels, tusks, chair legsمنحنيات، وزوايا، وعيون، وعجلات، وأنياب، وأرجل كراسٍ | tens of pixelsعشرات البكسلات |
| High levelالمستوى العالي | Deepest layersأعمق الطبقات | Whole faces, cars, elephants, chairsوجوه، وسيارات، وفيلة، وكراسٍ كاملة | most of the imageمعظم الصورة |
The mechanism in action: slide 24الآلية أثناء العمل: الشريحة 24
Slide 24 shows a network of the pattern [CONV, RELU, CONV, RELU, POOL] repeated three times and then a fully connected layer, run on a photo of a car. Each column is the activation maps of one layer. Read them left to right and the hierarchy appears live: the first columns look like edge-filtered copies of the car, the middle columns are sparse and blotchy, and the last columns are tiny grids that no longer resemble the photo at all.
تعرض الشريحة 24 شبكة من النمط [CONV, RELU, CONV, RELU, POOL] مكررًا ثلاث مرات ثم طبقة متصلة بالكامل (fully connected)، تعمل على صورة سيارة. كل عمود هو الـ activation maps لطبقة واحدة. اقرأها من اليسار إلى اليمين وسيظهر التسلسل الهرمي حيًّا: الأعمدة الأولى تبدو نسخًا من السيارة مرّت عبر فلتر حواف، والأعمدة الوسطى متناثرة وبقعية، والأعمدة الأخيرة شبكات صغيرة لم تعد تشبه الصورة إطلاقًا.
Two convs with ReLU, then pool: edges and colour blobs.
طبقتا conv مع ReLU، ثم pool: حواف وبقع لونية.
Same pattern on the smaller maps: corners, wheels, parts.
النمط نفسه على الخرائط الأصغر: زوايا وعجلات وأجزاء.
Coarse maps whose units see most of the image.
خرائط خشنة ترى وحداتها معظم الصورة.
car, truck, airplane, ship, horse; car wins.
car وtruck وairplane وship وhorse، والفائز car.
The ReLU after each conv keeps only positive responses, which is why the columns after it are darker. Each POOL halves the Feature map and, because the next block's k x k window now covers twice as many original pixels, pushes the receptive field outward. Two pools have already halved the maps twice, so the third block works on maps one quarter the width of the input, and the third pool leaves the fully connected layer maps one eighth the width; that is why the last units can see a whole car. The Fully connected layer at the end reads every unit of the final maps at once and produces one score per class. On the slide, car scores highest, well above truck, then airplane, ship and horse.
الـ ReLU بعد كل conv لا تُبقي إلا الاستجابات الموجبة، ولهذا تكون الأعمدة التي تليها أغمق. وكل POOL يقسم feature map على اثنين، ولأن نافذة k x k في الكتلة التالية تغطي الآن ضعف عدد البكسلات الأصلية، فإنه يدفع الحقل الاستقبالي إلى الخارج. وقد قسم الـ pool الأول والثاني الخرائط على اثنين مرتين، فتعمل الكتلة الثالثة على خرائط عرضها ربع عرض المدخل، ويترك الـ pool الثالث للطبقة المتصلة بالكامل خرائط عرضها ثُمن عرض المدخل؛ ولهذا تستطيع الوحدات الأخيرة رؤية سيارة كاملة. وتقرأ fully connected layer في النهاية كل وحدة من الخرائط الأخيرة دفعة واحدة وتُنتج درجة واحدة لكل فئة. وفي الشريحة تحصل car على أعلى درجة، أعلى بكثير من truck، ثم airplane وship وhorse.
Why this matters on an embedded deviceلماذا يهمّ هذا على جهاز مدمج
The hierarchy explains a pattern you will meet throughout this course. Early layers have few parameters (a 5 x 5 x 3 filter is 75 weights) but large activation maps; late layers have many parameters but tiny maps. So SRAM pressure comes from the front of the network and flash pressure from the back, and pruning or quantizing them calls for different budgets. Transfer learning on the edge uses the hierarchy directly: the edge and part detectors are generic, so you freeze the low tiers and retrain only the top.
يشرح التسلسل الهرمي نمطًا ستقابله طوال هذا المقرر. الطبقات الأولى لها معاملات قليلة (filter بحجم 5 x 5 x 3 يساوي 75 وزنًا) لكن activation maps كبيرة؛ والطبقات الأخيرة لها معاملات كثيرة لكن خرائط صغيرة جدًا. لذا يأتي الضغط على SRAM من مقدمة الشبكة، ويأتي الضغط على flash من مؤخرتها، ويحتاج الـ pruning أو الـ quantization لكل منهما إلى ميزانية مختلفة. ويستخدم الـ transfer learning على الحافة (edge) هذا التسلسل الهرمي مباشرة: كاشفات الحواف والأجزاء عامة، فتجمّد الطبقات الدنيا وتعيد تدريب العليا فقط.
Recall
Name the three tiers of the feature hierarchy with one example each, and say what property of deep layers makes the top tier possible.سمِّ المستويات الثلاثة للتسلسل الهرمي للخصائص مع مثال واحد لكل منها، واذكر ما خاصية الطبقات العميقة التي تجعل المستوى الأعلى ممكنًا.
Quick checkاختبار سريع
In the feature hierarchy, what do the deepest convolution layers respond to?في التسلسل الهرمي للخصائص، ماذا تستجيب له أعمق طبقات الـ convolution؟
Open the ConvNetJS CIFAR-10 demo and read its first conv block. It prints "conv (32x32x16), filter size 5x5x3, stride 1, parameters: 16x5x5x3+16 = 1216". That one line is a complete exam answer, and it is worth rebuilding by hand.
افتح عرض ConvNetJS CIFAR-10 واقرأ أول كتلة conv فيه. إنه يطبع «conv (32x32x16), filter size 5x5x3, stride 1, parameters: 16x5x5x3+16 = 1216». هذا السطر الواحد إجابة امتحان كاملة، ويستحق أن تعيد بناءه يدويًا.
Worked exampleمثال محلول
The ConvNetJS first conv layerأول طبقة conv في ConvNetJS
Weightsالأوزان
16 filters, each 5 x 5 and 3 deep to match the RGB input: 16 x 5 x 5 x 3 = 1200 weights.16 filter، كل منها 5 x 5 وعمقه 3 ليطابق مدخل RGB: 16 x 5 x 5 x 3 = 1200 من الـ weights.Biasesالـ biases
One Bias per filter, so 16.bias واحد لكل filter، أي 16.Why the map stays 32 x 32لماذا تبقى الخريطة 32 x 32
The demo's layer definition uses pad 2: (32 + 2·2 - 5)/1 + 1 = 32. With Padding equal to (F - 1)/2, a stride-1 conv keeps its size.تعريف الطبقة في العرض يستخدم pad 2: (32 + 2·2 - 5)/1 + 1 = 32. فعندما يساوي الـ padding القيمة (F - 1)/2، تحافظ conv بخطوة 1 على حجمها.Resultالنتيجة
1200 + 16 = 1216 parameters, output 32 x 32 x 16, which is 16,384 activations for one image.1200 + 16 = 1216 معاملًا، والمخرج 32 x 32 x 16، أي 16,384 قيمة activation لصورة واحدة.
The ConvNetJS CIFAR-10 demoعرض ConvNetJS على CIFAR-10
- Datasetمجموعة البيانات
- CIFAR-10: 60,000 colour images of 32 x 32, 10 classes, 50,000 train and 10,000 test (Krizhevsky)CIFAR-10: 60,000 صورة ملوّنة بحجم 32 x 32، و10 فئات، و50,000 للتدريب و10,000 للاختبار (Krizhevsky)
- Classesالفئات
- airplane, automobile, bird, cat, deer, dog, frog, horse, ship, truckairplane (طائرة)، automobile (سيارة)، bird (طائر)، cat (قطة)، deer (غزال)، dog (كلب)، frog (ضفدع)، horse (حصان)، ship (سفينة)، truck (شاحنة)
- Accuracy quoted on the pageالدقة المذكورة في الصفحة
- state of the art "about 90%", humans "about 94%" (2014 figures; current models exceed 99%)أفضل نتيجة وقتها «نحو 90%»، والبشر «نحو 94%» (أرقام 2014؛ والنماذج الحالية تتجاوز 99%)
- Augmentationزيادة البيانات (augmentation)
- random flips and random shifts of up to 2 pxقلب عشوائي (flips) وإزاحات عشوائية حتى 2 px
- Optimizerالمُحسِّن (optimizer)
- Adadelta, batch size 4, L2 decay 0.0001Adadelta، وحجم الدفعة (batch size) 4، وL2 decay قدره 0.0001
The whole demo network is small enough to count in full. Two things to watch: every conv filter is as deep as the channels feeding it, and the three pooling layers contribute nothing to the total while cutting the activations by four each time.
شبكة العرض كلها صغيرة بما يكفي لعدّها كاملة. انتبه لأمرين: كل filter في conv عمقه يساوي عدد القنوات الداخلة إليه، وطبقات الـ pooling الثلاث لا تضيف شيئًا إلى المجموع بينما تقلّص الـ activations بأربع مرات في كل مرة.
| Layerالطبقة | Outputالمخرج | Parametersالمعاملات | Noteملاحظة |
|---|---|---|---|
| inputالمدخل (input) | 32 x 32 x 332 x 32 x 3 | 00 | Raw CIFAR-10 imageصورة CIFAR-10 خام |
| conv, 16 filters 5x5x3, pad 2conv، 16 filter بحجم 5x5x3، pad 2 | 32 x 32 x 1632 x 32 x 16 | 16 x 5 x 5 x 3 + 16 = 121616 x 5 x 5 x 3 + 16 = 1216 | The count printed on slide 25العدد المطبوع في الشريحة 25 |
| max pool 2x2, stride 2max pool 2x2، stride 2 | 16 x 16 x 1616 x 16 x 16 | 00 | Activations cut by 4xتنقص الـ activations بأربع مرات |
| conv, 20 filters 5x5x16, pad 2conv، 20 filter بحجم 5x5x16، pad 2 | 16 x 16 x 2016 x 16 x 20 | 20 x 5 x 5 x 16 + 20 = 802020 x 5 x 5 x 16 + 20 = 8020 | Depth of the filter equals the input channelsعمق الـ filter يساوي عدد قنوات المدخل |
| max pool 2x2, stride 2max pool 2x2، stride 2 | 8 x 8 x 208 x 8 x 20 | 00 | |
| conv, 20 filters 5x5x20, pad 2conv، 20 filter بحجم 5x5x20، pad 2 | 8 x 8 x 208 x 8 x 20 | 20 x 5 x 5 x 20 + 20 = 1002020 x 5 x 5 x 20 + 20 = 10020 | |
| max pool 2x2, stride 2max pool 2x2، stride 2 | 4 x 4 x 204 x 4 x 20 | 00 | |
| softmax, 10 classessoftmax، 10 فئات | 1010 | 320 x 10 + 10 = 3210320 x 10 + 10 = 3210 | The only layer whose count depends on image sizeالطبقة الوحيدة التي يعتمد عدد معاملاتها على حجم الصورة |
| Totalالمجموع | 22,46622,466 | Three pools contribute nothingطبقات الـ pool الثلاث لا تساهم بشيء |
The total is 22,466 parameters. The softmax layer is the only one whose count depends on the image size, because it reads the flattened 4 x 4 x 20 = 320 activations; every conv layer's count depends only on its filter shape, which is Weight sharing at work.
المجموع 22,466 معاملًا. وطبقة الـ softmax هي الوحيدة التي يعتمد عدد معاملاتها على حجم الصورة، لأنها تقرأ الـ activations المسطّحة وعددها 4 x 4 x 20 = 320؛ أما عدد معاملات كل طبقة conv فيعتمد على شكل الـ filter فقط، وهذا هو weight sharing أثناء العمل.
CNN Explainer as retrieval practiceCNN Explainer كتمرين استرجاع
CNN Explainer (Wang et al., IEEE VIS 2020) runs a network the authors call Tiny VGG on ten classes: lifeboat, ladybug, pizza, bell pepper, school bus, koala, espresso, red panda, orange and sport car. Its training code uses 3 x 3 convolutions with 10 filters and no padding ("valid"), and 2 x 2 max pools with stride 2. The input is 64 x 64 x 3. Before you look at the table, chain the shapes yourself: a valid conv subtracts 2, a pool halves.
يشغّل CNN Explainer (Wang et al., IEEE VIS 2020) شبكة يسمّيها مؤلفوها Tiny VGG على عشر فئات: lifeboat وladybug وpizza وbell pepper وschool bus وkoala وespresso وred panda وorange وsport car. ويستخدم كود التدريب الخاص به convolutions بحجم 3 x 3 مع 10 filters ودون padding («valid»)، وmax pools بحجم 2 x 2 وخطوة 2. والمدخل 64 x 64 x 3. قبل أن تنظر إلى الجدول، تتبّع الأشكال بنفسك: الـ conv من نوع valid تطرح 2، والـ pool يقسم على اثنين.
Recall
Chain the CNN Explainer shapes from 64x64x3 to the second pool.تتبّع أشكال CNN Explainer من 64x64x3 حتى الـ pool الثاني.
| Layerالطبقة | Shape formulaصيغة الشكل | Outputالمخرج | Parametersالمعاملات |
|---|---|---|---|
| inputالمدخل (input) | 64 x 64 x 364 x 64 x 3 | 00 | |
| conv_1_1, 10 filters 3x3, validconv_1_1، 10 filters بحجم 3x3، valid | 64 - 3 + 164 - 3 + 1 | 62 x 62 x 1062 x 62 x 10 | 10 x 3 x 3 x 3 + 10 = 28010 x 3 x 3 x 3 + 10 = 280 |
| conv_1_2, 10 filters 3x3, validconv_1_2، 10 filters بحجم 3x3، valid | 62 - 3 + 162 - 3 + 1 | 60 x 60 x 1060 x 60 x 10 | 10 x 3 x 3 x 10 + 10 = 91010 x 3 x 3 x 10 + 10 = 910 |
| max_pool_1, 2x2, stride 2max_pool_1، 2x2، stride 2 | (60 - 2)/2 + 1(60 - 2)/2 + 1 | 30 x 30 x 1030 x 30 x 10 | 00 |
| conv_2_1, 10 filters 3x3, validconv_2_1، 10 filters بحجم 3x3، valid | 30 - 3 + 130 - 3 + 1 | 28 x 28 x 1028 x 28 x 10 | 910910 |
| conv_2_2, 10 filters 3x3, validconv_2_2، 10 filters بحجم 3x3، valid | 28 - 3 + 128 - 3 + 1 | 26 x 26 x 1026 x 26 x 10 | 910910 |
| max_pool_2, 2x2, stride 2max_pool_2، 2x2، stride 2 | (26 - 2)/2 + 1(26 - 2)/2 + 1 | 13 x 13 x 1013 x 13 x 10 | 00 |
| flatten, dense 10, softmaxflatten، ثم dense 10، ثم softmax | 13 x 13 x 10 = 169013 x 13 x 10 = 1690 | 1010 | 1690 x 10 + 10 = 16,9101690 x 10 + 10 = 16,910 |
| Totalالمجموع | 19,92019,920 |
The pattern repeats: 19,920 parameters, of which the two pools contribute 0 while each removes three quarters of the activations. The dense layer holds 16,910 of the total because it multiplies the image-dependent 1690 by the ten classes. Click any activation map in the live page and it animates the window that produced it, which is the pooling and convolution arithmetic of this lecture rendered one cell at a time.
النمط يتكرر: 19,920 معاملًا، يساهم فيها الـ pool الاثنان بـ 0، بينما يزيل كل منهما ثلاثة أرباع الـ activations. وتحمل الطبقة الكثيفة (dense) 16,910 من المجموع لأنها تضرب العدد 1690 المعتمد على حجم الصورة في الفئات العشر. انقر أي activation map في الصفحة الحية وستعرض حركيًا النافذة التي أنتجتها، وهذا هو حساب الـ pooling والـ convolution في هذه المحاضرة معروضًا خليةً خلية.
Recall
How many parameters does the ConvNetJS first conv layer hold, and why does the map stay 32x32?كم معاملًا تحمل أول طبقة conv في ConvNetJS، ولماذا تبقى الخريطة 32x32؟
Quick checkاختبار سريع
In the ConvNetJS CIFAR-10 demo the first conv layer has 16 filters of 5x5x3. How many parameters does it hold?في عرض ConvNetJS على CIFAR-10، أول طبقة conv فيها 16 filter بحجم 5x5x3. كم معاملًا تحمل؟
Quick checkاختبار سريع
In CNN Explainer, conv_1_2 outputs 60x60x10. What does max_pool_1 with a 2x2 window and stride 2 output?في CNN Explainer، مخرج conv_1_2 هو 60x60x10. ما مخرج max_pool_1 بنافذة 2x2 وخطوة 2؟
Recapالخلاصة
If you remember nothing elseإن لم تتذكر شيئاً آخر فتذكّر هذا
- Pooling summarizes a window in each activation map independently: spatial size drops, channel count stays, 224x224x64 becomes 112x112x64.يلخّص الـ pooling نافذة داخل كل activation map على حدة: يصغر الحجم المكاني ويبقى عدد القنوات كما هو، فيصبح 224x224x64 هو 112x112x64.
- W2 = (W1 - F)/S + 1, H2 = (H1 - F)/S + 1, depth C unchanged, parameters 0.W2 = (W1 - F)/S + 1 وH2 = (H1 - F)/S + 1، والعمق C لا يتغير، وعدد المعاملات 0.
- On the slide's 4x4 slice, F = 2 and S = 2 give max [[6,8],[3,4]] and mean [[3.25,5.25],[2,2]].على شريحة 4x4 في الشريحة 22، مع F = 2 وS = 2 يعطي max النتيجة [[6,8],[3,4]] ويعطي mean النتيجة [[3.25,5.25],[2,2]].
- Max pooling adds approximate invariance to small shifts; 'max is always better' is a heuristic, and many modern networks use strided convolutions or global average pooling instead.يضيف max pooling ثباتًا تقريبيًا أمام الإزاحات الصغيرة؛ وعبارة «max أفضل دائمًا» قاعدة تجريبية لا قانون، وكثير من الشبكات الحديثة تستخدم بدلًا منه strided convolutions أو global average pooling.
- Filters form a hierarchy: edges in early layers, object parts in the middle, whole objects deep, because receptive fields grow with depth and pooling.تشكّل الـ filters تسلسلًا هرميًا: حواف في الطبقات الأولى، وأجزاء أجسام في الوسط، وأجسام كاملة في العمق، لأن الحقل الاستقبالي يكبر مع العمق ومع الـ pooling.
- CONV-RELU-CONV-RELU-POOL repeated three times then FC turns an image into class scores; car beats truck, airplane, ship, horse.تكرار CONV-RELU-CONV-RELU-POOL ثلاث مرات ثم طبقة FC يحوّل الصورة إلى درجات للفئات؛ وتتفوق car على truck وairplane وship وhorse.
- ConvNetJS first layer: 16 x 5 x 5 x 3 + 16 = 1216 parameters; CNN Explainer shapes: 64, 62, 60, 30, 28, 26, 13.الطبقة الأولى في ConvNetJS: 16 x 5 x 5 x 3 + 16 = 1216 معاملًا؛ وأشكال CNN Explainer هي: 64، 62، 60، 30، 28، 26، 13.
Sourcesالمصادر
- CS231n Convolutional Neural Networks for Visual Recognition, Pooling LayerDocsStanford UniversityPooling formulas, zero parameters, 75% discard, the argmax switch, and getting rid of pooling.صيغ الـ pooling، وصفر معاملات، واستبعاد 75%، ومفتاح الـ argmax (switch)، والاستغناء عن الـ pooling.(opens in a new tab)(يفتح في تبويب جديد)
- Deep Learning, chapter 9.3 PoolingBookGoodfellow, Bengio and Courville, MIT PressApproximate translation invariance and k times fewer inputs for the next layer, pp. 335 to 337.الثبات التقريبي أمام الإزاحة، ومدخلات أقل بـ k مرة للطبقة التالية، الصفحات 335 إلى 337.(opens in a new tab)(يفتح في تبويب جديد)
- Convolutional Deep Belief Networks for Scalable Unsupervised Learning of Hierarchical RepresentationsPaperLee, Grosse, Ranganath and Ng, ICML 2009Source of the faces, cars, elephants, chairs figure on slide 23: edges, object parts, objects.مصدر شكل الوجوه والسيارات والفيلة والكراسي في الشريحة 23: حواف، ثم أجزاء أجسام، ثم أجسام.(opens in a new tab)(يفتح في تبويب جديد)
- Visualizing and Understanding Convolutional NetworksPaperZeiler and Fergus, 2013Deconvolutional visualization showing the same hierarchy in a supervised ImageNet CNN.عرض بصري بالـ deconvolution يُظهر التسلسل الهرمي نفسه في CNN مُشرَف عليها مدرَّبة على ImageNet.(opens in a new tab)(يفتح في تبويب جديد)
- Striving for Simplicity: The All Convolutional NetPaperSpringenberg, Dosovitskiy, Brox and Riedmiller, 2014Max pooling replaced by strided convolution with no loss in accuracy.استبدال max pooling بـ strided convolution دون خسارة في الدقة.(opens in a new tab)(يفتح في تبويب جديد)
- Network In NetworkPaperLin, Chen and Yan, 2013Global average pooling as a classifier head, less prone to overfitting than fully connected layers.global average pooling كرأس للتصنيف، وهو أقل عرضة للـ overfitting من الطبقات المتصلة بالكامل.(opens in a new tab)(يفتح في تبويب جديد)
- A Theoretical Analysis of Feature Pooling in Visual RecognitionPaperBoureau, Ponce and LeCun, ICML 2010When max beats average depends on feature sparsity and pool size.تفوّق max على average يعتمد على تناثر الخصائص (sparsity) وحجم الـ pool.(opens in a new tab)(يفتح في تبويب جديد)
- torch.nn.MaxPool2dDocsPyTorch documentationFloor formula, stride defaulting to kernel size, ceil_mode, and C unchanged from input to output.صيغة الـ floor، والخطوة التي تساوي حجم الـ kernel افتراضيًا، وceil_mode، وبقاء C دون تغيير من المدخل إلى المخرج.(opens in a new tab)(يفتح في تبويب جديد)
- ConvNetJS CIFAR-10 demoDocsAndrej Karpathy, StanfordAbout 90% state of the art, 94% human, 2 px shifts, Adadelta; layer parameters printed live.أفضل نتيجة نحو 90%، والبشر 94%، وإزاحات 2 px، وAdadelta؛ ومعاملات كل طبقة تُطبع مباشرة.(opens in a new tab)(يفتح في تبويب جديد)
- ConvNetJS CIFAR-10 demo sourceDocsGitHub, karpathy/convnetjslayer_defs with pad 2 and 16, 20, 20 filters; trainer with batch size 4 and L2 decay 0.0001.layer_defs مع pad 2 و16 و20 و20 filter؛ والـ trainer بحجم دفعة 4 وL2 decay قدره 0.0001.(opens in a new tab)(يفتح في تبويب جديد)
- The CIFAR-10 datasetDocsAlex Krizhevsky, University of Toronto60,000 colour 32x32 images in 10 classes, 50,000 train and 10,000 test.60,000 صورة ملوّنة بحجم 32x32 في 10 فئات، 50,000 للتدريب و10,000 للاختبار.(opens in a new tab)(يفتح في تبويب جديد)
- CNN ExplainerDocsPolo Club of Data Science, Georgia TechInteractive Tiny VGG with layer shapes 64, 62, 60, 30, 28, 26, 13.Tiny VGG تفاعلية بأشكال طبقات 64، 62، 60، 30، 28، 26، 13.(opens in a new tab)(يفتح في تبويب جديد)
- Tiny VGG training scriptDocsGitHub, poloclub/cnn-explainer3x3 valid convolutions with 10 filters, 2x2 max pools, dense 10 with softmax.convolutions من نوع valid بحجم 3x3 مع 10 filters، وmax pools بحجم 2x2، وطبقة dense 10 مع softmax.(opens in a new tab)(يفتح في تبويب جديد)
- CNN Explainer: Learning Convolutional Neural Networks with Interactive VisualizationPaperWang et al., IEEE TVCG (IEEE VIS 2020)The paper behind the demo on slide 26.الورقة التي يقوم عليها العرض في الشريحة 26.(opens in a new tab)(يفتح في تبويب جديد)
- MIT 6.5940 TinyML and Efficient Deep Learning Computing, Lecture 2DocsSong Han, MITThe course whose Basics of Deep Learning lecture these slides follow.المقرر الذي تتبع هذه الشرائح محاضرته Basics of Deep Learning.(opens in a new tab)(يفتح في تبويب جديد)