This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo lsof -iTCP -sTCP:LISTEN -n -P |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| df.dropna(subset=[1]) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| du -h -d=1 . |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| test_file = 'test.csv' | |
| test_data = pd.read_csv(test_file) | |
| predictions = predictions_3(test_data) | |
| result = open('result.csv', 'w') | |
| for item in predictions: | |
| result.write("%s\n" % item) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (* | |
| Open Terminal Here | |
| A toolbar script for Mac OS X 10.3/10.4 | |
| Written by Brian Schlining | |
| *) | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| mongo --host dds-2ze14d04d8fb07e42.mongodb.rds.aliyuncs.com:3717 --authenticationDatabase admin -u root -p zhihuishe1201 staging-beijing < group.js > result.csv |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var match = { | |
| 'date': { | |
| '$gte': '2017-06-24', | |
| '$lte': '2017-06-30', | |
| } | |
| } | |
| var group = { | |
| '_id': {'account_name':'$account_name','region':'$region'}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var bulk = db.gddata_daily_stats.initializeOrderedBulkOp(), | |
| count = 0; | |
| // List "all" fields that make a document "unique" in the `_id` | |
| // I am only listing some for example purposes to follow | |
| db.gddata_daily_stats.aggregate([ | |
| { "$group": { | |
| "_id": { | |
| "account_name" : "$account_name", | |
| "date": "$date", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var bulk = db.testkdd.initializeOrderedBulkOp(), | |
| count = 0; | |
| // List "all" fields that make a document "unique" in the `_id` | |
| // I am only listing some for example purposes to follow | |
| db.testkdd.aggregate([ | |
| { "$group": { | |
| "_id": { | |
| "duration" : "$duration", | |
| "protocol_type": "$protocol_type", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| In iTerm2, preferences>profiles>tab general, there is an option in Command called send text at start that executes any command you put there after login. | |
| pyenv activate zhangpeng |