دليل الأساسيات

وظائف الخسارة

A loss defines the objective used to assess predictions or another training target.

استمع إلى هذا الدليلرواه الذكاء الاصطناعي · ~3 min

في هذه الصفحةقراءة لمدة 3 دقائق
  1. نظرة عامة
  2. الغوص العميق
  3. التنفيذ في العالم الحقيقي
  4. مستقبل وظائف الخسارة
  5. وضعها موضع التنفيذ
  6. استمر في الاستكشاف
  7. الأسئلة المتداولة

نظرة عامة

Individual loss values are often combined into a scalar for optimization, and the chosen objective is a proxy that may differ from the application's evaluation metric.

الغوص العميق

A prediction loss compares outputs with training targets according to a specified rule. Those targets can be labels or values constructed for the learning task; they should not automatically be called unquestionable truth. Implementations may produce per-example losses and then sum or average them for an optimization step. Choosing the rule matters. Mean squared error averages squared residuals, giving large residuals more influence than mean absolute error, which averages their absolute values. For residuals one and three, mean squared error is five, while mean absolute error is two. These are illustrative calculations rather than performance results from a dataset. Classification commonly uses cross-entropy. With a one-hot target and a predicted probability p for its class, the loss is minus log p. A lower probability for the target class gives a larger loss, so confident wrong predictions can incur high loss. The logarithm base determines the units: base-two loss is in bits, while a natural logarithm gives nats. For a target probability of one-quarter, minus log-base-two p is two bits. Gradient-based optimization needs usable derivative information, but differentiability requirements should not be generalized to every learning algorithm. Some losses have nondifferentiable points handled by an appropriate subgradient or surrogate. Accuracy is a discrete evaluation metric and is generally not directly useful as a gradient-training objective. A suitable training loss supplies an optimization signal; final task quality needs evaluation using the relevant metrics.

التنفيذ في العالم الحقيقي

استخدام فقدان الإنتروبيا المتقاطعة لتدريب مصنف البريد الإلكتروني العشوائي الذي يعاقب التصنيفات الخاطئة الواثقة

اختيار متوسط ​​الخطأ المطلق للتنبؤ بأسعار المنازل بحيث لا تهيمن بعض القصور المتطرفة على التدريب

تطبيق فقدان التباين بحيث يقوم نموذج التعرف على الوجوه بجمع صور الشخص نفسه معًا

هندسة خسارة نموذج المكافأة لتوجيه روبوت الدردشة نحو استجابات أكثر فائدة وصدقًا

مستقبل وظائف الخسارة

Objective design can combine prediction terms, regularization, and other task requirements. Comparisons should state the target definition, formula, reduction, units, and evaluation metric. An objective can decrease while an application metric remains unchanged or worsens, so improvement should be measured rather than inferred from training loss alone. Custom losses need examination of the behavior they encourage as well as their numerical and optimization properties.

وضعها موضع التنفيذ

لماذا يهم

  • قرارات أوضح. يساعدك على فصل المطالبات الفنية الواضحة عن لغة التسويق.
  • التكلفة والميزانية. يمكنك طرح أسئلة تنفيذ أفضل قبل إنفاق المال أو الوقت.
  • الفريق وسير العمل. تتخذ الفرق ذات الفهم المشترك قرارات أفضل بشأن المنتجات والسياسات والتعلم.

احترس من

  • قد تستخدم الفرق المختلفة نفس المصطلح بشكل مختلف، لذا حدد النطاق مبكرًا.
  • يمكن أن تبدو المعايير قوية بينما يكون الأداء في العالم الحقيقي غير متساوٍ.
  • غالبًا ما يؤدي تجاهل جودة البيانات وخطط التقييم إلى نتائج هشة.

الخطوات التالية

  1. ابدأ بتعريف لغة واضحة للنتيجة التي تحتاجها.
  2. اختر مقياس نجاح واحد وحالة فشل واحدة قبل الاختبار.
  3. قم بتشغيل برنامج تجريبي صغير يحتوي على بيانات تمثيلية، وليس مجموعة تجريبية مصقولة.
  4. قم بالتوثيق حيث تساعد وظائف الخسارة وأين تكون الطرق الأبسط أفضل.

استمر في الاستكشاف

رسالة إخبارية مجانية

احصل على الإحاطة اليومية لمنظمة العفو الدولية

ثلاث قصص تم التحقق منها بواسطة الذكاء الاصطناعي كل صباح من أيام الأسبوع، مكتوبة باللغة الإنجليزية البسيطة. مجاني للأبد، بدون إعلانات.

بريد إلكتروني واحد كل يوم من أيام الأسبوع. إلغاء الاشتراك بنقرة واحدة. نحن لا نبيع أو نشارك عنوانك أبدًا.

اختبر نفسك

Take the Loss Functions quiz

تعليقات فورية على كل إجابة، وشهادة قابلة للمشاركة مع معرف يمكن التحقق منه بمجرد اجتياز الدورة التدريبية.

ابدأ الاختبار

دعم تعليم الذكاء الاصطناعي المجاني. AI Understanding هي منظمة 501(c)(3) غير ربحية - لا إعلانات ولا نظام حظر الاشتراك غير المدفوع على الإطلاق. قم بالتبرع

الأسئلة المتداولة

What is Loss Functions?

A loss defines the objective used to assess predictions or another training target. Individual loss values are often combined into a scalar for optimization, and the chosen objective is a proxy that may differ from the application's evaluation metric.

For a prediction task, what does its selected loss quantify against the training target?

A loss defines a training objective; it does not automatically measure every aspect of application quality.

ما هي دالة الخسارة الأكثر استخدامًا في مهام التصنيف؟

يقارن الإنتروبيا المتقاطعة التوزيعات الاحتمالية المتوقعة بالتسميات الحقيقية وهو الاختيار القياسي للتصنيف.

بالمقارنة مع متوسط الخطأ التربيعي، لماذا قد تختار متوسط الخطأ المطلق؟

يعالج الخطأ المطلق المتوسط ​​جميع الأخطاء بشكل متناسب بدلاً من تربيعها، لذلك يكون لبعض القيم المتطرفة تأثير أقل.

Why does gradient-based training need a usable loss derivative or suitable substitute?

This concerns gradient-based training, not a claim that every possible learning algorithm requires a differentiable loss.

How does one-hot class cross-entropy change as probability assigned to the target class becomes very small?

The term minus log p grows as the target-class probability shrinks. This does not guarantee a particular gradient magnitude for every model weight.

استمر في التعلم

أدلة ذات صلة

تم اختيار المزيد من الأدلة لهذا الموضوع

احصل على شهادة الذكاء الاصطناعي المجانيةدورة مجانية قصيرة واختبار. لا تكلفة ولا بطاقة. حوالي 2.5 ساعة.ابدأ مجانًا →