Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
Tags
- Python
- 컨텍스트 매니져
- UDF
- 반복문
- 인자 힌트
- AI 동화
- Compute
- Azure
- Ai
- 퓨샷
- 파이썬
- GPT
- 검색
- 조건문
- 모험
- Cognitive Service
- 제로샷
- 도커
- 인컨텍스트 러닝
- 동화책
- FOR
- Docker
- 파라미터 힌트
- 프롬프트 튜닝
- 토끼
- 아기동화
- Cognitive Search
- Redshift
- 대스크
- dask
Archives
- Today
- Total
목록컨텍스트 매니져 (1)
호랭이 분석가

1. Decorator (데코레이터) Decorator는 다른 함수를 장식하거나 수정하는 함수입니다. Decorator는 함수를 인자로 받아서 새로운 함수를 반환합니다. 이를 사용하면 코드를 재사용하고, 로직을 캡슐화하고 기존 함수를 수정하지 않고도 행동을 추가하거나 변경할 수 있습니다. Decorator를 통해서 함수의 실행 시간을 측정해 보도록 하겠습니다. def timer(func) : def wrapper(*args, **kwargs) : start_time = time.time() result = func(*args, **kwargs) end_time = time.time() elapsed_time = end_time - start_time td = timedelta(seconds=elapsed..
Python
2023. 7. 23. 16:36