Giter Site home page Giter Site logo

clean-python's Introduction

  1. 재사용 가능한 @property 메서드를 만들려면 디스크립터를 사용하라.
    1. 키워드: __dict__, __set__, __get__
    2. 용어: 클래스 애트리뷰트, 인스턴스 애트리뷰트
  2. 지연 계산 애트리뷰트가 필요하면 __getattr__, __getattribute__, __setattr__ 을 사용하라.
    1. 키워드: __dict__
    2. 용어: 훅(hook), 오브젝트 훅
    3. 용어: 인스턴스 애트리뷰트 딕셔너리
  3. 메타클래스 대신 __init_subclass__ 를 사용해 하위 클래스를 검증하라.
  4. __init_subclass__ 를 이용해 클래스를 자동으로 등록하라.
    1. 용어: 클래스 등록
    2. 용어: 클래스 등록 패턴
    3. 용어: 직렬화, 역직렬화
  5. __set_name__ 으로 클래스 애트리뷰트를 표시하라.
  6. 클래스를 합성하고자 하거나, 모든 메서드에 대한 일괄 데코레이팅이 필요하면 클래스 데코레이터를 고려하라.
    1. 용어: 클래스 합성
    2. 용어: 클래스 데코레이터
  7. 병렬적으로 자식 프로세스를 실행하고 관리하기 위해 subprocess를 사용하라.
    1. 용어: 동시성, 병렬성
  8. skip
  9. 스레드에서 데이터 경합을 피하기 위해 Lock을 사용하라.
    1. 키워드: 블로킹 I/O
  10. 스레드 사이의 작업을 조율하기 위해 Queue를 사용하라.
    1. 용어: 기아(starvation) 상태
    2. 용어: 생성자-소비자 큐
    3. 용어: 바쁜 대기(busy waiting)
    4. 용어: 폴링(polling)
    5. 키워드: 이터레이터 프로토콜, iter, __iter__
  11. 생명 게임 베이스코드
    1. 용어: 팬인(fan-in)
    2. 용어: 팬아웃(fan-out)
  12. 높은 동시성이 요구될 때 스레드를 계속 생성하면 어떤 문제가 일어나는지 알아라.
    1. 키워드: 높은 (블로킹 I/O)동시성
    2. 키워드: 스레드와 예외처리
    3. 키워드: 트레이스
    4. 키워드: sys.stderr
  13. Queue 를 이용하여 리팩토링하는 방법을 알고, 어떤 장단점이 있는지 기억해두어라.
  14. 스레드가 필요한 경우에는 ThreadPoolExecutor를 사용하라.
    1. 키워드: future.submit, future.result
  15. 스레드 대신 코루틴을 사용하는 것도 방법이다.
    1. 용어: 코루틴(coroutine)
    2. 용어: 이벤트 루프
    3. 키워드: asyncio, await, coroutine.gather

skip ...

  1. 프로그램이 메모리를 사용하는 방식과 누수를 이해하기 위해 tracemalloc을 사용하라.
    1. 용어: 참조, 참조 카운팅
    2. 용어: 스택 트레이스(stack trace)

clean-python's People

Contributors

protossdragoon avatar

Stargazers

 avatar Hyeonsu,Ryu avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.