Skip to content

Instantly share code, notes, and snippets.

@ericdill
Created July 15, 2017 16:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ericdill/c75b798e1aef8421fe1d261dac2551f4 to your computer and use it in GitHub Desktop.
Save ericdill/c75b798e1aef8421fe1d261dac2551f4 to your computer and use it in GitHub Desktop.
{
"cells": [
{
"cell_type": "code",
"execution_count": 45,
"metadata": {},
"outputs": [],
"source": [
"import pandas as pd\n",
"import fnmatch"
]
},
{
"cell_type": "code",
"execution_count": 2,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"README.md find_compiled.py osx-64.csv\r\n",
"Untitled.ipynb linux-64.csv win-64.csv\r\n"
]
}
],
"source": [
"ls"
]
},
{
"cell_type": "code",
"execution_count": 83,
"metadata": {
"collapsed": true
},
"outputs": [],
"source": [
"linux = pd.read_csv('linux-64.csv')"
]
},
{
"cell_type": "code",
"execution_count": 84,
"metadata": {
"collapsed": true
},
"outputs": [],
"source": [
"del linux['Unnamed: 0']"
]
},
{
"cell_type": "code",
"execution_count": 85,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div>\n",
"<style>\n",
" .dataframe thead tr:only-child th {\n",
" text-align: right;\n",
" }\n",
"\n",
" .dataframe thead th {\n",
" text-align: left;\n",
" }\n",
"\n",
" .dataframe tbody tr th {\n",
" vertical-align: top;\n",
" }\n",
"</style>\n",
"<table border=\"1\" class=\"dataframe\">\n",
" <thead>\n",
" <tr style=\"text-align: right;\">\n",
" <th></th>\n",
" <th>ext</th>\n",
" <th>name</th>\n",
" </tr>\n",
" </thead>\n",
" <tbody>\n",
" <tr>\n",
" <th>0</th>\n",
" <td>{'', '.txt', '.py', '.rendered', '.pyc', '.jso...</td>\n",
" <td>pytest-cookies-0.2.0-py34_0.tar.bz2</td>\n",
" </tr>\n",
" <tr>\n",
" <th>1</th>\n",
" <td>{'', '.txt', '.py', '.rendered', '.pyc', '.egg...</td>\n",
" <td>permission-0.4.1-py27_0.tar.bz2</td>\n",
" </tr>\n",
" <tr>\n",
" <th>2</th>\n",
" <td>{'', '.txt', '.py', '.1', '.pyc', '.egg-info',...</td>\n",
" <td>trash-cli-0.17.1.14-py27_0.tar.bz2</td>\n",
" </tr>\n",
" <tr>\n",
" <th>3</th>\n",
" <td>{'', '.txt', '.py', '.pyc', '.json', '.yaml', ...</td>\n",
" <td>pims-0.3.3-py35_1.tar.bz2</td>\n",
" </tr>\n",
" <tr>\n",
" <th>4</th>\n",
" <td>{'', '.txt', '.py', '.pyc', '.json', '.yaml', ...</td>\n",
" <td>extras-1.0.0-py36_0.tar.bz2</td>\n",
" </tr>\n",
" </tbody>\n",
"</table>\n",
"</div>"
],
"text/plain": [
" ext \\\n",
"0 {'', '.txt', '.py', '.rendered', '.pyc', '.jso... \n",
"1 {'', '.txt', '.py', '.rendered', '.pyc', '.egg... \n",
"2 {'', '.txt', '.py', '.1', '.pyc', '.egg-info',... \n",
"3 {'', '.txt', '.py', '.pyc', '.json', '.yaml', ... \n",
"4 {'', '.txt', '.py', '.pyc', '.json', '.yaml', ... \n",
"\n",
" name \n",
"0 pytest-cookies-0.2.0-py34_0.tar.bz2 \n",
"1 permission-0.4.1-py27_0.tar.bz2 \n",
"2 trash-cli-0.17.1.14-py27_0.tar.bz2 \n",
"3 pims-0.3.3-py35_1.tar.bz2 \n",
"4 extras-1.0.0-py36_0.tar.bz2 "
]
},
"execution_count": 85,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"linux.head()"
]
},
{
"cell_type": "code",
"execution_count": 86,
"metadata": {
"collapsed": true
},
"outputs": [],
"source": [
"linux['ext'] = linux['ext'].apply(eval)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": true
},
"outputs": [],
"source": [
"# Define some common binary extensiosn\n",
"\n",
"bin_extensions = set(['.so', '.pyd', '.dylib', '.exe', '.dll', '.lib', '.a'])"
]
},
{
"cell_type": "code",
"execution_count": 294,
"metadata": {},
"outputs": [],
"source": [
"categorized_extensions = {\n",
" 'numeric': ['.%d' % num for num in range(10)],\n",
" 'web': ['.css', '.css_t', '.html', '.gif', '.js', '.png'],\n",
" 'jupyter': ['.ipynb'],\n",
" 'conda': ['.rendered', '.template', '.yaml', '.bat', '.sh',\n",
" '.tmpl', '.yml'],\n",
" 'other': ['', '.py', '.pyc', '.json', '.json', '.egg-info', \n",
" '.txt', '.pc', '.rst', '.csv', '.ogg', '.test',\n",
" '.conf', '.xsd', '.xml', '.ico', '.map', '.cmd',\n",
" '.svg', '.manifest', '.info', '.bash', '.md',\n",
" '.dat']\n",
"}\n",
"allowed_extensions = set()\n",
"for category, extensions in categorized_extensions.items():\n",
" allowed_extensions.update(extensions)\n"
]
},
{
"cell_type": "code",
"execution_count": 295,
"metadata": {},
"outputs": [],
"source": [
"linux['compiled'] = linux['ext'].apply(lambda extensions: any(ext in extensions for ext in bin_extensions))\n",
"linux['pure'] = linux['ext'].apply(lambda extensions: extensions <= allowed_extensions)\n",
"linux['neither'] = ~linux['pure'] & ~linux['compiled']"
]
},
{
"cell_type": "code",
"execution_count": 296,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"compiled: 8886\n",
"pure: 8390\n",
"neither: 3700\n",
"20976 20976\n"
]
}
],
"source": [
"total = 0\n",
"for col in ['compiled', 'pure', 'neither']:\n",
" subset = linux[linux[col] == True]\n",
" print('%s: %s' % (col, len(subset)))\n",
" total += len(subset)\n",
"print(total, len(linux))"
]
},
{
"cell_type": "code",
"execution_count": 297,
"metadata": {},
"outputs": [
{
"name": "stdout",
"output_type": "stream",
"text": [
"jupyterlab-0.13.1-py35_1.tar.bz2\n",
"\t{'.eot', '.woff', '.ttf', '.ts', '.woff2'}\n",
"jupyterlab-0.13.2-py35_1.tar.bz2\n",
"\t{'.eot', '.woff', '.ttf', '.ts', '.woff2'}\n",
"sphinx-1.6.3-py27_0.tar.bz2\n",
"\t{'.opf_t', '.mo', '.js_t', '.sty', '.pot', '.ncx_t', '.po', '.xhtml_t', '.bat_t', '.cls', '.c', '.ist', '.pyx', '.py_t', '.new_t', '.rst_t', '.pickle', '.tex_t'}\n",
"pagmo-2.4-0.tar.bz2\n",
"\t{'.cmake', '.hpp', '.h'}\n",
"graph-1.11-0.tar.bz2\n",
"\t{'.hxx', '.diff'}\n",
"iris-grib-0.10.1-py27_0.tar.bz2\n",
"\t{'.cml'}\n",
"iris-1.12.0-py27_2.tar.bz2\n",
"\t{'.LESSER', '.patch', '.krb', '.cfg'}\n",
"compliance-checker-2.3.1-py34_0.tar.bz2\n",
"\t{'.nc', '.j2', '.cdl'}\n",
"alembic-0.8.10-py35_1.tar.bz2\n",
"\t{'.mako'}\n",
"glymur-0.8.4-py35_0.tar.bz2\n",
"\t{'.tif', '.jpx', '.jp2', '.j2k'}\n"
]
}
],
"source": [
"neither = linux[linux['neither'] == True]\n",
"\n",
"for name, ext in zip(neither['name'].values[:10], neither['ext'].values[:10]):\n",
" print(name)\n",
" print('\\t%s' % ext.difference(allowed_extensions))\n"
]
},
{
"cell_type": "code",
"execution_count": 298,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"{'.eot', '.ts', '.ttf', '.woff', '.woff2'}"
]
},
"execution_count": 298,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"neither['ext'].values[1].difference(allowed_extensions)"
]
},
{
"cell_type": "code",
"execution_count": 218,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"'librosa-0.5.0rc0-py34_0.tar.bz2'"
]
},
"execution_count": 218,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"neither['name'].values[1]"
]
},
{
"cell_type": "code",
"execution_count": 197,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"{'',\n",
" '.0',\n",
" '.1',\n",
" '.2',\n",
" '.3',\n",
" '.4',\n",
" '.5',\n",
" '.6',\n",
" '.7',\n",
" '.8',\n",
" '.9',\n",
" '.bat',\n",
" '.css',\n",
" '.egg-info',\n",
" '.gif',\n",
" '.html',\n",
" '.ipynb',\n",
" '.js',\n",
" '.json',\n",
" '.png',\n",
" '.py',\n",
" '.pyc',\n",
" '.rendered',\n",
" '.sh',\n",
" '.template',\n",
" '.tmpl',\n",
" '.txt',\n",
" '.yaml',\n",
" '.yml'}"
]
},
"execution_count": 197,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"allowed_extensions.difference()"
]
},
{
"cell_type": "code",
"execution_count": 96,
"metadata": {},
"outputs": [
{
"data": {
"text/html": [
"<div>\n",
"<style>\n",
" .dataframe thead tr:only-child th {\n",
" text-align: right;\n",
" }\n",
"\n",
" .dataframe thead th {\n",
" text-align: left;\n",
" }\n",
"\n",
" .dataframe tbody tr th {\n",
" vertical-align: top;\n",
" }\n",
"</style>\n",
"<table border=\"1\" class=\"dataframe\">\n",
" <thead>\n",
" <tr style=\"text-align: right;\">\n",
" <th></th>\n",
" <th>ext</th>\n",
" <th>name</th>\n",
" <th>compiled</th>\n",
" <th>pure</th>\n",
" </tr>\n",
" </thead>\n",
" <tbody>\n",
" <tr>\n",
" <th>0</th>\n",
" <td>{, .rendered, .yaml, .pyc, .py, .txt, .json}</td>\n",
" <td>pytest-cookies-0.2.0-py34_0.tar.bz2</td>\n",
" <td>False</td>\n",
" <td>True</td>\n",
" </tr>\n",
" <tr>\n",
" <th>1</th>\n",
" <td>{, .rendered, .egg-info, .yaml, .pyc, .py, .tx...</td>\n",
" <td>permission-0.4.1-py27_0.tar.bz2</td>\n",
" <td>False</td>\n",
" <td>False</td>\n",
" </tr>\n",
" <tr>\n",
" <th>2</th>\n",
" <td>{, .egg-info, .yaml, .1, .template, .pyc, .py,...</td>\n",
" <td>trash-cli-0.17.1.14-py27_0.tar.bz2</td>\n",
" <td>False</td>\n",
" <td>False</td>\n",
" </tr>\n",
" <tr>\n",
" <th>3</th>\n",
" <td>{, .yaml, .template, .pyc, .py, .json, .txt}</td>\n",
" <td>pims-0.3.3-py35_1.tar.bz2</td>\n",
" <td>False</td>\n",
" <td>False</td>\n",
" </tr>\n",
" <tr>\n",
" <th>4</th>\n",
" <td>{, .yaml, .template, .pyc, .py, .json, .txt}</td>\n",
" <td>extras-1.0.0-py36_0.tar.bz2</td>\n",
" <td>False</td>\n",
" <td>False</td>\n",
" </tr>\n",
" </tbody>\n",
"</table>\n",
"</div>"
],
"text/plain": [
" ext \\\n",
"0 {, .rendered, .yaml, .pyc, .py, .txt, .json} \n",
"1 {, .rendered, .egg-info, .yaml, .pyc, .py, .tx... \n",
"2 {, .egg-info, .yaml, .1, .template, .pyc, .py,... \n",
"3 {, .yaml, .template, .pyc, .py, .json, .txt} \n",
"4 {, .yaml, .template, .pyc, .py, .json, .txt} \n",
"\n",
" name compiled pure \n",
"0 pytest-cookies-0.2.0-py34_0.tar.bz2 False True \n",
"1 permission-0.4.1-py27_0.tar.bz2 False False \n",
"2 trash-cli-0.17.1.14-py27_0.tar.bz2 False False \n",
"3 pims-0.3.3-py35_1.tar.bz2 False False \n",
"4 extras-1.0.0-py36_0.tar.bz2 False False "
]
},
"execution_count": 96,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"neither.head()"
]
},
{
"cell_type": "code",
"execution_count": 93,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"20976"
]
},
"execution_count": 93,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"len(neither)"
]
},
{
"cell_type": "code",
"execution_count": 73,
"metadata": {},
"outputs": [
{
"data": {
"text/plain": [
"5 True\n",
"27 True\n",
"30 True\n",
"33 True\n",
"34 True\n",
"35 True\n",
"45 True\n",
"46 True\n",
"49 True\n",
"52 True\n",
"56 True\n",
"59 True\n",
"63 True\n",
"66 True\n",
"67 True\n",
"70 True\n",
"71 True\n",
"72 True\n",
"75 True\n",
"77 True\n",
"78 True\n",
"85 True\n",
"86 True\n",
"91 True\n",
"93 True\n",
"94 True\n",
"96 True\n",
"99 True\n",
"100 True\n",
"102 True\n",
" ... \n",
"20916 True\n",
"20920 True\n",
"20921 True\n",
"20922 True\n",
"20927 True\n",
"20929 True\n",
"20930 True\n",
"20931 True\n",
"20932 True\n",
"20934 True\n",
"20936 True\n",
"20937 True\n",
"20939 True\n",
"20941 True\n",
"20942 True\n",
"20947 True\n",
"20957 True\n",
"20958 True\n",
"20961 True\n",
"20963 True\n",
"20964 True\n",
"20965 True\n",
"20967 True\n",
"20968 True\n",
"20969 True\n",
"20970 True\n",
"20972 True\n",
"20973 True\n",
"20974 True\n",
"20975 True\n",
"Name: compiled, Length: 8987, dtype: bool"
]
},
"execution_count": 73,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"linux['compiled'][linux['compiled'] == True]"
]
},
{
"cell_type": "code",
"execution_count": 47,
"metadata": {},
"outputs": [
{
"ename": "TypeError",
"evalue": "expected str, bytes or os.PathLike object, not list",
"output_type": "error",
"traceback": [
"\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
"\u001b[0;31mTypeError\u001b[0m Traceback (most recent call last)",
"\u001b[0;32m<ipython-input-47-bebe7562194d>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m()\u001b[0m\n\u001b[0;32m----> 1\u001b[0;31m \u001b[0mfnmatch\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mfilter\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mall_extensions\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mbin_extensions\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m",
"\u001b[0;32m~/miniconda/lib/python3.6/fnmatch.py\u001b[0m in \u001b[0;36mfilter\u001b[0;34m(names, pat)\u001b[0m\n\u001b[1;32m 49\u001b[0m \u001b[0;34m\"\"\"Return the subset of the list NAMES that match PAT.\"\"\"\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 50\u001b[0m \u001b[0mresult\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0;34m[\u001b[0m\u001b[0;34m]\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m---> 51\u001b[0;31m \u001b[0mpat\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mos\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mpath\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mnormcase\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mpat\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 52\u001b[0m \u001b[0mmatch\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0m_compile_pattern\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0mpat\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 53\u001b[0m \u001b[0;32mif\u001b[0m \u001b[0mos\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mpath\u001b[0m \u001b[0;32mis\u001b[0m \u001b[0mposixpath\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
"\u001b[0;32m~/miniconda/lib/python3.6/posixpath.py\u001b[0m in \u001b[0;36mnormcase\u001b[0;34m(s)\u001b[0m\n\u001b[1;32m 50\u001b[0m \u001b[0;32mdef\u001b[0m \u001b[0mnormcase\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ms\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 51\u001b[0m \u001b[0;34m\"\"\"Normalize case of pathname. Has no effect under Posix\"\"\"\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m---> 52\u001b[0;31m \u001b[0ms\u001b[0m \u001b[0;34m=\u001b[0m \u001b[0mos\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0mfspath\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ms\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 53\u001b[0m \u001b[0;32mif\u001b[0m \u001b[0;32mnot\u001b[0m \u001b[0misinstance\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0ms\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0;34m(\u001b[0m\u001b[0mbytes\u001b[0m\u001b[0;34m,\u001b[0m \u001b[0mstr\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m:\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 54\u001b[0m raise TypeError(\"normcase() argument must be str or bytes, \"\n",
"\u001b[0;31mTypeError\u001b[0m: expected str, bytes or os.PathLike object, not list"
]
}
],
"source": [
"fnmatch.filter(all_extensions, bin_extensions)"
]
},
{
"cell_type": "code",
"execution_count": 37,
"metadata": {
"scrolled": false
},
"outputs": [
{
"data": {
"text/plain": [
"['',\n",
" '.0',\n",
" '.0-deps',\n",
" '.0-no-ofed',\n",
" '.0-no-ofed-brokenblacs',\n",
" '.0-no-ofed-brokenfftw',\n",
" '.0-rc3',\n",
" '.00',\n",
" '.01',\n",
" '.02',\n",
" '.027',\n",
" '.028',\n",
" '.03',\n",
" '.038',\n",
" '.04',\n",
" '.049',\n",
" '.05',\n",
" '.06',\n",
" '.06-xc',\n",
" '.060433',\n",
" '.07',\n",
" '.070601',\n",
" '.073',\n",
" '.08',\n",
" '.09',\n",
" '.0nv',\n",
" '.0rv',\n",
" '.1',\n",
" '.1-17',\n",
" '.10',\n",
" '.100',\n",
" '.101',\n",
" '.108',\n",
" '.10nv',\n",
" '.10rv',\n",
" '.11',\n",
" '.12',\n",
" '.124800',\n",
" '.13',\n",
" '.130',\n",
" '.133',\n",
" '.138',\n",
" '.14',\n",
" '.15',\n",
" '.16',\n",
" '.17',\n",
" '.18',\n",
" '.19',\n",
" '.1976-0',\n",
" '.1d',\n",
" '.2',\n",
" '.20',\n",
" '.2016',\n",
" '.21',\n",
" '.22',\n",
" '.23',\n",
" '.24',\n",
" '.24ec0a1-dirty',\n",
" '.25',\n",
" '.25nv',\n",
" '.25rv',\n",
" '.26',\n",
" '.27',\n",
" '.28',\n",
" '.286cab6-dirty',\n",
" '.29',\n",
" '.3',\n",
" '.3-no-ofed',\n",
" '.31',\n",
" '.33',\n",
" '.35-1',\n",
" '.361',\n",
" '.367',\n",
" '.3_defaults',\n",
" '.3d',\n",
" '.4',\n",
" '.4-config',\n",
" '.40',\n",
" '.41',\n",
" '.49',\n",
" '.4m',\n",
" '.4m-config',\n",
" '.5',\n",
" '.5-config',\n",
" '.53',\n",
" '.54',\n",
" '.55',\n",
" '.56',\n",
" '.57',\n",
" '.58',\n",
" '.59',\n",
" '.5m',\n",
" '.5m-config',\n",
" '.6',\n",
" '.6-config',\n",
" '.62-now',\n",
" '.66',\n",
" '.6m',\n",
" '.6m-config',\n",
" '.7',\n",
" '.7-config',\n",
" '.8',\n",
" '.8e9ccef-dirty',\n",
" '.8svx',\n",
" '.9',\n",
" '.92b61f2-dirty',\n",
" '._js',\n",
" '._nd',\n",
" '.a',\n",
" '.a1032_001bh_z',\n",
" '.a1032_001bh_z_mseed',\n",
" '.a99',\n",
" '.ac',\n",
" '.access',\n",
" '.ace',\n",
" '.add',\n",
" '.aff',\n",
" '.affiliation',\n",
" '.affix',\n",
" '.afm',\n",
" '.ag',\n",
" '.aif',\n",
" '.aifc',\n",
" '.aiff',\n",
" '.alias',\n",
" '.am',\n",
" '.amiga',\n",
" '.ampl',\n",
" '.announce',\n",
" '.api',\n",
" '.app',\n",
" '.append',\n",
" '.applescript',\n",
" '.applications',\n",
" '.applite',\n",
" '.appup',\n",
" '.ar2v',\n",
" '.arc',\n",
" '.area',\n",
" '.areas',\n",
" '.arff',\n",
" '.as',\n",
" '.asc',\n",
" '.ascii',\n",
" '.asd',\n",
" '.asis',\n",
" '.asm',\n",
" '.asn',\n",
" '.asn1',\n",
" '.asn1config',\n",
" '.aspx',\n",
" '.ast',\n",
" '.attr',\n",
" '.au',\n",
" '.autoconf',\n",
" '.aux',\n",
" '.avas',\n",
" '.avi',\n",
" '.avsc',\n",
" '.awk',\n",
" '.b',\n",
" '.b1',\n",
" '.b99',\n",
" '.bai',\n",
" '.bak',\n",
" '.bash',\n",
" '.basket',\n",
" '.bat',\n",
" '.bat_t',\n",
" '.bbl',\n",
" '.bc',\n",
" '.bcf',\n",
" '.bdf',\n",
" '.bdouble',\n",
" '.beam',\n",
" '.bed',\n",
" '.bfc',\n",
" '.bfd',\n",
" '.bfloat',\n",
" '.bg',\n",
" '.bh_',\n",
" '.bhe_short',\n",
" '.bhz',\n",
" '.bib',\n",
" '.bim',\n",
" '.bin',\n",
" '.bindata',\n",
" '.binpos',\n",
" '.bisect',\n",
" '.bk1',\n",
" '.bki',\n",
" '.blg',\n",
" '.blo',\n",
" '.block',\n",
" '.bm',\n",
" '.bmp',\n",
" '.bnf',\n",
" '.bob',\n",
" '.boot',\n",
" '.bottom',\n",
" '.boundary',\n",
" '.brep',\n",
" '.brew',\n",
" '.browser',\n",
" '.bsd',\n",
" '.bsh',\n",
" '.bst',\n",
" '.bval',\n",
" '.bvec',\n",
" '.bw_dhfo',\n",
" '.bw_furt',\n",
" '.bw_manz',\n",
" '.bw_rjob',\n",
" '.bw_rotz',\n",
" '.bw_zugs',\n",
" '.bz2',\n",
" '.c',\n",
" '.cache-4',\n",
" '.cal',\n",
" '.canvas3d',\n",
" '.capnp',\n",
" '.cas',\n",
" '.cc',\n",
" '.cc-tst',\n",
" '.ccp4',\n",
" '.cdf',\n",
" '.cdl',\n",
" '.certs',\n",
" '.cf',\n",
" '.cff',\n",
" '.cfg',\n",
" '.cgi',\n",
" '.changelog',\n",
" '.changes',\n",
" '.charset',\n",
" '.chl',\n",
" '.chm',\n",
" '.chr',\n",
" '.cir',\n",
" '.cit',\n",
" '.cl',\n",
" '.class',\n",
" '.clh',\n",
" '.clr',\n",
" '.cls',\n",
" '.cm4',\n",
" '.cmake',\n",
" '.cmd',\n",
" '.cml',\n",
" '.cmn',\n",
" '.cmn_text',\n",
" '.cn',\n",
" '.cnf',\n",
" '.cnv',\n",
" '.co',\n",
" '.cobyla',\n",
" '.cocos',\n",
" '.coffee',\n",
" '.col',\n",
" '.color',\n",
" '.common',\n",
" '.compact',\n",
" '.con',\n",
" '.conf',\n",
" '.config',\n",
" '.config1',\n",
" '.config2',\n",
" '.config3',\n",
" '.config4',\n",
" '.config5',\n",
" '.config6',\n",
" '.config7',\n",
" '.configure',\n",
" '.contributors',\n",
" '.control',\n",
" '.cor',\n",
" '.cords',\n",
" '.cp',\n",
" '.cpg',\n",
" '.cpp',\n",
" '.cpt',\n",
" '.cpu0000',\n",
" '.crd',\n",
" '.crfsuite',\n",
" '.crl',\n",
" '.cross',\n",
" '.crt',\n",
" '.cs',\n",
" '.csd',\n",
" '.csh',\n",
" '.csl',\n",
" '.css',\n",
" '.css_t',\n",
" '.csv',\n",
" '.ctd',\n",
" '.ctl',\n",
" '.ctv',\n",
" '.ctypes',\n",
" '.cu',\n",
" '.cub',\n",
" '.cuh',\n",
" '.cur',\n",
" '.cxx',\n",
" '.d',\n",
" '.darwin',\n",
" '.das',\n",
" '.dat',\n",
" '.dat_dec',\n",
" '.dat_sun',\n",
" '.data',\n",
" '.data2',\n",
" '.dataless',\n",
" '.db',\n",
" '.dbf',\n",
" '.dbg',\n",
" '.dbj',\n",
" '.dbout',\n",
" '.dcd',\n",
" '.dcf',\n",
" '.dcm',\n",
" '.dcr',\n",
" '.dd',\n",
" '.ddoc',\n",
" '.dds',\n",
" '.de',\n",
" '.deb',\n",
" '.dec',\n",
" '.dectest',\n",
" '.def',\n",
" '.default',\n",
" '.dem',\n",
" '.demo',\n",
" '.dens',\n",
" '.deps',\n",
" '.der',\n",
" '.des',\n",
" '.desc',\n",
" '.description',\n",
" '.desktop',\n",
" '.dev',\n",
" '.devhelp',\n",
" '.devhelp2',\n",
" '.dft',\n",
" '.dgn',\n",
" '.dgux386',\n",
" '.di',\n",
" '.dia',\n",
" '.dic',\n",
" '.dict',\n",
" '.dif',\n",
" '.diff',\n",
" '.dir',\n",
" '.dist',\n",
" '.distinct',\n",
" '.dj',\n",
" '.dll',\n",
" '.dm3',\n",
" '.dm4',\n",
" '.dms',\n",
" '.doc',\n",
" '.doctest',\n",
" '.doctree',\n",
" '.docx',\n",
" '.dods',\n",
" '.dos',\n",
" '.dot',\n",
" '.dox',\n",
" '.dsfmt',\n",
" '.dsptemplate',\n",
" '.dst',\n",
" '.dta',\n",
" '.dtd',\n",
" '.dtr',\n",
" '.dual',\n",
" '.dump',\n",
" '.dvars',\n",
" '.dvi',\n",
" '.dx',\n",
" '.dxf',\n",
" '.dylib',\n",
" '.e',\n",
" '.e00',\n",
" '.e2x',\n",
" '.eb',\n",
" '.ebnf',\n",
" '.ecs',\n",
" '.edf',\n",
" '.edgelist',\n",
" '.egg',\n",
" '.egg-info',\n",
" '.ehz',\n",
" '.el',\n",
" '.elc',\n",
" '.ele',\n",
" '.emd',\n",
" '.emi',\n",
" '.eml',\n",
" '.enc',\n",
" '.end',\n",
" '.ent',\n",
" '.environment',\n",
" '.eo',\n",
" '.eopc04_iau2000',\n",
" '.eot',\n",
" '.eps',\n",
" '.erb',\n",
" '.erl',\n",
" '.error',\n",
" '.es',\n",
" '.escript',\n",
" '.eterm',\n",
" '.ev3',\n",
" '.evt',\n",
" '.ews4800',\n",
" '.ex2',\n",
" '.example',\n",
" '.exe',\n",
" '.exii',\n",
" '.expected',\n",
" '.expr',\n",
" '.exr',\n",
" '.extra',\n",
" '.ez',\n",
" '.f',\n",
" '.f-e',\n",
" '.f03',\n",
" '.f8-lsb',\n",
" '.f8-msb',\n",
" '.f90',\n",
" '.facet',\n",
" '.faddeeva',\n",
" '.fam',\n",
" '.faq',\n",
" '.fas',\n",
" '.fasta',\n",
" '.fastq',\n",
" '.fax',\n",
" '.fd',\n",
" '.feather',\n",
" '.ffpreset',\n",
" '.fh',\n",
" '.fif',\n",
" '.fig',\n",
" '.files',\n",
" '.finals2000a',\n",
" '.first_10_records',\n",
" '.first_record',\n",
" '.fish',\n",
" '.fit',\n",
" '.fits',\n",
" '.flate',\n",
" '.flc',\n",
" '.flf',\n",
" '.flm',\n",
" '.flo',\n",
" '.flv',\n",
" '.fmu',\n",
" '.fontified',\n",
" '.for',\n",
" '.format',\n",
" '.fr',\n",
" '.frag',\n",
" '.fragmentshader',\n",
" '.free_use',\n",
" '.fs',\n",
" '.fts',\n",
" '.fullseed',\n",
" '.funcs',\n",
" '.fz',\n",
" '.g',\n",
" '.gal',\n",
" '.gap',\n",
" '.gap-default64',\n",
" '.gd',\n",
" '.gdb',\n",
" '.gem',\n",
" '.gemspec',\n",
" '.gen',\n",
" '.geo',\n",
" '.geojson',\n",
" '.gexf',\n",
" '.gff',\n",
" '.gfs',\n",
" '.gi',\n",
" '.gif',\n",
" '.gih',\n",
" '.gii',\n",
" '.gir',\n",
" '.global',\n",
" '.glsl',\n",
" '.glu',\n",
" '.gms',\n",
" '.gmt',\n",
" '.gnome',\n",
" '.gnu',\n",
" '.gold',\n",
" '.gp',\n",
" '.gpg',\n",
" '.gpickle',\n",
" '.gpkg',\n",
" '.gpl',\n",
" '.gplt',\n",
" '.gplv2',\n",
" '.grb',\n",
" '.grb2',\n",
" '.grd',\n",
" '.gri',\n",
" '.grib2',\n",
" '.gro',\n",
" '.grp',\n",
" '.gs',\n",
" '.gsb',\n",
" '.gse',\n",
" '.gse2',\n",
" '.guess',\n",
" '.gv',\n",
" '.gwt',\n",
" '.gxl',\n",
" '.gxx',\n",
" '.gyp',\n",
" '.gypi',\n",
" '.gz',\n",
" '.gzip',\n",
" '.h',\n",
" '.h++',\n",
" '.h5',\n",
" '.h90',\n",
" '.handlebars',\n",
" '.hbs',\n",
" '.hcom',\n",
" '.hd',\n",
" '.hdf',\n",
" '.hdf5',\n",
" '.hdr',\n",
" '.he',\n",
" '.he2',\n",
" '.he5',\n",
" '.head',\n",
" '.header',\n",
" '.hexmodops',\n",
" '.hf5',\n",
" '.hh',\n",
" '.hhc',\n",
" '.hhk',\n",
" '.hhp',\n",
" '.hhz',\n",
" '.hierarchy',\n",
" '.hin',\n",
" '.history',\n",
" '.hjson',\n",
" '.hlp',\n",
" '.hmat',\n",
" '.hoomdxml',\n",
" '.how-to',\n",
" '.howto',\n",
" '.hp',\n",
" '.hpp',\n",
" '.hrl',\n",
" '.hspy',\n",
" '.htc',\n",
" '.htm',\n",
" '.html',\n",
" '.html-tpl',\n",
" '.html_t',\n",
" '.humor',\n",
" '.hxx',\n",
" '.hy',\n",
" '.hydra',\n",
" '.hyp',\n",
" '.i',\n",
" '.i386-linux',\n",
" '.i386-linux-gnu',\n",
" '.i686_mac_darwin10',\n",
" '.icd',\n",
" '.icns',\n",
" '.ico',\n",
" '.icon',\n",
" '.ics',\n",
" '.idl',\n",
" '.idtf',\n",
" '.idx',\n",
" '.iga',\n",
" '.iges',\n",
" '.ii_coco',\n",
" '.ijg',\n",
" '.ijmap',\n",
" '.ilp',\n",
" '.imfits',\n",
" '.img',\n",
" '.iml',\n",
" '.in',\n",
" '.inc',\n",
" '.indented',\n",
" '.info',\n",
" '.info-1',\n",
" '.info-2',\n",
" '.info-3',\n",
" '.info-4',\n",
" '.info-5',\n",
" '.info-6',\n",
" '.info-7',\n",
" '.ini',\n",
" '.ini_tmpl',\n",
" '.init',\n",
" '.inl',\n",
" '.inp',\n",
" '.inpcrd',\n",
" '.input',\n",
" '.intel-mac',\n",
" '.internal',\n",
" '.introspection',\n",
" '.inv',\n",
" '.ip',\n",
" '.ipp',\n",
" '.ipynb',\n",
" '.isph',\n",
" '.ist',\n",
" '.it',\n",
" '.its',\n",
" '.j2',\n",
" '.j2k',\n",
" '.ja',\n",
" '.jade',\n",
" '.jar',\n",
" '.java',\n",
" '.jbf',\n",
" '.jinja',\n",
" '.jnilib',\n",
" '.jnl',\n",
" '.jp2',\n",
" '.jpeg',\n",
" '.jpg',\n",
" '.jpx',\n",
" '.js',\n",
" '.js_t',\n",
" '.jsm',\n",
" '.json',\n",
" '.jst',\n",
" '.jsx',\n",
" '.js~',\n",
" '.kea',\n",
" '.kendall',\n",
" '.key',\n",
" '.kissfft',\n",
" '.kml',\n",
" '.kmz',\n",
" '.knet',\n",
" '.ko',\n",
" '.kolmogorovsmirnovdist',\n",
" '.kono__004',\n",
" '.konsole',\n",
" '.krb',\n",
" '.ksh',\n",
" '.kwt',\n",
" '.l',\n",
" '.la',\n",
" '.lab',\n",
" '.label',\n",
" '.lammpstrj',\n",
" '.lay',\n",
" '.lbm',\n",
" '.ld',\n",
" '.ldif',\n",
" '.lefty',\n",
" '.less',\n",
" '.lesser',\n",
" '.lesserv3',\n",
" '.lgpl',\n",
" '.lh5',\n",
" '.lib',\n",
" '.license',\n",
" '.lines',\n",
" '.linux',\n",
" '.lisp',\n",
" '.list',\n",
" '.ll',\n",
" '.ll-tst',\n",
" '.lnk',\n",
" '.loc',\n",
" '.local',\n",
" '.locale',\n",
" '.lock',\n",
" '.log',\n",
" '.lout',\n",
" '.lp',\n",
" '.lsf',\n",
" '.lsp',\n",
" '.lss',\n",
" '.lst',\n",
" '.lua',\n",
" '.lut',\n",
" '.lxx',\n",
" '.lyx',\n",
" '.lzma',\n",
" '.m',\n",
" '.m4',\n",
" '.m4f',\n",
" '.mac',\n",
" '.macosx',\n",
" '.macros',\n",
" '.macsyma',\n",
" '.mak',\n",
" '.make',\n",
" '.mako',\n",
" '.man',\n",
" '.manifest',\n",
" '.map',\n",
" '.maple',\n",
" '.markdown',\n",
" '.mas12',\n",
" '.mashed',\n",
" '.mask',\n",
" '.mat',\n",
" '.mbconvert',\n",
" '.mbga_z',\n",
" '.mbox',\n",
" '.mbsize',\n",
" '.mbskin',\n",
" '.mbsurfplot',\n",
" '.mbtagprop',\n",
" '.mc',\n",
" '.md',\n",
" '.md5',\n",
" '.mdb',\n",
" '.mdcrd',\n",
" '.mdcrdbox',\n",
" '.mdl',\n",
" '.mdp',\n",
" '.mdv',\n",
" '.md~',\n",
" '.me',\n",
" '.meca',\n",
" '.med',\n",
" '.mesh',\n",
" '.mesh3d',\n",
" '.metadata',\n",
" '.metainfo',\n",
" '.methodss3',\n",
" '.mex',\n",
" '.mexa64',\n",
" '.mexmaci64',\n",
" '.mexw64',\n",
" '.mgc',\n",
" '.mgz',\n",
" '.mha',\n",
" '.mib',\n",
" '.mif',\n",
" '.mif2',\n",
" '.min',\n",
" '.misc',\n",
" '.mk',\n",
" '.mkv',\n",
" '.ml',\n",
" '.mli',\n",
" '.mlterm',\n",
" '.mmtf',\n",
" '.mnc',\n",
" '.mo',\n",
" '.mod',\n",
" '.modreg',\n",
" '.modulemap',\n",
" '.modules',\n",
" '.mol2',\n",
" '.mono',\n",
" '.mos',\n",
" '.mov',\n",
" '.mp4',\n",
" '.mpl2',\n",
" '.mplstyle',\n",
" '.mps',\n",
" '.mrxvt',\n",
" '.ms',\n",
" '.msa',\n",
" '.mseed',\n",
" '.msg',\n",
" '.msgpack',\n",
" '.msgs',\n",
" '.msh',\n",
" '.mtl',\n",
" '.mtx',\n",
" '.mustache',\n",
" '.mvo_21_1',\n",
" '.mw',\n",
" '.mwmrc',\n",
" '.mws',\n",
" '.n',\n",
" '.names',\n",
" '.nawk',\n",
" '.nb',\n",
" '.nc',\n",
" '.nc4',\n",
" '.ncdf',\n",
" '.ncl',\n",
" '.ncmap',\n",
" '.ncx_t',\n",
" '.nd',\n",
" '.ndk',\n",
" '.net',\n",
" '.netcdf',\n",
" '.netrc',\n",
" '.network',\n",
" '.neu',\n",
" '.new_t',\n",
" '.nff',\n",
" '.ngdc',\n",
" '.nib',\n",
" '.nii',\n",
" '.nl',\n",
" '.node',\n",
" '.noncf',\n",
" '.notanipynb',\n",
" '.notes',\n",
" '.npy',\n",
" '.npz',\n",
" '.ntwk',\n",
" '.nwk',\n",
" '.o',\n",
" '.obf',\n",
" '.obj',\n",
" '.obs',\n",
" '.oct',\n",
" '.odf',\n",
" '.odt',\n",
" '.offsets',\n",
" '.ogg',\n",
" '.ogv',\n",
" '.ohf',\n",
" '.omf',\n",
" '.oo',\n",
" '.op',\n",
" '.opf_t',\n",
" '.opt',\n",
" '.options',\n",
" '.opts',\n",
" '.org',\n",
" '.orig',\n",
" '.os2',\n",
" '.osm',\n",
" '.otf',\n",
" '.out',\n",
" '.output',\n",
" '.ovf',\n",
" '.own',\n",
" '.ows',\n",
" '.p',\n",
" '.p12',\n",
" '.pag',\n",
" '.pap',\n",
" '.par',\n",
" '.param',\n",
" '.params',\n",
" '.parm',\n",
" '.parm7',\n",
" '.pas',\n",
" '.pat',\n",
" '.patch',\n",
" '.path',\n",
" '.pbfilespec',\n",
" '.pbm',\n",
" '.pbz',\n",
" '.pc',\n",
" '.pck',\n",
" '.pcx',\n",
" '.pdb',\n",
" '.pdbqt',\n",
" '.pdf',\n",
" '.pem',\n",
" '.perl',\n",
" '.pf',\n",
" '.pfb',\n",
" '.pfx',\n",
" '.pgm',\n",
" '.phases',\n",
" '.php',\n",
" '.pial',\n",
" '.pickle',\n",
" '.pkl',\n",
" '.pklz',\n",
" '.pl',\n",
" '.plist',\n",
" '.plot',\n",
" '.plt',\n",
" '.ply',\n",
" '.pm',\n",
" '.png',\n",
" '.pngi',\n",
" '.pnm',\n",
" '.po',\n",
" '.pod',\n",
" '.poissinv',\n",
" '.policy',\n",
" '.port',\n",
" '.pos',\n",
" '.pot',\n",
" '.po~',\n",
" '.pp',\n",
" '.ppd',\n",
" '.ppm',\n",
" '.ppt',\n",
" '.pptx',\n",
" '.pqr',\n",
" '.prf',\n",
" '.pri',\n",
" '.priv',\n",
" '.prj',\n",
" '.prl',\n",
" '.prmtop',\n",
" '.pro',\n",
" '.procmap',\n",
" '.prog',\n",
" '.properties',\n",
" '.props',\n",
" '.proto',\n",
" '.ps',\n",
" '.ps1',\n",
" '.psf',\n",
" '.psp',\n",
" '.pt',\n",
" '.pt_br',\n",
" '.pth',\n",
" '.pub',\n",
" '.pug',\n",
" '.pump',\n",
" '.pvsm',\n",
" '.pxd',\n",
" '.pxi',\n",
" '.pxx',\n",
" '.py',\n",
" '.py-dist',\n",
" '.py-tpl',\n",
" '.py_t',\n",
" '.py_tmpl',\n",
" '.pyc',\n",
" '.pyf',\n",
" '.pyi',\n",
" '.pyke',\n",
" '.pym',\n",
" '.pyo',\n",
" '.pyomo',\n",
" '.pyutilib',\n",
" '.pyw',\n",
" '.pyx',\n",
" '.py~',\n",
" '.pz',\n",
" '.q',\n",
" '.qbn',\n",
" '.qdoc',\n",
" '.qdocconf',\n",
" '.qdocinc',\n",
" '.qgs',\n",
" '.qhd',\n",
" '.qhp',\n",
" '.qm',\n",
" '.qml',\n",
" '.qmltypes',\n",
" '.qph',\n",
" '.qpj',\n",
" '.qrc',\n",
" '.qss',\n",
" '.r',\n",
" '.ram',\n",
" '.ras',\n",
" '.raw',\n",
" '.rawimg',\n",
" '.rb',\n",
" '.rc',\n",
" '.rd',\n",
" '.rda',\n",
" '.rdata',\n",
" '.rdb',\n",
" '.rdoc',\n",
" '.rds',\n",
" '.rdx',\n",
" '.re',\n",
" '.readme',\n",
" '.rec',\n",
" '.ref',\n",
" '.refresp',\n",
" '.regex',\n",
" '.rel',\n",
" '.remark',\n",
" '.rendered',\n",
" '.repository',\n",
" '.res',\n",
" '.resp',\n",
" '.resu',\n",
" '.rev',\n",
" '.rgb',\n",
" '.rgba',\n",
" '.rhtml',\n",
" '.rle',\n",
" '.rm',\n",
" '.rmd',\n",
" '.rms',\n",
" '.rnc',\n",
" '.rng',\n",
" '.rnw',\n",
" '.ro',\n",
" '.rockspec',\n",
" '.roi',\n",
" ...]"
]
},
"execution_count": 37,
"metadata": {},
"output_type": "execute_result"
}
],
"source": [
"sorted(all_extensions)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"collapsed": true
},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.1"
}
},
"nbformat": 4,
"nbformat_minor": 2
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment