Skip to content

Instantly share code, notes, and snippets.

View gwentmaster's full-sized avatar

gwentmaster gwentmaster

View GitHub Profile
components:
schemas:
definitions:
info:
title: 平台Python服务接口文档
version: v1
openapi: 3.0.2
paths:
# mpc日志
@gwentmaster
gwentmaster / hh.py
Created November 23, 2022 08:43
子进程与父进程队列初始化
# -*- coding: utf-8 -*-
import os
import time
from multiprocessing import Process, Queue
queue = Queue()
@gwentmaster
gwentmaster / test.py
Created May 27, 2021 02:59
多进程使用tensorflow导致子进程被挂起
# -*- coding: utf-8 -*-
import multiprocessing
import tensorflow as tf
def test():
@gwentmaster
gwentmaster / test.py
Last active March 12, 2021 02:03
异步上下文切换导致数据库会话异常
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# @Date : 2020-08-27 10:55:49
# @Author : gwentmaster(1950251906@qq.com)
# I regret in my life
import asyncio
from contextlib import contextmanager