# TensorFlow & Keras (Data Science & ML) > Sequential API, Functional API, layers, callbacks, checkpoints, TensorBoard, 모델 저장 - 22 면접 질문 - Senior - [면접 질문: Data Science & ML](https://sharpskill.dev/ko/technologies/data-science/interview-questions.md) ## 1. Keras Sequential API와 Functional API의 주요 차이점은 무엇입니까? **답변** Sequential API는 각 layer가 정확히 하나의 입력과 하나의 출력을 갖는 선형 방식으로 모델을 생성할 수 있습니다. Functional API는 다중 입력, 다중 출력, residual connections, 공유 layer 그래프와 같은 복잡한 아키텍처를 가능하게 하여 더 큰 유연성을 제공합니다. 단순한 아키텍처에는 Sequential을, 더 고급 사례에는 Functional을 사용하세요. ## 2. 64개 뉴런의 Dense layer 다음에 10개 뉴런의 출력 layer가 있는 Sequential 모델을 어떻게 생성합니까? **답변** 표준 방법은 tf.keras.Sequential()을 인스턴스화한 후 model.add()를 사용하여 layer를 하나씩 추가하거나, layer 리스트를 생성자에 직접 전달하는 것입니다. 각 Dense layer는 units 수를 매개변수로 받으며, 첫 번째 layer는 입력 데이터 형태를 정의하기 위해 input_shape을 지정해야 합니다. ## 3. 출력 layer에서 'softmax' 활성화 함수의 역할은 무엇입니까? **답변** softmax 함수는 logits(원시 출력)를 합이 1이 되는 확률로 변환하며, 이는 다중 클래스 분류에 이상적입니다. 각 출력은 클래스에 속할 확률을 나타냅니다. 일반적으로 one-hot 라벨에는 categorical_crossentropy loss와 함께, 정수 라벨에는 sparse_categorical_crossentropy와 함께 사용됩니다. ## 19개 추가 질문 이용 가능 - Functional API로 두 개의 서로 다른 입력을 가진 모델을 어떻게 정의합니까? - validation loss가 더 이상 개선되지 않을 때 학습을 중지하기 위해 어떤 callback을 사용합니까? 무료로 가입하기: https://sharpskill.dev/ko/login ## 기타 Data Science & ML 면접 주제 - [Python 기초](https://sharpskill.dev/ko/technologies/data-science/interview-questions/python-basics.md): 25개 질문, Junior - [Python 객체 지향 프로그래밍](https://sharpskill.dev/ko/technologies/data-science/interview-questions/python-oop.md): 20개 질문, Junior - [Python 데이터 구조](https://sharpskill.dev/ko/technologies/data-science/interview-questions/python-data-structures.md): 20개 질문, Junior - [Git 기초](https://sharpskill.dev/ko/technologies/data-science/interview-questions/git-fundamentals.md): 18개 질문, Junior - [SQL 기초](https://sharpskill.dev/ko/technologies/data-science/interview-questions/sql-basics.md): 20개 질문, Junior - [NumPy 기초](https://sharpskill.dev/ko/technologies/data-science/interview-questions/numpy-fundamentals.md): 22개 질문, Junior - [Pandas 기초](https://sharpskill.dev/ko/technologies/data-science/interview-questions/pandas-basics.md): 22개 질문, Junior - [Jupyter & Google Colab](https://sharpskill.dev/ko/technologies/data-science/interview-questions/jupyter-colab.md): 16개 질문, Junior - [SQL Joins 및 고급 쿼리](https://sharpskill.dev/ko/technologies/data-science/interview-questions/sql-joins-advanced.md): 22개 질문, Mid-Level - [Pandas 고급](https://sharpskill.dev/ko/technologies/data-science/interview-questions/pandas-advanced.md): 24개 질문, Mid-Level - [Matplotlib & Seaborn을 활용한 시각화](https://sharpskill.dev/ko/technologies/data-science/interview-questions/matplotlib-seaborn.md): 20개 질문, Mid-Level - [Plotly로 만드는 인터랙티브 시각화](https://sharpskill.dev/ko/technologies/data-science/interview-questions/plotly-interactive.md): 18개 질문, Mid-Level - [기술 통계](https://sharpskill.dev/ko/technologies/data-science/interview-questions/statistics-descriptive.md): 20개 질문, Mid-Level - [추론 통계학](https://sharpskill.dev/ko/technologies/data-science/interview-questions/statistics-inferential.md): 24개 질문, Mid-Level - [Web Scraping](https://sharpskill.dev/ko/technologies/data-science/interview-questions/web-scraping.md): 18개 질문, Mid-Level - [BigQuery & Cloud Data](https://sharpskill.dev/ko/technologies/data-science/interview-questions/bigquery-cloud.md): 18개 질문, Mid-Level - [Feature Engineering](https://sharpskill.dev/ko/technologies/data-science/interview-questions/feature-engineering.md): 22개 질문, Mid-Level - [지도 머신러닝: 회귀](https://sharpskill.dev/ko/technologies/data-science/interview-questions/ml-supervised-regression.md): 24개 질문, Mid-Level - [지도 머신러닝: 분류](https://sharpskill.dev/ko/technologies/data-science/interview-questions/ml-supervised-classification.md): 24개 질문, Mid-Level - [결정 트리 및 앙상블](https://sharpskill.dev/ko/technologies/data-science/interview-questions/ml-trees-ensembles.md): 24개 질문, Mid-Level - [비지도 ML](https://sharpskill.dev/ko/technologies/data-science/interview-questions/ml-unsupervised.md): 22개 질문, Mid-Level - [ML 파이프라인 및 검증](https://sharpskill.dev/ko/technologies/data-science/interview-questions/ml-pipelines-validation.md): 22개 질문, Mid-Level - [시계열 및 예측](https://sharpskill.dev/ko/technologies/data-science/interview-questions/time-series-forecasting.md): 22개 질문, Mid-Level - [Deep Learning 기초](https://sharpskill.dev/ko/technologies/data-science/interview-questions/deep-learning-fundamentals.md): 24개 질문, Senior - [CNN 및 이미지 분류](https://sharpskill.dev/ko/technologies/data-science/interview-questions/cnn-image-classification.md): 24개 질문, Senior - [RNN 및 시퀀스](https://sharpskill.dev/ko/technologies/data-science/interview-questions/rnn-sequences.md): 22개 질문, Senior - [Transformers 및 Attention](https://sharpskill.dev/ko/technologies/data-science/interview-questions/transformers-attention.md): 24개 질문, Senior - [NLP 및 Hugging Face](https://sharpskill.dev/ko/technologies/data-science/interview-questions/nlp-huggingface.md): 24개 질문, Senior - [GenAI 및 LangChain](https://sharpskill.dev/ko/technologies/data-science/interview-questions/genai-langchain.md): 24개 질문, Senior - [MLOps 및 배포](https://sharpskill.dev/ko/technologies/data-science/interview-questions/mlops-deployment.md): 24개 질문, Senior --- Source: SharpSkill (https://sharpskill.dev), tech interview preparation for your real stack. HTML version of this page: https://sharpskill.dev/ko/technologies/data-science/interview-questions/tensorflow-keras