Глоссарий по машинному обучению

В этом глоссарии определены общие термины машинного обучения, а также термины, специфичные для TensorFlow.

А

абляция

Метод оценки важности функции или компонента путем временного удаления его из модели . Затем вы переобучаете модель без этой функции или компонента, и если переобученная модель работает значительно хуже, то удаленная функция или компонент, вероятно, были важны.

Например, предположим, что вы обучаете модель классификации на 10 признаках и достигаете точности 88 % на тестовом наборе . Чтобы проверить важность первой функции, вы можете переобучить модель, используя только девять других функций. Если переобученная модель работает значительно хуже (например, точность 55%), то удаленная функция, вероятно, была важна. И наоборот, если переобученная модель работает одинаково хорошо, то эта функция, вероятно, не так уж важна.

Абляция также может помочь определить важность:

  • Более крупные компоненты, например целая подсистема более крупной системы машинного обучения.
  • Процессы или методы, такие как этап предварительной обработки данных.

В обоих случаях вы увидите, как изменится (или не изменится) производительность системы после удаления компонента.

А/Б тестирование

Статистический способ сравнения двух (или более) методов — А и Б. Обычно A — это существующая технология, а B — новая технология. A/B-тестирование не только определяет, какой метод работает лучше, но также определяет, является ли разница статистически значимой.

A/B-тестирование обычно сравнивает одну метрику двух методов; например, как сравнивается точность модели для двух методов? Однако A/B-тестирование также позволяет сравнивать любое конечное число метрик.

чип-ускоритель

#GoogleCloud

Категория специализированных аппаратных компонентов, предназначенных для выполнения ключевых вычислений, необходимых для алгоритмов глубокого обучения.

Чипы-ускорители (или просто ускорители , для краткости) могут значительно повысить скорость и эффективность задач обучения и вывода по сравнению с ЦП общего назначения. Они идеально подходят для обучения нейронных сетей и аналогичных задач с интенсивными вычислениями.

Примеры чипов-ускорителей включают в себя:

  • Тензорные процессоры Google ( TPU ) со специальным оборудованием для глубокого обучения.
  • Графические процессоры NVIDIA, изначально предназначенные для обработки графики, предназначены для обеспечения параллельной обработки, что может значительно повысить скорость обработки.

точность

#основы

Количество правильных прогнозов классификации, разделенное на общее количество прогнозов. То есть:

$$\text{Accuracy} = \frac{\text{correct predictions}} {\text{correct predictions + incorrect predictions }}$$

Например, модель, которая сделала 40 правильных прогнозов и 10 неправильных прогнозов, будет иметь точность:

$$\text{Accuracy} = \frac{\text{40}} {\text{40 + 10}} = \text{80%}$$

Бинарная классификация дает конкретные названия различным категориям правильных и неправильных прогнозов . Итак, формула точности бинарной классификации выглядит следующим образом:

$$\text{Accuracy} = \frac{\text{TP} + \text{TN}} {\text{TP} + \text{TN} + \text{FP} + \text{FN}}$$

где:

Сравните и сопоставьте точность с точностью и отзывом .

действие

#рл

В обучении с подкреплением - механизм, с помощью которого агент переходит между состояниями окружающей среды . Агент выбирает действие, используя политику .

функция активации

#основы

Функция, которая позволяет нейронным сетям изучать нелинейные (сложные) связи между объектами и меткой.

Популярные функции активации включают в себя:

Графики функций активации никогда не представляют собой одиночные прямые линии. Например, график функции активации ReLU состоит из двух прямых:

Декартов график из двух линий. Первая строка имеет постоянное значение y, равное 0, идущее вдоль оси X от -бесконечности,0 до 0,-0. Вторая строка начинается с 0,0. Эта линия имеет наклон +1, поэтому она проходит от 0,0 до +бесконечности,+бесконечности.

График сигмовидной функции активации выглядит следующим образом:

Двумерный изогнутый график со значениями x, охватывающими область от -бесконечности до +положительного, а значения y охватывают диапазон от почти 0 до почти 1. Когда x равно 0, y равно 0,5. Наклон кривой всегда положительный, с наибольшим наклоном 0,0,5 и постепенно уменьшающимся по мере увеличения абсолютного значения x.

активное изучение

Подход к обучению , при котором алгоритм выбирает некоторые данные, на которых он учится. Активное обучение особенно ценно, когда помеченные примеры редки или дороги. Вместо слепого поиска разнообразного диапазона помеченных примеров алгоритм активного обучения выборочно ищет конкретный диапазон примеров, необходимый для обучения.

АдаГрад

Сложный алгоритм градиентного спуска, который масштабирует градиенты каждого параметра , эффективно давая каждому параметру независимую скорость обучения . Полное объяснение можно найти в этой статье .

агент

#рл

В обучении с подкреплением - сущность, которая использует политику для максимизации ожидаемой отдачи , полученной от перехода между состояниями среды .

агломеративная кластеризация

#кластеризация

См. иерархическую кластеризацию .

обнаружение аномалий

Процесс выявления выбросов . Например, если среднее значение для определенного объекта равно 100 со стандартным отклонением 10, то обнаружение аномалий должно пометить значение 200 как подозрительное.

АР

Аббревиатура дополненной реальности .

площадь под кривой PR

См. PR AUC (площадь под кривой PR) .

площадь под кривой ROC

См. AUC (площадь под кривой ROC) .

общий искусственный интеллект

Нечеловеческий механизм, демонстрирующий широкий спектр решений проблем, креативность и адаптивность. Например, программа, демонстрирующая общий искусственный интеллект, могла бы переводить текст, сочинять симфонии и преуспевать в играх, которые еще не изобретены.

искусственный интеллект

#основы

Нечеловеческая программа или модель , способная решать сложные задачи. Например, программа или модель, которая переводит текст, или программа или модель, которая идентифицирует заболевания по радиологическим изображениям, обладают искусственным интеллектом.

Формально машинное обучение — это подобласть искусственного интеллекта. Однако в последние годы некоторые организации начали использовать термины «искусственный интеллект» и «машинное обучение» как синонимы.

внимание

#язык

Механизм, используемый в нейронной сети , который указывает важность определенного слова или части слова. Внимание сжимает объем информации, необходимой модели для прогнозирования следующего токена/слова. Типичный механизм внимания может состоять из взвешенной суммы по набору входных данных, где вес каждого входного сигнала вычисляется другой частью нейронной сети.

Обратитесь также к самовниманию и многоголовому самовниманию , которые являются строительными блоками Трансформеров .

атрибут

#справедливость

Синоним функции .

В рамках справедливости машинного обучения атрибуты часто относятся к характеристикам, относящимся к отдельным людям.

выборка атрибутов

#df

Тактика обучения леса решений , в которой каждое дерево решений при изучении условия учитывает только случайное подмножество возможных признаков . Обычно для каждого узла отбирается различное подмножество функций. Напротив, при обучении дерева решений без выборки атрибутов для каждого узла рассматриваются все возможные функции.

AUC (Площадь под кривой ROC)

#основы

Число от 0,0 до 1,0, обозначающее способность модели бинарной классификации отделять положительные классы от отрицательных классов . Чем ближе AUC к 1,0, тем лучше способность модели отделять классы друг от друга.

Например, на следующем рисунке показана модель классификатора, которая идеально отделяет положительные классы (зеленые овалы) от отрицательных классов (фиолетовые прямоугольники). Эта нереально идеальная модель имеет AUC 1,0:

Числовая линия с 8 положительными примерами с одной стороны и 9 отрицательными примерами с другой.

И наоборот, на следующем рисунке показаны результаты для модели классификатора, которая генерировала случайные результаты. Эта модель имеет AUC 0,5:

Числовая линия с 6 положительными примерами и 6 отрицательными примерами. Последовательность примеров такова: положительный, отрицательный, положительный, отрицательный, положительный, отрицательный, положительный, отрицательный, положительный отрицательный, положительный, отрицательный.

Да, предыдущая модель имеет AUC 0,5, а не 0,0.

Большинство моделей находятся где-то между двумя крайностями. Например, следующая модель несколько отделяет положительные значения от отрицательных и поэтому имеет AUC где-то между 0,5 и 1,0:

Числовая линия с 6 положительными примерами и 6 отрицательными примерами. Последовательность примеров следующая: отрицательный, отрицательный, отрицательный, отрицательный, положительный, отрицательный, положительный, положительный, отрицательный, положительный, положительный, положительный.

AUC игнорирует любые значения, установленные вами для порога классификации . Вместо этого AUC учитывает все возможные пороги классификации.

дополненная реальность

#изображение

Технология, которая накладывает изображение, созданное компьютером, на представление пользователя о реальном мире, создавая таким образом составное представление.

автоэнкодер

#язык
#изображение

Система, которая учится извлекать наиболее важную информацию из входных данных. Автоэнкодеры представляют собой комбинацию кодера и декодера . Автоэнкодеры полагаются на следующий двухэтапный процесс:

  1. Кодер преобразует входные данные в (обычно) низкоразмерный (промежуточный) формат с потерями.
  2. Декодер создает версию исходного ввода с потерями, сопоставляя формат меньшей размерности с исходным входным форматом более высокой размерности.

Автокодировщики обучаются сквозно, заставляя декодер пытаться как можно точнее восстановить исходный входной сигнал из промежуточного формата кодера. Поскольку промежуточный формат меньше (меньшая размерность), чем исходный формат, автокодировщику приходится узнавать, какая информация на входе важна, и выходные данные не будут полностью идентичны входным.

Например:

  • Если входные данные представляют собой графику, неточная копия будет похожа на исходную графику, но несколько изменена. Возможно, неточная копия удаляет шум из исходной графики или заполняет некоторые недостающие пиксели.
  • Если входные данные представляют собой текст, автокодировщик сгенерирует новый текст, который имитирует (но не идентичен) исходному тексту.

См. также вариационные автоэнкодеры .

предвзятость автоматизации

#справедливость

Когда человек, принимающий решения, предпочитает рекомендации автоматизированной системы принятия решений информации, полученной без автоматизации, даже если автоматизированная система принятия решений допускает ошибки.

АвтоМЛ

Любой автоматизированный процесс построения моделей машинного обучения . AutoML может автоматически выполнять такие задачи, как следующие:

AutoML полезен для специалистов по данным, поскольку может сэкономить им время и усилия при разработке конвейеров машинного обучения и повысить точность прогнозирования. Это также полезно для неспециалистов, поскольку делает сложные задачи машинного обучения более доступными для них.

авторегрессионная модель

#язык
#изображение
#генеративныйИИ

Модель , которая делает прогноз на основе собственных предыдущих прогнозов. Например, авторегрессионные языковые модели прогнозируют следующий токен на основе ранее предсказанных токенов. Все модели большого языка на основе Transformer являются авторегрессионными.

Напротив, модели изображений на основе GAN обычно не являются авторегрессионными, поскольку они генерируют изображение за один проход вперед, а не поэтапно итеративно. Однако некоторые модели генерации изображений являются авторегрессионными, поскольку они генерируют изображение поэтапно.

вспомогательная потеря

Функция потерь , используемая вместе с основной функцией потерь модели нейронной сети , которая помогает ускорить обучение на ранних итерациях, когда веса инициализируются случайным образом.

Вспомогательные функции потерь перемещают эффективные градиенты на более ранние слои . Это облегчает сходимость во время обучения , решая проблему исчезновения градиента .

средняя точность

Метрика для подведения итогов производительности ранжированной последовательности результатов. Средняя точность рассчитывается путем взятия среднего значения точности для каждого релевантного результата (каждого результата в ранжированном списке, отзыв которого увеличивается по сравнению с предыдущим результатом).

См. также Площадь под кривой PR .

условие совмещения осей

#df

В дереве решений - условие , включающее только один признак . Например, если площадь является объектом, то условием выравнивания по оси является следующее:

area > 200

Сравните с наклонным состоянием .

Б

обратное распространение ошибки

#основы

Алгоритм, реализующий градиентный спуск в нейронных сетях .

Обучение нейронной сети включает в себя множество итераций следующего двухпроходного цикла:

  1. Во время прямого прохода система обрабатывает пакет примеров для получения прогнозов. Система сравнивает каждый прогноз с каждым значением метки . Разница между прогнозом и значением метки — это потеря для этого примера. Система суммирует потери для всех примеров, чтобы вычислить общие потери для текущей партии.
  2. Во время обратного прохода (обратного распространения ошибки) система уменьшает потери, корректируя веса всех нейронов во всех скрытых слоях .

Нейронные сети часто содержат множество нейронов во многих скрытых слоях. Каждый из этих нейронов по-разному вносит свой вклад в общую потерю. Обратное распространение ошибки определяет, следует ли увеличивать или уменьшать веса, применяемые к конкретным нейронам.

Скорость обучения — это множитель, который контролирует степень увеличения или уменьшения каждого веса при каждом обратном проходе. Большая скорость обучения будет увеличивать или уменьшать каждый вес больше, чем низкая скорость обучения.

С точки зрения исчисления, обратное распространение ошибки реализует цепное правило исчисления. То есть обратное распространение ошибки вычисляет частную производную ошибки по каждому параметру. Дополнительные сведения см. в этом руководстве в ускоренном курсе машинного обучения .

Несколько лет назад специалистам по машинному обучению приходилось писать код для реализации обратного распространения ошибки. Современные API машинного обучения, такие как TensorFlow, теперь реализуют обратное распространение ошибки. Уф!

упаковка в мешки

#df

Метод обучения ансамбля , при котором каждая составляющая модель обучается на случайном подмножестве обучающих примеров , выбранных с заменой . Например, случайный лес — это набор деревьев решений , обученных с помощью мешков.

Термин «бэггинг» является сокращением от бутстрап - агрегирования .

мешок слов

#язык

Представление слов во фразе или отрывке независимо от порядка. Например, мешок слов одинаково представляет следующие три фразы:

  • собака прыгает
  • прыгает на собаку
  • собака прыгает

Каждое слово сопоставляется с индексом в разреженном векторе , где вектор имеет индекс для каждого слова в словаре. Например, фраза «собака прыгает» отображается в вектор признаков с ненулевыми значениями трех индексов, соответствующих словам « собака » и «прыжки» . Ненулевое значение может быть любым из следующих:

  • 1 указывает на наличие слова.
  • Подсчет количества раз, когда слово появляется в сумке. Например, если бы фраза была «бордовая собака» — это собака с бордовой шерстью , то и «бордовый» , и «собака» были бы представлены как 2, а другие слова были бы представлены как 1.
  • Некоторое другое значение, например логарифм количества раз, которое слово появляется в сумке.

базовый уровень

Модель , используемая в качестве ориентира для сравнения эффективности другой модели (обычно более сложной). Например, модель логистической регрессии может служить хорошей основой для глубокой модели .

Для конкретной проблемы базовый уровень помогает разработчикам моделей количественно определить минимальную ожидаемую производительность, которой должна достичь новая модель, чтобы новая модель была полезной.

партия

#основы

Набор примеров , используемых в одной обучающей итерации . Размер партии определяет количество примеров в партии.

См. «Эпоха» для объяснения того, как партия связана с эпохой.

пакетный вывод

#TensorFlow
#GoogleCloud

Процесс вывода прогнозов на нескольких немаркированных примерах , разделенных на более мелкие подмножества («партии»).

Пакетный вывод может использовать возможности распараллеливания микросхем-ускорителей . То есть несколько ускорителей могут одновременно делать прогнозы на разных пакетах немаркированных примеров, резко увеличивая количество выводов в секунду.

пакетная нормализация

Нормализация ввода или вывода функций активации в скрытом слое . Пакетная нормализация может дать следующие преимущества:

размер партии

#основы

Количество примеров в пакете . Например, если размер пакета равен 100, модель обрабатывает 100 примеров за итерацию .

Ниже приведены популярные стратегии размера партии:

  • Стохастический градиентный спуск (SGD) , в котором размер пакета равен 1.
  • полный пакет, в котором размер пакета — это количество примеров во всем обучающем наборе . Например, если обучающий набор содержит миллион примеров, то размер пакета будет составлять миллион примеров. Полная партия обычно является неэффективной стратегией.
  • мини-пакет , размер которого обычно составляет от 10 до 1000. Мини-пакет обычно является наиболее эффективной стратегией.

Байесовская нейронная сеть

Вероятностная нейронная сеть , которая учитывает неопределенность в весах и выходных данных. Стандартная модель регрессии нейронной сети обычно предсказывает скалярное значение; например, стандартная модель прогнозирует цену дома в 853 000 долларов. Напротив, байесовская нейронная сеть предсказывает распределение значений; например, байесовская модель предсказывает цену дома в размере 853 000 со стандартным отклонением 67 200.

Байесовская нейронная сеть опирается на теорему Байеса для расчета неопределенностей в весах и прогнозах. Байесовская нейронная сеть может быть полезна, когда важно количественно оценить неопределенность, например, в моделях, связанных с фармацевтическими препаратами. Байесовские нейронные сети также могут помочь предотвратить переобучение .

Байесовская оптимизация

Метод модели вероятностной регрессии для оптимизации дорогостоящих в вычислительном отношении целевых функций путем оптимизации суррогатной функции, которая количественно определяет неопределенность с помощью метода байесовского обучения. Поскольку байесовская оптимизация сама по себе очень дорога, ее обычно используют для оптимизации дорогостоящих в оценке задач с небольшим количеством параметров, таких как выбор гиперпараметров .

уравнение Беллмана

#рл

При обучении с подкреплением оптимальная Q-функция удовлетворяет следующему тождеству:

\[Q(s, a) = r(s, a) + \gamma \mathbb{E}_{s'|s,a} \max_{a'} Q(s', a')\]

Алгоритмы обучения с подкреплением применяют эту идентичность для создания Q-обучения с помощью следующего правила обновления:

\[Q(s,a) \gets Q(s,a) + \alpha \left[r(s,a) + \gamma \displaystyle\max_{\substack{a_1}} Q(s’,a’) - Q(s,a) \right] \]

Помимо обучения с подкреплением, уравнение Беллмана находит применение в динамическом программировании. См. статью в Википедии об уравнении Беллмана .

BERT (представления двунаправленного кодировщика от трансформаторов)

#язык

Архитектура модели для представления текста. Обученная модель BERT может действовать как часть более крупной модели для классификации текста или других задач машинного обучения.

BERT имеет следующие характеристики:

Варианты BERT включают:

Обзор BERT см. в разделе «Открытый исходный код BERT: современное предварительное обучение обработке естественного языка» .

предвзятость (этика/справедливость)

#справедливость
#основы

1. Стереотипы, предрассудки или фаворитизм в отношении одних вещей, людей или групп по сравнению с другими. Эти предубеждения могут повлиять на сбор и интерпретацию данных, дизайн системы и то, как пользователи взаимодействуют с системой. К формам этого типа предвзятости относятся:

2. Систематическая ошибка, вызванная процедурой выборки или отчетности. К формам этого типа предвзятости относятся:

Не путать с термином «предвзятость» в моделях машинного обучения или «предвзятость прогнозирования» .

предвзятость (математика) или термин предвзятости

#основы

Перехват или смещение от начала координат. Смещение — это параметр в моделях машинного обучения, который обозначается одним из следующих символов:

  • б
  • ш 0

Например, смещение — это буква b в следующей формуле:

$$y' = b + w_1x_1 + w_2x_2 + … w_nx_n$$

В простой двумерной линии смещение означает просто «пересечение оси Y». Например, смещение линии на следующем рисунке равно 2.

График линии с наклоном 0,5 и смещением (пересечение оси Y) 2.

Смещение существует, потому что не все модели начинаются с начала координат (0,0). Например, предположим, что вход в парк развлечений стоит 2 евро и дополнительно 0,5 евро за каждый час пребывания клиента. Следовательно, модель, отображающая общую стоимость, имеет смещение 2, поскольку минимальная стоимость составляет 2 евро.

Предвзятость не следует путать с предвзятостью в вопросах этики и справедливости или предвзятостью прогнозирования .

двунаправленный

#язык

Термин, используемый для описания системы, которая оценивает текст, который предшествует и следует за целевым разделом текста. Напротив, однонаправленная система оценивает только текст, который предшествует целевому разделу текста.

Например, рассмотрим модель языка в масках , которая должна определять вероятности для слова или слов, представляющих подчеркивание в следующем вопросе:

Что с тобой _____?

Однонаправленная языковая модель должна была бы основывать свои вероятности только на контексте, обеспечиваемом словами «Что», «есть» и «the». Напротив, двунаправленная языковая модель также может получить контекст от слов «с» и «вы», что может помочь модели генерировать более качественные прогнозы.

двунаправленная языковая модель

#язык

Языковая модель , определяющая вероятность присутствия данного токена в заданном месте во фрагменте текста на основе предыдущего и последующего текста.

биграмма

#seq
#язык

N-грамма , в которой N=2.

бинарная классификация

#основы

Тип задачи классификации , которая прогнозирует один из двух взаимоисключающих классов:

Например, каждая из следующих двух моделей машинного обучения выполняет двоичную классификацию:

  • Модель, определяющая, являются ли сообщения электронной почты спамом (положительный класс) или нет (негативный класс).
  • Модель, которая оценивает медицинские симптомы, чтобы определить, есть ли у человека определенное заболевание (положительный класс) или нет этого заболевания (негативный класс).

Сравните с многоклассовой классификацией .

См. также логистическую регрессию и порог классификации .

двоичное состояние

#df

В дереве решенийусловие , имеющее только два возможных результата, обычно «да» или «нет» . Например, следующее двоичное условие:

temperature >= 100

Сравните с небинарным состоянием .

группирование

Синоним квитирования .

BLEU (дублёр двуязычной оценки)

#язык

Оценка от 0,0 до 1,0 включительно, указывающая на качество перевода между двумя человеческими языками (например, между английским и русским). Оценка BLEU 1,0 указывает на идеальный перевод; оценка BLEU 0,0 указывает на ужасный перевод.

повышение

Метод машинного обучения, который итеративно объединяет набор простых и не очень точных классификаторов (называемых «слабыми» классификаторами) в классификатор с высокой точностью («сильный» классификатор) путем увеличения веса примеров, которые модель в данный момент неправильно классифицирует.

Ограничительная рамка

#изображение

На изображении координаты ( x , y ) прямоугольника вокруг интересующей области, например собаки на изображении ниже.

Фотография собаки, сидящей на диване. Зеленая ограничивающая рамка с координатами верхнего левого угла (275, 1271) и координатами нижнего правого угла (2954, 2761) окружает тело собаки.

вещание

Расширение формы операнда в матричной математической операции до размеров , совместимых для этой операции. Например, линейная алгебра требует, чтобы два операнда в операции сложения матриц имели одинаковые размерности. Следовательно, вы не можете добавить матрицу формы (m, n) к вектору длины n. Широковещательная рассылка позволяет выполнить эту операцию, виртуально расширяя вектор длины n до матрицы формы (m, n) путем репликации одних и тех же значений в каждом столбце.

Например, учитывая следующие определения, линейная алгебра запрещает A+B, поскольку A и B имеют разные размерности:

A = [[7, 10, 4],
     [13, 5, 9]]
B = [2]

Однако широковещание позволяет осуществлять операцию A+B, виртуально расширяя B до:

 [[2, 2, 2],
  [2, 2, 2]]

Таким образом, A+B теперь является допустимой операцией:

[[7, 10, 4],  +  [[2, 2, 2],  =  [[ 9, 12, 6],
 [13, 5, 9]]      [2, 2, 2]]      [15, 7, 11]]

Более подробную информацию смотрите в следующем описании трансляции в NumPy .

группирование

#основы

Преобразование одного объекта в несколько двоичных объектов, называемых сегментами или контейнерами , обычно на основе диапазона значений. Вырезанный объект обычно является непрерывным объектом .

Например, вместо того, чтобы представлять температуру как один непрерывный признак с плавающей запятой, вы можете разбить диапазоны температур на отдельные сегменты, например:

  • <= 10 градусов по Цельсию будет «холодным» ведром.
  • 11–24 градуса по Цельсию будет «умеренным» ведром.
  • >= 25 градусов по Цельсию будет «теплым» ведром.

Модель будет обрабатывать каждое значение в одном и том же сегменте одинаково. Например, значения 13 и 22 относятся к сегменту умеренного климата, поэтому модель обрабатывает эти два значения одинаково.

С

калибровочный слой

Корректировка после прогнозирования, обычно для учета систематической ошибки прогноза . Скорректированные прогнозы и вероятности должны соответствовать распределению наблюдаемого набора меток.

поколение кандидатов

#recsystems

Начальный набор рекомендаций, выбранный рекомендательной системой . Например, рассмотрим книжный магазин, предлагающий 100 000 наименований. На этапе генерации кандидатов создается гораздо меньший список подходящих книг для конкретного пользователя, скажем, 500. Но даже 500 книг — это слишком много, чтобы рекомендовать пользователю. Последующие, более дорогостоящие этапы системы рекомендаций (такие как выставление оценок и изменение рейтинга ) сводят эти 500 к гораздо меньшему и более полезному набору рекомендаций.

выборка кандидатов

Оптимизация времени обучения, которая вычисляет вероятность для всех положительных меток, используя, например, softmax , но только для случайной выборки отрицательных меток. Например, для примера, помеченного как «бигль» и «собака» , выборка кандидатов вычисляет прогнозируемые вероятности и соответствующие условия потерь для:

  • бигль
  • собака
  • случайное подмножество оставшихся отрицательных классов (например, кот , леденец , забор ).

Идея состоит в том, что негативные классы могут учиться на менее частом негативном подкреплении, пока позитивные классы всегда получают правильное положительное подкрепление, и это действительно наблюдается эмпирически.

Кандидатская выборка более эффективна в вычислительном отношении, чем алгоритмы обучения, которые вычисляют прогнозы для всех отрицательных классов, особенно когда количество отрицательных классов очень велико.

категориальные данные

#основы

Функции , имеющие определенный набор возможных значений. Например, рассмотрим категориальную функцию под названием traffic-light-state , которая может иметь только одно из следующих трех возможных значений:

  • red
  • yellow
  • green

Представляя traffic-light-state как категориальную характеристику, модель может изучить различное влияние red , green и yellow на поведение водителя.

Категориальные признаки иногда называют дискретными признаками .

Сравните с числовыми данными .

причинно-языковая модель

#язык

Синоним однонаправленной языковой модели .

См. двунаправленную языковую модель , чтобы сравнить различные направленные подходы к языковому моделированию.

центроид

#кластеризация

Центр кластера, определенный алгоритмом k-средних или k-медианы . Например, если k равно 3, то алгоритм k-средних или k-медианы находит 3 центроида.

кластеризация на основе центроидов

#кластеризация

Категория алгоритмов кластеризации , которая организует данные в неиерархические кластеры. k-means — наиболее широко используемый алгоритм кластеризации на основе центроидов.

В отличие от алгоритмов иерархической кластеризации .

подсказка по цепочке мыслей

#язык
#генеративныйИИ

Метод быстрого проектирования , который побуждает большую языковую модель (LLM) шаг за шагом объяснять свои рассуждения. Например, рассмотрите следующую подсказку, уделив особое внимание второму предложению:

Какую силу перегрузки испытает водитель автомобиля, разгоняющегося от 0 до 60 миль в час за 7 секунд? В ответе покажите все соответствующие расчеты.

Ответ LLM, скорее всего, будет следующим:

  • Покажите последовательность физических формул, вставляя значения 0, 60 и 7 в соответствующие места.
  • Объясните, почему он выбрал именно эти формулы и что означают различные переменные.

Подсказки по цепочке мыслей заставляют LLM выполнять все вычисления, которые могут привести к более правильному ответу. Кроме того, подсказки по цепочке мыслей позволяют пользователю изучить шаги LLM, чтобы определить, имеет ли ответ смысл.

контрольно-пропускной пункт

Данные, которые фиксируют состояние параметров модели на определенной итерации обучения. Контрольные точки позволяют экспортировать веса модели или выполнять обучение в нескольких сеансах. Контрольные точки также позволяют обучать продолжению прошлых ошибок (например, прерывания задания).

При точной настройке отправной точкой обучения новой модели будет конкретная контрольная точка предварительно обученной модели .

сорт

#основы

Категория, к которой может принадлежать метка . Например:

Модель классификации предсказывает класс. Напротив, регрессионная модель предсказывает число, а не класс.

модель классификации

#основы

Модель , предсказание которой является классом . Например, ниже приведены все модели классификации:

  • Модель, которая предсказывает язык входного предложения (французский? испанский? итальянский?).
  • Модель, предсказывающая породы деревьев (клен? дуб? баобаб?).
  • Модель, которая прогнозирует положительный или отрицательный класс конкретного заболевания.

Напротив, регрессионные модели предсказывают числа, а не классы.

Два распространенных типа классификационных моделей:

порог классификации

#основы

В двоичной классификации - число от 0 до 1, которое преобразует необработанные выходные данные модели логистической регрессии в прогноз либо положительного , либо отрицательного класса . Обратите внимание, что порог классификации — это значение, которое выбирает человек, а не значение, выбранное при обучении модели.

Модель логистической регрессии выводит необработанное значение от 0 до 1. Затем:

  • Если это необработанное значение превышает порог классификации, то прогнозируется положительный класс.
  • Если это необработанное значение меньше порога классификации, то прогнозируется отрицательный класс.

Например, предположим, что порог классификации равен 0,8. Если исходное значение равно 0,9, модель прогнозирует положительный класс. Если исходное значение равно 0,7, то модель прогнозирует отрицательный класс.

Выбор порога классификации сильно влияет на количество ложноположительных и ложноотрицательных результатов .

несбалансированный по классам набор данных

#основы

Набор данных для задачи классификации, в которой общее количество меток каждого класса значительно различается. Например, рассмотрим набор данных двоичной классификации, две метки которого разделены следующим образом:

  • 1 000 000 негативных ярлыков
  • 10 положительных ярлыков

Соотношение отрицательных и положительных меток составляет 100 000 к 1, поэтому это набор данных с несбалансированным классом.

Напротив, следующий набор данных не является несбалансированным по классам, поскольку соотношение отрицательных меток к положительным меткам относительно близко к 1:

  • 517 отрицательных ярлыков
  • 483 положительных метки

Многоклассовые наборы данных также могут быть несбалансированными по классам. Например, следующий набор данных многоклассовой классификации также несбалансирован по классам, поскольку одна метка содержит гораздо больше примеров, чем две другие:

  • 1 000 000 этикеток класса «зеленый»
  • 200 этикеток класса «фиолетовый».
  • 350 этикеток класса «оранжевый».

См. также энтропию , класс большинства и класс меньшинства .

вырезка

#основы

Техника обработки выбросов путем выполнения одного или обоих следующих действий:

  • Уменьшение значений функций , превышающих максимальный порог, до этого максимального порога.
  • Увеличение значений функций, которые меньше минимального порога, до этого минимального порога.

Например, предположим, что <0,5% значений определенного признака выходят за пределы диапазона 40–60. В этом случае вы можете сделать следующее:

  • Обрежьте все значения выше 60 (максимальный порог), чтобы они составляли ровно 60.
  • Обрежьте все значения ниже 40 (минимальный порог), чтобы они составляли ровно 40.

Выбросы могут повредить модели, иногда вызывая переполнение весов во время обучения. Некоторые выбросы также могут существенно испортить такие показатели, как точность . Обрезка — распространенный метод ограничения ущерба.

Отсечение градиента приводит к тому, что значения градиента находятся в пределах заданного диапазона во время обучения.

Облачный ТПУ

#TensorFlow
#GoogleCloud

Специализированный аппаратный ускоритель, предназначенный для ускорения рабочих нагрузок машинного обучения на Google Cloud Platform.

кластеризация

#кластеризация

Группирование связанных примеров , особенно во время неконтролируемого обучения . После того, как все примеры сгруппированы, человек может при желании предоставить значение каждому кластеру.

Существует много алгоритмов кластеризации. Например, примеры Algorithm Algorithm A-Means , основанные на их близости к центру , как на следующей диаграмме:

Двумерный график, в котором ось X помечена «ширина дерева», а ось Y помечена «высота дерева». График содержит две центральные и несколько десятков точек данных. Точки данных классифицируются на основе их близости. То есть точки данных, ближайшие к одному центру, классифицируются как «кластер 1», в то время как ближайшие к другому центроиду классифицируются как «кластер 2».

Затем человеческий исследователь мог рассмотреть кластеры и, например, пометить кластер 1 как «карликовые деревья» и кластер 2 как «полноразмерные деревья».

В качестве другого примера рассмотрим алгоритм кластеризации, основанный на расстоянии примера от центральной точки, показанного следующим образом:

Десятки точек данных расположены в концентрических кругах, почти как отверстия вокруг центра доски DART. Самое внутреннее кольцо точек данных классифицируется как «кластер 1», среднее кольцо классифицируется как «кластер 2», а самое внешнее кольцо как «кластер 3.»

совместная адаптация

Когда нейроны предсказывают паттерны в обучении данных, полагаясь почти исключительно на выходы конкретных других нейронов, а не полагаться на поведение сети в целом. Когда закономерности, которые вызывают совместное адаптацию, не присутствуют в данных проверки, то коадаптация вызывает переосмысление. Регуляризация отсева снижает коадаптацию, потому что выпадение гарантирует, что нейроны не могут полагаться исключительно на конкретные другие нейроны.

совместная фильтрация

#recsystems

Сделать прогнозы о интересах одного пользователя на основе интересов многих других пользователей. Совместная фильтрация часто используется в системах рекомендаций .

состояние

#df

В дереве решений любой узел , который оценивает выражение. Например, следующая часть дерева решений содержит два условия:

Дерево решений, состоящее из двух условий: (x> 0) и (y> 0).

Условие также называется разделением или тестом.

Контрастное состояние с листом .

Смотрите также:

конфигурация

Процесс назначения начальных значений свойств, используемых для обучения модели, включая:

В проектах машинного обучения конфигурация может быть выполнена с помощью специального файла конфигурации или через библиотеки конфигурации, такие как следующее:

Подтверждение смещения

#справедливость

Тенденция искать, интерпретировать, пользоваться и вспоминать информацию таким образом, что подтверждает свои ранее существовавшие убеждения или гипотезы. Разработчики машинного обучения могут непреднамеренно собирать или маркировать данные способами, которые влияют на результат, подтверждающий их существующие убеждения. Связь с подтверждением является формой неявного предвзятости .

Смещение экспериментатора является формой предвзятости подтверждения, в которой экспериментатор продолжает тренировочные модели до тех пор, пока не будет подтверждена ранее существовавшая гипотеза.

матрица путаницы

#основы

Таблица NXN, которая суммирует количество правильных и неправильных прогнозов, которые сделала классификационная модель . Например, рассмотрим следующую матрицу путаницы для модели бинарной классификации :

Опухоль (прогнозируется) Не нулевой (прогнозируется)
Опухоль (наземная правда) 18 (TP) 1 (FN)
Не нулевой (наземная правда) 6 (FP) 452 (TN)

Предыдущая матрица путаницы показывает следующее:

  • Из 19 прогнозов, в которых основная истина была опухоли, модель правильно классифицировала 18 и неправильно классифицирована 1.
  • Из 458 предсказаний, в которых основная истина не была нулевой, модель правильно классифицировала 452 и неверно классифицирована 6.

Матрица путаницы для многоклассной проблемы классификации может помочь вам определить шаблоны ошибок. Например, рассмотрим следующую матрицу путаницы для многоклассной модели классификации с 3 классами, которая классифицирует три различных типа IRIS (Virginica, Versicolor и Setosa). Когда основной правдой была Вирджика, матрица путаницы показывает, что модель была гораздо чаще ошибочно предсказать Versicolor, чем Setosa:

Setosa (прогнозируется) Versicolor (прогнозируется) Виригика (прогнозируется)
Сетоза (наземная правда) 88 12 0
Versicolor (наземная правда) 6 141 7
Виригика (наземная правда) 2 27 109

В качестве еще одного примера, матрица путаницы может показать, что модель, обученная распознавать рукописные цифры, имеет тенденцию ошибочно предсказывать 9 вместо 4 или ошибочно предсказывать 1 вместо 7.

Матрицы путаницы содержат достаточную информацию для расчета различных показателей производительности, включая точность и отзыв .

Расположение избирательного округа

#язык

Разделение предложения на меньшие грамматические структуры («компоненты»). Более поздняя часть системы ML, такая как модель понимания естественного языка , может проанализировать избирателей легче, чем первоначальное предложение. Например, рассмотрим следующее предложение:

Мой друг усыновил двух кошек.

Паризер избирательного округа может разделить это предложение на следующие два избирателя:

  • Мой друг - существительная фраза.
  • Принятые две кошки - это глагольная фраза.

Эти составляющие могут быть дополнительно разделены на более мелкие составляющие. Например, глагольная фраза

принял две кошки

может быть дополнительно подразделен на:

  • Принято глагол.
  • Две кошки - еще одна существительная фраза.

непрерывная особенность

#основы

Особенность с плавающей точкой с бесконечным диапазоном возможных значений, таких как температура или вес.

Сравните с дискретной функцией .

удобство отбора проб

Использование набора данных, не собранного с научной точки зрения, для проведения быстрых экспериментов. Позже, важно перейти на набор данных с научно собранным.

конвергенция

#основы

Государство достигло, когда значения потерь меняются очень мало или вообще не с каждой итерацией . Например, следующая кривая потерь предполагает конвергенцию около 700 итераций:

Картезианский сюжет. Ось X — потери. Ось Y-это количество итераций обучения. Потеря очень высока во время первых итераций, но резко падает. Примерно через 100 итераций потеря все еще спускается, но гораздо более постепенно. Примерно через 700 итераций потеря остается плоской.

Модель сходится , когда дополнительное обучение не улучшит модель.

В глубоком обучении значения потерь иногда остаются постоянными или почти для многих итераций, прежде чем, наконец, спуститься. В течение длительного периода постоянных значений потерь вы можете временно получить ложное чувство сходимости.

Смотрите также раннюю остановку .

выпуклая функция

Функция, у которой область над графиком функции представляет собой выпуклое множество . Прототип выпуклой функции имеет форму буквы U. Например, все следующие выпуклые функции:

U-образные кривые, каждая с одной точкой минимума.

Напротив, следующая функция не является выпуклой. Обратите внимание, что область над графиком не является выпуклым множеством:

W-образная кривая с двумя разными точками локального минимума.

Строго выпуклая функция имеет ровно одну точку локального минимума, которая также является точкой глобального минимума. Классические U-образные функции являются строго выпуклыми функциями. Однако некоторые выпуклые функции (например, прямые) не имеют U-образной формы.

выпуклая оптимизация

Процесс использования математических методов, таких как градиентный спуск, для нахождения минимума выпуклой функции . Многие исследования в области машинного обучения были сосредоточены на формулировании различных задач в виде задач выпуклой оптимизации и более эффективном решении этих проблем.

Для получения полной информации см. Boyd and Vandenberghe, Convex Optimization .

выпуклое множество

Подмножество евклидова пространства, в котором линия, проведенная между любыми двумя точками этого подмножества, полностью остается внутри этого подмножества. Например, следующие две фигуры являются выпуклыми множествами:

Одна иллюстрация прямоугольника. Еще одна иллюстрация овала.

Напротив, следующие две фигуры не являются выпуклыми множествами:

Одна иллюстрация круговой диаграммы с отсутствующим фрагментом. Еще одна иллюстрация крайне неправильного многоугольника.

свертка

#изображение

В математике, условно говоря, смесь двух функций. В машинном обучении свертка смешивает сверточный фильтр и входную матрицу для обучения весов .

Термин «свертка» в машинном обучении часто является сокращением для обозначения сверточной операции или сверточного слоя .

Без сверток алгоритму машинного обучения пришлось бы изучать отдельный вес для каждой ячейки в большом тензоре . Например, алгоритм машинного обучения, обучающийся на изображениях размером 2K x 2K, будет вынужден найти 4M отдельных весов. Благодаря сверткам алгоритму машинного обучения достаточно найти веса для каждой ячейки в сверточном фильтре , что значительно сокращает объем памяти, необходимой для обучения модели. Когда применяется сверточный фильтр, он просто реплицируется по ячейкам, так что каждая из них умножается на фильтр.

сверточный фильтр

#изображение

Один из двух участников сверточной операции . (Другой актер — это часть входной матрицы.) Сверточный фильтр — это матрица того же ранга , что и входная матрица, но меньшей формы. Например, для входной матрицы размером 28x28 фильтром может быть любая двумерная матрица размером меньше 28x28.

При фотографических манипуляциях для всех ячеек сверточного фильтра обычно устанавливается постоянный набор единиц и нулей. В машинном обучении сверточные фильтры обычно заполняют случайными числами, а затем сеть обучает идеальные значения.

сверточный слой

#изображение

Слой глубокой нейронной сети , в котором сверточный фильтр проходит по входной матрице. Например, рассмотрим следующий сверточный фильтр 3x3:

Матрица 3x3 со следующими значениями: [[0,1,0], [1,0,1], [0,1,0]]

Следующая анимация показывает сверточный слой, состоящий из 9 сверточных операций с входной матрицей 5x5. Обратите внимание, что каждая сверточная операция работает с отдельным фрагментом входной матрицы размером 3x3. Полученная матрица 3x3 (справа) состоит из результатов 9 сверточных операций:

Анимация, показывающая две матрицы. Первая матрица - матрица 5x5: [[128,97,53,201,198], [35,22,25,200,195], [37,24,28,197,182], [33,28,92,195,179], [31,40,100,192,177]. Вторая матрица - матрица 3x3: [[181,303,618], [115,338,605], [169,351,560]]. Вторая матрица рассчитывается путем применения сверточного фильтра [[[0, 1, 0], [1, 0, 1], [0, 1, 0]] в разных подмножествах 3x3 матрицы 5x5.

сверточная нейронная сеть

#изображение

Нейронная сеть , в которой хотя бы один слой является сверточным . Типичная сверточная нейронная сеть состоит из некоторой комбинации следующих слоев:

Сверточные нейронные сети добились больших успехов в решении определенных задач, таких как распознавание изображений.

сверточная операция

#изображение

Следующая двухэтапная математическая операция:

  1. Поэлементное умножение сверточного фильтра и среза входной матрицы. (Срез входной матрицы имеет тот же ранг и размер, что и сверточный фильтр.)
  2. Суммирование всех значений в результирующей матрице продуктов.

Например, рассмотрим следующую входную матрицу 5x5:

Матрица 5x5: [[128,97,53,201,198], [35,22,25,200,195], [37,24,28,197,182], [33,28,92,195,179], [31,40,192,177]].

Теперь представьте себе следующий сверточный фильтр 2x2:

Матрица 2x2: [[1, 0], [0, 1]]

Каждая сверточная операция включает в себя один срез входной матрицы размером 2x2. Например, предположим, что мы используем срез 2x2 в верхнем левом углу входной матрицы. Итак, операция свертки на этом срезе выглядит следующим образом:

Применение сверточного фильтра [[1, 0], [0, 1]] к верхней левой части 2x2 входной матрицы, которая составляет [[128,97], [35,22]]. Снульный фильтр оставляет 128 и 22 нетронутыми, но Zeros 97 и 35. Следовательно, операция свертки дает значение 150 (128+22).

Сверточный слой состоит из серии сверточных операций, каждая из которых действует на отдельный фрагмент входной матрицы.

расходы

Синоним потери .

совместное обучение

Подход к полуконтролируемому обучению особенно полезен, когда выполняются все следующие условия:

Совместное обучение, по сути, усиливает независимые сигналы в более сильный сигнал. Например, рассмотрим модель классификации , которая классифицирует отдельные подержанные автомобили как «хорошие» или «плохие» . Один набор прогнозирующих функций может быть сосредоточен на совокупных характеристиках, таких как год, марка и модель автомобиля; другой набор прогнозирующих функций может быть сосредоточен на послужном списке предыдущего владельца и истории технического обслуживания автомобиля.

Основополагающая статья о совместном обучении — «Объединение размеченных и неразмеченных данных с совместным обучением» Блюма и Митчелла.

контрфактическая справедливость

#справедливость
Метрика справедливости , которая проверяет, дает ли классификатор тот же результат для одного человека, что и для другого человека, идентичного первому, за исключением одного или нескольких чувствительных атрибутов . Оценка классификатора на предмет контрфактической справедливости является одним из методов выявления потенциальных источников систематической ошибки в модели.

См. «Когда миры сталкиваются: интеграция различных контрфактических предположений в справедливость» для более подробного обсуждения контрфактической справедливости.

смещение охвата

#справедливость

См. смещение выбора .

крах цветения

#язык

Предложение или фраза с неоднозначным смыслом. Цветение сбоев представляет собой серьезную проблему в понимании естественного языка . Например, заголовок «Красная лента держит небоскреб» — это настоящий крах, потому что модель NLU может интерпретировать заголовок буквально или фигурально.

критик

#рл

Синоним Deep Q-Network .

перекрестная энтропия

Обобщение Log Loss для задач многоклассовой классификации . Перекрестная энтропия количественно определяет разницу между двумя распределениями вероятностей. См. также недоумение .

перекрестная проверка

Механизм оценки того, насколько хорошо модель будет обобщаться на новые данные, путем тестирования модели на одном или нескольких непересекающихся подмножествах данных, исключенных из обучающего набора .

Д

анализ данных

Получение понимания данных путем рассмотрения образцов, измерений и визуализации. Анализ данных может быть особенно полезен, когда набор данных получен впервые, прежде чем будет построена первая модель . Это также имеет решающее значение для понимания экспериментов и устранения проблем в системе.

увеличение данных

#изображение

Искусственно увеличивая диапазон и количество примеров обучения путем преобразования существующих примеров для создания дополнительных примеров. Например, предположим, что изображения являются одной из ваших функций , но ваш набор данных не содержит достаточного количества примеров изображения для изучения полезных ассоциаций. В идеале вы добавите достаточно маркированных изображений в свой набор данных, чтобы ваша модель была должным образом тренироваться. Если это невозможно, увеличение данных может вращаться, растягиваться и отражать каждое изображение, чтобы создать множество вариантов исходной картины, возможно, давая достаточно помеченных данных, чтобы обеспечить превосходное обучение.

DataFrame

#основы

Популярный DataType Pandas для представления наборов данных в памяти.

DataFrame аналогичен таблице или электронной таблице. Каждый столбец DataFrame имеет имя (заголовок), и каждая строка определяется уникальным номером.

Каждый столбец в DataFrame структурирован как 2D -массив, за исключением того, что каждому столбцу можно присвоить свой собственный тип данных.

См. Также Официальную страницу справочника Pandas.dataframe .

Параллелизм данных

Способ масштабирования обучения или вывода , который повторяет целую модель на несколько устройств, а затем передает подмножество входных данных каждому устройству. Параллелизм данных может обеспечить обучение и вывод по очень большим размерам пакетов ; Тем не менее, параллелизм данных требует, чтобы модель была достаточно мала, чтобы соответствовать всем устройствам.

Параллелизм данных обычно ускоряет тренировку и вывод.

См. Также модель параллелизма .

набор данных или набор данных

#основы

Коллекция необработанных данных, обычно (но не исключительно), организованные в одном из следующих форматов:

  • таблица
  • Файл в формате CSV (разделенные запятыми)

API набора данных (tf.data)

#Tensorflow

Высокий API Tensorflow Tensorflow для чтения данных и преобразования его в форму, в которой требуется алгоритм машинного обучения. Объект tf.data.Dataset представляет собой последовательность элементов, в которой каждый элемент содержит один или несколько тензоров . Объект tf.data.Iterator обеспечивает доступ к элементам Dataset .

Для получения подробной информации об API набора данных см. TF.Data: Постройте входные трубопроводы TensorFlow в руководстве программиста TensorFlow .

граница решения

Разделитель между классами , изученными моделью в бинарном классе или многоклассных задачах классификации . Например, на следующем изображении, представляющемся бинарной классификации, граница принятия решений является границей между классом оранжевого и синим классом:

Четкая граница между одним классом и другим.

Решение Лес

#df

Модель, созданная из нескольких деревьев решений . Решение леса делает прогноз, агрегируя прогнозы своих деревьев решений. Популярные виды решений леса включают в себя случайные леса и градиент, повышенные деревья .

Порог решения

Синоним порога классификации .

Древо решений

#df

Контролируемая учебная модель, состоящая из набора условий и листья организованных иерархически. Например, следующее приведено дерево решений:

Дерево решений, состоящее из четырех условий, организованных иерархически, что приводит к пяти листьям.

декодер

#язык

В целом, любая система ML, которая преобразуется из обработанного, плотного или внутреннего представления в более сырое, разреженное или внешнее представление.

Декодеры часто являются компонентом более крупной модели, где они часто сочетаются с кодером .

В задачах последовательности к последовательности декодер начинается с внутреннего состояния, генерируемого кодером для прогнозирования следующей последовательности.

Обратитесь к Transformer для определения декодера в архитектуре трансформатора.

глубокая модель

#основы

Нейронная сеть , содержащая более одного скрытого уровня .

Глубокая модель также называется глубокой нейронной сетью .

Сравните с широкой моделью .

Глубокая нейронная сеть

Синоним глубокой модели .

Глубокая Q-сеть (DQN)

#рл

В Q-обучении глубокая нейронная сеть , которая предсказывает Q-функции .

Критик является синонимом глубокой Q-сети.

демографический паритет

#справедливость

Метрика справедливости , которая удовлетворена, если результаты классификации модели не зависят от данного чувствительного атрибута .

Например, если как лиллипуты, так и бробдингнагианцы применяются в Университете Глюббдубдриба, демографический паритет достигается, если процент признанных лиллипутов такими же, как и процент брубдингнагианцев, независимо от того, является ли одна группа в среднем более квалифицированной, чем другая.

В отличие от уравновешенных шансов и равенства возможностей , что позволяет классификации приводит к агрегату, чтобы зависеть от чувствительных атрибутов, но не позволяют результатам классификации для определенных указанных меток истины земли зависеть от чувствительных атрибутов. См. «Атакующий дискриминацию с помощью умного машинного обучения» для визуализации, изучающей компромиссы при оптимизации для демографического паритета.

разоблачение

#язык

Общий подход к самоотверженному обучению, в котором:

  1. Шум искусственно добавляется в набор данных.
  2. Модель пытается удалить шум.

Обеспонцирование позволяет учиться на немеченых примерах . Оригинальный набор данных служит целевым или меткой и шумными данными в качестве ввода.

Некоторые маскированные языковые модели используют денообразование следующим образом:

  1. Шум искусственно добавляется к немеченному предложению, маскируя некоторые токены.
  2. Модель пытается предсказать оригинальные токены.

плотная особенность

#основы

Особенность , в которой большинство или все значения являются ненулевыми, обычно тензор значений с плавающей точкой. Например, следующий тензор из 10 элементов плотный, потому что 9 из его значений ненулевые:

8 3 7 5 2 4 0 4 9 6

Сравните с редкой функцией .

плотный слой

Синоним для полностью подключенного слоя .

глубина

#основы

Сумма следующего в нейронной сети :

Например, нейронная сеть с пятью скрытыми слоями и одним выходным слоем имеет глубину 6.

Обратите внимание, что входной слой не влияет на глубину.

глубинная отдельная сверточная нейронная сеть (SEPCNN)

#изображение

Архитектура сверточной нейронной сети, основанная на основе начала , но где модули основания заменяются глубинными отдельными свертками. Также известен как XCEPTE.

Глубиная отдельная свертка (также сокращена как отдельная свертка), факторы, основанные на стандартной трехмерной свертке в две отдельные операции свертки, которые более эффективны в вычислительности: во-первых, глубинная свертка, с глубиной 1 (n ✕ n ✕ 1), а затем, а затем и затем Во -вторых, точечная свертка с длиной и шириной 1 (1 ✕ 1 ✕ n).

Чтобы узнать больше, см. Xcept: глубокое обучение с глубинными разделяемыми сознаниями .

Полученная этикетка

Синоним прокси -лейбла .

устройство

#Tensorflow
#GoogleCloud

Перегруженный термин со следующими двумя возможными определениями:

  1. Категория аппаратного обеспечения, которая может запустить сеанс TensorFlow, включая процессоры, графические процессоры и TPU .
  2. При обучении модели ML по чипам ускорителя (графические процессоры или TPU), часть системы, которая фактически манипулирует тензорами и встраиванием . Устройство работает на чипах акселератора. Напротив, хост обычно работает на процессоре.

дифференциальная конфиденциальность

Подход анонимизации к конфиденциальности, который защищает личную информацию человека, которая может быть включена в учебный набор модели. Этот подход гарантирует, что модель мало что выводит о конкретном человеке. Дифференциальная конфиденциальность вводит шум во время обучения, чтобы скрыть отдельные точки данных.

Дифференциальная конфиденциальность также используется вне машинного обучения. Например, ученые данных иногда используют дифференциальную конфиденциальность для защиты индивидуальной конфиденциальности при вычислении статистики использования продукта для различной демографии.

сокращение измерений

Уменьшение количества измерений, используемых для представления конкретной функции в векторе признаков, обычно путем преобразования в вектор встраивания .

размеры

Перегруженный термин с каким -либо из следующих определений:

  • Количество уровней координат в тензоре . Например:

    • Скаляр имеет нулевые размеры; Например, ["Hello"] .
    • Вектор имеет одно измерение; Например, [3, 5, 7, 11] .
    • Матрица имеет два измерения; Например, [[2, 4, 18], [5, 7, 14]] .

    Вы можете однозначно указать конкретную ячейку в одномерном векторе с одной координатой; Вам нужно два координата, чтобы уникально указать конкретную ячейку в двухмерной матрице.

  • Количество записей в векторе функций .

  • Количество элементов в встраиваемом слое .

прямое подсказка

#язык
#генеративныйИИ

Синоним подсказки с нулевым выстрелом .

дискретная функция

#основы

Функция с конечным набором возможных значений. Например, функция, значения которых могут быть только животным , овощным или минералом , является дискретной (или категориальной) особенностью.

Сравните с непрерывной особенностью .

дискриминационная модель

Модель , которая предсказывает этикетки из набора из одной или нескольких функций . Более формально, дискриминационные модели определяют условную вероятность выхода, учитывая особенности и веса ; то есть:

p(output | features, weights)

Например, модель, которая предсказывает, является ли электронная почта спам от функций и весов, является дискриминационной моделью.

Подавляющее большинство контролируемых моделей обучения, включая модели классификации и регрессии, являются дискриминационными моделями.

Сравните с генеративной моделью .

дискриминатор

Система, которая определяет, являются ли примеры реальными или фальшивыми.

Альтернативно, подсистема в генеративной состязательной сети , которая определяет, являются ли примеры, созданные генератором реальными или фальшивыми.

несопоставимое воздействие

#справедливость

Решение о людях, которые не имеют различных подгрупп населения непропорционально. Обычно это относится к ситуациям, когда алгоритмический процесс принятия решений вредит или приносит пользу некоторым подгруппам больше, чем другие.

Например, предположим, что алгоритм, который определяет право лилипутиана на миниатюрную кредит, с большей вероятностью классифицирует их как «неприемлемые», если их почтовый адрес содержит определенный почтовый код. Если лиллипуты с большими эндиунами с большей вероятностью будут иметь почтовые адреса с этим почтовым кодом, чем лилипуты с маленькими эндианскими, то этот алгоритм может привести к несопоставимому воздействию.

В отличие от разрозненного лечения , которое фокусируется на различиях, которые возникают, когда характеристики подгруппы являются явными вводами в алгоритмический процесс принятия решений.

несопоставимое обращение

#справедливость

Факторинг чувствительных атрибутов субъектов в алгоритмический процесс принятия решений, так что с разными подгруппами людей обращаются по-разному.

Например, рассмотрим алгоритм, который определяет право на получение лилипутов на миниатюрную кредит на основе данных, которые они предоставляют в их заявке на кредит. Если алгоритм использует лилипутистскую принадлежность как крупного или маленького, в качестве входного ввода, он принимает разрозненное лечение вдоль этого измерения.

В отличие от разнородного воздействия , которое фокусируется на различиях в социальном воздействии алгоритмических решений на подгруппы, независимо от того, являются ли эти подгруппы входными данными для модели.

дистилляция

#генеративныйИИ

Процесс уменьшения размера одной модели (известной как учитель ) в меньшую модель (известную как ученик ), которая эмулирует прогнозы оригинальной модели максимально верно. Дистилляция полезна, потому что меньшая модель имеет два ключевых преимущества по сравнению с более крупной моделью (учитель):

  • Более быстрое время вывода
  • Униженное использование памяти и энергии

Тем не менее, прогнозы ученика, как правило, не так хороши, как прогнозы учителя.

Дистилляция обучает модель студента, чтобы минимизировать функцию потерь на основе разницы между результатами прогнозов моделей ученика и учителя.

Сравните и сопоставьте дистилляцию со следующими терминами:

Разделительная кластеризация

#clustering

См. иерархическую кластеризацию .

понижение частоты дискретизации

#изображение

Перегруженный термин, который может означать любое из следующего:

  • Сокращение объема информации в функции , чтобы более эффективно обучить модель. Например, перед обучением модели распознавания изображений в формате с более низким разрешением в формате с низким разрешением в формате с более низким разрешением.
  • Обучение по непропорционально низкому проценту перепредставленных примеров класса для улучшения модельного обучения по недопредставленным классам. Например, в классе-имбалансированном наборе данных модели, как правило, много узнают о классе большинства и недостаточно о классе меньшинства . Отставка помогает сбалансировать объем обучения для большинства и уроков меньшинств.

Дкн

#рл

Аббревиатура для глубокой Q-сети .

регуляризация отсева

Форма регуляризации , полезная в обучении нейронных сетей . Регуляризация отсева удаляет случайный выбор фиксированного числа единиц в сетевом уровне для одного шага градиента. Чем больше подразделений выпало, тем сильнее регуляризация. Это аналогично обучению сети для эмуляции экспоненциально большого ансамбля из небольших сетей. Для получения полной информации см. Вывод: простой способ предотвратить переживание нейронных сетей .

динамичный

#основы

Что -то делалось часто или непрерывно. Термины динамики и онлайн являются синонимами в машинном обучении. Ниже приведены распространенные использование динамического и онлайн в машинном обучении:

  • Динамическая модель (или онлайн -модель ) - это модель, которая часто или непрерывно перепровещается.
  • Динамическое обучение (или онлайн -обучение ) - это процесс обучения часто или непрерывно.
  • Динамический вывод (или онлайн -вывод ) - это процесс создания прогнозов по спросу.

динамическая модель

#основы

Модель , которая часто (может быть, даже непрерывно) переподготовлена. Динамическая модель - это «учащийся на протяжении всей жизни», который постоянно адаптируется к развивающимся данным. Динамическая модель также известна как онлайн -модель .

Контраст со статической моделью .

Э

Жесткое исполнение

#Tensorflow

Среда программирования тензорфлова, в которой операции работают немедленно. Напротив, операции, вызванные выполнением графика, не работают, пока они не будут явно оценены. Жесткое выполнение является императивным интерфейсом , очень похожим на код на большинстве языков программирования. Стремительные программы выполнения, как правило, гораздо проще отлаживать, чем программы выполнения графиков.

ранняя остановка

#основы

Метод регуляризации , который включает в себя окончание тренировок до того, как обучение потерь заканчивается, уменьшается. В ранней остановке вы намеренно прекращаете обучение модели, когда потеря набора данных валидации начинает увеличиваться; То есть, когда производительность обобщения ухудшается.

Расстояние Земли (EMD)

Мера относительного сходства между двумя документами. Чем нижняя дистанция грунта Земли, тем более похожи документы.

Редактировать расстояние

#язык

Измерение того, насколько похожи две текстовые строки друг к другу. В машинном обучении редактирование расстояние полезно, потому что оно просто и легко вычислить, и эффективный способ сравнения двух строк, которые, как известно, похожи, или находить строки, похожие на данную строку.

Есть несколько определений расстояния редактирования, каждое из которых использует различные строковые операции. Например, расстояние Levenshtein рассматривает наименьшее количество операций удаления, вставки и замены.

Например, расстояние Левенштейна между словами «Сердце» и «Дартс» составляет 3, потому что следующие 3 редактора являются наименьшими изменениями, чтобы превратить одно слово в другое:

  1. Сердце → DEART (заменитель «H» на «D»)
  2. DEART → DART (DELETE "E")
  3. Дарт → Дартс (вставка "s")

Einsum нотация

Эффективная нотация для описания того, как должны быть объединены два тензора . Тензоры объединяются путем умножения элементов одного тензора на элементы другого тензора, а затем суммируя продукты. Einsum natation использует символы для идентификации осей каждого тензора, и те же самые символы переставляются, чтобы указать форму нового полученного тензора.

Numpy обеспечивает общую реализацию Einsum.

внедрение слоя

#язык
#основы

Специальный скрытый слой , который тренируется на высокомерной категориальной функции, чтобы постепенно изучать вектор более низкого измерения. Встроенный слой позволяет нейронной сети тренироваться гораздо более эффективно, чем тренироваться только по высокомерной категориальной особенности.

Например, Земля в настоящее время поддерживает около 73 000 видов деревьев. Предположим, что виды деревьев являются особенностью в вашей модели, поэтому входной слой вашей модели включает в себя одножелачный вектор 73 000 элементов. Например, возможно, baobab был бы представлен как -то вроде этого:

Массив из 73 000 элементов. Первые 6 232 элемента содержит значение 0. Следующий элемент содержит значение 1. Окончательные 66 767 элементов содержит значение нуля.

Массив 73 000 элементов очень длинный. Если вы не добавите в модель встраивающий слой, обучение будет очень много времени из -за умножения 72 999 нулей. Возможно, вы выбираете встроенный слой, чтобы состоять из 12 измерений. Следовательно, встраивающий слой постепенно изучает новый вектор встраивания для каждого вида деревьев.

В определенных ситуациях хешинг является разумной альтернативой внедрению слоя.

внедрение пространства

#язык

Сопоставляется d-мерное векторное пространство, являющееся частью векторного пространства более высокой размерности. В идеале пространство встраивания содержит структуру, которая дает значимые математические результаты; например, в идеальном пространстве вложений сложение и вычитание вложений могут решить задачи по аналогии слов.

Скалярное произведение двух вложений является мерой их сходства.

вектор внедрения

#язык

Грубо говоря, массив чисел с плавающей запятой, взятый из любого скрытого слоя и описывающий входные данные этого скрытого слоя. Часто вектор внедрения представляет собой массив чисел с плавающей запятой, обученный на слое внедрения. Например, предположим, что слой внедрения должен изучить вектор внедрения для каждого из 73 000 видов деревьев на Земле. Возможно, следующий массив является вектором внедрения дерева баобаба:

Массив из 12 элементов, каждый из которых удерживает число с плавающей точкой от 0,0 до 1,0.

Вектор внедрения — это не набор случайных чисел. Слой внедрения определяет эти значения посредством обучения, аналогично тому, как нейронная сеть изучает другие веса во время обучения. Каждый элемент массива представляет собой рейтинг по некоторой характеристике породы дерева. Какой элемент представляет характеристику какой породы деревьев? Людям это очень трудно определить.

Математически примечательная часть вектора внедрения заключается в том, что аналогичные элементы имеют одинаковые наборы чисел с плавающей запятой. Например, похожие породы деревьев имеют более похожий набор чисел с плавающей запятой, чем разные породы деревьев. Секвойи и секвойи являются родственными породами деревьев, поэтому у них будет более похожий набор чисел с плавающей запятой, чем у секвой и кокосовых пальм. Числа в векторе внедрения будут меняться каждый раз, когда вы переобучаете модель, даже если вы переобучаете модель с идентичными входными данными.

минимизация эмпирического риска (ERM)

Выбор функции, минимизирующей потери на обучающем наборе. Контраст с минимизацией структурного риска .

кодер

#язык

В общем, любая система машинного обучения, которая преобразует необработанное, разреженное или внешнее представление в более обработанное, более плотное или более внутреннее представление.

Кодеры часто являются компонентом более крупной модели, где они часто работают в паре с декодером . Некоторые Трансформеры объединяют кодеры с декодерами, хотя другие Трансформеры используют только кодер или только декодер.

Некоторые системы используют выходные данные кодировщика в качестве входных данных для сети классификации или регрессии.

В задачах «последовательность-последовательность» кодер принимает входную последовательность и возвращает внутреннее состояние (вектор). Затем декодер использует это внутреннее состояние для прогнозирования следующей последовательности.

Обратитесь к Transformer для определения кодера в архитектуре Transformer.

ансамбль

Коллекция моделей , обученных независимо, чьи прогнозы усредняются или агрегируются. Во многих случаях ансамбль дает лучшие прогнозы, чем одна модель. Например, случайный лес — это ансамбль, построенный из нескольких деревьев решений . Обратите внимание, что не все леса решений являются ансамблями.

энтропия

#df

В теории информации — описание того, насколько непредсказуемо распределение вероятностей. Альтернативно, энтропия также определяется как количество информации, содержащейся в каждом примере . Распределение имеет максимально возможную энтропию, когда все значения случайной величины равновероятны.

Энтропия набора с двумя возможными значениями «0» и «1» (например, метки в задаче бинарной классификации ) имеет следующую формулу:

H = -p log p - q log q = -p log p - (1-p) * log (1-p)

где:

  • H — энтропия.
  • p — доля примеров «1».
  • q — доля примеров «0». Обратите внимание, что q = (1 - p)
  • log обычно равен log 2 . В данном случае единицей энтропии является бит.

Например, предположим следующее:

  • 100 примеров содержат значение «1»
  • 300 примеров содержат значение «0»

Следовательно, значение энтропии равно:

  • p = 0,25
  • Q = 0,75
  • ч = (-0,25) log 2 (0,25) - (0,75) log 2 (0,75) = 0,81
  • бита на пример

Идеально сбалансированный набор (например, 200 «0» и 200 «1») будет иметь энтропию 1,0 бита на каждый пример. Когда набор становится более несбалансированным , его энтропия приближается к 0,0.

В деревьях решений энтропия помогает сформулировать прирост информации , чтобы помочь разделителю выбрать условия во время роста дерева решений классификации.

Сравните энтропию с:

Энтропию часто называют энтропией Шеннона.

среда

#рл

В обучении с подкреплением — мир, в котором находится агент и который позволяет агенту наблюдать за состоянием этого мира. Например, представленный мир может быть игрой, например шахматами, или физическим миром, например лабиринтом. Когда агент применяет действие к среде, среда переходит между состояниями.

эпизод

#рл

При обучении с подкреплением — каждая из повторяющихся попыток агента изучить окружающую среду .

эпоха

#основы

Полный проход обучения по всему обучающему набору , при котором каждый пример обрабатывается один раз.

Эпоха представляет собой итерации обучения N / партии , где N - общее количество примеров.

Например, предположим следующее:

  • Набор данных состоит из 1000 примеров.
  • Размер партии — 50 экземпляров.

Следовательно, для одной эпохи требуется 20 итераций:

1 epoch = (N/batch size) = (1,000 / 50) = 20 iterations

жадная политика Эпсилон

#рл

В обучении с подкреплением - политика , которая следует либо случайной политике с эпсилон-вероятностью, либо жадной политике в противном случае. Например, если эпсилон равен 0,9, то политика следует случайной политике в 90% случаев и жадной политике в 10% случаев.

В последовательных эпизодах алгоритм уменьшает значение эпсилона, чтобы перейти от следования случайной политике к жадной политике. Изменяя политику, агент сначала случайным образом исследует окружающую среду, а затем жадно использует результаты случайного исследования.

равенство возможностей

#справедливость
Метрика справедливости , которая проверяет, прогнозирует ли классификатор для предпочтительной метки (которая дает преимущество или выгоду человеку) и данного атрибута одинаково хорошо для всех значений этого атрибута. Другими словами, равенство возможностей измеряет, имеют ли люди, которые должны претендовать на возможность, сделать это с одинаковой вероятностью, независимо от их принадлежности к группе.

Например, предположим, что университет Глаббдубдриб принимает как лилипутов, так и бробдингнегов на строгую математическую программу. Средние школы лилипутов предлагают обширную программу занятий по математике, и подавляющее большинство учащихся имеют право на университетскую программу. В средних школах Бробдингнеджана вообще не проводятся занятия по математике, и в результате гораздо меньше учеников имеют соответствующую квалификацию. Равенство возможностей соблюдается для предпочтительного ярлыка «допущенный» в отношении национальности (лилипут или бробдингнаг), если квалифицированные студенты имеют одинаковую вероятность быть принятыми независимо от того, являются ли они лилипутами или бробдингнегами.

Например, предположим, что 100 лилипутов и 100 бробдингнагцев подают заявку в университет Глаббдубдриб, и решения о приеме принимаются следующим образом:

Таблица 1. Кандидаты-лилипуты (90% соответствуют требованиям)

Квалифицированный Неквалифицированный
Допущенный 45 3
Отклоненный 45 7
Общий 90 10
Процент квалифицированных студентов признался: 45/90 = 50%
Процент неквалифицированных студентов отклонил: 7/10 = 70%
Общий процент лиллипутских студентов признался: (45+3)/100 = 48%

Таблица 2. Кандидаты из Бробдингнага (10% соответствуют требованиям):

Квалифицированный Неквалифицированный
Допущенный 5 9
Отклоненный 5 81
Общий 10 90
Процент квалифицированных студентов признался: 5/10 = 50%
Процент неквалифицированных студентов отклонил: 81/90 = 90%
Общий процент студентов бробдингнагиана признался: (5+9)/100 = 14%

Предыдущие примеры удовлетворяют равенству возможностей для приема квалифицированных студентов, поскольку квалифицированные лилипуты и бробдингнаги имеют 50% шансов на поступление.

См. «Равенство возможностей в контролируемом обучении» для более подробного обсуждения равенства возможностей. Также см. «Борьба с дискриминацией с помощью более умного машинного обучения», где представлена ​​визуализация компромиссов при оптимизации для обеспечения равенства возможностей.

уравненные шансы

#справедливость
Метрика справедливости , которая проверяет, прогнозирует ли классификатор для какой-либо конкретной метки и атрибута одинаково хорошо эту метку для всех значений этого атрибута.

Например, предположим, что университет Глаббдубдриб принимает как лилипутов, так и бробдингнегов на строгую математическую программу. Средние школы лилипутов предлагают обширную программу занятий по математике, и подавляющее большинство учащихся имеют право на университетскую программу. В средних школах Бробдингнеджана вообще не проводятся занятия по математике, и в результате гораздо меньше учеников имеют соответствующую квалификацию. Уравненные шансы удовлетворяются при условии, что независимо от того, является ли заявитель лилипутом или бробдингнежцем, если он соответствует требованиям, он имеет одинаковую вероятность быть допущенным к программе, а если он не соответствует требованиям, он с одинаковой вероятностью будет отклонен. .

Допустим, 100 лилипутов и 100 бробдингнажинов применяются в Университете Глюббдубдриба, а решения о приеме принимаются следующим образом:

Таблица 3. Лиллипутские кандидаты (90% квалифицированы)

Квалифицированный Неквалифицированный
Допущенный 45 2
Отклоненный 45 8
Общий 90 10
Процент квалифицированных студентов признался: 45/90 = 50%
Процент неквалифицированных студентов отклонил: 8/10 = 80%
Общий процент студентов лиллипутов признал: (45+2)/100 = 47%

Таблица 4. Бробдингнагианские кандидаты (10% квалифицированы):

Квалифицированный Неквалифицированный
Допущенный 5 18
Отклоненный 5 72
Общий 10 90
Процент квалифицированных студентов признался: 5/10 = 50%
Процент неквалифицированных студентов отклонил: 72/90 = 80%
Общий процент студентов бробдингнагиана признался: (5+18)/100 = 23%

Уравновешенные шансы удовлетворяются, потому что квалифицированные лилипутские и бробдингианские студенты имеют 50% вероятность того, что у лиллипутов и бробдингнагиана есть неквалифицированные лилипутианские и бробдингнагианские шансы на то, чтобы быть отклоненным.

Выравниваемые шансы формально определяются в «равенстве возможностей в контролируемом обучении» следующим образом: «Предсказатель ŷ удовлетворяет выравнивающим шансам в отношении защищенного атрибута A и результата y, если ŷ и A являются независимыми, условными на Y.»

Оценщик

#Tensorflow

Устаревший API Tensorflow. Используйте tf.keras вместо оценок.

пример

#основы

Значения одного ряда функций и, возможно, этикетки . Примеры в контролируемом обучении делятся на две общие категории:

  • Намеченный пример состоит из одной или нескольких функций и метки. Маркированные примеры используются во время обучения.
  • Немаркированный пример состоит из одного или нескольких объектов, но без метки. Во время вывода используются немаркированные примеры.

Например, предположим, что вы обучаете модель для определения влияния погодных условий на результаты тестов учащихся. Вот три помеченных примера:

Функции Этикетка
Температура Влажность Давление Оценка теста
15 47 998 Хороший
19 34 1020 Отличный
18 92 1012 Бедный

Вот три немаркированных примера:

Температура Влажность Давление
12 62 1014
21 47 1017
19 41 1021

Строка набора данных обычно является необработанным источником примера. То есть пример обычно состоит из подмножества столбцов набора данных. Кроме того, объекты в примере также могут включать в себя синтетические объекты , такие как перекрестные объекты .

повтор опыта

#рл

В обучении с подкреплением — метод DQN , используемый для уменьшения временных корреляций в обучающих данных. Агент сохраняет переходы состояний в буфере воспроизведения , а затем выбирает переходы из буфера воспроизведения для создания обучающих данных.

предвзятость экспериментатора

#справедливость

См. предвзятость подтверждения .

проблема взрывающегося градиента

#seq

Тенденция градиентов в глубоких нейронных сетях (особенно в рекуррентных нейронных сетях ) становиться удивительно крутыми (высокими). Крутые градиенты часто вызывают очень большие обновления весов каждого узла в глубокой нейронной сети.

Модели, страдающие от проблемы взрывного градиента, становится трудно или невозможно обучать. Градиентное отсечение может решить эту проблему.

Сравните с проблемой исчезающего градиента .

Ф

Ф 1

«Сводная» метрика двоичной классификации , которая зависит как от точности , так и от полноты . Вот формула:

$$F{_1} = \frac{\text{2 * precision * recall}} {\text{precision + recall}}$$

Например, учитывая следующее:

  • точность = 0,6
  • отзыв = 0,4
$$F{_1} = \frac{\text{2 * 0.6 * 0.4}} {\text{0.6 + 0.4}} = 0.48$$

Когда точность и полнота достаточно близки (как в предыдущем примере), F 1 близок к их среднему значению. Когда точность и полнота существенно различаются, F 1 ближе к нижнему значению. Например:

  • точность = 0,9
  • отзыв = 0,1
$$F{_1} = \frac{\text{2 * 0.9 * 0.1}} {\text{0.9 + 0.1}} = 0.18$$

ограничение справедливости

#справедливость
Применение ограничения к алгоритму для обеспечения соблюдения одного или нескольких определений справедливости. Примеры ограничений справедливости включают в себя:

показатель справедливости

#справедливость

Математическое определение «справедливости», которое измеримо. Некоторые часто используемые показатели справедливости включают:

Многие показатели справедливости являются взаимоисключающими; См. Несовместимость показателей справедливости .

ложный отрицательный (FN)

#основы

Пример, в котором модель ошибочно предсказывает отрицательный класс . Например, модель предсказывает, что конкретное сообщение электронной почты не является спамом (отрицательный класс), но это сообщение электронной почты на самом деле является спамом .

ложная отрицательная скорость

Доля фактических положительных примеров, для которых модель ошибочно предсказывала отрицательный класс. Следующая формула вычисляет ложную отрицательную скорость:

$$\text{false negative rate} = \frac{\text{false negatives}}{\text{false negatives} + \text{true positives}}$$

ложноположительный результат (FP)

#основы

Пример, в котором модель ошибочно предсказывает положительный класс . Например, модель предсказывает, что конкретным сообщением электронной почты является спам (положительный класс), но это сообщение электронной почты на самом деле не спам .

ложная положительная скорость (FPR)

#основы

Доля фактических отрицательных примеров, для которых модель ошибочно предсказывала положительный класс. Следующая формула вычисляет ложную положительную скорость:

$$\text{false positive rate} = \frac{\text{false positives}}{\text{false positives} + \text{true negatives}}$$

Ложная положительная скорость-это ось X в кривой ROC .

особенность

#основы

Входная переменная для модели машинного обучения. Пример состоит из одной или нескольких функций. Например, предположим, что вы обучаете модель для определения влияния погодных условий на результаты тестов учащихся. В следующей таблице показаны три примера, каждый из которых содержит три функции и одну метку:

Функции Этикетка
Температура Влажность Давление Оценка теста
15 47 998 92
19 34 1020 84
18 92 1012 87

Сравните с этикеткой .

функция креста

#основы

Синтетическая особенность , сформированная «пересечение» категориальных или ведровых функций.

Например, рассмотрим модель «прогнозирование настроения», которая представляет температуру в одном из следующих четырех ведра:

  • freezing
  • chilly
  • temperate
  • warm

И представляет скорость ветра в одном из следующих трех ведер:

  • still
  • light
  • windy

Без скрещиваний функций линейная модель тренируется независимо на каждом из предыдущих семи различных ведер. Таким образом, модель тренируется, например, freezing независимо от обучения, например, windy .

В качестве альтернативы, вы можете создать характерный крест температуры и скорости ветра. Эта синтетическая функция будет иметь следующие 12 возможных значений:

  • freezing-still
  • freezing-light
  • freezing-windy
  • chilly-still
  • chilly-light
  • chilly-windy
  • temperate-still
  • temperate-light
  • temperate-windy
  • warm-still
  • warm-light
  • warm-windy

Благодаря скрещиваниям функций модель может изучить различия в настроении между днем freezing-windy и днем freezing-still .

Если вы создаете синтетическую функцию из двух функций, у каждого из которых есть много разных ведер, полученный в результате крест функции будет огромное количество возможных комбинаций. For example, if one feature has 1,000 buckets and the other feature has 2,000 buckets, the resulting feature cross has 2,000,000 buckets.

Formally, a cross is a Cartesian product .

Feature crosses are mostly used with linear models and are rarely used with neural networks.

feature engineering

#основы
#TensorFlow

A process that involves the following steps:

  1. Determining which features might be useful in training a model.
  2. Converting raw data from the dataset into efficient versions of those features.

For example, you might determine that temperature might be a useful feature. Then, you might experiment with bucketing to optimize what the model can learn from different temperature ranges.

Feature engineering is sometimes called feature extraction .

извлечение признаков

Overloaded term having either of the following definitions:

feature importances

#df

Synonym for variable importances .

набор функций

#основы

The group of features your machine learning model trains on. For example, postal code, property size, and property condition might comprise a simple feature set for a model that predicts housing prices.

feature spec

#TensorFlow

Describes the information required to extract features data from the tf.Example protocol buffer. Because the tf.Example protocol buffer is just a container for data, you must specify the following:

  • the data to extract (that is, the keys for the features)
  • the data type (for example, float or int)
  • The length (fixed or variable)

feature vector

#основы

The array of feature values comprising an example . The feature vector is input during training and during inference . For example, the feature vector for a model with two discrete features might be:

[0.92, 0.56]

Четыре слоя: входной слой, два скрытых слоя и один выходной слой. The input layer contains two nodes, one containing the value           0.92 and the other containing the value 0.56.

Each example supplies different values for the feature vector, so the feature vector for the next example could be something like:

[0.73, 0.49]

Feature engineering determines how to represent features in the feature vector. For example, a binary categorical feature with five possible values might be represented with one-hot encoding . In this case, the portion of the feature vector for a particular example would consist of four zeroes and a single 1.0 in the third position, as follows:

[0.0, 0.0, 1.0, 0.0, 0.0]

As another example, suppose your model consists of three features:

  • a binary categorical feature with five possible values represented with one-hot encoding; for example: [0.0, 1.0, 0.0, 0.0, 0.0]
  • another binary categorical feature with three possible values represented with one-hot encoding; for example: [0.0, 0.0, 1.0]
  • a floating-point feature; for example: 8.3 .

In this case, the feature vector for each example would be represented by nine values. Given the example values in the preceding list, the feature vector would be:

0.0
1.0
0.0
0.0
0.0
0.0
0.0
1.0
8.3

федеративное обучение

A distributed machine learning approach that trains machine learning models using decentralized examples residing on devices such as smartphones. In federated learning, a subset of devices downloads the current model from a central coordinating server. The devices use the examples stored on the devices to make improvements to the model. The devices then upload the model improvements (but not the training examples) to the coordinating server, where they are aggregated with other updates to yield an improved global model. After the aggregation, the model updates computed by devices are no longer needed, and can be discarded.

Since the training examples are never uploaded, federated learning follows the privacy principles of focused data collection and data minimization.

For more information about federated learning, see this tutorial .

Обратная связь

#основы

In machine learning, a situation in which a model's predictions influence the training data for the same model or another model. For example, a model that recommends movies will influence the movies that people see, which will then influence subsequent movie recommendation models.

feedforward neural network (FFN)

A neural network without cyclic or recursive connections. For example, traditional deep neural networks are feedforward neural networks. Contrast with recurrent neural networks , which are cyclic.

few-shot learning

A machine learning approach, often used for object classification, designed to train effective classifiers from only a small number of training examples.

See also one-shot learning and zero-shot learning .

подсказка из нескольких кадров

#язык
#генеративныйИИ

A prompt that contains more than one (a "few") example demonstrating how the large language model should respond. For example, the following lengthy prompt contains two examples showing a large language model how to answer a query.

Части одной подсказки Примечания
Какая официальная валюта указанной страны? Вопрос, на который вы хотите получить ответ от LLM.
France: EUR One example.
United Kingdom: GBP Другой пример.
Индия: Фактический запрос.

Few-shot prompting generally produces more desirable results than zero-shot prompting and one-shot prompting . However, few-shot prompting requires a lengthier prompt.

Few-shot prompting is a form of few-shot learning applied to prompt-based learning .

скрипка

#язык

A Python-first configuration library that sets the values of functions and classes without invasive code or infrastructure. In the case of Pax —and other ML codebases—these functions and classes represent models and training hyperparameters .

Fiddle assumes that machine learning codebases are typically divided into:

  • Library code, which defines the layers and optimizers.
  • Dataset "glue" code, which calls the libraries and wires everything together.

Fiddle captures the call structure of the glue code in an unevaluated and mutable form.

тонкая настройка

#язык
#изображение
#генеративныйИИ

A second, task-specific training pass performed on a pre-trained model to refine its parameters for a specific use case. For example, the full training sequence for some large language models is as follows:

  1. Pre-training: Train a large language model on a vast general dataset, such as all the English language Wikipedia pages.
  2. Fine-tuning: Train the pre-trained model to perform a specific task, such as responding to medical queries. Fine-tuning typically involves hundreds or thousands of examples focused on the specific task.

As another example, the full training sequence for a large image model is as follows:

  1. Pre-training: Train a large image model on a vast general image dataset, such as all the images in Wikimedia commons.
  2. Fine-tuning: Train the pre-trained model to perform a specific task, such as generating images of orcas.

Fine-tuning can entail any combination of the following strategies:

  • Modifying all of the pre-trained model's existing parameters . This is sometimes called full fine-tuning .
  • Modifying only some of the pre-trained model's existing parameters (typically, the layers closest to the output layer ), while keeping other existing parameters unchanged (typically, the layers closest to the input layer ). See parameter-efficient tuning .
  • Adding more layers, typically on top of the existing layers closest to the output layer.

Fine-tuning is a form of transfer learning . As such, fine-tuning might use a different loss function or a different model type than those used to train the pre-trained model. For example, you could fine-tune a pre-trained large image model to produce a regression model that returns the number of birds in an input image.

Compare and contrast fine-tuning with the following terms:

Лен

#язык

A high-performance open-source library for deep learning built on top of JAX . Flax provides functions for training neural networks , as well as methods for evaluating their performance.

Flaxformer

#язык

An open-source Transformer library , built on Flax , designed primarily for natural language processing and multimodal research.

forget gate

#seq

The portion of a Long Short-Term Memory cell that regulates the flow of information through the cell. Forget gates maintain context by deciding which information to discard from the cell state.

full softmax

Synonym for softmax .

Contrast with candidate sampling .

fully connected layer

A hidden layer in which each node is connected to every node in the subsequent hidden layer.

A fully connected layer is also known as a dense layer .

г

ГАН

Abbreviation for generative adversarial network .

обобщение

#основы

A model's ability to make correct predictions on new, previously unseen data. A model that can generalize is the opposite of a model that is overfitting .

generalization curve

#основы

A plot of both training loss and validation loss as a function of the number of iterations .

A generalization curve can help you detect possible overfitting . For example, the following generalization curve suggests overfitting because validation loss ultimately becomes significantly higher than training loss.

A Cartesian graph in which the y-axis is labeled 'loss' and the x-axis           is labeled 'iterations'. Появляются два сюжета. One plots shows the           training loss and the other shows the validation loss. The two plots start off similarly, but the training loss eventually           dips far lower than the validation loss.

generalized linear model

A generalization of least squares regression models, which are based on Gaussian noise , to other types of models based on other types of noise, such as Poisson noise or categorical noise. Examples of generalized linear models include:

The parameters of a generalized linear model can be found through convex optimization .

Generalized linear models exhibit the following properties:

  • The average prediction of the optimal least squares regression model is equal to the average label on the training data.
  • The average probability predicted by the optimal logistic regression model is equal to the average label on the training data.

The power of a generalized linear model is limited by its features. Unlike a deep model, a generalized linear model cannot "learn new features."

generative adversarial network (GAN)

A system to create new data in which a generator creates data and a discriminator determines whether that created data is valid or invalid.

генеративный ИИ

#язык
#изображение
#генеративныйИИ

An emerging transformative field with no formal definition. That said, most experts agree that generative AI models can create ("generate") content that is all of the following:

  • сложный
  • последовательный
  • оригинальный

For example, a generative AI model can create sophisticated essays or images.

Some earlier technologies, including LSTMs and RNNs , can also generate original and coherent content. Some experts view these earlier technologies as generative AI, while others feel that true generative AI requires more complex output than those earlier technologies can produce.

Contrast with predictive ML .

generative model

Practically speaking, a model that does either of the following:

  • Creates (generates) new examples from the training dataset. For example, a generative model could create poetry after training on a dataset of poems. The generator part of a generative adversarial network falls into this category.
  • Determines the probability that a new example comes from the training set, or was created from the same mechanism that created the training set. For example, after training on a dataset consisting of English sentences, a generative model could determine the probability that new input is a valid English sentence.

A generative model can theoretically discern the distribution of examples or particular features in a dataset. То есть:

p(examples)

Unsupervised learning models are generative.

Contrast with discriminative models .

генератор

The subsystem within a generative adversarial network that creates new examples .

Contrast with discriminative model .

gini impurity

#df

A metric similar to entropy . Splitters use values derived from either gini impurity or entropy to compose conditions for classification decision trees . Information gain is derived from entropy. There is no universally accepted equivalent term for the metric derived from gini impurity; however, this unnamed metric is just as important as information gain.

Gini impurity is also called gini index , or simply gini .

GPT (Generative Pre-trained Transformer)

#язык

A family of Transformer -based large language models developed by OpenAI .

GPT variants can apply to multiple modalities , including:

  • image generation (for example, ImageGPT)
  • text-to-image generation (for example, DALL-E ).

градиент

The vector of partial derivatives with respect to all of the independent variables. In machine learning, the gradient is the vector of partial derivatives of the model function. The gradient points in the direction of steepest ascent.

gradient boosted (decision) trees (GBT)

#df

A type of decision forest in which:

повышение градиента

#df

Алгоритм обучения, в котором слабые модели обучаются для итеративного улучшения качества (уменьшения потерь) сильной модели. Например, слабая модель может представлять собой линейную модель или модель небольшого дерева решений. Сильная модель становится суммой всех ранее обученных слабых моделей.

В простейшей форме повышения градиента на каждой итерации слабая модель обучается прогнозированию градиента потерь сильной модели. Затем выходные данные сильной модели обновляются путем вычитания прогнозируемого градиента, аналогично градиентному спуску .

$$F_{0} = 0$$$$F_{i+1} = F_i - \xi f_i $$

где:

  • $F_{0}$ is the starting strong model.
  • $F_{i+1}$ is the next strong model.
  • $F_{i}$ is the current strong model.
  • $\xi$ is a value between 0.0 and 1.0 called shrinkage , which is analogous to the learning rate in gradient descent.
  • $f_{i}$ is the weak model trained to predict the loss gradient of $F_{i}$.

Современные варианты повышения градиента также включают в свои вычисления вторую производную (гессиан) потерь.

Деревья решений обычно используются в качестве слабых моделей при повышении градиента. См. деревья решений (решений) с градиентным усилением .

градиентная обрезка

#seq

Часто используемый механизм для смягчения проблемы взрывающегося градиента путем искусственного ограничения (обрезания) максимального значения градиентов при использовании градиентного спуска для обучения модели.

градиентный спуск

#основы

Математический метод минимизации потерь . Градиентный спуск итеративно корректирует веса и смещения , постепенно находя наилучшую комбинацию для минимизации потерь.

Градиентный спуск старше — намного старше — чем машинное обучение.

график

#TensorFlow

В TensorFlow — спецификация вычислений. Узлы графа представляют операции. Ребра являются направленными и представляют собой передачу результата операции ( Tensor ) в качестве операнда в другую операцию. Используйте TensorBoard для визуализации графика.

выполнение графа

#TensorFlow

Среда программирования TensorFlow, в которой программа сначала создает граф , а затем выполняет весь или часть этого графа. Выполнение графа — это режим выполнения по умолчанию в TensorFlow 1.x.

Сравните с нетерпеливым исполнением .

жадная политика

#рл

В обучении с подкреплением — политика , которая всегда выбирает действие с наибольшей ожидаемой отдачей .

основная истина

#основы

Реальность.

То, что произошло на самом деле.

Например, рассмотрим модель бинарной классификации , которая предсказывает, окончит ли студент первого курса университета обучение в течение шести лет. Основная истина для этой модели заключается в том, действительно ли этот студент окончил обучение в течение шести лет.

предвзятость групповой атрибуции

#справедливость

Предполагается, что то, что верно для отдельного человека, верно и для всех членов этой группы. Эффект предвзятости групповой атрибуции может усугубиться, если для сбора данных используется удобная выборка . В нерепрезентативной выборке могут быть сделаны атрибуции, не отражающие реальности.

См. также смещение из-за однородности чужой группы и смещение внутри группы .

ЧАС

галлюцинация

#язык

Производство кажущихся правдоподобными, но на самом деле неверных результатов с помощью генеративной модели ИИ , которая якобы делает утверждение о реальном мире. Например, генеративная модель искусственного интеллекта, утверждающая, что Барак Обама умер в 1865 году, является галлюцинацией .

хеширование

В машинном обучении — механизм группировки категориальных данных , особенно когда количество категорий велико, но количество категорий, фактически появляющихся в наборе данных, сравнительно невелико.

For example, Earth is home to about 73,000 tree species. You could represent each of the 73,000 tree species in 73,000 separate categorical buckets. Alternatively, if only 200 of those tree species actually appear in a dataset, you could use hashing to divide tree species into perhaps 500 buckets.

A single bucket could contain multiple tree species. For example, hashing could place baobab and red maple —two genetically dissimilar species—into the same bucket. Regardless, hashing is still a good way to map large categorical sets into the desired number of buckets. Hashing turns a categorical feature having a large number of possible values into a much smaller number of values by grouping values in a deterministic way.

эвристика

A simple and quickly implemented solution to a problem. For example, "With a heuristic, we achieved 86% accuracy. When we switched to a deep neural network, accuracy went up to 98%."

скрытый слой

#основы

A layer in a neural network between the input layer (the features) and the output layer (the prediction). Each hidden layer consists of one or more neurons . For example, the following neural network contains two hidden layers, the first with three neurons and the second with two neurons:

Четыре слоя. The first layer is an input layer containing two           features. The second layer is a hidden layer containing three           neurons. The third layer is a hidden layer containing two           neurons. Четвертый слой — выходной. Each feature           contains three edges, each of which points to a different neuron           in the second layer. Each of the neurons in the second layer           contains two edges, each of which points to a different neuron           in the third layer. Each of the neurons in the third layer contain           one edge, each pointing to the output layer.

A deep neural network contains more than one hidden layer. For example, the preceding illustration is a deep neural network because the model contains two hidden layers.

иерархическая кластеризация

#clustering

A category of clustering algorithms that create a tree of clusters. Hierarchical clustering is well-suited to hierarchical data, such as botanical taxonomies. There are two types of hierarchical clustering algorithms:

  • Agglomerative clustering first assigns every example to its own cluster, and iteratively merges the closest clusters to create a hierarchical tree.
  • Divisive clustering first groups all examples into one cluster and then iteratively divides the cluster into a hierarchical tree.

Contrast with centroid-based clustering .

hinge loss

A family of loss functions for classification designed to find the decision boundary as distant as possible from each training example, thus maximizing the margin between examples and the boundary. KSVMs use hinge loss (or a related function, such as squared hinge loss). For binary classification, the hinge loss function is defined as follows:

$$\text{loss} = \text{max}(0, 1 - (y * y'))$$

where y is the true label, either -1 or +1, and y' is the raw output of the classifier model:

$$y' = b + w_1x_1 + w_2x_2 + … w_nx_n$$

Consequently, a plot of hinge loss vs. (y * y') looks as follows:

A Cartesian plot consisting of two joined line segments. The first
          line segment starts at (-3, 4) and ends at (1, 0). The second line
          segment begins at (1, 0) and continues indefinitely with a slope
          of 0.

holdout data

Examples intentionally not used ("held out") during training. The validation dataset and test dataset are examples of holdout data. Holdout data helps evaluate your model's ability to generalize to data other than the data it was trained on. The loss on the holdout set provides a better estimate of the loss on an unseen dataset than does the loss on the training set.

хозяин

#TensorFlow
#GoogleCloud

When training an ML model on accelerator chips (GPUs or TPUs ), the part of the system that controls both of the following:

  • The overall flow of the code.
  • The extraction and transformation of the input pipeline.

The host typically runs on a CPU, not on an accelerator chip; the device manipulates tensors on the accelerator chips.

hyperparameter

#основы

The variables that you or a hyperparameter tuning serviceadjust during successive runs of training a model. For example, learning rate is a hyperparameter. You could set the learning rate to 0.01 before one training session. If you determine that 0.01 is too high, you could perhaps set the learning rate to 0.003 for the next training session.

In contrast, parameters are the various weights and bias that the model learns during training.

гиперплоскость

A boundary that separates a space into two subspaces. For example, a line is a hyperplane in two dimensions and a plane is a hyperplane in three dimensions. More typically in machine learning, a hyperplane is the boundary separating a high-dimensional space. Kernel Support Vector Machines use hyperplanes to separate positive classes from negative classes, often in a very high-dimensional space.

я

iid

Abbreviation for independently and identically distributed .

image recognition

#изображение

A process that classifies object(s), pattern(s), or concept(s) in an image. Image recognition is also known as image classification .

For more information, see ML Practicum: Image Classification .

imbalanced dataset

Synonym for class-imbalanced dataset .

implicit bias

#справедливость

Automatically making an association or assumption based on one's mental models and memories. Implicit bias can affect the following:

  • How data is collected and classified.
  • How machine learning systems are designed and developed.

For example, when building a classifier to identify wedding photos, an engineer may use the presence of a white dress in a photo as a feature. However, white dresses have been customary only during certain eras and in certain cultures.

См. также предвзятость подтверждения .

вменение

Краткая форма вменения стоимости .

несовместимость показателей справедливости

#справедливость

Идея о том, что некоторые понятия справедливости несовместимы друг с другом и не могут быть удовлетворены одновременно. В результате не существует единого универсального показателя для количественной оценки справедливости, который можно было бы применить ко всем проблемам ОД.

Хотя это может показаться обескураживающим, несовместимость показателей справедливости не означает, что усилия по обеспечению справедливости бесплодны. Вместо этого предполагается, что справедливость должна определяться контекстуально для конкретной проблемы ОД с целью предотвращения вреда, специфичного для случаев ее использования.

См. «О (не)возможности справедливости» для более подробного обсуждения этой темы.

обучение в контексте

#язык
#генеративныйИИ

Синоним « подсказки с несколькими выстрелами ».

независимо и одинаково распределены (iid)

#основы

Data drawn from a distribution that doesn't change, and where each value drawn doesn't depend on values that have been drawn previously. An iid is the ideal gas of machine learning—a useful mathematical construct but almost never exactly found in the real world. For example, the distribution of visitors to a web page may be iid over a brief window of time; that is, the distribution doesn't change during that brief window and one person's visit is generally independent of another's visit. However, if you expand that window of time, seasonal differences in the web page's visitors may appear.

See also nonstationarity .

individual fairness

#справедливость

A fairness metric that checks whether similar individuals are classified similarly. For example, Brobdingnagian Academy might want to satisfy individual fairness by ensuring that two students with identical grades and standardized test scores are equally likely to gain admission.

Note that individual fairness relies entirely on how you define "similarity" (in this case, grades and test scores), and you can run the risk of introducing new fairness problems if your similarity metric misses important information (such as the rigor of a student's учебный план).

See "Fairness Through Awareness" for a more detailed discussion of individual fairness.

вывод

#основы

In machine learning, the process of making predictions by applying a trained model to unlabeled examples .

Inference has a somewhat different meaning in statistics. See the Wikipedia article on statistical inference for details.

inference path

#df

In a decision tree , during inference , the route a particular example takes from the root to other conditions , terminating with a leaf . For instance, in the following decision tree, the thicker arrows show the inference path for an example with the following feature values:

  • x = 7
  • у = 12
  • z = -3

The inference path in the following illustration travels through three conditions before reaching the leaf ( Zeta ).

A decision tree consisting of four conditions and five leaves.
          The root condition is (x > 0). Since the answer is Yes, the
          inference path travels from the root to the next condition (y > 0).
          Since the answer is Yes, the inference path then travels to the
          next condition (z > 0). Since the answer is No, the inference path
          travels to its terminal node, which is the leaf (Zeta).

The three thick arrows show the inference path.

получение информации

#df

In decision forests , the difference between a node's entropy and the weighted (by number of examples) sum of the entropy of its children nodes. A node's entropy is the entropy of the examples in that node.

For example, consider the following entropy values:

  • entropy of parent node = 0.6
  • entropy of one child node with 16 relevant examples = 0.2
  • entropy of another child node with 24 relevant examples = 0.1

So 40% of the examples are in one child node and 60% are in the other child node. Поэтому:

  • weighted entropy sum of child nodes = (0.4 * 0.2) + (0.6 * 0.1) = 0.14

So, the information gain is:

  • information gain = entropy of parent node - weighted entropy sum of child nodes
  • information gain = 0.6 - 0.14 = 0.46

Most splitters seek to create conditions that maximize information gain.

in-group bias

#справедливость

Showing partiality to one's own group or own characteristics. If testers or raters consist of the machine learning developer's friends, family, or colleagues, then in-group bias may invalidate product testing or the dataset.

In-group bias is a form of group attribution bias . See also out-group homogeneity bias .

input generator

A mechanism by which data is loaded into a neural network .

An input generator can be thought of as a component responsible for processing raw data into tensors which are iterated over to generate batches for training, evaluation, and inference.

входной слой

#основы

The layer of a neural network that holds the feature vector . That is, the input layer provides examples for training or inference . For example, the input layer in the following neural network consists of two features:

Four layers: an input layer, two hidden layers, and an output layer.

in-set condition

#df

In a decision tree , a condition that tests for the presence of one item in a set of items. For example, the following is an in-set condition:

  house-style in [tudor, colonial, cape]

During inference, if the value of the house-style feature is tudor or colonial or cape , then this condition evaluates to Yes. If the value of the house-style feature is something else (for example, ranch ), then this condition evaluates to No.

In-set conditions usually lead to more efficient decision trees than conditions that test one-hot encoded features.

пример

Synonym for example .

инструкция по настройке

#генеративныйИИ

A form of fine-tuning that improves a generative AI model's ability to follow instructions. Instruction tuning involves training a model on a series of instruction prompts, typically covering a wide variety of tasks. The resulting instruction-tuned model then tends to generate useful responses to zero-shot prompts across a variety of tasks.

Compare and contrast with:

интерпретируемость

#основы

The ability to explain or to present an ML model's reasoning in understandable terms to a human.

Most linear regression models, for example, are highly interpretable. (You merely need to look at the trained weights for each feature.) Decision forests are also highly interpretable. Some models, however, require sophisticated visualization to become interpretable.

You can use the Learning Interpretability Tool (LIT) to interpret ML models.

inter-rater agreement

A measurement of how often human raters agree when doing a task. If raters disagree, the task instructions may need to be improved. Also sometimes called inter-annotator agreement or inter-rater reliability . See also Cohen's kappa , which is one of the most popular inter-rater agreement measurements.

intersection over union (IoU)

#изображение

The intersection of two sets divided by their union. In machine-learning image-detection tasks, IoU is used to measure the accuracy of the model's predicted bounding box with respect to the ground-truth bounding box. In this case, the IoU for the two boxes is the ratio between the overlapping area and the total area, and its value ranges from 0 (no overlap of predicted bounding box and ground-truth bounding box) to 1 (predicted bounding box and ground-truth bounding box have the exact same coordinates).

For example, in the image below:

  • The predicted bounding box (the coordinates delimiting where the model predicts the night table in the painting is located) is outlined in purple.
  • The ground-truth bounding box (the coordinates delimiting where the night table in the painting is actually located) is outlined in green.

The Van Gogh painting 'Vincent's Bedroom in Arles', with two different
          bounding boxes around the night table beside the bed. The ground-truth
          bounding box (in green) perfectly circumscribes the night table. The
          predicted bounding box (in purple) is offset 50% down and to the right
          of the ground-truth bounding box; it encloses the bottom-right quarter
          of the night table, but misses the rest of the table.

Here, the intersection of the bounding boxes for prediction and ground truth (below left) is 1, and the union of the bounding boxes for prediction and ground truth (below right) is 7, so the IoU is \(\frac{1}{7}\).

Same image as above, but with each bounding box divided into four
          quadrants. There are seven quadrants total, as the bottom-right
          quadrant of the ground-truth bounding box and the top-left
          quadrant of the predicted bounding box overlap each other. This
          overlapping section (highlighted in green) represents the
          intersection, and has an area of 1.Same image as above, but with each bounding box divided into four
          quadrants. There are seven quadrants total, as the bottom-right
          quadrant of the ground-truth bounding box and the top-left
          quadrant of the predicted bounding box overlap each other.
          The entire interior enclosed by both bounding boxes
          (highlighted in green) represents the union, and has
          an area of 7.

IoU

Abbreviation for intersection over union .

item matrix

#recsystems

In recommendation systems , a matrix of embedding vectors generated by matrix factorization that holds latent signals about each item . Each row of the item matrix holds the value of a single latent feature for all items. For example, consider a movie recommendation system. Each column in the item matrix represents a single movie. The latent signals might represent genres, or might be harder-to-interpret signals that involve complex interactions among genre, stars, movie age, or other factors.

The item matrix has the same number of columns as the target matrix that is being factorized. For example, given a movie recommendation system that evaluates 10,000 movie titles, the item matrix will have 10,000 columns.

предметы

#recsystems

In a recommendation system , the entities that a system recommends. For example, videos are the items that a video store recommends, while books are the items that a bookstore recommends.

итерация

#основы

A single update of a model's parameters—the model's weights and biases —during training . The batch size determines how many examples the model processes in a single iteration. For instance, if the batch size is 20, then the model processes 20 examples before adjusting the parameters.

When training a neural network , a single iteration involves the following two passes:

  1. A forward pass to evaluate loss on a single batch.
  2. A backward pass ( backpropagation ) to adjust the model's parameters based on the loss and the learning rate.

Дж

ДЖАКС

An array computing library, bringing together XLA (Accelerated Linear Algebra) and automatic differentiation for high-performance numerical computing. JAX provides a simple and powerful API for writing accelerated numerical code with composable transformations. JAX provides features such as:

  • grad (automatic differentiation)
  • jit (just-in-time compilation)
  • vmap (automatic vectorization or batching)
  • pmap (parallelization)

JAX is a language for expressing and composing transformations of numerical code, analogous—but much larger in scope—to Python's NumPy library. (In fact, the .numpy library under JAX is a functionally equivalent, but entirely rewritten version of the Python NumPy library.)

JAX is particularly well-suited for speeding up many machine learning tasks by transforming the models and data into a form suitable for parallelism across GPU and TPU accelerator chips .

Flax , Optax , Pax , and many other libraries are built on the JAX infrastructure.

К

Керас

A popular Python machine learning API. Keras runs on several deep learning frameworks, including TensorFlow, where it is made available as tf.keras .

Kernel Support Vector Machines (KSVMs)

A classification algorithm that seeks to maximize the margin between positive and negative classes by mapping input data vectors to a higher dimensional space. For example, consider a classification problem in which the input dataset has a hundred features. To maximize the margin between positive and negative classes, a KSVM could internally map those features into a million-dimension space. KSVMs uses a loss function called hinge loss .

keypoints

#изображение

The coordinates of particular features in an image. For example, for an image recognition model that distinguishes flower species, keypoints might be the center of each petal, the stem, the stamen, and so on.

k-fold cross validation

An algorithm for predicting a model's ability to generalize to new data. The k in k-fold refers to the number of equal groups you divide a dataset's examples into; that is, you train and test your model k times. For each round of training and testing, a different group is the test set, and all remaining groups become the training set. After k rounds of training and testing, you calculate the mean and standard deviation of the desired test metric(s).

For example, suppose your dataset consists of 120 examples. Further suppose, you decide to set k to 4. Therefore, after shuffling the examples, you divide the dataset into four equal groups of 30 examples and conduct four training/testing rounds:

A dataset broken into four equal groups of examples. In Round 1,
          the first three groups are used for training and the last group
          is used for testing. In Round 2, the first two groups and the last
          group are used for training, while the third group is used for
          testing. In Round 3, the first group and the last two groups are
          used for training, while the second group is used for testing.
          In Round 4, the first group is used is for testing, while the final
          three groups are used for training.

For example, Mean Squared Error (MSE) might be the most meaningful metric for a linear regression model. Therefore, you would find the mean and standard deviation of the MSE across all four rounds.

k-средство

#clustering

A popular clustering algorithm that groups examples in unsupervised learning. The k-means algorithm basically does the following:

  • Iteratively determines the best k center points (known as centroids ).
  • Assigns each example to the closest centroid. Those examples nearest the same centroid belong to the same group.

The k-means algorithm picks centroid locations to minimize the cumulative square of the distances from each example to its closest centroid.

For example, consider the following plot of dog height to dog width:

A Cartesian plot with several dozen data points.

If k=3, the k-means algorithm will determine three centroids. Each example is assigned to its closest centroid, yielding three groups:

The same Cartesian plot as in the previous illustration, except
          with three centroids added.
          The previous data points are clustered into three distinct groups,
          with each group representing the data points closest to a particular
          centroid.

Imagine that a manufacturer wants to determine the ideal sizes for small, medium, and large sweaters for dogs. The three centroids identify the mean height and mean width of each dog in that cluster. So, the manufacturer should probably base sweater sizes on those three centroids. Note that the centroid of a cluster is typically not an example in the cluster.

The preceding illustrations shows k-means for examples with only two features (height and width). Note that k-means can group examples across many features.

k-median

#clustering

A clustering algorithm closely related to k-means . The practical difference between the two is as follows:

  • In k-means, centroids are determined by minimizing the sum of the squares of the distance between a centroid candidate and each of its examples.
  • In k-median, centroids are determined by minimizing the sum of the distance between a centroid candidate and each of its examples.

Note that the definitions of distance are also different:

  • k-means relies on the Euclidean distance from the centroid to an example. (In two dimensions, the Euclidean distance means using the Pythagorean theorem to calculate the hypotenuse.) For example, the k-means distance between (2,2) and (5,-2) would be:
$$ {\text{Euclidean distance}} = {\sqrt {(2-5)^2 + (2--2)^2}} = 5 $$
  • k-median relies on the Manhattan distance from the centroid to an example. This distance is the sum of the absolute deltas in each dimension. For example, the k-median distance between (2,2) and (5,-2) would be:
$$ {\text{Manhattan distance}} = \lvert 2-5 \rvert + \lvert 2--2 \rvert = 7 $$

л

L 0 regularization

#основы

A type of regularization that penalizes the total number of nonzero weights in a model. For example, a model having 11 nonzero weights would be penalized more than a similar model having 10 nonzero weights.

L 0 regularization is sometimes called L0-norm regularization .

L 1 loss

#основы

A loss function that calculates the absolute value of the difference between actual label values and the values that a model predicts. For example, here's the calculation of L 1 loss for a batch of five examples :

Actual value of example Model's predicted value Absolute value of delta
7 6 1
5 4 1
8 11 3
4 6 2
9 8 1
8 = L 1 loss

L 1 loss is less sensitive to outliers than L 2 loss .

The Mean Absolute Error is the average L 1 loss per example.

L 1 regularization

#основы

A type of regularization that penalizes weights in proportion to the sum of the absolute value of the weights. L 1 regularization helps drive the weights of irrelevant or barely relevant features to exactly 0 . A feature with a weight of 0 is effectively removed from the model.

Contrast with L 2 regularization .

L 2 loss

#основы

A loss function that calculates the square of the difference between actual label values and the values that a model predicts. For example, here's the calculation of L 2 loss for a batch of five examples :

Actual value of example Model's predicted value Square of delta
7 6 1
5 4 1
8 11 9
4 6 4
9 8 1
16 = L 2 loss

Due to squaring, L 2 loss amplifies the influence of outliers . That is, L 2 loss reacts more strongly to bad predictions than L 1 loss . For example, the L 1 loss for the preceding batch would be 8 rather than 16. Notice that a single outlier accounts for 9 of the 16.

Regression models typically use L 2 loss as the loss function.

The Mean Squared Error is the average L 2 loss per example. Squared loss is another name for L 2 loss.

L 2 regularization

#основы

A type of regularization that penalizes weights in proportion to the sum of the squares of the weights. L 2 regularization helps drive outlier weights (those with high positive or low negative values) closer to 0 but not quite to 0 . Features with values very close to 0 remain in the model but don't influence the model's prediction very much.

L 2 regularization always improves generalization in linear models .

Contrast with L 1 regularization .

этикетка

#основы

In supervised machine learning , the "answer" or "result" portion of an example .

Each labeled example consists of one or more features and a label. For instance, in a spam detection dataset, the label would probably be either "spam" or "not spam." In a rainfall dataset, the label might be the amount of rain that fell during a certain period.

labeled example

#основы

An example that contains one or more features and a label . For example, the following table shows three labeled examples from a house valuation model, each with three features and one label:

Количество спален Количество ванных комнат House age House price (label)
3 2 15 345 000 долларов США
2 1 72 $179,000
4 2 34 $392,000

In supervised machine learning , models train on labeled examples and make predictions on unlabeled examples .

Contrast labeled example with unlabeled examples.

label leakage

A model design flaw in which a feature is a proxy for the label . For example, consider a binary classification model that predicts whether or not a prospective customer will purchase a particular product. Suppose that one of the features for the model is a Boolean named SpokeToCustomerAgent . Further suppose that a customer agent is only assigned after the prospective customer has actually purchased the product. During training, the model will quickly learn the association between SpokeToCustomerAgent and the label.

лямбда

#основы

Synonym for regularization rate .

Lambda is an overloaded term. Here we're focusing on the term's definition within regularization .

LaMDA (Language Model for Dialogue Applications)

#язык

A Transformer -based large language model developed by Google trained on a large dialogue dataset that can generate realistic conversational responses.

LaMDA: our breakthrough conversation technology provides an overview.

landmarks

#изображение

Synonym for keypoints .

language model

#язык

A model that estimates the probability of a token or sequence of tokens occurring in a longer sequence of tokens.

большая языковая модель

#язык

An informal term with no strict definition that usually means a language model that has a high number of parameters . Some large language models contain over 100 billion parameters.

слой

#основы

A set of neurons in a neural network . Three common types of layers are as follows:

For example, the following illustration shows a neural network with one input layer, two hidden layers, and one output layer:

A neural network with one input layer, two hidden layers, and one           output layer. Входной слой состоит из двух объектов. The first           hidden layer consists of three neurons and the second hidden layer           consists of two neurons. Выходной слой состоит из одного узла.

In TensorFlow , layers are also Python functions that take Tensors and configuration options as input and produce other tensors as output.

Layers API (tf.layers)

#TensorFlow

A TensorFlow API for constructing a deep neural network as a composition of layers. The Layers API enables you to build different types of layers , such as:

The Layers API follows the Keras layers API conventions. That is, aside from a different prefix, all functions in the Layers API have the same names and signatures as their counterparts in the Keras layers API.

лист

#df

Any endpoint in a decision tree . Unlike a condition , a leaf doesn't perform a test. Rather, a leaf is a possible prediction. A leaf is also the terminal node of an inference path .

For example, the following decision tree contains three leaves:

Дерево решений с двумя условиями, ведущими к трем листьям.

Learning Interpretability Tool (LIT)

A visual, interactive model-understanding and data visualization tool.

You can use open-source LIT to interpret models or to visualize text, image, and tabular data.

скорость обучения

#основы

A floating-point number that tells the gradient descent algorithm how strongly to adjust weights and biases on each iteration . For example, a learning rate of 0.3 would adjust weights and biases three times more powerfully than a learning rate of 0.1.

Learning rate is a key hyperparameter . If you set the learning rate too low, training will take too long. If you set the learning rate too high, gradient descent often has trouble reaching convergence .

регрессия по методу наименьших квадратов

A linear regression model trained by minimizing L 2 Loss .

линейный

#основы

A relationship between two or more variables that can be represented solely through addition and multiplication.

The plot of a linear relationship is a line.

Contrast with nonlinear .

linear model

#основы

A model that assigns one weight per feature to make predictions . (Linear models also incorporate a bias .) In contrast, the relationship of features to predictions in deep models is generally nonlinear .

Linear models are usually easier to train and more interpretable than deep models. However, deep models can learn complex relationships between features.

Linear regression and logistic regression are two types of linear models.

линейная регрессия

#основы

A type of machine learning model in which both of the following are true:

  • The model is a linear model .
  • The prediction is a floating-point value. (This is the regression part of linear regression .)

Contrast linear regression with logistic regression . Also, contrast regression with classification .

ЛИТ

Abbreviation for the Learning Interpretability Tool (LIT) , which was previously known as the Language Interpretability Tool.

логистическая регрессия

#основы

A type of regression model that predicts a probability. Logistic regression models have the following characteristics:

  • The label is categorical . The term logistic regression usually refers to binary logistic regression , that is, to a model that calculates probabilities for labels with two possible values. A less common variant, multinomial logistic regression , calculates probabilities for labels with more than two possible values.
  • The loss function during training is Log Loss . (Multiple Log Loss units can be placed in parallel for labels with more than two possible values.)
  • The model has a linear architecture, not a deep neural network. However, the remainder of this definition also applies to deep models that predict probabilities for categorical labels.

For example, consider a logistic regression model that calculates the probability of an input email being either spam or not spam. During inference, suppose the model predicts 0.72. Therefore, the model is estimating:

  • A 72% chance of the email being spam.
  • A 28% chance of the email not being spam.

A logistic regression model uses the following two-step architecture:

  1. The model generates a raw prediction (y') by applying a linear function of input features.
  2. The model uses that raw prediction as input to a sigmoid function , which converts the raw prediction to a value between 0 and 1, exclusive.

Like any regression model, a logistic regression model predicts a number. However, this number typically becomes part of a binary classification model as follows:

  • If the predicted number is greater than the classification threshold , the binary classification model predicts the positive class.
  • If the predicted number is less than the classification threshold, the binary classification model predicts the negative class.

логиты

The vector of raw (non-normalized) predictions that a classification model generates, which is ordinarily then passed to a normalization function. If the model is solving a multi-class classification problem, logits typically become an input to the softmax function. The softmax function then generates a vector of (normalized) probabilities with one value for each possible class.

tf.nn.sigmoid_cross_entropy_with_logits .

Log Loss

#основы

The loss function used in binary logistic regression .

log-odds

#основы

The logarithm of the odds of some event.

Long Short-Term Memory (LSTM)

#seq

A type of cell in a recurrent neural network used to process sequences of data in applications such as handwriting recognition, machine translation, and image captioning. LSTMs address the vanishing gradient problem that occurs when training RNNs due to long data sequences by maintaining history in an internal memory state based on new input and context from previous cells in the RNN.

потеря

#основы

During the training of a supervised model , a measure of how far a model's prediction is from its label .

A loss function calculates the loss.

loss aggregator

A type of machine learning algorithm that improves the performance of a model by combining the predictions of multiple models and using those predictions to make a single prediction. As a result, a loss aggregator can reduce the variance of the predictions and improve the accuracy of the predictions.

loss curve

#основы

A plot of loss as a function of the number of training iterations . The following plot shows a typical loss curve:

A Cartesian graph of loss versus training iterations, showing a
          rapid drop in loss for the initial iterations, followed by a gradual
          drop, and then a flat slope during the final iterations.

Loss curves can help you determine when your model is converging or overfitting .

Loss curves can plot all of the following types of loss:

See also generalization curve .

loss function

#основы

During training or testing, a mathematical function that calculates the loss on a batch of examples. A loss function returns a lower loss for models that makes good predictions than for models that make bad predictions.

The goal of training is typically to minimize the loss that a loss function returns.

Many different kinds of loss functions exist. Pick the appropriate loss function for the kind of model you are building. Например:

loss surface

A graph of weight(s) vs. loss. Gradient descent aims to find the weight(s) for which the loss surface is at a local minimum.

ЛСТМ

#seq

Abbreviation for Long Short-Term Memory .

М

машинное обучение

#основы

A program or system that trains a model from input data. The trained model can make useful predictions from new (never-before-seen) data drawn from the same distribution as the one used to train the model.

Machine learning also refers to the field of study concerned with these programs or systems.

majority class

#основы

The more common label in a class-imbalanced dataset . For example, given a dataset containing 99% negative labels and 1% positive labels, the negative labels are the majority class.

Contrast with minority class .

Markov decision process (MDP)

#рл

A graph representing the decision-making model where decisions (or actions ) are taken to navigate a sequence of states under the assumption that the Markov property holds. In reinforcement learning , these transitions between states return a numerical reward .

Markov property

#рл

A property of certain environments , where state transitions are entirely determined by information implicit in the current state and the agent's action .

masked language model

#язык

A language model that predicts the probability of candidate tokens to fill in blanks in a sequence. For instance, a masked language model can calculate probabilities for candidate word(s) to replace the underline in the following sentence:

The ____ in the hat came back.

The literature typically uses the string "MASK" instead of an underline. Например:

The "MASK" in the hat came back.

Most modern masked language models are bidirectional .

matplotlib

An open-source Python 2D plotting library. matplotlib helps you visualize different aspects of machine learning.

matrix factorization

#recsystems

In math, a mechanism for finding the matrices whose dot product approximates a target matrix.

In recommendation systems , the target matrix often holds users' ratings on items . For example, the target matrix for a movie recommendation system might look something like the following, where the positive integers are user ratings and 0 means that the user didn't rate the movie:

Касабланка The Philadelphia Story Черная пантера Удивительная женщина Криминальное чтиво
Пользователь 1 5.0 3.0 0,0 2.0 0,0
Пользователь 2 4.0 0,0 0,0 1.0 5.0
User 3 3.0 1.0 4.0 5.0 0,0

The movie recommendation system aims to predict user ratings for unrated movies. For example, will User 1 like Black Panther ?

One approach for recommendation systems is to use matrix factorization to generate the following two matrices:

  • A user matrix , shaped as the number of users X the number of embedding dimensions.
  • An item matrix , shaped as the number of embedding dimensions X the number of items.

For example, using matrix factorization on our three users and five items could yield the following user matrix and item matrix:

User Matrix                 Item Matrix

1.1   2.3           0.9   0.2   1.4    2.0   1.2
0.6   2.0           1.7   1.2   1.2   -0.1   2.1
2.5   0.5

The dot product of the user matrix and item matrix yields a recommendation matrix that contains not only the original user ratings but also predictions for the movies that each user hasn't seen. For example, consider User 1's rating of Casablanca , which was 5.0. The dot product corresponding to that cell in the recommendation matrix should hopefully be around 5.0, and it is:

(1.1 * 0.9) + (2.3 * 1.7) = 4.9

More importantly, will User 1 like Black Panther ? Taking the dot product corresponding to the first row and the third column yields a predicted rating of 4.3:

(1.1 * 1.4) + (2.3 * 1.2) = 4.3

Matrix factorization typically yields a user matrix and item matrix that, together, are significantly more compact than the target matrix.

Mean Absolute Error (MAE)

The average loss per example when L 1 loss is used. Calculate Mean Absolute Error as follows:

  1. Calculate the L 1 loss for a batch.
  2. Divide the L 1 loss by the number of examples in the batch.

For example, consider the calculation of L 1 loss on the following batch of five examples:

Actual value of example Model's predicted value Loss (difference between actual and predicted)
7 6 1
5 4 1
8 11 3
4 6 2
9 8 1
8 = L 1 loss

So, L 1 loss is 8 and the number of examples is 5. Therefore, the Mean Absolute Error is:

Mean Absolute Error = L1 loss / Number of Examples
Mean Absolute Error = 8/5 = 1.6

Contrast Mean Absolute Error with Mean Squared Error and Root Mean Squared Error .

Среднеквадратическая ошибка (MSE)

The average loss per example when L 2 loss is used. Calculate Mean Squared Error as follows:

  1. Calculate the L 2 loss for a batch.
  2. Divide the L 2 loss by the number of examples in the batch.

For example, consider the loss on the following batch of five examples:

Реальная стоимость Model's prediction Потеря Squared loss
7 6 1 1
5 4 1 1
8 11 3 9
4 6 2 4
9 8 1 1
16 = L 2 loss

Therefore, the Mean Squared Error is:

Mean Squared Error = L2 loss / Number of Examples
Mean Squared Error = 16/5 = 3.2

Mean Squared Error is a popular training optimizer , particularly for linear regression .

Contrast Mean Squared Error with Mean Absolute Error and Root Mean Squared Error .

TensorFlow Playground uses Mean Squared Error to calculate loss values.

сетка

#TensorFlow
#GoogleCloud

In ML parallel programming, a term associated with assigning the data and model to TPU chips, and defining how these values will be sharded or replicated.

Mesh is an overloaded term that can mean either of the following:

  • A physical layout of TPU chips.
  • An abstract logical construct for mapping the data and model to the TPU chips.

In either case, a mesh is specified as a shape .

meta-learning

#язык

A subset of machine learning that discovers or improves a learning algorithm. A meta-learning system can also aim to train a model to quickly learn a new task from a small amount of data or from experience gained in previous tasks. Meta-learning algorithms generally try to achieve the following:

  • Improve/learn hand-engineered features (such as an initializer or an optimizer).
  • Be more data-efficient and compute-efficient.
  • Improve generalization.

Meta-learning is related to few-shot learning .

метрика

#TensorFlow

A statistic that you care about.

An objective is a metric that a machine learning system tries to optimize.

Metrics API (tf.metrics)

A TensorFlow API for evaluating models. For example, tf.metrics.accuracy determines how often a model's predictions match labels.

mini-batch

#основы

A small, randomly selected subset of a batch processed in one iteration . The batch size of a mini-batch is usually between 10 and 1,000 examples.

For example, suppose the entire training set (the full batch) consists of 1,000 examples. Further suppose that you set the batch size of each mini-batch to 20. Therefore, each iteration determines the loss on a random 20 of the 1,000 examples and then adjusts the weights and biases accordingly.

It is much more efficient to calculate the loss on a mini-batch than the loss on all the examples in the full batch.

mini-batch stochastic gradient descent

A gradient descent algorithm that uses mini-batches . In other words, mini-batch stochastic gradient descent estimates the gradient based on a small subset of the training data. Regular stochastic gradient descent uses a mini-batch of size 1.

minimax loss

A loss function for generative adversarial networks , based on the cross-entropy between the distribution of generated data and real data.

Minimax loss is used in the first paper to describe generative adversarial networks.

minority class

#основы

The less common label in a class-imbalanced dataset . For example, given a dataset containing 99% negative labels and 1% positive labels, the positive labels are the minority class.

Contrast with majority class .

МЛ

Abbreviation for machine learning .

MNIST

#изображение

A public-domain dataset compiled by LeCun, Cortes, and Burges containing 60,000 images, each image showing how a human manually wrote a particular digit from 0–9. Each image is stored as a 28x28 array of integers, where each integer is a grayscale value between 0 and 255, inclusive.

MNIST is a canonical dataset for machine learning, often used to test new machine learning approaches. For details, see The MNIST Database of Handwritten Digits .

модальность

#язык

A high-level data category. For example, numbers, text, images, video, and audio are five different modalities.

модель

#основы

In general, any mathematical construct that processes input data and returns output. Phrased differently, a model is the set of parameters and structure needed for a system to make predictions. In supervised machine learning , a model takes an example as input and infers a prediction as output. Within supervised machine learning, models differ somewhat. Например:

  • A linear regression model consists of a set of weights and a bias .
  • A neural network model consists of:
    • A set of hidden layers , each containing one or more neurons .
    • The weights and bias associated with each neuron.
  • A decision tree model consists of:
    • The shape of the tree; that is, the pattern in which the conditions and leaves are connected.
    • The conditions and leaves.

You can save, restore, or make copies of a model.

Unsupervised machine learning also generates models, typically a function that can map an input example to the most appropriate cluster .

model capacity

The complexity of problems that a model can learn. The more complex the problems that a model can learn, the higher the model's capacity. A model's capacity typically increases with the number of model parameters. For a formal definition of classifier capacity, see VC dimension .

model parallelism

#язык

A way of scaling training or inference that puts different parts of one model on different devices . Model parallelism enables models that are too big to fit on a single device.

To implement model parallelism, a system typically does the following:

  1. Shards (divides) the model into smaller parts.
  2. Distributes the training of those smaller parts across multiple processors. Each processor trains its own part of the model.
  3. Combines the results to create a single model.

Model parallelism slows training.

See also data parallelism .

model training

The process of determining the best model .

Импульс

A sophisticated gradient descent algorithm in which a learning step depends not only on the derivative in the current step, but also on the derivatives of the step(s) that immediately preceded it. Momentum involves computing an exponentially weighted moving average of the gradients over time, analogous to momentum in physics. Momentum sometimes prevents learning from getting stuck in local minima.

multi-class classification

#основы

In supervised learning, a classification problem in which the dataset contains more than two classes of labels. For example, the labels in the Iris dataset must be one of the following three classes:

  • Iris setosa
  • Iris virginica
  • Iris versicolor

A model trained on the Iris dataset that predicts Iris type on new examples is performing multi-class classification.

In contrast, classification problems that distinguish between exactly two classes are binary classification models . For example, an email model that predicts either spam or not spam is a binary classification model.

In clustering problems, multi-class classification refers to more than two clusters.

multi-class logistic regression

Using logistic regression in multi-class classification problems.

multi-head self-attention

#язык

An extension of self-attention that applies the self-attention mechanism multiple times for each position in the input sequence.

Transformers introduced multi-head self-attention.

multimodal model

#язык

A model whose inputs and/or outputs include more than one modality . For example, consider a model that takes both an image and a text caption (two modalities) as features , and outputs a score indicating how appropriate the text caption is for the image. So, this model's inputs are multimodal and the output is unimodal.

multinomial classification

Synonym for multi-class classification .

multinomial regression

Synonym for multi-class logistic regression .

многозадачность

A machine learning technique in which a single model is trained to perform multiple tasks .

Multitask models are created by training on data that is appropriate for each of the different tasks. This allows the model to learn to share information across the tasks, which helps the model learn more effectively.

A model trained for multiple tasks often has improved generalization abilities and can be more robust at handling different types of data.

Н

NaN trap

When one number in your model becomes a NaN during training, which causes many or all other numbers in your model to eventually become a NaN.

NaN is an abbreviation for N ot a N umber.

natural language understanding

#язык

Determining a user's intentions based on what the user typed or said. For example, a search engine uses natural language understanding to determine what the user is searching for based on what the user typed or said.

negative class

#основы

In binary classification , one class is termed positive and the other is termed negative . The positive class is the thing or event that the model is testing for and the negative class is the other possibility. Например:

  • The negative class in a medical test might be "not tumor."
  • The negative class in an email classifier might be "not spam."

Contrast with positive class .

negative sampling

Synonym for candidate sampling .

Neural Architecture Search (NAS)

A technique for automatically designing the architecture of a neural network . NAS algorithms can reduce the amount of time and resources required to train a neural network.

NAS typically uses:

  • A search space, which is a set of possible architectures.
  • A fitness function, which is a measure of how well a particular architecture performs on a given task.

NAS algorithms often start with a small set of possible architectures and gradually expand the search space as the algorithm learns more about what architectures are effective. The fitness function is typically based on the performance of the architecture on a training set, and the algorithm is typically trained using a reinforcement learning technique.

NAS algorithms have proven effective in finding high-performing architectures for a variety of tasks, including image classification , text classification, and machine translation.

нейронная сеть

#основы

A model containing at least one hidden layer . A deep neural network is a type of neural network containing more than one hidden layer. For example, the following diagram shows a deep neural network containing two hidden layers.

A neural network with an input layer, two hidden layers, and an
          output layer.

Each neuron in a neural network connects to all of the nodes in the next layer. For example, in the preceding diagram, notice that each of the three neurons in the first hidden layer separately connect to both of the two neurons in the second hidden layer.

Neural networks implemented on computers are sometimes called artificial neural networks to differentiate them from neural networks found in brains and other nervous systems.

Some neural networks can mimic extremely complex nonlinear relationships between different features and the label.

See also convolutional neural network and recurrent neural network .

нейрон

#основы

In machine learning, a distinct unit within a hidden layer of a neural network . Each neuron performs the following two-step action:

  1. Calculates the weighted sum of input values multiplied by their corresponding weights.
  2. Passes the weighted sum as input to an activation function .

A neuron in the first hidden layer accepts inputs from the feature values in the input layer . A neuron in any hidden layer beyond the first accepts inputs from the neurons in the preceding hidden layer. For example, a neuron in the second hidden layer accepts inputs from the neurons in the first hidden layer.

The following illustration highlights two neurons and their inputs.

A neural network with an input layer, two hidden layers, and an
          output layer. Two neurons are highlighted: one in the first
          hidden layer and one in the second hidden layer. The highlighted
          neuron in the first hidden layer receives inputs from both features
          in the input layer. The highlighted neuron in the second hidden layer
          receives inputs from each of the three neurons in the first hidden
          layer.

A neuron in a neural network mimics the behavior of neurons in brains and other parts of nervous systems.

N-gram

#seq
#язык

An ordered sequence of N words. For example, truly madly is a 2-gram. Because order is relevant, madly truly is a different 2-gram than truly madly .

Н Name(s) for this kind of N-gram Примеры
2 bigram or 2-gram to go, go to, eat lunch, eat dinner
3 trigram or 3-gram ate too much, three blind mice, the bell tolls
4 4-gram walk in the park, dust in the wind, the boy ate lentils

Many natural language understanding models rely on N-grams to predict the next word that the user will type or say. For example, suppose a user typed three blind . An NLU model based on trigrams would likely predict that the user will next type mice .

Contrast N-grams with bag of words , which are unordered sets of words.

НЛУ

#язык

Abbreviation for natural language understanding .

node (decision tree)

#df

In a decision tree , any condition or leaf .

Дерево решений с двумя условиями и тремя листьями.

node (neural network)

#основы

A neuron in a hidden layer .

node (TensorFlow graph)

#TensorFlow

An operation in a TensorFlow graph .

шум

Broadly speaking, anything that obscures the signal in a dataset. Noise can be introduced into data in a variety of ways. Например:

  • Human raters make mistakes in labeling.
  • Humans and instruments mis-record or omit feature values.

non-binary condition

#df

A condition containing more than two possible outcomes. For example, the following non-binary condition contains three possible outcomes:

A condition (number_of_legs = ?) that leads to three possible
          outcomes. One outcome (number_of_legs = 8) leads to a leaf
          named spider. A second outcome (number_of_legs = 4) leads to
          a leaf named dog. A third outcome (number_of_legs = 2) leads to
          a leaf named penguin.

нелинейный

#основы

A relationship between two or more variables that can't be represented solely through addition and multiplication. A linear relationship can be represented as a line; a nonlinear relationship can't be represented as a line. For example, consider two models that each relate a single feature to a single label. The model on the left is linear and the model on the right is nonlinear:

Два сюжета. Один график представляет собой линию, поэтому это линейная зависимость. Другой график представляет собой кривую, поэтому это нелинейная зависимость.

non-response bias

#справедливость

См. смещение выбора .

nonstationarity

#основы

A feature whose values change across one or more dimensions, usually time. For example, consider the following examples of nonstationarity:

  • The number of swimsuits sold at a particular store varies with the season.
  • The quantity of a particular fruit harvested in a particular region is zero for much of the year but large for a brief period.
  • Due to climate change, annual mean temperatures are shifting.

Contrast with stationarity .

нормализация

#основы

Broadly speaking, the process of converting a variable's actual range of values into a standard range of values, such as:

  • -1 to +1
  • 0 to 1
  • the normal distribution

For example, suppose the actual range of values of a certain feature is 800 to 2,400. As part of feature engineering , you could normalize the actual values down to a standard range, such as -1 to +1.

Normalization is a common task in feature engineering . Models usually train faster (and produce better predictions) when every numerical feature in the feature vector has roughly the same range.

novelty detection

The process of determining whether a new (novel) example comes from the same distribution as the training set . In other words, after training on the training set, novelty detection determines whether a new example (during inference or during additional training) is an outlier .

Contrast with outlier detection .

numerical data

#основы

Features represented as integers or real-valued numbers. For example, a house valuation model would probably represent the size of a house (in square feet or square meters) as numerical data. Representing a feature as numerical data indicates that the feature's values have a mathematical relationship to the label. That is, the number of square meters in a house probably has some mathematical relationship to the value of the house.

Not all integer data should be represented as numerical data. For example, postal codes in some parts of the world are integers; however, integer postal codes should not be represented as numerical data in models. That's because a postal code of 20000 is not twice (or half) as potent as a postal code of 10000. Furthermore, although different postal codes do correlate to different real estate values, we can't assume that real estate values at postal code 20000 are twice as valuable as real estate values at postal code 10000. Postal codes should be represented as categorical data instead.

Numerical features are sometimes called continuous features .

NumPy

An open-source math library that provides efficient array operations in Python. pandas is built on NumPy.

О

цель

A metric that your algorithm is trying to optimize.

целевая функция

The mathematical formula or metric that a model aims to optimize. For example, the objective function for linear regression is usually Mean Squared Loss . Therefore, when training a linear regression model, training aims to minimize Mean Squared Loss.

In some cases, the goal is to maximize the objective function. For example, if the objective function is accuracy, the goal is to maximize accuracy.

See also loss .

oblique condition

#df

In a decision tree , a condition that involves more than one feature . For example, if height and width are both features, then the following is an oblique condition:

  height > width

Contrast with axis-aligned condition .

не в сети

#основы

Synonym for static .

offline inference

#основы

The process of a model generating a batch of predictions and then caching (saving) those predictions. Apps can then access the desired prediction from the cache rather than rerunning the model.

For example, consider a model that generates local weather forecasts (predictions) once every four hours. After each model run, the system caches all the local weather forecasts. Weather apps retrieve the forecasts from the cache.

Offline inference is also called static inference .

Contrast with online inference .

one-hot encoding

#основы

Representing categorical data as a vector in which:

  • One element is set to 1.
  • All other elements are set to 0.

One-hot encoding is commonly used to represent strings or identifiers that have a finite set of possible values. For example, suppose a certain categorical feature named Scandinavia has five possible values:

  • "Дания"
  • "Швеция"
  • "Норвегия"
  • "Финляндия"
  • "Исландия"

One-hot encoding could represent each of the five values as follows:

страна Вектор
"Дания" 1 0 0 0 0
"Швеция" 0 1 0 0 0
"Норвегия" 0 0 1 0 0
"Финляндия" 0 0 0 1 0
"Исландия" 0 0 0 0 1

Thanks to one-hot encoding, a model can learn different connections based on each of the five countries.

Representing a feature as numerical data is an alternative to one-hot encoding. Unfortunately, representing the Scandinavian countries numerically is not a good choice. For example, consider the following numeric representation:

  • "Denmark" is 0
  • "Sweden" is 1
  • "Norway" is 2
  • "Finland" is 3
  • "Iceland" is 4

With numeric encoding, a model would interpret the raw numbers mathematically and would try to train on those numbers. However, Iceland isn't actually twice as much (or half as much) of something as Norway, so the model would come to some strange conclusions.

one-shot learning

A machine learning approach, often used for object classification, designed to learn effective classifiers from a single training example.

See also few-shot learning and zero-shot learning .

одноразовая подсказка

#язык
#генеративныйИИ

A prompt that contains one example demonstrating how the large language model should respond. For example, the following prompt contains one example showing a large language model how it should answer a query.

Части одной подсказки Примечания
Какая официальная валюта указанной страны? Вопрос, на который вы хотите получить ответ от LLM.
France: EUR One example.
Индия: Фактический запрос.

Compare and contrast one-shot prompting with the following terms:

one-vs.-all

#основы

Given a classification problem with N classes, a solution consisting of N separate binary classifiers —one binary classifier for each possible outcome. For example, given a model that classifies examples as animal, vegetable, or mineral, a one-vs.-all solution would provide the following three separate binary classifiers:

  • animal vs. not animal
  • vegetable vs. not vegetable
  • mineral vs. not mineral

В сети

#основы

Synonym for dynamic .

online inference

#основы

Generating predictions on demand. For example, suppose an app passes input to a model and issues a request for a prediction. A system using online inference responds to the request by running the model (and returning the prediction to the app).

Contrast with offline inference .

operation (op)

#TensorFlow

In TensorFlow, any procedure that creates, manipulates, or destroys a Tensor . For example, a matrix multiply is an operation that takes two Tensors as input and generates one Tensor as output.

Optax

A gradient processing and optimization library for JAX . Optax facilitates research by providing building blocks that can be recombined in custom ways to optimize parametric models such as deep neural networks. Other goals include:

  • Providing readable, well-tested, efficient implementations of core components.
  • Improving productivity by making it possible to combine low level ingredients into custom optimizers (or other gradient processing components).
  • Accelerating adoption of new ideas by making it easy for anyone to contribute.

оптимизатор

A specific implementation of the gradient descent algorithm. Popular optimizers include:

  • AdaGrad , which stands for ADAptive GRADient descent.
  • Adam, which stands for ADAptive with Momentum.

out-group homogeneity bias

#справедливость

The tendency to see out-group members as more alike than in-group members when comparing attitudes, values, personality traits, and other characteristics. In-group refers to people you interact with regularly; out-group refers to people you do not interact with regularly. If you create a dataset by asking people to provide attributes about out-groups, those attributes may be less nuanced and more stereotyped than attributes that participants list for people in their in-group.

For example, Lilliputians might describe the houses of other Lilliputians in great detail, citing small differences in architectural styles, windows, doors, and sizes. However, the same Lilliputians might simply declare that Brobdingnagians all live in identical houses.

Out-group homogeneity bias is a form of group attribution bias .

See also in-group bias .

outlier detection

The process of identifying outliers in a training set .

Contrast with novelty detection .

выбросы

Values distant from most other values. In machine learning, any of the following are outliers:

  • Input data whose values are more than roughly 3 standard deviations from the mean.
  • Weights with high absolute values.
  • Predicted values relatively far away from the actual values.

For example, suppose that widget-price is a feature of a certain model. Assume that the mean widget-price is 7 Euros with a standard deviation of 1 Euro. Examples containing a widget-price of 12 Euros or 2 Euros would therefore be considered outliers because each of those prices is five standard deviations from the mean.

Outliers are often caused by typos or other input mistakes. In other cases, outliers aren't mistakes; after all, values five standard deviations away from the mean are rare but hardly impossible.

Outliers often cause problems in model training. Clipping is one way of managing outliers.

out-of-bag evaluation (OOB evaluation)

#df

A mechanism for evaluating the quality of a decision forest by testing each decision tree against the examples not used during training of that decision tree. For example, in the following diagram, notice that the system trains each decision tree on about two-thirds of the examples and then evaluates against the remaining one-third of the examples.

Лес решений, состоящий из трех деревьев решений. One decision tree trains on two-thirds of the examples           and then uses the remaining one-third for OOB evaluation. A second decision tree trains on a different two-thirds           of the examples than the previous decision tree, and then           uses a different one-third for OOB evaluation than the           previous decision tree.

Out-of-bag evaluation is a computationally efficient and conservative approximation of the cross-validation mechanism. In cross-validation, one model is trained for each cross-validation round (for example, 10 models are trained in a 10-fold cross-validation). With OOB evaluation, a single model is trained. Because bagging withholds some data from each tree during training, OOB evaluation can use that data to approximate cross-validation.

output layer

#основы

The "final" layer of a neural network. The output layer contains the prediction.

The following illustration shows a small deep neural network with an input layer, two hidden layers, and an output layer:

A neural network with one input layer, two hidden layers, and one           output layer. Входной слой состоит из двух объектов. The first           hidden layer consists of three neurons and the second hidden layer           consists of two neurons. Выходной слой состоит из одного узла.

переоснащение

#основы

Creating a model that matches the training data so closely that the model fails to make correct predictions on new data.

Regularization can reduce overfitting. Training on a large and diverse training set can also reduce overfitting.

передискретизация

Reusing the examples of a minority class in a class-imbalanced dataset in order to create a more balanced training set .

For example, consider a binary classification problem in which the ratio of the majority class to the minority class is 5,000:1. If the dataset contains a million examples, then the dataset contains only about 200 examples of the minority class, which might be too few examples for effective training. To overcome this deficiency, you might oversample (reuse) those 200 examples multiple times, possibly yielding sufficient examples for useful training.

You need to be careful about over overfitting when oversampling.

Contrast with undersampling .

п

packed data

An approach for storing data more efficiently.

Packed data stores data either by using a compressed format or in some other way that allows it to be accessed more efficiently. Packed data minimizes the amount of memory and computation required to access it, leading to faster training and more efficient model inference.

Packed data is often used with other techniques, such as data augmentation and regularization , further improving the performance of models .

панды

#основы

A column-oriented data analysis API built on top of numpy . Many machine learning frameworks, including TensorFlow, support pandas data structures as inputs. See the pandas documentation for details.

параметр

#основы

The weights and biases that a model learns during training . For example, in a linear regression model, the parameters consist of the bias ( b ) and all the weights ( w 1 , w 2 , and so on) in the following formula:

$$y' = b + w_1x_1 + w_2x_2 + … w_nx_n$$

In contrast, hyperparameter are the values that you (or a hyperparameter turning service) supply to the model. For example, learning rate is a hyperparameter.

настройка с эффективным использованием параметров

#язык
#генеративныйИИ

A set of techniques to fine-tune a large pre-trained language model (PLM) more efficiently than full fine-tuning . Parameter-efficient tuning typically fine-tunes far fewer parameters than full fine-tuning, yet generally produces a large language model that performs as well (or almost as well) as a large language model built from full fine-tuning.

Compare and contrast parameter-efficient tuning with:

Parameter-efficient tuning is also known as parameter-efficient fine-tuning .

Parameter Server (PS)

#TensorFlow

A job that keeps track of a model's parameters in a distributed setting.

parameter update

The operation of adjusting a model's parameters during training, typically within a single iteration of gradient descent .

частная производная

A derivative in which all but one of the variables is considered a constant. For example, the partial derivative of f(x, y) with respect to x is the derivative of f considered as a function of x alone (that is, keeping y constant). The partial derivative of f with respect to x focuses only on how x is changing and ignores all other variables in the equation.

participation bias

#справедливость

Synonym for non-response bias. См. смещение выбора .

partitioning strategy

The algorithm by which variables are divided across parameter servers .

Пакс

A programming framework designed for training large-scale neural network models so large that they span multiple TPU accelerator chip slices or pods .

Pax is built on Flax , which is built on JAX .

Диаграмма, показывающая положение Пакса в стеке программного обеспечения. Pax построен на базе JAX. Pax itself consists of three           layers. Нижний слой содержит TensorStore и Flax. Средний слой содержит Оптакс и Флаксформер. The top           layer contains Praxis Modeling Library. Fiddle is built           on top of Pax.

персептрон

A system (either hardware or software) that takes in one or more input values, runs a function on the weighted sum of the inputs, and computes a single output value. In machine learning, the function is typically nonlinear, such as ReLU , sigmoid , or tanh . For example, the following perceptron relies on the sigmoid function to process three input values:

$$f(x_1, x_2, x_3) = \text{sigmoid}(w_1 x_1 + w_2 x_2 + w_3 x_3)$$

In the following illustration, the perceptron takes three inputs, each of which is itself modified by a weight before entering the perceptron:

A perceptron that takes in 3 inputs, each multiplied by separate           weights. Персептрон выводит одно значение.

Perceptrons are the neurons in neural networks .

производительность

Overloaded term with the following meanings:

  • The traditional meaning within software engineering. Namely: How fast (or efficiently) does this piece of software run?
  • The meaning within machine learning. Here, performance answers the following question: How correct is this model ? That is, how good are the model's predictions?

permutation variable importances

#df

A type of variable importance that evaluates the increase in the prediction error of a model after permuting the feature's values. Permutation variable importance is a model agnostic metric.

недоумение

One measure of how well a model is accomplishing its task. For example, suppose your task is to read the first few letters of a word a user is typing on a smartphone keyboard, and to offer a list of possible completion words. Perplexity, P, for this task is approximately the number of guesses you need to offer in order for your list to contain the actual word the user is trying to type.

Perplexity is related to cross-entropy as follows:

$$P= 2^{-\text{cross entropy}}$$

трубопровод

The infrastructure surrounding a machine learning algorithm. A pipeline includes gathering the data, putting the data into training data files, training one or more models, and exporting the models to production.

pipelining

#язык

A form of model parallelism in which a model's processing is divided into consecutive stages and each stage is executed on a different device. While a stage is processing one batch, the preceding stage can work on the next batch.

See also staged training .

pjit

A JAX function that splits code to run across multiple accelerator chips . The user passes a function to pjit, which returns a function that has the equivalent semantics but is compiled into an XLA computation that runs across multiple devices (such as GPUs or TPU cores).

pjit enables users to shard computations without rewriting them by using the SPMD partitioner.

As of March 2023, pjit has been merged with jit . Refer to Distributed arrays and automatic parallelization for more details.

PLM

#язык
#генеративныйИИ

Abbreviation for pre-trained language model .

pmap

A JAX function that executes copies of an input function on multiple underlying hardware devices (CPUs, GPUs, or TPUs ), with different input values. pmap relies on SPMD .

политика

#рл

In reinforcement learning, an agent's probabilistic mapping from states to actions .

объединение

#изображение

Reducing a matrix (or matrices) created by an earlier convolutional layer to a smaller matrix. Pooling usually involves taking either the maximum or average value across the pooled area. For example, suppose we have the following 3x3 matrix:

Матрица 3x3 [[5,3,1], [8,2,5], [9,4,3]].

A pooling operation, just like a convolutional operation, divides that matrix into slices and then slides that convolutional operation by strides . For example, suppose the pooling operation divides the convolutional matrix into 2x2 slices with a 1x1 stride. As the following diagram illustrates, four pooling operations take place. Imagine that each pooling operation picks the maximum value of the four in that slice:

The input matrix is 3x3 with the values: [[5,3,1], [8,2,5], [9,4,3]]. The top-left 2x2 submatrix of the input matrix is [[5,3], [8,2]], so           the top-left pooling operation yields the value 8 (which is the           maximum of 5, 3, 8, and 2 ). The top-right 2x2 submatrix of the input           matrix is [[3,1], [2,5]], so the top-right pooling operation yields           the value 5. The bottom-left 2x2 submatrix of the input matrix is           [[8,2], [9,4]], so the bottom-left pooling operation yields the value           9. The bottom-right 2x2 submatrix of the input matrix is           [[2,5], [4,3]], so the bottom-right pooling operation yields the value           5. In summary, the pooling operation yields the 2x2 matrix           [[8,5], [9,5]].

Pooling helps enforce translational invariance in the input matrix.

Pooling for vision applications is known more formally as spatial pooling . Time-series applications usually refer to pooling as temporal pooling . Less formally, pooling is often called subsampling or downsampling .

positional encoding

#язык

A technique to add information about the position of a token in a sequence to the token's embedding. Transformer models use positional encoding to better understand the relationship between different parts of the sequence.

A common implementation of positional encoding uses a sinusoidal function. (Specifically, the frequency and amplitude of the sinusoidal function are determined by the position of the token in the sequence.) This technique enables a Transformer model to learn to attend to different parts of the sequence based on their position.

positive class

#основы

The class you are testing for.

For example, the positive class in a cancer model might be "tumor." The positive class in an email classifier might be "spam."

Contrast with negative class .

Постобработка

#справедливость
#основы

Корректировка вывода модели после ее запуска. Постобработка может использоваться для обеспечения соблюдения ограничений справедливости без изменения самих моделей.

Например, можно применить постобработку к двоичному классификатору, установив порог классификации таким образом, чтобы для некоторого атрибута сохранялось равенство возможностей , проверяя, что истинный положительный уровень одинаков для всех значений этого атрибута.

PR AUC (площадь под кривой PR)

Площадь под интерполированной кривой точности-напоминаемости , полученной путем построения точек (напоминаемости, точности) для различных значений порога классификации . В зависимости от способа расчета PR AUC может быть эквивалентен средней точности модели.

Практика

Базовая высокопроизводительная библиотека машинного обучения Pax . Praxis часто называют «библиотекой слоев».

Praxis содержит не только определения класса Layer, но и большинство его вспомогательных компонентов, в том числе:

Praxis предоставляет определения класса Model.

точность

Метрика для моделей классификации , отвечающая на следующий вопрос:

Когда модель предсказала положительный класс , какой процент предсказаний оказался верным?

Вот формула:

$$\text{Precision} = \frac{\text{true positives}} {\text{true positives} + \text{false positives}}$$

где:

  • истинно положительный результат означает, что модель правильно предсказала положительный класс.
  • ложное срабатывание означает, что модель ошибочно предсказала положительный класс.

Например, предположим, что модель сделала 200 положительных прогнозов. Из этих 200 положительных предсказаний:

  • 150 из них были настоящими положительными.
  • 50 оказались ложноположительными.

В этом случае:

$$\text{Precision} = \frac{\text{150}} {\text{150} + \text{50}} = 0.75$$

Сравните с точностью и отзывом .

кривая точного отзыва

Кривая точности и полноты при различных порогах классификации .

прогноз

#основы

Выход модели. Например:

  • Прогноз модели бинарной классификации — это либо положительный класс, либо отрицательный класс.
  • Прогноз модели многоклассовой классификации представляет собой один класс.
  • Прогноз модели линейной регрессии — это число.

смещение прогноза

Значение, указывающее, насколько далеко среднее значение прогнозов отличается от среднего значения меток в наборе данных.

Не путать с термином предвзятости в моделях машинного обучения или с предвзятостью в вопросах этики и справедливости .

прогнозное машинное обучение

Любая традиционная («классическая») система машинного обучения .

Термин «предиктивное машинное обучение» не имеет формального определения. Скорее, этот термин обозначает категорию систем МО , не основанных на генеративном искусственном интеллекте .

прогнозируемая четность

#справедливость

Метрика справедливости , которая проверяет, эквивалентны ли для данного классификатора показатели точности для рассматриваемых подгрупп.

Например, модель, предсказывающая поступление в колледж, будет удовлетворять прогнозному паритету национальности, если ее уровень точности одинаков для лилипутов и бробдингнегов.

Прогнозируемый паритет иногда также называют прогнозирующим паритетом ставок .

См. «Объяснение определений справедливости» (раздел 3.2.1) для более подробного обсуждения прогнозируемой четности.

прогнозируемый паритет ставок

#справедливость

Другое название прогнозирующей четности .

предварительная обработка

#справедливость
Обработка данных перед их использованием для обучения модели. Предварительная обработка может быть такой же простой, как удаление слов из корпуса английского текста, которых нет в английском словаре, или может быть такой же сложной, как повторное выражение точек данных таким образом, чтобы исключить как можно больше атрибутов, которые коррелируют с конфиденциальными атрибутами . . Предварительная обработка может помочь удовлетворить ограничения справедливости .

предварительно обученная модель

#язык
#изображение
#генеративныйИИ

Модели или компоненты модели (например , вектор внедрения ), которые уже прошли обучение. Иногда вы вводите в нейронную сеть предварительно обученные векторы внедрения. В других случаях ваша модель будет обучать сами векторы внедрения, а не полагаться на предварительно обученные вектора внедрения.

Термин «предварительно обученная языковая модель» относится к большой языковой модели , прошедшей предварительное обучение .

предварительная подготовка

#язык
#изображение
#генеративныйИИ

Начальное обучение модели на большом наборе данных. Некоторые предварительно обученные модели являются неуклюжими гигантами и обычно требуют доработки посредством дополнительного обучения. Например, эксперты по машинному обучению могут предварительно обучить большую языковую модель на обширном наборе текстовых данных, например на всех английских страницах в Википедии. После предварительного обучения полученная модель может быть дополнительно уточнена с помощью любого из следующих методов:

предшествующее убеждение

Во что вы верите относительно данных, прежде чем начнете на них тренироваться. Например, регуляризация L2 опирается на априорное убеждение, что веса должны быть небольшими и обычно распределяться около нуля.

вероятностная регрессионная модель

Регрессионная модель , которая использует не только веса для каждого признака , но и неопределенность этих весов. Модель вероятностной регрессии генерирует прогноз и неопределенность этого прогноза. Например, модель вероятностной регрессии может дать прогноз 325 со стандартным отклонением 12. Для получения дополнительной информации о моделях вероятностной регрессии см. этот Colab на tensorflow.org .

быстрый

#язык
#генеративныйИИ

Любой текст, вводимый в качестве входных данных в большую языковую модель , чтобы заставить модель вести себя определенным образом. Подсказки могут быть короткими, как фраза, или произвольной длины (например, весь текст романа). Подсказки делятся на несколько категорий, включая те, которые показаны в следующей таблице:

Категория подсказки Пример Примечания
Вопрос How fast can a pigeon fly?
Инструкция Напишите забавное стихотворение об арбитраже. Подсказка, которая просит большую языковую модель что-то сделать .
Пример Переведите код Markdown в HTML. Например:
Markdown: * list item
HTML: <ul> <li>list item</li> </ul>
Первое предложение в этом примере приглашения представляет собой инструкцию. Оставшаяся часть приглашения является примером.
Роль Объясните, почему градиентный спуск используется при обучении машинному обучению для доктора философии по физике. Первая часть предложения представляет собой инструкцию; фраза «до степени доктора физики» является ролевой частью.
Частичный ввод для завершения модели Премьер-министр Соединенного Королевства живет в Подсказка частичного ввода может либо внезапно закончиться (как в этом примере), либо закончиться подчеркиванием.

Генеративная модель ИИ может отвечать на запрос текстом, кодом, изображениями, встраиваниями , видео… почти чем угодно.

быстрое обучение

#язык
#генеративныйИИ

Способность определенных моделей , позволяющая им адаптировать свое поведение в ответ на произвольный ввод текста ( подсказки ). В типичной парадигме обучения на основе подсказок большая языковая модель реагирует на подсказку, генерируя текст. Например, предположим, что пользователь вводит следующую подсказку:

Кратко изложите третий закон движения Ньютона.

Модель, способная к обучению на основе подсказок, специально не обучена отвечать на предыдущую подсказку. Скорее, модель «знает» много фактов о физике, много об общих правилах языка и многое о том, что представляет собой вообще полезные ответы. Этих знаний достаточно, чтобы дать (надеюсь) полезный ответ. Дополнительная обратная связь от человека («Этот ответ был слишком сложным» или «Какая реакция?») позволяет некоторым системам обучения на основе подсказок постепенно повышать полезность своих ответов.

быстрый дизайн

#язык
#генеративныйИИ

Синоним оперативного проектирования .

оперативное проектирование

#язык
#генеративныйИИ

Искусство создания подсказок , вызывающих желаемые ответы из большой языковой модели . Люди выполняют быстрые инженерные работы. Написание хорошо структурированных подсказок является важной частью обеспечения полезных ответов от большой языковой модели. Оперативное проектирование зависит от многих факторов, в том числе:

Дополнительные сведения о написании полезных подсказок см. в разделе «Введение в дизайн подсказок» .

Оперативное проектирование – это синоним оперативного проектирования.

оперативная настройка

#язык
#генеративныйИИ

Эффективный механизм настройки параметров , который запоминает «префикс», который система добавляет к фактическому приглашению .

Один из вариантов быстрой настройки, иногда называемый настройкой префикса , заключается в добавлении префикса на каждом уровне . Напротив, в большинстве случаев быстрая настройка добавляет только префикс к входному слою .

прокси-метки

#основы

Данные, используемые для аппроксимации меток, не доступны напрямую в наборе данных.

Например, предположим, что вам необходимо обучить модель прогнозированию уровня стресса сотрудников. Ваш набор данных содержит множество прогнозных функций, но не содержит метки с названием «уровень стресса». Не испугавшись, вы выбираете «несчастные случаи на рабочем месте» в качестве индикатора уровня стресса. Ведь сотрудники, находящиеся в состоянии сильного стресса, попадают в больше несчастных случаев, чем спокойные сотрудники. Или они? Возможно, количество несчастных случаев на производстве на самом деле растет и уменьшается по нескольким причинам.

В качестве второго примера предположим, что вы хотите , идет ли дождь? быть логической меткой для вашего набора данных, но ваш набор данных не содержит данных о дожде. Если имеются фотографии, вы можете использовать изображения людей с зонтиками в качестве косвенного индикатора того, идет ли дождь? Это хороший прокси-лейбл? Возможно, но люди в некоторых культурах с большей вероятностью будут носить с собой зонтики для защиты от солнца, чем от дождя.

Прокси-метки часто несовершенны. По возможности выбирайте настоящие метки, а не прокси-метки. Тем не менее, когда фактическая метка отсутствует, выбирайте прокси-метку очень осторожно, выбирая наименее ужасного кандидата на прокси-метку.

прокси (чувствительные атрибуты)

#справедливость
Атрибут, используемый в качестве замены конфиденциального атрибута . Например, почтовый индекс человека может использоваться в качестве показателя его дохода, расовой или этнической принадлежности.

чистая функция

Функция, выходные данные которой основаны только на ее входных данных и не имеет побочных эффектов. В частности, чистая функция не использует и не изменяет какое-либо глобальное состояние, например содержимое файла или значение переменной вне функции.

Чистые функции можно использовать для создания поточно-безопасного кода, что полезно при сегментировании кода модели по нескольким микросхемам ускорителей .

Методы преобразования функций JAX требуют, чтобы входные функции были чистыми функциями.

вопрос

Q-функция

#рл

В обучении с подкреплением - функция, которая прогнозирует ожидаемую прибыль от выполнения действия в определенном состоянии и последующего следования заданной политике .

Q-функция также известна как функция значения состояния-действия .

Q-обучение

#рл

В обучении с подкреплением — алгоритм, который позволяет агенту изучить оптимальную Q-функцию марковского процесса принятия решений , применяя уравнение Беллмана . Марковский процесс принятия решений моделирует окружающую среду .

quantile

Каждый сегмент в квантильном сегментировании .

квантильное группирование

Распределение значений признака по сегментам так, чтобы каждый сегмент содержал одинаковое (или почти одинаковое) количество примеров. Например, на следующем рисунке 44 точки разделены на 4 сегмента, каждый из которых содержит 11 баллов. Чтобы каждый сегмент на рисунке содержал одинаковое количество точек, некоторые сегменты охватывают разную ширину значений x.

44 data points divided into 4 buckets of 11 points each.
          Although each bucket contains the same number of data points,
          some buckets contain a wider range of feature values than other
          buckets.

quantization

Перегруженный термин, который можно использовать двумя способами:

  • Реализация квантильного сегментирования для конкретной функции .
  • Преобразование данных в нули и единицы для более быстрого хранения, обучения и вывода. Поскольку логические данные более устойчивы к шуму и ошибкам, чем другие форматы, квантование может повысить корректность модели. Методы квантования включают округление, усечение и объединение .

очередь

#TensorFlow

Операция TensorFlow, реализующая структуру данных очереди. Обычно используется при вводе-выводе.

р

случайный лес

#df

Ансамбль деревьев решений , в котором каждое дерево решений обучается с использованием определенного случайного шума, такого как пакетирование .

Случайные леса — это тип леса решений .

случайная политика

#рл

В обучении с подкреплениемполитика , которая выбирает действие случайным образом.

рейтинг

Тип контролируемого обучения , цель которого — упорядочить список предметов.

ранг (порядковость)

The ordinal position of a class in a machine learning problem that categorizes classes from highest to lowest. For example, a behavior ranking system could rank a dog's rewards from highest (a steak) to lowest (wilted kale).

rank (Tensor)

#TensorFlow

The number of dimensions in a Tensor . For instance, a scalar has rank 0, a vector has rank 1, and a matrix has rank 2.

Not to be confused with rank (ordinality) .

оценщик

#основы

A human who provides labels for examples . "Annotator" is another name for rater.

отзывать

Метрика для моделей классификации , отвечающая на следующий вопрос:

When ground truth was the positive class , what percentage of predictions did the model correctly identify as the positive class?

Вот формула:

\[\text{Recall} = \frac{\text{true positives}} {\text{true positives} + \text{false negatives}} \]

где:

  • истинно положительный результат означает, что модель правильно предсказала положительный класс.
  • false negative means that the model mistakenly predicted the negative class .

For instance, suppose your model made 200 predictions on examples for which ground truth was the positive class. Of these 200 predictions:

  • 180 were true positives.
  • 20 were false negatives.

В этом случае:

\[\text{Recall} = \frac{\text{180}} {\text{180} + \text{20}} = 0.9 \]

recommendation system

#recsystems

A system that selects for each user a relatively small set of desirable items from a large corpus. For example, a video recommendation system might recommend two videos from a corpus of 100,000 videos, selecting Casablanca and The Philadelphia Story for one user, and Wonder Woman and Black Panther for another. A video recommendation system might base its recommendations on factors such as:

  • Movies that similar users have rated or watched.
  • Genre, directors, actors, target demographic...

Rectified Linear Unit (ReLU)

#основы

An activation function with the following behavior:

  • If input is negative or zero, then the output is 0.
  • If input is positive, then the output is equal to the input.

Например:

  • If the input is -3, then the output is 0.
  • If the input is +3, then the output is 3.0.

Here is a plot of ReLU:

Декартов график из двух линий. The first line has a constant           y value of 0, running along the x-axis from -infinity,0 to 0,-0. Вторая строка начинается с 0,0. This line has a slope of +1, so           it runs from 0,0 to +infinity,+infinity.

ReLU is a very popular activation function. Despite its simple behavior, ReLU still enables a neural network to learn nonlinear relationships between features and the label .

рекуррентная нейронная сеть

#seq

A neural network that is intentionally run multiple times, where parts of each run feed into the next run. Specifically, hidden layers from the previous run provide part of the input to the same hidden layer in the next run. Recurrent neural networks are particularly useful for evaluating sequences, so that the hidden layers can learn from previous runs of the neural network on earlier parts of the sequence.

For example, the following figure shows a recurrent neural network that runs four times. Notice that the values learned in the hidden layers from the first run become part of the input to the same hidden layers in the second run. Similarly, the values learned in the hidden layer on the second run become part of the input to the same hidden layer in the third run. In this way, the recurrent neural network gradually trains and predicts the meaning of the entire sequence rather than just the meaning of individual words.

An RNN that runs four times to process four input words.

regression model

#основы

Informally, a model that generates a numerical prediction. (In contrast, a classification model generates a class prediction.) For example, the following are all regression models:

  • A model that predicts a certain house's value, such as 423,000 Euros.
  • A model that predicts a certain tree's life expectancy, such as 23.2 years.
  • A model that predicts the amount of rain that will fall in a certain city over the next six hours, such as 0.18 inches.

Two common types of regression models are:

  • Linear regression , which finds the line that best fits label values to features.
  • Logistic regression , which generates a probability between 0.0 and 1.0 that a system typically then maps to a class prediction.

Not every model that outputs numerical predictions is a regression model. In some cases, a numeric prediction is really just a classification model that happens to have numeric class names. For example, a model that predicts a numeric postal code is a classification model, not a regression model.

регуляризация

#основы

Any mechanism that reduces overfitting . Popular types of regularization include:

Regularization can also be defined as the penalty on a model's complexity.

regularization rate

#основы

A number that specifies the relative importance of regularization during training. Raising the regularization rate reduces overfitting but may reduce the model's predictive power. Conversely, reducing or omitting the regularization rate increases overfitting.

reinforcement learning (RL)

#рл

A family of algorithms that learn an optimal policy , whose goal is to maximize return when interacting with an environment . For example, the ultimate reward of most games is victory. Reinforcement learning systems can become expert at playing complex games by evaluating sequences of previous game moves that ultimately led to wins and sequences that ultimately led to losses.

Reinforcement Learning from Human Feedback (RLHF)

#генеративныйИИ
#рл

Using feedback from human raters to improve the quality of a model's responses. For example, an RLHF mechanism can ask users to rate the quality of a model's response with a 👍 or 👎 emoji. The system can then adjust its future responses based on that feedback.

РеЛУ

#основы

Abbreviation for Rectified Linear Unit .

replay buffer

#рл

In DQN -like algorithms, the memory used by the agent to store state transitions for use in experience replay .

копия

A copy of the training set or model , typically on another machine. For example, a system could use the following strategy for implementing data parallelism :

  1. Place replicas of an existing model on multiple machines.
  2. Send different subsets of the training set to each replica.
  3. Aggregate the parameter updates.

reporting bias

#справедливость

The fact that the frequency with which people write about actions, outcomes, or properties is not a reflection of their real-world frequencies or the degree to which a property is characteristic of a class of individuals. Reporting bias can influence the composition of data that machine learning systems learn from.

For example, in books, the word laughed is more prevalent than breathed . A machine learning model that estimates the relative frequency of laughing and breathing from a book corpus would probably determine that laughing is more common than breathing.

представление

The process of mapping data to useful features .

re-ranking

#recsystems

The final stage of a recommendation system , during which scored items may be re-graded according to some other (typically, non-ML) algorithm. Re-ranking evaluates the list of items generated by the scoring phase, taking actions such as:

  • Eliminating items that the user has already purchased.
  • Boosting the score of fresher items.

retrieval-augmented generation

#основы

A software architecture commonly used in large language model (LLM) applications. Common motivations to use retrieval-augmented generation include:

  • Increasing the factual accuracy of the model's generated responses
  • Giving the model access to knowledge it was not trained on
  • Changing what knowledge the model uses
  • Enabling the model to cite sources

For example, suppose that a chemistry app uses the PaLM API to generate summaries related to user queries. When the app's backend receives a query, the backend first searches for ("retrieves") data that's relevant to the user's query, appends ("augments") the relevant chemistry data to the user's query, and instructs the LLM to create a summary based on the appended data.

возвращаться

#рл

In reinforcement learning, given a certain policy and a certain state, the return is the sum of all rewards that the agent expects to receive when following the policy from the state to the end of the episode . The agent accounts for the delayed nature of expected rewards by discounting rewards according to the state transitions required to obtain the reward.

Therefore, if the discount factor is \(\gamma\), and \(r_0, \ldots, r_{N}\)denote the rewards until the end of the episode, then the return calculation is as follows:

$$\text{Return} = r_0 + \gamma r_1 + \gamma^2 r_2 + \ldots + \gamma^{N-1} r_{N-1}$$

награда

#рл

In reinforcement learning, the numerical result of taking an action in a state , as defined by the environment .

ridge regularization

Synonym for L 2 regularization . The term ridge regularization is more frequently used in pure statistics contexts, whereas L 2 regularization is used more often in machine learning.

РНН

#seq

Abbreviation for recurrent neural networks .

ROC (receiver operating characteristic) Curve

#основы

A graph of true positive rate vs. false positive rate for different classification thresholds in binary classification.

The shape of an ROC curve suggests a binary classification model's ability to separate positive classes from negative classes. Suppose, for example, that a binary classification model perfectly separates all the negative classes from all the positive classes:

A number line with 8 positive examples on the right side and
          7 negative examples on the left.

The ROC curve for the preceding model looks as follows:

An ROC curve. The x-axis is False Positive Rate and the y-axis
          is True Positive Rate. The curve has an inverted L shape. The curve
          starts at (0.0,0.0) and goes straight up to (0.0,1.0). Then the curve
          goes from (0.0,1.0) to (1.0,1.0).

In contrast, the following illustration graphs the raw logistic regression values for a terrible model that can't separate negative classes from positive classes at all:

A number line with positive examples and negative classes
          completely intermixed.

The ROC curve for this model looks as follows:

An ROC curve, which is actually a straight line from (0.0,0.0)
          to (1.0,1.0).

Meanwhile, back in the real world, most binary classification models separate positive and negative classes to some degree, but usually not perfectly. So, a typical ROC curve falls somewhere between the two extremes:

An ROC curve. The x-axis is False Positive Rate and the y-axis
          is True Positive Rate. The ROC curve approximates a shaky arc
          traversing the compass points from West to North.

The point on an ROC curve closest to (0.0,1.0) theoretically identifies the ideal classification threshold. However, several other real-world issues influence the selection of the ideal classification threshold. For example, perhaps false negatives cause far more pain than false positives.

A numerical metric called AUC summarizes the ROC curve into a single floating-point value.

role prompting

#язык
#генеративныйИИ

An optional part of a prompt that identifies a target audience for a generative AI model's response. Without a role prompt, a large language model provides an answer that may or may not be useful for the person asking the questions. With a role prompt, a large language model can answer in a way that's more appropriate and more helpful for a specific target audience. For example, the role prompt portion of the following prompts are in boldface:

  • Summarize this article for a PhD in economics .
  • Describe how tides work for a ten-year old .
  • Explain the 2008 financial crisis. Speak as you might to a young child, or a golden retriever.

корень

#df

The starting node (the first condition ) in a decision tree . By convention, diagrams put the root at the top of the decision tree. Например:

Дерево решений с двумя условиями и тремя листьями. The           starting condition (x > 2) is the root.

корневая директория

#TensorFlow

The directory you specify for hosting subdirectories of the TensorFlow checkpoint and events files of multiple models.

Root Mean Squared Error (RMSE)

#основы

The square root of the Mean Squared Error .

rotational invariance

#изображение

In an image classification problem, an algorithm's ability to successfully classify images even when the orientation of the image changes. For example, the algorithm can still identify a tennis racket whether it is pointing up, sideways, or down. Note that rotational invariance is not always desirable; for example, an upside-down 9 should not be classified as a 9.

See also translational invariance and size invariance .

R-squared

A regression metric indicating how much variation in a label is due to an individual feature or to a feature set. R-squared is a value between 0 and 1, which you can interpret as follows:

  • An R-squared of 0 means that none of a label's variation is due to the feature set.
  • An R-squared of 1 means that all of a label's variation is due to the feature set.
  • An R-squared between 0 and 1 indicates the extent to which the label's variation can be predicted from a particular feature or the feature set. For example, an R-squared of 0.10 means that 10 percent of the variance in the label is due to the feature set, an R-squared of 0.20 means that 20 percent is due to the feature set, and so on.

R-squared is the square of the Pearson correlation coefficient between the values that a model predicted and ground truth .

С

смещение выборки

#справедливость

См. смещение выбора .

sampling with replacement

#df

A method of picking items from a set of candidate items in which the same item can be picked multiple times. The phrase "with replacement" means that after each selection, the selected item is returned to the pool of candidate items. The inverse method, sampling without replacement , means that a candidate item can only be picked once.

For example, consider the following fruit set:

fruit = {kiwi, apple, pear, fig, cherry, lime, mango}

Suppose that the system randomly picks fig as the first item. If using sampling with replacement, then the system picks the second item from the following set:

fruit = {kiwi, apple, pear, fig, cherry, lime, mango}

Yes, that's the same set as before, so the system could potentially pick fig again.

If using sampling without replacement, once picked, a sample can't be picked again. For example, if the system randomly picks fig as the first sample, then fig can't be picked again. Therefore, the system picks the second sample from the following (reduced) set:

fruit = {kiwi, apple, pear, cherry, lime, mango}

SavedModel

#TensorFlow

The recommended format for saving and recovering TensorFlow models. SavedModel is a language-neutral, recoverable serialization format, which enables higher-level systems and tools to produce, consume, and transform TensorFlow models.

See the Saving and Restoring chapter in the TensorFlow Programmer's Guide for complete details.

Экономьте

#TensorFlow

A TensorFlow object responsible for saving model checkpoints.

скаляр

A single number or a single string that can be represented as a tensor of rank 0. For example, the following lines of code each create one scalar in TensorFlow:

breed = tf.Variable("poodle", tf.string)
temperature = tf.Variable(27, tf.int16)
precision = tf.Variable(0.982375101275, tf.float64)

масштабирование

Any mathematical transform or technique that shifts the range of a label and/or feature value. Some forms of scaling are very useful for transformations like normalization .

Common forms of scaling useful in Machine Learning include:

  • linear scaling, which typically uses a combination of subtraction and division to replace the original value with a number between -1 and +1 or between 0 and 1.
  • logarithmic scaling, which replaces the original value with its logarithm.
  • Z-score normalization , which replaces the original value with a floating-point value representing the number of standard deviations from that feature's mean.

scikit-learn

A popular open-source machine learning platform. See scikit-learn.org .

подсчет очков

#recsystems

The part of a recommendation system that provides a value or ranking for each item produced by the candidate generation phase.

критерий отбора

#справедливость

Errors in conclusions drawn from sampled data due to a selection process that generates systematic differences between samples observed in the data and those not observed. The following forms of selection bias exist:

  • смещение охвата : популяция, представленная в наборе данных, не соответствует популяции, о которой прогнозирует модель машинного обучения.
  • систематическая ошибка выборки : данные из целевой группы собираются не случайным образом.
  • предвзятость отсутствия ответов (также называемая предвзятостью участия ): пользователи из определенных групп отказываются от участия в опросах с разной частотой, чем пользователи из других групп.

Например, предположим, что вы создаете модель машинного обучения, которая предсказывает удовольствие людей от фильма. Чтобы собрать данные обучения, вы раздаете опросник всем, кто находится в первом ряду кинотеатра, где показывают фильм. На первый взгляд это может показаться разумным способом сбора набора данных; однако эта форма сбора данных может привести к следующим формам систематической ошибки отбора:

  • предвзятость охвата. При выборке из группы населения, которая решила посмотреть фильм, прогнозы вашей модели могут не распространяться на людей, которые еще не проявили такой уровень интереса к фильму.
  • смещение выборки: вместо случайной выборки из предполагаемой совокупности (всех людей в фильме) вы выбрали только людей в первом ряду. Возможно, что люди, сидевшие в первом ряду, заинтересовались фильмом больше, чем те, кто сидел в других рядах.
  • предвзятость в связи с отсутствием ответов. В целом, люди с сильными мнениями склонны отвечать на дополнительные опросы чаще, чем люди с умеренными мнениями. Поскольку опрос по фильму не является обязательным, ответы с большей вероятностью образуют бимодальное распределение , чем нормальное (колокольчатое) распределение.

самовнимание (также называемое слоем самовнимания)

#язык

Уровень нейронной сети, который преобразует последовательность вложений (например, встраивания токенов ) в другую последовательность вложений. Каждое вложение в выходную последовательность создается путем интеграции информации из элементов входной последовательности с помощью механизма внимания .

Часть внимания к себе относится к последовательности, обращенной к себе, а не к какому-то другому контексту. Самообслуживание является одним из основных строительных блоков Transformers и использует терминологию поиска по словарю, такую ​​как «запрос», «ключ» и «значение».

Уровень самообслуживания начинается с последовательности входных представлений, по одному на каждое слово. Входное представление слова может быть простым вложением. Для каждого слова во входной последовательности сеть оценивает релевантность слова каждому элементу всей последовательности слов. Оценки релевантности определяют, насколько окончательное представление слова включает в себя представления других слов.

Например, рассмотрим следующее предложение:

Животное не перешло улицу, потому что слишком устало.

На следующей иллюстрации (из книги «Трансформер: новая архитектура нейронной сети для понимания языка ») показан шаблон внимания уровня самообслуживания для местоимения «it» , при этом темнота каждой линии указывает, насколько каждое слово способствует представлению:

The following sentence appears twice: 'The animal didn't cross the
          street because it was too tired.'  Lines connect the word 'it' in
          one sentence to five tokens ('The', 'animal', 'street', 'it', and
          the period) in the other sentence.  The line between 'it' and
          'animal' is strongest.

Уровень самовнимания выделяет слова, имеющие отношение к «этому». В этом случае уровень внимания научился выделять слова, к которым он может относиться, придавая наивысший вес животному .

Для последовательности из n токенов самообладание преобразует последовательность вложений n отдельных раз, по одному разу в каждой позиции последовательности.

Обратите внимание также на внимание и многоголовое самовнимание .

самостоятельное обучение

Семейство методов преобразования задачи машинного обучения без учителя в задачу машинного обучения с учителем путем создания суррогатных меток из немаркированных примеров .

Некоторые модели на основе Transformer , такие как BERT, используют обучение с самоконтролем.

Самостоятельное обучение – это полуконтролируемый подход к обучению .

самообучение

A variant of self-supervised learning that is particularly useful when all of the following conditions are true:

Self-training works by iterating over the following two steps until the model stops improving:

  1. Use supervised machine learning to train a model on the labeled examples.
  2. Use the model created in Step 1 to generate predictions (labels) on the unlabeled examples, moving those in which there is high confidence into the labeled examples with the predicted label.

Notice that each iteration of Step 2 adds more labeled examples for Step 1 to train on.

semi-supervised learning

Training a model on data where some of the training examples have labels but others don't. One technique for semi-supervised learning is to infer labels for the unlabeled examples, and then to train on the inferred labels to create a new model. Semi-supervised learning can be useful if labels are expensive to obtain but unlabeled examples are plentiful.

Self-training is one technique for semi-supervised learning.

sensitive attribute

#справедливость
A human attribute that may be given special consideration for legal, ethical, social, or personal reasons.

анализ настроений

#язык

Using statistical or machine learning algorithms to determine a group's overall attitude—positive or negative—toward a service, product, organization, or topic. For example, using natural language understanding , an algorithm could perform sentiment analysis on the textual feedback from a university course to determine the degree to which students generally liked or disliked the course.

sequence model

#seq

A model whose inputs have a sequential dependence. For example, predicting the next video watched from a sequence of previously watched videos.

sequence-to-sequence task

#язык

A task that converts an input sequence of tokens to an output sequence of tokens. For example, two popular kinds of sequence-to-sequence tasks are:

  • Translators:
    • Sample input sequence: "I love you."
    • Sample output sequence: "Je t'aime."
  • Question answering:
    • Sample input sequence: "Do I need my car in New York City?"
    • Sample output sequence: "No. Please keep your car at home."

сервировка

A synonym for inferring .

shape (Tensor)

The number of elements in each dimension of a tensor. The shape is represented as a list of integers. For example, the following two-dimensional tensor has a shape of [3,4]:

[[5, 7, 6, 4],
 [2, 9, 4, 8],
 [3, 6, 5, 1]]

TensorFlow использует формат строк (стиль C) для представления порядка размеров, поэтому форма в TensorFlow — [3,4], а не [4,3]. Другими словами, в двумерном тензоре TensorFlow форма равна [ количество строк , количество столбцов ].

осколок

#TensorFlow
#GoogleCloud

Логическое разделение обучающего набора или модели . Как правило, некоторые процессы создают сегменты, разделяя примеры или параметры на (обычно) фрагменты одинакового размера. Затем каждый осколок назначается отдельной машине.

Шардинг модели называется параллелизмом модели ; сегментирование данных называется параллелизмом данных .

усадка

#df

Гиперпараметр в повышении градиента , который контролирует переобучение . Сокращение при повышении градиента аналогично скорости обучения при градиентном спуске . Усадка — это десятичное значение от 0,0 до 1,0. Более низкое значение усадки уменьшает переобучение больше, чем большее значение усадки.

сигмовидная функция

#основы

Математическая функция, которая «сжимает» входное значение в ограниченный диапазон, обычно от 0 до 1 или от -1 до +1. То есть вы можете передать любое число (два, миллион, отрицательный миллиард и т. д.) в сигмовидную форму, и результат все равно будет находиться в ограниченном диапазоне. График сигмовидной функции активации выглядит следующим образом:

A two-dimensional curved plot with x values spanning the domain
          -infinity to +positive, while y values span the range almost 0 to
          almost 1. When x is 0, y is 0.5. The slope of the curve is always
          positive, with the highest slope at 0,0.5 and gradually decreasing
          slopes as the absolute value of x increases.

Сигмовидная функция имеет несколько применений в машинном обучении, в том числе:

similarity measure

#clustering

In clustering algorithms, the metric used to determine how alike (how similar) any two examples are.

single program / multiple data (SPMD)

A parallelism technique where the same computation is run on different input data in parallel on different devices. The goal of SPMD is to obtain results more quickly. It is the most common style of parallel programming.

size invariance

#изображение

In an image classification problem, an algorithm's ability to successfully classify images even when the size of the image changes. For example, the algorithm can still identify a cat whether it consumes 2M pixels or 200K pixels. Note that even the best image classification algorithms still have practical limits on size invariance. For example, an algorithm (or human) is unlikely to correctly classify a cat image consuming only 20 pixels.

See also translational invariance and rotational invariance .

зарисовка

#clustering

In unsupervised machine learning , a category of algorithms that perform a preliminary similarity analysis on examples. Sketching algorithms use a locality-sensitive hash function to identify points that are likely to be similar, and then group them into buckets.

Sketching decreases the computation required for similarity calculations on large datasets. Instead of calculating similarity for every single pair of examples in the dataset, we calculate similarity only for each pair of points within each bucket.

софтмакс

#основы

A function that determines probabilities for each possible class in a multi-class classification model . The probabilities add up to exactly 1.0. For example, the following table shows how softmax distributes various probabilities:

Image is a... Вероятность
собака .85
кот .13
лошадь .02

Softmax is also called full softmax .

Contrast with candidate sampling .

sparse feature

#язык
#основы

A feature whose values are predominately zero or empty. For example, a feature containing a single 1 value and a million 0 values is sparse. In contrast, a dense feature has values that are predominantly not zero or empty.

In machine learning, a surprising number of features are sparse features. Categorical features are usually sparse features. For example, of the 300 possible tree species in a forest, a single example might identify just a maple tree . Or, of the millions of possible videos in a video library, a single example might identify just "Casablanca."

In a model, you typically represent sparse features with one-hot encoding . If the one-hot encoding is big, you might put an embedding layer on top of the one-hot encoding for greater efficiency.

sparse representation

#язык
#основы

Storing only the position(s) of nonzero elements in a sparse feature.

For example, suppose a categorical feature named species identifies the 36 tree species in a particular forest. Further assume that each example identifies only a single species.

You could use a one-hot vector to represent the tree species in each example. A one-hot vector would contain a single 1 (to represent the particular tree species in that example) and 35 0 s (to represent the 35 tree species not in that example). So, the one-hot representation of maple might look something like the following:

A vector in which positions 0 through 23 hold the value 0, position
          24 holds the value 1, and positions 25 through 35 hold the value 0.

Alternatively, sparse representation would simply identify the position of the particular species. If maple is at position 24, then the sparse representation of maple would simply be:

24

Notice that the sparse representation is much more compact than the one-hot representation.

sparse vector

#основы

A vector whose values are mostly zeroes. See also sparse feature and sparsity .

редкость

The number of elements set to zero (or null) in a vector or matrix divided by the total number of entries in that vector or matrix. For example, consider a 100-element matrix in which 98 cells contain zero. The calculation of sparsity is as follows:

$$ {\text{sparsity}} = \frac{\text{98}} {\text{100}} = {\text{0.98}} $$

Feature sparsity refers to the sparsity of a feature vector; model sparsity refers to the sparsity of the model weights.

spatial pooling

#изображение

See pooling .

расколоть

#df

In a decision tree , another name for a condition .

splitter

#df

While training a decision tree , the routine (and algorithm) responsible for finding the best condition at each node .

SPMD

Abbreviation for single program / multiple data .

squared hinge loss

The square of the hinge loss . Squared hinge loss penalizes outliers more harshly than regular hinge loss.

squared loss

#основы

Synonym for L 2 loss .

staged training

#язык

A tactic of training a model in a sequence of discrete stages. The goal can be either to speed up the training process, or to achieve better model quality.

An illustration of the progressive stacking approach is shown below:

  • Stage 1 contains 3 hidden layers, stage 2 contains 6 hidden layers, and stage 3 contains 12 hidden layers.
  • Stage 2 begins training with the weights learned in the 3 hidden layers of Stage 1. Stage 3 begins training with the weights learned in the 6 hidden layers of Stage 2.

Три этапа, которые обозначены как «Этап 1», «Этап 2» и «Этап 3». Each stage contains a different number of layers: Stage 1 contains           3 layers, Stage 2 contains 6 layers, and Stage 3 contains 12 layers. The 3 layers from Stage 1 become the first 3 layers of Stage 2.           Similarly, the 6 layers from Stage 2 become the first 6 layers of           Stage 3.

See also pipelining .

состояние

#рл

In reinforcement learning, the parameter values that describe the current configuration of the environment, which the agent uses to choose an action .

state-action value function

#рл

Synonym for Q-function .

статический

#основы

Something done once rather than continuously. The terms static and offline are synonyms. The following are common uses of static and offline in machine learning:

  • static model (or offline model ) is a model trained once and then used for a while.
  • static training (or offline training ) is the process of training a static model.
  • static inference (or offline inference ) is a process in which a model generates a batch of predictions at a time.

Contrast with dynamic .

static inference

#основы

Synonym for offline inference .

стационарность

#основы

A feature whose values don't change across one or more dimensions, usually time. For example, a feature whose values look about the same in 2021 and 2023 exhibits stationarity.

In the real world, very few features exhibit stationarity. Even features synonymous with stability (like sea level) change over time.

Contrast with nonstationarity .

шаг

A forward pass and backward pass of one batch .

See backpropagation for more information on the forward pass and backward pass.

размер шага

Synonym for learning rate .

stochastic gradient descent (SGD)

#основы

A gradient descent algorithm in which the batch size is one. In other words, SGD trains on a single example chosen uniformly at random from a training set .

шагать

#изображение

In a convolutional operation or pooling, the delta in each dimension of the next series of input slices. For example, the following animation demonstrates a (1,1) stride during a convolutional operation. Therefore, the next input slice starts one position to the right of the previous input slice. When the operation reaches the right edge, the next slice is all the way over to the left but one position down.

Входная матрица 5x5 и сверточный фильтр 3x3. Because the      stride is (1,1), a convolutional filter will be applied 9 times. The first      convolutional slice evaluates the top-left 3x3 submatrix of the input      matrix. The second slice evaluates the top-middle 3x3      submatrix. The third convolutional slice evaluates the top-right 3x3      submatrix. Четвертый срез оценивает среднюю левую подматрицу 3x3. Пятый срез оценивает среднюю подматрицу 3x3. The sixth slice      evaluates the middle-right 3x3 submatrix. The seventh slice evaluates      the bottom-left 3x3 submatrix. The eighth slice evaluates the      bottom-middle 3x3 submatrix. The ninth slice evaluates the bottom-right 3x3      submatrix.

The preceding example demonstrates a two-dimensional stride. If the input matrix is three-dimensional, the stride would also be three-dimensional.

structural risk minimization (SRM)

An algorithm that balances two goals:

  • The desire to build the most predictive model (for example, lowest loss).
  • The desire to keep the model as simple as possible (for example, strong regularization).

For example, a function that minimizes loss+regularization on the training set is a structural risk minimization algorithm.

Contrast with empirical risk minimization .

subsampling

#изображение

See pooling .

краткое содержание

#TensorFlow

In TensorFlow, a value or set of values calculated at a particular step , usually used for tracking model metrics during training.

supervised machine learning

#основы

Training a model from features and their corresponding labels . Supervised machine learning is analogous to learning a subject by studying a set of questions and their corresponding answers. After mastering the mapping between questions and answers, a student can then provide answers to new (never-before-seen) questions on the same topic.

Compare with unsupervised machine learning .

synthetic feature

#основы

A feature not present among the input features, but assembled from one or more of them. Methods for creating synthetic features include the following:

  • Bucketing a continuous feature into range bins.
  • Creating a feature cross .
  • Multiplying (or dividing) one feature value by other feature value(s) or by itself. For example, if a and b are input features, then the following are examples of synthetic features:
    • аб
    • 2
  • Applying a transcendental function to a feature value. For example, if c is an input feature, then the following are examples of synthetic features:
    • sin(c)
    • ln(c)

Features created by normalizing or scaling alone are not considered synthetic features.

Т

Т5

#язык

A text-to-text transfer learning model introduced by Google AI in 2020 . T5 is an encoder - decoder model, based on the Transformer architecture, trained on an extremely large dataset. It is effective at a variety of natural language processing tasks, such as generating text, translating languages, and answering questions in a conversational manner.

T5 gets its name from the five T's in "Text-to-Text Transfer Transformer."

T5X

#язык

An open-source, machine learning framework designed to build and train large-scale natural language processing (NLP) models. T5 is implemented on the T5X codebase (which is built on JAX and Flax ).

tabular Q-learning

#рл

In reinforcement learning , implementing Q-learning by using a table to store the Q-functions for every combination of state and action .

цель

Synonym for label .

target network

#рл

In Deep Q-learning , a neural network that is a stable approximation of the main neural network, where the main neural network implements either a Q-function or a policy . Then, you can train the main network on the Q-values predicted by the target network. Therefore, you prevent the feedback loop that occurs when the main network trains on Q-values predicted by itself. By avoiding this feedback, training stability increases.

задача

A problem that can be solved using machine learning techniques, such as:

температура

#язык
#изображение
#генеративныйИИ

A hyperparameter that controls the degree of randomness of a model's output. Higher temperatures result in more random output, while lower temperatures result in less random output.

Choosing the best temperature depends on the specific application and the desired properties of the model's output. For example, you would probably raise the temperature when creating an application that generates creative output. Conversely, you would probably lower the temperature when building a model that classifies images or text in order to improve the model's accuracy and consistency.

Temperature is often used with softmax .

temporal data

Data recorded at different points in time. For example, winter coat sales recorded for each day of the year would be temporal data.

Тензор

#TensorFlow

The primary data structure in TensorFlow programs. Tensors are N-dimensional (where N could be very large) data structures, most commonly scalars, vectors, or matrices. The elements of a Tensor can hold integer, floating-point, or string values.

TensorBoard

#TensorFlow

The dashboard that displays the summaries saved during the execution of one or more TensorFlow programs.

Тензорфлоу

#TensorFlow

A large-scale, distributed, machine learning platform. The term also refers to the base API layer in the TensorFlow stack, which supports general computation on dataflow graphs.

Although TensorFlow is primarily used for machine learning, you may also use TensorFlow for non-ML tasks that require numerical computation using dataflow graphs.

TensorFlow Playground

#TensorFlow

A program that visualizes how different hyperparameters influence model (primarily neural network) training. Go to http://playground.tensorflow.org to experiment with TensorFlow Playground.

TensorFlow Serving

#TensorFlow

A platform to deploy trained models in production.

Тензорный процессор (ТПУ)

#TensorFlow
#GoogleCloud

An application-specific integrated circuit (ASIC) that optimizes the performance of machine learning workloads. These ASICs are deployed as multiple TPU chips on a TPU device .

Tensor rank

#TensorFlow

See rank (Tensor) .

Tensor shape

#TensorFlow

The number of elements a Tensor contains in various dimensions. For example, a [5, 10] Tensor has a shape of 5 in one dimension and 10 in another.

Tensor size

#TensorFlow

The total number of scalars a Tensor contains. For example, a [5, 10] Tensor has a size of 50.

TensorStore

A library for efficiently reading and writing large multi-dimensional arrays.

условие завершения

#рл

In reinforcement learning , the conditions that determine when an episode ends, such as when the agent reaches a certain state or exceeds a threshold number of state transitions. For example, in tic-tac-toe (also known as noughts and crosses), an episode terminates either when a player marks three consecutive spaces or when all spaces are marked.

тест

#df

In a decision tree , another name for a condition .

test loss

#основы

A metric representing a model's loss against the test set . When building a model , you typically try to minimize test loss. That's because a low test loss is a stronger quality signal than a low training loss or low validation loss .

A large gap between test loss and training loss or validation loss sometimes suggests that you need to increase the regularization rate .

test set

A subset of the dataset reserved for testing a trained model .

Traditionally, you divide examples in the dataset into the following three distinct subsets:

Each example in a dataset should belong to only one of the preceding subsets. For instance, a single example should not belong to both the training set and the test set.

The training set and validation set are both closely tied to training a model. Because the test set is only indirectly associated with training, test loss is a less biased, higher quality metric than training loss or validation loss .

text span

#язык

The array index span associated with a specific subsection of a text string. For example, the word good in the Python string s="Be good now" occupies the text span from 3 to 6.

tf.Example

#TensorFlow

A standard protocol buffer for describing input data for machine learning model training or inference.

tf.keras

#TensorFlow

An implementation of Keras integrated into TensorFlow .

threshold (for decision trees)

#df

In an axis-aligned condition , the value that a feature is being compared against. For example, 75 is the threshold value in the following condition:

grade >= 75

time series analysis

#clustering

A subfield of machine learning and statistics that analyzes temporal data . Many types of machine learning problems require time series analysis, including classification, clustering, forecasting, and anomaly detection. For example, you could use time series analysis to forecast the future sales of winter coats by month based on historical sales data.

шаг времени

#seq

One "unrolled" cell within a recurrent neural network . For example, the following figure shows three timesteps (labeled with the subscripts t-1, t, and t+1):

Три временных шага в рекуррентной нейронной сети. The output of the           first timestep becomes input to the second timestep. The output           of the second timestep becomes input to the third timestep.

жетон

#язык

In a language model , the atomic unit that the model is training on and making predictions on. A token is typically one of the following:

  • a word—for example, the phrase "dogs like cats" consists of three word tokens: "dogs", "like", and "cats".
  • a character—for example, the phrase "bike fish" consists of nine character tokens. (Note that the blank space counts as one of the tokens.)
  • subwords—in which a single word can be a single token or multiple tokens. A subword consists of a root word, a prefix, or a suffix. For example, a language model that uses subwords as tokens might view the word "dogs" as two tokens (the root word "dog" and the plural suffix "s"). That same language model might view the single word "taller" as two subwords (the root word "tall" and the suffix "er").

In domains outside of language models, tokens can represent other kinds of atomic units. For example, in computer vision, a token might be a subset of an image.

башня

A component of a deep neural network that is itself a deep neural network without an output layer. Typically, each tower reads from an independent data source. Towers are independent until their output is combined in a final layer.

ТПУ

#TensorFlow
#GoogleCloud

Abbreviation for Tensor Processing Unit .

TPU chip

#TensorFlow
#GoogleCloud

A programmable linear algebra accelerator with on-chip high bandwidth memory that is optimized for machine learning workloads. Multiple TPU chips are deployed on a TPU device .

TPU device

#TensorFlow
#GoogleCloud

A printed circuit board (PCB) with multiple TPU chips , high bandwidth network interfaces, and system cooling hardware.

TPU master

#TensorFlow
#GoogleCloud

The central coordination process running on a host machine that sends and receives data, results, programs, performance, and system health information to the TPU workers . The TPU master also manages the setup and shutdown of TPU devices .

TPU node

#TensorFlow
#GoogleCloud

A TPU resource on Google Cloud Platform with a specific TPU type . The TPU node connects to your VPC Network from a peer VPC network . TPU nodes are a resource defined in the Cloud TPU API .

TPU Pod

#TensorFlow
#GoogleCloud

A specific configuration of TPU devices in a Google data center. All of the devices in a TPU Pod are connected to one another over a dedicated high-speed network. A TPU Pod is the largest configuration of TPU devices available for a specific TPU version.

TPU resource

#TensorFlow
#GoogleCloud

A TPU entity on Google Cloud Platform that you create, manage, or consume. For example, TPU nodes and TPU types are TPU resources.

TPU slice

#TensorFlow
#GoogleCloud

A TPU slice is a fractional portion of the TPU devices in a TPU Pod . All of the devices in a TPU slice are connected to one another over a dedicated high-speed network.

TPU type

#TensorFlow
#GoogleCloud

A configuration of one or more TPU devices with a specific TPU hardware version. You select a TPU type when you create a TPU node on Google Cloud Platform. For example, a v2-8 TPU type is a single TPU v2 device with 8 cores. A v3-2048 TPU type has 256 networked TPU v3 devices and a total of 2048 cores. TPU types are a resource defined in the Cloud TPU API .

TPU worker

#TensorFlow
#GoogleCloud

A process that runs on a host machine and executes machine learning programs on TPU devices .

обучение

#основы

The process of determining the ideal parameters (weights and biases) comprising a model . During training, a system reads in examples and gradually adjusts parameters. Training uses each example anywhere from a few times to billions of times.

training loss

#основы

A metric representing a model's loss during a particular training iteration. For example, suppose the loss function is Mean Squared Error . Perhaps the training loss (the Mean Squared Error) for the 10th iteration is 2.2, and the training loss for the 100th iteration is 1.9.

A loss curve plots training loss vs. the number of iterations. A loss curve provides the following hints about training:

  • A downward slope implies that the model is improving.
  • An upward slope implies that the model is getting worse.
  • A flat slope implies that the model has reached convergence .

For example, the following somewhat idealized loss curve shows:

  • A steep downward slope during the initial iterations, which implies rapid model improvement.
  • A gradually flattening (but still downward) slope until close to the end of training, which implies continued model improvement at a somewhat slower pace then during the initial iterations.
  • A flat slope towards the end of training, which suggests convergence.

График потерь обучения в сравнении с итерациями. This loss curve starts      with a steep downward slope. The slope gradually flattens until the      slope becomes zero.

Although training loss is important, see also generalization .

training-serving skew

#основы

The difference between a model's performance during training and that same model's performance during serving .

Обучающий набор

#основы

The subset of the dataset used to train a model .

Traditionally, examples in the dataset are divided into the following three distinct subsets:

Ideally, each example in the dataset should belong to only one of the preceding subsets. For example, a single example should not belong to both the training set and the validation set.

траектория

#рл

In reinforcement learning , a sequence of tuples that represent a sequence of state transitions of the agent , where each tuple corresponds to the state, action , reward , and next state for a given state transition.

transfer learning

Transferring information from one machine learning task to another. For example, in multi-task learning, a single model solves multiple tasks, such as a deep model that has different output nodes for different tasks. Transfer learning might involve transferring knowledge from the solution of a simpler task to a more complex one, or involve transferring knowledge from a task where there is more data to one where there is less data.

Most machine learning systems solve a single task. Transfer learning is a baby step towards artificial intelligence in which a single program can solve multiple tasks.

Трансформатор

#язык

A neural network architecture developed at Google that relies on self-attention mechanisms to transform a sequence of input embeddings into a sequence of output embeddings without relying on convolutions or recurrent neural networks . A Transformer can be viewed as a stack of self-attention layers.

A Transformer can include any of the following:

An encoder transforms a sequence of embeddings into a new sequence of the same length. An encoder includes N identical layers, each of which contains two sub-layers. These two sub-layers are applied at each position of the input embedding sequence, transforming each element of the sequence into a new embedding. The first encoder sub-layer aggregates information from across the input sequence. The second encoder sub-layer transforms the aggregated information into an output embedding.

A decoder transforms a sequence of input embeddings into a sequence of output embeddings, possibly with a different length. A decoder also includes N identical layers with three sub-layers, two of which are similar to the encoder sub-layers. The third decoder sub-layer takes the output of the encoder and applies the self-attention mechanism to gather information from it.

The blog post Transformer: A Novel Neural Network Architecture for Language Understanding provides a good introduction to Transformers.

translational invariance

#изображение

In an image classification problem, an algorithm's ability to successfully classify images even when the position of objects within the image changes. For example, the algorithm can still identify a dog, whether it is in the center of the frame or at the left end of the frame.

See also size invariance and rotational invariance .

Триграмм

#seq
#язык

An N-gram in which N=3.

true negative (TN)

#основы

An example in which the model correctly predicts the negative class . For example, the model infers that a particular email message is not spam , and that email message really is not spam .

true positive (TP)

#основы

An example in which the model correctly predicts the positive class . For example, the model infers that a particular email message is spam, and that email message really is spam.

true positive rate (TPR)

#основы

Synonym for recall . То есть:

$$\text{true positive rate} = \frac{\text{true positives}} {\text{true positives} + \text{false negatives}}$$

True positive rate is the y-axis in an ROC curve .

ты

unawareness (to a sensitive attribute)

#справедливость

A situation in which sensitive attributes are present, but not included in the training data. Because sensitive attributes are often correlated with other attributes of one's data, a model trained with unawareness about a sensitive attribute could still have disparate impact with respect to that attribute, or violate other fairness constraints .

неподходящий

#основы

Producing a model with poor predictive ability because the model hasn't fully captured the complexity of the training data. Many problems can cause underfitting, including:

недостаточная выборка

Removing examples from the majority class in a class-imbalanced dataset in order to create a more balanced training set .

For example, consider a dataset in which the ratio of the majority class to the minority class is 20:1. To overcome this class imbalance, you could create a training set consisting of all of the minority class examples but only a tenth of the majority class examples, which would create a training-set class ratio of 2:1. Thanks to undersampling, this more balanced training set might produce a better model. Alternatively, this more balanced training set might contain insufficient examples to train an effective model.

Contrast with oversampling .

однонаправленный

#язык

A system that only evaluates the text that precedes a target section of text. In contrast, a bidirectional system evaluates both the text that precedes and follows a target section of text. See bidirectional for more details.

unidirectional language model

#язык

A language model that bases its probabilities only on the tokens appearing before , not after , the target token(s). Contrast with bidirectional language model .

unlabeled example

#основы

An example that contains features but no label . For example, the following table shows three unlabeled examples from a house valuation model, each with three features but no house value:

Количество спален Количество ванных комнат House age
3 2 15
2 1 72
4 2 34

In supervised machine learning , models train on labeled examples and make predictions on unlabeled examples .

In semi-supervised and unsupervised learning, unlabeled examples are used during training.

Contrast unlabeled example with labeled example .

unsupervised machine learning

#clustering
#fundamentals

Training a model to find patterns in a dataset, typically an unlabeled dataset.

The most common use of unsupervised machine learning is to cluster data into groups of similar examples. For example, an unsupervised machine learning algorithm can cluster songs based on various properties of the music. The resulting clusters can become an input to other machine learning algorithms (for example, to a music recommendation service). Clustering can help when useful labels are scarce or absent. For example, in domains such as anti-abuse and fraud, clusters can help humans better understand the data.

Contrast with supervised machine learning .

моделирование поднятия

A modeling technique, commonly used in marketing, that models the "causal effect" (also known as the "incremental impact") of a "treatment" on an "individual." Вот два примера:

  • Doctors might use uplift modeling to predict the mortality decrease (causal effect) of a medical procedure (treatment) depending on the age and medical history of a patient (individual).
  • Marketers might use uplift modeling to predict the increase in probability of a purchase (causal effect) due to an advertisement (treatment) on a person (individual).

Uplift modeling differs from classification or regression in that some labels (for example, half of the labels in binary treatments) are always missing in uplift modeling. For example, a patient can either receive or not receive a treatment; therefore, we can only observe whether the patient is going to heal or not heal in only one of these two situations (but never both). The main advantage of an uplift model is that it can generate predictions for the unobserved situation (the counterfactual) and use it to compute the causal effect.

upweighting

Applying a weight to the downsampled class equal to the factor by which you downsampled.

user matrix

#recsystems

In recommendation systems , an embedding vector generated by matrix factorization that holds latent signals about user preferences. Each row of the user matrix holds information about the relative strength of various latent signals for a single user. For example, consider a movie recommendation system. In this system, the latent signals in the user matrix might represent each user's interest in particular genres, or might be harder-to-interpret signals that involve complex interactions across multiple factors.

The user matrix has a column for each latent feature and a row for each user. That is, the user matrix has the same number of rows as the target matrix that is being factorized. For example, given a movie recommendation system for 1,000,000 users, the user matrix will have 1,000,000 rows.

В

Проверка

#основы

The initial evaluation of a model's quality. Validation checks the quality of a model's predictions against the validation set .

Because the validation set differs from the training set , validation helps guard against overfitting .

You might think of evaluating the model against the validation set as the first round of testing and evaluating the model against the test set as the second round of testing.

validation loss

#fundamentals

A metric representing a model's loss on the validation set during a particular iteration of training.

See also generalization curve .

набор проверки

#fundamentals

The subset of the dataset that performs initial evaluation against a trained model . Typically, you evaluate the trained model against the validation set several times before evaluating the model against the test set .

Traditionally, you divide the examples in the dataset into the following three distinct subsets:

Ideally, each example in the dataset should belong to only one of the preceding subsets. For example, a single example should not belong to both the training set and the validation set.

value imputation

The process of replacing a missing value with an acceptable substitute. When a value is missing, you can either discard the entire example or you can use value imputation to salvage the example.

For example, consider a dataset containing a temperature feature that is supposed to be recorded every hour. However, the temperature reading was unavailable for a particular hour. Here is a section of the dataset:

Временная метка Температура
1680561000 10
1680564600 12
1680568200 отсутствующий
1680571800 20
1680575400 21
1680579000 21

A system could either delete the missing example or impute the missing temperature as 12, 16, 18, or 20, depending on the imputation algorithm.

vanishing gradient problem

#seq

The tendency for the gradients of early hidden layers of some deep neural networks to become surprisingly flat (low). Increasingly lower gradients result in increasingly smaller changes to the weights on nodes in a deep neural network, leading to little or no learning. Models suffering from the vanishing gradient problem become difficult or impossible to train. Long Short-Term Memory cells address this issue.

Compare to exploding gradient problem .

variable importances

#df

A set of scores that indicates the relative importance of each feature to the model.

For example, consider a decision tree that estimates house prices. Suppose this decision tree uses three features: size, age, and style. If a set of variable importances for the three features are calculated to be {size=5.8, age=2.5, style=4.7}, then size is more important to the decision tree than age or style.

Different variable importance metrics exist, which can inform ML experts about different aspects of models.

variational autoencoder (VAE)

#язык

A type of autoencoder that leverages the discrepancy between inputs and outputs to generate modified versions of the inputs. Variational autoencoders are useful for generative AI .

VAEs are based on variational inference: a technique for estimating the parameters of a probability model.

Вт

Wasserstein loss

One of the loss functions commonly used in generative adversarial networks , based on the earth mover's distance between the distribution of generated data and real data.

масса

#fundamentals

A value that a model multiplies by another value. Training is the process of determining a model's ideal weights; inference is the process of using those learned weights to make predictions.

Weighted Alternating Least Squares (WALS)

#recsystems

An algorithm for minimizing the objective function during matrix factorization in recommendation systems , which allows a downweighting of the missing examples. WALS minimizes the weighted squared error between the original matrix and the reconstruction by alternating between fixing the row factorization and column factorization. Each of these optimizations can be solved by least squares convex optimization . For details, see the Recommendation Systems course .

weighted sum

#fundamentals

Сумма всех соответствующих входных значений, умноженная на их соответствующие веса. Например, предположим, что соответствующие входные данные состоят из следующего:

входное значение входной вес
2 -1,3
-1 0,6
3 0,4

Таким образом, взвешенная сумма равна:

weighted sum = (2)(-1.3) + (-1)(0.6) + (3)(0.4) = -2.0

A weighted sum is the input argument to an activation function .

широкая модель

Линейная модель, которая обычно имеет множество разреженных входных функций . Мы называем ее «широкой», поскольку такая модель представляет собой особый тип нейронной сети с большим количеством входов, которые подключаются напрямую к выходному узлу. Широкие модели часто легче отлаживать и проверять, чем глубокие модели . Хотя широкие модели не могут выражать нелинейности через скрытые слои , широкие модели могут использовать преобразования, такие как пересечение объектов и группирование, для моделирования нелинейностей различными способами.

Контраст с глубокой моделью .

ширина

Количество нейронов в определенном слое нейронной сети .

мудрость толпы

#df

Идея о том, что усреднение мнений или оценок большой группы людей («толпы») часто дает удивительно хорошие результаты. Например, рассмотрим игру, в которой люди угадывают количество жевательных конфет, упакованных в большую банку. Хотя большинство индивидуальных предположений будут неточными, эмпирически было показано, что среднее значение всех догадок удивительно близко к фактическому количеству мармеладных конфет в банке.

Ансамбли — это программный аналог мудрости толпы. Даже если отдельные модели дают крайне неточные прогнозы, усреднение прогнозов многих моделей часто дает удивительно хорошие прогнозы. Например, хотя отдельное дерево решений может давать плохие прогнозы, лес решений часто дает очень хорошие прогнозы.

встраивание слов

#язык

Представление каждого слова в наборе слов внутри вектора внедрения ; то есть представление каждого слова как вектора значений с плавающей запятой от 0,0 до 1,0. Слова со схожим значением имеют более схожие представления, чем слова с разными значениями. Например, морковь , сельдерей и огурцы будут иметь относительно схожие представления, которые будут сильно отличаться от изображений самолета , солнцезащитных очков и зубной пасты .

Икс

XLA (ускоренная линейная алгебра)

Компилятор машинного обучения с открытым исходным кодом для графических процессоров, процессоров и ускорителей машинного обучения.

Компилятор XLA берет модели из популярных платформ машинного обучения, таких как PyTorch , TensorFlow и JAX , и оптимизирует их для высокопроизводительного выполнения на различных аппаратных платформах, включая графические процессоры, центральные процессоры и ускорители машинного обучения.

З

обучение с нулевым выстрелом

Тип обучения машинному обучению , при котором модель делает прогноз для задачи, для которой она еще не была обучена. Другими словами, модели не предоставляются примеры обучения для конкретной задачи, но ее просят сделать вывод для этой задачи.

подсказка с нулевым выстрелом

#язык
#генеративныйИИ

Приглашение , не содержащее примера того, как должна реагировать большая языковая модель . Например:

Части одной подсказки Примечания
Какая официальная валюта указанной страны? Вопрос, на который вы хотите получить ответ от LLM.
Индия: Фактический запрос.

Модель большого языка может ответить любым из следующих действий:

  • Рупия
  • индийская рупия
  • Индийская рупия
  • рупия
  • Индийская рупия

Все ответы верны, хотя вы можете предпочесть определенный формат.

Сравните и сопоставьте подсказки «нулевого выстрела» со следующими терминами:

Нормализация Z-показателя

#fundamentals

Метод масштабирования , при котором необработанное значение признака заменяется значением с плавающей запятой, представляющим количество стандартных отклонений от среднего значения этого признака. Например, рассмотрим объект, среднее значение которого равно 800, а стандартное отклонение равно 100. В следующей таблице показано, как нормализация Z-показателя сопоставит необработанное значение с его Z-показателем:

Исходное значение Z-score
800 0
950 +1,5
575 -2,25

Затем модель машинного обучения обучается на Z-показателях этой функции, а не на необработанных значениях.