这几天需要扫AAAI的摘要及论文,但是一看AAAI每年有几百篇,我就傻眼了,加之本人有个习惯,善其事之前,总是喜欢利其器,于是花了个把小时写了个把AAAI的摘要爬出来并整理成一个html文件的程序。
#!/usr/bin/env python
# -*- coding: UTF-8 -*-
#
# Copyright 2011 Sigma  http://www.sigma.me.
#
#
#######usage#######
# $python
# >>>from get_abstract_aaai import *
# >>> get_allyear_abstract()
# or
# >>> get_allyear_pdf()
# DBLP_conf_link is like "http://www.informatik.uni-trier.de/~ley/db/conf/aaai/"
#  OR just modify the main function and then
# $python get_abstract_aaai.py
import os
import urllib
import urllib2
import httplib #for https link
import re
import socket
import locale,string
import codecs

title_regx=r'
([\\s\\S]+)
' author_regx=r'
([\\s\\S]+)
' abstract_regx=r'

Abstract

\ \
\ \
([\\s\\S]*)
\ \
\ \