自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

蛋酥沙琪玛

一块很香的沙琪玛

  • 博客(16)
  • 收藏
  • 关注

转载 hmm lda data requirement

WS a 1 x N vector where WS(k) contains the vocabulary index of the kth word token, and N is the number of word tokens. The word indices are not zero based, i.e., min( WS)=1 and max( WS ) = W = numbe

2015-04-07 16:13:04 914

原创 python page rank

#-*- coding:utf-8 -*-import sysimport reimport numpyas npimport scipy.ioimport mathreload(sys)sys.setdefaultencoding('utf-8')class page_rank(object):

2015-04-07 16:07:17 806

转载 urllib 与 urllib2 区别

urllib and  urllib2are both Python modules that do URL request related stuff but offer different functionalities. Their two most significant differences are listed below: urllib 和urllib2都是接受URL请

2015-01-24 08:15:31 566

转载 django mysql phpmyadmin nginx 配置

1. 使用官方PPA安装 Nginx 最新版本,使用以下命令:sudo add-apt-repository ppa:nginx/stablesudo apt-get updatesudo apt-get install nginxNginx相关控制命令:启动 Nginx:sudo /etc/init.d/nginx start浏览器浏览运行情况输入:http://lo

2014-04-25 11:57:25 1069

转载 Highcharts选项配置详细说明文档

Highcharts选项配置详细说明文档Chart:图表区选项Chart图表区选项用于设置图表区相关属性。参数 描述 默认值backgroundColor 设置图表区背景色 #FFFFFFborderWidth 设置图表边框宽度   0borderRadius 设置图表边框圆角角度   5renderTo    图表放置的容器,一般在html中放置一个DIV,   

2014-04-24 11:28:39 805

原创 分享技巧-工具(不定期更新)

vimtutor

2014-04-14 19:31:54 820

原创 Ubuntu Android开发环境配置

1.sun jdk 1.6安装java运行环境,sun-jdk,安装方式请上网找谷歌,这里使用sun-jdk。请注意,使用1.6版。

2014-04-14 19:23:00 718

翻译 如何在django查看一个group里的所有user

from django.contrib.auth.models import User, Group

2014-04-14 16:33:12 5716

原创 format html floatformat django python

开发python项目时,使用django框架,前台的数值有时需要format, 每3位加逗号之类的。只需要以下两行就搞定{% load humanize %}{{ value|floatformat:1|intcomma }}

2014-04-01 10:22:32 1641

原创 django python html checkbox

当我们在开发网页的时候,如果数据大于10的都不能用下拉选择方式显示, 而要转为多选的方式。这是html页面的checkbox表单{% for item in item_list %}<input name="aaa" type="checkbox" value="{{ item }}" {% for it in item_list %}{% ifequal it item %}

2014-03-31 17:35:47 1440

原创 django 中使用ajax 检查后台数据

在django中,很多数据是需要即时判断的或者自动填表,就需要使用ajax。后台:p

2014-03-31 14:51:54 1412

原创 spf13安装

安装SPF13不用翻墙,代理的方法。不知道为什么装spf13的插件需要写入命令行:sh 装插件失败后,需要用ll查看root主目录下的插件文件,吧配置文件给删除如果外国服务器被封的话,需要用以下办法git clone git://github.com/spf13/spf13-vim.gitcd spf13-vimsh bootstrap.sh

2014-03-30 21:04:00 2388

原创 beautifulsoup 简单使用

直接上码,抓的是安智市场的数据#-*-coding:utf-8-*-from bs4 import BeautifulSoupimport urllibimport reimport xlwti = 1data = xlwt.Workbook()sheet = data.add_sheet(“sheet 1″)row = 0while i path =

2014-03-04 11:20:31 1051

原创 Ubuntu中gvim中文输入法ibus无法使用的问题

用gvim得时候发现ibus无法输入中文,切换到中文输入法时,输入无候选项,会自动把拼音切换到英文解决放法:在输入法的首选项中,把 “在应用程序窗口中启用内嵌编辑模式” 前面的勾去掉。

2014-03-04 11:18:31 1207

原创 python dictionary list

python dictionary 的使用新建空的dictionary :dict = {}建立dict的键值:dict['key'] = 'value'如果key值存在则覆盖,如果key值不存在则添加查找key是否存在用 key in or not in dict如果存在返回 true获取key的所对应的value则用dict['key'] = value

2014-02-12 11:55:47 991

原创 git 使用

现在很多人都用gitlab存放代码,如何将代码clone到本地需要用到命令行 ssh-keygen然后不用输出任何命令,按enter把存放好的在.ssh/id_rsa.pub 用cat命令显示在终端,然后将字段复制到gitlab的ssh_key 中git branch XX : 新建一个分支git branch  :查看所在分支git checkout XX :

2014-01-20 20:28:58 807

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除