이 페이지에서는 Vertex AI와 함께 제공되는 특성 기여 분석 메서드의 개념을 간략히 설명합니다. 자세한 기술 논의는 AI Explanations 백서를 참조하세요.
전역 특성 중요도 (모델 특성 기여 분석)는 각 특성이 모델에 미치는 영향을 보여줍니다. 이 값은 각 특성의 백분율로 제공됩니다. 백분율이 높을수록 특성이 모델 학습에 더 큰 영향을 미칩니다. 모델의 전역 특성 중요도를 보려면 평가 측정항목을 조사합니다.
시계열 모델의 로컬 특성 기여 분석은 데이터의 각 특성이 예상된 결과에 미치는 영향을 나타냅니다. 이 정보를 활용하여 모델이 예상대로 작동하는지 확인하고, 모델의 편향을 인식하고, 모델 및 학습 데이터를 개선할 수 있는 방법에 대한 아이디어를 얻을 수 있습니다. 추론을 요청하면 예측 값이 모델에 적절하게 표시됩니다. 설명을 요청하면 특성 기여 분석 정보와 함께 추론이 표시됩니다.
다음 예시를 살펴보겠습니다. 심층신경망은 날씨 데이터와 이전의 차량 공유 데이터를 기반으로 자전거 주행 시간을 예측하도록 학습됩니다.
이 모델에서 추론만 요청하면 예상 자전거 주행 시간이 분 단위로 표시됩니다. 설명을 요청하면 설명 요청의 각 특성에 대한 기여 분석 점수와 함께 자전거 여행 예상 시간이 표시됩니다. 기여 분석 점수는 지정한 기준 값을 기준으로 특성이 추론 값의 변경에 얼마나 영향을 주었는지 표시합니다. 모델에 적합한 의미 있는 기준을 선택합니다. 이 경우 자전거 주행 시간의 중앙값입니다.
특성 기여 점수를 플롯으로 나타내어 결과 추론에 가장 많이 기여한 특성을 확인할 수 있습니다.
온라인 추론 작업 또는 일괄 추론 작업을 수행할 때 로컬 특성 기여 분석을 생성하고 쿼리할 수 있습니다.
장점
특정 인스턴스를 검사하고 학습 데이터세트 전체에서 특성 기여 분석을 집계하면 모델 작동 방식에 대해 더 자세히 파악할 수 있습니다. 다음과 같은 장점이 있습니다.
디버깅 모델: 특성 기여 분석은 표준 모델 평가 기술이 일반적으로 놓칠 수 있는 데이터 문제를 감지하는 데 도움이 됩니다.
모델 최적화: 덜 중요한 특성을 식별하고 제거하여 모델의 효율성을 높일 수 있습니다.
개념적 제한사항
특성 기여 분석의 제한사항을 고려하세요.
AutoML의 로컬 특성 중요도를 포함하여 특성 기여 분석은 개별 추론에 따라 달라집니다.
개별 추론에 대한 특성 기여도를 검사하면 우수한 통계를 얻을 수 있지만 그러한 통계를 개별 인스턴스의 전체 클래스 또는 전체 모델에 일반화할 수는 없습니다.
AutoML 모델에 대해 보다 일반화 가능한 통계를 얻으려면 모델 특성 중요도를 참조하세요. 다른 모델에 대해 보다 일반화 가능한 통계를 얻으려면 데이터 세트의 하위 집합 또는 전체 데이터 세트에 대해 기여 분석을 집계합니다.
각 기여 분석은 특정 예시에 대해 특성이 추론에 영향을 미친 정도를 나타냅니다. 단일 기여 분석은 모델의 전체 동작을 반영하지 않을 수 있습니다. 전체 데이터세트의 전반적인 모델 동작을 이해하려면 전체 데이트세트에 대한 기여 분석을 집계하세요.
특성 기여 분석이 모델 디버깅에 도움이 될 수 있지만 문제가 모델에서 발생했는지 또는 모델이 학습된 데이터에서 발생했는지 항상 명확하게 나타내는 것은 아닙니다. 최선의 판단을 내리고 일반적인 데이터 문제를 진단하여 잠재적 원인의 범위를 좁혀야 합니다.
기여 분석은 모델을 학습시키는 데 사용되는 모델 및 데이터에 전적으로 의존합니다.
이러한 값은 모델이 데이터에서 찾아내는 패턴에는 영향을 미치지만 데이터에서 근본적인 관계를 밝히지는 못합니다. 특정한 특성에 대한 강력한 기여 분석이 존재하는지 여부가 해당 특성과 타겟 간에 관계가 있는지 여부를 의미하지 않습니다. 기여 분석은 모델이 추론에 특성을 사용 중인지 여부만 나타냅니다.
기여 분석만으로는 모델이 공평하고 편향되지 않으며 품질을 신뢰할 수 있는지 여부를 알 수 없습니다. 기여 분석 외에 학습 데이터 및 평가 측정항목을 신중하게 평가해야 합니다.
기여 분석 방법은 Shapley 값의 근사치를 계산합니다. 샘플링된 Shapley 메서드의 경로 수를 늘려 근사치의 정밀도를 개선할 수 있습니다. 결과적으로 기여 분석 결과가 크게 달라질 수 있습니다.
기여 분석은 기준 값을 기준으로 특성이 추론 값의 변경에 얼마나 영향을 주었는지만 표시합니다. 모델에 물어보려는 질문과 관련된 의미 있는 기준을 선택해야 합니다.
기준 값을 전환하면 기여 분석 값과 그 해석이 크게 변경될 수 있습니다.
알고리즘
Vertex AI는 특정 출력에 대해 한 게임의 각 플레이어에 크레딧을 할당하는 협력 게임 이론 알고리즘인 Shapley 값을 사용하여 특정 기여 분석을 제공합니다. 머신러닝 모델에 적용하면 각 모델 특성이 게임에서 '플레이어'로 취급되고 크레딧이 특정 추론의 결과에 비례해서 할당됩니다. 구조화된 데이터 모델의 경우 Vertex AI는 샘플링된 Shapley라는 정확한 Shapley 값의 샘플링 근사값을 사용합니다.
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["이해하기 어려움","hardToUnderstand","thumb-down"],["잘못된 정보 또는 샘플 코드","incorrectInformationOrSampleCode","thumb-down"],["필요한 정보/샘플이 없음","missingTheInformationSamplesINeed","thumb-down"],["번역 문제","translationIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2025-09-04(UTC)"],[],[],null,["# Feature attributions for classification and regression\n\nIntroduction\n------------\n\n\nThis page provides a brief conceptual overview of the feature attribution\nmethods available with Vertex AI. For an in-depth technical\ndiscussion, see our [AI Explanations Whitepaper](https://storage.googleapis.com/cloud-ai-whitepapers/AI%20Explainability%20Whitepaper.pdf).\n\n\u003cbr /\u003e\n\nGlobal feature importance (model feature attributions) shows how each\nfeature impacts a model. The values are a percentage for each\nfeature: the higher the percentage, the more impact the feature had on model\ntraining. To view the global feature importance for your model, examine the\n[evaluation metrics](/vertex-ai/docs/tabular-data/classification-regression/evaluate-model).\n\nLocal feature attributions for time series models indicate how much each feature\nin the data contributed to the predicted result. Use this\ninformation to verify that the model behaves as expected, recognize bias in\nyour models, and get ideas for ways to improve your model and your training\ndata. When you request inferences, you\nget predicted values as appropriate for your model. When you request\n*explanations*, you get the inferences along with feature attribution\ninformation.\n\nConsider the following example: A deep neural network is trained to predict the\nduration of a bike ride, based on weather data and previous ride-sharing data.\nIf you request only inferences from this model, you get predicted durations of\nbike rides in number of minutes. If you request *explanations*, you get the\npredicted bike trip duration, along with an attribution score for each feature\nin your explanations request. The attribution scores show how much the feature\naffected the change in inference value, relative to the baseline value that\nyou specify. Choose a meaningful baseline that makes sense for your model -\nin this case, the median bike ride duration.\n\nYou can plot the feature attribution scores to see which features contributed\nmost strongly to the resulting inference:\n\nGenerate and query local feature attributions when performing an\n[online inference](/vertex-ai/docs/tabular-data/classification-regression/get-online-predictions)\njob or a [batch inference](/vertex-ai/docs/tabular-data/classification-regression/get-batch-predictions)\njob.\n\nAdvantages\n----------\n\n\nIf you inspect specific instances, and also aggregate feature attributions\nacross your training dataset, you can get deeper insight into how your model\nworks. Consider the following advantages:\n\n- **Debugging models**: Feature attributions can help detect issues in the data\n that standard model evaluation techniques would usually miss.\n\n- **Optimizing models**: You can identify and remove features that are less\n important, which can result in more efficient models.\n\n\u003cbr /\u003e\n\nConceptual limitations\n----------------------\n\n\nConsider the following limitations of feature attributions:\n\n- Feature attributions, including local feature importance for AutoML, are\n specific to individual inferences.\n Inspecting the feature attributions for an individual inference may provide\n good insight, but the insight may not be generalizable to the entire class for\n that individual instance, or the entire model.\n\n To get more generalizable insight for AutoML models, refer to the model\n feature importance. To get more generalizable insight for other models,\n aggregate attributions over subsets over your dataset, or the entire dataset.\n- Each attribution only shows how much the feature affected the inference for\n that particular example. A single attribution might not reflect the overall\n behavior of the model. To understand approximate model behavior on an entire\n dataset, aggregate attributions over the entire dataset.\n\n- Although feature attributions can help with model debugging, they don't\n always indicate clearly whether an issue arises from the model or from the\n data that the model is trained on. Use your best judgment, and diagnose common\n data issues to narrow the space of potential causes.\n\n- The attributions depend entirely on the model and data used to train the model.\n They can only reveal the patterns the model found in the data, and can't\n detect any fundamental relationships in the data. The presence or absence of a\n strong attribution to a certain feature doesn't mean there is or is not a\n relationship between that feature and the target. The attribution merely shows\n that the model is or is not using the feature in its inferences.\n\n- Attributions alone cannot tell if your model is fair, unbiased, or of sound\n quality. Carefully evaluate your training data and evaluation metrics in\n addition to the attributions.\n\nFor more information about limitations, see the\n[AI Explanations Whitepaper](https://storage.googleapis.com/cloud-ai-whitepapers/AI%20Explainability%20Whitepaper.pdf).\n\n\u003cbr /\u003e\n\nImproving feature attributions\n------------------------------\n\n\nThe following factors have the highest impact on feature attributions:\n\n- The attribution methods approximate the Shapley value. You can increase the precision of the approximation by increasing the number of paths for the sampled Shapley method. As a result, the attributions could change dramatically.\n- The attributions only express how much the feature affected the change in inference value, relative to the baseline value. Be sure to choose a meaningful baseline, relevant to the question you're asking of the model. Attribution values and their interpretation might change significantly as you switch baselines.\n\n\u003cbr /\u003e\n\nAlgorithm\n---------\n\n\nVertex AI provides feature attributions using *Shapley Values* , a cooperative\ngame theory algorithm that assigns credit to each player in a game for a\nparticular outcome. Applied to machine learning models, this means that each\nmodel feature is treated as a \"player\" in the game and credit is assigned in\nproportion to the outcome of a particular inference. For structured data\nmodels, Vertex AI uses a sampling approximation of exact Shapley Values called\n*Sampled Shapley*.\n\nFor in-depth information about how the sampled Shapley method works, read the paper\n[Bounding the Estimation Error of Sampling-based Shapley Value Approximation](https://arxiv.org/abs/1306.4265).\n\n\u003cbr /\u003e\n\nWhat's next\n-----------\n\n\nThe following resources provide further useful educational material:\n\n- [Interpretable Machine Learning: Shapley values](https://christophm.github.io/interpretable-ml-book/shapley.html)\n- [Introduction to Shapley values](https://www.kaggle.com/dansbecker/shap-values#Introduction)\n\n\u003cbr /\u003e"]]