일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
29 | 30 |
Tags
- Container
- enV
- TORCH
- Paper
- format
- CUDA
- list
- pytorch
- evaluation
- Flask
- PostgreSQL
- Windows
- numpy
- GitLab
- docker
- Python
- judge
- Converting
- KAKAO
- LLM
- git
- Laravel
- DB
- Mac
- file
- Database
- Package
- Linux
- pandas
- AI
Archives
- Today
- Total
목록binary (1)
Daily Develope
[Python] Pickle library (object serialization)
Pickle이란? Python의 객체(Object)를 binary 파일로 serializing 하거나 반대로 binray 파일로부터 de-serializing 하기 위한 프로토콜이 구현된 라이브러리. 흔히 pickling, flattening, marshalling 등으로 일컫는다. 장점? Python 객체를 바로 파일로 쓰거나 읽을 수 있다. Binary(또는 Bytes) 형태로 데이터를 다루기 때문에 읽기/쓰기 속도가 빠르다. 읽기/쓰기 예시코드 import pickle import os my_filepath = "target/file/path/filename.bin" my_data = ['target', 'data'] if os.path.isfile(my_filepath): ### 읽기 with o..
Develope/Python
2023. 10. 17. 14:37