MLops
패스트캠퍼스 챌린지 38일차
Laftel
2022. 3. 2. 22:27
반응형
- Local 에서 Feast Server 실행하기
- Server 실행
pip install feast
feast init feature_repo
cd feature_repo
feast apply
feast materialize-incremental $(date +%Y-%m-%d)
feast serve
"""
feast.errors.ExperimentalFeatureNotEnabled:
You are attempting to use an experimental feature that is not enabled.
Please run `feast alpha enable python_feature_server`
"""
curl 을 이용해 Query 실행
curl -X POST \
"http://localhost:6566/get-online-features" \
-d '{
"features": [
"driver_hourly_stats:conv_rate",
"driver_hourly_stats:acc_rate",
"driver_hourly_stats:avg_daily_trips"
],
"entities": {
"driver_id": [1001, 1002, 1003]
}
}'
Docker Container 로 Feast Server 실행하기
Build the docker image
mkdir -p docker
cd docker
sudo vim requirements.txt
requirement.txt 생성
# requirement.txt
feast
scikit-learn
mlflow
Dockerfile 생성
- syntax=[원격 저장소의 이미지 레퍼런스]
# syntax=docker/dockerfile:1
FROM jupyter/base-notebook
WORKDIR /home/jovyan
COPY . /home/jovyan
RUN pip3 install -r requirements.txt
USER jovyan
RUN feast init feature_repo && \
cd feature_repo && \
feast apply && \
feast materialize-incremental $(date +%Y-%m-%d) && \
feast alpha enable python_feature_server
COPY feature_server.py /opt/conda/lib/python3.9/site-packages/feast/feature_server.py
CMD [ "/bin/sh", "-c", "cd /home/jovyan/feature_repo && feast serve"]
WORKDIR /home/jovyan
#직장인인강 #직장인자기계발 #패스트캠퍼스후기#온라인패키지:머신러닝서비스구축을위한실전MLOps#머신러닝서비스구축을위한실전MLOps온라인패키지Online.
https://bit.ly/37BpXiC
패스트캠퍼스 [직장인 실무교육]
프로그래밍, 영상편집, UX/UI, 마케팅, 데이터 분석, 엑셀강의, The RED, 국비지원, 기업교육, 서비스 제공.
fastcampus.co.kr
본 포스팅은 패스트캠퍼스 환급 챌린지 참여를 위해 작성되었습니다.
반응형