Magic words:
psql -U postgres
If run with -E
flag, it will describe the underlaying queries of the \
commands (cool for learning!).
Most \d
commands support additional param of __schema__.name__
and accept wildcards like *.*
0 - Read http://blog.databigbang.com/running-your-own-anonymous-rotating-proxies/ | |
1 - Install monit, haproxy, tor and delegated. | |
2 - Setup your environment in the setup.rb file | |
3 - Just run > ruby setup.rb | |
4 - ........... | |
5 - PROFIT! > http://www.southparkstudios.com/clips/151040/the-underpants-business |
### Keybase proof | |
I hereby claim: | |
* I am herrbuerger on github. | |
* I am herrbuerger (https://keybase.io/herrbuerger) on keybase. | |
* I have a public key ASDehSwsfC_aKN2WUeEHyWdANSMW8ppk7RjIDs8tFXekTQo | |
To claim this, I am signing this object: |
#include <Python.h> | |
#include <numpy/arrayobject.h> | |
#include "euclidean.h" | |
/* Docstrings */ | |
static char module_docstring[] = | |
"This module provides an interface for calculating squared euclidean distance"; | |
static char euclidean_docstring[] = | |
"Calculate the squared euclidean distance of two 128-dimensional vectors"; | |
<context-param> | |
<param-name>net.myrrix.web.InitListener.USER_NAME</param-name> | |
<param-value>admin</param-value> | |
</context-param> | |
<context-param> | |
<param-name>net.myrrix.web.InitListener.PASSWORD</param-name> | |
<param-value>password</param-value> | |
</context-param> |
This is a very basic method to do rotating snapshots for Elasticsearch. For this to work you will need to have jq installed (http://stedolan.github.io/jq/).
PLEASE, PLEASE, PLEASE don't put this blindly in your commandline and execute it :)
curl -s -S -XGET "localhost:9200/_snapshot/my_s3_repository/_all?pretty=true" | jq '.snapshots[] | .snapshot + " " + .end_time' | sed 's/^.\(.*\).$/\1/' | sort -k 2 -r | awk '{ if (NR > 1) { system("curl -XDELETE " "localhost:9200/_snapshot/my_s3_repository/"$1) } } END { system("curl -XPUT " "localhost:9200/_snapshot/my_s3_repository/`date +\%s`") }'
.... |
Hallo Basti. |
<iframe src="http://www.google.com/talk/service/badge/Show?tk=z01q6amlqds2ocfa7occdcfjga2cakqe0d40n0tbanbeslbn2vadcq7ags0ab7vm1s8ftk971vmma9g7lfj3rkrikt0rgbm7esslsmva5dtsaqftf3bhisgljpbskmvj0cmtte0t5a56qd55ekqnoi9v258u89llmrm9bclss4tjh6morbm7jiop585i89bunco&w=200&h=60" frameborder="0" allowtransparency="true" width="200" height="60"></iframe> |
from annoy import AnnoyIndex | |
a = AnnoyIndex(3) | |
a.add_item(10, [1, 0, 0]) | |
a.add_item(11, [0, 1, 0]) | |
a.add_item(13, [0, 0, 1]) | |
a.build(-1) | |
print a.get_nns_by_item(13, 10) | |
print a.get_nns_by_item(1, 10) |