
python
文章平均质量分 69
yusisc
这个作者很懒,什么都没留下…
展开
-
conemu activates conda env while open new terminal
cmd.exe /k ""%ConEmuBaseDir%\CmdInit.cmd"" & conda activate tfgpu25原创 2021-08-11 14:15:08 · 221 阅读 · 0 评论 -
jupyter notebook works in vscode
I found that vscode is able to open jupyter notebooks directly, which i had been wishing for, early this year.This feature makes it’s easy to open a jupyter notebook as open a terminal, start jupyter server and work in browser.jupyter notebook runing in原创 2020-08-24 00:04:34 · 207 阅读 · 0 评论 -
Argparse简易教程
译者:likebeta本教程是对于Python标准库中推荐使用的命令行解析模块argparse的简单介绍。PS:还有其他两个模块实现这一功能,getopt(等同于C语言中的getopt())和弃用的optparse。因为argparse是基于optparse,所以用法很类似。概念让我们先用ls来展示这篇教程将要介绍的相关特性:$ lscpython转载 2017-11-21 11:20:16 · 269 阅读 · 0 评论 -
Python Save Data To File
Methods to save data save data load data np.save() np.load() np.savetxt() np.loadtxt() np.savez() np.load() aNumpyArray.tofile() np.fromfile() import pickle原创 2017-12-06 23:17:28 · 6084 阅读 · 0 评论 -
Python将汉字数字转换成阿拉伯数字的方法
refer from:http://www.iplaypy.com/code/base/b2600.htmlPython将汉字数字转换成阿拉伯数字的方法用Python语言来为不同数字之间做转换之前就有介绍过,今天分享的是用Python将汉字数字转换成阿拉伯数字的方法。汉字数字就是我们的大写数字:零、壹、贰、叁、肆、伍、陆、柒、捌、玖、拾,这种只有在会计人员才会常用的数字。转载 2017-12-06 23:19:08 · 12481 阅读 · 2 评论 -
jagged accuracy curve in tensorflow
What is f-string in pythonstep = 5test_accuracy = 0.77777print(f'step {step:05d}, test accuracy {test_accuracy}\n') # f-strings# It's more simple thanprint('step {:05d}, test accuracy {}\n'.fo...原创 2018-04-20 12:38:44 · 162 阅读 · 0 评论 -
The strategy to make a configuration object for your python project
dictionary easydict a class原创 2018-08-06 13:39:14 · 168 阅读 · 0 评论 -
nvidia errors in TensorFlow
Go to check GPU memory usage, when encountering nvidia or cuda error.I’ve been worked with tensorflow-gpu for a while. When run the codes, nvidia reports kinds of errors without clear instructio...原创 2018-08-02 17:47:45 · 177 阅读 · 0 评论 -
reinitialize parameters in keras
# Reset/Reinitialize model weights/parameters · Issue #341 · keras-team/keras# https://github.com/keras-team/keras/issues/341session = K.get_session()for layer in model.layers: for v in layer...转载 2018-08-21 00:01:19 · 369 阅读 · 0 评论 -
smooth a curve in images
This is from a post in stackoverflow.com . I make a copy here so that it’s easy to access.#!/usr/bin/env python3# -*- coding: utf-8 -*-# @Time : 2019-03-09 01_17_59 Sat# @Author : yusisc (yusi...转载 2019-03-09 01:22:44 · 407 阅读 · 0 评论 -
python 命令行参数解析 argparse简单分析
from: python 命令行参数解析 argparse简单分析 - 优快云博客 http://blog.youkuaiyun.com/it_way/article/details/44815141在python 2.7 后,不推荐使用 optparse, 而推荐使用 argparse.其它的不多说,简单的分析下我遇到的问题:我是想用 argparse 来解析不定长的命令行参数转载 2017-11-21 11:13:55 · 312 阅读 · 0 评论 -
How To Add Bookmark (mark) In Pycharm
When reading or editing a long code, you may want to add some bookmarks to the current file. For example you are amending原创 2017-11-20 14:30:56 · 599 阅读 · 0 评论 -
pycharm的一些快捷键
[转]pycharm的一些快捷键 - seven_clear - 博客园http://www.cnblogs.com/littleseven/p/5599019.html转载 2017-11-20 14:22:49 · 280 阅读 · 0 评论 -
make a copy of list in python
Methods to copy a list in pythonAs s freshman using python, It’s easy to be confused when copying a list. Here are some methods to make copy from originalList to targetList which are from the blog p原创 2017-10-07 12:19:21 · 642 阅读 · 0 评论 -
stuff list of python
pythontensorflow笔记 :常用函数说明 - Multiangle’s Notepad - 优快云博客 http://blog.youkuaiyun.com/u014595019/article/details/52805444 Python中的random模块 - Capricorn.python - 博客园 http://www.cnblogs.com/yd1227/archive/20原创 2017-10-23 11:14:10 · 353 阅读 · 0 评论 -
pycharm快捷键及一些常用设置
pycharm快捷键及一些常用设置 - 系统其他栏目 - 红黑联盟https://www.2cto.com/os/201410/341542.htmlpycharm快捷键及一些常用设置2014-10-09 09:31:07 0个评论 来源:pipisorry的专栏 收藏 我要投稿https://blog.csdn转载 2017-10-29 15:25:03 · 293 阅读 · 0 评论 -
论numpy中matrix 和 array的区别
论numpy中matrix 和 array的区别 - 优快云博客http://blog.youkuaiyun.com/vincentlipan/article/details/20717163 2014年03月07日 16:26:55Numpy matrices必须是2维的,但是 numpy arrays (ndarrays) 可以是多维的(1D,2D,3D····ND). Ma转载 2017-10-19 12:55:21 · 349 阅读 · 0 评论 -
distinguish "list" & "array" in python
It seems array is a subconcept of numpy package. list & array are with some different properties. The most apparent difference show as follow.import numpy as nplist1 = [1, 2]list2 = [3,4]type原创 2017-10-19 12:45:08 · 249 阅读 · 0 评论 -
Python Logging Module
Main stufflogger, handler, formatter.How it works ref: How Python logging module works | Shut Up and Ship http://zqpythonic.qiniucdn.com/data/20161124153540/index.htmlSimple example原创 2017-11-20 14:18:29 · 348 阅读 · 0 评论 -
Python File Processing
Get your hand dirtytitle = 'aaa'with open('%s.txt' % (title,),'a') as f: f.write('---------**-----------\n') for i in range(10): f.write(str(i) + '\n') f.write('%%%%%%%%%%原创 2017-11-20 14:19:16 · 678 阅读 · 0 评论 -
Multithreading in Python
The package for multithreadingThe package threading is for multithreaded programming in python. To get it ready to use, one should import it. As:import threadingGet your hand dirtyimport t原创 2017-11-20 14:19:48 · 350 阅读 · 0 评论 -
GIT BASH IN INTELLIJ IDEA 13 ON WINDOWS One of the top features of the recent release of IntelliJ ID
GIT BASH IN INTELLIJ IDEA 13 ON WINDOWSOne of the top features of the recent release of IntelliJ IDEA 13 is definitively a built-in command-line interface. For me, this is really great feature转载 2017-11-20 14:20:36 · 227 阅读 · 0 评论