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 Python: | |
from collections import defaultdict | |
def infinite_cache(): | |
cache = lambda: defaultdict(cache) | |
return cache() | |
cache = infinite_cache() |
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
/** | |
* 引用不同的数据,会得到不同的地图切片 | |
* 卫星(无地标) WGS-84 一般 GCJ-02 | |
* <script src="https://maps.googleapis.com/maps/api/js?v=3.exp&sensor=false"></script> | |
* 卫星(有地标) GCJ-02 一般 GCJ-02 | |
* <script src="https://ditu.google.cn/maps/api/js?v=3.exp&sensor=false"></script> | |
*/ | |
(function (map) { | |
var Converter = function () { |
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
# Logging settings for django projects, works with django 1.5+ | |
# If DEBUG=True, all logs (including django logs) will be | |
# written to console and to debug_file. | |
# If DEBUG=False, logs with level INFO or higher will be | |
# saved to production_file. | |
# Logging usage: | |
# import logging | |
# logger = logging.getLogger(__name__) | |
# logger.info("Log this message") |