repo_name
stringlengths
5
100
path
stringlengths
4
375
copies
stringclasses
991 values
size
stringlengths
4
7
content
stringlengths
666
1M
license
stringclasses
15 values
debugger22/sympy
sympy/matrices/expressions/tests/test_trace.py
83
2693
from sympy.core import Lambda, S, symbols from sympy.concrete import Sum from sympy.functions import adjoint, conjugate, transpose from sympy.matrices import eye, Matrix, ShapeError, ImmutableMatrix from sympy.matrices.expressions import ( Adjoint, Identity, FunctionMatrix, MatrixExpr, MatrixSymbol, Trace, ZeroMatrix, trace, MatPow, MatAdd, MatMul ) from sympy.utilities.pytest import raises, XFAIL n = symbols('n', integer=True) A = MatrixSymbol('A', n, n) B = MatrixSymbol('B', n, n) C = MatrixSymbol('C', 3, 4) def test_Trace(): assert isinstance(Trace(A), Trace) assert not isinstance(Trace(A), MatrixExpr) raises(ShapeError, lambda: Trace(C)) assert trace(eye(3)) == 3 assert trace(Matrix(3, 3, [1, 2, 3, 4, 5, 6, 7, 8, 9])) == 15 assert adjoint(Trace(A)) == trace(Adjoint(A)) assert conjugate(Trace(A)) == trace(Adjoint(A)) assert transpose(Trace(A)) == Trace(A) A / Trace(A) # Make sure this is possible # Some easy simplifications assert trace(Identity(5)) == 5 assert trace(ZeroMatrix(5, 5)) == 0 assert trace(2*A*B) == 2*Trace(A*B) assert trace(A.T) == trace(A) i, j = symbols('i j') F = FunctionMatrix(3, 3, Lambda((i, j), i + j)) assert trace(F) == (0 + 0) + (1 + 1) + (2 + 2) raises(TypeError, lambda: Trace(S.One)) assert Trace(A).arg is A assert str(trace(A)) == str(Trace(A).doit()) def test_Trace_A_plus_B(): assert trace(A + B) == Trace(A) + Trace(B) assert Trace(A + B).arg == MatAdd(A, B) assert Trace(A + B).doit() == Trace(A) + Trace(B) def test_Trace_MatAdd_doit(): # See issue #9028 X = ImmutableMatrix([[1, 2, 3]]*3) Y = MatrixSymbol('Y', 3, 3) q = MatAdd(X, 2*X, Y, -3*Y) assert Trace(q).arg == q assert Trace(q).doit() == 18 - 2*Trace(Y) def test_Trace_MatPow_doit(): X = Matrix([[1, 2], [3, 4]]) assert Trace(X).doit() == 5 q = MatPow(X, 2) assert Trace(q).arg == q assert Trace(q).doit() == 29 def test_Trace_MutableMatrix_plus(): # See issue #9043 X = Matrix([[1, 2], [3, 4]]) assert Trace(X) + Trace(X) == 2*Trace(X) def test_Trace_doit_deep_False(): X = Matrix([[1, 2], [3, 4]]) q = MatPow(X, 2) assert Trace(q).doit(deep=False).arg == q q = MatAdd(X, 2*X) assert Trace(q).doit(deep=False).arg == q q = MatMul(X, 2*X) assert Trace(q).doit(deep=False).arg == q def test_trace_constant_factor(): # Issue 9052: gave 2*Trace(MatMul(A)) instead of 2*Trace(A) assert trace(2*A) == 2*Trace(A) X = ImmutableMatrix([[1, 2], [3, 4]]) assert trace(MatMul(2, X)) == 10 @XFAIL def test_rewrite(): assert isinstance(trace(A).rewrite(Sum), Sum)
bsd-3-clause
Groupe24/CodeInSpace
tournoi/40/back.py
1
1080
#!/usr/bin/python # -*- coding: utf-8 -*- """ back.py is a part of colored. Copyright 2014-2017 Dimitris Zlatanidis <d.zlatanidis@gmail.com> All rights reserved. Colored is very simple Python library for color and formatting in terminal. https://github.com/dslackw/colored colored is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see <http://www.gnu.org/licenses/>. """ from colors import names class back(object): ESC = '\x1b[48;5;' END = 'm' num = 0 for color in names: vars()[color] = '{}{}{}'.format(ESC, num, END) num += 1
mit
obestwalter/obestwalter.github.io
lebut/livereloader.py
1
1176
import logging import subprocess import time from lebut.config import PATH log = logging.getLogger(__name__) class LiveReloader: cmd = "livereload" def start_with_keep_alive(self, **_): self.start() while self._is_alive: log.info("livereload is active") time.sleep(10) def start(self, port): if self._is_alive: log.info(f"nothing to do - {self.cmd} is running") return args = [self.cmd, "--host", "0.0.0.0", "--port", port, str(PATH.OUTPUT)] log.info("spawn: %s", " ".join(args)) subprocess.Popen(args) while not self._is_alive: log.info(f"wait for {self.cmd} process to spawn") time.sleep(0.5) @property def _is_alive(self): cmd = ["pgrep", "-af", "livereload"] try: out = subprocess.check_output(cmd).decode().strip() return out.split("\n") except subprocess.CalledProcessError as e: if e.returncode == 1: return if __name__ == "__main__": logging.basicConfig(level=logging.DEBUG) lr = LiveReloader() lr.start_with_keep_alive()
mit
kachick/rubinius
vm/test/cxxtest/cxxtestgen.py
74
21164
#!/usr/bin/python '''Usage: %s [OPTIONS] <input file(s)> Generate test source file for CxxTest. -v, --version Write CxxTest version -o, --output=NAME Write output to file NAME --runner=CLASS Create a main() function that runs CxxTest::CLASS --gui=CLASS Like --runner, with GUI component --error-printer Same as --runner=ErrorPrinter --abort-on-fail Abort tests on failed asserts (like xUnit) --have-std Use standard library (even if not found in tests) --no-std Don\'t use standard library (even if found in tests) --have-eh Use exception handling (even if not found in tests) --no-eh Don\'t use exception handling (even if found in tests) --longlong=[TYPE] Use TYPE (default: long long) as long long --template=TEMPLATE Use TEMPLATE file to generate the test runner --include=HEADER Include HEADER in test runner before other headers --root Write CxxTest globals --part Don\'t write CxxTest globals --no-static-init Don\'t rely on static initialization ''' import re import sys import getopt import glob import string # Global variables suites = [] suite = None inBlock = 0 outputFileName = None runner = None gui = None root = None part = None noStaticInit = None templateFileName = None headers = [] haveExceptionHandling = 0 noExceptionHandling = 0 haveStandardLibrary = 0 noStandardLibrary = 0 abortOnFail = 0 factor = 0 longlong = 0 def main(): '''The main program''' files = parseCommandline() scanInputFiles( files ) writeOutput() def usage( problem = None ): '''Print usage info and exit''' if problem is None: print usageString() sys.exit(0) else: sys.stderr.write( usageString() ) abort( problem ) def usageString(): '''Construct program usage string''' return __doc__ % sys.argv[0] def abort( problem ): '''Print error message and exit''' sys.stderr.write( '\n' ) sys.stderr.write( problem ) sys.stderr.write( '\n\n' ) sys.exit(2) def parseCommandline(): '''Analyze command line arguments''' try: options, patterns = getopt.getopt( sys.argv[1:], 'o:r:', ['version', 'output=', 'runner=', 'gui=', 'error-printer', 'abort-on-fail', 'have-std', 'no-std', 'have-eh', 'no-eh', 'template=', 'include=', 'root', 'part', 'no-static-init', 'factor', 'longlong='] ) except getopt.error, problem: usage( problem ) setOptions( options ) return setFiles( patterns ) def setOptions( options ): '''Set options specified on command line''' global outputFileName, templateFileName, runner, gui, haveStandardLibrary, factor, longlong global haveExceptionHandling, noExceptionHandling, abortOnFail, headers, root, part, noStaticInit for o, a in options: if o in ('-v', '--version'): printVersion() elif o in ('-o', '--output'): outputFileName = a elif o == '--template': templateFileName = a elif o == '--runner': runner = a elif o == '--gui': gui = a elif o == '--include': if not re.match( r'^["<].*[>"]$', a ): a = ('"%s"' % a) headers.append( a ) elif o == '--error-printer': runner = 'ErrorPrinter' haveStandardLibrary = 1 elif o == '--abort-on-fail': abortOnFail = 1 elif o == '--have-std': haveStandardLibrary = 1 elif o == '--no-std': noStandardLibrary = 1 elif o == '--have-eh': haveExceptionHandling = 1 elif o == '--no-eh': noExceptionHandling = 1 elif o == '--root': root = 1 elif o == '--part': part = 1 elif o == '--no-static-init': noStaticInit = 1 elif o == '--factor': factor = 1 elif o == '--longlong': if a: longlong = a else: longlong = 'long long' if noStaticInit and (root or part): abort( '--no-static-init cannot be used with --root/--part' ) if gui and not runner: runner = 'StdioPrinter' def printVersion(): '''Print CxxTest version and exit''' sys.stdout.write( "This is CxxTest version 3.10.1.\n" ) sys.exit(0) def setFiles( patterns ): '''Set input files specified on command line''' files = expandWildcards( patterns ) if len(files) is 0 and not root: usage( "No input files found" ) return files def expandWildcards( patterns ): '''Expand all wildcards in an array (glob)''' fileNames = [] for pathName in patterns: patternFiles = glob.glob( pathName ) for fileName in patternFiles: fileNames.append( fixBackslashes( fileName ) ) return fileNames def fixBackslashes( fileName ): '''Convert backslashes to slashes in file name''' return re.sub( r'\\', '/', fileName, 0 ) def scanInputFiles(files): '''Scan all input files for test suites''' for file in files: scanInputFile(file) global suites if len(suites) is 0 and not root: abort( 'No tests defined' ) def scanInputFile(fileName): '''Scan single input file for test suites''' file = open(fileName) lineNo = 0 while 1: line = file.readline() if not line: break lineNo = lineNo + 1 scanInputLine( fileName, lineNo, line ) closeSuite() file.close() def scanInputLine( fileName, lineNo, line ): '''Scan single input line for interesting stuff''' scanLineForExceptionHandling( line ) scanLineForStandardLibrary( line ) scanLineForSuiteStart( fileName, lineNo, line ) global suite if suite: scanLineInsideSuite( suite, lineNo, line ) def scanLineInsideSuite( suite, lineNo, line ): '''Analyze line which is part of a suite''' global inBlock if lineBelongsToSuite( suite, lineNo, line ): scanLineForTest( suite, lineNo, line ) scanLineForCreate( suite, lineNo, line ) scanLineForDestroy( suite, lineNo, line ) def lineBelongsToSuite( suite, lineNo, line ): '''Returns whether current line is part of the current suite. This can be false when we are in a generated suite outside of CXXTEST_CODE() blocks If the suite is generated, adds the line to the list of lines''' if not suite['generated']: return 1 global inBlock if not inBlock: inBlock = lineStartsBlock( line ) if inBlock: inBlock = addLineToBlock( suite, lineNo, line ) return inBlock std_re = re.compile( r"\b(std\s*::|CXXTEST_STD|using\s+namespace\s+std\b|^\s*\#\s*include\s+<[a-z0-9]+>)" ) def scanLineForStandardLibrary( line ): '''Check if current line uses standard library''' global haveStandardLibrary, noStandardLibrary if not haveStandardLibrary and std_re.search(line): if not noStandardLibrary: haveStandardLibrary = 1 exception_re = re.compile( r"\b(throw|try|catch|TSM?_ASSERT_THROWS[A-Z_]*)\b" ) def scanLineForExceptionHandling( line ): '''Check if current line uses exception handling''' global haveExceptionHandling, noExceptionHandling if not haveExceptionHandling and exception_re.search(line): if not noExceptionHandling: haveExceptionHandling = 1 suite_re = re.compile( r'\bclass\s+(\w+)\s*:\s*public\s+((::)?\s*CxxTest\s*::\s*)?TestSuite\b' ) generatedSuite_re = re.compile( r'\bCXXTEST_SUITE\s*\(\s*(\w*)\s*\)' ) def scanLineForSuiteStart( fileName, lineNo, line ): '''Check if current line starts a new test suite''' m = suite_re.search( line ) if m: startSuite( m.group(1), fileName, lineNo, 0 ) m = generatedSuite_re.search( line ) if m: sys.stdout.write( "%s:%s: Warning: Inline test suites are deprecated.\n" % (fileName, lineNo) ) startSuite( m.group(1), fileName, lineNo, 1 ) def startSuite( name, file, line, generated ): '''Start scanning a new suite''' global suite closeSuite() suite = { 'name' : name, 'file' : file, 'cfile' : cstr(file), 'line' : line, 'generated' : generated, 'object' : 'suite_%s' % name, 'dobject' : 'suiteDescription_%s' % name, 'tlist' : 'Tests_%s' % name, 'tests' : [], 'lines' : [] } def lineStartsBlock( line ): '''Check if current line starts a new CXXTEST_CODE() block''' return re.search( r'\bCXXTEST_CODE\s*\(', line ) is not None test_re = re.compile( r'^([^/]|/[^/])*\bvoid\s+([Tt]est\w+)\s*\(\s*(void)?\s*\)' ) def scanLineForTest( suite, lineNo, line ): '''Check if current line starts a test''' m = test_re.search( line ) if m: addTest( suite, m.group(2), lineNo ) def addTest( suite, name, line ): '''Add a test function to the current suite''' test = { 'name' : name, 'suite' : suite, 'class' : 'TestDescription_%s_%s' % (suite['name'], name), 'object' : 'testDescription_%s_%s' % (suite['name'], name), 'line' : line, } suite['tests'].append( test ) def addLineToBlock( suite, lineNo, line ): '''Append the line to the current CXXTEST_CODE() block''' line = fixBlockLine( suite, lineNo, line ) line = re.sub( r'^.*\{\{', '', line ) e = re.search( r'\}\}', line ) if e: line = line[:e.start()] suite['lines'].append( line ) return e is None def fixBlockLine( suite, lineNo, line): '''Change all [E]TS_ macros used in a line to _[E]TS_ macros with the correct file/line''' return re.sub( r'\b(E?TSM?_(ASSERT[A-Z_]*|FAIL))\s*\(', r'_\1(%s,%s,' % (suite['cfile'], lineNo), line, 0 ) create_re = re.compile( r'\bstatic\s+\w+\s*\*\s*createSuite\s*\(\s*(void)?\s*\)' ) def scanLineForCreate( suite, lineNo, line ): '''Check if current line defines a createSuite() function''' if create_re.search( line ): addSuiteCreateDestroy( suite, 'create', lineNo ) destroy_re = re.compile( r'\bstatic\s+void\s+destroySuite\s*\(\s*\w+\s*\*\s*\w*\s*\)' ) def scanLineForDestroy( suite, lineNo, line ): '''Check if current line defines a destroySuite() function''' if destroy_re.search( line ): addSuiteCreateDestroy( suite, 'destroy', lineNo ) def cstr( str ): '''Convert a string to its C representation''' return '"' + string.replace( str, '\\', '\\\\' ) + '"' def addSuiteCreateDestroy( suite, which, line ): '''Add createSuite()/destroySuite() to current suite''' if suite.has_key(which): abort( '%s:%s: %sSuite() already declared' % ( suite['file'], str(line), which ) ) suite[which] = line def closeSuite(): '''Close current suite and add it to the list if valid''' global suite if suite is not None: if len(suite['tests']) is not 0: verifySuite(suite) rememberSuite(suite) suite = None def verifySuite(suite): '''Verify current suite is legal''' if suite.has_key('create') and not suite.has_key('destroy'): abort( '%s:%s: Suite %s has createSuite() but no destroySuite()' % (suite['file'], suite['create'], suite['name']) ) if suite.has_key('destroy') and not suite.has_key('create'): abort( '%s:%s: Suite %s has destroySuite() but no createSuite()' % (suite['file'], suite['destroy'], suite['name']) ) def rememberSuite(suite): '''Add current suite to list''' global suites suites.append( suite ) def writeOutput(): '''Create output file''' if templateFileName: writeTemplateOutput() else: writeSimpleOutput() def writeSimpleOutput(): '''Create output not based on template''' output = startOutputFile() writePreamble( output ) writeMain( output ) writeWorld( output ) output.close() include_re = re.compile( r"\s*\#\s*include\s+<cxxtest/" ) preamble_re = re.compile( r"^\s*<CxxTest\s+preamble>\s*$" ) world_re = re.compile( r"^\s*<CxxTest\s+world>\s*$" ) def writeTemplateOutput(): '''Create output based on template file''' template = open(templateFileName) output = startOutputFile() while 1: line = template.readline() if not line: break; if include_re.search( line ): writePreamble( output ) output.write( line ) elif preamble_re.search( line ): writePreamble( output ) elif world_re.search( line ): writeWorld( output ) else: output.write( line ) template.close() output.close() def startOutputFile(): '''Create output file and write header''' if outputFileName is not None: output = open( outputFileName, 'w' ) else: output = sys.stdout output.write( "/* Generated file, do not edit */\n\n" ) return output wrotePreamble = 0 def writePreamble( output ): '''Write the CxxTest header (#includes and #defines)''' global wrotePreamble, headers, longlong if wrotePreamble: return output.write( "#ifndef CXXTEST_RUNNING\n" ) output.write( "#define CXXTEST_RUNNING\n" ) output.write( "#endif\n" ) output.write( "\n" ) if haveStandardLibrary: output.write( "#define _CXXTEST_HAVE_STD\n" ) if haveExceptionHandling: output.write( "#define _CXXTEST_HAVE_EH\n" ) if abortOnFail: output.write( "#define _CXXTEST_ABORT_TEST_ON_FAIL\n" ) if longlong: output.write( "#define _CXXTEST_LONGLONG %s\n" % longlong ) if factor: output.write( "#define _CXXTEST_FACTOR\n" ) for header in headers: output.write( "#include %s\n" % header ) output.write( "#include <cxxtest/TestListener.h>\n" ) output.write( "#include <cxxtest/TestTracker.h>\n" ) output.write( "#include <cxxtest/TestRunner.h>\n" ) output.write( "#include <cxxtest/RealDescriptions.h>\n" ) if runner: output.write( "#include <cxxtest/%s.h>\n" % runner ) if gui: output.write( "#include <cxxtest/%s.h>\n" % gui ) output.write( "\n" ) wrotePreamble = 1 def writeMain( output ): '''Write the main() function for the test runner''' if gui: output.write( 'int main( int argc, char *argv[] ) {\n' ) if noStaticInit: output.write( ' CxxTest::initialize();\n' ) output.write( ' return CxxTest::GuiTuiRunner<CxxTest::%s, CxxTest::%s>( argc, argv ).run();\n' % (gui, runner) ) output.write( '}\n' ) elif runner: output.write( 'int main() {\n' ) if noStaticInit: output.write( ' CxxTest::initialize();\n' ) output.write( ' return CxxTest::%s().run();\n' % runner ) output.write( '}\n' ) wroteWorld = 0 def writeWorld( output ): '''Write the world definitions''' global wroteWorld, part if wroteWorld: return writePreamble( output ) writeSuites( output ) if root or not part: writeRoot( output ) if noStaticInit: writeInitialize( output ) wroteWorld = 1 def writeSuites(output): '''Write all TestDescriptions and SuiteDescriptions''' for suite in suites: writeInclude( output, suite['file'] ) if isGenerated(suite): generateSuite( output, suite ) if isDynamic(suite): writeSuitePointer( output, suite ) else: writeSuiteObject( output, suite ) writeTestList( output, suite ) writeSuiteDescription( output, suite ) writeTestDescriptions( output, suite ) def isGenerated(suite): '''Checks whether a suite class should be created''' return suite['generated'] def isDynamic(suite): '''Checks whether a suite is dynamic''' return suite.has_key('create') lastIncluded = '' def writeInclude(output, file): '''Add #include "file" statement''' global lastIncluded if file == lastIncluded: return output.writelines( [ '#include "', file, '"\n\n' ] ) lastIncluded = file def generateSuite( output, suite ): '''Write a suite declared with CXXTEST_SUITE()''' output.write( 'class %s : public CxxTest::TestSuite {\n' % suite['name'] ) output.write( 'public:\n' ) for line in suite['lines']: output.write(line) output.write( '};\n\n' ) def writeSuitePointer( output, suite ): '''Create static suite pointer object for dynamic suites''' if noStaticInit: output.write( 'static %s *%s;\n\n' % (suite['name'], suite['object']) ) else: output.write( 'static %s *%s = 0;\n\n' % (suite['name'], suite['object']) ) def writeSuiteObject( output, suite ): '''Create static suite object for non-dynamic suites''' output.writelines( [ "static ", suite['name'], " ", suite['object'], ";\n\n" ] ) def writeTestList( output, suite ): '''Write the head of the test linked list for a suite''' if noStaticInit: output.write( 'static CxxTest::List %s;\n' % suite['tlist'] ) else: output.write( 'static CxxTest::List %s = { 0, 0 };\n' % suite['tlist'] ) def writeTestDescriptions( output, suite ): '''Write all test descriptions for a suite''' for test in suite['tests']: writeTestDescription( output, suite, test ) def writeTestDescription( output, suite, test ): '''Write test description object''' output.write( 'static class %s : public CxxTest::RealTestDescription {\n' % test['class'] ) output.write( 'public:\n' ) if not noStaticInit: output.write( ' %s() : CxxTest::RealTestDescription( %s, %s, %s, "%s" ) {}\n' % (test['class'], suite['tlist'], suite['dobject'], test['line'], test['name']) ) output.write( ' void runTest() { %s }\n' % runBody( suite, test ) ) output.write( '} %s;\n\n' % test['object'] ) def runBody( suite, test ): '''Body of TestDescription::run()''' if isDynamic(suite): return dynamicRun( suite, test ) else: return staticRun( suite, test ) def dynamicRun( suite, test ): '''Body of TestDescription::run() for test in a dynamic suite''' return 'if ( ' + suite['object'] + ' ) ' + suite['object'] + '->' + test['name'] + '();' def staticRun( suite, test ): '''Body of TestDescription::run() for test in a non-dynamic suite''' return suite['object'] + '.' + test['name'] + '();' def writeSuiteDescription( output, suite ): '''Write SuiteDescription object''' if isDynamic( suite ): writeDynamicDescription( output, suite ) else: writeStaticDescription( output, suite ) def writeDynamicDescription( output, suite ): '''Write SuiteDescription for a dynamic suite''' output.write( 'CxxTest::DynamicSuiteDescription<%s> %s' % (suite['name'], suite['dobject']) ) if not noStaticInit: output.write( '( %s, %s, "%s", %s, %s, %s, %s )' % (suite['cfile'], suite['line'], suite['name'], suite['tlist'], suite['object'], suite['create'], suite['destroy']) ) output.write( ';\n\n' ) def writeStaticDescription( output, suite ): '''Write SuiteDescription for a static suite''' output.write( 'CxxTest::StaticSuiteDescription %s' % suite['dobject'] ) if not noStaticInit: output.write( '( %s, %s, "%s", %s, %s )' % (suite['cfile'], suite['line'], suite['name'], suite['object'], suite['tlist']) ) output.write( ';\n\n' ) def writeRoot(output): '''Write static members of CxxTest classes''' output.write( '#include <cxxtest/Root.cpp>\n' ) def writeInitialize(output): '''Write CxxTest::initialize(), which replaces static initialization''' output.write( 'namespace CxxTest {\n' ) output.write( ' void initialize()\n' ) output.write( ' {\n' ) for suite in suites: output.write( ' %s.initialize();\n' % suite['tlist'] ) if isDynamic(suite): output.write( ' %s = 0;\n' % suite['object'] ) output.write( ' %s.initialize( %s, %s, "%s", %s, %s, %s, %s );\n' % (suite['dobject'], suite['cfile'], suite['line'], suite['name'], suite['tlist'], suite['object'], suite['create'], suite['destroy']) ) else: output.write( ' %s.initialize( %s, %s, "%s", %s, %s );\n' % (suite['dobject'], suite['cfile'], suite['line'], suite['name'], suite['object'], suite['tlist']) ) for test in suite['tests']: output.write( ' %s.initialize( %s, %s, %s, "%s" );\n' % (test['object'], suite['tlist'], suite['dobject'], test['line'], test['name']) ) output.write( ' }\n' ) output.write( '}\n' ) main()
bsd-3-clause
efortuna/AndroidSDKClone
ndk_experimental/prebuilt/linux-x86_64/lib/python2.7/test/test_fileio.py
36
15507
# Adapted from test_file.py by Daniel Stutzbach from __future__ import unicode_literals import sys import os import errno import unittest from array import array from weakref import proxy from functools import wraps from UserList import UserList import _testcapi from test.test_support import TESTFN, check_warnings, run_unittest, make_bad_fd from test.test_support import py3k_bytes as bytes from test.script_helper import run_python from _io import FileIO as _FileIO class AutoFileTests(unittest.TestCase): # file tests for which a test file is automatically set up def setUp(self): self.f = _FileIO(TESTFN, 'w') def tearDown(self): if self.f: self.f.close() os.remove(TESTFN) def testWeakRefs(self): # verify weak references p = proxy(self.f) p.write(bytes(range(10))) self.assertEqual(self.f.tell(), p.tell()) self.f.close() self.f = None self.assertRaises(ReferenceError, getattr, p, 'tell') def testSeekTell(self): self.f.write(bytes(range(20))) self.assertEqual(self.f.tell(), 20) self.f.seek(0) self.assertEqual(self.f.tell(), 0) self.f.seek(10) self.assertEqual(self.f.tell(), 10) self.f.seek(5, 1) self.assertEqual(self.f.tell(), 15) self.f.seek(-5, 1) self.assertEqual(self.f.tell(), 10) self.f.seek(-5, 2) self.assertEqual(self.f.tell(), 15) def testAttributes(self): # verify expected attributes exist f = self.f self.assertEqual(f.mode, "wb") self.assertEqual(f.closed, False) # verify the attributes are readonly for attr in 'mode', 'closed': self.assertRaises((AttributeError, TypeError), setattr, f, attr, 'oops') def testReadinto(self): # verify readinto self.f.write(b"\x01\x02") self.f.close() a = array(b'b', b'x'*10) self.f = _FileIO(TESTFN, 'r') n = self.f.readinto(a) self.assertEqual(array(b'b', [1, 2]), a[:n]) def testWritelinesList(self): l = [b'123', b'456'] self.f.writelines(l) self.f.close() self.f = _FileIO(TESTFN, 'rb') buf = self.f.read() self.assertEqual(buf, b'123456') def testWritelinesUserList(self): l = UserList([b'123', b'456']) self.f.writelines(l) self.f.close() self.f = _FileIO(TESTFN, 'rb') buf = self.f.read() self.assertEqual(buf, b'123456') def testWritelinesError(self): self.assertRaises(TypeError, self.f.writelines, [1, 2, 3]) self.assertRaises(TypeError, self.f.writelines, None) def test_none_args(self): self.f.write(b"hi\nbye\nabc") self.f.close() self.f = _FileIO(TESTFN, 'r') self.assertEqual(self.f.read(None), b"hi\nbye\nabc") self.f.seek(0) self.assertEqual(self.f.readline(None), b"hi\n") self.assertEqual(self.f.readlines(None), [b"bye\n", b"abc"]) def testRepr(self): self.assertEqual(repr(self.f), "<_io.FileIO name=%r mode='%s'>" % (self.f.name, self.f.mode)) del self.f.name self.assertEqual(repr(self.f), "<_io.FileIO fd=%r mode='%s'>" % (self.f.fileno(), self.f.mode)) self.f.close() self.assertEqual(repr(self.f), "<_io.FileIO [closed]>") def testErrors(self): f = self.f self.assertTrue(not f.isatty()) self.assertTrue(not f.closed) #self.assertEqual(f.name, TESTFN) self.assertRaises(ValueError, f.read, 10) # Open for reading f.close() self.assertTrue(f.closed) f = _FileIO(TESTFN, 'r') self.assertRaises(TypeError, f.readinto, "") self.assertTrue(not f.closed) f.close() self.assertTrue(f.closed) def testMethods(self): methods = ['fileno', 'isatty', 'read', 'readinto', 'seek', 'tell', 'truncate', 'write', 'seekable', 'readable', 'writable'] if sys.platform.startswith('atheos'): methods.remove('truncate') self.f.close() self.assertTrue(self.f.closed) for methodname in methods: method = getattr(self.f, methodname) # should raise on closed file self.assertRaises(ValueError, method) def testOpendir(self): # Issue 3703: opening a directory should fill the errno # Windows always returns "[Errno 13]: Permission denied # Unix calls dircheck() and returns "[Errno 21]: Is a directory" try: _FileIO('.', 'r') except IOError as e: self.assertNotEqual(e.errno, 0) self.assertEqual(e.filename, ".") else: self.fail("Should have raised IOError") @unittest.skipIf(os.name == 'nt', "test only works on a POSIX-like system") def testOpenDirFD(self): fd = os.open('.', os.O_RDONLY) with self.assertRaises(IOError) as cm: _FileIO(fd, 'r') os.close(fd) self.assertEqual(cm.exception.errno, errno.EISDIR) #A set of functions testing that we get expected behaviour if someone has #manually closed the internal file descriptor. First, a decorator: def ClosedFD(func): @wraps(func) def wrapper(self): #forcibly close the fd before invoking the problem function f = self.f os.close(f.fileno()) try: func(self, f) finally: try: self.f.close() except IOError: pass return wrapper def ClosedFDRaises(func): @wraps(func) def wrapper(self): #forcibly close the fd before invoking the problem function f = self.f os.close(f.fileno()) try: func(self, f) except IOError as e: self.assertEqual(e.errno, errno.EBADF) else: self.fail("Should have raised IOError") finally: try: self.f.close() except IOError: pass return wrapper @ClosedFDRaises def testErrnoOnClose(self, f): f.close() @ClosedFDRaises def testErrnoOnClosedWrite(self, f): f.write('a') @ClosedFDRaises def testErrnoOnClosedSeek(self, f): f.seek(0) @ClosedFDRaises def testErrnoOnClosedTell(self, f): f.tell() @ClosedFDRaises def testErrnoOnClosedTruncate(self, f): f.truncate(0) @ClosedFD def testErrnoOnClosedSeekable(self, f): f.seekable() @ClosedFD def testErrnoOnClosedReadable(self, f): f.readable() @ClosedFD def testErrnoOnClosedWritable(self, f): f.writable() @ClosedFD def testErrnoOnClosedFileno(self, f): f.fileno() @ClosedFD def testErrnoOnClosedIsatty(self, f): self.assertEqual(f.isatty(), False) def ReopenForRead(self): try: self.f.close() except IOError: pass self.f = _FileIO(TESTFN, 'r') os.close(self.f.fileno()) return self.f @ClosedFDRaises def testErrnoOnClosedRead(self, f): f = self.ReopenForRead() f.read(1) @ClosedFDRaises def testErrnoOnClosedReadall(self, f): f = self.ReopenForRead() f.readall() @ClosedFDRaises def testErrnoOnClosedReadinto(self, f): f = self.ReopenForRead() a = array(b'b', b'x'*10) f.readinto(a) class OtherFileTests(unittest.TestCase): def testAbles(self): try: f = _FileIO(TESTFN, "w") self.assertEqual(f.readable(), False) self.assertEqual(f.writable(), True) self.assertEqual(f.seekable(), True) f.close() f = _FileIO(TESTFN, "r") self.assertEqual(f.readable(), True) self.assertEqual(f.writable(), False) self.assertEqual(f.seekable(), True) f.close() f = _FileIO(TESTFN, "a+") self.assertEqual(f.readable(), True) self.assertEqual(f.writable(), True) self.assertEqual(f.seekable(), True) self.assertEqual(f.isatty(), False) f.close() if sys.platform != "win32": try: f = _FileIO("/dev/tty", "a") except EnvironmentError: # When run in a cron job there just aren't any # ttys, so skip the test. This also handles other # OS'es that don't support /dev/tty. pass else: self.assertEqual(f.readable(), False) self.assertEqual(f.writable(), True) if sys.platform != "darwin" and \ 'bsd' not in sys.platform and \ not sys.platform.startswith('sunos'): # Somehow /dev/tty appears seekable on some BSDs self.assertEqual(f.seekable(), False) self.assertEqual(f.isatty(), True) f.close() finally: os.unlink(TESTFN) def testModeStrings(self): # check invalid mode strings for mode in ("", "aU", "wU+", "rw", "rt"): try: f = _FileIO(TESTFN, mode) except ValueError: pass else: f.close() self.fail('%r is an invalid file mode' % mode) def testUnicodeOpen(self): # verify repr works for unicode too f = _FileIO(str(TESTFN), "w") f.close() os.unlink(TESTFN) def testBytesOpen(self): # Opening a bytes filename try: fn = TESTFN.encode("ascii") except UnicodeEncodeError: # Skip test return f = _FileIO(fn, "w") try: f.write(b"abc") f.close() with open(TESTFN, "rb") as f: self.assertEqual(f.read(), b"abc") finally: os.unlink(TESTFN) def testInvalidFd(self): self.assertRaises(ValueError, _FileIO, -10) self.assertRaises(OSError, _FileIO, make_bad_fd()) if sys.platform == 'win32': import msvcrt self.assertRaises(IOError, msvcrt.get_osfhandle, make_bad_fd()) # Issue 15989 self.assertRaises(TypeError, _FileIO, _testcapi.INT_MAX + 1) self.assertRaises(TypeError, _FileIO, _testcapi.INT_MIN - 1) def testBadModeArgument(self): # verify that we get a sensible error message for bad mode argument bad_mode = "qwerty" try: f = _FileIO(TESTFN, bad_mode) except ValueError as msg: if msg.args[0] != 0: s = str(msg) if TESTFN in s or bad_mode not in s: self.fail("bad error message for invalid mode: %s" % s) # if msg.args[0] == 0, we're probably on Windows where there may be # no obvious way to discover why open() failed. else: f.close() self.fail("no error for invalid mode: %s" % bad_mode) def testTruncate(self): f = _FileIO(TESTFN, 'w') f.write(bytes(bytearray(range(10)))) self.assertEqual(f.tell(), 10) f.truncate(5) self.assertEqual(f.tell(), 10) self.assertEqual(f.seek(0, os.SEEK_END), 5) f.truncate(15) self.assertEqual(f.tell(), 5) self.assertEqual(f.seek(0, os.SEEK_END), 15) f.close() def testTruncateOnWindows(self): def bug801631(): # SF bug <http://www.python.org/sf/801631> # "file.truncate fault on windows" f = _FileIO(TESTFN, 'w') f.write(bytes(range(11))) f.close() f = _FileIO(TESTFN,'r+') data = f.read(5) if data != bytes(range(5)): self.fail("Read on file opened for update failed %r" % data) if f.tell() != 5: self.fail("File pos after read wrong %d" % f.tell()) f.truncate() if f.tell() != 5: self.fail("File pos after ftruncate wrong %d" % f.tell()) f.close() size = os.path.getsize(TESTFN) if size != 5: self.fail("File size after ftruncate wrong %d" % size) try: bug801631() finally: os.unlink(TESTFN) def testAppend(self): try: f = open(TESTFN, 'wb') f.write(b'spam') f.close() f = open(TESTFN, 'ab') f.write(b'eggs') f.close() f = open(TESTFN, 'rb') d = f.read() f.close() self.assertEqual(d, b'spameggs') finally: try: os.unlink(TESTFN) except: pass def testInvalidInit(self): self.assertRaises(TypeError, _FileIO, "1", 0, 0) def testWarnings(self): with check_warnings(quiet=True) as w: self.assertEqual(w.warnings, []) self.assertRaises(TypeError, _FileIO, []) self.assertEqual(w.warnings, []) self.assertRaises(ValueError, _FileIO, "/some/invalid/name", "rt") self.assertEqual(w.warnings, []) def test_surrogates(self): # Issue #8438: try to open a filename containing surrogates. # It should either fail because the file doesn't exist or the filename # can't be represented using the filesystem encoding, but not because # of a LookupError for the error handler "surrogateescape". filename = u'\udc80.txt' try: with _FileIO(filename): pass except (UnicodeEncodeError, IOError): pass # Spawn a separate Python process with a different "file system # default encoding", to exercise this further. env = dict(os.environ) env[b'LC_CTYPE'] = b'C' _, out = run_python('-c', 'import _io; _io.FileIO(%r)' % filename, env=env) if ('UnicodeEncodeError' not in out and not ( ('IOError: [Errno 2] No such file or directory' in out) or ('IOError: [Errno 22] Invalid argument' in out) ) ): self.fail('Bad output: %r' % out) def testUnclosedFDOnException(self): class MyException(Exception): pass class MyFileIO(_FileIO): def __setattr__(self, name, value): if name == "name": raise MyException("blocked setting name") return super(MyFileIO, self).__setattr__(name, value) fd = os.open(__file__, os.O_RDONLY) self.assertRaises(MyException, MyFileIO, fd) os.close(fd) # should not raise OSError(EBADF) def test_main(): # Historically, these tests have been sloppy about removing TESTFN. # So get rid of it no matter what. try: run_unittest(AutoFileTests, OtherFileTests) finally: if os.path.exists(TESTFN): os.unlink(TESTFN) if __name__ == '__main__': test_main()
apache-2.0
stackdio/stackdio
stackdio/api/cloud/apps.py
2
3992
# -*- coding: utf-8 -*- # Copyright 2017, Digital Reasoning # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # from __future__ import unicode_literals import io import json import logging import os from django.apps import AppConfig, apps from django.core import exceptions from django.db import DEFAULT_DB_ALIAS, router from django.db.models.signals import post_migrate from django.utils.translation import ugettext_lazy as _ logger = logging.getLogger(__name__) def load_initial_data(): cloud_dir = os.path.dirname(os.path.abspath(__file__)) fixtures_json = os.path.join(cloud_dir, 'fixtures', 'cloud_objects.json') with io.open(fixtures_json, 'rt') as f: initial_data = json.load(f) if initial_data is None: logger.info('Unable to load cloud objects') return initial_data def load_cloud_objects(app_config, verbosity=2, interactive=True, using=DEFAULT_DB_ALIAS, **kwargs): if not app_config.models_module: return initial_data = load_initial_data() for model in initial_data: logger.info("Attempting to load data for {}...".format(model['model'])) # Grab the model class, but don't fail if we can't find it try: model_cls = apps.get_model('cloud', model['model']) except LookupError: logger.warning('Failed to load model class: {}'.format(model['model'])) continue # If we can't migrate this model, don't do anything & go on to the next if not router.allow_migrate_model(using, model_cls): logger.info("Skipping data load for {}".format(model['model'])) continue to_create = [] # Grab the attribute to filter on filter_attr = model['filter_attr'] for object_data in model['objects']: # Only create if it's not already there filtered = model_cls.objects.filter(**{filter_attr: object_data[filter_attr]}) if filtered.count() == 0: # Object doesn't exist in the database if 'pk' in object_data: try: model_cls.objects.get(pk=object_data['pk']) # This means there's a conflicting pk, so we'll just remove the pk from # the object_data dict and let it get assigned something else. del object_data['pk'] except exceptions.ObjectDoesNotExist: # There's no conflicting object, this is good pass # Add this object to the create list to_create.append(model_cls(**object_data)) else: # This object already exists in the database # Update the fields to match the new stuff if the object already exists for obj in filtered: for attr, val in object_data.items(): # We don't want to change the object's primary key # it would mess up a bunch of relations if attr != 'pk': setattr(obj, attr, val) obj.save() # bulk create everything model_cls.objects.using(using).bulk_create(to_create) class CloudConfig(AppConfig): name = 'stackdio.api.cloud' verbose_name = _('Cloud') def ready(self): post_migrate.connect(load_cloud_objects, sender=self)
apache-2.0
caidongyun/pyzmq
examples/poll/pair.py
10
1400
"""A thorough test of polling PAIR sockets.""" #----------------------------------------------------------------------------- # Copyright (c) 2010 Brian Granger # # Distributed under the terms of the New BSD License. The full license is in # the file COPYING.BSD, distributed as part of this software. #----------------------------------------------------------------------------- import time import zmq print "Running polling tests for PAIR sockets..." addr = 'tcp://127.0.0.1:5555' ctx = zmq.Context() s1 = ctx.socket(zmq.PAIR) s2 = ctx.socket(zmq.PAIR) s1.bind(addr) s2.connect(addr) # Sleep to allow sockets to connect. time.sleep(1.0) poller = zmq.Poller() poller.register(s1, zmq.POLLIN|zmq.POLLOUT) poller.register(s2, zmq.POLLIN|zmq.POLLOUT) # Now make sure that both are send ready. socks = dict(poller.poll()) assert socks[s1] == zmq.POLLOUT assert socks[s2] == zmq.POLLOUT # Now do a send on both, wait and test for zmq.POLLOUT|zmq.POLLIN s1.send('msg1') s2.send('msg2') time.sleep(1.0) socks = dict(poller.poll()) assert socks[s1] == zmq.POLLOUT|zmq.POLLIN assert socks[s2] == zmq.POLLOUT|zmq.POLLIN # Make sure that both are in POLLOUT after recv. s1.recv() s2.recv() socks = dict(poller.poll()) assert socks[s1] == zmq.POLLOUT assert socks[s2] == zmq.POLLOUT poller.unregister(s1) poller.unregister(s2) # Wait for everything to finish. time.sleep(1.0) print "Finished."
bsd-3-clause
neoshrew/gelnarBot
gelnar_bot/EXCEPTIONS.py
1
1455
PLURAL_EXCEPTIONS_MAP = { \ 'women' : 'woman', \ 'men' : 'man', \ 'children' : 'child', \ 'teeth' : 'tooth', \ 'feet' : 'foot', \ 'people' : 'person', \ 'leaves' : 'leaf', \ 'mice' : 'mouse', \ 'geese' : 'goose', \ 'halves' : 'half', \ 'knives' : 'knife', \ 'wives' : 'wife', \ 'lives' : 'life', \ 'elves' : 'elf', \ 'loaves' : 'loaf', \ 'potatoes' : 'potato', \ 'tomatoes' : 'tomato', \ 'cacti' : 'cactus', \ 'foci' : 'focus', \ 'fung' : 'fungus', \ 'nuclei' : 'nucleus', \ 'syllabi' : 'syllabus', \ 'analyses' : 'analysis', \ 'diagnoses': 'diagnosis', \ 'oases' : 'oasis', \ 'theses' : 'thesis', \ 'crises' : 'crisis', \ 'phenomena': 'phenomenon', \ 'criteria' : 'criterion', \ 'data' : 'datum', \ } ARTICLE_EXCEPTIONS_LIST = [ 'uber', \ 'ubiety', \ 'ubiquity', \ 'udale', \ 'udall', \ 'uganda', \ 'ukraine', \ 'uinita', \ 'ukase', \ 'udy', \ 'ueberroth', \ 'ullyses', \ 'udometer', \ 'ufo', \ 'ukelele', \ 'uke', \ 'ululate', \ 'upas', \ 'ural', \ 'uranium', \ 'uranus', \ 'urea', \ 'ureter', \ 'urethra', \ 'urine', \ 'urology', \ 'urus', \ 'use', \ 'usual', \ 'usury', \ 'usurp', \ 'utensil', \ 'uterus', \ 'utility', \ 'utopia', \ 'utricle', \ 'uvarovite', \ 'uvea', \ 'uvula', \ 'one', \ 'once', \ ] INDEF_ARTICLE_EXCEPTIONS_LIST = [ 'heir', \ 'heiress', \ 'hour', \ 'honor', \ 'honour', \ 'honest', \ ]
mit
hryamzik/ansible
lib/ansible/modules/network/cloudengine/ce_vxlan_tunnel.py
39
31157
#!/usr/bin/python # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Ansible is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Ansible. If not, see <http://www.gnu.org/licenses/>. # ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} DOCUMENTATION = ''' --- module: ce_vxlan_tunnel version_added: "2.4" short_description: Manages VXLAN tunnel configuration on HUAWEI CloudEngine devices. description: - This module offers the ability to set the VNI and mapped to the BD, and configure an ingress replication list on HUAWEI CloudEngine devices. author: - Li Yanfeng (@CloudEngine-Ansible) options: bridge_domain_id: description: - Specifies a bridge domain ID. The value is an integer ranging from 1 to 16777215. vni_id: description: - Specifies a VXLAN network identifier (VNI) ID. The value is an integer ranging from 1 to 16000000. nve_name: description: - Specifies the number of an NVE interface. The value ranges from 1 to 2. nve_mode: description: - Specifies the working mode of an NVE interface. choices: ['mode-l2','mode-l3'] peer_list_ip: description: - Specifies the IP address of a remote VXLAN tunnel endpoints (VTEP). The value is in dotted decimal notation. protocol_type: description: - The operation type of routing protocol. choices: ['bgp','null'] source_ip: description: - Specifies an IP address for a source VTEP. The value is in dotted decimal notation. state: description: - Manage the state of the resource. default: present choices: ['present','absent'] ''' EXAMPLES = ''' - name: vxlan tunnel module test hosts: ce128 connection: local gather_facts: no vars: cli: host: "{{ inventory_hostname }}" port: "{{ ansible_ssh_port }}" username: "{{ username }}" password: "{{ password }}" transport: cli tasks: - name: Make sure nve_name is exist, ensure vni_id and protocol_type is configured on Nve1 interface. ce_vxlan_tunnel: nve_name: Nve1 vni_id: 100 protocol_type: bgp state: present provider: "{{ cli }}" ''' RETURN = ''' proposed: description: k/v pairs of parameters passed into module returned: always type: dict sample: {nve_interface_name": "Nve1", nve_mode": "mode-l2", "source_ip": "0.0.0.0"} existing: description: - k/v pairs of existing rollback returned: always type: dict sample: {nve_interface_name": "Nve1", nve_mode": "mode-l3", "source_ip": "0.0.0.0"} updates: description: command sent to the device returned: always type: list sample: ["interface Nve1", "mode l3"] changed: description: check to see if a change was made on the device returned: always type: boolean sample: true end_state: description: k/v pairs of configuration after module execution returned: always type: dict sample: {nve_interface_name": "Nve1", nve_mode": "mode-l3", "source_ip": "0.0.0.0"} ''' from xml.etree import ElementTree from ansible.module_utils.basic import AnsibleModule from ansible.module_utils.network.cloudengine.ce import get_nc_config, set_nc_config, get_config, ce_argument_spec CE_NC_GET_VNI_BD_INFO = """ <filter type="subtree"> <nvo3 xmlns="http://www.huawei.com/netconf/vrp" content-version="1.0" format-version="1.0"> <nvo3Vni2Bds> <nvo3Vni2Bd> <vniId></vniId> <bdId></bdId> </nvo3Vni2Bd> </nvo3Vni2Bds> </nvo3> </filter> """ CE_NC_GET_NVE_INFO = """ <filter type="subtree"> <nvo3 xmlns="http://www.huawei.com/netconf/vrp" content-version="1.0" format-version="1.0"> <nvo3Nves> <nvo3Nve> <ifName>%s</ifName> </nvo3Nve> </nvo3Nves> </nvo3> </filter> </filter> """ CE_NC_MERGE_VNI_BD_ID = """ <config> <nvo3 xmlns="http://www.huawei.com/netconf/vrp" content-version="1.0" format-version="1.0"> <nvo3Vni2Bds> <nvo3Vni2Bd operation="create"> <vniId>%s</vniId> <bdId>%s</bdId> </nvo3Vni2Bd> </nvo3Vni2Bds> </nvo3> </config> """ CE_NC_DELETE_VNI_BD_ID = """ <config> <nvo3 xmlns="http://www.huawei.com/netconf/vrp" content-version="1.0" format-version="1.0"> <nvo3Vni2Bds> <nvo3Vni2Bd operation="delete"> <vniId>%s</vniId> <bdId>%s</bdId> </nvo3Vni2Bd> </nvo3Vni2Bds> </nvo3> </config> """ CE_NC_MERGE_NVE_MODE = """ <config> <nvo3 xmlns="http://www.huawei.com/netconf/vrp" content-version="1.0" format-version="1.0"> <nvo3Nves> <nvo3Nve operation="merge"> <ifName>%s</ifName> <nveType>%s</nveType> </nvo3Nve> </nvo3Nves> </nvo3> </config> """ CE_NC_MERGE_NVE_SOURCE_IP_PROTOCOL = """ <config> <nvo3 xmlns="http://www.huawei.com/netconf/vrp" content-version="1.0" format-version="1.0"> <nvo3Nves> <nvo3Nve operation="merge"> <ifName>%s</ifName> <srcAddr>%s</srcAddr> </nvo3Nve> </nvo3Nves> </nvo3> </config> """ CE_NC_MERGE_VNI_PEER_ADDRESS_IP_HEAD = """ <config> <nvo3 xmlns="http://www.huawei.com/netconf/vrp" content-version="1.0" format-version="1.0"> <nvo3Nves> <nvo3Nve> <ifName>%s</ifName> <vniMembers> <vniMember> <vniId>%s</vniId> """ CE_NC_MERGE_VNI_PEER_ADDRESS_IP_END = """ </vniMember> </vniMembers> </nvo3Nve> </nvo3Nves> </nvo3> </config> """ CE_NC_MERGE_VNI_PEER_ADDRESS_IP_MERGE = """ <nvo3VniPeers> <nvo3VniPeer operation="merge"> <peerAddr>%s</peerAddr> </nvo3VniPeer> </nvo3VniPeers> """ CE_NC_DELETE_VNI_PEER_ADDRESS_IP_HEAD = """ <config> <nvo3 xmlns="http://www.huawei.com/netconf/vrp" content-version="1.0" format-version="1.0"> <nvo3Nves> <nvo3Nve> <ifName>%s</ifName> <vniMembers> <vniMember operation="delete"> <vniId>%s</vniId> """ CE_NC_DELETE_VNI_PEER_ADDRESS_IP_END = """ </vniMember> </vniMembers> </nvo3Nve> </nvo3Nves> </nvo3> </config> """ CE_NC_DELETE_VNI_PEER_ADDRESS_IP_DELETE = """ <nvo3VniPeers> <nvo3VniPeer operation="delete"> <peerAddr>%s</peerAddr> </nvo3VniPeer> </nvo3VniPeers> """ CE_NC_DELETE_PEER_ADDRESS_IP_HEAD = """ <config> <nvo3 xmlns="http://www.huawei.com/netconf/vrp" content-version="1.0" format-version="1.0"> <nvo3Nves> <nvo3Nve> <ifName>%s</ifName> <vniMembers> <vniMember> <vniId>%s</vniId> """ CE_NC_DELETE_PEER_ADDRESS_IP_END = """ </vniMember> </vniMembers> </nvo3Nve> </nvo3Nves> </nvo3> </config> """ CE_NC_MERGE_VNI_PROTOCOL = """ <config> <nvo3 xmlns="http://www.huawei.com/netconf/vrp" content-version="1.0" format-version="1.0"> <nvo3Nves> <nvo3Nve> <ifName>%s</ifName> <vniMembers> <vniMember operation="merge"> <vniId>%s</vniId> <protocol>%s</protocol> </vniMember> </vniMembers> </nvo3Nve> </nvo3Nves> </nvo3> </config> """ CE_NC_DELETE_VNI_PROTOCOL = """ <config> <nvo3 xmlns="http://www.huawei.com/netconf/vrp" content-version="1.0" format-version="1.0"> <nvo3Nves> <nvo3Nve> <ifName>%s</ifName> <vniMembers> <vniMember operation="delete"> <vniId>%s</vniId> <protocol>%s</protocol> </vniMember> </vniMembers> </nvo3Nve> </nvo3Nves> </nvo3> </config> """ def is_valid_address(address): """check ip-address is valid""" if address.find('.') != -1: addr_list = address.split('.') if len(addr_list) != 4: return False for each_num in addr_list: if not each_num.isdigit(): return False if int(each_num) > 255: return False return True return False class VxlanTunnel(object): """ Manages vxlan tunnel configuration. """ def __init__(self, argument_spec): self.spec = argument_spec self.module = None self.init_module() # module input info self.bridge_domain_id = self.module.params['bridge_domain_id'] self.vni_id = self.module.params['vni_id'] self.nve_name = self.module.params['nve_name'] self.nve_mode = self.module.params['nve_mode'] self.peer_list_ip = self.module.params['peer_list_ip'] self.protocol_type = self.module.params['protocol_type'] self.source_ip = self.module.params['source_ip'] self.state = self.module.params['state'] # state self.changed = False self.updates_cmd = list() self.results = dict() self.existing = dict() self.proposed = dict() self.end_state = dict() # configuration nve info self.vni2bd_info = None self.nve_info = None def init_module(self): """ init module """ self.module = AnsibleModule( argument_spec=self.spec, supports_check_mode=True) def check_response(self, xml_str, xml_name): """Check if response message is already succeed.""" if "<ok/>" not in xml_str: self.module.fail_json(msg='Error: %s failed.' % xml_name) def get_current_config(self, vni_id, peer_ip_list): """get current configuration""" flags = list() exp = " | include vni " exp += vni_id exp += " head-end peer-list " for peer_ip in peer_ip_list: exp += "| exclude %s " % peer_ip flags.append(exp) return get_config(self.module, flags) def get_vni2bd_dict(self): """ get vni2bd attributes dict.""" vni2bd_info = dict() # get vni bd info conf_str = CE_NC_GET_VNI_BD_INFO xml_str = get_nc_config(self.module, conf_str) if "<data/>" in xml_str: return vni2bd_info xml_str = xml_str.replace('\r', '').replace('\n', '').\ replace('xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"', "").\ replace('xmlns="http://www.huawei.com/netconf/vrp"', "") # get vni to bridge domain id info root = ElementTree.fromstring(xml_str) vni2bd_info["vni2BdInfos"] = list() vni2bds = root.findall("data/nvo3/nvo3Vni2Bds/nvo3Vni2Bd") if vni2bds: for vni2bd in vni2bds: vni_dict = dict() for ele in vni2bd: if ele.tag in ["vniId", "bdId"]: vni_dict[ele.tag] = ele.text vni2bd_info["vni2BdInfos"].append(vni_dict) return vni2bd_info def check_nve_interface(self, nve_name): """is nve interface exist""" if not self.nve_info: return False if self.nve_info["ifName"] == nve_name: return True return False def get_nve_dict(self, nve_name): """ get nve interface attributes dict.""" nve_info = dict() # get nve info conf_str = CE_NC_GET_NVE_INFO % nve_name xml_str = get_nc_config(self.module, conf_str) if "<data/>" in xml_str: return nve_info xml_str = xml_str.replace('\r', '').replace('\n', '').\ replace('xmlns="urn:ietf:params:xml:ns:netconf:base:1.0"', "").\ replace('xmlns="http://www.huawei.com/netconf/vrp"', "") # get nve info root = ElementTree.fromstring(xml_str) nvo3 = root.find("data/nvo3/nvo3Nves/nvo3Nve") if nvo3: for nve in nvo3: if nve.tag in ["srcAddr", "ifName", "nveType"]: nve_info[nve.tag] = nve.text # get nve vni info nve_info["vni_peer_protocols"] = list() vni_members = root.findall( "data/nvo3/nvo3Nves/nvo3Nve/vniMembers/vniMember") if vni_members: for member in vni_members: vni_dict = dict() for ele in member: if ele.tag in ["vniId", "protocol"]: vni_dict[ele.tag] = ele.text nve_info["vni_peer_protocols"].append(vni_dict) # get vni peer address ip info nve_info["vni_peer_ips"] = list() vni_peers = root.findall( "data/nvo3/nvo3Nves/nvo3Nve/vniMembers/vniMember/nvo3VniPeers/nvo3VniPeer") if vni_peers: for peer_address in vni_peers: vni_peer_dict = dict() for ele in peer_address: if ele.tag in ["vniId", "peerAddr"]: vni_peer_dict[ele.tag] = ele.text nve_info["vni_peer_ips"].append(vni_peer_dict) return nve_info def check_nve_name(self): """Gets Nve interface name""" if self.nve_name is None: return False if self.nve_name in ["Nve1", "Nve2"]: return True return False def is_vni_bd_exist(self, vni_id, bd_id): """is vni to bridge-domain-id exist""" if not self.vni2bd_info: return False for vni2bd in self.vni2bd_info["vni2BdInfos"]: if vni2bd["vniId"] == vni_id and vni2bd["bdId"] == bd_id: return True return False def is_vni_bd_change(self, vni_id, bd_id): """is vni to bridge-domain-id change""" if not self.vni2bd_info: return True for vni2bd in self.vni2bd_info["vni2BdInfos"]: if vni2bd["vniId"] == vni_id and vni2bd["bdId"] == bd_id: return False return True def is_nve_mode_exist(self, nve_name, mode): """is nve interface mode exist""" if not self.nve_info: return False if self.nve_info["ifName"] == nve_name and self.nve_info["nveType"] == mode: return True return False def is_nve_mode_change(self, nve_name, mode): """is nve interface mode change""" if not self.nve_info: return True if self.nve_info["ifName"] == nve_name and self.nve_info["nveType"] == mode: return False return True def is_nve_source_ip_exist(self, nve_name, source_ip): """is vni to bridge-domain-id exist""" if not self.nve_info: return False if self.nve_info["ifName"] == nve_name and self.nve_info["srcAddr"] == source_ip: return True return False def is_nve_source_ip_change(self, nve_name, source_ip): """is vni to bridge-domain-id change""" if not self.nve_info: return True if self.nve_info["ifName"] == nve_name and self.nve_info["srcAddr"] == source_ip: return False return True def is_vni_protocol_exist(self, nve_name, vni_id, protocol_type): """is vni protocol exist""" if not self.nve_info: return False if self.nve_info["ifName"] == nve_name: for member in self.nve_info["vni_peer_protocols"]: if member["vniId"] == vni_id and member["protocol"] == protocol_type: return True return False def is_vni_protocol_change(self, nve_name, vni_id, protocol_type): """is vni protocol change""" if not self.nve_info: return True if self.nve_info["ifName"] == nve_name: for member in self.nve_info["vni_peer_protocols"]: if member["vniId"] == vni_id and member["protocol"] == protocol_type: return False return True def is_vni_peer_list_exist(self, nve_name, vni_id, peer_ip): """is vni peer list exist""" if not self.nve_info: return False if self.nve_info["ifName"] == nve_name: for member in self.nve_info["vni_peer_ips"]: if member["vniId"] == vni_id and member["peerAddr"] == peer_ip: return True return False def is_vni_peer_list_change(self, nve_name, vni_id, peer_ip_list): """is vni peer list change""" if not self.nve_info: return True for peer_ip in peer_ip_list: if self.nve_info["ifName"] == nve_name: if not self.nve_info["vni_peer_ips"]: return True for member in self.nve_info["vni_peer_ips"]: if member["vniId"] != vni_id: return True elif member["vniId"] == vni_id and member["peerAddr"] != peer_ip: return True return False def config_merge_vni2bd(self, bd_id, vni_id): """config vni to bd id""" if self.is_vni_bd_change(vni_id, bd_id): cfg_xml = CE_NC_MERGE_VNI_BD_ID % (vni_id, bd_id) recv_xml = set_nc_config(self.module, cfg_xml) self.check_response(recv_xml, "MERGE_VNI_BD") self.updates_cmd.append("bridge-domain %s" % bd_id) self.updates_cmd.append("vxlan vni %s" % vni_id) self.changed = True def config_merge_mode(self, nve_name, mode): """config nve mode""" if self.is_nve_mode_change(nve_name, mode): cfg_xml = CE_NC_MERGE_NVE_MODE % (nve_name, mode) recv_xml = set_nc_config(self.module, cfg_xml) self.check_response(recv_xml, "MERGE_MODE") self.updates_cmd.append("interface %s" % nve_name) self.updates_cmd.append("mode l3") self.changed = True def config_merge_source_ip(self, nve_name, source_ip): """config nve source ip""" if self.is_nve_source_ip_change(nve_name, source_ip): cfg_xml = CE_NC_MERGE_NVE_SOURCE_IP_PROTOCOL % ( nve_name, source_ip) recv_xml = set_nc_config(self.module, cfg_xml) self.check_response(recv_xml, "MERGE_SOURCE_IP") self.updates_cmd.append("interface %s" % nve_name) self.updates_cmd.append("source %s" % source_ip) self.changed = True def config_merge_vni_peer_ip(self, nve_name, vni_id, peer_ip_list): """config vni peer ip""" if self.is_vni_peer_list_change(nve_name, vni_id, peer_ip_list): cfg_xml = CE_NC_MERGE_VNI_PEER_ADDRESS_IP_HEAD % ( nve_name, vni_id) for peer_ip in peer_ip_list: cfg_xml += CE_NC_MERGE_VNI_PEER_ADDRESS_IP_MERGE % peer_ip cfg_xml += CE_NC_MERGE_VNI_PEER_ADDRESS_IP_END recv_xml = set_nc_config(self.module, cfg_xml) self.check_response(recv_xml, "MERGE_VNI_PEER_IP") self.updates_cmd.append("interface %s" % nve_name) for peer_ip in peer_ip_list: cmd_output = "vni %s head-end peer-list %s" % (vni_id, peer_ip) self.updates_cmd.append(cmd_output) self.changed = True def config_merge_vni_protocol_type(self, nve_name, vni_id, protocol_type): """config vni protocol type""" if self.is_vni_protocol_change(nve_name, vni_id, protocol_type): cfg_xml = CE_NC_MERGE_VNI_PROTOCOL % ( nve_name, vni_id, protocol_type) recv_xml = set_nc_config(self.module, cfg_xml) self.check_response(recv_xml, "MERGE_VNI_PEER_PROTOCOL") self.updates_cmd.append("interface %s" % nve_name) if protocol_type == "bgp": self.updates_cmd.append( "vni %s head-end peer-list protocol %s" % (vni_id, protocol_type)) else: self.updates_cmd.append( "undo vni %s head-end peer-list protocol bgp" % vni_id) self.changed = True def config_delete_vni2bd(self, bd_id, vni_id): """remove vni to bd id""" if not self.is_vni_bd_exist(vni_id, bd_id): return cfg_xml = CE_NC_DELETE_VNI_BD_ID % (vni_id, bd_id) recv_xml = set_nc_config(self.module, cfg_xml) self.check_response(recv_xml, "DELETE_VNI_BD") self.updates_cmd.append( "bridge-domain %s" % bd_id) self.updates_cmd.append( "undo vxlan vni %s" % vni_id) self.changed = True def config_delete_mode(self, nve_name, mode): """nve mode""" if mode == "mode-l3": if not self.is_nve_mode_exist(nve_name, mode): return cfg_xml = CE_NC_MERGE_NVE_MODE % (nve_name, "mode-l2") recv_xml = set_nc_config(self.module, cfg_xml) self.check_response(recv_xml, "DELETE_MODE") self.updates_cmd.append("interface %s" % nve_name) self.updates_cmd.append("undo mode l3") self.changed = True else: self.module.fail_json( msg='Error: Can not configure undo mode l2.') def config_delete_source_ip(self, nve_name, source_ip): """nve source ip""" if not self.is_nve_source_ip_exist(nve_name, source_ip): return ipaddr = "0.0.0.0" cfg_xml = CE_NC_MERGE_NVE_SOURCE_IP_PROTOCOL % ( nve_name, ipaddr) recv_xml = set_nc_config(self.module, cfg_xml) self.check_response(recv_xml, "DELETE_SOURCE_IP") self.updates_cmd.append("interface %s" % nve_name) self.updates_cmd.append("undo source %s" % source_ip) self.changed = True def config_delete_vni_peer_ip(self, nve_name, vni_id, peer_ip_list): """remove vni peer ip""" for peer_ip in peer_ip_list: if not self.is_vni_peer_list_exist(nve_name, vni_id, peer_ip): self.module.fail_json(msg='Error: The %s does not exist' % peer_ip) config = self.get_current_config(vni_id, peer_ip_list) if not config: cfg_xml = CE_NC_DELETE_VNI_PEER_ADDRESS_IP_HEAD % ( nve_name, vni_id) for peer_ip in peer_ip_list: cfg_xml += CE_NC_DELETE_VNI_PEER_ADDRESS_IP_DELETE % peer_ip cfg_xml += CE_NC_DELETE_VNI_PEER_ADDRESS_IP_END else: cfg_xml = CE_NC_DELETE_PEER_ADDRESS_IP_HEAD % ( nve_name, vni_id) for peer_ip in peer_ip_list: cfg_xml += CE_NC_DELETE_VNI_PEER_ADDRESS_IP_DELETE % peer_ip cfg_xml += CE_NC_DELETE_PEER_ADDRESS_IP_END recv_xml = set_nc_config(self.module, cfg_xml) self.check_response(recv_xml, "DELETE_VNI_PEER_IP") self.updates_cmd.append("interface %s" % nve_name) for peer_ip in peer_ip_list: cmd_output = "undo vni %s head-end peer-list %s" % (vni_id, peer_ip) self.updates_cmd.append(cmd_output) self.changed = True def config_delete_vni_protocol_type(self, nve_name, vni_id, protocol_type): """remove vni protocol type""" if not self.is_vni_protocol_exist(nve_name, vni_id, protocol_type): return cfg_xml = CE_NC_DELETE_VNI_PROTOCOL % (nve_name, vni_id, protocol_type) recv_xml = set_nc_config(self.module, cfg_xml) self.check_response(recv_xml, "DELETE_VNI_PEER_PROTOCOL") self.updates_cmd.append("interface %s" % nve_name) self.updates_cmd.append( "undo vni %s head-end peer-list protocol bgp " % vni_id) self.changed = True def check_params(self): """Check all input params""" # bridge_domain_id check if self.bridge_domain_id: if not self.bridge_domain_id.isdigit(): self.module.fail_json( msg='Error: The parameter of bridge domain id is invalid.') if int(self.bridge_domain_id) > 16777215 or int(self.bridge_domain_id) < 1: self.module.fail_json( msg='Error: The bridge domain id must be an integer between 1 and 16777215.') # vni_id check if self.vni_id: if not self.vni_id.isdigit(): self.module.fail_json( msg='Error: The parameter of vni id is invalid.') if int(self.vni_id) > 16000000 or int(self.vni_id) < 1: self.module.fail_json( msg='Error: The vni id must be an integer between 1 and 16000000.') # nve_name check if self.nve_name: if not self.check_nve_name(): self.module.fail_json( msg='Error: Error: NVE interface %s is invalid.' % self.nve_name) # peer_list_ip check if self.peer_list_ip: for peer_ip in self.peer_list_ip: if not is_valid_address(peer_ip): self.module.fail_json( msg='Error: The ip address %s is invalid.' % self.peer_list_ip) # source_ip check if self.source_ip: if not is_valid_address(self.source_ip): self.module.fail_json( msg='Error: The ip address %s is invalid.' % self.source_ip) def get_proposed(self): """get proposed info""" if self.bridge_domain_id: self.proposed["bridge_domain_id"] = self.bridge_domain_id if self.vni_id: self.proposed["vni_id"] = self.vni_id if self.nve_name: self.proposed["nve_name"] = self.nve_name if self.nve_mode: self.proposed["nve_mode"] = self.nve_mode if self.peer_list_ip: self.proposed["peer_list_ip"] = self.peer_list_ip if self.source_ip: self.proposed["source_ip"] = self.source_ip if self.state: self.proposed["state"] = self.state def get_existing(self): """get existing info""" if self.vni2bd_info: self.existing["vni_to_bridge_domain"] = self.vni2bd_info[ "vni2BdInfos"] if self.nve_info: self.existing["nve_interface_name"] = self.nve_info["ifName"] self.existing["source_ip"] = self.nve_info["srcAddr"] self.existing["nve_mode"] = self.nve_info["nveType"] self.existing["vni_peer_list_ip"] = self.nve_info[ "vni_peer_ips"] self.existing["vni_peer_list_protocol"] = self.nve_info[ "vni_peer_protocols"] def get_end_state(self): """get end state info""" vni2bd_info = self.get_vni2bd_dict() if vni2bd_info: self.end_state["vni_to_bridge_domain"] = vni2bd_info["vni2BdInfos"] nve_info = self.get_nve_dict(self.nve_name) if nve_info: self.end_state["nve_interface_name"] = nve_info["ifName"] self.end_state["source_ip"] = nve_info["srcAddr"] self.end_state["nve_mode"] = nve_info["nveType"] self.end_state["vni_peer_list_ip"] = nve_info[ "vni_peer_ips"] self.end_state["vni_peer_list_protocol"] = nve_info[ "vni_peer_protocols"] def work(self): """worker""" self.check_params() self.vni2bd_info = self.get_vni2bd_dict() if self.nve_name: self.nve_info = self.get_nve_dict(self.nve_name) self.get_existing() self.get_proposed() # deal present or absent if self.state == "present": if self.bridge_domain_id and self.vni_id: self.config_merge_vni2bd(self.bridge_domain_id, self.vni_id) if self.nve_name: if self.check_nve_interface(self.nve_name): if self.nve_mode: self.config_merge_mode(self.nve_name, self.nve_mode) if self.source_ip: self.config_merge_source_ip( self.nve_name, self.source_ip) if self.vni_id and self.peer_list_ip: self.config_merge_vni_peer_ip( self.nve_name, self.vni_id, self.peer_list_ip) if self.vni_id and self.protocol_type: self.config_merge_vni_protocol_type( self.nve_name, self.vni_id, self.protocol_type) else: self.module.fail_json( msg='Error: Nve interface %s does not exist.' % self.nve_name) else: if self.bridge_domain_id and self.vni_id: self.config_delete_vni2bd(self.bridge_domain_id, self.vni_id) if self.nve_name: if self.check_nve_interface(self.nve_name): if self.nve_mode: self.config_delete_mode(self.nve_name, self.nve_mode) if self.source_ip: self.config_delete_source_ip( self.nve_name, self.source_ip) if self.vni_id and self.peer_list_ip: self.config_delete_vni_peer_ip( self.nve_name, self.vni_id, self.peer_list_ip) if self.vni_id and self.protocol_type: self.config_delete_vni_protocol_type( self.nve_name, self.vni_id, self.protocol_type) else: self.module.fail_json( msg='Error: Nve interface %s does not exist.' % self.nve_name) self.get_end_state() self.results['changed'] = self.changed self.results['proposed'] = self.proposed self.results['existing'] = self.existing self.results['end_state'] = self.end_state if self.changed: self.results['updates'] = self.updates_cmd else: self.results['updates'] = list() self.module.exit_json(**self.results) def main(): """Module main""" argument_spec = dict( bridge_domain_id=dict(required=False), vni_id=dict(required=False, type='str'), nve_name=dict(required=False, type='str'), nve_mode=dict(required=False, choices=['mode-l2', 'mode-l3']), peer_list_ip=dict(required=False, type='list'), protocol_type=dict(required=False, type='str', choices=[ 'bgp', 'null']), source_ip=dict(required=False), state=dict(required=False, default='present', choices=['present', 'absent']) ) argument_spec.update(ce_argument_spec) module = VxlanTunnel(argument_spec) module.work() if __name__ == '__main__': main()
gpl-3.0
Viyom/Implementation-of-TCP-Delayed-Congestion-Response--DCR--in-ns-3
src/aodv/bindings/modulegen__gcc_LP64.py
14
532920
from pybindgen import Module, FileCodeSink, param, retval, cppclass, typehandlers import pybindgen.settings import warnings class ErrorHandler(pybindgen.settings.ErrorHandler): def handle_error(self, wrapper, exception, traceback_): warnings.warn("exception %r in wrapper %s" % (exception, wrapper)) return True pybindgen.settings.error_handler = ErrorHandler() import sys def module_init(): root_module = Module('ns.aodv', cpp_namespace='::ns3') return root_module def register_types(module): root_module = module.get_root() ## wifi-mac-header.h (module 'wifi'): ns3::WifiMacType [enumeration] module.add_enum('WifiMacType', ['WIFI_MAC_CTL_CTLWRAPPER', 'WIFI_MAC_CTL_RTS', 'WIFI_MAC_CTL_CTS', 'WIFI_MAC_CTL_ACK', 'WIFI_MAC_CTL_BACKREQ', 'WIFI_MAC_CTL_BACKRESP', 'WIFI_MAC_MGT_BEACON', 'WIFI_MAC_MGT_ASSOCIATION_REQUEST', 'WIFI_MAC_MGT_ASSOCIATION_RESPONSE', 'WIFI_MAC_MGT_DISASSOCIATION', 'WIFI_MAC_MGT_REASSOCIATION_REQUEST', 'WIFI_MAC_MGT_REASSOCIATION_RESPONSE', 'WIFI_MAC_MGT_PROBE_REQUEST', 'WIFI_MAC_MGT_PROBE_RESPONSE', 'WIFI_MAC_MGT_AUTHENTICATION', 'WIFI_MAC_MGT_DEAUTHENTICATION', 'WIFI_MAC_MGT_ACTION', 'WIFI_MAC_MGT_ACTION_NO_ACK', 'WIFI_MAC_MGT_MULTIHOP_ACTION', 'WIFI_MAC_DATA', 'WIFI_MAC_DATA_CFACK', 'WIFI_MAC_DATA_CFPOLL', 'WIFI_MAC_DATA_CFACK_CFPOLL', 'WIFI_MAC_DATA_NULL', 'WIFI_MAC_DATA_NULL_CFACK', 'WIFI_MAC_DATA_NULL_CFPOLL', 'WIFI_MAC_DATA_NULL_CFACK_CFPOLL', 'WIFI_MAC_QOSDATA', 'WIFI_MAC_QOSDATA_CFACK', 'WIFI_MAC_QOSDATA_CFPOLL', 'WIFI_MAC_QOSDATA_CFACK_CFPOLL', 'WIFI_MAC_QOSDATA_NULL', 'WIFI_MAC_QOSDATA_NULL_CFPOLL', 'WIFI_MAC_QOSDATA_NULL_CFACK_CFPOLL'], import_from_module='ns.wifi') ## address.h (module 'network'): ns3::Address [class] module.add_class('Address', import_from_module='ns.network') ## address.h (module 'network'): ns3::Address::MaxSize_e [enumeration] module.add_enum('MaxSize_e', ['MAX_SIZE'], outer_class=root_module['ns3::Address'], import_from_module='ns.network') ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList [class] module.add_class('AttributeConstructionList', import_from_module='ns.core') ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item [struct] module.add_class('Item', import_from_module='ns.core', outer_class=root_module['ns3::AttributeConstructionList']) ## buffer.h (module 'network'): ns3::Buffer [class] module.add_class('Buffer', import_from_module='ns.network') ## buffer.h (module 'network'): ns3::Buffer::Iterator [class] module.add_class('Iterator', import_from_module='ns.network', outer_class=root_module['ns3::Buffer']) ## packet.h (module 'network'): ns3::ByteTagIterator [class] module.add_class('ByteTagIterator', import_from_module='ns.network') ## packet.h (module 'network'): ns3::ByteTagIterator::Item [class] module.add_class('Item', import_from_module='ns.network', outer_class=root_module['ns3::ByteTagIterator']) ## byte-tag-list.h (module 'network'): ns3::ByteTagList [class] module.add_class('ByteTagList', import_from_module='ns.network') ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator [class] module.add_class('Iterator', import_from_module='ns.network', outer_class=root_module['ns3::ByteTagList']) ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item [struct] module.add_class('Item', import_from_module='ns.network', outer_class=root_module['ns3::ByteTagList::Iterator']) ## callback.h (module 'core'): ns3::CallbackBase [class] module.add_class('CallbackBase', import_from_module='ns.core') ## event-id.h (module 'core'): ns3::EventId [class] module.add_class('EventId', import_from_module='ns.core') ## hash.h (module 'core'): ns3::Hasher [class] module.add_class('Hasher', import_from_module='ns.core') ## inet6-socket-address.h (module 'network'): ns3::Inet6SocketAddress [class] module.add_class('Inet6SocketAddress', import_from_module='ns.network') ## inet6-socket-address.h (module 'network'): ns3::Inet6SocketAddress [class] root_module['ns3::Inet6SocketAddress'].implicitly_converts_to(root_module['ns3::Address']) ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress [class] module.add_class('InetSocketAddress', import_from_module='ns.network') ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress [class] root_module['ns3::InetSocketAddress'].implicitly_converts_to(root_module['ns3::Address']) ## int-to-type.h (module 'core'): ns3::IntToType<0> [struct] module.add_class('IntToType', import_from_module='ns.core', template_parameters=['0']) ## int-to-type.h (module 'core'): ns3::IntToType<0>::v_e [enumeration] module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 0 >'], import_from_module='ns.core') ## int-to-type.h (module 'core'): ns3::IntToType<1> [struct] module.add_class('IntToType', import_from_module='ns.core', template_parameters=['1']) ## int-to-type.h (module 'core'): ns3::IntToType<1>::v_e [enumeration] module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 1 >'], import_from_module='ns.core') ## int-to-type.h (module 'core'): ns3::IntToType<2> [struct] module.add_class('IntToType', import_from_module='ns.core', template_parameters=['2']) ## int-to-type.h (module 'core'): ns3::IntToType<2>::v_e [enumeration] module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 2 >'], import_from_module='ns.core') ## int-to-type.h (module 'core'): ns3::IntToType<3> [struct] module.add_class('IntToType', import_from_module='ns.core', template_parameters=['3']) ## int-to-type.h (module 'core'): ns3::IntToType<3>::v_e [enumeration] module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 3 >'], import_from_module='ns.core') ## int-to-type.h (module 'core'): ns3::IntToType<4> [struct] module.add_class('IntToType', import_from_module='ns.core', template_parameters=['4']) ## int-to-type.h (module 'core'): ns3::IntToType<4>::v_e [enumeration] module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 4 >'], import_from_module='ns.core') ## int-to-type.h (module 'core'): ns3::IntToType<5> [struct] module.add_class('IntToType', import_from_module='ns.core', template_parameters=['5']) ## int-to-type.h (module 'core'): ns3::IntToType<5>::v_e [enumeration] module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 5 >'], import_from_module='ns.core') ## int-to-type.h (module 'core'): ns3::IntToType<6> [struct] module.add_class('IntToType', import_from_module='ns.core', template_parameters=['6']) ## int-to-type.h (module 'core'): ns3::IntToType<6>::v_e [enumeration] module.add_enum('v_e', ['value'], outer_class=root_module['ns3::IntToType< 6 >'], import_from_module='ns.core') ## ipv4-address.h (module 'network'): ns3::Ipv4Address [class] module.add_class('Ipv4Address', import_from_module='ns.network') ## ipv4-address.h (module 'network'): ns3::Ipv4Address [class] root_module['ns3::Ipv4Address'].implicitly_converts_to(root_module['ns3::Address']) ## ipv4-interface-address.h (module 'internet'): ns3::Ipv4InterfaceAddress [class] module.add_class('Ipv4InterfaceAddress', import_from_module='ns.internet') ## ipv4-interface-address.h (module 'internet'): ns3::Ipv4InterfaceAddress::InterfaceAddressScope_e [enumeration] module.add_enum('InterfaceAddressScope_e', ['HOST', 'LINK', 'GLOBAL'], outer_class=root_module['ns3::Ipv4InterfaceAddress'], import_from_module='ns.internet') ## ipv4-address.h (module 'network'): ns3::Ipv4Mask [class] module.add_class('Ipv4Mask', import_from_module='ns.network') ## ipv4-routing-helper.h (module 'internet'): ns3::Ipv4RoutingHelper [class] module.add_class('Ipv4RoutingHelper', allow_subclassing=True, import_from_module='ns.internet') ## ipv6-address.h (module 'network'): ns3::Ipv6Address [class] module.add_class('Ipv6Address', import_from_module='ns.network') ## ipv6-address.h (module 'network'): ns3::Ipv6Address [class] root_module['ns3::Ipv6Address'].implicitly_converts_to(root_module['ns3::Address']) ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix [class] module.add_class('Ipv6Prefix', import_from_module='ns.network') ## mac48-address.h (module 'network'): ns3::Mac48Address [class] module.add_class('Mac48Address', import_from_module='ns.network') ## mac48-address.h (module 'network'): ns3::Mac48Address [class] root_module['ns3::Mac48Address'].implicitly_converts_to(root_module['ns3::Address']) ## node-container.h (module 'network'): ns3::NodeContainer [class] module.add_class('NodeContainer', import_from_module='ns.network') ## object-base.h (module 'core'): ns3::ObjectBase [class] module.add_class('ObjectBase', allow_subclassing=True, import_from_module='ns.core') ## object.h (module 'core'): ns3::ObjectDeleter [struct] module.add_class('ObjectDeleter', import_from_module='ns.core') ## object-factory.h (module 'core'): ns3::ObjectFactory [class] module.add_class('ObjectFactory', import_from_module='ns.core') ## packet-metadata.h (module 'network'): ns3::PacketMetadata [class] module.add_class('PacketMetadata', import_from_module='ns.network') ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item [struct] module.add_class('Item', import_from_module='ns.network', outer_class=root_module['ns3::PacketMetadata']) ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item [enumeration] module.add_enum('', ['PAYLOAD', 'HEADER', 'TRAILER'], outer_class=root_module['ns3::PacketMetadata::Item'], import_from_module='ns.network') ## packet-metadata.h (module 'network'): ns3::PacketMetadata::ItemIterator [class] module.add_class('ItemIterator', import_from_module='ns.network', outer_class=root_module['ns3::PacketMetadata']) ## packet.h (module 'network'): ns3::PacketTagIterator [class] module.add_class('PacketTagIterator', import_from_module='ns.network') ## packet.h (module 'network'): ns3::PacketTagIterator::Item [class] module.add_class('Item', import_from_module='ns.network', outer_class=root_module['ns3::PacketTagIterator']) ## packet-tag-list.h (module 'network'): ns3::PacketTagList [class] module.add_class('PacketTagList', import_from_module='ns.network') ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData [struct] module.add_class('TagData', import_from_module='ns.network', outer_class=root_module['ns3::PacketTagList']) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter> [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Object', 'ns3::ObjectBase', 'ns3::ObjectDeleter'], parent=root_module['ns3::ObjectBase'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## simulator.h (module 'core'): ns3::Simulator [class] module.add_class('Simulator', destructor_visibility='private', import_from_module='ns.core') ## simulator.h (module 'core'): ns3::Simulator [enumeration] module.add_enum('', ['NO_CONTEXT'], outer_class=root_module['ns3::Simulator'], import_from_module='ns.core') ## tag.h (module 'network'): ns3::Tag [class] module.add_class('Tag', import_from_module='ns.network', parent=root_module['ns3::ObjectBase']) ## tag-buffer.h (module 'network'): ns3::TagBuffer [class] module.add_class('TagBuffer', import_from_module='ns.network') ## nstime.h (module 'core'): ns3::TimeWithUnit [class] module.add_class('TimeWithUnit', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer [class] module.add_class('Timer', import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer::DestroyPolicy [enumeration] module.add_enum('DestroyPolicy', ['CANCEL_ON_DESTROY', 'REMOVE_ON_DESTROY', 'CHECK_ON_DESTROY'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') ## timer.h (module 'core'): ns3::Timer::State [enumeration] module.add_enum('State', ['RUNNING', 'EXPIRED', 'SUSPENDED'], outer_class=root_module['ns3::Timer'], import_from_module='ns.core') ## timer-impl.h (module 'core'): ns3::TimerImpl [class] module.add_class('TimerImpl', allow_subclassing=True, import_from_module='ns.core') ## type-id.h (module 'core'): ns3::TypeId [class] module.add_class('TypeId', import_from_module='ns.core') ## type-id.h (module 'core'): ns3::TypeId::AttributeFlag [enumeration] module.add_enum('AttributeFlag', ['ATTR_GET', 'ATTR_SET', 'ATTR_CONSTRUCT', 'ATTR_SGC'], outer_class=root_module['ns3::TypeId'], import_from_module='ns.core') ## type-id.h (module 'core'): ns3::TypeId::SupportLevel [enumeration] module.add_enum('SupportLevel', ['SUPPORTED', 'DEPRECATED', 'OBSOLETE'], outer_class=root_module['ns3::TypeId'], import_from_module='ns.core') ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation [struct] module.add_class('AttributeInformation', import_from_module='ns.core', outer_class=root_module['ns3::TypeId']) ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation [struct] module.add_class('TraceSourceInformation', import_from_module='ns.core', outer_class=root_module['ns3::TypeId']) ## empty.h (module 'core'): ns3::empty [class] module.add_class('empty', import_from_module='ns.core') ## int64x64-double.h (module 'core'): ns3::int64x64_t [class] module.add_class('int64x64_t', import_from_module='ns.core') ## int64x64-double.h (module 'core'): ns3::int64x64_t::impl_type [enumeration] module.add_enum('impl_type', ['int128_impl', 'cairo_impl', 'ld_impl'], outer_class=root_module['ns3::int64x64_t'], import_from_module='ns.core') ## aodv-helper.h (module 'aodv'): ns3::AodvHelper [class] module.add_class('AodvHelper', parent=root_module['ns3::Ipv4RoutingHelper']) ## chunk.h (module 'network'): ns3::Chunk [class] module.add_class('Chunk', import_from_module='ns.network', parent=root_module['ns3::ObjectBase']) ## header.h (module 'network'): ns3::Header [class] module.add_class('Header', import_from_module='ns.network', parent=root_module['ns3::Chunk']) ## ipv4-header.h (module 'internet'): ns3::Ipv4Header [class] module.add_class('Ipv4Header', import_from_module='ns.internet', parent=root_module['ns3::Header']) ## ipv4-header.h (module 'internet'): ns3::Ipv4Header::DscpType [enumeration] module.add_enum('DscpType', ['DscpDefault', 'DSCP_CS1', 'DSCP_AF11', 'DSCP_AF12', 'DSCP_AF13', 'DSCP_CS2', 'DSCP_AF21', 'DSCP_AF22', 'DSCP_AF23', 'DSCP_CS3', 'DSCP_AF31', 'DSCP_AF32', 'DSCP_AF33', 'DSCP_CS4', 'DSCP_AF41', 'DSCP_AF42', 'DSCP_AF43', 'DSCP_CS5', 'DSCP_EF', 'DSCP_CS6', 'DSCP_CS7'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') ## ipv4-header.h (module 'internet'): ns3::Ipv4Header::EcnType [enumeration] module.add_enum('EcnType', ['ECN_NotECT', 'ECN_ECT1', 'ECN_ECT0', 'ECN_CE'], outer_class=root_module['ns3::Ipv4Header'], import_from_module='ns.internet') ## object.h (module 'core'): ns3::Object [class] module.add_class('Object', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter >']) ## object.h (module 'core'): ns3::Object::AggregateIterator [class] module.add_class('AggregateIterator', import_from_module='ns.core', outer_class=root_module['ns3::Object']) ## random-variable-stream.h (module 'core'): ns3::RandomVariableStream [class] module.add_class('RandomVariableStream', import_from_module='ns.core', parent=root_module['ns3::Object']) ## random-variable-stream.h (module 'core'): ns3::SequentialRandomVariable [class] module.add_class('SequentialRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeAccessor', 'ns3::empty', 'ns3::DefaultDeleter<ns3::AttributeAccessor>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeChecker', 'ns3::empty', 'ns3::DefaultDeleter<ns3::AttributeChecker>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::AttributeValue', 'ns3::empty', 'ns3::DefaultDeleter<ns3::AttributeValue>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::CallbackImplBase', 'ns3::empty', 'ns3::DefaultDeleter<ns3::CallbackImplBase>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::EventImpl', 'ns3::empty', 'ns3::DefaultDeleter<ns3::EventImpl>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter<ns3::Hash::Implementation> > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Hash::Implementation', 'ns3::empty', 'ns3::DefaultDeleter<ns3::Hash::Implementation>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Ipv4MulticastRoute, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4MulticastRoute> > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Ipv4MulticastRoute', 'ns3::empty', 'ns3::DefaultDeleter<ns3::Ipv4MulticastRoute>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Ipv4Route, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4Route> > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Ipv4Route', 'ns3::empty', 'ns3::DefaultDeleter<ns3::Ipv4Route>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::NixVector', 'ns3::empty', 'ns3::DefaultDeleter<ns3::NixVector>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::OutputStreamWrapper', 'ns3::empty', 'ns3::DefaultDeleter<ns3::OutputStreamWrapper>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::Packet', 'ns3::empty', 'ns3::DefaultDeleter<ns3::Packet>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> > [class] module.add_class('SimpleRefCount', automatic_type_narrowing=True, import_from_module='ns.core', template_parameters=['ns3::TraceSourceAccessor', 'ns3::empty', 'ns3::DefaultDeleter<ns3::TraceSourceAccessor>'], parent=root_module['ns3::empty'], memory_policy=cppclass.ReferenceCountingMethodsPolicy(incref_method='Ref', decref_method='Unref', peekref_method='GetReferenceCount')) ## socket.h (module 'network'): ns3::Socket [class] module.add_class('Socket', import_from_module='ns.network', parent=root_module['ns3::Object']) ## socket.h (module 'network'): ns3::Socket::SocketErrno [enumeration] module.add_enum('SocketErrno', ['ERROR_NOTERROR', 'ERROR_ISCONN', 'ERROR_NOTCONN', 'ERROR_MSGSIZE', 'ERROR_AGAIN', 'ERROR_SHUTDOWN', 'ERROR_OPNOTSUPP', 'ERROR_AFNOSUPPORT', 'ERROR_INVAL', 'ERROR_BADF', 'ERROR_NOROUTETOHOST', 'ERROR_NODEV', 'ERROR_ADDRNOTAVAIL', 'ERROR_ADDRINUSE', 'SOCKET_ERRNO_LAST'], outer_class=root_module['ns3::Socket'], import_from_module='ns.network') ## socket.h (module 'network'): ns3::Socket::SocketType [enumeration] module.add_enum('SocketType', ['NS3_SOCK_STREAM', 'NS3_SOCK_SEQPACKET', 'NS3_SOCK_DGRAM', 'NS3_SOCK_RAW'], outer_class=root_module['ns3::Socket'], import_from_module='ns.network') ## socket.h (module 'network'): ns3::Socket::SocketPriority [enumeration] module.add_enum('SocketPriority', ['NS3_PRIO_BESTEFFORT', 'NS3_PRIO_FILLER', 'NS3_PRIO_BULK', 'NS3_PRIO_INTERACTIVE_BULK', 'NS3_PRIO_INTERACTIVE', 'NS3_PRIO_CONTROL'], outer_class=root_module['ns3::Socket'], import_from_module='ns.network') ## socket.h (module 'network'): ns3::Socket::Ipv6MulticastFilterMode [enumeration] module.add_enum('Ipv6MulticastFilterMode', ['INCLUDE', 'EXCLUDE'], outer_class=root_module['ns3::Socket'], import_from_module='ns.network') ## socket.h (module 'network'): ns3::SocketIpTosTag [class] module.add_class('SocketIpTosTag', import_from_module='ns.network', parent=root_module['ns3::Tag']) ## socket.h (module 'network'): ns3::SocketIpTtlTag [class] module.add_class('SocketIpTtlTag', import_from_module='ns.network', parent=root_module['ns3::Tag']) ## socket.h (module 'network'): ns3::SocketIpv6HopLimitTag [class] module.add_class('SocketIpv6HopLimitTag', import_from_module='ns.network', parent=root_module['ns3::Tag']) ## socket.h (module 'network'): ns3::SocketIpv6TclassTag [class] module.add_class('SocketIpv6TclassTag', import_from_module='ns.network', parent=root_module['ns3::Tag']) ## socket.h (module 'network'): ns3::SocketPriorityTag [class] module.add_class('SocketPriorityTag', import_from_module='ns.network', parent=root_module['ns3::Tag']) ## socket.h (module 'network'): ns3::SocketSetDontFragmentTag [class] module.add_class('SocketSetDontFragmentTag', import_from_module='ns.network', parent=root_module['ns3::Tag']) ## nstime.h (module 'core'): ns3::Time [class] module.add_class('Time', import_from_module='ns.core') ## nstime.h (module 'core'): ns3::Time::Unit [enumeration] module.add_enum('Unit', ['Y', 'D', 'H', 'MIN', 'S', 'MS', 'US', 'NS', 'PS', 'FS', 'LAST'], outer_class=root_module['ns3::Time'], import_from_module='ns.core') ## nstime.h (module 'core'): ns3::Time [class] root_module['ns3::Time'].implicitly_converts_to(root_module['ns3::int64x64_t']) ## trace-source-accessor.h (module 'core'): ns3::TraceSourceAccessor [class] module.add_class('TraceSourceAccessor', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >']) ## trailer.h (module 'network'): ns3::Trailer [class] module.add_class('Trailer', import_from_module='ns.network', parent=root_module['ns3::Chunk']) ## random-variable-stream.h (module 'core'): ns3::TriangularRandomVariable [class] module.add_class('TriangularRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## random-variable-stream.h (module 'core'): ns3::UniformRandomVariable [class] module.add_class('UniformRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## random-variable-stream.h (module 'core'): ns3::WeibullRandomVariable [class] module.add_class('WeibullRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## wifi-mac-header.h (module 'wifi'): ns3::WifiMacHeader [class] module.add_class('WifiMacHeader', import_from_module='ns.wifi', parent=root_module['ns3::Header']) ## wifi-mac-header.h (module 'wifi'): ns3::WifiMacHeader::QosAckPolicy [enumeration] module.add_enum('QosAckPolicy', ['NORMAL_ACK', 'NO_ACK', 'NO_EXPLICIT_ACK', 'BLOCK_ACK'], outer_class=root_module['ns3::WifiMacHeader'], import_from_module='ns.wifi') ## wifi-mac-header.h (module 'wifi'): ns3::WifiMacHeader::AddressType [enumeration] module.add_enum('AddressType', ['ADDR1', 'ADDR2', 'ADDR3', 'ADDR4'], outer_class=root_module['ns3::WifiMacHeader'], import_from_module='ns.wifi') ## random-variable-stream.h (module 'core'): ns3::ZetaRandomVariable [class] module.add_class('ZetaRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## random-variable-stream.h (module 'core'): ns3::ZipfRandomVariable [class] module.add_class('ZipfRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## arp-cache.h (module 'internet'): ns3::ArpCache [class] module.add_class('ArpCache', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## arp-cache.h (module 'internet'): ns3::ArpCache::Entry [class] module.add_class('Entry', import_from_module='ns.internet', outer_class=root_module['ns3::ArpCache']) ## attribute.h (module 'core'): ns3::AttributeAccessor [class] module.add_class('AttributeAccessor', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >']) ## attribute.h (module 'core'): ns3::AttributeChecker [class] module.add_class('AttributeChecker', allow_subclassing=False, automatic_type_narrowing=True, import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >']) ## attribute.h (module 'core'): ns3::AttributeValue [class] module.add_class('AttributeValue', allow_subclassing=False, automatic_type_narrowing=True, import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >']) ## callback.h (module 'core'): ns3::CallbackChecker [class] module.add_class('CallbackChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker']) ## callback.h (module 'core'): ns3::CallbackImplBase [class] module.add_class('CallbackImplBase', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >']) ## callback.h (module 'core'): ns3::CallbackValue [class] module.add_class('CallbackValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue']) ## random-variable-stream.h (module 'core'): ns3::ConstantRandomVariable [class] module.add_class('ConstantRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## random-variable-stream.h (module 'core'): ns3::DeterministicRandomVariable [class] module.add_class('DeterministicRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## random-variable-stream.h (module 'core'): ns3::EmpiricalRandomVariable [class] module.add_class('EmpiricalRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## attribute.h (module 'core'): ns3::EmptyAttributeAccessor [class] module.add_class('EmptyAttributeAccessor', import_from_module='ns.core', parent=root_module['ns3::AttributeAccessor']) ## attribute.h (module 'core'): ns3::EmptyAttributeChecker [class] module.add_class('EmptyAttributeChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker']) ## attribute.h (module 'core'): ns3::EmptyAttributeValue [class] module.add_class('EmptyAttributeValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue']) ## enum.h (module 'core'): ns3::EnumChecker [class] module.add_class('EnumChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker']) ## enum.h (module 'core'): ns3::EnumValue [class] module.add_class('EnumValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue']) ## random-variable-stream.h (module 'core'): ns3::ErlangRandomVariable [class] module.add_class('ErlangRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## event-impl.h (module 'core'): ns3::EventImpl [class] module.add_class('EventImpl', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >']) ## random-variable-stream.h (module 'core'): ns3::ExponentialRandomVariable [class] module.add_class('ExponentialRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## random-variable-stream.h (module 'core'): ns3::GammaRandomVariable [class] module.add_class('GammaRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## ipv4.h (module 'internet'): ns3::Ipv4 [class] module.add_class('Ipv4', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker [class] module.add_class('Ipv4AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker']) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressValue [class] module.add_class('Ipv4AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## ipv4-interface.h (module 'internet'): ns3::Ipv4Interface [class] module.add_class('Ipv4Interface', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv4-l3-protocol.h (module 'internet'): ns3::Ipv4L3Protocol [class] module.add_class('Ipv4L3Protocol', import_from_module='ns.internet', parent=root_module['ns3::Ipv4']) ## ipv4-l3-protocol.h (module 'internet'): ns3::Ipv4L3Protocol::DropReason [enumeration] module.add_enum('DropReason', ['DROP_TTL_EXPIRED', 'DROP_NO_ROUTE', 'DROP_BAD_CHECKSUM', 'DROP_INTERFACE_DOWN', 'DROP_ROUTE_ERROR', 'DROP_FRAGMENT_TIMEOUT'], outer_class=root_module['ns3::Ipv4L3Protocol'], import_from_module='ns.internet') ## ipv4-address.h (module 'network'): ns3::Ipv4MaskChecker [class] module.add_class('Ipv4MaskChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker']) ## ipv4-address.h (module 'network'): ns3::Ipv4MaskValue [class] module.add_class('Ipv4MaskValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## ipv4-route.h (module 'internet'): ns3::Ipv4MulticastRoute [class] module.add_class('Ipv4MulticastRoute', import_from_module='ns.internet', parent=root_module['ns3::SimpleRefCount< ns3::Ipv4MulticastRoute, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4MulticastRoute> >']) ## ipv4-route.h (module 'internet'): ns3::Ipv4Route [class] module.add_class('Ipv4Route', import_from_module='ns.internet', parent=root_module['ns3::SimpleRefCount< ns3::Ipv4Route, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4Route> >']) ## ipv4-routing-protocol.h (module 'internet'): ns3::Ipv4RoutingProtocol [class] module.add_class('Ipv4RoutingProtocol', import_from_module='ns.internet', parent=root_module['ns3::Object']) ## ipv6-address.h (module 'network'): ns3::Ipv6AddressChecker [class] module.add_class('Ipv6AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker']) ## ipv6-address.h (module 'network'): ns3::Ipv6AddressValue [class] module.add_class('Ipv6AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker [class] module.add_class('Ipv6PrefixChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker']) ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixValue [class] module.add_class('Ipv6PrefixValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## random-variable-stream.h (module 'core'): ns3::LogNormalRandomVariable [class] module.add_class('LogNormalRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## mac48-address.h (module 'network'): ns3::Mac48AddressChecker [class] module.add_class('Mac48AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker']) ## mac48-address.h (module 'network'): ns3::Mac48AddressValue [class] module.add_class('Mac48AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## net-device.h (module 'network'): ns3::NetDevice [class] module.add_class('NetDevice', import_from_module='ns.network', parent=root_module['ns3::Object']) ## net-device.h (module 'network'): ns3::NetDevice::PacketType [enumeration] module.add_enum('PacketType', ['PACKET_HOST', 'NS3_PACKET_HOST', 'PACKET_BROADCAST', 'NS3_PACKET_BROADCAST', 'PACKET_MULTICAST', 'NS3_PACKET_MULTICAST', 'PACKET_OTHERHOST', 'NS3_PACKET_OTHERHOST'], outer_class=root_module['ns3::NetDevice'], import_from_module='ns.network') ## nix-vector.h (module 'network'): ns3::NixVector [class] module.add_class('NixVector', import_from_module='ns.network', parent=root_module['ns3::SimpleRefCount< ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >']) ## node.h (module 'network'): ns3::Node [class] module.add_class('Node', import_from_module='ns.network', parent=root_module['ns3::Object']) ## random-variable-stream.h (module 'core'): ns3::NormalRandomVariable [class] module.add_class('NormalRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## object-factory.h (module 'core'): ns3::ObjectFactoryChecker [class] module.add_class('ObjectFactoryChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker']) ## object-factory.h (module 'core'): ns3::ObjectFactoryValue [class] module.add_class('ObjectFactoryValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue']) ## output-stream-wrapper.h (module 'network'): ns3::OutputStreamWrapper [class] module.add_class('OutputStreamWrapper', import_from_module='ns.network', parent=root_module['ns3::SimpleRefCount< ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >']) ## packet.h (module 'network'): ns3::Packet [class] module.add_class('Packet', import_from_module='ns.network', parent=root_module['ns3::SimpleRefCount< ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >']) ## random-variable-stream.h (module 'core'): ns3::ParetoRandomVariable [class] module.add_class('ParetoRandomVariable', import_from_module='ns.core', parent=root_module['ns3::RandomVariableStream']) ## nstime.h (module 'core'): ns3::TimeValue [class] module.add_class('TimeValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue']) ## type-id.h (module 'core'): ns3::TypeIdChecker [class] module.add_class('TypeIdChecker', import_from_module='ns.core', parent=root_module['ns3::AttributeChecker']) ## type-id.h (module 'core'): ns3::TypeIdValue [class] module.add_class('TypeIdValue', import_from_module='ns.core', parent=root_module['ns3::AttributeValue']) ## address.h (module 'network'): ns3::AddressChecker [class] module.add_class('AddressChecker', import_from_module='ns.network', parent=root_module['ns3::AttributeChecker']) ## address.h (module 'network'): ns3::AddressValue [class] module.add_class('AddressValue', import_from_module='ns.network', parent=root_module['ns3::AttributeValue']) ## ipv4-list-routing.h (module 'internet'): ns3::Ipv4ListRouting [class] module.add_class('Ipv4ListRouting', import_from_module='ns.internet', parent=root_module['ns3::Ipv4RoutingProtocol']) module.add_container('std::vector< ns3::Ipv6Address >', 'ns3::Ipv6Address', container_type=u'vector') module.add_container('std::list< std::pair< ns3::Ptr< ns3::Packet >, ns3::Ipv4Header > >', 'std::pair< ns3::Ptr< ns3::Packet >, ns3::Ipv4Header >', container_type=u'list') module.add_container('std::list< ns3::ArpCache::Entry * >', 'ns3::ArpCache::Entry *', container_type=u'list') module.add_container('std::map< unsigned int, unsigned int >', ('unsigned int', 'unsigned int'), container_type=u'map') ## Register a nested module for the namespace FatalImpl nested_module = module.add_cpp_namespace('FatalImpl') register_types_ns3_FatalImpl(nested_module) ## Register a nested module for the namespace Hash nested_module = module.add_cpp_namespace('Hash') register_types_ns3_Hash(nested_module) ## Register a nested module for the namespace TracedValueCallback nested_module = module.add_cpp_namespace('TracedValueCallback') register_types_ns3_TracedValueCallback(nested_module) ## Register a nested module for the namespace aodv nested_module = module.add_cpp_namespace('aodv') register_types_ns3_aodv(nested_module) def register_types_ns3_FatalImpl(module): root_module = module.get_root() def register_types_ns3_Hash(module): root_module = module.get_root() ## hash-function.h (module 'core'): ns3::Hash::Implementation [class] module.add_class('Implementation', import_from_module='ns.core', parent=root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter<ns3::Hash::Implementation> >']) typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash64Function_ptr') typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash64Function_ptr*') typehandlers.add_type_alias(u'uint64_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash64Function_ptr&') typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *', u'ns3::Hash::Hash32Function_ptr') typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) **', u'ns3::Hash::Hash32Function_ptr*') typehandlers.add_type_alias(u'uint32_t ( * ) ( char const *, size_t ) *&', u'ns3::Hash::Hash32Function_ptr&') ## Register a nested module for the namespace Function nested_module = module.add_cpp_namespace('Function') register_types_ns3_Hash_Function(nested_module) def register_types_ns3_Hash_Function(module): root_module = module.get_root() ## hash-fnv.h (module 'core'): ns3::Hash::Function::Fnv1a [class] module.add_class('Fnv1a', import_from_module='ns.core', parent=root_module['ns3::Hash::Implementation']) ## hash-function.h (module 'core'): ns3::Hash::Function::Hash32 [class] module.add_class('Hash32', import_from_module='ns.core', parent=root_module['ns3::Hash::Implementation']) ## hash-function.h (module 'core'): ns3::Hash::Function::Hash64 [class] module.add_class('Hash64', import_from_module='ns.core', parent=root_module['ns3::Hash::Implementation']) ## hash-murmur3.h (module 'core'): ns3::Hash::Function::Murmur3 [class] module.add_class('Murmur3', import_from_module='ns.core', parent=root_module['ns3::Hash::Implementation']) def register_types_ns3_TracedValueCallback(module): root_module = module.get_root() typehandlers.add_type_alias(u'void ( * ) ( ns3::Time, ns3::Time ) *', u'ns3::TracedValueCallback::Time') typehandlers.add_type_alias(u'void ( * ) ( ns3::Time, ns3::Time ) **', u'ns3::TracedValueCallback::Time*') typehandlers.add_type_alias(u'void ( * ) ( ns3::Time, ns3::Time ) *&', u'ns3::TracedValueCallback::Time&') def register_types_ns3_aodv(module): root_module = module.get_root() ## aodv-packet.h (module 'aodv'): ns3::aodv::MessageType [enumeration] module.add_enum('MessageType', ['AODVTYPE_RREQ', 'AODVTYPE_RREP', 'AODVTYPE_RERR', 'AODVTYPE_RREP_ACK']) ## aodv-rtable.h (module 'aodv'): ns3::aodv::RouteFlags [enumeration] module.add_enum('RouteFlags', ['VALID', 'INVALID', 'IN_SEARCH']) ## aodv-dpd.h (module 'aodv'): ns3::aodv::DuplicatePacketDetection [class] module.add_class('DuplicatePacketDetection') ## aodv-id-cache.h (module 'aodv'): ns3::aodv::IdCache [class] module.add_class('IdCache') ## aodv-neighbor.h (module 'aodv'): ns3::aodv::Neighbors [class] module.add_class('Neighbors') ## aodv-neighbor.h (module 'aodv'): ns3::aodv::Neighbors::Neighbor [struct] module.add_class('Neighbor', outer_class=root_module['ns3::aodv::Neighbors']) ## aodv-rqueue.h (module 'aodv'): ns3::aodv::QueueEntry [class] module.add_class('QueueEntry') ## aodv-rqueue.h (module 'aodv'): ns3::aodv::RequestQueue [class] module.add_class('RequestQueue') ## aodv-packet.h (module 'aodv'): ns3::aodv::RerrHeader [class] module.add_class('RerrHeader', parent=root_module['ns3::Header']) ## aodv-routing-protocol.h (module 'aodv'): ns3::aodv::RoutingProtocol [class] module.add_class('RoutingProtocol', parent=root_module['ns3::Ipv4RoutingProtocol']) ## aodv-rtable.h (module 'aodv'): ns3::aodv::RoutingTable [class] module.add_class('RoutingTable') ## aodv-rtable.h (module 'aodv'): ns3::aodv::RoutingTableEntry [class] module.add_class('RoutingTableEntry') ## aodv-packet.h (module 'aodv'): ns3::aodv::RrepAckHeader [class] module.add_class('RrepAckHeader', parent=root_module['ns3::Header']) ## aodv-packet.h (module 'aodv'): ns3::aodv::RrepHeader [class] module.add_class('RrepHeader', parent=root_module['ns3::Header']) ## aodv-packet.h (module 'aodv'): ns3::aodv::RreqHeader [class] module.add_class('RreqHeader', parent=root_module['ns3::Header']) ## aodv-packet.h (module 'aodv'): ns3::aodv::TypeHeader [class] module.add_class('TypeHeader', parent=root_module['ns3::Header']) module.add_container('std::map< ns3::Ipv4Address, unsigned int >', ('ns3::Ipv4Address', 'unsigned int'), container_type=u'map') module.add_container('std::vector< ns3::Ipv4Address >', 'ns3::Ipv4Address', container_type=u'vector') def register_methods(root_module): register_Ns3Address_methods(root_module, root_module['ns3::Address']) register_Ns3AttributeConstructionList_methods(root_module, root_module['ns3::AttributeConstructionList']) register_Ns3AttributeConstructionListItem_methods(root_module, root_module['ns3::AttributeConstructionList::Item']) register_Ns3Buffer_methods(root_module, root_module['ns3::Buffer']) register_Ns3BufferIterator_methods(root_module, root_module['ns3::Buffer::Iterator']) register_Ns3ByteTagIterator_methods(root_module, root_module['ns3::ByteTagIterator']) register_Ns3ByteTagIteratorItem_methods(root_module, root_module['ns3::ByteTagIterator::Item']) register_Ns3ByteTagList_methods(root_module, root_module['ns3::ByteTagList']) register_Ns3ByteTagListIterator_methods(root_module, root_module['ns3::ByteTagList::Iterator']) register_Ns3ByteTagListIteratorItem_methods(root_module, root_module['ns3::ByteTagList::Iterator::Item']) register_Ns3CallbackBase_methods(root_module, root_module['ns3::CallbackBase']) register_Ns3EventId_methods(root_module, root_module['ns3::EventId']) register_Ns3Hasher_methods(root_module, root_module['ns3::Hasher']) register_Ns3Inet6SocketAddress_methods(root_module, root_module['ns3::Inet6SocketAddress']) register_Ns3InetSocketAddress_methods(root_module, root_module['ns3::InetSocketAddress']) register_Ns3IntToType__0_methods(root_module, root_module['ns3::IntToType< 0 >']) register_Ns3IntToType__1_methods(root_module, root_module['ns3::IntToType< 1 >']) register_Ns3IntToType__2_methods(root_module, root_module['ns3::IntToType< 2 >']) register_Ns3IntToType__3_methods(root_module, root_module['ns3::IntToType< 3 >']) register_Ns3IntToType__4_methods(root_module, root_module['ns3::IntToType< 4 >']) register_Ns3IntToType__5_methods(root_module, root_module['ns3::IntToType< 5 >']) register_Ns3IntToType__6_methods(root_module, root_module['ns3::IntToType< 6 >']) register_Ns3Ipv4Address_methods(root_module, root_module['ns3::Ipv4Address']) register_Ns3Ipv4InterfaceAddress_methods(root_module, root_module['ns3::Ipv4InterfaceAddress']) register_Ns3Ipv4Mask_methods(root_module, root_module['ns3::Ipv4Mask']) register_Ns3Ipv4RoutingHelper_methods(root_module, root_module['ns3::Ipv4RoutingHelper']) register_Ns3Ipv6Address_methods(root_module, root_module['ns3::Ipv6Address']) register_Ns3Ipv6Prefix_methods(root_module, root_module['ns3::Ipv6Prefix']) register_Ns3Mac48Address_methods(root_module, root_module['ns3::Mac48Address']) register_Ns3NodeContainer_methods(root_module, root_module['ns3::NodeContainer']) register_Ns3ObjectBase_methods(root_module, root_module['ns3::ObjectBase']) register_Ns3ObjectDeleter_methods(root_module, root_module['ns3::ObjectDeleter']) register_Ns3ObjectFactory_methods(root_module, root_module['ns3::ObjectFactory']) register_Ns3PacketMetadata_methods(root_module, root_module['ns3::PacketMetadata']) register_Ns3PacketMetadataItem_methods(root_module, root_module['ns3::PacketMetadata::Item']) register_Ns3PacketMetadataItemIterator_methods(root_module, root_module['ns3::PacketMetadata::ItemIterator']) register_Ns3PacketTagIterator_methods(root_module, root_module['ns3::PacketTagIterator']) register_Ns3PacketTagIteratorItem_methods(root_module, root_module['ns3::PacketTagIterator::Item']) register_Ns3PacketTagList_methods(root_module, root_module['ns3::PacketTagList']) register_Ns3PacketTagListTagData_methods(root_module, root_module['ns3::PacketTagList::TagData']) register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, root_module['ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter >']) register_Ns3Simulator_methods(root_module, root_module['ns3::Simulator']) register_Ns3Tag_methods(root_module, root_module['ns3::Tag']) register_Ns3TagBuffer_methods(root_module, root_module['ns3::TagBuffer']) register_Ns3TimeWithUnit_methods(root_module, root_module['ns3::TimeWithUnit']) register_Ns3Timer_methods(root_module, root_module['ns3::Timer']) register_Ns3TimerImpl_methods(root_module, root_module['ns3::TimerImpl']) register_Ns3TypeId_methods(root_module, root_module['ns3::TypeId']) register_Ns3TypeIdAttributeInformation_methods(root_module, root_module['ns3::TypeId::AttributeInformation']) register_Ns3TypeIdTraceSourceInformation_methods(root_module, root_module['ns3::TypeId::TraceSourceInformation']) register_Ns3Empty_methods(root_module, root_module['ns3::empty']) register_Ns3Int64x64_t_methods(root_module, root_module['ns3::int64x64_t']) register_Ns3AodvHelper_methods(root_module, root_module['ns3::AodvHelper']) register_Ns3Chunk_methods(root_module, root_module['ns3::Chunk']) register_Ns3Header_methods(root_module, root_module['ns3::Header']) register_Ns3Ipv4Header_methods(root_module, root_module['ns3::Ipv4Header']) register_Ns3Object_methods(root_module, root_module['ns3::Object']) register_Ns3ObjectAggregateIterator_methods(root_module, root_module['ns3::Object::AggregateIterator']) register_Ns3RandomVariableStream_methods(root_module, root_module['ns3::RandomVariableStream']) register_Ns3SequentialRandomVariable_methods(root_module, root_module['ns3::SequentialRandomVariable']) register_Ns3SimpleRefCount__Ns3AttributeAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeAccessor__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >']) register_Ns3SimpleRefCount__Ns3AttributeChecker_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeChecker__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >']) register_Ns3SimpleRefCount__Ns3AttributeValue_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeValue__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >']) register_Ns3SimpleRefCount__Ns3CallbackImplBase_Ns3Empty_Ns3DefaultDeleter__lt__ns3CallbackImplBase__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >']) register_Ns3SimpleRefCount__Ns3EventImpl_Ns3Empty_Ns3DefaultDeleter__lt__ns3EventImpl__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >']) register_Ns3SimpleRefCount__Ns3HashImplementation_Ns3Empty_Ns3DefaultDeleter__lt__ns3HashImplementation__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter<ns3::Hash::Implementation> >']) register_Ns3SimpleRefCount__Ns3Ipv4MulticastRoute_Ns3Empty_Ns3DefaultDeleter__lt__ns3Ipv4MulticastRoute__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Ipv4MulticastRoute, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4MulticastRoute> >']) register_Ns3SimpleRefCount__Ns3Ipv4Route_Ns3Empty_Ns3DefaultDeleter__lt__ns3Ipv4Route__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Ipv4Route, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4Route> >']) register_Ns3SimpleRefCount__Ns3NixVector_Ns3Empty_Ns3DefaultDeleter__lt__ns3NixVector__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >']) register_Ns3SimpleRefCount__Ns3OutputStreamWrapper_Ns3Empty_Ns3DefaultDeleter__lt__ns3OutputStreamWrapper__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >']) register_Ns3SimpleRefCount__Ns3Packet_Ns3Empty_Ns3DefaultDeleter__lt__ns3Packet__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >']) register_Ns3SimpleRefCount__Ns3TraceSourceAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3TraceSourceAccessor__gt___methods(root_module, root_module['ns3::SimpleRefCount< ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >']) register_Ns3Socket_methods(root_module, root_module['ns3::Socket']) register_Ns3SocketIpTosTag_methods(root_module, root_module['ns3::SocketIpTosTag']) register_Ns3SocketIpTtlTag_methods(root_module, root_module['ns3::SocketIpTtlTag']) register_Ns3SocketIpv6HopLimitTag_methods(root_module, root_module['ns3::SocketIpv6HopLimitTag']) register_Ns3SocketIpv6TclassTag_methods(root_module, root_module['ns3::SocketIpv6TclassTag']) register_Ns3SocketPriorityTag_methods(root_module, root_module['ns3::SocketPriorityTag']) register_Ns3SocketSetDontFragmentTag_methods(root_module, root_module['ns3::SocketSetDontFragmentTag']) register_Ns3Time_methods(root_module, root_module['ns3::Time']) register_Ns3TraceSourceAccessor_methods(root_module, root_module['ns3::TraceSourceAccessor']) register_Ns3Trailer_methods(root_module, root_module['ns3::Trailer']) register_Ns3TriangularRandomVariable_methods(root_module, root_module['ns3::TriangularRandomVariable']) register_Ns3UniformRandomVariable_methods(root_module, root_module['ns3::UniformRandomVariable']) register_Ns3WeibullRandomVariable_methods(root_module, root_module['ns3::WeibullRandomVariable']) register_Ns3WifiMacHeader_methods(root_module, root_module['ns3::WifiMacHeader']) register_Ns3ZetaRandomVariable_methods(root_module, root_module['ns3::ZetaRandomVariable']) register_Ns3ZipfRandomVariable_methods(root_module, root_module['ns3::ZipfRandomVariable']) register_Ns3ArpCache_methods(root_module, root_module['ns3::ArpCache']) register_Ns3ArpCacheEntry_methods(root_module, root_module['ns3::ArpCache::Entry']) register_Ns3AttributeAccessor_methods(root_module, root_module['ns3::AttributeAccessor']) register_Ns3AttributeChecker_methods(root_module, root_module['ns3::AttributeChecker']) register_Ns3AttributeValue_methods(root_module, root_module['ns3::AttributeValue']) register_Ns3CallbackChecker_methods(root_module, root_module['ns3::CallbackChecker']) register_Ns3CallbackImplBase_methods(root_module, root_module['ns3::CallbackImplBase']) register_Ns3CallbackValue_methods(root_module, root_module['ns3::CallbackValue']) register_Ns3ConstantRandomVariable_methods(root_module, root_module['ns3::ConstantRandomVariable']) register_Ns3DeterministicRandomVariable_methods(root_module, root_module['ns3::DeterministicRandomVariable']) register_Ns3EmpiricalRandomVariable_methods(root_module, root_module['ns3::EmpiricalRandomVariable']) register_Ns3EmptyAttributeAccessor_methods(root_module, root_module['ns3::EmptyAttributeAccessor']) register_Ns3EmptyAttributeChecker_methods(root_module, root_module['ns3::EmptyAttributeChecker']) register_Ns3EmptyAttributeValue_methods(root_module, root_module['ns3::EmptyAttributeValue']) register_Ns3EnumChecker_methods(root_module, root_module['ns3::EnumChecker']) register_Ns3EnumValue_methods(root_module, root_module['ns3::EnumValue']) register_Ns3ErlangRandomVariable_methods(root_module, root_module['ns3::ErlangRandomVariable']) register_Ns3EventImpl_methods(root_module, root_module['ns3::EventImpl']) register_Ns3ExponentialRandomVariable_methods(root_module, root_module['ns3::ExponentialRandomVariable']) register_Ns3GammaRandomVariable_methods(root_module, root_module['ns3::GammaRandomVariable']) register_Ns3Ipv4_methods(root_module, root_module['ns3::Ipv4']) register_Ns3Ipv4AddressChecker_methods(root_module, root_module['ns3::Ipv4AddressChecker']) register_Ns3Ipv4AddressValue_methods(root_module, root_module['ns3::Ipv4AddressValue']) register_Ns3Ipv4Interface_methods(root_module, root_module['ns3::Ipv4Interface']) register_Ns3Ipv4L3Protocol_methods(root_module, root_module['ns3::Ipv4L3Protocol']) register_Ns3Ipv4MaskChecker_methods(root_module, root_module['ns3::Ipv4MaskChecker']) register_Ns3Ipv4MaskValue_methods(root_module, root_module['ns3::Ipv4MaskValue']) register_Ns3Ipv4MulticastRoute_methods(root_module, root_module['ns3::Ipv4MulticastRoute']) register_Ns3Ipv4Route_methods(root_module, root_module['ns3::Ipv4Route']) register_Ns3Ipv4RoutingProtocol_methods(root_module, root_module['ns3::Ipv4RoutingProtocol']) register_Ns3Ipv6AddressChecker_methods(root_module, root_module['ns3::Ipv6AddressChecker']) register_Ns3Ipv6AddressValue_methods(root_module, root_module['ns3::Ipv6AddressValue']) register_Ns3Ipv6PrefixChecker_methods(root_module, root_module['ns3::Ipv6PrefixChecker']) register_Ns3Ipv6PrefixValue_methods(root_module, root_module['ns3::Ipv6PrefixValue']) register_Ns3LogNormalRandomVariable_methods(root_module, root_module['ns3::LogNormalRandomVariable']) register_Ns3Mac48AddressChecker_methods(root_module, root_module['ns3::Mac48AddressChecker']) register_Ns3Mac48AddressValue_methods(root_module, root_module['ns3::Mac48AddressValue']) register_Ns3NetDevice_methods(root_module, root_module['ns3::NetDevice']) register_Ns3NixVector_methods(root_module, root_module['ns3::NixVector']) register_Ns3Node_methods(root_module, root_module['ns3::Node']) register_Ns3NormalRandomVariable_methods(root_module, root_module['ns3::NormalRandomVariable']) register_Ns3ObjectFactoryChecker_methods(root_module, root_module['ns3::ObjectFactoryChecker']) register_Ns3ObjectFactoryValue_methods(root_module, root_module['ns3::ObjectFactoryValue']) register_Ns3OutputStreamWrapper_methods(root_module, root_module['ns3::OutputStreamWrapper']) register_Ns3Packet_methods(root_module, root_module['ns3::Packet']) register_Ns3ParetoRandomVariable_methods(root_module, root_module['ns3::ParetoRandomVariable']) register_Ns3TimeValue_methods(root_module, root_module['ns3::TimeValue']) register_Ns3TypeIdChecker_methods(root_module, root_module['ns3::TypeIdChecker']) register_Ns3TypeIdValue_methods(root_module, root_module['ns3::TypeIdValue']) register_Ns3AddressChecker_methods(root_module, root_module['ns3::AddressChecker']) register_Ns3AddressValue_methods(root_module, root_module['ns3::AddressValue']) register_Ns3Ipv4ListRouting_methods(root_module, root_module['ns3::Ipv4ListRouting']) register_Ns3HashImplementation_methods(root_module, root_module['ns3::Hash::Implementation']) register_Ns3HashFunctionFnv1a_methods(root_module, root_module['ns3::Hash::Function::Fnv1a']) register_Ns3HashFunctionHash32_methods(root_module, root_module['ns3::Hash::Function::Hash32']) register_Ns3HashFunctionHash64_methods(root_module, root_module['ns3::Hash::Function::Hash64']) register_Ns3HashFunctionMurmur3_methods(root_module, root_module['ns3::Hash::Function::Murmur3']) register_Ns3AodvDuplicatePacketDetection_methods(root_module, root_module['ns3::aodv::DuplicatePacketDetection']) register_Ns3AodvIdCache_methods(root_module, root_module['ns3::aodv::IdCache']) register_Ns3AodvNeighbors_methods(root_module, root_module['ns3::aodv::Neighbors']) register_Ns3AodvNeighborsNeighbor_methods(root_module, root_module['ns3::aodv::Neighbors::Neighbor']) register_Ns3AodvQueueEntry_methods(root_module, root_module['ns3::aodv::QueueEntry']) register_Ns3AodvRequestQueue_methods(root_module, root_module['ns3::aodv::RequestQueue']) register_Ns3AodvRerrHeader_methods(root_module, root_module['ns3::aodv::RerrHeader']) register_Ns3AodvRoutingProtocol_methods(root_module, root_module['ns3::aodv::RoutingProtocol']) register_Ns3AodvRoutingTable_methods(root_module, root_module['ns3::aodv::RoutingTable']) register_Ns3AodvRoutingTableEntry_methods(root_module, root_module['ns3::aodv::RoutingTableEntry']) register_Ns3AodvRrepAckHeader_methods(root_module, root_module['ns3::aodv::RrepAckHeader']) register_Ns3AodvRrepHeader_methods(root_module, root_module['ns3::aodv::RrepHeader']) register_Ns3AodvRreqHeader_methods(root_module, root_module['ns3::aodv::RreqHeader']) register_Ns3AodvTypeHeader_methods(root_module, root_module['ns3::aodv::TypeHeader']) return def register_Ns3Address_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_binary_comparison_operator('<') cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## address.h (module 'network'): ns3::Address::Address() [constructor] cls.add_constructor([]) ## address.h (module 'network'): ns3::Address::Address(uint8_t type, uint8_t const * buffer, uint8_t len) [constructor] cls.add_constructor([param('uint8_t', 'type'), param('uint8_t const *', 'buffer'), param('uint8_t', 'len')]) ## address.h (module 'network'): ns3::Address::Address(ns3::Address const & address) [copy constructor] cls.add_constructor([param('ns3::Address const &', 'address')]) ## address.h (module 'network'): bool ns3::Address::CheckCompatible(uint8_t type, uint8_t len) const [member function] cls.add_method('CheckCompatible', 'bool', [param('uint8_t', 'type'), param('uint8_t', 'len')], is_const=True) ## address.h (module 'network'): uint32_t ns3::Address::CopyAllFrom(uint8_t const * buffer, uint8_t len) [member function] cls.add_method('CopyAllFrom', 'uint32_t', [param('uint8_t const *', 'buffer'), param('uint8_t', 'len')]) ## address.h (module 'network'): uint32_t ns3::Address::CopyAllTo(uint8_t * buffer, uint8_t len) const [member function] cls.add_method('CopyAllTo', 'uint32_t', [param('uint8_t *', 'buffer'), param('uint8_t', 'len')], is_const=True) ## address.h (module 'network'): uint32_t ns3::Address::CopyFrom(uint8_t const * buffer, uint8_t len) [member function] cls.add_method('CopyFrom', 'uint32_t', [param('uint8_t const *', 'buffer'), param('uint8_t', 'len')]) ## address.h (module 'network'): uint32_t ns3::Address::CopyTo(uint8_t * buffer) const [member function] cls.add_method('CopyTo', 'uint32_t', [param('uint8_t *', 'buffer')], is_const=True) ## address.h (module 'network'): void ns3::Address::Deserialize(ns3::TagBuffer buffer) [member function] cls.add_method('Deserialize', 'void', [param('ns3::TagBuffer', 'buffer')]) ## address.h (module 'network'): uint8_t ns3::Address::GetLength() const [member function] cls.add_method('GetLength', 'uint8_t', [], is_const=True) ## address.h (module 'network'): uint32_t ns3::Address::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True) ## address.h (module 'network'): bool ns3::Address::IsInvalid() const [member function] cls.add_method('IsInvalid', 'bool', [], is_const=True) ## address.h (module 'network'): bool ns3::Address::IsMatchingType(uint8_t type) const [member function] cls.add_method('IsMatchingType', 'bool', [param('uint8_t', 'type')], is_const=True) ## address.h (module 'network'): static uint8_t ns3::Address::Register() [member function] cls.add_method('Register', 'uint8_t', [], is_static=True) ## address.h (module 'network'): void ns3::Address::Serialize(ns3::TagBuffer buffer) const [member function] cls.add_method('Serialize', 'void', [param('ns3::TagBuffer', 'buffer')], is_const=True) return def register_Ns3AttributeConstructionList_methods(root_module, cls): ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::AttributeConstructionList(ns3::AttributeConstructionList const & arg0) [copy constructor] cls.add_constructor([param('ns3::AttributeConstructionList const &', 'arg0')]) ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::AttributeConstructionList() [constructor] cls.add_constructor([]) ## attribute-construction-list.h (module 'core'): void ns3::AttributeConstructionList::Add(std::string name, ns3::Ptr<ns3::AttributeChecker const> checker, ns3::Ptr<ns3::AttributeValue> value) [member function] cls.add_method('Add', 'void', [param('std::string', 'name'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker'), param('ns3::Ptr< ns3::AttributeValue >', 'value')]) ## attribute-construction-list.h (module 'core'): std::_List_const_iterator<ns3::AttributeConstructionList::Item> ns3::AttributeConstructionList::Begin() const [member function] cls.add_method('Begin', 'std::_List_const_iterator< ns3::AttributeConstructionList::Item >', [], is_const=True) ## attribute-construction-list.h (module 'core'): std::_List_const_iterator<ns3::AttributeConstructionList::Item> ns3::AttributeConstructionList::End() const [member function] cls.add_method('End', 'std::_List_const_iterator< ns3::AttributeConstructionList::Item >', [], is_const=True) ## attribute-construction-list.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::AttributeConstructionList::Find(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('Find', 'ns3::Ptr< ns3::AttributeValue >', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True) return def register_Ns3AttributeConstructionListItem_methods(root_module, cls): ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::Item() [constructor] cls.add_constructor([]) ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::Item(ns3::AttributeConstructionList::Item const & arg0) [copy constructor] cls.add_constructor([param('ns3::AttributeConstructionList::Item const &', 'arg0')]) ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::checker [variable] cls.add_instance_attribute('checker', 'ns3::Ptr< ns3::AttributeChecker const >', is_const=False) ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::name [variable] cls.add_instance_attribute('name', 'std::string', is_const=False) ## attribute-construction-list.h (module 'core'): ns3::AttributeConstructionList::Item::value [variable] cls.add_instance_attribute('value', 'ns3::Ptr< ns3::AttributeValue >', is_const=False) return def register_Ns3Buffer_methods(root_module, cls): ## buffer.h (module 'network'): ns3::Buffer::Buffer() [constructor] cls.add_constructor([]) ## buffer.h (module 'network'): ns3::Buffer::Buffer(uint32_t dataSize) [constructor] cls.add_constructor([param('uint32_t', 'dataSize')]) ## buffer.h (module 'network'): ns3::Buffer::Buffer(uint32_t dataSize, bool initialize) [constructor] cls.add_constructor([param('uint32_t', 'dataSize'), param('bool', 'initialize')]) ## buffer.h (module 'network'): ns3::Buffer::Buffer(ns3::Buffer const & o) [copy constructor] cls.add_constructor([param('ns3::Buffer const &', 'o')]) ## buffer.h (module 'network'): void ns3::Buffer::AddAtEnd(uint32_t end) [member function] cls.add_method('AddAtEnd', 'void', [param('uint32_t', 'end')]) ## buffer.h (module 'network'): void ns3::Buffer::AddAtEnd(ns3::Buffer const & o) [member function] cls.add_method('AddAtEnd', 'void', [param('ns3::Buffer const &', 'o')]) ## buffer.h (module 'network'): void ns3::Buffer::AddAtStart(uint32_t start) [member function] cls.add_method('AddAtStart', 'void', [param('uint32_t', 'start')]) ## buffer.h (module 'network'): ns3::Buffer::Iterator ns3::Buffer::Begin() const [member function] cls.add_method('Begin', 'ns3::Buffer::Iterator', [], is_const=True) ## buffer.h (module 'network'): void ns3::Buffer::CopyData(std::ostream * os, uint32_t size) const [member function] cls.add_method('CopyData', 'void', [param('std::ostream *', 'os'), param('uint32_t', 'size')], is_const=True) ## buffer.h (module 'network'): uint32_t ns3::Buffer::CopyData(uint8_t * buffer, uint32_t size) const [member function] cls.add_method('CopyData', 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')], is_const=True) ## buffer.h (module 'network'): ns3::Buffer ns3::Buffer::CreateFragment(uint32_t start, uint32_t length) const [member function] cls.add_method('CreateFragment', 'ns3::Buffer', [param('uint32_t', 'start'), param('uint32_t', 'length')], is_const=True) ## buffer.h (module 'network'): uint32_t ns3::Buffer::Deserialize(uint8_t const * buffer, uint32_t size) [member function] cls.add_method('Deserialize', 'uint32_t', [param('uint8_t const *', 'buffer'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): ns3::Buffer::Iterator ns3::Buffer::End() const [member function] cls.add_method('End', 'ns3::Buffer::Iterator', [], is_const=True) ## buffer.h (module 'network'): uint32_t ns3::Buffer::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True) ## buffer.h (module 'network'): uint32_t ns3::Buffer::GetSize() const [member function] cls.add_method('GetSize', 'uint32_t', [], is_const=True) ## buffer.h (module 'network'): uint8_t const * ns3::Buffer::PeekData() const [member function] cls.add_method('PeekData', 'uint8_t const *', [], is_const=True) ## buffer.h (module 'network'): void ns3::Buffer::RemoveAtEnd(uint32_t end) [member function] cls.add_method('RemoveAtEnd', 'void', [param('uint32_t', 'end')]) ## buffer.h (module 'network'): void ns3::Buffer::RemoveAtStart(uint32_t start) [member function] cls.add_method('RemoveAtStart', 'void', [param('uint32_t', 'start')]) ## buffer.h (module 'network'): uint32_t ns3::Buffer::Serialize(uint8_t * buffer, uint32_t maxSize) const [member function] cls.add_method('Serialize', 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) return def register_Ns3BufferIterator_methods(root_module, cls): ## buffer.h (module 'network'): ns3::Buffer::Iterator::Iterator(ns3::Buffer::Iterator const & arg0) [copy constructor] cls.add_constructor([param('ns3::Buffer::Iterator const &', 'arg0')]) ## buffer.h (module 'network'): ns3::Buffer::Iterator::Iterator() [constructor] cls.add_constructor([]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::CalculateIpChecksum(uint16_t size) [member function] cls.add_method('CalculateIpChecksum', 'uint16_t', [param('uint16_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::CalculateIpChecksum(uint16_t size, uint32_t initialChecksum) [member function] cls.add_method('CalculateIpChecksum', 'uint16_t', [param('uint16_t', 'size'), param('uint32_t', 'initialChecksum')]) ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::GetDistanceFrom(ns3::Buffer::Iterator const & o) const [member function] cls.add_method('GetDistanceFrom', 'uint32_t', [param('ns3::Buffer::Iterator const &', 'o')], is_const=True) ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::GetRemainingSize() const [member function] cls.add_method('GetRemainingSize', 'uint32_t', [], is_const=True) ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::GetSize() const [member function] cls.add_method('GetSize', 'uint32_t', [], is_const=True) ## buffer.h (module 'network'): bool ns3::Buffer::Iterator::IsEnd() const [member function] cls.add_method('IsEnd', 'bool', [], is_const=True) ## buffer.h (module 'network'): bool ns3::Buffer::Iterator::IsStart() const [member function] cls.add_method('IsStart', 'bool', [], is_const=True) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Next() [member function] cls.add_method('Next', 'void', []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Next(uint32_t delta) [member function] cls.add_method('Next', 'void', [param('uint32_t', 'delta')]) ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::PeekU8() [member function] cls.add_method('PeekU8', 'uint8_t', []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev() [member function] cls.add_method('Prev', 'void', []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Prev(uint32_t delta) [member function] cls.add_method('Prev', 'void', [param('uint32_t', 'delta')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(uint8_t * buffer, uint32_t size) [member function] cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Read(ns3::Buffer::Iterator start, uint32_t size) [member function] cls.add_method('Read', 'void', [param('ns3::Buffer::Iterator', 'start'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadLsbtohU16() [member function] cls.add_method('ReadLsbtohU16', 'uint16_t', []) ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::ReadLsbtohU32() [member function] cls.add_method('ReadLsbtohU32', 'uint32_t', []) ## buffer.h (module 'network'): uint64_t ns3::Buffer::Iterator::ReadLsbtohU64() [member function] cls.add_method('ReadLsbtohU64', 'uint64_t', []) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadNtohU16() [member function] cls.add_method('ReadNtohU16', 'uint16_t', []) ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::ReadNtohU32() [member function] cls.add_method('ReadNtohU32', 'uint32_t', []) ## buffer.h (module 'network'): uint64_t ns3::Buffer::Iterator::ReadNtohU64() [member function] cls.add_method('ReadNtohU64', 'uint64_t', []) ## buffer.h (module 'network'): uint16_t ns3::Buffer::Iterator::ReadU16() [member function] cls.add_method('ReadU16', 'uint16_t', []) ## buffer.h (module 'network'): uint32_t ns3::Buffer::Iterator::ReadU32() [member function] cls.add_method('ReadU32', 'uint32_t', []) ## buffer.h (module 'network'): uint64_t ns3::Buffer::Iterator::ReadU64() [member function] cls.add_method('ReadU64', 'uint64_t', []) ## buffer.h (module 'network'): uint8_t ns3::Buffer::Iterator::ReadU8() [member function] cls.add_method('ReadU8', 'uint8_t', []) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Write(uint8_t const * buffer, uint32_t size) [member function] cls.add_method('Write', 'void', [param('uint8_t const *', 'buffer'), param('uint32_t', 'size')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::Write(ns3::Buffer::Iterator start, ns3::Buffer::Iterator end) [member function] cls.add_method('Write', 'void', [param('ns3::Buffer::Iterator', 'start'), param('ns3::Buffer::Iterator', 'end')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtolsbU16(uint16_t data) [member function] cls.add_method('WriteHtolsbU16', 'void', [param('uint16_t', 'data')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtolsbU32(uint32_t data) [member function] cls.add_method('WriteHtolsbU32', 'void', [param('uint32_t', 'data')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtolsbU64(uint64_t data) [member function] cls.add_method('WriteHtolsbU64', 'void', [param('uint64_t', 'data')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtonU16(uint16_t data) [member function] cls.add_method('WriteHtonU16', 'void', [param('uint16_t', 'data')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtonU32(uint32_t data) [member function] cls.add_method('WriteHtonU32', 'void', [param('uint32_t', 'data')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteHtonU64(uint64_t data) [member function] cls.add_method('WriteHtonU64', 'void', [param('uint64_t', 'data')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU16(uint16_t data) [member function] cls.add_method('WriteU16', 'void', [param('uint16_t', 'data')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU32(uint32_t data) [member function] cls.add_method('WriteU32', 'void', [param('uint32_t', 'data')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU64(uint64_t data) [member function] cls.add_method('WriteU64', 'void', [param('uint64_t', 'data')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU8(uint8_t data) [member function] cls.add_method('WriteU8', 'void', [param('uint8_t', 'data')]) ## buffer.h (module 'network'): void ns3::Buffer::Iterator::WriteU8(uint8_t data, uint32_t len) [member function] cls.add_method('WriteU8', 'void', [param('uint8_t', 'data'), param('uint32_t', 'len')]) return def register_Ns3ByteTagIterator_methods(root_module, cls): ## packet.h (module 'network'): ns3::ByteTagIterator::ByteTagIterator(ns3::ByteTagIterator const & arg0) [copy constructor] cls.add_constructor([param('ns3::ByteTagIterator const &', 'arg0')]) ## packet.h (module 'network'): bool ns3::ByteTagIterator::HasNext() const [member function] cls.add_method('HasNext', 'bool', [], is_const=True) ## packet.h (module 'network'): ns3::ByteTagIterator::Item ns3::ByteTagIterator::Next() [member function] cls.add_method('Next', 'ns3::ByteTagIterator::Item', []) return def register_Ns3ByteTagIteratorItem_methods(root_module, cls): ## packet.h (module 'network'): ns3::ByteTagIterator::Item::Item(ns3::ByteTagIterator::Item const & arg0) [copy constructor] cls.add_constructor([param('ns3::ByteTagIterator::Item const &', 'arg0')]) ## packet.h (module 'network'): uint32_t ns3::ByteTagIterator::Item::GetEnd() const [member function] cls.add_method('GetEnd', 'uint32_t', [], is_const=True) ## packet.h (module 'network'): uint32_t ns3::ByteTagIterator::Item::GetStart() const [member function] cls.add_method('GetStart', 'uint32_t', [], is_const=True) ## packet.h (module 'network'): void ns3::ByteTagIterator::Item::GetTag(ns3::Tag & tag) const [member function] cls.add_method('GetTag', 'void', [param('ns3::Tag &', 'tag')], is_const=True) ## packet.h (module 'network'): ns3::TypeId ns3::ByteTagIterator::Item::GetTypeId() const [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_const=True) return def register_Ns3ByteTagList_methods(root_module, cls): ## byte-tag-list.h (module 'network'): ns3::ByteTagList::ByteTagList() [constructor] cls.add_constructor([]) ## byte-tag-list.h (module 'network'): ns3::ByteTagList::ByteTagList(ns3::ByteTagList const & o) [copy constructor] cls.add_constructor([param('ns3::ByteTagList const &', 'o')]) ## byte-tag-list.h (module 'network'): ns3::TagBuffer ns3::ByteTagList::Add(ns3::TypeId tid, uint32_t bufferSize, int32_t start, int32_t end) [member function] cls.add_method('Add', 'ns3::TagBuffer', [param('ns3::TypeId', 'tid'), param('uint32_t', 'bufferSize'), param('int32_t', 'start'), param('int32_t', 'end')]) ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::Add(ns3::ByteTagList const & o) [member function] cls.add_method('Add', 'void', [param('ns3::ByteTagList const &', 'o')]) ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::AddAtEnd(int32_t appendOffset) [member function] cls.add_method('AddAtEnd', 'void', [param('int32_t', 'appendOffset')]) ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::AddAtStart(int32_t prependOffset) [member function] cls.add_method('AddAtStart', 'void', [param('int32_t', 'prependOffset')]) ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::Adjust(int32_t adjustment) [member function] cls.add_method('Adjust', 'void', [param('int32_t', 'adjustment')]) ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator ns3::ByteTagList::Begin(int32_t offsetStart, int32_t offsetEnd) const [member function] cls.add_method('Begin', 'ns3::ByteTagList::Iterator', [param('int32_t', 'offsetStart'), param('int32_t', 'offsetEnd')], is_const=True) ## byte-tag-list.h (module 'network'): void ns3::ByteTagList::RemoveAll() [member function] cls.add_method('RemoveAll', 'void', []) return def register_Ns3ByteTagListIterator_methods(root_module, cls): ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Iterator(ns3::ByteTagList::Iterator const & arg0) [copy constructor] cls.add_constructor([param('ns3::ByteTagList::Iterator const &', 'arg0')]) ## byte-tag-list.h (module 'network'): uint32_t ns3::ByteTagList::Iterator::GetOffsetStart() const [member function] cls.add_method('GetOffsetStart', 'uint32_t', [], is_const=True) ## byte-tag-list.h (module 'network'): bool ns3::ByteTagList::Iterator::HasNext() const [member function] cls.add_method('HasNext', 'bool', [], is_const=True) ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item ns3::ByteTagList::Iterator::Next() [member function] cls.add_method('Next', 'ns3::ByteTagList::Iterator::Item', []) return def register_Ns3ByteTagListIteratorItem_methods(root_module, cls): ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::Item(ns3::ByteTagList::Iterator::Item const & arg0) [copy constructor] cls.add_constructor([param('ns3::ByteTagList::Iterator::Item const &', 'arg0')]) ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::Item(ns3::TagBuffer buf) [constructor] cls.add_constructor([param('ns3::TagBuffer', 'buf')]) ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::buf [variable] cls.add_instance_attribute('buf', 'ns3::TagBuffer', is_const=False) ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::end [variable] cls.add_instance_attribute('end', 'int32_t', is_const=False) ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::size [variable] cls.add_instance_attribute('size', 'uint32_t', is_const=False) ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::start [variable] cls.add_instance_attribute('start', 'int32_t', is_const=False) ## byte-tag-list.h (module 'network'): ns3::ByteTagList::Iterator::Item::tid [variable] cls.add_instance_attribute('tid', 'ns3::TypeId', is_const=False) return def register_Ns3CallbackBase_methods(root_module, cls): ## callback.h (module 'core'): ns3::CallbackBase::CallbackBase(ns3::CallbackBase const & arg0) [copy constructor] cls.add_constructor([param('ns3::CallbackBase const &', 'arg0')]) ## callback.h (module 'core'): ns3::CallbackBase::CallbackBase() [constructor] cls.add_constructor([]) ## callback.h (module 'core'): ns3::Ptr<ns3::CallbackImplBase> ns3::CallbackBase::GetImpl() const [member function] cls.add_method('GetImpl', 'ns3::Ptr< ns3::CallbackImplBase >', [], is_const=True) ## callback.h (module 'core'): ns3::CallbackBase::CallbackBase(ns3::Ptr<ns3::CallbackImplBase> impl) [constructor] cls.add_constructor([param('ns3::Ptr< ns3::CallbackImplBase >', 'impl')], visibility='protected') return def register_Ns3EventId_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_binary_comparison_operator('==') ## event-id.h (module 'core'): ns3::EventId::EventId(ns3::EventId const & arg0) [copy constructor] cls.add_constructor([param('ns3::EventId const &', 'arg0')]) ## event-id.h (module 'core'): ns3::EventId::EventId() [constructor] cls.add_constructor([]) ## event-id.h (module 'core'): ns3::EventId::EventId(ns3::Ptr<ns3::EventImpl> const & impl, uint64_t ts, uint32_t context, uint32_t uid) [constructor] cls.add_constructor([param('ns3::Ptr< ns3::EventImpl > const &', 'impl'), param('uint64_t', 'ts'), param('uint32_t', 'context'), param('uint32_t', 'uid')]) ## event-id.h (module 'core'): void ns3::EventId::Cancel() [member function] cls.add_method('Cancel', 'void', []) ## event-id.h (module 'core'): uint32_t ns3::EventId::GetContext() const [member function] cls.add_method('GetContext', 'uint32_t', [], is_const=True) ## event-id.h (module 'core'): uint64_t ns3::EventId::GetTs() const [member function] cls.add_method('GetTs', 'uint64_t', [], is_const=True) ## event-id.h (module 'core'): uint32_t ns3::EventId::GetUid() const [member function] cls.add_method('GetUid', 'uint32_t', [], is_const=True) ## event-id.h (module 'core'): bool ns3::EventId::IsExpired() const [member function] cls.add_method('IsExpired', 'bool', [], is_const=True) ## event-id.h (module 'core'): bool ns3::EventId::IsRunning() const [member function] cls.add_method('IsRunning', 'bool', [], is_const=True) ## event-id.h (module 'core'): ns3::EventImpl * ns3::EventId::PeekEventImpl() const [member function] cls.add_method('PeekEventImpl', 'ns3::EventImpl *', [], is_const=True) return def register_Ns3Hasher_methods(root_module, cls): ## hash.h (module 'core'): ns3::Hasher::Hasher(ns3::Hasher const & arg0) [copy constructor] cls.add_constructor([param('ns3::Hasher const &', 'arg0')]) ## hash.h (module 'core'): ns3::Hasher::Hasher() [constructor] cls.add_constructor([]) ## hash.h (module 'core'): ns3::Hasher::Hasher(ns3::Ptr<ns3::Hash::Implementation> hp) [constructor] cls.add_constructor([param('ns3::Ptr< ns3::Hash::Implementation >', 'hp')]) ## hash.h (module 'core'): uint32_t ns3::Hasher::GetHash32(char const * buffer, size_t const size) [member function] cls.add_method('GetHash32', 'uint32_t', [param('char const *', 'buffer'), param('size_t const', 'size')]) ## hash.h (module 'core'): uint32_t ns3::Hasher::GetHash32(std::string const s) [member function] cls.add_method('GetHash32', 'uint32_t', [param('std::string const', 's')]) ## hash.h (module 'core'): uint64_t ns3::Hasher::GetHash64(char const * buffer, size_t const size) [member function] cls.add_method('GetHash64', 'uint64_t', [param('char const *', 'buffer'), param('size_t const', 'size')]) ## hash.h (module 'core'): uint64_t ns3::Hasher::GetHash64(std::string const s) [member function] cls.add_method('GetHash64', 'uint64_t', [param('std::string const', 's')]) ## hash.h (module 'core'): ns3::Hasher & ns3::Hasher::clear() [member function] cls.add_method('clear', 'ns3::Hasher &', []) return def register_Ns3Inet6SocketAddress_methods(root_module, cls): ## inet6-socket-address.h (module 'network'): ns3::Inet6SocketAddress::Inet6SocketAddress(ns3::Inet6SocketAddress const & arg0) [copy constructor] cls.add_constructor([param('ns3::Inet6SocketAddress const &', 'arg0')]) ## inet6-socket-address.h (module 'network'): ns3::Inet6SocketAddress::Inet6SocketAddress(ns3::Ipv6Address ipv6, uint16_t port) [constructor] cls.add_constructor([param('ns3::Ipv6Address', 'ipv6'), param('uint16_t', 'port')]) ## inet6-socket-address.h (module 'network'): ns3::Inet6SocketAddress::Inet6SocketAddress(ns3::Ipv6Address ipv6) [constructor] cls.add_constructor([param('ns3::Ipv6Address', 'ipv6')]) ## inet6-socket-address.h (module 'network'): ns3::Inet6SocketAddress::Inet6SocketAddress(uint16_t port) [constructor] cls.add_constructor([param('uint16_t', 'port')]) ## inet6-socket-address.h (module 'network'): ns3::Inet6SocketAddress::Inet6SocketAddress(char const * ipv6, uint16_t port) [constructor] cls.add_constructor([param('char const *', 'ipv6'), param('uint16_t', 'port')]) ## inet6-socket-address.h (module 'network'): ns3::Inet6SocketAddress::Inet6SocketAddress(char const * ipv6) [constructor] cls.add_constructor([param('char const *', 'ipv6')]) ## inet6-socket-address.h (module 'network'): static ns3::Inet6SocketAddress ns3::Inet6SocketAddress::ConvertFrom(ns3::Address const & addr) [member function] cls.add_method('ConvertFrom', 'ns3::Inet6SocketAddress', [param('ns3::Address const &', 'addr')], is_static=True) ## inet6-socket-address.h (module 'network'): ns3::Ipv6Address ns3::Inet6SocketAddress::GetIpv6() const [member function] cls.add_method('GetIpv6', 'ns3::Ipv6Address', [], is_const=True) ## inet6-socket-address.h (module 'network'): uint16_t ns3::Inet6SocketAddress::GetPort() const [member function] cls.add_method('GetPort', 'uint16_t', [], is_const=True) ## inet6-socket-address.h (module 'network'): static bool ns3::Inet6SocketAddress::IsMatchingType(ns3::Address const & addr) [member function] cls.add_method('IsMatchingType', 'bool', [param('ns3::Address const &', 'addr')], is_static=True) ## inet6-socket-address.h (module 'network'): void ns3::Inet6SocketAddress::SetIpv6(ns3::Ipv6Address ipv6) [member function] cls.add_method('SetIpv6', 'void', [param('ns3::Ipv6Address', 'ipv6')]) ## inet6-socket-address.h (module 'network'): void ns3::Inet6SocketAddress::SetPort(uint16_t port) [member function] cls.add_method('SetPort', 'void', [param('uint16_t', 'port')]) return def register_Ns3InetSocketAddress_methods(root_module, cls): ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress::InetSocketAddress(ns3::InetSocketAddress const & arg0) [copy constructor] cls.add_constructor([param('ns3::InetSocketAddress const &', 'arg0')]) ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress::InetSocketAddress(ns3::Ipv4Address ipv4, uint16_t port) [constructor] cls.add_constructor([param('ns3::Ipv4Address', 'ipv4'), param('uint16_t', 'port')]) ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress::InetSocketAddress(ns3::Ipv4Address ipv4) [constructor] cls.add_constructor([param('ns3::Ipv4Address', 'ipv4')]) ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress::InetSocketAddress(uint16_t port) [constructor] cls.add_constructor([param('uint16_t', 'port')]) ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress::InetSocketAddress(char const * ipv4, uint16_t port) [constructor] cls.add_constructor([param('char const *', 'ipv4'), param('uint16_t', 'port')]) ## inet-socket-address.h (module 'network'): ns3::InetSocketAddress::InetSocketAddress(char const * ipv4) [constructor] cls.add_constructor([param('char const *', 'ipv4')]) ## inet-socket-address.h (module 'network'): static ns3::InetSocketAddress ns3::InetSocketAddress::ConvertFrom(ns3::Address const & address) [member function] cls.add_method('ConvertFrom', 'ns3::InetSocketAddress', [param('ns3::Address const &', 'address')], is_static=True) ## inet-socket-address.h (module 'network'): ns3::Ipv4Address ns3::InetSocketAddress::GetIpv4() const [member function] cls.add_method('GetIpv4', 'ns3::Ipv4Address', [], is_const=True) ## inet-socket-address.h (module 'network'): uint16_t ns3::InetSocketAddress::GetPort() const [member function] cls.add_method('GetPort', 'uint16_t', [], is_const=True) ## inet-socket-address.h (module 'network'): uint8_t ns3::InetSocketAddress::GetTos() const [member function] cls.add_method('GetTos', 'uint8_t', [], is_const=True) ## inet-socket-address.h (module 'network'): static bool ns3::InetSocketAddress::IsMatchingType(ns3::Address const & address) [member function] cls.add_method('IsMatchingType', 'bool', [param('ns3::Address const &', 'address')], is_static=True) ## inet-socket-address.h (module 'network'): void ns3::InetSocketAddress::SetIpv4(ns3::Ipv4Address address) [member function] cls.add_method('SetIpv4', 'void', [param('ns3::Ipv4Address', 'address')]) ## inet-socket-address.h (module 'network'): void ns3::InetSocketAddress::SetPort(uint16_t port) [member function] cls.add_method('SetPort', 'void', [param('uint16_t', 'port')]) ## inet-socket-address.h (module 'network'): void ns3::InetSocketAddress::SetTos(uint8_t tos) [member function] cls.add_method('SetTos', 'void', [param('uint8_t', 'tos')]) return def register_Ns3IntToType__0_methods(root_module, cls): ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType() [constructor] cls.add_constructor([]) ## int-to-type.h (module 'core'): ns3::IntToType<0>::IntToType(ns3::IntToType<0> const & arg0) [copy constructor] cls.add_constructor([param('ns3::IntToType< 0 > const &', 'arg0')]) return def register_Ns3IntToType__1_methods(root_module, cls): ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType() [constructor] cls.add_constructor([]) ## int-to-type.h (module 'core'): ns3::IntToType<1>::IntToType(ns3::IntToType<1> const & arg0) [copy constructor] cls.add_constructor([param('ns3::IntToType< 1 > const &', 'arg0')]) return def register_Ns3IntToType__2_methods(root_module, cls): ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType() [constructor] cls.add_constructor([]) ## int-to-type.h (module 'core'): ns3::IntToType<2>::IntToType(ns3::IntToType<2> const & arg0) [copy constructor] cls.add_constructor([param('ns3::IntToType< 2 > const &', 'arg0')]) return def register_Ns3IntToType__3_methods(root_module, cls): ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType() [constructor] cls.add_constructor([]) ## int-to-type.h (module 'core'): ns3::IntToType<3>::IntToType(ns3::IntToType<3> const & arg0) [copy constructor] cls.add_constructor([param('ns3::IntToType< 3 > const &', 'arg0')]) return def register_Ns3IntToType__4_methods(root_module, cls): ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType() [constructor] cls.add_constructor([]) ## int-to-type.h (module 'core'): ns3::IntToType<4>::IntToType(ns3::IntToType<4> const & arg0) [copy constructor] cls.add_constructor([param('ns3::IntToType< 4 > const &', 'arg0')]) return def register_Ns3IntToType__5_methods(root_module, cls): ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType() [constructor] cls.add_constructor([]) ## int-to-type.h (module 'core'): ns3::IntToType<5>::IntToType(ns3::IntToType<5> const & arg0) [copy constructor] cls.add_constructor([param('ns3::IntToType< 5 > const &', 'arg0')]) return def register_Ns3IntToType__6_methods(root_module, cls): ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType() [constructor] cls.add_constructor([]) ## int-to-type.h (module 'core'): ns3::IntToType<6>::IntToType(ns3::IntToType<6> const & arg0) [copy constructor] cls.add_constructor([param('ns3::IntToType< 6 > const &', 'arg0')]) return def register_Ns3Ipv4Address_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_binary_comparison_operator('<') cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## ipv4-address.h (module 'network'): ns3::Ipv4Address::Ipv4Address(ns3::Ipv4Address const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4Address const &', 'arg0')]) ## ipv4-address.h (module 'network'): ns3::Ipv4Address::Ipv4Address() [constructor] cls.add_constructor([]) ## ipv4-address.h (module 'network'): ns3::Ipv4Address::Ipv4Address(uint32_t address) [constructor] cls.add_constructor([param('uint32_t', 'address')]) ## ipv4-address.h (module 'network'): ns3::Ipv4Address::Ipv4Address(char const * address) [constructor] cls.add_constructor([param('char const *', 'address')]) ## ipv4-address.h (module 'network'): ns3::Ipv4Address ns3::Ipv4Address::CombineMask(ns3::Ipv4Mask const & mask) const [member function] cls.add_method('CombineMask', 'ns3::Ipv4Address', [param('ns3::Ipv4Mask const &', 'mask')], is_const=True) ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::ConvertFrom(ns3::Address const & address) [member function] cls.add_method('ConvertFrom', 'ns3::Ipv4Address', [param('ns3::Address const &', 'address')], is_static=True) ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::Deserialize(uint8_t const * buf) [member function] cls.add_method('Deserialize', 'ns3::Ipv4Address', [param('uint8_t const *', 'buf')], is_static=True) ## ipv4-address.h (module 'network'): uint32_t ns3::Ipv4Address::Get() const [member function] cls.add_method('Get', 'uint32_t', [], is_const=True) ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::GetAny() [member function] cls.add_method('GetAny', 'ns3::Ipv4Address', [], is_static=True) ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::GetBroadcast() [member function] cls.add_method('GetBroadcast', 'ns3::Ipv4Address', [], is_static=True) ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::GetLoopback() [member function] cls.add_method('GetLoopback', 'ns3::Ipv4Address', [], is_static=True) ## ipv4-address.h (module 'network'): ns3::Ipv4Address ns3::Ipv4Address::GetSubnetDirectedBroadcast(ns3::Ipv4Mask const & mask) const [member function] cls.add_method('GetSubnetDirectedBroadcast', 'ns3::Ipv4Address', [param('ns3::Ipv4Mask const &', 'mask')], is_const=True) ## ipv4-address.h (module 'network'): static ns3::Ipv4Address ns3::Ipv4Address::GetZero() [member function] cls.add_method('GetZero', 'ns3::Ipv4Address', [], is_static=True) ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsAny() const [member function] cls.add_method('IsAny', 'bool', [], is_const=True) ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsBroadcast() const [member function] cls.add_method('IsBroadcast', 'bool', [], is_const=True) ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsEqual(ns3::Ipv4Address const & other) const [member function] cls.add_method('IsEqual', 'bool', [param('ns3::Ipv4Address const &', 'other')], is_const=True) ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsLocalMulticast() const [member function] cls.add_method('IsLocalMulticast', 'bool', [], is_const=True) ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsLocalhost() const [member function] cls.add_method('IsLocalhost', 'bool', [], is_const=True) ## ipv4-address.h (module 'network'): static bool ns3::Ipv4Address::IsMatchingType(ns3::Address const & address) [member function] cls.add_method('IsMatchingType', 'bool', [param('ns3::Address const &', 'address')], is_static=True) ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsMulticast() const [member function] cls.add_method('IsMulticast', 'bool', [], is_const=True) ## ipv4-address.h (module 'network'): bool ns3::Ipv4Address::IsSubnetDirectedBroadcast(ns3::Ipv4Mask const & mask) const [member function] cls.add_method('IsSubnetDirectedBroadcast', 'bool', [param('ns3::Ipv4Mask const &', 'mask')], is_const=True) ## ipv4-address.h (module 'network'): void ns3::Ipv4Address::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True) ## ipv4-address.h (module 'network'): void ns3::Ipv4Address::Serialize(uint8_t * buf) const [member function] cls.add_method('Serialize', 'void', [param('uint8_t *', 'buf')], is_const=True) ## ipv4-address.h (module 'network'): void ns3::Ipv4Address::Set(uint32_t address) [member function] cls.add_method('Set', 'void', [param('uint32_t', 'address')]) ## ipv4-address.h (module 'network'): void ns3::Ipv4Address::Set(char const * address) [member function] cls.add_method('Set', 'void', [param('char const *', 'address')]) return def register_Ns3Ipv4InterfaceAddress_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## ipv4-interface-address.h (module 'internet'): ns3::Ipv4InterfaceAddress::Ipv4InterfaceAddress() [constructor] cls.add_constructor([]) ## ipv4-interface-address.h (module 'internet'): ns3::Ipv4InterfaceAddress::Ipv4InterfaceAddress(ns3::Ipv4Address local, ns3::Ipv4Mask mask) [constructor] cls.add_constructor([param('ns3::Ipv4Address', 'local'), param('ns3::Ipv4Mask', 'mask')]) ## ipv4-interface-address.h (module 'internet'): ns3::Ipv4InterfaceAddress::Ipv4InterfaceAddress(ns3::Ipv4InterfaceAddress const & o) [copy constructor] cls.add_constructor([param('ns3::Ipv4InterfaceAddress const &', 'o')]) ## ipv4-interface-address.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4InterfaceAddress::GetBroadcast() const [member function] cls.add_method('GetBroadcast', 'ns3::Ipv4Address', [], is_const=True) ## ipv4-interface-address.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4InterfaceAddress::GetLocal() const [member function] cls.add_method('GetLocal', 'ns3::Ipv4Address', [], is_const=True) ## ipv4-interface-address.h (module 'internet'): ns3::Ipv4Mask ns3::Ipv4InterfaceAddress::GetMask() const [member function] cls.add_method('GetMask', 'ns3::Ipv4Mask', [], is_const=True) ## ipv4-interface-address.h (module 'internet'): ns3::Ipv4InterfaceAddress::InterfaceAddressScope_e ns3::Ipv4InterfaceAddress::GetScope() const [member function] cls.add_method('GetScope', 'ns3::Ipv4InterfaceAddress::InterfaceAddressScope_e', [], is_const=True) ## ipv4-interface-address.h (module 'internet'): bool ns3::Ipv4InterfaceAddress::IsSecondary() const [member function] cls.add_method('IsSecondary', 'bool', [], is_const=True) ## ipv4-interface-address.h (module 'internet'): void ns3::Ipv4InterfaceAddress::SetBroadcast(ns3::Ipv4Address broadcast) [member function] cls.add_method('SetBroadcast', 'void', [param('ns3::Ipv4Address', 'broadcast')]) ## ipv4-interface-address.h (module 'internet'): void ns3::Ipv4InterfaceAddress::SetLocal(ns3::Ipv4Address local) [member function] cls.add_method('SetLocal', 'void', [param('ns3::Ipv4Address', 'local')]) ## ipv4-interface-address.h (module 'internet'): void ns3::Ipv4InterfaceAddress::SetMask(ns3::Ipv4Mask mask) [member function] cls.add_method('SetMask', 'void', [param('ns3::Ipv4Mask', 'mask')]) ## ipv4-interface-address.h (module 'internet'): void ns3::Ipv4InterfaceAddress::SetPrimary() [member function] cls.add_method('SetPrimary', 'void', []) ## ipv4-interface-address.h (module 'internet'): void ns3::Ipv4InterfaceAddress::SetScope(ns3::Ipv4InterfaceAddress::InterfaceAddressScope_e scope) [member function] cls.add_method('SetScope', 'void', [param('ns3::Ipv4InterfaceAddress::InterfaceAddressScope_e', 'scope')]) ## ipv4-interface-address.h (module 'internet'): void ns3::Ipv4InterfaceAddress::SetSecondary() [member function] cls.add_method('SetSecondary', 'void', []) return def register_Ns3Ipv4Mask_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## ipv4-address.h (module 'network'): ns3::Ipv4Mask::Ipv4Mask(ns3::Ipv4Mask const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4Mask const &', 'arg0')]) ## ipv4-address.h (module 'network'): ns3::Ipv4Mask::Ipv4Mask() [constructor] cls.add_constructor([]) ## ipv4-address.h (module 'network'): ns3::Ipv4Mask::Ipv4Mask(uint32_t mask) [constructor] cls.add_constructor([param('uint32_t', 'mask')]) ## ipv4-address.h (module 'network'): ns3::Ipv4Mask::Ipv4Mask(char const * mask) [constructor] cls.add_constructor([param('char const *', 'mask')]) ## ipv4-address.h (module 'network'): uint32_t ns3::Ipv4Mask::Get() const [member function] cls.add_method('Get', 'uint32_t', [], is_const=True) ## ipv4-address.h (module 'network'): uint32_t ns3::Ipv4Mask::GetInverse() const [member function] cls.add_method('GetInverse', 'uint32_t', [], is_const=True) ## ipv4-address.h (module 'network'): static ns3::Ipv4Mask ns3::Ipv4Mask::GetLoopback() [member function] cls.add_method('GetLoopback', 'ns3::Ipv4Mask', [], is_static=True) ## ipv4-address.h (module 'network'): static ns3::Ipv4Mask ns3::Ipv4Mask::GetOnes() [member function] cls.add_method('GetOnes', 'ns3::Ipv4Mask', [], is_static=True) ## ipv4-address.h (module 'network'): uint16_t ns3::Ipv4Mask::GetPrefixLength() const [member function] cls.add_method('GetPrefixLength', 'uint16_t', [], is_const=True) ## ipv4-address.h (module 'network'): static ns3::Ipv4Mask ns3::Ipv4Mask::GetZero() [member function] cls.add_method('GetZero', 'ns3::Ipv4Mask', [], is_static=True) ## ipv4-address.h (module 'network'): bool ns3::Ipv4Mask::IsEqual(ns3::Ipv4Mask other) const [member function] cls.add_method('IsEqual', 'bool', [param('ns3::Ipv4Mask', 'other')], is_const=True) ## ipv4-address.h (module 'network'): bool ns3::Ipv4Mask::IsMatch(ns3::Ipv4Address a, ns3::Ipv4Address b) const [member function] cls.add_method('IsMatch', 'bool', [param('ns3::Ipv4Address', 'a'), param('ns3::Ipv4Address', 'b')], is_const=True) ## ipv4-address.h (module 'network'): void ns3::Ipv4Mask::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True) ## ipv4-address.h (module 'network'): void ns3::Ipv4Mask::Set(uint32_t mask) [member function] cls.add_method('Set', 'void', [param('uint32_t', 'mask')]) return def register_Ns3Ipv4RoutingHelper_methods(root_module, cls): ## ipv4-routing-helper.h (module 'internet'): ns3::Ipv4RoutingHelper::Ipv4RoutingHelper() [constructor] cls.add_constructor([]) ## ipv4-routing-helper.h (module 'internet'): ns3::Ipv4RoutingHelper::Ipv4RoutingHelper(ns3::Ipv4RoutingHelper const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4RoutingHelper const &', 'arg0')]) ## ipv4-routing-helper.h (module 'internet'): ns3::Ipv4RoutingHelper * ns3::Ipv4RoutingHelper::Copy() const [member function] cls.add_method('Copy', 'ns3::Ipv4RoutingHelper *', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4-routing-helper.h (module 'internet'): ns3::Ptr<ns3::Ipv4RoutingProtocol> ns3::Ipv4RoutingHelper::Create(ns3::Ptr<ns3::Node> node) const [member function] cls.add_method('Create', 'ns3::Ptr< ns3::Ipv4RoutingProtocol >', [param('ns3::Ptr< ns3::Node >', 'node')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4-routing-helper.h (module 'internet'): static void ns3::Ipv4RoutingHelper::PrintNeighborCacheAllAt(ns3::Time printTime, ns3::Ptr<ns3::OutputStreamWrapper> stream) [member function] cls.add_method('PrintNeighborCacheAllAt', 'void', [param('ns3::Time', 'printTime'), param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream')], is_static=True) ## ipv4-routing-helper.h (module 'internet'): static void ns3::Ipv4RoutingHelper::PrintNeighborCacheAllEvery(ns3::Time printInterval, ns3::Ptr<ns3::OutputStreamWrapper> stream) [member function] cls.add_method('PrintNeighborCacheAllEvery', 'void', [param('ns3::Time', 'printInterval'), param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream')], is_static=True) ## ipv4-routing-helper.h (module 'internet'): static void ns3::Ipv4RoutingHelper::PrintNeighborCacheAt(ns3::Time printTime, ns3::Ptr<ns3::Node> node, ns3::Ptr<ns3::OutputStreamWrapper> stream) [member function] cls.add_method('PrintNeighborCacheAt', 'void', [param('ns3::Time', 'printTime'), param('ns3::Ptr< ns3::Node >', 'node'), param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream')], is_static=True) ## ipv4-routing-helper.h (module 'internet'): static void ns3::Ipv4RoutingHelper::PrintNeighborCacheEvery(ns3::Time printInterval, ns3::Ptr<ns3::Node> node, ns3::Ptr<ns3::OutputStreamWrapper> stream) [member function] cls.add_method('PrintNeighborCacheEvery', 'void', [param('ns3::Time', 'printInterval'), param('ns3::Ptr< ns3::Node >', 'node'), param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream')], is_static=True) ## ipv4-routing-helper.h (module 'internet'): static void ns3::Ipv4RoutingHelper::PrintRoutingTableAllAt(ns3::Time printTime, ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::Time::Unit unit=::ns3::Time::S) [member function] cls.add_method('PrintRoutingTableAllAt', 'void', [param('ns3::Time', 'printTime'), param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::Time::Unit', 'unit', default_value='::ns3::Time::S')], is_static=True) ## ipv4-routing-helper.h (module 'internet'): static void ns3::Ipv4RoutingHelper::PrintRoutingTableAllEvery(ns3::Time printInterval, ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::Time::Unit unit=::ns3::Time::S) [member function] cls.add_method('PrintRoutingTableAllEvery', 'void', [param('ns3::Time', 'printInterval'), param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::Time::Unit', 'unit', default_value='::ns3::Time::S')], is_static=True) ## ipv4-routing-helper.h (module 'internet'): static void ns3::Ipv4RoutingHelper::PrintRoutingTableAt(ns3::Time printTime, ns3::Ptr<ns3::Node> node, ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::Time::Unit unit=::ns3::Time::S) [member function] cls.add_method('PrintRoutingTableAt', 'void', [param('ns3::Time', 'printTime'), param('ns3::Ptr< ns3::Node >', 'node'), param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::Time::Unit', 'unit', default_value='::ns3::Time::S')], is_static=True) ## ipv4-routing-helper.h (module 'internet'): static void ns3::Ipv4RoutingHelper::PrintRoutingTableEvery(ns3::Time printInterval, ns3::Ptr<ns3::Node> node, ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::Time::Unit unit=::ns3::Time::S) [member function] cls.add_method('PrintRoutingTableEvery', 'void', [param('ns3::Time', 'printInterval'), param('ns3::Ptr< ns3::Node >', 'node'), param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::Time::Unit', 'unit', default_value='::ns3::Time::S')], is_static=True) return def register_Ns3Ipv6Address_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_binary_comparison_operator('<') cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address() [constructor] cls.add_constructor([]) ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address(char const * address) [constructor] cls.add_constructor([param('char const *', 'address')]) ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address(uint8_t * address) [constructor] cls.add_constructor([param('uint8_t *', 'address')]) ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address(ns3::Ipv6Address const & addr) [copy constructor] cls.add_constructor([param('ns3::Ipv6Address const &', 'addr')]) ## ipv6-address.h (module 'network'): ns3::Ipv6Address::Ipv6Address(ns3::Ipv6Address const * addr) [constructor] cls.add_constructor([param('ns3::Ipv6Address const *', 'addr')]) ## ipv6-address.h (module 'network'): ns3::Ipv6Address ns3::Ipv6Address::CombinePrefix(ns3::Ipv6Prefix const & prefix) [member function] cls.add_method('CombinePrefix', 'ns3::Ipv6Address', [param('ns3::Ipv6Prefix const &', 'prefix')]) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::ConvertFrom(ns3::Address const & address) [member function] cls.add_method('ConvertFrom', 'ns3::Ipv6Address', [param('ns3::Address const &', 'address')], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::Deserialize(uint8_t const * buf) [member function] cls.add_method('Deserialize', 'ns3::Ipv6Address', [param('uint8_t const *', 'buf')], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetAllHostsMulticast() [member function] cls.add_method('GetAllHostsMulticast', 'ns3::Ipv6Address', [], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetAllNodesMulticast() [member function] cls.add_method('GetAllNodesMulticast', 'ns3::Ipv6Address', [], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetAllRoutersMulticast() [member function] cls.add_method('GetAllRoutersMulticast', 'ns3::Ipv6Address', [], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetAny() [member function] cls.add_method('GetAny', 'ns3::Ipv6Address', [], is_static=True) ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::GetBytes(uint8_t * buf) const [member function] cls.add_method('GetBytes', 'void', [param('uint8_t *', 'buf')], is_const=True) ## ipv6-address.h (module 'network'): ns3::Ipv4Address ns3::Ipv6Address::GetIpv4MappedAddress() const [member function] cls.add_method('GetIpv4MappedAddress', 'ns3::Ipv4Address', [], is_const=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetLoopback() [member function] cls.add_method('GetLoopback', 'ns3::Ipv6Address', [], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetOnes() [member function] cls.add_method('GetOnes', 'ns3::Ipv6Address', [], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::GetZero() [member function] cls.add_method('GetZero', 'ns3::Ipv6Address', [], is_static=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsAllHostsMulticast() const [member function] cls.add_method('IsAllHostsMulticast', 'bool', [], deprecated=True, is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsAllNodesMulticast() const [member function] cls.add_method('IsAllNodesMulticast', 'bool', [], is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsAllRoutersMulticast() const [member function] cls.add_method('IsAllRoutersMulticast', 'bool', [], is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsAny() const [member function] cls.add_method('IsAny', 'bool', [], is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsDocumentation() const [member function] cls.add_method('IsDocumentation', 'bool', [], is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsEqual(ns3::Ipv6Address const & other) const [member function] cls.add_method('IsEqual', 'bool', [param('ns3::Ipv6Address const &', 'other')], is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsIpv4MappedAddress() const [member function] cls.add_method('IsIpv4MappedAddress', 'bool', [], is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsLinkLocal() const [member function] cls.add_method('IsLinkLocal', 'bool', [], is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsLinkLocalMulticast() const [member function] cls.add_method('IsLinkLocalMulticast', 'bool', [], is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsLocalhost() const [member function] cls.add_method('IsLocalhost', 'bool', [], is_const=True) ## ipv6-address.h (module 'network'): static bool ns3::Ipv6Address::IsMatchingType(ns3::Address const & address) [member function] cls.add_method('IsMatchingType', 'bool', [param('ns3::Address const &', 'address')], is_static=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsMulticast() const [member function] cls.add_method('IsMulticast', 'bool', [], is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Address::IsSolicitedMulticast() const [member function] cls.add_method('IsSolicitedMulticast', 'bool', [], is_const=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeAutoconfiguredAddress(ns3::Mac16Address addr, ns3::Ipv6Address prefix) [member function] cls.add_method('MakeAutoconfiguredAddress', 'ns3::Ipv6Address', [param('ns3::Mac16Address', 'addr'), param('ns3::Ipv6Address', 'prefix')], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeAutoconfiguredAddress(ns3::Mac48Address addr, ns3::Ipv6Address prefix) [member function] cls.add_method('MakeAutoconfiguredAddress', 'ns3::Ipv6Address', [param('ns3::Mac48Address', 'addr'), param('ns3::Ipv6Address', 'prefix')], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeAutoconfiguredAddress(ns3::Mac64Address addr, ns3::Ipv6Address prefix) [member function] cls.add_method('MakeAutoconfiguredAddress', 'ns3::Ipv6Address', [param('ns3::Mac64Address', 'addr'), param('ns3::Ipv6Address', 'prefix')], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeAutoconfiguredLinkLocalAddress(ns3::Mac16Address mac) [member function] cls.add_method('MakeAutoconfiguredLinkLocalAddress', 'ns3::Ipv6Address', [param('ns3::Mac16Address', 'mac')], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeAutoconfiguredLinkLocalAddress(ns3::Mac48Address mac) [member function] cls.add_method('MakeAutoconfiguredLinkLocalAddress', 'ns3::Ipv6Address', [param('ns3::Mac48Address', 'mac')], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeAutoconfiguredLinkLocalAddress(ns3::Mac64Address mac) [member function] cls.add_method('MakeAutoconfiguredLinkLocalAddress', 'ns3::Ipv6Address', [param('ns3::Mac64Address', 'mac')], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeIpv4MappedAddress(ns3::Ipv4Address addr) [member function] cls.add_method('MakeIpv4MappedAddress', 'ns3::Ipv6Address', [param('ns3::Ipv4Address', 'addr')], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Address ns3::Ipv6Address::MakeSolicitedAddress(ns3::Ipv6Address addr) [member function] cls.add_method('MakeSolicitedAddress', 'ns3::Ipv6Address', [param('ns3::Ipv6Address', 'addr')], is_static=True) ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True) ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::Serialize(uint8_t * buf) const [member function] cls.add_method('Serialize', 'void', [param('uint8_t *', 'buf')], is_const=True) ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::Set(char const * address) [member function] cls.add_method('Set', 'void', [param('char const *', 'address')]) ## ipv6-address.h (module 'network'): void ns3::Ipv6Address::Set(uint8_t * address) [member function] cls.add_method('Set', 'void', [param('uint8_t *', 'address')]) return def register_Ns3Ipv6Prefix_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix() [constructor] cls.add_constructor([]) ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(uint8_t * prefix) [constructor] cls.add_constructor([param('uint8_t *', 'prefix')]) ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(char const * prefix) [constructor] cls.add_constructor([param('char const *', 'prefix')]) ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(uint8_t prefix) [constructor] cls.add_constructor([param('uint8_t', 'prefix')]) ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(ns3::Ipv6Prefix const & prefix) [copy constructor] cls.add_constructor([param('ns3::Ipv6Prefix const &', 'prefix')]) ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix::Ipv6Prefix(ns3::Ipv6Prefix const * prefix) [constructor] cls.add_constructor([param('ns3::Ipv6Prefix const *', 'prefix')]) ## ipv6-address.h (module 'network'): void ns3::Ipv6Prefix::GetBytes(uint8_t * buf) const [member function] cls.add_method('GetBytes', 'void', [param('uint8_t *', 'buf')], is_const=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Prefix ns3::Ipv6Prefix::GetLoopback() [member function] cls.add_method('GetLoopback', 'ns3::Ipv6Prefix', [], is_static=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Prefix ns3::Ipv6Prefix::GetOnes() [member function] cls.add_method('GetOnes', 'ns3::Ipv6Prefix', [], is_static=True) ## ipv6-address.h (module 'network'): uint8_t ns3::Ipv6Prefix::GetPrefixLength() const [member function] cls.add_method('GetPrefixLength', 'uint8_t', [], is_const=True) ## ipv6-address.h (module 'network'): static ns3::Ipv6Prefix ns3::Ipv6Prefix::GetZero() [member function] cls.add_method('GetZero', 'ns3::Ipv6Prefix', [], is_static=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Prefix::IsEqual(ns3::Ipv6Prefix const & other) const [member function] cls.add_method('IsEqual', 'bool', [param('ns3::Ipv6Prefix const &', 'other')], is_const=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6Prefix::IsMatch(ns3::Ipv6Address a, ns3::Ipv6Address b) const [member function] cls.add_method('IsMatch', 'bool', [param('ns3::Ipv6Address', 'a'), param('ns3::Ipv6Address', 'b')], is_const=True) ## ipv6-address.h (module 'network'): void ns3::Ipv6Prefix::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True) return def register_Ns3Mac48Address_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_binary_comparison_operator('<') cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## mac48-address.h (module 'network'): ns3::Mac48Address::Mac48Address(ns3::Mac48Address const & arg0) [copy constructor] cls.add_constructor([param('ns3::Mac48Address const &', 'arg0')]) ## mac48-address.h (module 'network'): ns3::Mac48Address::Mac48Address() [constructor] cls.add_constructor([]) ## mac48-address.h (module 'network'): ns3::Mac48Address::Mac48Address(char const * str) [constructor] cls.add_constructor([param('char const *', 'str')]) ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::Allocate() [member function] cls.add_method('Allocate', 'ns3::Mac48Address', [], is_static=True) ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::ConvertFrom(ns3::Address const & address) [member function] cls.add_method('ConvertFrom', 'ns3::Mac48Address', [param('ns3::Address const &', 'address')], is_static=True) ## mac48-address.h (module 'network'): void ns3::Mac48Address::CopyFrom(uint8_t const * buffer) [member function] cls.add_method('CopyFrom', 'void', [param('uint8_t const *', 'buffer')]) ## mac48-address.h (module 'network'): void ns3::Mac48Address::CopyTo(uint8_t * buffer) const [member function] cls.add_method('CopyTo', 'void', [param('uint8_t *', 'buffer')], is_const=True) ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetBroadcast() [member function] cls.add_method('GetBroadcast', 'ns3::Mac48Address', [], is_static=True) ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetMulticast(ns3::Ipv4Address address) [member function] cls.add_method('GetMulticast', 'ns3::Mac48Address', [param('ns3::Ipv4Address', 'address')], is_static=True) ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetMulticast(ns3::Ipv6Address address) [member function] cls.add_method('GetMulticast', 'ns3::Mac48Address', [param('ns3::Ipv6Address', 'address')], is_static=True) ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetMulticast6Prefix() [member function] cls.add_method('GetMulticast6Prefix', 'ns3::Mac48Address', [], is_static=True) ## mac48-address.h (module 'network'): static ns3::Mac48Address ns3::Mac48Address::GetMulticastPrefix() [member function] cls.add_method('GetMulticastPrefix', 'ns3::Mac48Address', [], is_static=True) ## mac48-address.h (module 'network'): bool ns3::Mac48Address::IsBroadcast() const [member function] cls.add_method('IsBroadcast', 'bool', [], is_const=True) ## mac48-address.h (module 'network'): bool ns3::Mac48Address::IsGroup() const [member function] cls.add_method('IsGroup', 'bool', [], is_const=True) ## mac48-address.h (module 'network'): static bool ns3::Mac48Address::IsMatchingType(ns3::Address const & address) [member function] cls.add_method('IsMatchingType', 'bool', [param('ns3::Address const &', 'address')], is_static=True) return def register_Ns3NodeContainer_methods(root_module, cls): ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & arg0) [copy constructor] cls.add_constructor([param('ns3::NodeContainer const &', 'arg0')]) ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer() [constructor] cls.add_constructor([]) ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::Ptr<ns3::Node> node) [constructor] cls.add_constructor([param('ns3::Ptr< ns3::Node >', 'node')]) ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(std::string nodeName) [constructor] cls.add_constructor([param('std::string', 'nodeName')]) ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & a, ns3::NodeContainer const & b) [constructor] cls.add_constructor([param('ns3::NodeContainer const &', 'a'), param('ns3::NodeContainer const &', 'b')]) ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & a, ns3::NodeContainer const & b, ns3::NodeContainer const & c) [constructor] cls.add_constructor([param('ns3::NodeContainer const &', 'a'), param('ns3::NodeContainer const &', 'b'), param('ns3::NodeContainer const &', 'c')]) ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & a, ns3::NodeContainer const & b, ns3::NodeContainer const & c, ns3::NodeContainer const & d) [constructor] cls.add_constructor([param('ns3::NodeContainer const &', 'a'), param('ns3::NodeContainer const &', 'b'), param('ns3::NodeContainer const &', 'c'), param('ns3::NodeContainer const &', 'd')]) ## node-container.h (module 'network'): ns3::NodeContainer::NodeContainer(ns3::NodeContainer const & a, ns3::NodeContainer const & b, ns3::NodeContainer const & c, ns3::NodeContainer const & d, ns3::NodeContainer const & e) [constructor] cls.add_constructor([param('ns3::NodeContainer const &', 'a'), param('ns3::NodeContainer const &', 'b'), param('ns3::NodeContainer const &', 'c'), param('ns3::NodeContainer const &', 'd'), param('ns3::NodeContainer const &', 'e')]) ## node-container.h (module 'network'): void ns3::NodeContainer::Add(ns3::NodeContainer other) [member function] cls.add_method('Add', 'void', [param('ns3::NodeContainer', 'other')]) ## node-container.h (module 'network'): void ns3::NodeContainer::Add(ns3::Ptr<ns3::Node> node) [member function] cls.add_method('Add', 'void', [param('ns3::Ptr< ns3::Node >', 'node')]) ## node-container.h (module 'network'): void ns3::NodeContainer::Add(std::string nodeName) [member function] cls.add_method('Add', 'void', [param('std::string', 'nodeName')]) ## node-container.h (module 'network'): __gnu_cxx::__normal_iterator<const ns3::Ptr<ns3::Node>*,std::vector<ns3::Ptr<ns3::Node>, std::allocator<ns3::Ptr<ns3::Node> > > > ns3::NodeContainer::Begin() const [member function] cls.add_method('Begin', '__gnu_cxx::__normal_iterator< ns3::Ptr< ns3::Node > const, std::vector< ns3::Ptr< ns3::Node > > >', [], is_const=True) ## node-container.h (module 'network'): void ns3::NodeContainer::Create(uint32_t n) [member function] cls.add_method('Create', 'void', [param('uint32_t', 'n')]) ## node-container.h (module 'network'): void ns3::NodeContainer::Create(uint32_t n, uint32_t systemId) [member function] cls.add_method('Create', 'void', [param('uint32_t', 'n'), param('uint32_t', 'systemId')]) ## node-container.h (module 'network'): __gnu_cxx::__normal_iterator<const ns3::Ptr<ns3::Node>*,std::vector<ns3::Ptr<ns3::Node>, std::allocator<ns3::Ptr<ns3::Node> > > > ns3::NodeContainer::End() const [member function] cls.add_method('End', '__gnu_cxx::__normal_iterator< ns3::Ptr< ns3::Node > const, std::vector< ns3::Ptr< ns3::Node > > >', [], is_const=True) ## node-container.h (module 'network'): ns3::Ptr<ns3::Node> ns3::NodeContainer::Get(uint32_t i) const [member function] cls.add_method('Get', 'ns3::Ptr< ns3::Node >', [param('uint32_t', 'i')], is_const=True) ## node-container.h (module 'network'): static ns3::NodeContainer ns3::NodeContainer::GetGlobal() [member function] cls.add_method('GetGlobal', 'ns3::NodeContainer', [], is_static=True) ## node-container.h (module 'network'): uint32_t ns3::NodeContainer::GetN() const [member function] cls.add_method('GetN', 'uint32_t', [], is_const=True) return def register_Ns3ObjectBase_methods(root_module, cls): ## object-base.h (module 'core'): ns3::ObjectBase::ObjectBase() [constructor] cls.add_constructor([]) ## object-base.h (module 'core'): ns3::ObjectBase::ObjectBase(ns3::ObjectBase const & arg0) [copy constructor] cls.add_constructor([param('ns3::ObjectBase const &', 'arg0')]) ## object-base.h (module 'core'): void ns3::ObjectBase::GetAttribute(std::string name, ns3::AttributeValue & value) const [member function] cls.add_method('GetAttribute', 'void', [param('std::string', 'name'), param('ns3::AttributeValue &', 'value')], is_const=True) ## object-base.h (module 'core'): bool ns3::ObjectBase::GetAttributeFailSafe(std::string name, ns3::AttributeValue & value) const [member function] cls.add_method('GetAttributeFailSafe', 'bool', [param('std::string', 'name'), param('ns3::AttributeValue &', 'value')], is_const=True) ## object-base.h (module 'core'): ns3::TypeId ns3::ObjectBase::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## object-base.h (module 'core'): static ns3::TypeId ns3::ObjectBase::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## object-base.h (module 'core'): void ns3::ObjectBase::SetAttribute(std::string name, ns3::AttributeValue const & value) [member function] cls.add_method('SetAttribute', 'void', [param('std::string', 'name'), param('ns3::AttributeValue const &', 'value')]) ## object-base.h (module 'core'): bool ns3::ObjectBase::SetAttributeFailSafe(std::string name, ns3::AttributeValue const & value) [member function] cls.add_method('SetAttributeFailSafe', 'bool', [param('std::string', 'name'), param('ns3::AttributeValue const &', 'value')]) ## object-base.h (module 'core'): bool ns3::ObjectBase::TraceConnect(std::string name, std::string context, ns3::CallbackBase const & cb) [member function] cls.add_method('TraceConnect', 'bool', [param('std::string', 'name'), param('std::string', 'context'), param('ns3::CallbackBase const &', 'cb')]) ## object-base.h (module 'core'): bool ns3::ObjectBase::TraceConnectWithoutContext(std::string name, ns3::CallbackBase const & cb) [member function] cls.add_method('TraceConnectWithoutContext', 'bool', [param('std::string', 'name'), param('ns3::CallbackBase const &', 'cb')]) ## object-base.h (module 'core'): bool ns3::ObjectBase::TraceDisconnect(std::string name, std::string context, ns3::CallbackBase const & cb) [member function] cls.add_method('TraceDisconnect', 'bool', [param('std::string', 'name'), param('std::string', 'context'), param('ns3::CallbackBase const &', 'cb')]) ## object-base.h (module 'core'): bool ns3::ObjectBase::TraceDisconnectWithoutContext(std::string name, ns3::CallbackBase const & cb) [member function] cls.add_method('TraceDisconnectWithoutContext', 'bool', [param('std::string', 'name'), param('ns3::CallbackBase const &', 'cb')]) ## object-base.h (module 'core'): void ns3::ObjectBase::ConstructSelf(ns3::AttributeConstructionList const & attributes) [member function] cls.add_method('ConstructSelf', 'void', [param('ns3::AttributeConstructionList const &', 'attributes')], visibility='protected') ## object-base.h (module 'core'): void ns3::ObjectBase::NotifyConstructionCompleted() [member function] cls.add_method('NotifyConstructionCompleted', 'void', [], visibility='protected', is_virtual=True) return def register_Ns3ObjectDeleter_methods(root_module, cls): ## object.h (module 'core'): ns3::ObjectDeleter::ObjectDeleter() [constructor] cls.add_constructor([]) ## object.h (module 'core'): ns3::ObjectDeleter::ObjectDeleter(ns3::ObjectDeleter const & arg0) [copy constructor] cls.add_constructor([param('ns3::ObjectDeleter const &', 'arg0')]) ## object.h (module 'core'): static void ns3::ObjectDeleter::Delete(ns3::Object * object) [member function] cls.add_method('Delete', 'void', [param('ns3::Object *', 'object')], is_static=True) return def register_Ns3ObjectFactory_methods(root_module, cls): cls.add_output_stream_operator() ## object-factory.h (module 'core'): ns3::ObjectFactory::ObjectFactory(ns3::ObjectFactory const & arg0) [copy constructor] cls.add_constructor([param('ns3::ObjectFactory const &', 'arg0')]) ## object-factory.h (module 'core'): ns3::ObjectFactory::ObjectFactory() [constructor] cls.add_constructor([]) ## object-factory.h (module 'core'): ns3::ObjectFactory::ObjectFactory(std::string typeId) [constructor] cls.add_constructor([param('std::string', 'typeId')]) ## object-factory.h (module 'core'): ns3::Ptr<ns3::Object> ns3::ObjectFactory::Create() const [member function] cls.add_method('Create', 'ns3::Ptr< ns3::Object >', [], is_const=True) ## object-factory.h (module 'core'): ns3::TypeId ns3::ObjectFactory::GetTypeId() const [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_const=True) ## object-factory.h (module 'core'): void ns3::ObjectFactory::Set(std::string name, ns3::AttributeValue const & value) [member function] cls.add_method('Set', 'void', [param('std::string', 'name'), param('ns3::AttributeValue const &', 'value')]) ## object-factory.h (module 'core'): void ns3::ObjectFactory::SetTypeId(ns3::TypeId tid) [member function] cls.add_method('SetTypeId', 'void', [param('ns3::TypeId', 'tid')]) ## object-factory.h (module 'core'): void ns3::ObjectFactory::SetTypeId(char const * tid) [member function] cls.add_method('SetTypeId', 'void', [param('char const *', 'tid')]) ## object-factory.h (module 'core'): void ns3::ObjectFactory::SetTypeId(std::string tid) [member function] cls.add_method('SetTypeId', 'void', [param('std::string', 'tid')]) return def register_Ns3PacketMetadata_methods(root_module, cls): ## packet-metadata.h (module 'network'): ns3::PacketMetadata::PacketMetadata(uint64_t uid, uint32_t size) [constructor] cls.add_constructor([param('uint64_t', 'uid'), param('uint32_t', 'size')]) ## packet-metadata.h (module 'network'): ns3::PacketMetadata::PacketMetadata(ns3::PacketMetadata const & o) [copy constructor] cls.add_constructor([param('ns3::PacketMetadata const &', 'o')]) ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::AddAtEnd(ns3::PacketMetadata const & o) [member function] cls.add_method('AddAtEnd', 'void', [param('ns3::PacketMetadata const &', 'o')]) ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::AddHeader(ns3::Header const & header, uint32_t size) [member function] cls.add_method('AddHeader', 'void', [param('ns3::Header const &', 'header'), param('uint32_t', 'size')]) ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::AddPaddingAtEnd(uint32_t end) [member function] cls.add_method('AddPaddingAtEnd', 'void', [param('uint32_t', 'end')]) ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::AddTrailer(ns3::Trailer const & trailer, uint32_t size) [member function] cls.add_method('AddTrailer', 'void', [param('ns3::Trailer const &', 'trailer'), param('uint32_t', 'size')]) ## packet-metadata.h (module 'network'): ns3::PacketMetadata::ItemIterator ns3::PacketMetadata::BeginItem(ns3::Buffer buffer) const [member function] cls.add_method('BeginItem', 'ns3::PacketMetadata::ItemIterator', [param('ns3::Buffer', 'buffer')], is_const=True) ## packet-metadata.h (module 'network'): ns3::PacketMetadata ns3::PacketMetadata::CreateFragment(uint32_t start, uint32_t end) const [member function] cls.add_method('CreateFragment', 'ns3::PacketMetadata', [param('uint32_t', 'start'), param('uint32_t', 'end')], is_const=True) ## packet-metadata.h (module 'network'): uint32_t ns3::PacketMetadata::Deserialize(uint8_t const * buffer, uint32_t size) [member function] cls.add_method('Deserialize', 'uint32_t', [param('uint8_t const *', 'buffer'), param('uint32_t', 'size')]) ## packet-metadata.h (module 'network'): static void ns3::PacketMetadata::Enable() [member function] cls.add_method('Enable', 'void', [], is_static=True) ## packet-metadata.h (module 'network'): static void ns3::PacketMetadata::EnableChecking() [member function] cls.add_method('EnableChecking', 'void', [], is_static=True) ## packet-metadata.h (module 'network'): uint32_t ns3::PacketMetadata::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True) ## packet-metadata.h (module 'network'): uint64_t ns3::PacketMetadata::GetUid() const [member function] cls.add_method('GetUid', 'uint64_t', [], is_const=True) ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::RemoveAtEnd(uint32_t end) [member function] cls.add_method('RemoveAtEnd', 'void', [param('uint32_t', 'end')]) ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::RemoveAtStart(uint32_t start) [member function] cls.add_method('RemoveAtStart', 'void', [param('uint32_t', 'start')]) ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::RemoveHeader(ns3::Header const & header, uint32_t size) [member function] cls.add_method('RemoveHeader', 'void', [param('ns3::Header const &', 'header'), param('uint32_t', 'size')]) ## packet-metadata.h (module 'network'): void ns3::PacketMetadata::RemoveTrailer(ns3::Trailer const & trailer, uint32_t size) [member function] cls.add_method('RemoveTrailer', 'void', [param('ns3::Trailer const &', 'trailer'), param('uint32_t', 'size')]) ## packet-metadata.h (module 'network'): uint32_t ns3::PacketMetadata::Serialize(uint8_t * buffer, uint32_t maxSize) const [member function] cls.add_method('Serialize', 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) return def register_Ns3PacketMetadataItem_methods(root_module, cls): ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::Item() [constructor] cls.add_constructor([]) ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::Item(ns3::PacketMetadata::Item const & arg0) [copy constructor] cls.add_constructor([param('ns3::PacketMetadata::Item const &', 'arg0')]) ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::current [variable] cls.add_instance_attribute('current', 'ns3::Buffer::Iterator', is_const=False) ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::currentSize [variable] cls.add_instance_attribute('currentSize', 'uint32_t', is_const=False) ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::currentTrimedFromEnd [variable] cls.add_instance_attribute('currentTrimedFromEnd', 'uint32_t', is_const=False) ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::currentTrimedFromStart [variable] cls.add_instance_attribute('currentTrimedFromStart', 'uint32_t', is_const=False) ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::isFragment [variable] cls.add_instance_attribute('isFragment', 'bool', is_const=False) ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item::tid [variable] cls.add_instance_attribute('tid', 'ns3::TypeId', is_const=False) return def register_Ns3PacketMetadataItemIterator_methods(root_module, cls): ## packet-metadata.h (module 'network'): ns3::PacketMetadata::ItemIterator::ItemIterator(ns3::PacketMetadata::ItemIterator const & arg0) [copy constructor] cls.add_constructor([param('ns3::PacketMetadata::ItemIterator const &', 'arg0')]) ## packet-metadata.h (module 'network'): ns3::PacketMetadata::ItemIterator::ItemIterator(ns3::PacketMetadata const * metadata, ns3::Buffer buffer) [constructor] cls.add_constructor([param('ns3::PacketMetadata const *', 'metadata'), param('ns3::Buffer', 'buffer')]) ## packet-metadata.h (module 'network'): bool ns3::PacketMetadata::ItemIterator::HasNext() const [member function] cls.add_method('HasNext', 'bool', [], is_const=True) ## packet-metadata.h (module 'network'): ns3::PacketMetadata::Item ns3::PacketMetadata::ItemIterator::Next() [member function] cls.add_method('Next', 'ns3::PacketMetadata::Item', []) return def register_Ns3PacketTagIterator_methods(root_module, cls): ## packet.h (module 'network'): ns3::PacketTagIterator::PacketTagIterator(ns3::PacketTagIterator const & arg0) [copy constructor] cls.add_constructor([param('ns3::PacketTagIterator const &', 'arg0')]) ## packet.h (module 'network'): bool ns3::PacketTagIterator::HasNext() const [member function] cls.add_method('HasNext', 'bool', [], is_const=True) ## packet.h (module 'network'): ns3::PacketTagIterator::Item ns3::PacketTagIterator::Next() [member function] cls.add_method('Next', 'ns3::PacketTagIterator::Item', []) return def register_Ns3PacketTagIteratorItem_methods(root_module, cls): ## packet.h (module 'network'): ns3::PacketTagIterator::Item::Item(ns3::PacketTagIterator::Item const & arg0) [copy constructor] cls.add_constructor([param('ns3::PacketTagIterator::Item const &', 'arg0')]) ## packet.h (module 'network'): void ns3::PacketTagIterator::Item::GetTag(ns3::Tag & tag) const [member function] cls.add_method('GetTag', 'void', [param('ns3::Tag &', 'tag')], is_const=True) ## packet.h (module 'network'): ns3::TypeId ns3::PacketTagIterator::Item::GetTypeId() const [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_const=True) return def register_Ns3PacketTagList_methods(root_module, cls): ## packet-tag-list.h (module 'network'): ns3::PacketTagList::PacketTagList() [constructor] cls.add_constructor([]) ## packet-tag-list.h (module 'network'): ns3::PacketTagList::PacketTagList(ns3::PacketTagList const & o) [copy constructor] cls.add_constructor([param('ns3::PacketTagList const &', 'o')]) ## packet-tag-list.h (module 'network'): void ns3::PacketTagList::Add(ns3::Tag const & tag) const [member function] cls.add_method('Add', 'void', [param('ns3::Tag const &', 'tag')], is_const=True) ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData const * ns3::PacketTagList::Head() const [member function] cls.add_method('Head', 'ns3::PacketTagList::TagData const *', [], is_const=True) ## packet-tag-list.h (module 'network'): bool ns3::PacketTagList::Peek(ns3::Tag & tag) const [member function] cls.add_method('Peek', 'bool', [param('ns3::Tag &', 'tag')], is_const=True) ## packet-tag-list.h (module 'network'): bool ns3::PacketTagList::Remove(ns3::Tag & tag) [member function] cls.add_method('Remove', 'bool', [param('ns3::Tag &', 'tag')]) ## packet-tag-list.h (module 'network'): void ns3::PacketTagList::RemoveAll() [member function] cls.add_method('RemoveAll', 'void', []) ## packet-tag-list.h (module 'network'): bool ns3::PacketTagList::Replace(ns3::Tag & tag) [member function] cls.add_method('Replace', 'bool', [param('ns3::Tag &', 'tag')]) return def register_Ns3PacketTagListTagData_methods(root_module, cls): ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::TagData() [constructor] cls.add_constructor([]) ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::TagData(ns3::PacketTagList::TagData const & arg0) [copy constructor] cls.add_constructor([param('ns3::PacketTagList::TagData const &', 'arg0')]) ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::count [variable] cls.add_instance_attribute('count', 'uint32_t', is_const=False) ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::data [variable] cls.add_instance_attribute('data', 'uint8_t [ 1 ]', is_const=False) ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::next [variable] cls.add_instance_attribute('next', 'ns3::PacketTagList::TagData *', is_const=False) ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::size [variable] cls.add_instance_attribute('size', 'uint32_t', is_const=False) ## packet-tag-list.h (module 'network'): ns3::PacketTagList::TagData::tid [variable] cls.add_instance_attribute('tid', 'ns3::TypeId', is_const=False) return def register_Ns3SimpleRefCount__Ns3Object_Ns3ObjectBase_Ns3ObjectDeleter_methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter>::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter>::SimpleRefCount(ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter> const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::Object, ns3::ObjectBase, ns3::ObjectDeleter>::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3Simulator_methods(root_module, cls): ## simulator.h (module 'core'): ns3::Simulator::Simulator(ns3::Simulator const & arg0) [copy constructor] cls.add_constructor([param('ns3::Simulator const &', 'arg0')]) ## simulator.h (module 'core'): static void ns3::Simulator::Cancel(ns3::EventId const & id) [member function] cls.add_method('Cancel', 'void', [param('ns3::EventId const &', 'id')], is_static=True) ## simulator.h (module 'core'): static void ns3::Simulator::Destroy() [member function] cls.add_method('Destroy', 'void', [], is_static=True) ## simulator.h (module 'core'): static uint32_t ns3::Simulator::GetContext() [member function] cls.add_method('GetContext', 'uint32_t', [], is_static=True) ## simulator.h (module 'core'): static ns3::Time ns3::Simulator::GetDelayLeft(ns3::EventId const & id) [member function] cls.add_method('GetDelayLeft', 'ns3::Time', [param('ns3::EventId const &', 'id')], is_static=True) ## simulator.h (module 'core'): static ns3::Ptr<ns3::SimulatorImpl> ns3::Simulator::GetImplementation() [member function] cls.add_method('GetImplementation', 'ns3::Ptr< ns3::SimulatorImpl >', [], is_static=True) ## simulator.h (module 'core'): static ns3::Time ns3::Simulator::GetMaximumSimulationTime() [member function] cls.add_method('GetMaximumSimulationTime', 'ns3::Time', [], is_static=True) ## simulator.h (module 'core'): static uint32_t ns3::Simulator::GetSystemId() [member function] cls.add_method('GetSystemId', 'uint32_t', [], is_static=True) ## simulator.h (module 'core'): static bool ns3::Simulator::IsExpired(ns3::EventId const & id) [member function] cls.add_method('IsExpired', 'bool', [param('ns3::EventId const &', 'id')], is_static=True) ## simulator.h (module 'core'): static bool ns3::Simulator::IsFinished() [member function] cls.add_method('IsFinished', 'bool', [], is_static=True) ## simulator.h (module 'core'): static ns3::Time ns3::Simulator::Now() [member function] cls.add_method('Now', 'ns3::Time', [], is_static=True) ## simulator.h (module 'core'): static void ns3::Simulator::Remove(ns3::EventId const & id) [member function] cls.add_method('Remove', 'void', [param('ns3::EventId const &', 'id')], is_static=True) ## simulator.h (module 'core'): static void ns3::Simulator::SetImplementation(ns3::Ptr<ns3::SimulatorImpl> impl) [member function] cls.add_method('SetImplementation', 'void', [param('ns3::Ptr< ns3::SimulatorImpl >', 'impl')], is_static=True) ## simulator.h (module 'core'): static void ns3::Simulator::SetScheduler(ns3::ObjectFactory schedulerFactory) [member function] cls.add_method('SetScheduler', 'void', [param('ns3::ObjectFactory', 'schedulerFactory')], is_static=True) ## simulator.h (module 'core'): static void ns3::Simulator::Stop() [member function] cls.add_method('Stop', 'void', [], is_static=True) ## simulator.h (module 'core'): static void ns3::Simulator::Stop(ns3::Time const & delay) [member function] cls.add_method('Stop', 'void', [param('ns3::Time const &', 'delay')], is_static=True) return def register_Ns3Tag_methods(root_module, cls): ## tag.h (module 'network'): ns3::Tag::Tag() [constructor] cls.add_constructor([]) ## tag.h (module 'network'): ns3::Tag::Tag(ns3::Tag const & arg0) [copy constructor] cls.add_constructor([param('ns3::Tag const &', 'arg0')]) ## tag.h (module 'network'): void ns3::Tag::Deserialize(ns3::TagBuffer i) [member function] cls.add_method('Deserialize', 'void', [param('ns3::TagBuffer', 'i')], is_pure_virtual=True, is_virtual=True) ## tag.h (module 'network'): uint32_t ns3::Tag::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## tag.h (module 'network'): static ns3::TypeId ns3::Tag::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## tag.h (module 'network'): void ns3::Tag::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_pure_virtual=True, is_const=True, is_virtual=True) ## tag.h (module 'network'): void ns3::Tag::Serialize(ns3::TagBuffer i) const [member function] cls.add_method('Serialize', 'void', [param('ns3::TagBuffer', 'i')], is_pure_virtual=True, is_const=True, is_virtual=True) return def register_Ns3TagBuffer_methods(root_module, cls): ## tag-buffer.h (module 'network'): ns3::TagBuffer::TagBuffer(ns3::TagBuffer const & arg0) [copy constructor] cls.add_constructor([param('ns3::TagBuffer const &', 'arg0')]) ## tag-buffer.h (module 'network'): ns3::TagBuffer::TagBuffer(uint8_t * start, uint8_t * end) [constructor] cls.add_constructor([param('uint8_t *', 'start'), param('uint8_t *', 'end')]) ## tag-buffer.h (module 'network'): void ns3::TagBuffer::CopyFrom(ns3::TagBuffer o) [member function] cls.add_method('CopyFrom', 'void', [param('ns3::TagBuffer', 'o')]) ## tag-buffer.h (module 'network'): void ns3::TagBuffer::Read(uint8_t * buffer, uint32_t size) [member function] cls.add_method('Read', 'void', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')]) ## tag-buffer.h (module 'network'): double ns3::TagBuffer::ReadDouble() [member function] cls.add_method('ReadDouble', 'double', []) ## tag-buffer.h (module 'network'): uint16_t ns3::TagBuffer::ReadU16() [member function] cls.add_method('ReadU16', 'uint16_t', []) ## tag-buffer.h (module 'network'): uint32_t ns3::TagBuffer::ReadU32() [member function] cls.add_method('ReadU32', 'uint32_t', []) ## tag-buffer.h (module 'network'): uint64_t ns3::TagBuffer::ReadU64() [member function] cls.add_method('ReadU64', 'uint64_t', []) ## tag-buffer.h (module 'network'): uint8_t ns3::TagBuffer::ReadU8() [member function] cls.add_method('ReadU8', 'uint8_t', []) ## tag-buffer.h (module 'network'): void ns3::TagBuffer::TrimAtEnd(uint32_t trim) [member function] cls.add_method('TrimAtEnd', 'void', [param('uint32_t', 'trim')]) ## tag-buffer.h (module 'network'): void ns3::TagBuffer::Write(uint8_t const * buffer, uint32_t size) [member function] cls.add_method('Write', 'void', [param('uint8_t const *', 'buffer'), param('uint32_t', 'size')]) ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteDouble(double v) [member function] cls.add_method('WriteDouble', 'void', [param('double', 'v')]) ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteU16(uint16_t data) [member function] cls.add_method('WriteU16', 'void', [param('uint16_t', 'data')]) ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteU32(uint32_t data) [member function] cls.add_method('WriteU32', 'void', [param('uint32_t', 'data')]) ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteU64(uint64_t v) [member function] cls.add_method('WriteU64', 'void', [param('uint64_t', 'v')]) ## tag-buffer.h (module 'network'): void ns3::TagBuffer::WriteU8(uint8_t v) [member function] cls.add_method('WriteU8', 'void', [param('uint8_t', 'v')]) return def register_Ns3TimeWithUnit_methods(root_module, cls): cls.add_output_stream_operator() ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::TimeWithUnit const & arg0) [copy constructor] cls.add_constructor([param('ns3::TimeWithUnit const &', 'arg0')]) ## nstime.h (module 'core'): ns3::TimeWithUnit::TimeWithUnit(ns3::Time const time, ns3::Time::Unit const unit) [constructor] cls.add_constructor([param('ns3::Time const', 'time'), param('ns3::Time::Unit const', 'unit')]) return def register_Ns3Timer_methods(root_module, cls): ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer const & arg0) [copy constructor] cls.add_constructor([param('ns3::Timer const &', 'arg0')]) ## timer.h (module 'core'): ns3::Timer::Timer() [constructor] cls.add_constructor([]) ## timer.h (module 'core'): ns3::Timer::Timer(ns3::Timer::DestroyPolicy destroyPolicy) [constructor] cls.add_constructor([param('ns3::Timer::DestroyPolicy', 'destroyPolicy')]) ## timer.h (module 'core'): void ns3::Timer::Cancel() [member function] cls.add_method('Cancel', 'void', []) ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelay() const [member function] cls.add_method('GetDelay', 'ns3::Time', [], is_const=True) ## timer.h (module 'core'): ns3::Time ns3::Timer::GetDelayLeft() const [member function] cls.add_method('GetDelayLeft', 'ns3::Time', [], is_const=True) ## timer.h (module 'core'): ns3::Timer::State ns3::Timer::GetState() const [member function] cls.add_method('GetState', 'ns3::Timer::State', [], is_const=True) ## timer.h (module 'core'): bool ns3::Timer::IsExpired() const [member function] cls.add_method('IsExpired', 'bool', [], is_const=True) ## timer.h (module 'core'): bool ns3::Timer::IsRunning() const [member function] cls.add_method('IsRunning', 'bool', [], is_const=True) ## timer.h (module 'core'): bool ns3::Timer::IsSuspended() const [member function] cls.add_method('IsSuspended', 'bool', [], is_const=True) ## timer.h (module 'core'): void ns3::Timer::Remove() [member function] cls.add_method('Remove', 'void', []) ## timer.h (module 'core'): void ns3::Timer::Resume() [member function] cls.add_method('Resume', 'void', []) ## timer.h (module 'core'): void ns3::Timer::Schedule() [member function] cls.add_method('Schedule', 'void', []) ## timer.h (module 'core'): void ns3::Timer::Schedule(ns3::Time delay) [member function] cls.add_method('Schedule', 'void', [param('ns3::Time', 'delay')]) ## timer.h (module 'core'): void ns3::Timer::SetDelay(ns3::Time const & delay) [member function] cls.add_method('SetDelay', 'void', [param('ns3::Time const &', 'delay')]) ## timer.h (module 'core'): void ns3::Timer::Suspend() [member function] cls.add_method('Suspend', 'void', []) return def register_Ns3TimerImpl_methods(root_module, cls): ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl() [constructor] cls.add_constructor([]) ## timer-impl.h (module 'core'): ns3::TimerImpl::TimerImpl(ns3::TimerImpl const & arg0) [copy constructor] cls.add_constructor([param('ns3::TimerImpl const &', 'arg0')]) ## timer-impl.h (module 'core'): void ns3::TimerImpl::Invoke() [member function] cls.add_method('Invoke', 'void', [], is_pure_virtual=True, is_virtual=True) ## timer-impl.h (module 'core'): ns3::EventId ns3::TimerImpl::Schedule(ns3::Time const & delay) [member function] cls.add_method('Schedule', 'ns3::EventId', [param('ns3::Time const &', 'delay')], is_pure_virtual=True, is_virtual=True) return def register_Ns3TypeId_methods(root_module, cls): cls.add_binary_comparison_operator('!=') cls.add_binary_comparison_operator('<') cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## type-id.h (module 'core'): ns3::TypeId::TypeId(char const * name) [constructor] cls.add_constructor([param('char const *', 'name')]) ## type-id.h (module 'core'): ns3::TypeId::TypeId() [constructor] cls.add_constructor([]) ## type-id.h (module 'core'): ns3::TypeId::TypeId(ns3::TypeId const & o) [copy constructor] cls.add_constructor([param('ns3::TypeId const &', 'o')]) ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::AddAttribute(std::string name, std::string help, ns3::AttributeValue const & initialValue, ns3::Ptr<ns3::AttributeAccessor const> accessor, ns3::Ptr<ns3::AttributeChecker const> checker, ns3::TypeId::SupportLevel supportLevel=::ns3::TypeId::SUPPORTED, std::string const & supportMsg="") [member function] cls.add_method('AddAttribute', 'ns3::TypeId', [param('std::string', 'name'), param('std::string', 'help'), param('ns3::AttributeValue const &', 'initialValue'), param('ns3::Ptr< ns3::AttributeAccessor const >', 'accessor'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker'), param('ns3::TypeId::SupportLevel', 'supportLevel', default_value='::ns3::TypeId::SUPPORTED'), param('std::string const &', 'supportMsg', default_value='""')]) ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::AddAttribute(std::string name, std::string help, uint32_t flags, ns3::AttributeValue const & initialValue, ns3::Ptr<ns3::AttributeAccessor const> accessor, ns3::Ptr<ns3::AttributeChecker const> checker, ns3::TypeId::SupportLevel supportLevel=::ns3::TypeId::SUPPORTED, std::string const & supportMsg="") [member function] cls.add_method('AddAttribute', 'ns3::TypeId', [param('std::string', 'name'), param('std::string', 'help'), param('uint32_t', 'flags'), param('ns3::AttributeValue const &', 'initialValue'), param('ns3::Ptr< ns3::AttributeAccessor const >', 'accessor'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker'), param('ns3::TypeId::SupportLevel', 'supportLevel', default_value='::ns3::TypeId::SUPPORTED'), param('std::string const &', 'supportMsg', default_value='""')]) ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::AddTraceSource(std::string name, std::string help, ns3::Ptr<ns3::TraceSourceAccessor const> accessor) [member function] cls.add_method('AddTraceSource', 'ns3::TypeId', [param('std::string', 'name'), param('std::string', 'help'), param('ns3::Ptr< ns3::TraceSourceAccessor const >', 'accessor')], deprecated=True) ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::AddTraceSource(std::string name, std::string help, ns3::Ptr<ns3::TraceSourceAccessor const> accessor, std::string callback, ns3::TypeId::SupportLevel supportLevel=::ns3::TypeId::SUPPORTED, std::string const & supportMsg="") [member function] cls.add_method('AddTraceSource', 'ns3::TypeId', [param('std::string', 'name'), param('std::string', 'help'), param('ns3::Ptr< ns3::TraceSourceAccessor const >', 'accessor'), param('std::string', 'callback'), param('ns3::TypeId::SupportLevel', 'supportLevel', default_value='::ns3::TypeId::SUPPORTED'), param('std::string const &', 'supportMsg', default_value='""')]) ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation ns3::TypeId::GetAttribute(uint32_t i) const [member function] cls.add_method('GetAttribute', 'ns3::TypeId::AttributeInformation', [param('uint32_t', 'i')], is_const=True) ## type-id.h (module 'core'): std::string ns3::TypeId::GetAttributeFullName(uint32_t i) const [member function] cls.add_method('GetAttributeFullName', 'std::string', [param('uint32_t', 'i')], is_const=True) ## type-id.h (module 'core'): uint32_t ns3::TypeId::GetAttributeN() const [member function] cls.add_method('GetAttributeN', 'uint32_t', [], is_const=True) ## type-id.h (module 'core'): ns3::Callback<ns3::ObjectBase*,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> ns3::TypeId::GetConstructor() const [member function] cls.add_method('GetConstructor', 'ns3::Callback< ns3::ObjectBase *, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', [], is_const=True) ## type-id.h (module 'core'): std::string ns3::TypeId::GetGroupName() const [member function] cls.add_method('GetGroupName', 'std::string', [], is_const=True) ## type-id.h (module 'core'): uint32_t ns3::TypeId::GetHash() const [member function] cls.add_method('GetHash', 'uint32_t', [], is_const=True) ## type-id.h (module 'core'): std::string ns3::TypeId::GetName() const [member function] cls.add_method('GetName', 'std::string', [], is_const=True) ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::GetParent() const [member function] cls.add_method('GetParent', 'ns3::TypeId', [], is_const=True) ## type-id.h (module 'core'): static ns3::TypeId ns3::TypeId::GetRegistered(uint32_t i) [member function] cls.add_method('GetRegistered', 'ns3::TypeId', [param('uint32_t', 'i')], is_static=True) ## type-id.h (module 'core'): static uint32_t ns3::TypeId::GetRegisteredN() [member function] cls.add_method('GetRegisteredN', 'uint32_t', [], is_static=True) ## type-id.h (module 'core'): std::size_t ns3::TypeId::GetSize() const [member function] cls.add_method('GetSize', 'std::size_t', [], is_const=True) ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation ns3::TypeId::GetTraceSource(uint32_t i) const [member function] cls.add_method('GetTraceSource', 'ns3::TypeId::TraceSourceInformation', [param('uint32_t', 'i')], is_const=True) ## type-id.h (module 'core'): uint32_t ns3::TypeId::GetTraceSourceN() const [member function] cls.add_method('GetTraceSourceN', 'uint32_t', [], is_const=True) ## type-id.h (module 'core'): uint16_t ns3::TypeId::GetUid() const [member function] cls.add_method('GetUid', 'uint16_t', [], is_const=True) ## type-id.h (module 'core'): bool ns3::TypeId::HasConstructor() const [member function] cls.add_method('HasConstructor', 'bool', [], is_const=True) ## type-id.h (module 'core'): bool ns3::TypeId::HasParent() const [member function] cls.add_method('HasParent', 'bool', [], is_const=True) ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::HideFromDocumentation() [member function] cls.add_method('HideFromDocumentation', 'ns3::TypeId', []) ## type-id.h (module 'core'): bool ns3::TypeId::IsChildOf(ns3::TypeId other) const [member function] cls.add_method('IsChildOf', 'bool', [param('ns3::TypeId', 'other')], is_const=True) ## type-id.h (module 'core'): bool ns3::TypeId::LookupAttributeByName(std::string name, ns3::TypeId::AttributeInformation * info) const [member function] cls.add_method('LookupAttributeByName', 'bool', [param('std::string', 'name'), param('ns3::TypeId::AttributeInformation *', 'info', transfer_ownership=False)], is_const=True) ## type-id.h (module 'core'): static ns3::TypeId ns3::TypeId::LookupByHash(uint32_t hash) [member function] cls.add_method('LookupByHash', 'ns3::TypeId', [param('uint32_t', 'hash')], is_static=True) ## type-id.h (module 'core'): static bool ns3::TypeId::LookupByHashFailSafe(uint32_t hash, ns3::TypeId * tid) [member function] cls.add_method('LookupByHashFailSafe', 'bool', [param('uint32_t', 'hash'), param('ns3::TypeId *', 'tid')], is_static=True) ## type-id.h (module 'core'): static ns3::TypeId ns3::TypeId::LookupByName(std::string name) [member function] cls.add_method('LookupByName', 'ns3::TypeId', [param('std::string', 'name')], is_static=True) ## type-id.h (module 'core'): ns3::Ptr<ns3::TraceSourceAccessor const> ns3::TypeId::LookupTraceSourceByName(std::string name) const [member function] cls.add_method('LookupTraceSourceByName', 'ns3::Ptr< ns3::TraceSourceAccessor const >', [param('std::string', 'name')], is_const=True) ## type-id.h (module 'core'): ns3::Ptr<ns3::TraceSourceAccessor const> ns3::TypeId::LookupTraceSourceByName(std::string name, ns3::TypeId::TraceSourceInformation * info) const [member function] cls.add_method('LookupTraceSourceByName', 'ns3::Ptr< ns3::TraceSourceAccessor const >', [param('std::string', 'name'), param('ns3::TypeId::TraceSourceInformation *', 'info')], is_const=True) ## type-id.h (module 'core'): bool ns3::TypeId::MustHideFromDocumentation() const [member function] cls.add_method('MustHideFromDocumentation', 'bool', [], is_const=True) ## type-id.h (module 'core'): bool ns3::TypeId::SetAttributeInitialValue(uint32_t i, ns3::Ptr<ns3::AttributeValue const> initialValue) [member function] cls.add_method('SetAttributeInitialValue', 'bool', [param('uint32_t', 'i'), param('ns3::Ptr< ns3::AttributeValue const >', 'initialValue')]) ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::SetGroupName(std::string groupName) [member function] cls.add_method('SetGroupName', 'ns3::TypeId', [param('std::string', 'groupName')]) ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::SetParent(ns3::TypeId tid) [member function] cls.add_method('SetParent', 'ns3::TypeId', [param('ns3::TypeId', 'tid')]) ## type-id.h (module 'core'): ns3::TypeId ns3::TypeId::SetSize(std::size_t size) [member function] cls.add_method('SetSize', 'ns3::TypeId', [param('std::size_t', 'size')]) ## type-id.h (module 'core'): void ns3::TypeId::SetUid(uint16_t uid) [member function] cls.add_method('SetUid', 'void', [param('uint16_t', 'uid')]) return def register_Ns3TypeIdAttributeInformation_methods(root_module, cls): ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::AttributeInformation() [constructor] cls.add_constructor([]) ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::AttributeInformation(ns3::TypeId::AttributeInformation const & arg0) [copy constructor] cls.add_constructor([param('ns3::TypeId::AttributeInformation const &', 'arg0')]) ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::accessor [variable] cls.add_instance_attribute('accessor', 'ns3::Ptr< ns3::AttributeAccessor const >', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::checker [variable] cls.add_instance_attribute('checker', 'ns3::Ptr< ns3::AttributeChecker const >', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::flags [variable] cls.add_instance_attribute('flags', 'uint32_t', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::help [variable] cls.add_instance_attribute('help', 'std::string', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::initialValue [variable] cls.add_instance_attribute('initialValue', 'ns3::Ptr< ns3::AttributeValue const >', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::name [variable] cls.add_instance_attribute('name', 'std::string', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::originalInitialValue [variable] cls.add_instance_attribute('originalInitialValue', 'ns3::Ptr< ns3::AttributeValue const >', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::supportLevel [variable] cls.add_instance_attribute('supportLevel', 'ns3::TypeId::SupportLevel', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::AttributeInformation::supportMsg [variable] cls.add_instance_attribute('supportMsg', 'std::string', is_const=False) return def register_Ns3TypeIdTraceSourceInformation_methods(root_module, cls): ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::TraceSourceInformation() [constructor] cls.add_constructor([]) ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::TraceSourceInformation(ns3::TypeId::TraceSourceInformation const & arg0) [copy constructor] cls.add_constructor([param('ns3::TypeId::TraceSourceInformation const &', 'arg0')]) ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::accessor [variable] cls.add_instance_attribute('accessor', 'ns3::Ptr< ns3::TraceSourceAccessor const >', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::callback [variable] cls.add_instance_attribute('callback', 'std::string', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::help [variable] cls.add_instance_attribute('help', 'std::string', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::name [variable] cls.add_instance_attribute('name', 'std::string', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::supportLevel [variable] cls.add_instance_attribute('supportLevel', 'ns3::TypeId::SupportLevel', is_const=False) ## type-id.h (module 'core'): ns3::TypeId::TraceSourceInformation::supportMsg [variable] cls.add_instance_attribute('supportMsg', 'std::string', is_const=False) return def register_Ns3Empty_methods(root_module, cls): ## empty.h (module 'core'): ns3::empty::empty() [constructor] cls.add_constructor([]) ## empty.h (module 'core'): ns3::empty::empty(ns3::empty const & arg0) [copy constructor] cls.add_constructor([param('ns3::empty const &', 'arg0')]) return def register_Ns3Int64x64_t_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') cls.add_inplace_numeric_operator('+=', param('ns3::int64x64_t const &', u'right')) cls.add_binary_numeric_operator('*', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) cls.add_binary_numeric_operator('+', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) cls.add_binary_numeric_operator('-', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) cls.add_unary_numeric_operator('-') cls.add_binary_numeric_operator('/', root_module['ns3::int64x64_t'], root_module['ns3::int64x64_t'], param('ns3::int64x64_t const &', u'right')) cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('>') cls.add_inplace_numeric_operator('*=', param('ns3::int64x64_t const &', u'right')) cls.add_inplace_numeric_operator('-=', param('ns3::int64x64_t const &', u'right')) cls.add_inplace_numeric_operator('/=', param('ns3::int64x64_t const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t() [constructor] cls.add_constructor([]) ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(double v) [constructor] cls.add_constructor([param('double', 'v')]) ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long double v) [constructor] cls.add_constructor([param('long double', 'v')]) ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(int v) [constructor] cls.add_constructor([param('int', 'v')]) ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long int v) [constructor] cls.add_constructor([param('long int', 'v')]) ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long long int v) [constructor] cls.add_constructor([param('long long int', 'v')]) ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(unsigned int v) [constructor] cls.add_constructor([param('unsigned int', 'v')]) ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long unsigned int v) [constructor] cls.add_constructor([param('long unsigned int', 'v')]) ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(long long unsigned int v) [constructor] cls.add_constructor([param('long long unsigned int', 'v')]) ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(int64_t hi, uint64_t lo) [constructor] cls.add_constructor([param('int64_t', 'hi'), param('uint64_t', 'lo')]) ## int64x64-double.h (module 'core'): ns3::int64x64_t::int64x64_t(ns3::int64x64_t const & o) [copy constructor] cls.add_constructor([param('ns3::int64x64_t const &', 'o')]) ## int64x64-double.h (module 'core'): double ns3::int64x64_t::GetDouble() const [member function] cls.add_method('GetDouble', 'double', [], is_const=True) ## int64x64-double.h (module 'core'): int64_t ns3::int64x64_t::GetHigh() const [member function] cls.add_method('GetHigh', 'int64_t', [], is_const=True) ## int64x64-double.h (module 'core'): uint64_t ns3::int64x64_t::GetLow() const [member function] cls.add_method('GetLow', 'uint64_t', [], is_const=True) ## int64x64-double.h (module 'core'): static ns3::int64x64_t ns3::int64x64_t::Invert(uint64_t v) [member function] cls.add_method('Invert', 'ns3::int64x64_t', [param('uint64_t', 'v')], is_static=True) ## int64x64-double.h (module 'core'): void ns3::int64x64_t::MulByInvert(ns3::int64x64_t const & o) [member function] cls.add_method('MulByInvert', 'void', [param('ns3::int64x64_t const &', 'o')]) ## int64x64-double.h (module 'core'): ns3::int64x64_t::implementation [variable] cls.add_static_attribute('implementation', 'ns3::int64x64_t::impl_type const', is_const=True) return def register_Ns3AodvHelper_methods(root_module, cls): ## aodv-helper.h (module 'aodv'): ns3::AodvHelper::AodvHelper(ns3::AodvHelper const & arg0) [copy constructor] cls.add_constructor([param('ns3::AodvHelper const &', 'arg0')]) ## aodv-helper.h (module 'aodv'): ns3::AodvHelper::AodvHelper() [constructor] cls.add_constructor([]) ## aodv-helper.h (module 'aodv'): int64_t ns3::AodvHelper::AssignStreams(ns3::NodeContainer c, int64_t stream) [member function] cls.add_method('AssignStreams', 'int64_t', [param('ns3::NodeContainer', 'c'), param('int64_t', 'stream')]) ## aodv-helper.h (module 'aodv'): ns3::AodvHelper * ns3::AodvHelper::Copy() const [member function] cls.add_method('Copy', 'ns3::AodvHelper *', [], is_const=True, is_virtual=True) ## aodv-helper.h (module 'aodv'): ns3::Ptr<ns3::Ipv4RoutingProtocol> ns3::AodvHelper::Create(ns3::Ptr<ns3::Node> node) const [member function] cls.add_method('Create', 'ns3::Ptr< ns3::Ipv4RoutingProtocol >', [param('ns3::Ptr< ns3::Node >', 'node')], is_const=True, is_virtual=True) ## aodv-helper.h (module 'aodv'): void ns3::AodvHelper::Set(std::string name, ns3::AttributeValue const & value) [member function] cls.add_method('Set', 'void', [param('std::string', 'name'), param('ns3::AttributeValue const &', 'value')]) return def register_Ns3Chunk_methods(root_module, cls): ## chunk.h (module 'network'): ns3::Chunk::Chunk() [constructor] cls.add_constructor([]) ## chunk.h (module 'network'): ns3::Chunk::Chunk(ns3::Chunk const & arg0) [copy constructor] cls.add_constructor([param('ns3::Chunk const &', 'arg0')]) ## chunk.h (module 'network'): uint32_t ns3::Chunk::Deserialize(ns3::Buffer::Iterator start) [member function] cls.add_method('Deserialize', 'uint32_t', [param('ns3::Buffer::Iterator', 'start')], is_pure_virtual=True, is_virtual=True) ## chunk.h (module 'network'): static ns3::TypeId ns3::Chunk::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## chunk.h (module 'network'): void ns3::Chunk::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_pure_virtual=True, is_const=True, is_virtual=True) return def register_Ns3Header_methods(root_module, cls): cls.add_output_stream_operator() ## header.h (module 'network'): ns3::Header::Header() [constructor] cls.add_constructor([]) ## header.h (module 'network'): ns3::Header::Header(ns3::Header const & arg0) [copy constructor] cls.add_constructor([param('ns3::Header const &', 'arg0')]) ## header.h (module 'network'): uint32_t ns3::Header::Deserialize(ns3::Buffer::Iterator start) [member function] cls.add_method('Deserialize', 'uint32_t', [param('ns3::Buffer::Iterator', 'start')], is_pure_virtual=True, is_virtual=True) ## header.h (module 'network'): uint32_t ns3::Header::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## header.h (module 'network'): static ns3::TypeId ns3::Header::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## header.h (module 'network'): void ns3::Header::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_pure_virtual=True, is_const=True, is_virtual=True) ## header.h (module 'network'): void ns3::Header::Serialize(ns3::Buffer::Iterator start) const [member function] cls.add_method('Serialize', 'void', [param('ns3::Buffer::Iterator', 'start')], is_pure_virtual=True, is_const=True, is_virtual=True) return def register_Ns3Ipv4Header_methods(root_module, cls): ## ipv4-header.h (module 'internet'): ns3::Ipv4Header::Ipv4Header(ns3::Ipv4Header const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4Header const &', 'arg0')]) ## ipv4-header.h (module 'internet'): ns3::Ipv4Header::Ipv4Header() [constructor] cls.add_constructor([]) ## ipv4-header.h (module 'internet'): uint32_t ns3::Ipv4Header::Deserialize(ns3::Buffer::Iterator start) [member function] cls.add_method('Deserialize', 'uint32_t', [param('ns3::Buffer::Iterator', 'start')], is_virtual=True) ## ipv4-header.h (module 'internet'): std::string ns3::Ipv4Header::DscpTypeToString(ns3::Ipv4Header::DscpType dscp) const [member function] cls.add_method('DscpTypeToString', 'std::string', [param('ns3::Ipv4Header::DscpType', 'dscp')], is_const=True) ## ipv4-header.h (module 'internet'): std::string ns3::Ipv4Header::EcnTypeToString(ns3::Ipv4Header::EcnType ecn) const [member function] cls.add_method('EcnTypeToString', 'std::string', [param('ns3::Ipv4Header::EcnType', 'ecn')], is_const=True) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::EnableChecksum() [member function] cls.add_method('EnableChecksum', 'void', []) ## ipv4-header.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4Header::GetDestination() const [member function] cls.add_method('GetDestination', 'ns3::Ipv4Address', [], is_const=True) ## ipv4-header.h (module 'internet'): ns3::Ipv4Header::DscpType ns3::Ipv4Header::GetDscp() const [member function] cls.add_method('GetDscp', 'ns3::Ipv4Header::DscpType', [], is_const=True) ## ipv4-header.h (module 'internet'): ns3::Ipv4Header::EcnType ns3::Ipv4Header::GetEcn() const [member function] cls.add_method('GetEcn', 'ns3::Ipv4Header::EcnType', [], is_const=True) ## ipv4-header.h (module 'internet'): uint16_t ns3::Ipv4Header::GetFragmentOffset() const [member function] cls.add_method('GetFragmentOffset', 'uint16_t', [], is_const=True) ## ipv4-header.h (module 'internet'): uint16_t ns3::Ipv4Header::GetIdentification() const [member function] cls.add_method('GetIdentification', 'uint16_t', [], is_const=True) ## ipv4-header.h (module 'internet'): ns3::TypeId ns3::Ipv4Header::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## ipv4-header.h (module 'internet'): uint16_t ns3::Ipv4Header::GetPayloadSize() const [member function] cls.add_method('GetPayloadSize', 'uint16_t', [], is_const=True) ## ipv4-header.h (module 'internet'): uint8_t ns3::Ipv4Header::GetProtocol() const [member function] cls.add_method('GetProtocol', 'uint8_t', [], is_const=True) ## ipv4-header.h (module 'internet'): uint32_t ns3::Ipv4Header::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## ipv4-header.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4Header::GetSource() const [member function] cls.add_method('GetSource', 'ns3::Ipv4Address', [], is_const=True) ## ipv4-header.h (module 'internet'): uint8_t ns3::Ipv4Header::GetTos() const [member function] cls.add_method('GetTos', 'uint8_t', [], is_const=True) ## ipv4-header.h (module 'internet'): uint8_t ns3::Ipv4Header::GetTtl() const [member function] cls.add_method('GetTtl', 'uint8_t', [], is_const=True) ## ipv4-header.h (module 'internet'): static ns3::TypeId ns3::Ipv4Header::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## ipv4-header.h (module 'internet'): bool ns3::Ipv4Header::IsChecksumOk() const [member function] cls.add_method('IsChecksumOk', 'bool', [], is_const=True) ## ipv4-header.h (module 'internet'): bool ns3::Ipv4Header::IsDontFragment() const [member function] cls.add_method('IsDontFragment', 'bool', [], is_const=True) ## ipv4-header.h (module 'internet'): bool ns3::Ipv4Header::IsLastFragment() const [member function] cls.add_method('IsLastFragment', 'bool', [], is_const=True) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::Serialize(ns3::Buffer::Iterator start) const [member function] cls.add_method('Serialize', 'void', [param('ns3::Buffer::Iterator', 'start')], is_const=True, is_virtual=True) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetDestination(ns3::Ipv4Address destination) [member function] cls.add_method('SetDestination', 'void', [param('ns3::Ipv4Address', 'destination')]) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetDontFragment() [member function] cls.add_method('SetDontFragment', 'void', []) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetDscp(ns3::Ipv4Header::DscpType dscp) [member function] cls.add_method('SetDscp', 'void', [param('ns3::Ipv4Header::DscpType', 'dscp')]) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetEcn(ns3::Ipv4Header::EcnType ecn) [member function] cls.add_method('SetEcn', 'void', [param('ns3::Ipv4Header::EcnType', 'ecn')]) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetFragmentOffset(uint16_t offsetBytes) [member function] cls.add_method('SetFragmentOffset', 'void', [param('uint16_t', 'offsetBytes')]) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetIdentification(uint16_t identification) [member function] cls.add_method('SetIdentification', 'void', [param('uint16_t', 'identification')]) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetLastFragment() [member function] cls.add_method('SetLastFragment', 'void', []) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetMayFragment() [member function] cls.add_method('SetMayFragment', 'void', []) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetMoreFragments() [member function] cls.add_method('SetMoreFragments', 'void', []) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetPayloadSize(uint16_t size) [member function] cls.add_method('SetPayloadSize', 'void', [param('uint16_t', 'size')]) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetProtocol(uint8_t num) [member function] cls.add_method('SetProtocol', 'void', [param('uint8_t', 'num')]) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetSource(ns3::Ipv4Address source) [member function] cls.add_method('SetSource', 'void', [param('ns3::Ipv4Address', 'source')]) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetTos(uint8_t tos) [member function] cls.add_method('SetTos', 'void', [param('uint8_t', 'tos')]) ## ipv4-header.h (module 'internet'): void ns3::Ipv4Header::SetTtl(uint8_t ttl) [member function] cls.add_method('SetTtl', 'void', [param('uint8_t', 'ttl')]) return def register_Ns3Object_methods(root_module, cls): ## object.h (module 'core'): ns3::Object::Object() [constructor] cls.add_constructor([]) ## object.h (module 'core'): void ns3::Object::AggregateObject(ns3::Ptr<ns3::Object> other) [member function] cls.add_method('AggregateObject', 'void', [param('ns3::Ptr< ns3::Object >', 'other')]) ## object.h (module 'core'): void ns3::Object::Dispose() [member function] cls.add_method('Dispose', 'void', []) ## object.h (module 'core'): ns3::Object::AggregateIterator ns3::Object::GetAggregateIterator() const [member function] cls.add_method('GetAggregateIterator', 'ns3::Object::AggregateIterator', [], is_const=True) ## object.h (module 'core'): ns3::TypeId ns3::Object::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## object.h (module 'core'): static ns3::TypeId ns3::Object::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## object.h (module 'core'): void ns3::Object::Initialize() [member function] cls.add_method('Initialize', 'void', []) ## object.h (module 'core'): bool ns3::Object::IsInitialized() const [member function] cls.add_method('IsInitialized', 'bool', [], is_const=True) ## object.h (module 'core'): ns3::Object::Object(ns3::Object const & o) [copy constructor] cls.add_constructor([param('ns3::Object const &', 'o')], visibility='protected') ## object.h (module 'core'): void ns3::Object::DoDispose() [member function] cls.add_method('DoDispose', 'void', [], visibility='protected', is_virtual=True) ## object.h (module 'core'): void ns3::Object::DoInitialize() [member function] cls.add_method('DoInitialize', 'void', [], visibility='protected', is_virtual=True) ## object.h (module 'core'): void ns3::Object::NotifyNewAggregate() [member function] cls.add_method('NotifyNewAggregate', 'void', [], visibility='protected', is_virtual=True) return def register_Ns3ObjectAggregateIterator_methods(root_module, cls): ## object.h (module 'core'): ns3::Object::AggregateIterator::AggregateIterator(ns3::Object::AggregateIterator const & arg0) [copy constructor] cls.add_constructor([param('ns3::Object::AggregateIterator const &', 'arg0')]) ## object.h (module 'core'): ns3::Object::AggregateIterator::AggregateIterator() [constructor] cls.add_constructor([]) ## object.h (module 'core'): bool ns3::Object::AggregateIterator::HasNext() const [member function] cls.add_method('HasNext', 'bool', [], is_const=True) ## object.h (module 'core'): ns3::Ptr<ns3::Object const> ns3::Object::AggregateIterator::Next() [member function] cls.add_method('Next', 'ns3::Ptr< ns3::Object const >', []) return def register_Ns3RandomVariableStream_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::RandomVariableStream::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::RandomVariableStream::RandomVariableStream() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): void ns3::RandomVariableStream::SetStream(int64_t stream) [member function] cls.add_method('SetStream', 'void', [param('int64_t', 'stream')]) ## random-variable-stream.h (module 'core'): int64_t ns3::RandomVariableStream::GetStream() const [member function] cls.add_method('GetStream', 'int64_t', [], is_const=True) ## random-variable-stream.h (module 'core'): void ns3::RandomVariableStream::SetAntithetic(bool isAntithetic) [member function] cls.add_method('SetAntithetic', 'void', [param('bool', 'isAntithetic')]) ## random-variable-stream.h (module 'core'): bool ns3::RandomVariableStream::IsAntithetic() const [member function] cls.add_method('IsAntithetic', 'bool', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::RandomVariableStream::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_pure_virtual=True, is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::RandomVariableStream::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_pure_virtual=True, is_virtual=True) ## random-variable-stream.h (module 'core'): ns3::RngStream * ns3::RandomVariableStream::Peek() const [member function] cls.add_method('Peek', 'ns3::RngStream *', [], is_const=True, visibility='protected') return def register_Ns3SequentialRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::SequentialRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::SequentialRandomVariable::SequentialRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): double ns3::SequentialRandomVariable::GetMin() const [member function] cls.add_method('GetMin', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::SequentialRandomVariable::GetMax() const [member function] cls.add_method('GetMax', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): ns3::Ptr<ns3::RandomVariableStream> ns3::SequentialRandomVariable::GetIncrement() const [member function] cls.add_method('GetIncrement', 'ns3::Ptr< ns3::RandomVariableStream >', [], is_const=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::SequentialRandomVariable::GetConsecutive() const [member function] cls.add_method('GetConsecutive', 'uint32_t', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::SequentialRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::SequentialRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3SimpleRefCount__Ns3AttributeAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeAccessor__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >::SimpleRefCount(ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> > const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter< ns3::AttributeAccessor > > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::AttributeAccessor, ns3::empty, ns3::DefaultDeleter<ns3::AttributeAccessor> >::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3SimpleRefCount__Ns3AttributeChecker_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeChecker__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >::SimpleRefCount(ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> > const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter< ns3::AttributeChecker > > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::AttributeChecker, ns3::empty, ns3::DefaultDeleter<ns3::AttributeChecker> >::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3SimpleRefCount__Ns3AttributeValue_Ns3Empty_Ns3DefaultDeleter__lt__ns3AttributeValue__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >::SimpleRefCount(ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> > const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter< ns3::AttributeValue > > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::AttributeValue, ns3::empty, ns3::DefaultDeleter<ns3::AttributeValue> >::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3SimpleRefCount__Ns3CallbackImplBase_Ns3Empty_Ns3DefaultDeleter__lt__ns3CallbackImplBase__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >::SimpleRefCount(ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> > const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter< ns3::CallbackImplBase > > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::CallbackImplBase, ns3::empty, ns3::DefaultDeleter<ns3::CallbackImplBase> >::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3SimpleRefCount__Ns3EventImpl_Ns3Empty_Ns3DefaultDeleter__lt__ns3EventImpl__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >::SimpleRefCount(ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> > const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::EventImpl, ns3::empty, ns3::DefaultDeleter< ns3::EventImpl > > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::EventImpl, ns3::empty, ns3::DefaultDeleter<ns3::EventImpl> >::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3SimpleRefCount__Ns3HashImplementation_Ns3Empty_Ns3DefaultDeleter__lt__ns3HashImplementation__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter<ns3::Hash::Implementation> >::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter<ns3::Hash::Implementation> >::SimpleRefCount(ns3::SimpleRefCount<ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter<ns3::Hash::Implementation> > const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter< ns3::Hash::Implementation > > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::Hash::Implementation, ns3::empty, ns3::DefaultDeleter<ns3::Hash::Implementation> >::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3SimpleRefCount__Ns3Ipv4MulticastRoute_Ns3Empty_Ns3DefaultDeleter__lt__ns3Ipv4MulticastRoute__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Ipv4MulticastRoute, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4MulticastRoute> >::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Ipv4MulticastRoute, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4MulticastRoute> >::SimpleRefCount(ns3::SimpleRefCount<ns3::Ipv4MulticastRoute, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4MulticastRoute> > const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::Ipv4MulticastRoute, ns3::empty, ns3::DefaultDeleter< ns3::Ipv4MulticastRoute > > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::Ipv4MulticastRoute, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4MulticastRoute> >::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3SimpleRefCount__Ns3Ipv4Route_Ns3Empty_Ns3DefaultDeleter__lt__ns3Ipv4Route__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Ipv4Route, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4Route> >::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Ipv4Route, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4Route> >::SimpleRefCount(ns3::SimpleRefCount<ns3::Ipv4Route, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4Route> > const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::Ipv4Route, ns3::empty, ns3::DefaultDeleter< ns3::Ipv4Route > > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::Ipv4Route, ns3::empty, ns3::DefaultDeleter<ns3::Ipv4Route> >::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3SimpleRefCount__Ns3NixVector_Ns3Empty_Ns3DefaultDeleter__lt__ns3NixVector__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >::SimpleRefCount(ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> > const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::NixVector, ns3::empty, ns3::DefaultDeleter< ns3::NixVector > > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::NixVector, ns3::empty, ns3::DefaultDeleter<ns3::NixVector> >::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3SimpleRefCount__Ns3OutputStreamWrapper_Ns3Empty_Ns3DefaultDeleter__lt__ns3OutputStreamWrapper__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >::SimpleRefCount(ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> > const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter< ns3::OutputStreamWrapper > > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::OutputStreamWrapper, ns3::empty, ns3::DefaultDeleter<ns3::OutputStreamWrapper> >::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3SimpleRefCount__Ns3Packet_Ns3Empty_Ns3DefaultDeleter__lt__ns3Packet__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >::SimpleRefCount(ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> > const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::Packet, ns3::empty, ns3::DefaultDeleter< ns3::Packet > > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::Packet, ns3::empty, ns3::DefaultDeleter<ns3::Packet> >::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3SimpleRefCount__Ns3TraceSourceAccessor_Ns3Empty_Ns3DefaultDeleter__lt__ns3TraceSourceAccessor__gt___methods(root_module, cls): ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >::SimpleRefCount() [constructor] cls.add_constructor([]) ## simple-ref-count.h (module 'core'): ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >::SimpleRefCount(ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> > const & o) [copy constructor] cls.add_constructor([param('ns3::SimpleRefCount< ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter< ns3::TraceSourceAccessor > > const &', 'o')]) ## simple-ref-count.h (module 'core'): static void ns3::SimpleRefCount<ns3::TraceSourceAccessor, ns3::empty, ns3::DefaultDeleter<ns3::TraceSourceAccessor> >::Cleanup() [member function] cls.add_method('Cleanup', 'void', [], is_static=True) return def register_Ns3Socket_methods(root_module, cls): ## socket.h (module 'network'): ns3::Socket::Socket(ns3::Socket const & arg0) [copy constructor] cls.add_constructor([param('ns3::Socket const &', 'arg0')]) ## socket.h (module 'network'): ns3::Socket::Socket() [constructor] cls.add_constructor([]) ## socket.h (module 'network'): int ns3::Socket::Bind(ns3::Address const & address) [member function] cls.add_method('Bind', 'int', [param('ns3::Address const &', 'address')], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): int ns3::Socket::Bind() [member function] cls.add_method('Bind', 'int', [], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): int ns3::Socket::Bind6() [member function] cls.add_method('Bind6', 'int', [], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): void ns3::Socket::BindToNetDevice(ns3::Ptr<ns3::NetDevice> netdevice) [member function] cls.add_method('BindToNetDevice', 'void', [param('ns3::Ptr< ns3::NetDevice >', 'netdevice')], is_virtual=True) ## socket.h (module 'network'): int ns3::Socket::Close() [member function] cls.add_method('Close', 'int', [], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): int ns3::Socket::Connect(ns3::Address const & address) [member function] cls.add_method('Connect', 'int', [param('ns3::Address const &', 'address')], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): static ns3::Ptr<ns3::Socket> ns3::Socket::CreateSocket(ns3::Ptr<ns3::Node> node, ns3::TypeId tid) [member function] cls.add_method('CreateSocket', 'ns3::Ptr< ns3::Socket >', [param('ns3::Ptr< ns3::Node >', 'node'), param('ns3::TypeId', 'tid')], is_static=True) ## socket.h (module 'network'): bool ns3::Socket::GetAllowBroadcast() const [member function] cls.add_method('GetAllowBroadcast', 'bool', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## socket.h (module 'network'): ns3::Ptr<ns3::NetDevice> ns3::Socket::GetBoundNetDevice() [member function] cls.add_method('GetBoundNetDevice', 'ns3::Ptr< ns3::NetDevice >', []) ## socket.h (module 'network'): ns3::Socket::SocketErrno ns3::Socket::GetErrno() const [member function] cls.add_method('GetErrno', 'ns3::Socket::SocketErrno', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## socket.h (module 'network'): uint8_t ns3::Socket::GetIpTos() const [member function] cls.add_method('GetIpTos', 'uint8_t', [], is_const=True) ## socket.h (module 'network'): uint8_t ns3::Socket::GetIpTtl() const [member function] cls.add_method('GetIpTtl', 'uint8_t', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): uint8_t ns3::Socket::GetIpv6HopLimit() const [member function] cls.add_method('GetIpv6HopLimit', 'uint8_t', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): uint8_t ns3::Socket::GetIpv6Tclass() const [member function] cls.add_method('GetIpv6Tclass', 'uint8_t', [], is_const=True) ## socket.h (module 'network'): ns3::Ptr<ns3::Node> ns3::Socket::GetNode() const [member function] cls.add_method('GetNode', 'ns3::Ptr< ns3::Node >', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## socket.h (module 'network'): int ns3::Socket::GetPeerName(ns3::Address & address) const [member function] cls.add_method('GetPeerName', 'int', [param('ns3::Address &', 'address')], is_pure_virtual=True, is_const=True, is_virtual=True) ## socket.h (module 'network'): uint8_t ns3::Socket::GetPriority() const [member function] cls.add_method('GetPriority', 'uint8_t', [], is_const=True) ## socket.h (module 'network'): uint32_t ns3::Socket::GetRxAvailable() const [member function] cls.add_method('GetRxAvailable', 'uint32_t', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## socket.h (module 'network'): int ns3::Socket::GetSockName(ns3::Address & address) const [member function] cls.add_method('GetSockName', 'int', [param('ns3::Address &', 'address')], is_pure_virtual=True, is_const=True, is_virtual=True) ## socket.h (module 'network'): ns3::Socket::SocketType ns3::Socket::GetSocketType() const [member function] cls.add_method('GetSocketType', 'ns3::Socket::SocketType', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## socket.h (module 'network'): uint32_t ns3::Socket::GetTxAvailable() const [member function] cls.add_method('GetTxAvailable', 'uint32_t', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## socket.h (module 'network'): static ns3::TypeId ns3::Socket::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## socket.h (module 'network'): static uint8_t ns3::Socket::IpTos2Priority(uint8_t ipTos) [member function] cls.add_method('IpTos2Priority', 'uint8_t', [param('uint8_t', 'ipTos')], is_static=True) ## socket.h (module 'network'): void ns3::Socket::Ipv6JoinGroup(ns3::Ipv6Address address, ns3::Socket::Ipv6MulticastFilterMode filterMode, std::vector<ns3::Ipv6Address,std::allocator<ns3::Ipv6Address> > sourceAddresses) [member function] cls.add_method('Ipv6JoinGroup', 'void', [param('ns3::Ipv6Address', 'address'), param('ns3::Socket::Ipv6MulticastFilterMode', 'filterMode'), param('std::vector< ns3::Ipv6Address >', 'sourceAddresses')], is_virtual=True) ## socket.h (module 'network'): void ns3::Socket::Ipv6JoinGroup(ns3::Ipv6Address address) [member function] cls.add_method('Ipv6JoinGroup', 'void', [param('ns3::Ipv6Address', 'address')], is_virtual=True) ## socket.h (module 'network'): void ns3::Socket::Ipv6LeaveGroup() [member function] cls.add_method('Ipv6LeaveGroup', 'void', [], is_virtual=True) ## socket.h (module 'network'): bool ns3::Socket::IsIpRecvTos() const [member function] cls.add_method('IsIpRecvTos', 'bool', [], is_const=True) ## socket.h (module 'network'): bool ns3::Socket::IsIpRecvTtl() const [member function] cls.add_method('IsIpRecvTtl', 'bool', [], is_const=True) ## socket.h (module 'network'): bool ns3::Socket::IsIpv6RecvHopLimit() const [member function] cls.add_method('IsIpv6RecvHopLimit', 'bool', [], is_const=True) ## socket.h (module 'network'): bool ns3::Socket::IsIpv6RecvTclass() const [member function] cls.add_method('IsIpv6RecvTclass', 'bool', [], is_const=True) ## socket.h (module 'network'): bool ns3::Socket::IsRecvPktInfo() const [member function] cls.add_method('IsRecvPktInfo', 'bool', [], is_const=True) ## socket.h (module 'network'): int ns3::Socket::Listen() [member function] cls.add_method('Listen', 'int', [], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): ns3::Ptr<ns3::Packet> ns3::Socket::Recv(uint32_t maxSize, uint32_t flags) [member function] cls.add_method('Recv', 'ns3::Ptr< ns3::Packet >', [param('uint32_t', 'maxSize'), param('uint32_t', 'flags')], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): ns3::Ptr<ns3::Packet> ns3::Socket::Recv() [member function] cls.add_method('Recv', 'ns3::Ptr< ns3::Packet >', []) ## socket.h (module 'network'): int ns3::Socket::Recv(uint8_t * buf, uint32_t size, uint32_t flags) [member function] cls.add_method('Recv', 'int', [param('uint8_t *', 'buf'), param('uint32_t', 'size'), param('uint32_t', 'flags')]) ## socket.h (module 'network'): ns3::Ptr<ns3::Packet> ns3::Socket::RecvFrom(uint32_t maxSize, uint32_t flags, ns3::Address & fromAddress) [member function] cls.add_method('RecvFrom', 'ns3::Ptr< ns3::Packet >', [param('uint32_t', 'maxSize'), param('uint32_t', 'flags'), param('ns3::Address &', 'fromAddress')], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): ns3::Ptr<ns3::Packet> ns3::Socket::RecvFrom(ns3::Address & fromAddress) [member function] cls.add_method('RecvFrom', 'ns3::Ptr< ns3::Packet >', [param('ns3::Address &', 'fromAddress')]) ## socket.h (module 'network'): int ns3::Socket::RecvFrom(uint8_t * buf, uint32_t size, uint32_t flags, ns3::Address & fromAddress) [member function] cls.add_method('RecvFrom', 'int', [param('uint8_t *', 'buf'), param('uint32_t', 'size'), param('uint32_t', 'flags'), param('ns3::Address &', 'fromAddress')]) ## socket.h (module 'network'): int ns3::Socket::Send(ns3::Ptr<ns3::Packet> p, uint32_t flags) [member function] cls.add_method('Send', 'int', [param('ns3::Ptr< ns3::Packet >', 'p'), param('uint32_t', 'flags')], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): int ns3::Socket::Send(ns3::Ptr<ns3::Packet> p) [member function] cls.add_method('Send', 'int', [param('ns3::Ptr< ns3::Packet >', 'p')]) ## socket.h (module 'network'): int ns3::Socket::Send(uint8_t const * buf, uint32_t size, uint32_t flags) [member function] cls.add_method('Send', 'int', [param('uint8_t const *', 'buf'), param('uint32_t', 'size'), param('uint32_t', 'flags')]) ## socket.h (module 'network'): int ns3::Socket::SendTo(ns3::Ptr<ns3::Packet> p, uint32_t flags, ns3::Address const & toAddress) [member function] cls.add_method('SendTo', 'int', [param('ns3::Ptr< ns3::Packet >', 'p'), param('uint32_t', 'flags'), param('ns3::Address const &', 'toAddress')], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): int ns3::Socket::SendTo(uint8_t const * buf, uint32_t size, uint32_t flags, ns3::Address const & address) [member function] cls.add_method('SendTo', 'int', [param('uint8_t const *', 'buf'), param('uint32_t', 'size'), param('uint32_t', 'flags'), param('ns3::Address const &', 'address')]) ## socket.h (module 'network'): void ns3::Socket::SetAcceptCallback(ns3::Callback<bool, ns3::Ptr<ns3::Socket>, ns3::Address const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> connectionRequest, ns3::Callback<void, ns3::Ptr<ns3::Socket>, ns3::Address const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> newConnectionCreated) [member function] cls.add_method('SetAcceptCallback', 'void', [param('ns3::Callback< bool, ns3::Ptr< ns3::Socket >, ns3::Address const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'connectionRequest'), param('ns3::Callback< void, ns3::Ptr< ns3::Socket >, ns3::Address const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'newConnectionCreated')]) ## socket.h (module 'network'): bool ns3::Socket::SetAllowBroadcast(bool allowBroadcast) [member function] cls.add_method('SetAllowBroadcast', 'bool', [param('bool', 'allowBroadcast')], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): void ns3::Socket::SetCloseCallbacks(ns3::Callback<void, ns3::Ptr<ns3::Socket>, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> normalClose, ns3::Callback<void, ns3::Ptr<ns3::Socket>, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> errorClose) [member function] cls.add_method('SetCloseCallbacks', 'void', [param('ns3::Callback< void, ns3::Ptr< ns3::Socket >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'normalClose'), param('ns3::Callback< void, ns3::Ptr< ns3::Socket >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'errorClose')]) ## socket.h (module 'network'): void ns3::Socket::SetConnectCallback(ns3::Callback<void, ns3::Ptr<ns3::Socket>, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> connectionSucceeded, ns3::Callback<void, ns3::Ptr<ns3::Socket>, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> connectionFailed) [member function] cls.add_method('SetConnectCallback', 'void', [param('ns3::Callback< void, ns3::Ptr< ns3::Socket >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'connectionSucceeded'), param('ns3::Callback< void, ns3::Ptr< ns3::Socket >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'connectionFailed')]) ## socket.h (module 'network'): void ns3::Socket::SetDataSentCallback(ns3::Callback<void, ns3::Ptr<ns3::Socket>, unsigned int, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> dataSent) [member function] cls.add_method('SetDataSentCallback', 'void', [param('ns3::Callback< void, ns3::Ptr< ns3::Socket >, unsigned int, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'dataSent')]) ## socket.h (module 'network'): void ns3::Socket::SetIpRecvTos(bool ipv4RecvTos) [member function] cls.add_method('SetIpRecvTos', 'void', [param('bool', 'ipv4RecvTos')]) ## socket.h (module 'network'): void ns3::Socket::SetIpRecvTtl(bool ipv4RecvTtl) [member function] cls.add_method('SetIpRecvTtl', 'void', [param('bool', 'ipv4RecvTtl')]) ## socket.h (module 'network'): void ns3::Socket::SetIpTos(uint8_t ipTos) [member function] cls.add_method('SetIpTos', 'void', [param('uint8_t', 'ipTos')]) ## socket.h (module 'network'): void ns3::Socket::SetIpTtl(uint8_t ipTtl) [member function] cls.add_method('SetIpTtl', 'void', [param('uint8_t', 'ipTtl')], is_virtual=True) ## socket.h (module 'network'): void ns3::Socket::SetIpv6HopLimit(uint8_t ipHopLimit) [member function] cls.add_method('SetIpv6HopLimit', 'void', [param('uint8_t', 'ipHopLimit')], is_virtual=True) ## socket.h (module 'network'): void ns3::Socket::SetIpv6RecvHopLimit(bool ipv6RecvHopLimit) [member function] cls.add_method('SetIpv6RecvHopLimit', 'void', [param('bool', 'ipv6RecvHopLimit')]) ## socket.h (module 'network'): void ns3::Socket::SetIpv6RecvTclass(bool ipv6RecvTclass) [member function] cls.add_method('SetIpv6RecvTclass', 'void', [param('bool', 'ipv6RecvTclass')]) ## socket.h (module 'network'): void ns3::Socket::SetIpv6Tclass(int ipTclass) [member function] cls.add_method('SetIpv6Tclass', 'void', [param('int', 'ipTclass')]) ## socket.h (module 'network'): void ns3::Socket::SetPriority(uint8_t priority) [member function] cls.add_method('SetPriority', 'void', [param('uint8_t', 'priority')]) ## socket.h (module 'network'): void ns3::Socket::SetRecvCallback(ns3::Callback<void, ns3::Ptr<ns3::Socket>, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> arg0) [member function] cls.add_method('SetRecvCallback', 'void', [param('ns3::Callback< void, ns3::Ptr< ns3::Socket >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'arg0')]) ## socket.h (module 'network'): void ns3::Socket::SetRecvPktInfo(bool flag) [member function] cls.add_method('SetRecvPktInfo', 'void', [param('bool', 'flag')]) ## socket.h (module 'network'): void ns3::Socket::SetSendCallback(ns3::Callback<void, ns3::Ptr<ns3::Socket>, unsigned int, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> sendCb) [member function] cls.add_method('SetSendCallback', 'void', [param('ns3::Callback< void, ns3::Ptr< ns3::Socket >, unsigned int, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'sendCb')]) ## socket.h (module 'network'): int ns3::Socket::ShutdownRecv() [member function] cls.add_method('ShutdownRecv', 'int', [], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): int ns3::Socket::ShutdownSend() [member function] cls.add_method('ShutdownSend', 'int', [], is_pure_virtual=True, is_virtual=True) ## socket.h (module 'network'): void ns3::Socket::DoDispose() [member function] cls.add_method('DoDispose', 'void', [], visibility='protected', is_virtual=True) ## socket.h (module 'network'): bool ns3::Socket::IsManualIpTtl() const [member function] cls.add_method('IsManualIpTtl', 'bool', [], is_const=True, visibility='protected') ## socket.h (module 'network'): bool ns3::Socket::IsManualIpv6HopLimit() const [member function] cls.add_method('IsManualIpv6HopLimit', 'bool', [], is_const=True, visibility='protected') ## socket.h (module 'network'): bool ns3::Socket::IsManualIpv6Tclass() const [member function] cls.add_method('IsManualIpv6Tclass', 'bool', [], is_const=True, visibility='protected') ## socket.h (module 'network'): void ns3::Socket::NotifyConnectionFailed() [member function] cls.add_method('NotifyConnectionFailed', 'void', [], visibility='protected') ## socket.h (module 'network'): bool ns3::Socket::NotifyConnectionRequest(ns3::Address const & from) [member function] cls.add_method('NotifyConnectionRequest', 'bool', [param('ns3::Address const &', 'from')], visibility='protected') ## socket.h (module 'network'): void ns3::Socket::NotifyConnectionSucceeded() [member function] cls.add_method('NotifyConnectionSucceeded', 'void', [], visibility='protected') ## socket.h (module 'network'): void ns3::Socket::NotifyDataRecv() [member function] cls.add_method('NotifyDataRecv', 'void', [], visibility='protected') ## socket.h (module 'network'): void ns3::Socket::NotifyDataSent(uint32_t size) [member function] cls.add_method('NotifyDataSent', 'void', [param('uint32_t', 'size')], visibility='protected') ## socket.h (module 'network'): void ns3::Socket::NotifyErrorClose() [member function] cls.add_method('NotifyErrorClose', 'void', [], visibility='protected') ## socket.h (module 'network'): void ns3::Socket::NotifyNewConnectionCreated(ns3::Ptr<ns3::Socket> socket, ns3::Address const & from) [member function] cls.add_method('NotifyNewConnectionCreated', 'void', [param('ns3::Ptr< ns3::Socket >', 'socket'), param('ns3::Address const &', 'from')], visibility='protected') ## socket.h (module 'network'): void ns3::Socket::NotifyNormalClose() [member function] cls.add_method('NotifyNormalClose', 'void', [], visibility='protected') ## socket.h (module 'network'): void ns3::Socket::NotifySend(uint32_t spaceAvailable) [member function] cls.add_method('NotifySend', 'void', [param('uint32_t', 'spaceAvailable')], visibility='protected') return def register_Ns3SocketIpTosTag_methods(root_module, cls): ## socket.h (module 'network'): ns3::SocketIpTosTag::SocketIpTosTag(ns3::SocketIpTosTag const & arg0) [copy constructor] cls.add_constructor([param('ns3::SocketIpTosTag const &', 'arg0')]) ## socket.h (module 'network'): ns3::SocketIpTosTag::SocketIpTosTag() [constructor] cls.add_constructor([]) ## socket.h (module 'network'): void ns3::SocketIpTosTag::Deserialize(ns3::TagBuffer i) [member function] cls.add_method('Deserialize', 'void', [param('ns3::TagBuffer', 'i')], is_virtual=True) ## socket.h (module 'network'): ns3::TypeId ns3::SocketIpTosTag::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): uint32_t ns3::SocketIpTosTag::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): uint8_t ns3::SocketIpTosTag::GetTos() const [member function] cls.add_method('GetTos', 'uint8_t', [], is_const=True) ## socket.h (module 'network'): static ns3::TypeId ns3::SocketIpTosTag::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## socket.h (module 'network'): void ns3::SocketIpTosTag::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## socket.h (module 'network'): void ns3::SocketIpTosTag::Serialize(ns3::TagBuffer i) const [member function] cls.add_method('Serialize', 'void', [param('ns3::TagBuffer', 'i')], is_const=True, is_virtual=True) ## socket.h (module 'network'): void ns3::SocketIpTosTag::SetTos(uint8_t tos) [member function] cls.add_method('SetTos', 'void', [param('uint8_t', 'tos')]) return def register_Ns3SocketIpTtlTag_methods(root_module, cls): ## socket.h (module 'network'): ns3::SocketIpTtlTag::SocketIpTtlTag(ns3::SocketIpTtlTag const & arg0) [copy constructor] cls.add_constructor([param('ns3::SocketIpTtlTag const &', 'arg0')]) ## socket.h (module 'network'): ns3::SocketIpTtlTag::SocketIpTtlTag() [constructor] cls.add_constructor([]) ## socket.h (module 'network'): void ns3::SocketIpTtlTag::Deserialize(ns3::TagBuffer i) [member function] cls.add_method('Deserialize', 'void', [param('ns3::TagBuffer', 'i')], is_virtual=True) ## socket.h (module 'network'): ns3::TypeId ns3::SocketIpTtlTag::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): uint32_t ns3::SocketIpTtlTag::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): uint8_t ns3::SocketIpTtlTag::GetTtl() const [member function] cls.add_method('GetTtl', 'uint8_t', [], is_const=True) ## socket.h (module 'network'): static ns3::TypeId ns3::SocketIpTtlTag::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## socket.h (module 'network'): void ns3::SocketIpTtlTag::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## socket.h (module 'network'): void ns3::SocketIpTtlTag::Serialize(ns3::TagBuffer i) const [member function] cls.add_method('Serialize', 'void', [param('ns3::TagBuffer', 'i')], is_const=True, is_virtual=True) ## socket.h (module 'network'): void ns3::SocketIpTtlTag::SetTtl(uint8_t ttl) [member function] cls.add_method('SetTtl', 'void', [param('uint8_t', 'ttl')]) return def register_Ns3SocketIpv6HopLimitTag_methods(root_module, cls): ## socket.h (module 'network'): ns3::SocketIpv6HopLimitTag::SocketIpv6HopLimitTag(ns3::SocketIpv6HopLimitTag const & arg0) [copy constructor] cls.add_constructor([param('ns3::SocketIpv6HopLimitTag const &', 'arg0')]) ## socket.h (module 'network'): ns3::SocketIpv6HopLimitTag::SocketIpv6HopLimitTag() [constructor] cls.add_constructor([]) ## socket.h (module 'network'): void ns3::SocketIpv6HopLimitTag::Deserialize(ns3::TagBuffer i) [member function] cls.add_method('Deserialize', 'void', [param('ns3::TagBuffer', 'i')], is_virtual=True) ## socket.h (module 'network'): uint8_t ns3::SocketIpv6HopLimitTag::GetHopLimit() const [member function] cls.add_method('GetHopLimit', 'uint8_t', [], is_const=True) ## socket.h (module 'network'): ns3::TypeId ns3::SocketIpv6HopLimitTag::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): uint32_t ns3::SocketIpv6HopLimitTag::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): static ns3::TypeId ns3::SocketIpv6HopLimitTag::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## socket.h (module 'network'): void ns3::SocketIpv6HopLimitTag::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## socket.h (module 'network'): void ns3::SocketIpv6HopLimitTag::Serialize(ns3::TagBuffer i) const [member function] cls.add_method('Serialize', 'void', [param('ns3::TagBuffer', 'i')], is_const=True, is_virtual=True) ## socket.h (module 'network'): void ns3::SocketIpv6HopLimitTag::SetHopLimit(uint8_t hopLimit) [member function] cls.add_method('SetHopLimit', 'void', [param('uint8_t', 'hopLimit')]) return def register_Ns3SocketIpv6TclassTag_methods(root_module, cls): ## socket.h (module 'network'): ns3::SocketIpv6TclassTag::SocketIpv6TclassTag(ns3::SocketIpv6TclassTag const & arg0) [copy constructor] cls.add_constructor([param('ns3::SocketIpv6TclassTag const &', 'arg0')]) ## socket.h (module 'network'): ns3::SocketIpv6TclassTag::SocketIpv6TclassTag() [constructor] cls.add_constructor([]) ## socket.h (module 'network'): void ns3::SocketIpv6TclassTag::Deserialize(ns3::TagBuffer i) [member function] cls.add_method('Deserialize', 'void', [param('ns3::TagBuffer', 'i')], is_virtual=True) ## socket.h (module 'network'): ns3::TypeId ns3::SocketIpv6TclassTag::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): uint32_t ns3::SocketIpv6TclassTag::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): uint8_t ns3::SocketIpv6TclassTag::GetTclass() const [member function] cls.add_method('GetTclass', 'uint8_t', [], is_const=True) ## socket.h (module 'network'): static ns3::TypeId ns3::SocketIpv6TclassTag::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## socket.h (module 'network'): void ns3::SocketIpv6TclassTag::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## socket.h (module 'network'): void ns3::SocketIpv6TclassTag::Serialize(ns3::TagBuffer i) const [member function] cls.add_method('Serialize', 'void', [param('ns3::TagBuffer', 'i')], is_const=True, is_virtual=True) ## socket.h (module 'network'): void ns3::SocketIpv6TclassTag::SetTclass(uint8_t tclass) [member function] cls.add_method('SetTclass', 'void', [param('uint8_t', 'tclass')]) return def register_Ns3SocketPriorityTag_methods(root_module, cls): ## socket.h (module 'network'): ns3::SocketPriorityTag::SocketPriorityTag(ns3::SocketPriorityTag const & arg0) [copy constructor] cls.add_constructor([param('ns3::SocketPriorityTag const &', 'arg0')]) ## socket.h (module 'network'): ns3::SocketPriorityTag::SocketPriorityTag() [constructor] cls.add_constructor([]) ## socket.h (module 'network'): void ns3::SocketPriorityTag::Deserialize(ns3::TagBuffer i) [member function] cls.add_method('Deserialize', 'void', [param('ns3::TagBuffer', 'i')], is_virtual=True) ## socket.h (module 'network'): ns3::TypeId ns3::SocketPriorityTag::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): uint8_t ns3::SocketPriorityTag::GetPriority() const [member function] cls.add_method('GetPriority', 'uint8_t', [], is_const=True) ## socket.h (module 'network'): uint32_t ns3::SocketPriorityTag::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): static ns3::TypeId ns3::SocketPriorityTag::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## socket.h (module 'network'): void ns3::SocketPriorityTag::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## socket.h (module 'network'): void ns3::SocketPriorityTag::Serialize(ns3::TagBuffer i) const [member function] cls.add_method('Serialize', 'void', [param('ns3::TagBuffer', 'i')], is_const=True, is_virtual=True) ## socket.h (module 'network'): void ns3::SocketPriorityTag::SetPriority(uint8_t priority) [member function] cls.add_method('SetPriority', 'void', [param('uint8_t', 'priority')]) return def register_Ns3SocketSetDontFragmentTag_methods(root_module, cls): ## socket.h (module 'network'): ns3::SocketSetDontFragmentTag::SocketSetDontFragmentTag(ns3::SocketSetDontFragmentTag const & arg0) [copy constructor] cls.add_constructor([param('ns3::SocketSetDontFragmentTag const &', 'arg0')]) ## socket.h (module 'network'): ns3::SocketSetDontFragmentTag::SocketSetDontFragmentTag() [constructor] cls.add_constructor([]) ## socket.h (module 'network'): void ns3::SocketSetDontFragmentTag::Deserialize(ns3::TagBuffer i) [member function] cls.add_method('Deserialize', 'void', [param('ns3::TagBuffer', 'i')], is_virtual=True) ## socket.h (module 'network'): void ns3::SocketSetDontFragmentTag::Disable() [member function] cls.add_method('Disable', 'void', []) ## socket.h (module 'network'): void ns3::SocketSetDontFragmentTag::Enable() [member function] cls.add_method('Enable', 'void', []) ## socket.h (module 'network'): ns3::TypeId ns3::SocketSetDontFragmentTag::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): uint32_t ns3::SocketSetDontFragmentTag::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## socket.h (module 'network'): static ns3::TypeId ns3::SocketSetDontFragmentTag::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## socket.h (module 'network'): bool ns3::SocketSetDontFragmentTag::IsEnabled() const [member function] cls.add_method('IsEnabled', 'bool', [], is_const=True) ## socket.h (module 'network'): void ns3::SocketSetDontFragmentTag::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## socket.h (module 'network'): void ns3::SocketSetDontFragmentTag::Serialize(ns3::TagBuffer i) const [member function] cls.add_method('Serialize', 'void', [param('ns3::TagBuffer', 'i')], is_const=True, is_virtual=True) return def register_Ns3Time_methods(root_module, cls): cls.add_binary_comparison_operator('<=') cls.add_binary_comparison_operator('!=') cls.add_inplace_numeric_operator('+=', param('ns3::Time const &', u'right')) cls.add_binary_numeric_operator('*', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) cls.add_binary_numeric_operator('+', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) cls.add_binary_numeric_operator('-', root_module['ns3::Time'], root_module['ns3::Time'], param('ns3::Time const &', u'right')) cls.add_binary_numeric_operator('/', root_module['ns3::Time'], root_module['ns3::Time'], param('int64_t const &', u'right')) cls.add_binary_comparison_operator('<') cls.add_binary_comparison_operator('>') cls.add_inplace_numeric_operator('-=', param('ns3::Time const &', u'right')) cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') cls.add_binary_comparison_operator('>=') ## nstime.h (module 'core'): ns3::Time::Time() [constructor] cls.add_constructor([]) ## nstime.h (module 'core'): ns3::Time::Time(ns3::Time const & o) [copy constructor] cls.add_constructor([param('ns3::Time const &', 'o')]) ## nstime.h (module 'core'): ns3::Time::Time(double v) [constructor] cls.add_constructor([param('double', 'v')]) ## nstime.h (module 'core'): ns3::Time::Time(int v) [constructor] cls.add_constructor([param('int', 'v')]) ## nstime.h (module 'core'): ns3::Time::Time(long int v) [constructor] cls.add_constructor([param('long int', 'v')]) ## nstime.h (module 'core'): ns3::Time::Time(long long int v) [constructor] cls.add_constructor([param('long long int', 'v')]) ## nstime.h (module 'core'): ns3::Time::Time(unsigned int v) [constructor] cls.add_constructor([param('unsigned int', 'v')]) ## nstime.h (module 'core'): ns3::Time::Time(long unsigned int v) [constructor] cls.add_constructor([param('long unsigned int', 'v')]) ## nstime.h (module 'core'): ns3::Time::Time(long long unsigned int v) [constructor] cls.add_constructor([param('long long unsigned int', 'v')]) ## nstime.h (module 'core'): ns3::Time::Time(ns3::int64x64_t const & v) [constructor] cls.add_constructor([param('ns3::int64x64_t const &', 'v')]) ## nstime.h (module 'core'): ns3::Time::Time(std::string const & s) [constructor] cls.add_constructor([param('std::string const &', 's')]) ## nstime.h (module 'core'): ns3::TimeWithUnit ns3::Time::As(ns3::Time::Unit const unit) const [member function] cls.add_method('As', 'ns3::TimeWithUnit', [param('ns3::Time::Unit const', 'unit')], is_const=True) ## nstime.h (module 'core'): int ns3::Time::Compare(ns3::Time const & o) const [member function] cls.add_method('Compare', 'int', [param('ns3::Time const &', 'o')], is_const=True) ## nstime.h (module 'core'): static ns3::Time ns3::Time::From(ns3::int64x64_t const & value) [member function] cls.add_method('From', 'ns3::Time', [param('ns3::int64x64_t const &', 'value')], is_static=True) ## nstime.h (module 'core'): static ns3::Time ns3::Time::From(ns3::int64x64_t const & value, ns3::Time::Unit unit) [member function] cls.add_method('From', 'ns3::Time', [param('ns3::int64x64_t const &', 'value'), param('ns3::Time::Unit', 'unit')], is_static=True) ## nstime.h (module 'core'): static ns3::Time ns3::Time::FromDouble(double value, ns3::Time::Unit unit) [member function] cls.add_method('FromDouble', 'ns3::Time', [param('double', 'value'), param('ns3::Time::Unit', 'unit')], is_static=True) ## nstime.h (module 'core'): static ns3::Time ns3::Time::FromInteger(uint64_t value, ns3::Time::Unit unit) [member function] cls.add_method('FromInteger', 'ns3::Time', [param('uint64_t', 'value'), param('ns3::Time::Unit', 'unit')], is_static=True) ## nstime.h (module 'core'): double ns3::Time::GetDays() const [member function] cls.add_method('GetDays', 'double', [], is_const=True) ## nstime.h (module 'core'): double ns3::Time::GetDouble() const [member function] cls.add_method('GetDouble', 'double', [], is_const=True) ## nstime.h (module 'core'): int64_t ns3::Time::GetFemtoSeconds() const [member function] cls.add_method('GetFemtoSeconds', 'int64_t', [], is_const=True) ## nstime.h (module 'core'): double ns3::Time::GetHours() const [member function] cls.add_method('GetHours', 'double', [], is_const=True) ## nstime.h (module 'core'): int64_t ns3::Time::GetInteger() const [member function] cls.add_method('GetInteger', 'int64_t', [], is_const=True) ## nstime.h (module 'core'): int64_t ns3::Time::GetMicroSeconds() const [member function] cls.add_method('GetMicroSeconds', 'int64_t', [], is_const=True) ## nstime.h (module 'core'): int64_t ns3::Time::GetMilliSeconds() const [member function] cls.add_method('GetMilliSeconds', 'int64_t', [], is_const=True) ## nstime.h (module 'core'): double ns3::Time::GetMinutes() const [member function] cls.add_method('GetMinutes', 'double', [], is_const=True) ## nstime.h (module 'core'): int64_t ns3::Time::GetNanoSeconds() const [member function] cls.add_method('GetNanoSeconds', 'int64_t', [], is_const=True) ## nstime.h (module 'core'): int64_t ns3::Time::GetPicoSeconds() const [member function] cls.add_method('GetPicoSeconds', 'int64_t', [], is_const=True) ## nstime.h (module 'core'): static ns3::Time::Unit ns3::Time::GetResolution() [member function] cls.add_method('GetResolution', 'ns3::Time::Unit', [], is_static=True) ## nstime.h (module 'core'): double ns3::Time::GetSeconds() const [member function] cls.add_method('GetSeconds', 'double', [], is_const=True) ## nstime.h (module 'core'): int64_t ns3::Time::GetTimeStep() const [member function] cls.add_method('GetTimeStep', 'int64_t', [], is_const=True) ## nstime.h (module 'core'): double ns3::Time::GetYears() const [member function] cls.add_method('GetYears', 'double', [], is_const=True) ## nstime.h (module 'core'): bool ns3::Time::IsNegative() const [member function] cls.add_method('IsNegative', 'bool', [], is_const=True) ## nstime.h (module 'core'): bool ns3::Time::IsPositive() const [member function] cls.add_method('IsPositive', 'bool', [], is_const=True) ## nstime.h (module 'core'): bool ns3::Time::IsStrictlyNegative() const [member function] cls.add_method('IsStrictlyNegative', 'bool', [], is_const=True) ## nstime.h (module 'core'): bool ns3::Time::IsStrictlyPositive() const [member function] cls.add_method('IsStrictlyPositive', 'bool', [], is_const=True) ## nstime.h (module 'core'): bool ns3::Time::IsZero() const [member function] cls.add_method('IsZero', 'bool', [], is_const=True) ## nstime.h (module 'core'): static ns3::Time ns3::Time::Max() [member function] cls.add_method('Max', 'ns3::Time', [], is_static=True) ## nstime.h (module 'core'): static ns3::Time ns3::Time::Min() [member function] cls.add_method('Min', 'ns3::Time', [], is_static=True) ## nstime.h (module 'core'): static void ns3::Time::SetResolution(ns3::Time::Unit resolution) [member function] cls.add_method('SetResolution', 'void', [param('ns3::Time::Unit', 'resolution')], is_static=True) ## nstime.h (module 'core'): static bool ns3::Time::StaticInit() [member function] cls.add_method('StaticInit', 'bool', [], is_static=True) ## nstime.h (module 'core'): ns3::int64x64_t ns3::Time::To(ns3::Time::Unit unit) const [member function] cls.add_method('To', 'ns3::int64x64_t', [param('ns3::Time::Unit', 'unit')], is_const=True) ## nstime.h (module 'core'): double ns3::Time::ToDouble(ns3::Time::Unit unit) const [member function] cls.add_method('ToDouble', 'double', [param('ns3::Time::Unit', 'unit')], is_const=True) ## nstime.h (module 'core'): int64_t ns3::Time::ToInteger(ns3::Time::Unit unit) const [member function] cls.add_method('ToInteger', 'int64_t', [param('ns3::Time::Unit', 'unit')], is_const=True) return def register_Ns3TraceSourceAccessor_methods(root_module, cls): ## trace-source-accessor.h (module 'core'): ns3::TraceSourceAccessor::TraceSourceAccessor(ns3::TraceSourceAccessor const & arg0) [copy constructor] cls.add_constructor([param('ns3::TraceSourceAccessor const &', 'arg0')]) ## trace-source-accessor.h (module 'core'): ns3::TraceSourceAccessor::TraceSourceAccessor() [constructor] cls.add_constructor([]) ## trace-source-accessor.h (module 'core'): bool ns3::TraceSourceAccessor::Connect(ns3::ObjectBase * obj, std::string context, ns3::CallbackBase const & cb) const [member function] cls.add_method('Connect', 'bool', [param('ns3::ObjectBase *', 'obj', transfer_ownership=False), param('std::string', 'context'), param('ns3::CallbackBase const &', 'cb')], is_pure_virtual=True, is_const=True, is_virtual=True) ## trace-source-accessor.h (module 'core'): bool ns3::TraceSourceAccessor::ConnectWithoutContext(ns3::ObjectBase * obj, ns3::CallbackBase const & cb) const [member function] cls.add_method('ConnectWithoutContext', 'bool', [param('ns3::ObjectBase *', 'obj', transfer_ownership=False), param('ns3::CallbackBase const &', 'cb')], is_pure_virtual=True, is_const=True, is_virtual=True) ## trace-source-accessor.h (module 'core'): bool ns3::TraceSourceAccessor::Disconnect(ns3::ObjectBase * obj, std::string context, ns3::CallbackBase const & cb) const [member function] cls.add_method('Disconnect', 'bool', [param('ns3::ObjectBase *', 'obj', transfer_ownership=False), param('std::string', 'context'), param('ns3::CallbackBase const &', 'cb')], is_pure_virtual=True, is_const=True, is_virtual=True) ## trace-source-accessor.h (module 'core'): bool ns3::TraceSourceAccessor::DisconnectWithoutContext(ns3::ObjectBase * obj, ns3::CallbackBase const & cb) const [member function] cls.add_method('DisconnectWithoutContext', 'bool', [param('ns3::ObjectBase *', 'obj', transfer_ownership=False), param('ns3::CallbackBase const &', 'cb')], is_pure_virtual=True, is_const=True, is_virtual=True) return def register_Ns3Trailer_methods(root_module, cls): cls.add_output_stream_operator() ## trailer.h (module 'network'): ns3::Trailer::Trailer() [constructor] cls.add_constructor([]) ## trailer.h (module 'network'): ns3::Trailer::Trailer(ns3::Trailer const & arg0) [copy constructor] cls.add_constructor([param('ns3::Trailer const &', 'arg0')]) ## trailer.h (module 'network'): uint32_t ns3::Trailer::Deserialize(ns3::Buffer::Iterator end) [member function] cls.add_method('Deserialize', 'uint32_t', [param('ns3::Buffer::Iterator', 'end')], is_pure_virtual=True, is_virtual=True) ## trailer.h (module 'network'): uint32_t ns3::Trailer::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## trailer.h (module 'network'): static ns3::TypeId ns3::Trailer::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## trailer.h (module 'network'): void ns3::Trailer::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_pure_virtual=True, is_const=True, is_virtual=True) ## trailer.h (module 'network'): void ns3::Trailer::Serialize(ns3::Buffer::Iterator start) const [member function] cls.add_method('Serialize', 'void', [param('ns3::Buffer::Iterator', 'start')], is_pure_virtual=True, is_const=True, is_virtual=True) return def register_Ns3TriangularRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::TriangularRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::TriangularRandomVariable::TriangularRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): double ns3::TriangularRandomVariable::GetMean() const [member function] cls.add_method('GetMean', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::TriangularRandomVariable::GetMin() const [member function] cls.add_method('GetMin', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::TriangularRandomVariable::GetMax() const [member function] cls.add_method('GetMax', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::TriangularRandomVariable::GetValue(double mean, double min, double max) [member function] cls.add_method('GetValue', 'double', [param('double', 'mean'), param('double', 'min'), param('double', 'max')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::TriangularRandomVariable::GetInteger(uint32_t mean, uint32_t min, uint32_t max) [member function] cls.add_method('GetInteger', 'uint32_t', [param('uint32_t', 'mean'), param('uint32_t', 'min'), param('uint32_t', 'max')]) ## random-variable-stream.h (module 'core'): double ns3::TriangularRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::TriangularRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3UniformRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::UniformRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::UniformRandomVariable::UniformRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): double ns3::UniformRandomVariable::GetMin() const [member function] cls.add_method('GetMin', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::UniformRandomVariable::GetMax() const [member function] cls.add_method('GetMax', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::UniformRandomVariable::GetValue(double min, double max) [member function] cls.add_method('GetValue', 'double', [param('double', 'min'), param('double', 'max')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::UniformRandomVariable::GetInteger(uint32_t min, uint32_t max) [member function] cls.add_method('GetInteger', 'uint32_t', [param('uint32_t', 'min'), param('uint32_t', 'max')]) ## random-variable-stream.h (module 'core'): double ns3::UniformRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::UniformRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3WeibullRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::WeibullRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::WeibullRandomVariable::WeibullRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): double ns3::WeibullRandomVariable::GetScale() const [member function] cls.add_method('GetScale', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::WeibullRandomVariable::GetShape() const [member function] cls.add_method('GetShape', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::WeibullRandomVariable::GetBound() const [member function] cls.add_method('GetBound', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::WeibullRandomVariable::GetValue(double scale, double shape, double bound) [member function] cls.add_method('GetValue', 'double', [param('double', 'scale'), param('double', 'shape'), param('double', 'bound')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::WeibullRandomVariable::GetInteger(uint32_t scale, uint32_t shape, uint32_t bound) [member function] cls.add_method('GetInteger', 'uint32_t', [param('uint32_t', 'scale'), param('uint32_t', 'shape'), param('uint32_t', 'bound')]) ## random-variable-stream.h (module 'core'): double ns3::WeibullRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::WeibullRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3WifiMacHeader_methods(root_module, cls): ## wifi-mac-header.h (module 'wifi'): ns3::WifiMacHeader::WifiMacHeader(ns3::WifiMacHeader const & arg0) [copy constructor] cls.add_constructor([param('ns3::WifiMacHeader const &', 'arg0')]) ## wifi-mac-header.h (module 'wifi'): ns3::WifiMacHeader::WifiMacHeader() [constructor] cls.add_constructor([]) ## wifi-mac-header.h (module 'wifi'): uint32_t ns3::WifiMacHeader::Deserialize(ns3::Buffer::Iterator start) [member function] cls.add_method('Deserialize', 'uint32_t', [param('ns3::Buffer::Iterator', 'start')], is_virtual=True) ## wifi-mac-header.h (module 'wifi'): ns3::Mac48Address ns3::WifiMacHeader::GetAddr1() const [member function] cls.add_method('GetAddr1', 'ns3::Mac48Address', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): ns3::Mac48Address ns3::WifiMacHeader::GetAddr2() const [member function] cls.add_method('GetAddr2', 'ns3::Mac48Address', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): ns3::Mac48Address ns3::WifiMacHeader::GetAddr3() const [member function] cls.add_method('GetAddr3', 'ns3::Mac48Address', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): ns3::Mac48Address ns3::WifiMacHeader::GetAddr4() const [member function] cls.add_method('GetAddr4', 'ns3::Mac48Address', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): ns3::Time ns3::WifiMacHeader::GetDuration() const [member function] cls.add_method('GetDuration', 'ns3::Time', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): uint16_t ns3::WifiMacHeader::GetFragmentNumber() const [member function] cls.add_method('GetFragmentNumber', 'uint16_t', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): ns3::TypeId ns3::WifiMacHeader::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## wifi-mac-header.h (module 'wifi'): ns3::WifiMacHeader::QosAckPolicy ns3::WifiMacHeader::GetQosAckPolicy() const [member function] cls.add_method('GetQosAckPolicy', 'ns3::WifiMacHeader::QosAckPolicy', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): uint8_t ns3::WifiMacHeader::GetQosTid() const [member function] cls.add_method('GetQosTid', 'uint8_t', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): uint8_t ns3::WifiMacHeader::GetQosTxopLimit() const [member function] cls.add_method('GetQosTxopLimit', 'uint8_t', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): uint16_t ns3::WifiMacHeader::GetRawDuration() const [member function] cls.add_method('GetRawDuration', 'uint16_t', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): uint16_t ns3::WifiMacHeader::GetSequenceControl() const [member function] cls.add_method('GetSequenceControl', 'uint16_t', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): uint16_t ns3::WifiMacHeader::GetSequenceNumber() const [member function] cls.add_method('GetSequenceNumber', 'uint16_t', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): uint32_t ns3::WifiMacHeader::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## wifi-mac-header.h (module 'wifi'): uint32_t ns3::WifiMacHeader::GetSize() const [member function] cls.add_method('GetSize', 'uint32_t', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): ns3::WifiMacType ns3::WifiMacHeader::GetType() const [member function] cls.add_method('GetType', 'ns3::WifiMacType', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): static ns3::TypeId ns3::WifiMacHeader::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## wifi-mac-header.h (module 'wifi'): char const * ns3::WifiMacHeader::GetTypeString() const [member function] cls.add_method('GetTypeString', 'char const *', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsAck() const [member function] cls.add_method('IsAck', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsAction() const [member function] cls.add_method('IsAction', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsAssocReq() const [member function] cls.add_method('IsAssocReq', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsAssocResp() const [member function] cls.add_method('IsAssocResp', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsAuthentication() const [member function] cls.add_method('IsAuthentication', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsBeacon() const [member function] cls.add_method('IsBeacon', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsBlockAck() const [member function] cls.add_method('IsBlockAck', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsBlockAckReq() const [member function] cls.add_method('IsBlockAckReq', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsCfpoll() const [member function] cls.add_method('IsCfpoll', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsCtl() const [member function] cls.add_method('IsCtl', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsCts() const [member function] cls.add_method('IsCts', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsData() const [member function] cls.add_method('IsData', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsDeauthentication() const [member function] cls.add_method('IsDeauthentication', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsDisassociation() const [member function] cls.add_method('IsDisassociation', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsFromDs() const [member function] cls.add_method('IsFromDs', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsMgt() const [member function] cls.add_method('IsMgt', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsMoreFragments() const [member function] cls.add_method('IsMoreFragments', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsMultihopAction() const [member function] cls.add_method('IsMultihopAction', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsProbeReq() const [member function] cls.add_method('IsProbeReq', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsProbeResp() const [member function] cls.add_method('IsProbeResp', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsQosAck() const [member function] cls.add_method('IsQosAck', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsQosAmsdu() const [member function] cls.add_method('IsQosAmsdu', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsQosBlockAck() const [member function] cls.add_method('IsQosBlockAck', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsQosData() const [member function] cls.add_method('IsQosData', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsQosEosp() const [member function] cls.add_method('IsQosEosp', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsQosNoAck() const [member function] cls.add_method('IsQosNoAck', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsReassocReq() const [member function] cls.add_method('IsReassocReq', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsReassocResp() const [member function] cls.add_method('IsReassocResp', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsRetry() const [member function] cls.add_method('IsRetry', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsRts() const [member function] cls.add_method('IsRts', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): bool ns3::WifiMacHeader::IsToDs() const [member function] cls.add_method('IsToDs', 'bool', [], is_const=True) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::Serialize(ns3::Buffer::Iterator start) const [member function] cls.add_method('Serialize', 'void', [param('ns3::Buffer::Iterator', 'start')], is_const=True, is_virtual=True) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetAction() [member function] cls.add_method('SetAction', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetAddr1(ns3::Mac48Address address) [member function] cls.add_method('SetAddr1', 'void', [param('ns3::Mac48Address', 'address')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetAddr2(ns3::Mac48Address address) [member function] cls.add_method('SetAddr2', 'void', [param('ns3::Mac48Address', 'address')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetAddr3(ns3::Mac48Address address) [member function] cls.add_method('SetAddr3', 'void', [param('ns3::Mac48Address', 'address')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetAddr4(ns3::Mac48Address address) [member function] cls.add_method('SetAddr4', 'void', [param('ns3::Mac48Address', 'address')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetAssocReq() [member function] cls.add_method('SetAssocReq', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetAssocResp() [member function] cls.add_method('SetAssocResp', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetBeacon() [member function] cls.add_method('SetBeacon', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetBlockAck() [member function] cls.add_method('SetBlockAck', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetBlockAckReq() [member function] cls.add_method('SetBlockAckReq', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetDsFrom() [member function] cls.add_method('SetDsFrom', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetDsNotFrom() [member function] cls.add_method('SetDsNotFrom', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetDsNotTo() [member function] cls.add_method('SetDsNotTo', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetDsTo() [member function] cls.add_method('SetDsTo', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetDuration(ns3::Time duration) [member function] cls.add_method('SetDuration', 'void', [param('ns3::Time', 'duration')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetFragmentNumber(uint8_t frag) [member function] cls.add_method('SetFragmentNumber', 'void', [param('uint8_t', 'frag')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetId(uint16_t id) [member function] cls.add_method('SetId', 'void', [param('uint16_t', 'id')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetMoreFragments() [member function] cls.add_method('SetMoreFragments', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetMultihopAction() [member function] cls.add_method('SetMultihopAction', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetNoMoreFragments() [member function] cls.add_method('SetNoMoreFragments', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetNoOrder() [member function] cls.add_method('SetNoOrder', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetNoRetry() [member function] cls.add_method('SetNoRetry', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetOrder() [member function] cls.add_method('SetOrder', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetProbeReq() [member function] cls.add_method('SetProbeReq', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetProbeResp() [member function] cls.add_method('SetProbeResp', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetQosAckPolicy(ns3::WifiMacHeader::QosAckPolicy policy) [member function] cls.add_method('SetQosAckPolicy', 'void', [param('ns3::WifiMacHeader::QosAckPolicy', 'policy')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetQosAmsdu() [member function] cls.add_method('SetQosAmsdu', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetQosBlockAck() [member function] cls.add_method('SetQosBlockAck', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetQosEosp() [member function] cls.add_method('SetQosEosp', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetQosMeshControlPresent() [member function] cls.add_method('SetQosMeshControlPresent', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetQosNoAck() [member function] cls.add_method('SetQosNoAck', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetQosNoAmsdu() [member function] cls.add_method('SetQosNoAmsdu', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetQosNoEosp() [member function] cls.add_method('SetQosNoEosp', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetQosNoMeshControlPresent() [member function] cls.add_method('SetQosNoMeshControlPresent', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetQosNormalAck() [member function] cls.add_method('SetQosNormalAck', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetQosTid(uint8_t tid) [member function] cls.add_method('SetQosTid', 'void', [param('uint8_t', 'tid')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetQosTxopLimit(uint8_t txop) [member function] cls.add_method('SetQosTxopLimit', 'void', [param('uint8_t', 'txop')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetRawDuration(uint16_t duration) [member function] cls.add_method('SetRawDuration', 'void', [param('uint16_t', 'duration')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetRetry() [member function] cls.add_method('SetRetry', 'void', []) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetSequenceNumber(uint16_t seq) [member function] cls.add_method('SetSequenceNumber', 'void', [param('uint16_t', 'seq')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetType(ns3::WifiMacType type) [member function] cls.add_method('SetType', 'void', [param('ns3::WifiMacType', 'type')]) ## wifi-mac-header.h (module 'wifi'): void ns3::WifiMacHeader::SetTypeData() [member function] cls.add_method('SetTypeData', 'void', []) return def register_Ns3ZetaRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::ZetaRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::ZetaRandomVariable::ZetaRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): double ns3::ZetaRandomVariable::GetAlpha() const [member function] cls.add_method('GetAlpha', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::ZetaRandomVariable::GetValue(double alpha) [member function] cls.add_method('GetValue', 'double', [param('double', 'alpha')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::ZetaRandomVariable::GetInteger(uint32_t alpha) [member function] cls.add_method('GetInteger', 'uint32_t', [param('uint32_t', 'alpha')]) ## random-variable-stream.h (module 'core'): double ns3::ZetaRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::ZetaRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3ZipfRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::ZipfRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::ZipfRandomVariable::ZipfRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): uint32_t ns3::ZipfRandomVariable::GetN() const [member function] cls.add_method('GetN', 'uint32_t', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::ZipfRandomVariable::GetAlpha() const [member function] cls.add_method('GetAlpha', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::ZipfRandomVariable::GetValue(uint32_t n, double alpha) [member function] cls.add_method('GetValue', 'double', [param('uint32_t', 'n'), param('double', 'alpha')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::ZipfRandomVariable::GetInteger(uint32_t n, uint32_t alpha) [member function] cls.add_method('GetInteger', 'uint32_t', [param('uint32_t', 'n'), param('uint32_t', 'alpha')]) ## random-variable-stream.h (module 'core'): double ns3::ZipfRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::ZipfRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3ArpCache_methods(root_module, cls): ## arp-cache.h (module 'internet'): ns3::ArpCache::ArpCache() [constructor] cls.add_constructor([]) ## arp-cache.h (module 'internet'): ns3::ArpCache::Entry * ns3::ArpCache::Add(ns3::Ipv4Address to) [member function] cls.add_method('Add', 'ns3::ArpCache::Entry *', [param('ns3::Ipv4Address', 'to')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::Flush() [member function] cls.add_method('Flush', 'void', []) ## arp-cache.h (module 'internet'): ns3::Time ns3::ArpCache::GetAliveTimeout() const [member function] cls.add_method('GetAliveTimeout', 'ns3::Time', [], is_const=True) ## arp-cache.h (module 'internet'): ns3::Time ns3::ArpCache::GetDeadTimeout() const [member function] cls.add_method('GetDeadTimeout', 'ns3::Time', [], is_const=True) ## arp-cache.h (module 'internet'): ns3::Ptr<ns3::NetDevice> ns3::ArpCache::GetDevice() const [member function] cls.add_method('GetDevice', 'ns3::Ptr< ns3::NetDevice >', [], is_const=True) ## arp-cache.h (module 'internet'): ns3::Ptr<ns3::Ipv4Interface> ns3::ArpCache::GetInterface() const [member function] cls.add_method('GetInterface', 'ns3::Ptr< ns3::Ipv4Interface >', [], is_const=True) ## arp-cache.h (module 'internet'): static ns3::TypeId ns3::ArpCache::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## arp-cache.h (module 'internet'): ns3::Time ns3::ArpCache::GetWaitReplyTimeout() const [member function] cls.add_method('GetWaitReplyTimeout', 'ns3::Time', [], is_const=True) ## arp-cache.h (module 'internet'): ns3::ArpCache::Entry * ns3::ArpCache::Lookup(ns3::Ipv4Address destination) [member function] cls.add_method('Lookup', 'ns3::ArpCache::Entry *', [param('ns3::Ipv4Address', 'destination')]) ## arp-cache.h (module 'internet'): std::list<ns3::ArpCache::Entry*,std::allocator<ns3::ArpCache::Entry*> > ns3::ArpCache::LookupInverse(ns3::Address destination) [member function] cls.add_method('LookupInverse', 'std::list< ns3::ArpCache::Entry * >', [param('ns3::Address', 'destination')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::PrintArpCache(ns3::Ptr<ns3::OutputStreamWrapper> stream) [member function] cls.add_method('PrintArpCache', 'void', [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::Remove(ns3::ArpCache::Entry * entry) [member function] cls.add_method('Remove', 'void', [param('ns3::ArpCache::Entry *', 'entry')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::SetAliveTimeout(ns3::Time aliveTimeout) [member function] cls.add_method('SetAliveTimeout', 'void', [param('ns3::Time', 'aliveTimeout')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::SetArpRequestCallback(ns3::Callback<void, ns3::Ptr<ns3::ArpCache const>, ns3::Ipv4Address, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> arpRequestCallback) [member function] cls.add_method('SetArpRequestCallback', 'void', [param('ns3::Callback< void, ns3::Ptr< ns3::ArpCache const >, ns3::Ipv4Address, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'arpRequestCallback')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::SetDeadTimeout(ns3::Time deadTimeout) [member function] cls.add_method('SetDeadTimeout', 'void', [param('ns3::Time', 'deadTimeout')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::SetDevice(ns3::Ptr<ns3::NetDevice> device, ns3::Ptr<ns3::Ipv4Interface> interface) [member function] cls.add_method('SetDevice', 'void', [param('ns3::Ptr< ns3::NetDevice >', 'device'), param('ns3::Ptr< ns3::Ipv4Interface >', 'interface')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::SetWaitReplyTimeout(ns3::Time waitReplyTimeout) [member function] cls.add_method('SetWaitReplyTimeout', 'void', [param('ns3::Time', 'waitReplyTimeout')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::StartWaitReplyTimer() [member function] cls.add_method('StartWaitReplyTimer', 'void', []) ## arp-cache.h (module 'internet'): void ns3::ArpCache::DoDispose() [member function] cls.add_method('DoDispose', 'void', [], visibility='private', is_virtual=True) return def register_Ns3ArpCacheEntry_methods(root_module, cls): ## arp-cache.h (module 'internet'): ns3::ArpCache::Entry::Entry(ns3::ArpCache::Entry const & arg0) [copy constructor] cls.add_constructor([param('ns3::ArpCache::Entry const &', 'arg0')]) ## arp-cache.h (module 'internet'): ns3::ArpCache::Entry::Entry(ns3::ArpCache * arp) [constructor] cls.add_constructor([param('ns3::ArpCache *', 'arp')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::Entry::ClearPendingPacket() [member function] cls.add_method('ClearPendingPacket', 'void', []) ## arp-cache.h (module 'internet'): void ns3::ArpCache::Entry::ClearRetries() [member function] cls.add_method('ClearRetries', 'void', []) ## arp-cache.h (module 'internet'): std::pair<ns3::Ptr<ns3::Packet>,ns3::Ipv4Header> ns3::ArpCache::Entry::DequeuePending() [member function] cls.add_method('DequeuePending', 'std::pair< ns3::Ptr< ns3::Packet >, ns3::Ipv4Header >', []) ## arp-cache.h (module 'internet'): ns3::Ipv4Address ns3::ArpCache::Entry::GetIpv4Address() const [member function] cls.add_method('GetIpv4Address', 'ns3::Ipv4Address', [], is_const=True) ## arp-cache.h (module 'internet'): ns3::Address ns3::ArpCache::Entry::GetMacAddress() const [member function] cls.add_method('GetMacAddress', 'ns3::Address', [], is_const=True) ## arp-cache.h (module 'internet'): uint32_t ns3::ArpCache::Entry::GetRetries() const [member function] cls.add_method('GetRetries', 'uint32_t', [], is_const=True) ## arp-cache.h (module 'internet'): void ns3::ArpCache::Entry::IncrementRetries() [member function] cls.add_method('IncrementRetries', 'void', []) ## arp-cache.h (module 'internet'): bool ns3::ArpCache::Entry::IsAlive() [member function] cls.add_method('IsAlive', 'bool', []) ## arp-cache.h (module 'internet'): bool ns3::ArpCache::Entry::IsDead() [member function] cls.add_method('IsDead', 'bool', []) ## arp-cache.h (module 'internet'): bool ns3::ArpCache::Entry::IsExpired() const [member function] cls.add_method('IsExpired', 'bool', [], is_const=True) ## arp-cache.h (module 'internet'): bool ns3::ArpCache::Entry::IsPermanent() [member function] cls.add_method('IsPermanent', 'bool', []) ## arp-cache.h (module 'internet'): bool ns3::ArpCache::Entry::IsWaitReply() [member function] cls.add_method('IsWaitReply', 'bool', []) ## arp-cache.h (module 'internet'): void ns3::ArpCache::Entry::MarkAlive(ns3::Address macAddress) [member function] cls.add_method('MarkAlive', 'void', [param('ns3::Address', 'macAddress')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::Entry::MarkDead() [member function] cls.add_method('MarkDead', 'void', []) ## arp-cache.h (module 'internet'): void ns3::ArpCache::Entry::MarkPermanent() [member function] cls.add_method('MarkPermanent', 'void', []) ## arp-cache.h (module 'internet'): void ns3::ArpCache::Entry::MarkWaitReply(std::pair<ns3::Ptr<ns3::Packet>,ns3::Ipv4Header> waiting) [member function] cls.add_method('MarkWaitReply', 'void', [param('std::pair< ns3::Ptr< ns3::Packet >, ns3::Ipv4Header >', 'waiting')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::Entry::SetIpv4Address(ns3::Ipv4Address destination) [member function] cls.add_method('SetIpv4Address', 'void', [param('ns3::Ipv4Address', 'destination')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::Entry::SetMacAddresss(ns3::Address macAddress) [member function] cls.add_method('SetMacAddresss', 'void', [param('ns3::Address', 'macAddress')]) ## arp-cache.h (module 'internet'): void ns3::ArpCache::Entry::UpdateSeen() [member function] cls.add_method('UpdateSeen', 'void', []) ## arp-cache.h (module 'internet'): bool ns3::ArpCache::Entry::UpdateWaitReply(std::pair<ns3::Ptr<ns3::Packet>,ns3::Ipv4Header> waiting) [member function] cls.add_method('UpdateWaitReply', 'bool', [param('std::pair< ns3::Ptr< ns3::Packet >, ns3::Ipv4Header >', 'waiting')]) return def register_Ns3AttributeAccessor_methods(root_module, cls): ## attribute.h (module 'core'): ns3::AttributeAccessor::AttributeAccessor(ns3::AttributeAccessor const & arg0) [copy constructor] cls.add_constructor([param('ns3::AttributeAccessor const &', 'arg0')]) ## attribute.h (module 'core'): ns3::AttributeAccessor::AttributeAccessor() [constructor] cls.add_constructor([]) ## attribute.h (module 'core'): bool ns3::AttributeAccessor::Get(ns3::ObjectBase const * object, ns3::AttributeValue & attribute) const [member function] cls.add_method('Get', 'bool', [param('ns3::ObjectBase const *', 'object'), param('ns3::AttributeValue &', 'attribute')], is_pure_virtual=True, is_const=True, is_virtual=True) ## attribute.h (module 'core'): bool ns3::AttributeAccessor::HasGetter() const [member function] cls.add_method('HasGetter', 'bool', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## attribute.h (module 'core'): bool ns3::AttributeAccessor::HasSetter() const [member function] cls.add_method('HasSetter', 'bool', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## attribute.h (module 'core'): bool ns3::AttributeAccessor::Set(ns3::ObjectBase * object, ns3::AttributeValue const & value) const [member function] cls.add_method('Set', 'bool', [param('ns3::ObjectBase *', 'object', transfer_ownership=False), param('ns3::AttributeValue const &', 'value')], is_pure_virtual=True, is_const=True, is_virtual=True) return def register_Ns3AttributeChecker_methods(root_module, cls): ## attribute.h (module 'core'): ns3::AttributeChecker::AttributeChecker(ns3::AttributeChecker const & arg0) [copy constructor] cls.add_constructor([param('ns3::AttributeChecker const &', 'arg0')]) ## attribute.h (module 'core'): ns3::AttributeChecker::AttributeChecker() [constructor] cls.add_constructor([]) ## attribute.h (module 'core'): bool ns3::AttributeChecker::Check(ns3::AttributeValue const & value) const [member function] cls.add_method('Check', 'bool', [param('ns3::AttributeValue const &', 'value')], is_pure_virtual=True, is_const=True, is_virtual=True) ## attribute.h (module 'core'): bool ns3::AttributeChecker::Copy(ns3::AttributeValue const & source, ns3::AttributeValue & destination) const [member function] cls.add_method('Copy', 'bool', [param('ns3::AttributeValue const &', 'source'), param('ns3::AttributeValue &', 'destination')], is_pure_virtual=True, is_const=True, is_virtual=True) ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::AttributeChecker::Create() const [member function] cls.add_method('Create', 'ns3::Ptr< ns3::AttributeValue >', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::AttributeChecker::CreateValidValue(ns3::AttributeValue const & value) const [member function] cls.add_method('CreateValidValue', 'ns3::Ptr< ns3::AttributeValue >', [param('ns3::AttributeValue const &', 'value')], is_const=True) ## attribute.h (module 'core'): std::string ns3::AttributeChecker::GetUnderlyingTypeInformation() const [member function] cls.add_method('GetUnderlyingTypeInformation', 'std::string', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## attribute.h (module 'core'): std::string ns3::AttributeChecker::GetValueTypeName() const [member function] cls.add_method('GetValueTypeName', 'std::string', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## attribute.h (module 'core'): bool ns3::AttributeChecker::HasUnderlyingTypeInformation() const [member function] cls.add_method('HasUnderlyingTypeInformation', 'bool', [], is_pure_virtual=True, is_const=True, is_virtual=True) return def register_Ns3AttributeValue_methods(root_module, cls): ## attribute.h (module 'core'): ns3::AttributeValue::AttributeValue(ns3::AttributeValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::AttributeValue const &', 'arg0')]) ## attribute.h (module 'core'): ns3::AttributeValue::AttributeValue() [constructor] cls.add_constructor([]) ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::AttributeValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## attribute.h (module 'core'): bool ns3::AttributeValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_pure_virtual=True, is_virtual=True) ## attribute.h (module 'core'): std::string ns3::AttributeValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_pure_virtual=True, is_const=True, is_virtual=True) return def register_Ns3CallbackChecker_methods(root_module, cls): ## callback.h (module 'core'): ns3::CallbackChecker::CallbackChecker() [constructor] cls.add_constructor([]) ## callback.h (module 'core'): ns3::CallbackChecker::CallbackChecker(ns3::CallbackChecker const & arg0) [copy constructor] cls.add_constructor([param('ns3::CallbackChecker const &', 'arg0')]) return def register_Ns3CallbackImplBase_methods(root_module, cls): ## callback.h (module 'core'): ns3::CallbackImplBase::CallbackImplBase() [constructor] cls.add_constructor([]) ## callback.h (module 'core'): ns3::CallbackImplBase::CallbackImplBase(ns3::CallbackImplBase const & arg0) [copy constructor] cls.add_constructor([param('ns3::CallbackImplBase const &', 'arg0')]) ## callback.h (module 'core'): std::string ns3::CallbackImplBase::GetTypeid() const [member function] cls.add_method('GetTypeid', 'std::string', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## callback.h (module 'core'): bool ns3::CallbackImplBase::IsEqual(ns3::Ptr<ns3::CallbackImplBase const> other) const [member function] cls.add_method('IsEqual', 'bool', [param('ns3::Ptr< ns3::CallbackImplBase const >', 'other')], is_pure_virtual=True, is_const=True, is_virtual=True) ## callback.h (module 'core'): static std::string ns3::CallbackImplBase::Demangle(std::string const & mangled) [member function] cls.add_method('Demangle', 'std::string', [param('std::string const &', 'mangled')], is_static=True, visibility='protected') return def register_Ns3CallbackValue_methods(root_module, cls): ## callback.h (module 'core'): ns3::CallbackValue::CallbackValue(ns3::CallbackValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::CallbackValue const &', 'arg0')]) ## callback.h (module 'core'): ns3::CallbackValue::CallbackValue() [constructor] cls.add_constructor([]) ## callback.h (module 'core'): ns3::CallbackValue::CallbackValue(ns3::CallbackBase const & base) [constructor] cls.add_constructor([param('ns3::CallbackBase const &', 'base')]) ## callback.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::CallbackValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## callback.h (module 'core'): bool ns3::CallbackValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_virtual=True) ## callback.h (module 'core'): std::string ns3::CallbackValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True, is_virtual=True) ## callback.h (module 'core'): void ns3::CallbackValue::Set(ns3::CallbackBase base) [member function] cls.add_method('Set', 'void', [param('ns3::CallbackBase', 'base')]) return def register_Ns3ConstantRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::ConstantRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::ConstantRandomVariable::ConstantRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): double ns3::ConstantRandomVariable::GetConstant() const [member function] cls.add_method('GetConstant', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::ConstantRandomVariable::GetValue(double constant) [member function] cls.add_method('GetValue', 'double', [param('double', 'constant')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::ConstantRandomVariable::GetInteger(uint32_t constant) [member function] cls.add_method('GetInteger', 'uint32_t', [param('uint32_t', 'constant')]) ## random-variable-stream.h (module 'core'): double ns3::ConstantRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::ConstantRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3DeterministicRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::DeterministicRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::DeterministicRandomVariable::DeterministicRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): void ns3::DeterministicRandomVariable::SetValueArray(double * values, uint64_t length) [member function] cls.add_method('SetValueArray', 'void', [param('double *', 'values'), param('uint64_t', 'length')]) ## random-variable-stream.h (module 'core'): double ns3::DeterministicRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::DeterministicRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3EmpiricalRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): ns3::EmpiricalRandomVariable::EmpiricalRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): void ns3::EmpiricalRandomVariable::CDF(double v, double c) [member function] cls.add_method('CDF', 'void', [param('double', 'v'), param('double', 'c')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::EmpiricalRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::EmpiricalRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): double ns3::EmpiricalRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): double ns3::EmpiricalRandomVariable::Interpolate(double c1, double c2, double v1, double v2, double r) [member function] cls.add_method('Interpolate', 'double', [param('double', 'c1'), param('double', 'c2'), param('double', 'v1'), param('double', 'v2'), param('double', 'r')], visibility='private', is_virtual=True) ## random-variable-stream.h (module 'core'): void ns3::EmpiricalRandomVariable::Validate() [member function] cls.add_method('Validate', 'void', [], visibility='private', is_virtual=True) return def register_Ns3EmptyAttributeAccessor_methods(root_module, cls): ## attribute.h (module 'core'): ns3::EmptyAttributeAccessor::EmptyAttributeAccessor(ns3::EmptyAttributeAccessor const & arg0) [copy constructor] cls.add_constructor([param('ns3::EmptyAttributeAccessor const &', 'arg0')]) ## attribute.h (module 'core'): ns3::EmptyAttributeAccessor::EmptyAttributeAccessor() [constructor] cls.add_constructor([]) ## attribute.h (module 'core'): bool ns3::EmptyAttributeAccessor::Get(ns3::ObjectBase const * object, ns3::AttributeValue & attribute) const [member function] cls.add_method('Get', 'bool', [param('ns3::ObjectBase const *', 'object'), param('ns3::AttributeValue &', 'attribute')], is_const=True, is_virtual=True) ## attribute.h (module 'core'): bool ns3::EmptyAttributeAccessor::HasGetter() const [member function] cls.add_method('HasGetter', 'bool', [], is_const=True, is_virtual=True) ## attribute.h (module 'core'): bool ns3::EmptyAttributeAccessor::HasSetter() const [member function] cls.add_method('HasSetter', 'bool', [], is_const=True, is_virtual=True) ## attribute.h (module 'core'): bool ns3::EmptyAttributeAccessor::Set(ns3::ObjectBase * object, ns3::AttributeValue const & value) const [member function] cls.add_method('Set', 'bool', [param('ns3::ObjectBase *', 'object'), param('ns3::AttributeValue const &', 'value')], is_const=True, is_virtual=True) return def register_Ns3EmptyAttributeChecker_methods(root_module, cls): ## attribute.h (module 'core'): ns3::EmptyAttributeChecker::EmptyAttributeChecker(ns3::EmptyAttributeChecker const & arg0) [copy constructor] cls.add_constructor([param('ns3::EmptyAttributeChecker const &', 'arg0')]) ## attribute.h (module 'core'): ns3::EmptyAttributeChecker::EmptyAttributeChecker() [constructor] cls.add_constructor([]) ## attribute.h (module 'core'): bool ns3::EmptyAttributeChecker::Check(ns3::AttributeValue const & value) const [member function] cls.add_method('Check', 'bool', [param('ns3::AttributeValue const &', 'value')], is_const=True, is_virtual=True) ## attribute.h (module 'core'): bool ns3::EmptyAttributeChecker::Copy(ns3::AttributeValue const & source, ns3::AttributeValue & destination) const [member function] cls.add_method('Copy', 'bool', [param('ns3::AttributeValue const &', 'source'), param('ns3::AttributeValue &', 'destination')], is_const=True, is_virtual=True) ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::EmptyAttributeChecker::Create() const [member function] cls.add_method('Create', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## attribute.h (module 'core'): std::string ns3::EmptyAttributeChecker::GetUnderlyingTypeInformation() const [member function] cls.add_method('GetUnderlyingTypeInformation', 'std::string', [], is_const=True, is_virtual=True) ## attribute.h (module 'core'): std::string ns3::EmptyAttributeChecker::GetValueTypeName() const [member function] cls.add_method('GetValueTypeName', 'std::string', [], is_const=True, is_virtual=True) ## attribute.h (module 'core'): bool ns3::EmptyAttributeChecker::HasUnderlyingTypeInformation() const [member function] cls.add_method('HasUnderlyingTypeInformation', 'bool', [], is_const=True, is_virtual=True) return def register_Ns3EmptyAttributeValue_methods(root_module, cls): ## attribute.h (module 'core'): ns3::EmptyAttributeValue::EmptyAttributeValue(ns3::EmptyAttributeValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::EmptyAttributeValue const &', 'arg0')]) ## attribute.h (module 'core'): ns3::EmptyAttributeValue::EmptyAttributeValue() [constructor] cls.add_constructor([]) ## attribute.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::EmptyAttributeValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, visibility='private', is_virtual=True) ## attribute.h (module 'core'): bool ns3::EmptyAttributeValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], visibility='private', is_virtual=True) ## attribute.h (module 'core'): std::string ns3::EmptyAttributeValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True, visibility='private', is_virtual=True) return def register_Ns3EnumChecker_methods(root_module, cls): ## enum.h (module 'core'): ns3::EnumChecker::EnumChecker(ns3::EnumChecker const & arg0) [copy constructor] cls.add_constructor([param('ns3::EnumChecker const &', 'arg0')]) ## enum.h (module 'core'): ns3::EnumChecker::EnumChecker() [constructor] cls.add_constructor([]) ## enum.h (module 'core'): void ns3::EnumChecker::Add(int value, std::string name) [member function] cls.add_method('Add', 'void', [param('int', 'value'), param('std::string', 'name')]) ## enum.h (module 'core'): void ns3::EnumChecker::AddDefault(int value, std::string name) [member function] cls.add_method('AddDefault', 'void', [param('int', 'value'), param('std::string', 'name')]) ## enum.h (module 'core'): bool ns3::EnumChecker::Check(ns3::AttributeValue const & value) const [member function] cls.add_method('Check', 'bool', [param('ns3::AttributeValue const &', 'value')], is_const=True, is_virtual=True) ## enum.h (module 'core'): bool ns3::EnumChecker::Copy(ns3::AttributeValue const & src, ns3::AttributeValue & dst) const [member function] cls.add_method('Copy', 'bool', [param('ns3::AttributeValue const &', 'src'), param('ns3::AttributeValue &', 'dst')], is_const=True, is_virtual=True) ## enum.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::EnumChecker::Create() const [member function] cls.add_method('Create', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## enum.h (module 'core'): std::string ns3::EnumChecker::GetUnderlyingTypeInformation() const [member function] cls.add_method('GetUnderlyingTypeInformation', 'std::string', [], is_const=True, is_virtual=True) ## enum.h (module 'core'): std::string ns3::EnumChecker::GetValueTypeName() const [member function] cls.add_method('GetValueTypeName', 'std::string', [], is_const=True, is_virtual=True) ## enum.h (module 'core'): bool ns3::EnumChecker::HasUnderlyingTypeInformation() const [member function] cls.add_method('HasUnderlyingTypeInformation', 'bool', [], is_const=True, is_virtual=True) return def register_Ns3EnumValue_methods(root_module, cls): ## enum.h (module 'core'): ns3::EnumValue::EnumValue(ns3::EnumValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::EnumValue const &', 'arg0')]) ## enum.h (module 'core'): ns3::EnumValue::EnumValue() [constructor] cls.add_constructor([]) ## enum.h (module 'core'): ns3::EnumValue::EnumValue(int value) [constructor] cls.add_constructor([param('int', 'value')]) ## enum.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::EnumValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## enum.h (module 'core'): bool ns3::EnumValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_virtual=True) ## enum.h (module 'core'): int ns3::EnumValue::Get() const [member function] cls.add_method('Get', 'int', [], is_const=True) ## enum.h (module 'core'): std::string ns3::EnumValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True, is_virtual=True) ## enum.h (module 'core'): void ns3::EnumValue::Set(int value) [member function] cls.add_method('Set', 'void', [param('int', 'value')]) return def register_Ns3ErlangRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::ErlangRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::ErlangRandomVariable::ErlangRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): uint32_t ns3::ErlangRandomVariable::GetK() const [member function] cls.add_method('GetK', 'uint32_t', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::ErlangRandomVariable::GetLambda() const [member function] cls.add_method('GetLambda', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::ErlangRandomVariable::GetValue(uint32_t k, double lambda) [member function] cls.add_method('GetValue', 'double', [param('uint32_t', 'k'), param('double', 'lambda')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::ErlangRandomVariable::GetInteger(uint32_t k, uint32_t lambda) [member function] cls.add_method('GetInteger', 'uint32_t', [param('uint32_t', 'k'), param('uint32_t', 'lambda')]) ## random-variable-stream.h (module 'core'): double ns3::ErlangRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::ErlangRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3EventImpl_methods(root_module, cls): ## event-impl.h (module 'core'): ns3::EventImpl::EventImpl(ns3::EventImpl const & arg0) [copy constructor] cls.add_constructor([param('ns3::EventImpl const &', 'arg0')]) ## event-impl.h (module 'core'): ns3::EventImpl::EventImpl() [constructor] cls.add_constructor([]) ## event-impl.h (module 'core'): void ns3::EventImpl::Cancel() [member function] cls.add_method('Cancel', 'void', []) ## event-impl.h (module 'core'): void ns3::EventImpl::Invoke() [member function] cls.add_method('Invoke', 'void', []) ## event-impl.h (module 'core'): bool ns3::EventImpl::IsCancelled() [member function] cls.add_method('IsCancelled', 'bool', []) ## event-impl.h (module 'core'): void ns3::EventImpl::Notify() [member function] cls.add_method('Notify', 'void', [], is_pure_virtual=True, visibility='protected', is_virtual=True) return def register_Ns3ExponentialRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::ExponentialRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::ExponentialRandomVariable::ExponentialRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): double ns3::ExponentialRandomVariable::GetMean() const [member function] cls.add_method('GetMean', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::ExponentialRandomVariable::GetBound() const [member function] cls.add_method('GetBound', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::ExponentialRandomVariable::GetValue(double mean, double bound) [member function] cls.add_method('GetValue', 'double', [param('double', 'mean'), param('double', 'bound')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::ExponentialRandomVariable::GetInteger(uint32_t mean, uint32_t bound) [member function] cls.add_method('GetInteger', 'uint32_t', [param('uint32_t', 'mean'), param('uint32_t', 'bound')]) ## random-variable-stream.h (module 'core'): double ns3::ExponentialRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::ExponentialRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3GammaRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::GammaRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::GammaRandomVariable::GammaRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): double ns3::GammaRandomVariable::GetAlpha() const [member function] cls.add_method('GetAlpha', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::GammaRandomVariable::GetBeta() const [member function] cls.add_method('GetBeta', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::GammaRandomVariable::GetValue(double alpha, double beta) [member function] cls.add_method('GetValue', 'double', [param('double', 'alpha'), param('double', 'beta')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::GammaRandomVariable::GetInteger(uint32_t alpha, uint32_t beta) [member function] cls.add_method('GetInteger', 'uint32_t', [param('uint32_t', 'alpha'), param('uint32_t', 'beta')]) ## random-variable-stream.h (module 'core'): double ns3::GammaRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::GammaRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3Ipv4_methods(root_module, cls): ## ipv4.h (module 'internet'): ns3::Ipv4::Ipv4(ns3::Ipv4 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4 const &', 'arg0')]) ## ipv4.h (module 'internet'): ns3::Ipv4::Ipv4() [constructor] cls.add_constructor([]) ## ipv4.h (module 'internet'): bool ns3::Ipv4::AddAddress(uint32_t interface, ns3::Ipv4InterfaceAddress address) [member function] cls.add_method('AddAddress', 'bool', [param('uint32_t', 'interface'), param('ns3::Ipv4InterfaceAddress', 'address')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): uint32_t ns3::Ipv4::AddInterface(ns3::Ptr<ns3::NetDevice> device) [member function] cls.add_method('AddInterface', 'uint32_t', [param('ns3::Ptr< ns3::NetDevice >', 'device')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): ns3::Ptr<ns3::Socket> ns3::Ipv4::CreateRawSocket() [member function] cls.add_method('CreateRawSocket', 'ns3::Ptr< ns3::Socket >', [], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::DeleteRawSocket(ns3::Ptr<ns3::Socket> socket) [member function] cls.add_method('DeleteRawSocket', 'void', [param('ns3::Ptr< ns3::Socket >', 'socket')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): ns3::Ipv4InterfaceAddress ns3::Ipv4::GetAddress(uint32_t interface, uint32_t addressIndex) const [member function] cls.add_method('GetAddress', 'ns3::Ipv4InterfaceAddress', [param('uint32_t', 'interface'), param('uint32_t', 'addressIndex')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): int32_t ns3::Ipv4::GetInterfaceForAddress(ns3::Ipv4Address address) const [member function] cls.add_method('GetInterfaceForAddress', 'int32_t', [param('ns3::Ipv4Address', 'address')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): int32_t ns3::Ipv4::GetInterfaceForDevice(ns3::Ptr<const ns3::NetDevice> device) const [member function] cls.add_method('GetInterfaceForDevice', 'int32_t', [param('ns3::Ptr< ns3::NetDevice const >', 'device')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): int32_t ns3::Ipv4::GetInterfaceForPrefix(ns3::Ipv4Address address, ns3::Ipv4Mask mask) const [member function] cls.add_method('GetInterfaceForPrefix', 'int32_t', [param('ns3::Ipv4Address', 'address'), param('ns3::Ipv4Mask', 'mask')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): uint16_t ns3::Ipv4::GetMetric(uint32_t interface) const [member function] cls.add_method('GetMetric', 'uint16_t', [param('uint32_t', 'interface')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): uint16_t ns3::Ipv4::GetMtu(uint32_t interface) const [member function] cls.add_method('GetMtu', 'uint16_t', [param('uint32_t', 'interface')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): uint32_t ns3::Ipv4::GetNAddresses(uint32_t interface) const [member function] cls.add_method('GetNAddresses', 'uint32_t', [param('uint32_t', 'interface')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): uint32_t ns3::Ipv4::GetNInterfaces() const [member function] cls.add_method('GetNInterfaces', 'uint32_t', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): ns3::Ptr<ns3::NetDevice> ns3::Ipv4::GetNetDevice(uint32_t interface) [member function] cls.add_method('GetNetDevice', 'ns3::Ptr< ns3::NetDevice >', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): ns3::Ptr<ns3::IpL4Protocol> ns3::Ipv4::GetProtocol(int protocolNumber) const [member function] cls.add_method('GetProtocol', 'ns3::Ptr< ns3::IpL4Protocol >', [param('int', 'protocolNumber')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): ns3::Ptr<ns3::IpL4Protocol> ns3::Ipv4::GetProtocol(int protocolNumber, int32_t interfaceIndex) const [member function] cls.add_method('GetProtocol', 'ns3::Ptr< ns3::IpL4Protocol >', [param('int', 'protocolNumber'), param('int32_t', 'interfaceIndex')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): ns3::Ptr<ns3::Ipv4RoutingProtocol> ns3::Ipv4::GetRoutingProtocol() const [member function] cls.add_method('GetRoutingProtocol', 'ns3::Ptr< ns3::Ipv4RoutingProtocol >', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): static ns3::TypeId ns3::Ipv4::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::Insert(ns3::Ptr<ns3::IpL4Protocol> protocol) [member function] cls.add_method('Insert', 'void', [param('ns3::Ptr< ns3::IpL4Protocol >', 'protocol')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::Insert(ns3::Ptr<ns3::IpL4Protocol> protocol, uint32_t interfaceIndex) [member function] cls.add_method('Insert', 'void', [param('ns3::Ptr< ns3::IpL4Protocol >', 'protocol'), param('uint32_t', 'interfaceIndex')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): bool ns3::Ipv4::IsDestinationAddress(ns3::Ipv4Address address, uint32_t iif) const [member function] cls.add_method('IsDestinationAddress', 'bool', [param('ns3::Ipv4Address', 'address'), param('uint32_t', 'iif')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): bool ns3::Ipv4::IsForwarding(uint32_t interface) const [member function] cls.add_method('IsForwarding', 'bool', [param('uint32_t', 'interface')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): bool ns3::Ipv4::IsUp(uint32_t interface) const [member function] cls.add_method('IsUp', 'bool', [param('uint32_t', 'interface')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::Remove(ns3::Ptr<ns3::IpL4Protocol> protocol) [member function] cls.add_method('Remove', 'void', [param('ns3::Ptr< ns3::IpL4Protocol >', 'protocol')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::Remove(ns3::Ptr<ns3::IpL4Protocol> protocol, uint32_t interfaceIndex) [member function] cls.add_method('Remove', 'void', [param('ns3::Ptr< ns3::IpL4Protocol >', 'protocol'), param('uint32_t', 'interfaceIndex')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): bool ns3::Ipv4::RemoveAddress(uint32_t interface, uint32_t addressIndex) [member function] cls.add_method('RemoveAddress', 'bool', [param('uint32_t', 'interface'), param('uint32_t', 'addressIndex')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): bool ns3::Ipv4::RemoveAddress(uint32_t interface, ns3::Ipv4Address address) [member function] cls.add_method('RemoveAddress', 'bool', [param('uint32_t', 'interface'), param('ns3::Ipv4Address', 'address')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4::SelectSourceAddress(ns3::Ptr<const ns3::NetDevice> device, ns3::Ipv4Address dst, ns3::Ipv4InterfaceAddress::InterfaceAddressScope_e scope) [member function] cls.add_method('SelectSourceAddress', 'ns3::Ipv4Address', [param('ns3::Ptr< ns3::NetDevice const >', 'device'), param('ns3::Ipv4Address', 'dst'), param('ns3::Ipv4InterfaceAddress::InterfaceAddressScope_e', 'scope')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::Send(ns3::Ptr<ns3::Packet> packet, ns3::Ipv4Address source, ns3::Ipv4Address destination, uint8_t protocol, ns3::Ptr<ns3::Ipv4Route> route) [member function] cls.add_method('Send', 'void', [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv4Address', 'source'), param('ns3::Ipv4Address', 'destination'), param('uint8_t', 'protocol'), param('ns3::Ptr< ns3::Ipv4Route >', 'route')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::SendWithHeader(ns3::Ptr<ns3::Packet> packet, ns3::Ipv4Header ipHeader, ns3::Ptr<ns3::Ipv4Route> route) [member function] cls.add_method('SendWithHeader', 'void', [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv4Header', 'ipHeader'), param('ns3::Ptr< ns3::Ipv4Route >', 'route')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::SetDown(uint32_t interface) [member function] cls.add_method('SetDown', 'void', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::SetForwarding(uint32_t interface, bool val) [member function] cls.add_method('SetForwarding', 'void', [param('uint32_t', 'interface'), param('bool', 'val')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::SetMetric(uint32_t interface, uint16_t metric) [member function] cls.add_method('SetMetric', 'void', [param('uint32_t', 'interface'), param('uint16_t', 'metric')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::SetRoutingProtocol(ns3::Ptr<ns3::Ipv4RoutingProtocol> routingProtocol) [member function] cls.add_method('SetRoutingProtocol', 'void', [param('ns3::Ptr< ns3::Ipv4RoutingProtocol >', 'routingProtocol')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::SetUp(uint32_t interface) [member function] cls.add_method('SetUp', 'void', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4::SourceAddressSelection(uint32_t interface, ns3::Ipv4Address dest) [member function] cls.add_method('SourceAddressSelection', 'ns3::Ipv4Address', [param('uint32_t', 'interface'), param('ns3::Ipv4Address', 'dest')], is_pure_virtual=True, is_virtual=True) ## ipv4.h (module 'internet'): ns3::Ipv4::IF_ANY [variable] cls.add_static_attribute('IF_ANY', 'uint32_t const', is_const=True) ## ipv4.h (module 'internet'): bool ns3::Ipv4::GetIpForward() const [member function] cls.add_method('GetIpForward', 'bool', [], is_pure_virtual=True, is_const=True, visibility='private', is_virtual=True) ## ipv4.h (module 'internet'): bool ns3::Ipv4::GetWeakEsModel() const [member function] cls.add_method('GetWeakEsModel', 'bool', [], is_pure_virtual=True, is_const=True, visibility='private', is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::SetIpForward(bool forward) [member function] cls.add_method('SetIpForward', 'void', [param('bool', 'forward')], is_pure_virtual=True, visibility='private', is_virtual=True) ## ipv4.h (module 'internet'): void ns3::Ipv4::SetWeakEsModel(bool model) [member function] cls.add_method('SetWeakEsModel', 'void', [param('bool', 'model')], is_pure_virtual=True, visibility='private', is_virtual=True) return def register_Ns3Ipv4AddressChecker_methods(root_module, cls): ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker::Ipv4AddressChecker() [constructor] cls.add_constructor([]) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressChecker::Ipv4AddressChecker(ns3::Ipv4AddressChecker const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4AddressChecker const &', 'arg0')]) return def register_Ns3Ipv4AddressValue_methods(root_module, cls): ## ipv4-address.h (module 'network'): ns3::Ipv4AddressValue::Ipv4AddressValue() [constructor] cls.add_constructor([]) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressValue::Ipv4AddressValue(ns3::Ipv4AddressValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4AddressValue const &', 'arg0')]) ## ipv4-address.h (module 'network'): ns3::Ipv4AddressValue::Ipv4AddressValue(ns3::Ipv4Address const & value) [constructor] cls.add_constructor([param('ns3::Ipv4Address const &', 'value')]) ## ipv4-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Ipv4AddressValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## ipv4-address.h (module 'network'): bool ns3::Ipv4AddressValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_virtual=True) ## ipv4-address.h (module 'network'): ns3::Ipv4Address ns3::Ipv4AddressValue::Get() const [member function] cls.add_method('Get', 'ns3::Ipv4Address', [], is_const=True) ## ipv4-address.h (module 'network'): std::string ns3::Ipv4AddressValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True, is_virtual=True) ## ipv4-address.h (module 'network'): void ns3::Ipv4AddressValue::Set(ns3::Ipv4Address const & value) [member function] cls.add_method('Set', 'void', [param('ns3::Ipv4Address const &', 'value')]) return def register_Ns3Ipv4Interface_methods(root_module, cls): ## ipv4-interface.h (module 'internet'): static ns3::TypeId ns3::Ipv4Interface::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## ipv4-interface.h (module 'internet'): ns3::Ipv4Interface::Ipv4Interface() [constructor] cls.add_constructor([]) ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetNode(ns3::Ptr<ns3::Node> node) [member function] cls.add_method('SetNode', 'void', [param('ns3::Ptr< ns3::Node >', 'node')]) ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetDevice(ns3::Ptr<ns3::NetDevice> device) [member function] cls.add_method('SetDevice', 'void', [param('ns3::Ptr< ns3::NetDevice >', 'device')]) ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetTrafficControl(ns3::Ptr<ns3::TrafficControlLayer> tc) [member function] cls.add_method('SetTrafficControl', 'void', [param('ns3::Ptr< ns3::TrafficControlLayer >', 'tc')]) ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetArpCache(ns3::Ptr<ns3::ArpCache> arpCache) [member function] cls.add_method('SetArpCache', 'void', [param('ns3::Ptr< ns3::ArpCache >', 'arpCache')]) ## ipv4-interface.h (module 'internet'): ns3::Ptr<ns3::NetDevice> ns3::Ipv4Interface::GetDevice() const [member function] cls.add_method('GetDevice', 'ns3::Ptr< ns3::NetDevice >', [], is_const=True) ## ipv4-interface.h (module 'internet'): ns3::Ptr<ns3::ArpCache> ns3::Ipv4Interface::GetArpCache() const [member function] cls.add_method('GetArpCache', 'ns3::Ptr< ns3::ArpCache >', [], is_const=True) ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetMetric(uint16_t metric) [member function] cls.add_method('SetMetric', 'void', [param('uint16_t', 'metric')]) ## ipv4-interface.h (module 'internet'): uint16_t ns3::Ipv4Interface::GetMetric() const [member function] cls.add_method('GetMetric', 'uint16_t', [], is_const=True) ## ipv4-interface.h (module 'internet'): bool ns3::Ipv4Interface::IsUp() const [member function] cls.add_method('IsUp', 'bool', [], is_const=True) ## ipv4-interface.h (module 'internet'): bool ns3::Ipv4Interface::IsDown() const [member function] cls.add_method('IsDown', 'bool', [], is_const=True) ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetUp() [member function] cls.add_method('SetUp', 'void', []) ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetDown() [member function] cls.add_method('SetDown', 'void', []) ## ipv4-interface.h (module 'internet'): bool ns3::Ipv4Interface::IsForwarding() const [member function] cls.add_method('IsForwarding', 'bool', [], is_const=True) ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::SetForwarding(bool val) [member function] cls.add_method('SetForwarding', 'void', [param('bool', 'val')]) ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::Send(ns3::Ptr<ns3::Packet> p, ns3::Ipv4Header const & hdr, ns3::Ipv4Address dest) [member function] cls.add_method('Send', 'void', [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'hdr'), param('ns3::Ipv4Address', 'dest')]) ## ipv4-interface.h (module 'internet'): bool ns3::Ipv4Interface::AddAddress(ns3::Ipv4InterfaceAddress address) [member function] cls.add_method('AddAddress', 'bool', [param('ns3::Ipv4InterfaceAddress', 'address')]) ## ipv4-interface.h (module 'internet'): ns3::Ipv4InterfaceAddress ns3::Ipv4Interface::GetAddress(uint32_t index) const [member function] cls.add_method('GetAddress', 'ns3::Ipv4InterfaceAddress', [param('uint32_t', 'index')], is_const=True) ## ipv4-interface.h (module 'internet'): uint32_t ns3::Ipv4Interface::GetNAddresses() const [member function] cls.add_method('GetNAddresses', 'uint32_t', [], is_const=True) ## ipv4-interface.h (module 'internet'): ns3::Ipv4InterfaceAddress ns3::Ipv4Interface::RemoveAddress(uint32_t index) [member function] cls.add_method('RemoveAddress', 'ns3::Ipv4InterfaceAddress', [param('uint32_t', 'index')]) ## ipv4-interface.h (module 'internet'): ns3::Ipv4InterfaceAddress ns3::Ipv4Interface::RemoveAddress(ns3::Ipv4Address address) [member function] cls.add_method('RemoveAddress', 'ns3::Ipv4InterfaceAddress', [param('ns3::Ipv4Address', 'address')]) ## ipv4-interface.h (module 'internet'): void ns3::Ipv4Interface::DoDispose() [member function] cls.add_method('DoDispose', 'void', [], visibility='protected', is_virtual=True) return def register_Ns3Ipv4L3Protocol_methods(root_module, cls): ## ipv4-l3-protocol.h (module 'internet'): ns3::Ipv4L3Protocol::Ipv4L3Protocol() [constructor] cls.add_constructor([]) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::AddAddress(uint32_t i, ns3::Ipv4InterfaceAddress address) [member function] cls.add_method('AddAddress', 'bool', [param('uint32_t', 'i'), param('ns3::Ipv4InterfaceAddress', 'address')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): uint32_t ns3::Ipv4L3Protocol::AddInterface(ns3::Ptr<ns3::NetDevice> device) [member function] cls.add_method('AddInterface', 'uint32_t', [param('ns3::Ptr< ns3::NetDevice >', 'device')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): ns3::Ptr<ns3::Socket> ns3::Ipv4L3Protocol::CreateRawSocket() [member function] cls.add_method('CreateRawSocket', 'ns3::Ptr< ns3::Socket >', [], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::DeleteRawSocket(ns3::Ptr<ns3::Socket> socket) [member function] cls.add_method('DeleteRawSocket', 'void', [param('ns3::Ptr< ns3::Socket >', 'socket')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): ns3::Ipv4InterfaceAddress ns3::Ipv4L3Protocol::GetAddress(uint32_t interfaceIndex, uint32_t addressIndex) const [member function] cls.add_method('GetAddress', 'ns3::Ipv4InterfaceAddress', [param('uint32_t', 'interfaceIndex'), param('uint32_t', 'addressIndex')], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): ns3::Ptr<ns3::Ipv4Interface> ns3::Ipv4L3Protocol::GetInterface(uint32_t i) const [member function] cls.add_method('GetInterface', 'ns3::Ptr< ns3::Ipv4Interface >', [param('uint32_t', 'i')], is_const=True) ## ipv4-l3-protocol.h (module 'internet'): int32_t ns3::Ipv4L3Protocol::GetInterfaceForAddress(ns3::Ipv4Address addr) const [member function] cls.add_method('GetInterfaceForAddress', 'int32_t', [param('ns3::Ipv4Address', 'addr')], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): int32_t ns3::Ipv4L3Protocol::GetInterfaceForDevice(ns3::Ptr<const ns3::NetDevice> device) const [member function] cls.add_method('GetInterfaceForDevice', 'int32_t', [param('ns3::Ptr< ns3::NetDevice const >', 'device')], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): int32_t ns3::Ipv4L3Protocol::GetInterfaceForPrefix(ns3::Ipv4Address addr, ns3::Ipv4Mask mask) const [member function] cls.add_method('GetInterfaceForPrefix', 'int32_t', [param('ns3::Ipv4Address', 'addr'), param('ns3::Ipv4Mask', 'mask')], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): uint16_t ns3::Ipv4L3Protocol::GetMetric(uint32_t i) const [member function] cls.add_method('GetMetric', 'uint16_t', [param('uint32_t', 'i')], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): uint16_t ns3::Ipv4L3Protocol::GetMtu(uint32_t i) const [member function] cls.add_method('GetMtu', 'uint16_t', [param('uint32_t', 'i')], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): uint32_t ns3::Ipv4L3Protocol::GetNAddresses(uint32_t interface) const [member function] cls.add_method('GetNAddresses', 'uint32_t', [param('uint32_t', 'interface')], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): uint32_t ns3::Ipv4L3Protocol::GetNInterfaces() const [member function] cls.add_method('GetNInterfaces', 'uint32_t', [], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): ns3::Ptr<ns3::NetDevice> ns3::Ipv4L3Protocol::GetNetDevice(uint32_t i) [member function] cls.add_method('GetNetDevice', 'ns3::Ptr< ns3::NetDevice >', [param('uint32_t', 'i')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): ns3::Ptr<ns3::IpL4Protocol> ns3::Ipv4L3Protocol::GetProtocol(int protocolNumber) const [member function] cls.add_method('GetProtocol', 'ns3::Ptr< ns3::IpL4Protocol >', [param('int', 'protocolNumber')], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): ns3::Ptr<ns3::IpL4Protocol> ns3::Ipv4L3Protocol::GetProtocol(int protocolNumber, int32_t interfaceIndex) const [member function] cls.add_method('GetProtocol', 'ns3::Ptr< ns3::IpL4Protocol >', [param('int', 'protocolNumber'), param('int32_t', 'interfaceIndex')], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): ns3::Ptr<ns3::Ipv4RoutingProtocol> ns3::Ipv4L3Protocol::GetRoutingProtocol() const [member function] cls.add_method('GetRoutingProtocol', 'ns3::Ptr< ns3::Ipv4RoutingProtocol >', [], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): static ns3::TypeId ns3::Ipv4L3Protocol::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::Insert(ns3::Ptr<ns3::IpL4Protocol> protocol) [member function] cls.add_method('Insert', 'void', [param('ns3::Ptr< ns3::IpL4Protocol >', 'protocol')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::Insert(ns3::Ptr<ns3::IpL4Protocol> protocol, uint32_t interfaceIndex) [member function] cls.add_method('Insert', 'void', [param('ns3::Ptr< ns3::IpL4Protocol >', 'protocol'), param('uint32_t', 'interfaceIndex')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsDestinationAddress(ns3::Ipv4Address address, uint32_t iif) const [member function] cls.add_method('IsDestinationAddress', 'bool', [param('ns3::Ipv4Address', 'address'), param('uint32_t', 'iif')], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsForwarding(uint32_t i) const [member function] cls.add_method('IsForwarding', 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUnicast(ns3::Ipv4Address ad) const [member function] cls.add_method('IsUnicast', 'bool', [param('ns3::Ipv4Address', 'ad')], is_const=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::IsUp(uint32_t i) const [member function] cls.add_method('IsUp', 'bool', [param('uint32_t', 'i')], is_const=True, is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::Receive(ns3::Ptr<ns3::NetDevice> device, ns3::Ptr<ns3::Packet const> p, uint16_t protocol, ns3::Address const & from, ns3::Address const & to, ns3::NetDevice::PacketType packetType) [member function] cls.add_method('Receive', 'void', [param('ns3::Ptr< ns3::NetDevice >', 'device'), param('ns3::Ptr< ns3::Packet const >', 'p'), param('uint16_t', 'protocol'), param('ns3::Address const &', 'from'), param('ns3::Address const &', 'to'), param('ns3::NetDevice::PacketType', 'packetType')]) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::Remove(ns3::Ptr<ns3::IpL4Protocol> protocol) [member function] cls.add_method('Remove', 'void', [param('ns3::Ptr< ns3::IpL4Protocol >', 'protocol')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::Remove(ns3::Ptr<ns3::IpL4Protocol> protocol, uint32_t interfaceIndex) [member function] cls.add_method('Remove', 'void', [param('ns3::Ptr< ns3::IpL4Protocol >', 'protocol'), param('uint32_t', 'interfaceIndex')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::RemoveAddress(uint32_t interfaceIndex, uint32_t addressIndex) [member function] cls.add_method('RemoveAddress', 'bool', [param('uint32_t', 'interfaceIndex'), param('uint32_t', 'addressIndex')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::RemoveAddress(uint32_t interface, ns3::Ipv4Address address) [member function] cls.add_method('RemoveAddress', 'bool', [param('uint32_t', 'interface'), param('ns3::Ipv4Address', 'address')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4L3Protocol::SelectSourceAddress(ns3::Ptr<const ns3::NetDevice> device, ns3::Ipv4Address dst, ns3::Ipv4InterfaceAddress::InterfaceAddressScope_e scope) [member function] cls.add_method('SelectSourceAddress', 'ns3::Ipv4Address', [param('ns3::Ptr< ns3::NetDevice const >', 'device'), param('ns3::Ipv4Address', 'dst'), param('ns3::Ipv4InterfaceAddress::InterfaceAddressScope_e', 'scope')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::Send(ns3::Ptr<ns3::Packet> packet, ns3::Ipv4Address source, ns3::Ipv4Address destination, uint8_t protocol, ns3::Ptr<ns3::Ipv4Route> route) [member function] cls.add_method('Send', 'void', [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv4Address', 'source'), param('ns3::Ipv4Address', 'destination'), param('uint8_t', 'protocol'), param('ns3::Ptr< ns3::Ipv4Route >', 'route')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::SendWithHeader(ns3::Ptr<ns3::Packet> packet, ns3::Ipv4Header ipHeader, ns3::Ptr<ns3::Ipv4Route> route) [member function] cls.add_method('SendWithHeader', 'void', [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Ipv4Header', 'ipHeader'), param('ns3::Ptr< ns3::Ipv4Route >', 'route')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::SetDefaultTtl(uint8_t ttl) [member function] cls.add_method('SetDefaultTtl', 'void', [param('uint8_t', 'ttl')]) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::SetDown(uint32_t i) [member function] cls.add_method('SetDown', 'void', [param('uint32_t', 'i')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::SetForwarding(uint32_t i, bool val) [member function] cls.add_method('SetForwarding', 'void', [param('uint32_t', 'i'), param('bool', 'val')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::SetMetric(uint32_t i, uint16_t metric) [member function] cls.add_method('SetMetric', 'void', [param('uint32_t', 'i'), param('uint16_t', 'metric')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::SetNode(ns3::Ptr<ns3::Node> node) [member function] cls.add_method('SetNode', 'void', [param('ns3::Ptr< ns3::Node >', 'node')]) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::SetRoutingProtocol(ns3::Ptr<ns3::Ipv4RoutingProtocol> routingProtocol) [member function] cls.add_method('SetRoutingProtocol', 'void', [param('ns3::Ptr< ns3::Ipv4RoutingProtocol >', 'routingProtocol')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::SetUp(uint32_t i) [member function] cls.add_method('SetUp', 'void', [param('uint32_t', 'i')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4L3Protocol::SourceAddressSelection(uint32_t interface, ns3::Ipv4Address dest) [member function] cls.add_method('SourceAddressSelection', 'ns3::Ipv4Address', [param('uint32_t', 'interface'), param('ns3::Ipv4Address', 'dest')], is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): ns3::Ipv4L3Protocol::PROT_NUMBER [variable] cls.add_static_attribute('PROT_NUMBER', 'uint16_t const', is_const=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::DoDispose() [member function] cls.add_method('DoDispose', 'void', [], visibility='protected', is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::NotifyNewAggregate() [member function] cls.add_method('NotifyNewAggregate', 'void', [], visibility='protected', is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::GetIpForward() const [member function] cls.add_method('GetIpForward', 'bool', [], is_const=True, visibility='private', is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): bool ns3::Ipv4L3Protocol::GetWeakEsModel() const [member function] cls.add_method('GetWeakEsModel', 'bool', [], is_const=True, visibility='private', is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::SetIpForward(bool forward) [member function] cls.add_method('SetIpForward', 'void', [param('bool', 'forward')], visibility='private', is_virtual=True) ## ipv4-l3-protocol.h (module 'internet'): void ns3::Ipv4L3Protocol::SetWeakEsModel(bool model) [member function] cls.add_method('SetWeakEsModel', 'void', [param('bool', 'model')], visibility='private', is_virtual=True) return def register_Ns3Ipv4MaskChecker_methods(root_module, cls): ## ipv4-address.h (module 'network'): ns3::Ipv4MaskChecker::Ipv4MaskChecker() [constructor] cls.add_constructor([]) ## ipv4-address.h (module 'network'): ns3::Ipv4MaskChecker::Ipv4MaskChecker(ns3::Ipv4MaskChecker const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4MaskChecker const &', 'arg0')]) return def register_Ns3Ipv4MaskValue_methods(root_module, cls): ## ipv4-address.h (module 'network'): ns3::Ipv4MaskValue::Ipv4MaskValue() [constructor] cls.add_constructor([]) ## ipv4-address.h (module 'network'): ns3::Ipv4MaskValue::Ipv4MaskValue(ns3::Ipv4MaskValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4MaskValue const &', 'arg0')]) ## ipv4-address.h (module 'network'): ns3::Ipv4MaskValue::Ipv4MaskValue(ns3::Ipv4Mask const & value) [constructor] cls.add_constructor([param('ns3::Ipv4Mask const &', 'value')]) ## ipv4-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Ipv4MaskValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## ipv4-address.h (module 'network'): bool ns3::Ipv4MaskValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_virtual=True) ## ipv4-address.h (module 'network'): ns3::Ipv4Mask ns3::Ipv4MaskValue::Get() const [member function] cls.add_method('Get', 'ns3::Ipv4Mask', [], is_const=True) ## ipv4-address.h (module 'network'): std::string ns3::Ipv4MaskValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True, is_virtual=True) ## ipv4-address.h (module 'network'): void ns3::Ipv4MaskValue::Set(ns3::Ipv4Mask const & value) [member function] cls.add_method('Set', 'void', [param('ns3::Ipv4Mask const &', 'value')]) return def register_Ns3Ipv4MulticastRoute_methods(root_module, cls): ## ipv4-route.h (module 'internet'): ns3::Ipv4MulticastRoute::Ipv4MulticastRoute(ns3::Ipv4MulticastRoute const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4MulticastRoute const &', 'arg0')]) ## ipv4-route.h (module 'internet'): ns3::Ipv4MulticastRoute::Ipv4MulticastRoute() [constructor] cls.add_constructor([]) ## ipv4-route.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4MulticastRoute::GetGroup() const [member function] cls.add_method('GetGroup', 'ns3::Ipv4Address', [], is_const=True) ## ipv4-route.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4MulticastRoute::GetOrigin() const [member function] cls.add_method('GetOrigin', 'ns3::Ipv4Address', [], is_const=True) ## ipv4-route.h (module 'internet'): std::map<unsigned int, unsigned int, std::less<unsigned int>, std::allocator<std::pair<unsigned int const, unsigned int> > > ns3::Ipv4MulticastRoute::GetOutputTtlMap() const [member function] cls.add_method('GetOutputTtlMap', 'std::map< unsigned int, unsigned int >', [], is_const=True) ## ipv4-route.h (module 'internet'): uint32_t ns3::Ipv4MulticastRoute::GetParent() const [member function] cls.add_method('GetParent', 'uint32_t', [], is_const=True) ## ipv4-route.h (module 'internet'): void ns3::Ipv4MulticastRoute::SetGroup(ns3::Ipv4Address const group) [member function] cls.add_method('SetGroup', 'void', [param('ns3::Ipv4Address const', 'group')]) ## ipv4-route.h (module 'internet'): void ns3::Ipv4MulticastRoute::SetOrigin(ns3::Ipv4Address const origin) [member function] cls.add_method('SetOrigin', 'void', [param('ns3::Ipv4Address const', 'origin')]) ## ipv4-route.h (module 'internet'): void ns3::Ipv4MulticastRoute::SetOutputTtl(uint32_t oif, uint32_t ttl) [member function] cls.add_method('SetOutputTtl', 'void', [param('uint32_t', 'oif'), param('uint32_t', 'ttl')]) ## ipv4-route.h (module 'internet'): void ns3::Ipv4MulticastRoute::SetParent(uint32_t iif) [member function] cls.add_method('SetParent', 'void', [param('uint32_t', 'iif')]) ## ipv4-route.h (module 'internet'): ns3::Ipv4MulticastRoute::MAX_INTERFACES [variable] cls.add_static_attribute('MAX_INTERFACES', 'uint32_t const', is_const=True) ## ipv4-route.h (module 'internet'): ns3::Ipv4MulticastRoute::MAX_TTL [variable] cls.add_static_attribute('MAX_TTL', 'uint32_t const', is_const=True) return def register_Ns3Ipv4Route_methods(root_module, cls): cls.add_output_stream_operator() ## ipv4-route.h (module 'internet'): ns3::Ipv4Route::Ipv4Route(ns3::Ipv4Route const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4Route const &', 'arg0')]) ## ipv4-route.h (module 'internet'): ns3::Ipv4Route::Ipv4Route() [constructor] cls.add_constructor([]) ## ipv4-route.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4Route::GetDestination() const [member function] cls.add_method('GetDestination', 'ns3::Ipv4Address', [], is_const=True) ## ipv4-route.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4Route::GetGateway() const [member function] cls.add_method('GetGateway', 'ns3::Ipv4Address', [], is_const=True) ## ipv4-route.h (module 'internet'): ns3::Ptr<ns3::NetDevice> ns3::Ipv4Route::GetOutputDevice() const [member function] cls.add_method('GetOutputDevice', 'ns3::Ptr< ns3::NetDevice >', [], is_const=True) ## ipv4-route.h (module 'internet'): ns3::Ipv4Address ns3::Ipv4Route::GetSource() const [member function] cls.add_method('GetSource', 'ns3::Ipv4Address', [], is_const=True) ## ipv4-route.h (module 'internet'): void ns3::Ipv4Route::SetDestination(ns3::Ipv4Address dest) [member function] cls.add_method('SetDestination', 'void', [param('ns3::Ipv4Address', 'dest')]) ## ipv4-route.h (module 'internet'): void ns3::Ipv4Route::SetGateway(ns3::Ipv4Address gw) [member function] cls.add_method('SetGateway', 'void', [param('ns3::Ipv4Address', 'gw')]) ## ipv4-route.h (module 'internet'): void ns3::Ipv4Route::SetOutputDevice(ns3::Ptr<ns3::NetDevice> outputDevice) [member function] cls.add_method('SetOutputDevice', 'void', [param('ns3::Ptr< ns3::NetDevice >', 'outputDevice')]) ## ipv4-route.h (module 'internet'): void ns3::Ipv4Route::SetSource(ns3::Ipv4Address src) [member function] cls.add_method('SetSource', 'void', [param('ns3::Ipv4Address', 'src')]) return def register_Ns3Ipv4RoutingProtocol_methods(root_module, cls): ## ipv4-routing-protocol.h (module 'internet'): ns3::Ipv4RoutingProtocol::Ipv4RoutingProtocol() [constructor] cls.add_constructor([]) ## ipv4-routing-protocol.h (module 'internet'): ns3::Ipv4RoutingProtocol::Ipv4RoutingProtocol(ns3::Ipv4RoutingProtocol const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4RoutingProtocol const &', 'arg0')]) ## ipv4-routing-protocol.h (module 'internet'): static ns3::TypeId ns3::Ipv4RoutingProtocol::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## ipv4-routing-protocol.h (module 'internet'): void ns3::Ipv4RoutingProtocol::NotifyAddAddress(uint32_t interface, ns3::Ipv4InterfaceAddress address) [member function] cls.add_method('NotifyAddAddress', 'void', [param('uint32_t', 'interface'), param('ns3::Ipv4InterfaceAddress', 'address')], is_pure_virtual=True, is_virtual=True) ## ipv4-routing-protocol.h (module 'internet'): void ns3::Ipv4RoutingProtocol::NotifyInterfaceDown(uint32_t interface) [member function] cls.add_method('NotifyInterfaceDown', 'void', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) ## ipv4-routing-protocol.h (module 'internet'): void ns3::Ipv4RoutingProtocol::NotifyInterfaceUp(uint32_t interface) [member function] cls.add_method('NotifyInterfaceUp', 'void', [param('uint32_t', 'interface')], is_pure_virtual=True, is_virtual=True) ## ipv4-routing-protocol.h (module 'internet'): void ns3::Ipv4RoutingProtocol::NotifyRemoveAddress(uint32_t interface, ns3::Ipv4InterfaceAddress address) [member function] cls.add_method('NotifyRemoveAddress', 'void', [param('uint32_t', 'interface'), param('ns3::Ipv4InterfaceAddress', 'address')], is_pure_virtual=True, is_virtual=True) ## ipv4-routing-protocol.h (module 'internet'): void ns3::Ipv4RoutingProtocol::PrintRoutingTable(ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::Time::Unit unit=::ns3::Time::S) const [member function] cls.add_method('PrintRoutingTable', 'void', [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::Time::Unit', 'unit', default_value='::ns3::Time::S')], is_pure_virtual=True, is_const=True, is_virtual=True) ## ipv4-routing-protocol.h (module 'internet'): bool ns3::Ipv4RoutingProtocol::RouteInput(ns3::Ptr<ns3::Packet const> p, ns3::Ipv4Header const & header, ns3::Ptr<const ns3::NetDevice> idev, ns3::Callback<void, ns3::Ptr<ns3::Ipv4Route>, ns3::Ptr<ns3::Packet const>, ns3::Ipv4Header const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ucb, ns3::Callback<void,ns3::Ptr<ns3::Ipv4MulticastRoute>,ns3::Ptr<const ns3::Packet>,const ns3::Ipv4Header&,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> mcb, ns3::Callback<void,ns3::Ptr<const ns3::Packet>,const ns3::Ipv4Header&,unsigned int,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> lcb, ns3::Callback<void, ns3::Ptr<ns3::Packet const>, ns3::Ipv4Header const&, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ecb) [member function] cls.add_method('RouteInput', 'bool', [param('ns3::Ptr< ns3::Packet const >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::NetDevice const >', 'idev'), param('ns3::Callback< void, ns3::Ptr< ns3::Ipv4Route >, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ucb'), param('ns3::Callback< void, ns3::Ptr< ns3::Ipv4MulticastRoute >, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'mcb'), param('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, unsigned int, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'lcb'), param('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ecb')], is_pure_virtual=True, is_virtual=True) ## ipv4-routing-protocol.h (module 'internet'): ns3::Ptr<ns3::Ipv4Route> ns3::Ipv4RoutingProtocol::RouteOutput(ns3::Ptr<ns3::Packet> p, ns3::Ipv4Header const & header, ns3::Ptr<ns3::NetDevice> oif, ns3::Socket::SocketErrno & sockerr) [member function] cls.add_method('RouteOutput', 'ns3::Ptr< ns3::Ipv4Route >', [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::NetDevice >', 'oif'), param('ns3::Socket::SocketErrno &', 'sockerr')], is_pure_virtual=True, is_virtual=True) ## ipv4-routing-protocol.h (module 'internet'): void ns3::Ipv4RoutingProtocol::SetIpv4(ns3::Ptr<ns3::Ipv4> ipv4) [member function] cls.add_method('SetIpv4', 'void', [param('ns3::Ptr< ns3::Ipv4 >', 'ipv4')], is_pure_virtual=True, is_virtual=True) return def register_Ns3Ipv6AddressChecker_methods(root_module, cls): ## ipv6-address.h (module 'network'): ns3::Ipv6AddressChecker::Ipv6AddressChecker() [constructor] cls.add_constructor([]) ## ipv6-address.h (module 'network'): ns3::Ipv6AddressChecker::Ipv6AddressChecker(ns3::Ipv6AddressChecker const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv6AddressChecker const &', 'arg0')]) return def register_Ns3Ipv6AddressValue_methods(root_module, cls): ## ipv6-address.h (module 'network'): ns3::Ipv6AddressValue::Ipv6AddressValue() [constructor] cls.add_constructor([]) ## ipv6-address.h (module 'network'): ns3::Ipv6AddressValue::Ipv6AddressValue(ns3::Ipv6AddressValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv6AddressValue const &', 'arg0')]) ## ipv6-address.h (module 'network'): ns3::Ipv6AddressValue::Ipv6AddressValue(ns3::Ipv6Address const & value) [constructor] cls.add_constructor([param('ns3::Ipv6Address const &', 'value')]) ## ipv6-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Ipv6AddressValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6AddressValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_virtual=True) ## ipv6-address.h (module 'network'): ns3::Ipv6Address ns3::Ipv6AddressValue::Get() const [member function] cls.add_method('Get', 'ns3::Ipv6Address', [], is_const=True) ## ipv6-address.h (module 'network'): std::string ns3::Ipv6AddressValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True, is_virtual=True) ## ipv6-address.h (module 'network'): void ns3::Ipv6AddressValue::Set(ns3::Ipv6Address const & value) [member function] cls.add_method('Set', 'void', [param('ns3::Ipv6Address const &', 'value')]) return def register_Ns3Ipv6PrefixChecker_methods(root_module, cls): ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker::Ipv6PrefixChecker() [constructor] cls.add_constructor([]) ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixChecker::Ipv6PrefixChecker(ns3::Ipv6PrefixChecker const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv6PrefixChecker const &', 'arg0')]) return def register_Ns3Ipv6PrefixValue_methods(root_module, cls): ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixValue::Ipv6PrefixValue() [constructor] cls.add_constructor([]) ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixValue::Ipv6PrefixValue(ns3::Ipv6PrefixValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv6PrefixValue const &', 'arg0')]) ## ipv6-address.h (module 'network'): ns3::Ipv6PrefixValue::Ipv6PrefixValue(ns3::Ipv6Prefix const & value) [constructor] cls.add_constructor([param('ns3::Ipv6Prefix const &', 'value')]) ## ipv6-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Ipv6PrefixValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## ipv6-address.h (module 'network'): bool ns3::Ipv6PrefixValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_virtual=True) ## ipv6-address.h (module 'network'): ns3::Ipv6Prefix ns3::Ipv6PrefixValue::Get() const [member function] cls.add_method('Get', 'ns3::Ipv6Prefix', [], is_const=True) ## ipv6-address.h (module 'network'): std::string ns3::Ipv6PrefixValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True, is_virtual=True) ## ipv6-address.h (module 'network'): void ns3::Ipv6PrefixValue::Set(ns3::Ipv6Prefix const & value) [member function] cls.add_method('Set', 'void', [param('ns3::Ipv6Prefix const &', 'value')]) return def register_Ns3LogNormalRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::LogNormalRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::LogNormalRandomVariable::LogNormalRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): double ns3::LogNormalRandomVariable::GetMu() const [member function] cls.add_method('GetMu', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::LogNormalRandomVariable::GetSigma() const [member function] cls.add_method('GetSigma', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::LogNormalRandomVariable::GetValue(double mu, double sigma) [member function] cls.add_method('GetValue', 'double', [param('double', 'mu'), param('double', 'sigma')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::LogNormalRandomVariable::GetInteger(uint32_t mu, uint32_t sigma) [member function] cls.add_method('GetInteger', 'uint32_t', [param('uint32_t', 'mu'), param('uint32_t', 'sigma')]) ## random-variable-stream.h (module 'core'): double ns3::LogNormalRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::LogNormalRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3Mac48AddressChecker_methods(root_module, cls): ## mac48-address.h (module 'network'): ns3::Mac48AddressChecker::Mac48AddressChecker() [constructor] cls.add_constructor([]) ## mac48-address.h (module 'network'): ns3::Mac48AddressChecker::Mac48AddressChecker(ns3::Mac48AddressChecker const & arg0) [copy constructor] cls.add_constructor([param('ns3::Mac48AddressChecker const &', 'arg0')]) return def register_Ns3Mac48AddressValue_methods(root_module, cls): ## mac48-address.h (module 'network'): ns3::Mac48AddressValue::Mac48AddressValue() [constructor] cls.add_constructor([]) ## mac48-address.h (module 'network'): ns3::Mac48AddressValue::Mac48AddressValue(ns3::Mac48AddressValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::Mac48AddressValue const &', 'arg0')]) ## mac48-address.h (module 'network'): ns3::Mac48AddressValue::Mac48AddressValue(ns3::Mac48Address const & value) [constructor] cls.add_constructor([param('ns3::Mac48Address const &', 'value')]) ## mac48-address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::Mac48AddressValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## mac48-address.h (module 'network'): bool ns3::Mac48AddressValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_virtual=True) ## mac48-address.h (module 'network'): ns3::Mac48Address ns3::Mac48AddressValue::Get() const [member function] cls.add_method('Get', 'ns3::Mac48Address', [], is_const=True) ## mac48-address.h (module 'network'): std::string ns3::Mac48AddressValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True, is_virtual=True) ## mac48-address.h (module 'network'): void ns3::Mac48AddressValue::Set(ns3::Mac48Address const & value) [member function] cls.add_method('Set', 'void', [param('ns3::Mac48Address const &', 'value')]) return def register_Ns3NetDevice_methods(root_module, cls): ## net-device.h (module 'network'): ns3::NetDevice::NetDevice() [constructor] cls.add_constructor([]) ## net-device.h (module 'network'): ns3::NetDevice::NetDevice(ns3::NetDevice const & arg0) [copy constructor] cls.add_constructor([param('ns3::NetDevice const &', 'arg0')]) ## net-device.h (module 'network'): void ns3::NetDevice::AddLinkChangeCallback(ns3::Callback<void,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> callback) [member function] cls.add_method('AddLinkChangeCallback', 'void', [param('ns3::Callback< void, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'callback')], is_pure_virtual=True, is_virtual=True) ## net-device.h (module 'network'): ns3::Address ns3::NetDevice::GetAddress() const [member function] cls.add_method('GetAddress', 'ns3::Address', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): ns3::Address ns3::NetDevice::GetBroadcast() const [member function] cls.add_method('GetBroadcast', 'ns3::Address', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): ns3::Ptr<ns3::Channel> ns3::NetDevice::GetChannel() const [member function] cls.add_method('GetChannel', 'ns3::Ptr< ns3::Channel >', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): uint32_t ns3::NetDevice::GetIfIndex() const [member function] cls.add_method('GetIfIndex', 'uint32_t', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): uint16_t ns3::NetDevice::GetMtu() const [member function] cls.add_method('GetMtu', 'uint16_t', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): ns3::Address ns3::NetDevice::GetMulticast(ns3::Ipv4Address multicastGroup) const [member function] cls.add_method('GetMulticast', 'ns3::Address', [param('ns3::Ipv4Address', 'multicastGroup')], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): ns3::Address ns3::NetDevice::GetMulticast(ns3::Ipv6Address addr) const [member function] cls.add_method('GetMulticast', 'ns3::Address', [param('ns3::Ipv6Address', 'addr')], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): ns3::Ptr<ns3::Node> ns3::NetDevice::GetNode() const [member function] cls.add_method('GetNode', 'ns3::Ptr< ns3::Node >', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): static ns3::TypeId ns3::NetDevice::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## net-device.h (module 'network'): bool ns3::NetDevice::IsBridge() const [member function] cls.add_method('IsBridge', 'bool', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): bool ns3::NetDevice::IsBroadcast() const [member function] cls.add_method('IsBroadcast', 'bool', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): bool ns3::NetDevice::IsLinkUp() const [member function] cls.add_method('IsLinkUp', 'bool', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): bool ns3::NetDevice::IsMulticast() const [member function] cls.add_method('IsMulticast', 'bool', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): bool ns3::NetDevice::IsPointToPoint() const [member function] cls.add_method('IsPointToPoint', 'bool', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): bool ns3::NetDevice::NeedsArp() const [member function] cls.add_method('NeedsArp', 'bool', [], is_pure_virtual=True, is_const=True, is_virtual=True) ## net-device.h (module 'network'): bool ns3::NetDevice::Send(ns3::Ptr<ns3::Packet> packet, ns3::Address const & dest, uint16_t protocolNumber) [member function] cls.add_method('Send', 'bool', [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Address const &', 'dest'), param('uint16_t', 'protocolNumber')], is_pure_virtual=True, is_virtual=True) ## net-device.h (module 'network'): bool ns3::NetDevice::SendFrom(ns3::Ptr<ns3::Packet> packet, ns3::Address const & source, ns3::Address const & dest, uint16_t protocolNumber) [member function] cls.add_method('SendFrom', 'bool', [param('ns3::Ptr< ns3::Packet >', 'packet'), param('ns3::Address const &', 'source'), param('ns3::Address const &', 'dest'), param('uint16_t', 'protocolNumber')], is_pure_virtual=True, is_virtual=True) ## net-device.h (module 'network'): void ns3::NetDevice::SetAddress(ns3::Address address) [member function] cls.add_method('SetAddress', 'void', [param('ns3::Address', 'address')], is_pure_virtual=True, is_virtual=True) ## net-device.h (module 'network'): void ns3::NetDevice::SetIfIndex(uint32_t const index) [member function] cls.add_method('SetIfIndex', 'void', [param('uint32_t const', 'index')], is_pure_virtual=True, is_virtual=True) ## net-device.h (module 'network'): bool ns3::NetDevice::SetMtu(uint16_t const mtu) [member function] cls.add_method('SetMtu', 'bool', [param('uint16_t const', 'mtu')], is_pure_virtual=True, is_virtual=True) ## net-device.h (module 'network'): void ns3::NetDevice::SetNode(ns3::Ptr<ns3::Node> node) [member function] cls.add_method('SetNode', 'void', [param('ns3::Ptr< ns3::Node >', 'node')], is_pure_virtual=True, is_virtual=True) ## net-device.h (module 'network'): void ns3::NetDevice::SetPromiscReceiveCallback(ns3::Callback<bool,ns3::Ptr<ns3::NetDevice>,ns3::Ptr<const ns3::Packet>,short unsigned int,const ns3::Address&,const ns3::Address&,ns3::NetDevice::PacketType,ns3::empty,ns3::empty,ns3::empty> cb) [member function] cls.add_method('SetPromiscReceiveCallback', 'void', [param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, short unsigned int, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'cb')], is_pure_virtual=True, is_virtual=True) ## net-device.h (module 'network'): void ns3::NetDevice::SetReceiveCallback(ns3::Callback<bool,ns3::Ptr<ns3::NetDevice>,ns3::Ptr<const ns3::Packet>,short unsigned int,const ns3::Address&,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> cb) [member function] cls.add_method('SetReceiveCallback', 'void', [param('ns3::Callback< bool, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, short unsigned int, ns3::Address const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')], is_pure_virtual=True, is_virtual=True) ## net-device.h (module 'network'): bool ns3::NetDevice::SupportsSendFrom() const [member function] cls.add_method('SupportsSendFrom', 'bool', [], is_pure_virtual=True, is_const=True, is_virtual=True) return def register_Ns3NixVector_methods(root_module, cls): cls.add_output_stream_operator() ## nix-vector.h (module 'network'): ns3::NixVector::NixVector() [constructor] cls.add_constructor([]) ## nix-vector.h (module 'network'): ns3::NixVector::NixVector(ns3::NixVector const & o) [copy constructor] cls.add_constructor([param('ns3::NixVector const &', 'o')]) ## nix-vector.h (module 'network'): void ns3::NixVector::AddNeighborIndex(uint32_t newBits, uint32_t numberOfBits) [member function] cls.add_method('AddNeighborIndex', 'void', [param('uint32_t', 'newBits'), param('uint32_t', 'numberOfBits')]) ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::BitCount(uint32_t numberOfNeighbors) const [member function] cls.add_method('BitCount', 'uint32_t', [param('uint32_t', 'numberOfNeighbors')], is_const=True) ## nix-vector.h (module 'network'): ns3::Ptr<ns3::NixVector> ns3::NixVector::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::NixVector >', [], is_const=True) ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::Deserialize(uint32_t const * buffer, uint32_t size) [member function] cls.add_method('Deserialize', 'uint32_t', [param('uint32_t const *', 'buffer'), param('uint32_t', 'size')]) ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::ExtractNeighborIndex(uint32_t numberOfBits) [member function] cls.add_method('ExtractNeighborIndex', 'uint32_t', [param('uint32_t', 'numberOfBits')]) ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::GetRemainingBits() [member function] cls.add_method('GetRemainingBits', 'uint32_t', []) ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True) ## nix-vector.h (module 'network'): uint32_t ns3::NixVector::Serialize(uint32_t * buffer, uint32_t maxSize) const [member function] cls.add_method('Serialize', 'uint32_t', [param('uint32_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) return def register_Ns3Node_methods(root_module, cls): ## node.h (module 'network'): ns3::Node::Node(ns3::Node const & arg0) [copy constructor] cls.add_constructor([param('ns3::Node const &', 'arg0')]) ## node.h (module 'network'): ns3::Node::Node() [constructor] cls.add_constructor([]) ## node.h (module 'network'): ns3::Node::Node(uint32_t systemId) [constructor] cls.add_constructor([param('uint32_t', 'systemId')]) ## node.h (module 'network'): uint32_t ns3::Node::AddApplication(ns3::Ptr<ns3::Application> application) [member function] cls.add_method('AddApplication', 'uint32_t', [param('ns3::Ptr< ns3::Application >', 'application')]) ## node.h (module 'network'): uint32_t ns3::Node::AddDevice(ns3::Ptr<ns3::NetDevice> device) [member function] cls.add_method('AddDevice', 'uint32_t', [param('ns3::Ptr< ns3::NetDevice >', 'device')]) ## node.h (module 'network'): static bool ns3::Node::ChecksumEnabled() [member function] cls.add_method('ChecksumEnabled', 'bool', [], is_static=True) ## node.h (module 'network'): ns3::Ptr<ns3::Application> ns3::Node::GetApplication(uint32_t index) const [member function] cls.add_method('GetApplication', 'ns3::Ptr< ns3::Application >', [param('uint32_t', 'index')], is_const=True) ## node.h (module 'network'): ns3::Ptr<ns3::NetDevice> ns3::Node::GetDevice(uint32_t index) const [member function] cls.add_method('GetDevice', 'ns3::Ptr< ns3::NetDevice >', [param('uint32_t', 'index')], is_const=True) ## node.h (module 'network'): uint32_t ns3::Node::GetId() const [member function] cls.add_method('GetId', 'uint32_t', [], is_const=True) ## node.h (module 'network'): ns3::Time ns3::Node::GetLocalTime() const [member function] cls.add_method('GetLocalTime', 'ns3::Time', [], is_const=True) ## node.h (module 'network'): uint32_t ns3::Node::GetNApplications() const [member function] cls.add_method('GetNApplications', 'uint32_t', [], is_const=True) ## node.h (module 'network'): uint32_t ns3::Node::GetNDevices() const [member function] cls.add_method('GetNDevices', 'uint32_t', [], is_const=True) ## node.h (module 'network'): uint32_t ns3::Node::GetSystemId() const [member function] cls.add_method('GetSystemId', 'uint32_t', [], is_const=True) ## node.h (module 'network'): static ns3::TypeId ns3::Node::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## node.h (module 'network'): void ns3::Node::RegisterDeviceAdditionListener(ns3::Callback<void,ns3::Ptr<ns3::NetDevice>,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> listener) [member function] cls.add_method('RegisterDeviceAdditionListener', 'void', [param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'listener')]) ## node.h (module 'network'): void ns3::Node::RegisterProtocolHandler(ns3::Callback<void, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty> handler, uint16_t protocolType, ns3::Ptr<ns3::NetDevice> device, bool promiscuous=false) [member function] cls.add_method('RegisterProtocolHandler', 'void', [param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'handler'), param('uint16_t', 'protocolType'), param('ns3::Ptr< ns3::NetDevice >', 'device'), param('bool', 'promiscuous', default_value='false')]) ## node.h (module 'network'): void ns3::Node::UnregisterDeviceAdditionListener(ns3::Callback<void,ns3::Ptr<ns3::NetDevice>,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> listener) [member function] cls.add_method('UnregisterDeviceAdditionListener', 'void', [param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice >, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'listener')]) ## node.h (module 'network'): void ns3::Node::UnregisterProtocolHandler(ns3::Callback<void, ns3::Ptr<ns3::NetDevice>, ns3::Ptr<ns3::Packet const>, unsigned short, ns3::Address const&, ns3::Address const&, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty> handler) [member function] cls.add_method('UnregisterProtocolHandler', 'void', [param('ns3::Callback< void, ns3::Ptr< ns3::NetDevice >, ns3::Ptr< ns3::Packet const >, unsigned short, ns3::Address const &, ns3::Address const &, ns3::NetDevice::PacketType, ns3::empty, ns3::empty, ns3::empty >', 'handler')]) ## node.h (module 'network'): void ns3::Node::DoDispose() [member function] cls.add_method('DoDispose', 'void', [], visibility='protected', is_virtual=True) ## node.h (module 'network'): void ns3::Node::DoInitialize() [member function] cls.add_method('DoInitialize', 'void', [], visibility='protected', is_virtual=True) return def register_Ns3NormalRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): ns3::NormalRandomVariable::INFINITE_VALUE [variable] cls.add_static_attribute('INFINITE_VALUE', 'double const', is_const=True) ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::NormalRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::NormalRandomVariable::NormalRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): double ns3::NormalRandomVariable::GetMean() const [member function] cls.add_method('GetMean', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::NormalRandomVariable::GetVariance() const [member function] cls.add_method('GetVariance', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::NormalRandomVariable::GetBound() const [member function] cls.add_method('GetBound', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::NormalRandomVariable::GetValue(double mean, double variance, double bound=ns3::NormalRandomVariable::INFINITE_VALUE) [member function] cls.add_method('GetValue', 'double', [param('double', 'mean'), param('double', 'variance'), param('double', 'bound', default_value='ns3::NormalRandomVariable::INFINITE_VALUE')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::NormalRandomVariable::GetInteger(uint32_t mean, uint32_t variance, uint32_t bound) [member function] cls.add_method('GetInteger', 'uint32_t', [param('uint32_t', 'mean'), param('uint32_t', 'variance'), param('uint32_t', 'bound')]) ## random-variable-stream.h (module 'core'): double ns3::NormalRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::NormalRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3ObjectFactoryChecker_methods(root_module, cls): ## object-factory.h (module 'core'): ns3::ObjectFactoryChecker::ObjectFactoryChecker() [constructor] cls.add_constructor([]) ## object-factory.h (module 'core'): ns3::ObjectFactoryChecker::ObjectFactoryChecker(ns3::ObjectFactoryChecker const & arg0) [copy constructor] cls.add_constructor([param('ns3::ObjectFactoryChecker const &', 'arg0')]) return def register_Ns3ObjectFactoryValue_methods(root_module, cls): ## object-factory.h (module 'core'): ns3::ObjectFactoryValue::ObjectFactoryValue() [constructor] cls.add_constructor([]) ## object-factory.h (module 'core'): ns3::ObjectFactoryValue::ObjectFactoryValue(ns3::ObjectFactoryValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::ObjectFactoryValue const &', 'arg0')]) ## object-factory.h (module 'core'): ns3::ObjectFactoryValue::ObjectFactoryValue(ns3::ObjectFactory const & value) [constructor] cls.add_constructor([param('ns3::ObjectFactory const &', 'value')]) ## object-factory.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::ObjectFactoryValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## object-factory.h (module 'core'): bool ns3::ObjectFactoryValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_virtual=True) ## object-factory.h (module 'core'): ns3::ObjectFactory ns3::ObjectFactoryValue::Get() const [member function] cls.add_method('Get', 'ns3::ObjectFactory', [], is_const=True) ## object-factory.h (module 'core'): std::string ns3::ObjectFactoryValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True, is_virtual=True) ## object-factory.h (module 'core'): void ns3::ObjectFactoryValue::Set(ns3::ObjectFactory const & value) [member function] cls.add_method('Set', 'void', [param('ns3::ObjectFactory const &', 'value')]) return def register_Ns3OutputStreamWrapper_methods(root_module, cls): ## output-stream-wrapper.h (module 'network'): ns3::OutputStreamWrapper::OutputStreamWrapper(ns3::OutputStreamWrapper const & arg0) [copy constructor] cls.add_constructor([param('ns3::OutputStreamWrapper const &', 'arg0')]) ## output-stream-wrapper.h (module 'network'): ns3::OutputStreamWrapper::OutputStreamWrapper(std::string filename, std::_Ios_Openmode filemode) [constructor] cls.add_constructor([param('std::string', 'filename'), param('std::_Ios_Openmode', 'filemode')]) ## output-stream-wrapper.h (module 'network'): ns3::OutputStreamWrapper::OutputStreamWrapper(std::ostream * os) [constructor] cls.add_constructor([param('std::ostream *', 'os')]) ## output-stream-wrapper.h (module 'network'): std::ostream * ns3::OutputStreamWrapper::GetStream() [member function] cls.add_method('GetStream', 'std::ostream *', []) return def register_Ns3Packet_methods(root_module, cls): cls.add_output_stream_operator() ## packet.h (module 'network'): ns3::Packet::Packet() [constructor] cls.add_constructor([]) ## packet.h (module 'network'): ns3::Packet::Packet(ns3::Packet const & o) [copy constructor] cls.add_constructor([param('ns3::Packet const &', 'o')]) ## packet.h (module 'network'): ns3::Packet::Packet(uint32_t size) [constructor] cls.add_constructor([param('uint32_t', 'size')]) ## packet.h (module 'network'): ns3::Packet::Packet(uint8_t const * buffer, uint32_t size, bool magic) [constructor] cls.add_constructor([param('uint8_t const *', 'buffer'), param('uint32_t', 'size'), param('bool', 'magic')]) ## packet.h (module 'network'): ns3::Packet::Packet(uint8_t const * buffer, uint32_t size) [constructor] cls.add_constructor([param('uint8_t const *', 'buffer'), param('uint32_t', 'size')]) ## packet.h (module 'network'): void ns3::Packet::AddAtEnd(ns3::Ptr<ns3::Packet const> packet) [member function] cls.add_method('AddAtEnd', 'void', [param('ns3::Ptr< ns3::Packet const >', 'packet')]) ## packet.h (module 'network'): void ns3::Packet::AddByteTag(ns3::Tag const & tag) const [member function] cls.add_method('AddByteTag', 'void', [param('ns3::Tag const &', 'tag')], is_const=True) ## packet.h (module 'network'): void ns3::Packet::AddHeader(ns3::Header const & header) [member function] cls.add_method('AddHeader', 'void', [param('ns3::Header const &', 'header')]) ## packet.h (module 'network'): void ns3::Packet::AddPacketTag(ns3::Tag const & tag) const [member function] cls.add_method('AddPacketTag', 'void', [param('ns3::Tag const &', 'tag')], is_const=True) ## packet.h (module 'network'): void ns3::Packet::AddPaddingAtEnd(uint32_t size) [member function] cls.add_method('AddPaddingAtEnd', 'void', [param('uint32_t', 'size')]) ## packet.h (module 'network'): void ns3::Packet::AddTrailer(ns3::Trailer const & trailer) [member function] cls.add_method('AddTrailer', 'void', [param('ns3::Trailer const &', 'trailer')]) ## packet.h (module 'network'): ns3::PacketMetadata::ItemIterator ns3::Packet::BeginItem() const [member function] cls.add_method('BeginItem', 'ns3::PacketMetadata::ItemIterator', [], is_const=True) ## packet.h (module 'network'): ns3::Ptr<ns3::Packet> ns3::Packet::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::Packet >', [], is_const=True) ## packet.h (module 'network'): uint32_t ns3::Packet::CopyData(uint8_t * buffer, uint32_t size) const [member function] cls.add_method('CopyData', 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'size')], is_const=True) ## packet.h (module 'network'): void ns3::Packet::CopyData(std::ostream * os, uint32_t size) const [member function] cls.add_method('CopyData', 'void', [param('std::ostream *', 'os'), param('uint32_t', 'size')], is_const=True) ## packet.h (module 'network'): ns3::Ptr<ns3::Packet> ns3::Packet::CreateFragment(uint32_t start, uint32_t length) const [member function] cls.add_method('CreateFragment', 'ns3::Ptr< ns3::Packet >', [param('uint32_t', 'start'), param('uint32_t', 'length')], is_const=True) ## packet.h (module 'network'): static void ns3::Packet::EnableChecking() [member function] cls.add_method('EnableChecking', 'void', [], is_static=True) ## packet.h (module 'network'): static void ns3::Packet::EnablePrinting() [member function] cls.add_method('EnablePrinting', 'void', [], is_static=True) ## packet.h (module 'network'): bool ns3::Packet::FindFirstMatchingByteTag(ns3::Tag & tag) const [member function] cls.add_method('FindFirstMatchingByteTag', 'bool', [param('ns3::Tag &', 'tag')], is_const=True) ## packet.h (module 'network'): ns3::ByteTagIterator ns3::Packet::GetByteTagIterator() const [member function] cls.add_method('GetByteTagIterator', 'ns3::ByteTagIterator', [], is_const=True) ## packet.h (module 'network'): ns3::Ptr<ns3::NixVector> ns3::Packet::GetNixVector() const [member function] cls.add_method('GetNixVector', 'ns3::Ptr< ns3::NixVector >', [], is_const=True) ## packet.h (module 'network'): ns3::PacketTagIterator ns3::Packet::GetPacketTagIterator() const [member function] cls.add_method('GetPacketTagIterator', 'ns3::PacketTagIterator', [], is_const=True) ## packet.h (module 'network'): uint32_t ns3::Packet::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True) ## packet.h (module 'network'): uint32_t ns3::Packet::GetSize() const [member function] cls.add_method('GetSize', 'uint32_t', [], is_const=True) ## packet.h (module 'network'): uint64_t ns3::Packet::GetUid() const [member function] cls.add_method('GetUid', 'uint64_t', [], is_const=True) ## packet.h (module 'network'): uint32_t ns3::Packet::PeekHeader(ns3::Header & header) const [member function] cls.add_method('PeekHeader', 'uint32_t', [param('ns3::Header &', 'header')], is_const=True) ## packet.h (module 'network'): bool ns3::Packet::PeekPacketTag(ns3::Tag & tag) const [member function] cls.add_method('PeekPacketTag', 'bool', [param('ns3::Tag &', 'tag')], is_const=True) ## packet.h (module 'network'): uint32_t ns3::Packet::PeekTrailer(ns3::Trailer & trailer) [member function] cls.add_method('PeekTrailer', 'uint32_t', [param('ns3::Trailer &', 'trailer')]) ## packet.h (module 'network'): void ns3::Packet::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True) ## packet.h (module 'network'): void ns3::Packet::PrintByteTags(std::ostream & os) const [member function] cls.add_method('PrintByteTags', 'void', [param('std::ostream &', 'os')], is_const=True) ## packet.h (module 'network'): void ns3::Packet::PrintPacketTags(std::ostream & os) const [member function] cls.add_method('PrintPacketTags', 'void', [param('std::ostream &', 'os')], is_const=True) ## packet.h (module 'network'): void ns3::Packet::RemoveAllByteTags() [member function] cls.add_method('RemoveAllByteTags', 'void', []) ## packet.h (module 'network'): void ns3::Packet::RemoveAllPacketTags() [member function] cls.add_method('RemoveAllPacketTags', 'void', []) ## packet.h (module 'network'): void ns3::Packet::RemoveAtEnd(uint32_t size) [member function] cls.add_method('RemoveAtEnd', 'void', [param('uint32_t', 'size')]) ## packet.h (module 'network'): void ns3::Packet::RemoveAtStart(uint32_t size) [member function] cls.add_method('RemoveAtStart', 'void', [param('uint32_t', 'size')]) ## packet.h (module 'network'): uint32_t ns3::Packet::RemoveHeader(ns3::Header & header) [member function] cls.add_method('RemoveHeader', 'uint32_t', [param('ns3::Header &', 'header')]) ## packet.h (module 'network'): bool ns3::Packet::RemovePacketTag(ns3::Tag & tag) [member function] cls.add_method('RemovePacketTag', 'bool', [param('ns3::Tag &', 'tag')]) ## packet.h (module 'network'): uint32_t ns3::Packet::RemoveTrailer(ns3::Trailer & trailer) [member function] cls.add_method('RemoveTrailer', 'uint32_t', [param('ns3::Trailer &', 'trailer')]) ## packet.h (module 'network'): bool ns3::Packet::ReplacePacketTag(ns3::Tag & tag) [member function] cls.add_method('ReplacePacketTag', 'bool', [param('ns3::Tag &', 'tag')]) ## packet.h (module 'network'): uint32_t ns3::Packet::Serialize(uint8_t * buffer, uint32_t maxSize) const [member function] cls.add_method('Serialize', 'uint32_t', [param('uint8_t *', 'buffer'), param('uint32_t', 'maxSize')], is_const=True) ## packet.h (module 'network'): void ns3::Packet::SetNixVector(ns3::Ptr<ns3::NixVector> nixVector) [member function] cls.add_method('SetNixVector', 'void', [param('ns3::Ptr< ns3::NixVector >', 'nixVector')]) ## packet.h (module 'network'): std::string ns3::Packet::ToString() const [member function] cls.add_method('ToString', 'std::string', [], is_const=True) return def register_Ns3ParetoRandomVariable_methods(root_module, cls): ## random-variable-stream.h (module 'core'): static ns3::TypeId ns3::ParetoRandomVariable::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## random-variable-stream.h (module 'core'): ns3::ParetoRandomVariable::ParetoRandomVariable() [constructor] cls.add_constructor([]) ## random-variable-stream.h (module 'core'): double ns3::ParetoRandomVariable::GetMean() const [member function] cls.add_method('GetMean', 'double', [], deprecated=True, is_const=True) ## random-variable-stream.h (module 'core'): double ns3::ParetoRandomVariable::GetScale() const [member function] cls.add_method('GetScale', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::ParetoRandomVariable::GetShape() const [member function] cls.add_method('GetShape', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::ParetoRandomVariable::GetBound() const [member function] cls.add_method('GetBound', 'double', [], is_const=True) ## random-variable-stream.h (module 'core'): double ns3::ParetoRandomVariable::GetValue(double scale, double shape, double bound) [member function] cls.add_method('GetValue', 'double', [param('double', 'scale'), param('double', 'shape'), param('double', 'bound')]) ## random-variable-stream.h (module 'core'): uint32_t ns3::ParetoRandomVariable::GetInteger(uint32_t scale, uint32_t shape, uint32_t bound) [member function] cls.add_method('GetInteger', 'uint32_t', [param('uint32_t', 'scale'), param('uint32_t', 'shape'), param('uint32_t', 'bound')]) ## random-variable-stream.h (module 'core'): double ns3::ParetoRandomVariable::GetValue() [member function] cls.add_method('GetValue', 'double', [], is_virtual=True) ## random-variable-stream.h (module 'core'): uint32_t ns3::ParetoRandomVariable::GetInteger() [member function] cls.add_method('GetInteger', 'uint32_t', [], is_virtual=True) return def register_Ns3TimeValue_methods(root_module, cls): ## nstime.h (module 'core'): ns3::TimeValue::TimeValue() [constructor] cls.add_constructor([]) ## nstime.h (module 'core'): ns3::TimeValue::TimeValue(ns3::TimeValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::TimeValue const &', 'arg0')]) ## nstime.h (module 'core'): ns3::TimeValue::TimeValue(ns3::Time const & value) [constructor] cls.add_constructor([param('ns3::Time const &', 'value')]) ## nstime.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::TimeValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## nstime.h (module 'core'): bool ns3::TimeValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_virtual=True) ## nstime.h (module 'core'): ns3::Time ns3::TimeValue::Get() const [member function] cls.add_method('Get', 'ns3::Time', [], is_const=True) ## nstime.h (module 'core'): std::string ns3::TimeValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True, is_virtual=True) ## nstime.h (module 'core'): void ns3::TimeValue::Set(ns3::Time const & value) [member function] cls.add_method('Set', 'void', [param('ns3::Time const &', 'value')]) return def register_Ns3TypeIdChecker_methods(root_module, cls): ## type-id.h (module 'core'): ns3::TypeIdChecker::TypeIdChecker() [constructor] cls.add_constructor([]) ## type-id.h (module 'core'): ns3::TypeIdChecker::TypeIdChecker(ns3::TypeIdChecker const & arg0) [copy constructor] cls.add_constructor([param('ns3::TypeIdChecker const &', 'arg0')]) return def register_Ns3TypeIdValue_methods(root_module, cls): ## type-id.h (module 'core'): ns3::TypeIdValue::TypeIdValue() [constructor] cls.add_constructor([]) ## type-id.h (module 'core'): ns3::TypeIdValue::TypeIdValue(ns3::TypeIdValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::TypeIdValue const &', 'arg0')]) ## type-id.h (module 'core'): ns3::TypeIdValue::TypeIdValue(ns3::TypeId const & value) [constructor] cls.add_constructor([param('ns3::TypeId const &', 'value')]) ## type-id.h (module 'core'): ns3::Ptr<ns3::AttributeValue> ns3::TypeIdValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## type-id.h (module 'core'): bool ns3::TypeIdValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_virtual=True) ## type-id.h (module 'core'): ns3::TypeId ns3::TypeIdValue::Get() const [member function] cls.add_method('Get', 'ns3::TypeId', [], is_const=True) ## type-id.h (module 'core'): std::string ns3::TypeIdValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True, is_virtual=True) ## type-id.h (module 'core'): void ns3::TypeIdValue::Set(ns3::TypeId const & value) [member function] cls.add_method('Set', 'void', [param('ns3::TypeId const &', 'value')]) return def register_Ns3AddressChecker_methods(root_module, cls): ## address.h (module 'network'): ns3::AddressChecker::AddressChecker() [constructor] cls.add_constructor([]) ## address.h (module 'network'): ns3::AddressChecker::AddressChecker(ns3::AddressChecker const & arg0) [copy constructor] cls.add_constructor([param('ns3::AddressChecker const &', 'arg0')]) return def register_Ns3AddressValue_methods(root_module, cls): ## address.h (module 'network'): ns3::AddressValue::AddressValue() [constructor] cls.add_constructor([]) ## address.h (module 'network'): ns3::AddressValue::AddressValue(ns3::AddressValue const & arg0) [copy constructor] cls.add_constructor([param('ns3::AddressValue const &', 'arg0')]) ## address.h (module 'network'): ns3::AddressValue::AddressValue(ns3::Address const & value) [constructor] cls.add_constructor([param('ns3::Address const &', 'value')]) ## address.h (module 'network'): ns3::Ptr<ns3::AttributeValue> ns3::AddressValue::Copy() const [member function] cls.add_method('Copy', 'ns3::Ptr< ns3::AttributeValue >', [], is_const=True, is_virtual=True) ## address.h (module 'network'): bool ns3::AddressValue::DeserializeFromString(std::string value, ns3::Ptr<ns3::AttributeChecker const> checker) [member function] cls.add_method('DeserializeFromString', 'bool', [param('std::string', 'value'), param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_virtual=True) ## address.h (module 'network'): ns3::Address ns3::AddressValue::Get() const [member function] cls.add_method('Get', 'ns3::Address', [], is_const=True) ## address.h (module 'network'): std::string ns3::AddressValue::SerializeToString(ns3::Ptr<ns3::AttributeChecker const> checker) const [member function] cls.add_method('SerializeToString', 'std::string', [param('ns3::Ptr< ns3::AttributeChecker const >', 'checker')], is_const=True, is_virtual=True) ## address.h (module 'network'): void ns3::AddressValue::Set(ns3::Address const & value) [member function] cls.add_method('Set', 'void', [param('ns3::Address const &', 'value')]) return def register_Ns3Ipv4ListRouting_methods(root_module, cls): ## ipv4-list-routing.h (module 'internet'): ns3::Ipv4ListRouting::Ipv4ListRouting(ns3::Ipv4ListRouting const & arg0) [copy constructor] cls.add_constructor([param('ns3::Ipv4ListRouting const &', 'arg0')]) ## ipv4-list-routing.h (module 'internet'): ns3::Ipv4ListRouting::Ipv4ListRouting() [constructor] cls.add_constructor([]) ## ipv4-list-routing.h (module 'internet'): void ns3::Ipv4ListRouting::AddRoutingProtocol(ns3::Ptr<ns3::Ipv4RoutingProtocol> routingProtocol, int16_t priority) [member function] cls.add_method('AddRoutingProtocol', 'void', [param('ns3::Ptr< ns3::Ipv4RoutingProtocol >', 'routingProtocol'), param('int16_t', 'priority')], is_virtual=True) ## ipv4-list-routing.h (module 'internet'): uint32_t ns3::Ipv4ListRouting::GetNRoutingProtocols() const [member function] cls.add_method('GetNRoutingProtocols', 'uint32_t', [], is_const=True, is_virtual=True) ## ipv4-list-routing.h (module 'internet'): ns3::Ptr<ns3::Ipv4RoutingProtocol> ns3::Ipv4ListRouting::GetRoutingProtocol(uint32_t index, int16_t & priority) const [member function] cls.add_method('GetRoutingProtocol', 'ns3::Ptr< ns3::Ipv4RoutingProtocol >', [param('uint32_t', 'index'), param('int16_t &', 'priority', direction=2)], is_const=True, is_virtual=True) ## ipv4-list-routing.h (module 'internet'): static ns3::TypeId ns3::Ipv4ListRouting::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## ipv4-list-routing.h (module 'internet'): void ns3::Ipv4ListRouting::NotifyAddAddress(uint32_t interface, ns3::Ipv4InterfaceAddress address) [member function] cls.add_method('NotifyAddAddress', 'void', [param('uint32_t', 'interface'), param('ns3::Ipv4InterfaceAddress', 'address')], is_virtual=True) ## ipv4-list-routing.h (module 'internet'): void ns3::Ipv4ListRouting::NotifyInterfaceDown(uint32_t interface) [member function] cls.add_method('NotifyInterfaceDown', 'void', [param('uint32_t', 'interface')], is_virtual=True) ## ipv4-list-routing.h (module 'internet'): void ns3::Ipv4ListRouting::NotifyInterfaceUp(uint32_t interface) [member function] cls.add_method('NotifyInterfaceUp', 'void', [param('uint32_t', 'interface')], is_virtual=True) ## ipv4-list-routing.h (module 'internet'): void ns3::Ipv4ListRouting::NotifyRemoveAddress(uint32_t interface, ns3::Ipv4InterfaceAddress address) [member function] cls.add_method('NotifyRemoveAddress', 'void', [param('uint32_t', 'interface'), param('ns3::Ipv4InterfaceAddress', 'address')], is_virtual=True) ## ipv4-list-routing.h (module 'internet'): void ns3::Ipv4ListRouting::PrintRoutingTable(ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::Time::Unit unit=::ns3::Time::S) const [member function] cls.add_method('PrintRoutingTable', 'void', [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::Time::Unit', 'unit', default_value='::ns3::Time::S')], is_const=True, is_virtual=True) ## ipv4-list-routing.h (module 'internet'): bool ns3::Ipv4ListRouting::RouteInput(ns3::Ptr<ns3::Packet const> p, ns3::Ipv4Header const & header, ns3::Ptr<const ns3::NetDevice> idev, ns3::Callback<void, ns3::Ptr<ns3::Ipv4Route>, ns3::Ptr<ns3::Packet const>, ns3::Ipv4Header const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ucb, ns3::Callback<void,ns3::Ptr<ns3::Ipv4MulticastRoute>,ns3::Ptr<const ns3::Packet>,const ns3::Ipv4Header&,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> mcb, ns3::Callback<void,ns3::Ptr<const ns3::Packet>,const ns3::Ipv4Header&,unsigned int,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> lcb, ns3::Callback<void, ns3::Ptr<ns3::Packet const>, ns3::Ipv4Header const&, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ecb) [member function] cls.add_method('RouteInput', 'bool', [param('ns3::Ptr< ns3::Packet const >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::NetDevice const >', 'idev'), param('ns3::Callback< void, ns3::Ptr< ns3::Ipv4Route >, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ucb'), param('ns3::Callback< void, ns3::Ptr< ns3::Ipv4MulticastRoute >, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'mcb'), param('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, unsigned int, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'lcb'), param('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ecb')], is_virtual=True) ## ipv4-list-routing.h (module 'internet'): ns3::Ptr<ns3::Ipv4Route> ns3::Ipv4ListRouting::RouteOutput(ns3::Ptr<ns3::Packet> p, ns3::Ipv4Header const & header, ns3::Ptr<ns3::NetDevice> oif, ns3::Socket::SocketErrno & sockerr) [member function] cls.add_method('RouteOutput', 'ns3::Ptr< ns3::Ipv4Route >', [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::NetDevice >', 'oif'), param('ns3::Socket::SocketErrno &', 'sockerr')], is_virtual=True) ## ipv4-list-routing.h (module 'internet'): void ns3::Ipv4ListRouting::SetIpv4(ns3::Ptr<ns3::Ipv4> ipv4) [member function] cls.add_method('SetIpv4', 'void', [param('ns3::Ptr< ns3::Ipv4 >', 'ipv4')], is_virtual=True) ## ipv4-list-routing.h (module 'internet'): void ns3::Ipv4ListRouting::DoDispose() [member function] cls.add_method('DoDispose', 'void', [], visibility='protected', is_virtual=True) ## ipv4-list-routing.h (module 'internet'): void ns3::Ipv4ListRouting::DoInitialize() [member function] cls.add_method('DoInitialize', 'void', [], visibility='protected', is_virtual=True) return def register_Ns3HashImplementation_methods(root_module, cls): ## hash-function.h (module 'core'): ns3::Hash::Implementation::Implementation(ns3::Hash::Implementation const & arg0) [copy constructor] cls.add_constructor([param('ns3::Hash::Implementation const &', 'arg0')]) ## hash-function.h (module 'core'): ns3::Hash::Implementation::Implementation() [constructor] cls.add_constructor([]) ## hash-function.h (module 'core'): uint32_t ns3::Hash::Implementation::GetHash32(char const * buffer, size_t const size) [member function] cls.add_method('GetHash32', 'uint32_t', [param('char const *', 'buffer'), param('size_t const', 'size')], is_pure_virtual=True, is_virtual=True) ## hash-function.h (module 'core'): uint64_t ns3::Hash::Implementation::GetHash64(char const * buffer, size_t const size) [member function] cls.add_method('GetHash64', 'uint64_t', [param('char const *', 'buffer'), param('size_t const', 'size')], is_virtual=True) ## hash-function.h (module 'core'): void ns3::Hash::Implementation::clear() [member function] cls.add_method('clear', 'void', [], is_pure_virtual=True, is_virtual=True) return def register_Ns3HashFunctionFnv1a_methods(root_module, cls): ## hash-fnv.h (module 'core'): ns3::Hash::Function::Fnv1a::Fnv1a(ns3::Hash::Function::Fnv1a const & arg0) [copy constructor] cls.add_constructor([param('ns3::Hash::Function::Fnv1a const &', 'arg0')]) ## hash-fnv.h (module 'core'): ns3::Hash::Function::Fnv1a::Fnv1a() [constructor] cls.add_constructor([]) ## hash-fnv.h (module 'core'): uint32_t ns3::Hash::Function::Fnv1a::GetHash32(char const * buffer, size_t const size) [member function] cls.add_method('GetHash32', 'uint32_t', [param('char const *', 'buffer'), param('size_t const', 'size')], is_virtual=True) ## hash-fnv.h (module 'core'): uint64_t ns3::Hash::Function::Fnv1a::GetHash64(char const * buffer, size_t const size) [member function] cls.add_method('GetHash64', 'uint64_t', [param('char const *', 'buffer'), param('size_t const', 'size')], is_virtual=True) ## hash-fnv.h (module 'core'): void ns3::Hash::Function::Fnv1a::clear() [member function] cls.add_method('clear', 'void', [], is_virtual=True) return def register_Ns3HashFunctionHash32_methods(root_module, cls): ## hash-function.h (module 'core'): ns3::Hash::Function::Hash32::Hash32(ns3::Hash::Function::Hash32 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Hash::Function::Hash32 const &', 'arg0')]) ## hash-function.h (module 'core'): ns3::Hash::Function::Hash32::Hash32(ns3::Hash::Hash32Function_ptr hp) [constructor] cls.add_constructor([param('ns3::Hash::Hash32Function_ptr', 'hp')]) ## hash-function.h (module 'core'): uint32_t ns3::Hash::Function::Hash32::GetHash32(char const * buffer, size_t const size) [member function] cls.add_method('GetHash32', 'uint32_t', [param('char const *', 'buffer'), param('size_t const', 'size')], is_virtual=True) ## hash-function.h (module 'core'): void ns3::Hash::Function::Hash32::clear() [member function] cls.add_method('clear', 'void', [], is_virtual=True) return def register_Ns3HashFunctionHash64_methods(root_module, cls): ## hash-function.h (module 'core'): ns3::Hash::Function::Hash64::Hash64(ns3::Hash::Function::Hash64 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Hash::Function::Hash64 const &', 'arg0')]) ## hash-function.h (module 'core'): ns3::Hash::Function::Hash64::Hash64(ns3::Hash::Hash64Function_ptr hp) [constructor] cls.add_constructor([param('ns3::Hash::Hash64Function_ptr', 'hp')]) ## hash-function.h (module 'core'): uint32_t ns3::Hash::Function::Hash64::GetHash32(char const * buffer, size_t const size) [member function] cls.add_method('GetHash32', 'uint32_t', [param('char const *', 'buffer'), param('size_t const', 'size')], is_virtual=True) ## hash-function.h (module 'core'): uint64_t ns3::Hash::Function::Hash64::GetHash64(char const * buffer, size_t const size) [member function] cls.add_method('GetHash64', 'uint64_t', [param('char const *', 'buffer'), param('size_t const', 'size')], is_virtual=True) ## hash-function.h (module 'core'): void ns3::Hash::Function::Hash64::clear() [member function] cls.add_method('clear', 'void', [], is_virtual=True) return def register_Ns3HashFunctionMurmur3_methods(root_module, cls): ## hash-murmur3.h (module 'core'): ns3::Hash::Function::Murmur3::Murmur3(ns3::Hash::Function::Murmur3 const & arg0) [copy constructor] cls.add_constructor([param('ns3::Hash::Function::Murmur3 const &', 'arg0')]) ## hash-murmur3.h (module 'core'): ns3::Hash::Function::Murmur3::Murmur3() [constructor] cls.add_constructor([]) ## hash-murmur3.h (module 'core'): uint32_t ns3::Hash::Function::Murmur3::GetHash32(char const * buffer, size_t const size) [member function] cls.add_method('GetHash32', 'uint32_t', [param('char const *', 'buffer'), param('size_t const', 'size')], is_virtual=True) ## hash-murmur3.h (module 'core'): uint64_t ns3::Hash::Function::Murmur3::GetHash64(char const * buffer, size_t const size) [member function] cls.add_method('GetHash64', 'uint64_t', [param('char const *', 'buffer'), param('size_t const', 'size')], is_virtual=True) ## hash-murmur3.h (module 'core'): void ns3::Hash::Function::Murmur3::clear() [member function] cls.add_method('clear', 'void', [], is_virtual=True) return def register_Ns3AodvDuplicatePacketDetection_methods(root_module, cls): ## aodv-dpd.h (module 'aodv'): ns3::aodv::DuplicatePacketDetection::DuplicatePacketDetection(ns3::aodv::DuplicatePacketDetection const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::DuplicatePacketDetection const &', 'arg0')]) ## aodv-dpd.h (module 'aodv'): ns3::aodv::DuplicatePacketDetection::DuplicatePacketDetection(ns3::Time lifetime) [constructor] cls.add_constructor([param('ns3::Time', 'lifetime')]) ## aodv-dpd.h (module 'aodv'): ns3::Time ns3::aodv::DuplicatePacketDetection::GetLifetime() const [member function] cls.add_method('GetLifetime', 'ns3::Time', [], is_const=True) ## aodv-dpd.h (module 'aodv'): bool ns3::aodv::DuplicatePacketDetection::IsDuplicate(ns3::Ptr<ns3::Packet const> p, ns3::Ipv4Header const & header) [member function] cls.add_method('IsDuplicate', 'bool', [param('ns3::Ptr< ns3::Packet const >', 'p'), param('ns3::Ipv4Header const &', 'header')]) ## aodv-dpd.h (module 'aodv'): void ns3::aodv::DuplicatePacketDetection::SetLifetime(ns3::Time lifetime) [member function] cls.add_method('SetLifetime', 'void', [param('ns3::Time', 'lifetime')]) return def register_Ns3AodvIdCache_methods(root_module, cls): ## aodv-id-cache.h (module 'aodv'): ns3::aodv::IdCache::IdCache(ns3::aodv::IdCache const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::IdCache const &', 'arg0')]) ## aodv-id-cache.h (module 'aodv'): ns3::aodv::IdCache::IdCache(ns3::Time lifetime) [constructor] cls.add_constructor([param('ns3::Time', 'lifetime')]) ## aodv-id-cache.h (module 'aodv'): ns3::Time ns3::aodv::IdCache::GetLifeTime() const [member function] cls.add_method('GetLifeTime', 'ns3::Time', [], is_const=True) ## aodv-id-cache.h (module 'aodv'): uint32_t ns3::aodv::IdCache::GetSize() [member function] cls.add_method('GetSize', 'uint32_t', []) ## aodv-id-cache.h (module 'aodv'): bool ns3::aodv::IdCache::IsDuplicate(ns3::Ipv4Address addr, uint32_t id) [member function] cls.add_method('IsDuplicate', 'bool', [param('ns3::Ipv4Address', 'addr'), param('uint32_t', 'id')]) ## aodv-id-cache.h (module 'aodv'): void ns3::aodv::IdCache::Purge() [member function] cls.add_method('Purge', 'void', []) ## aodv-id-cache.h (module 'aodv'): void ns3::aodv::IdCache::SetLifetime(ns3::Time lifetime) [member function] cls.add_method('SetLifetime', 'void', [param('ns3::Time', 'lifetime')]) return def register_Ns3AodvNeighbors_methods(root_module, cls): ## aodv-neighbor.h (module 'aodv'): ns3::aodv::Neighbors::Neighbors(ns3::aodv::Neighbors const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::Neighbors const &', 'arg0')]) ## aodv-neighbor.h (module 'aodv'): ns3::aodv::Neighbors::Neighbors(ns3::Time delay) [constructor] cls.add_constructor([param('ns3::Time', 'delay')]) ## aodv-neighbor.h (module 'aodv'): void ns3::aodv::Neighbors::AddArpCache(ns3::Ptr<ns3::ArpCache> arg0) [member function] cls.add_method('AddArpCache', 'void', [param('ns3::Ptr< ns3::ArpCache >', 'arg0')]) ## aodv-neighbor.h (module 'aodv'): void ns3::aodv::Neighbors::Clear() [member function] cls.add_method('Clear', 'void', []) ## aodv-neighbor.h (module 'aodv'): void ns3::aodv::Neighbors::DelArpCache(ns3::Ptr<ns3::ArpCache> arg0) [member function] cls.add_method('DelArpCache', 'void', [param('ns3::Ptr< ns3::ArpCache >', 'arg0')]) ## aodv-neighbor.h (module 'aodv'): ns3::Callback<void, ns3::Ipv4Address, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ns3::aodv::Neighbors::GetCallback() const [member function] cls.add_method('GetCallback', 'ns3::Callback< void, ns3::Ipv4Address, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', [], is_const=True) ## aodv-neighbor.h (module 'aodv'): ns3::Time ns3::aodv::Neighbors::GetExpireTime(ns3::Ipv4Address addr) [member function] cls.add_method('GetExpireTime', 'ns3::Time', [param('ns3::Ipv4Address', 'addr')]) ## aodv-neighbor.h (module 'aodv'): ns3::Callback<void, ns3::WifiMacHeader const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ns3::aodv::Neighbors::GetTxErrorCallback() const [member function] cls.add_method('GetTxErrorCallback', 'ns3::Callback< void, ns3::WifiMacHeader const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', [], is_const=True) ## aodv-neighbor.h (module 'aodv'): bool ns3::aodv::Neighbors::IsNeighbor(ns3::Ipv4Address addr) [member function] cls.add_method('IsNeighbor', 'bool', [param('ns3::Ipv4Address', 'addr')]) ## aodv-neighbor.h (module 'aodv'): void ns3::aodv::Neighbors::Purge() [member function] cls.add_method('Purge', 'void', []) ## aodv-neighbor.h (module 'aodv'): void ns3::aodv::Neighbors::ScheduleTimer() [member function] cls.add_method('ScheduleTimer', 'void', []) ## aodv-neighbor.h (module 'aodv'): void ns3::aodv::Neighbors::SetCallback(ns3::Callback<void, ns3::Ipv4Address, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> cb) [member function] cls.add_method('SetCallback', 'void', [param('ns3::Callback< void, ns3::Ipv4Address, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'cb')]) ## aodv-neighbor.h (module 'aodv'): void ns3::aodv::Neighbors::Update(ns3::Ipv4Address addr, ns3::Time expire) [member function] cls.add_method('Update', 'void', [param('ns3::Ipv4Address', 'addr'), param('ns3::Time', 'expire')]) return def register_Ns3AodvNeighborsNeighbor_methods(root_module, cls): ## aodv-neighbor.h (module 'aodv'): ns3::aodv::Neighbors::Neighbor::Neighbor(ns3::aodv::Neighbors::Neighbor const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::Neighbors::Neighbor const &', 'arg0')]) ## aodv-neighbor.h (module 'aodv'): ns3::aodv::Neighbors::Neighbor::Neighbor(ns3::Ipv4Address ip, ns3::Mac48Address mac, ns3::Time t) [constructor] cls.add_constructor([param('ns3::Ipv4Address', 'ip'), param('ns3::Mac48Address', 'mac'), param('ns3::Time', 't')]) ## aodv-neighbor.h (module 'aodv'): ns3::aodv::Neighbors::Neighbor::close [variable] cls.add_instance_attribute('close', 'bool', is_const=False) ## aodv-neighbor.h (module 'aodv'): ns3::aodv::Neighbors::Neighbor::m_expireTime [variable] cls.add_instance_attribute('m_expireTime', 'ns3::Time', is_const=False) ## aodv-neighbor.h (module 'aodv'): ns3::aodv::Neighbors::Neighbor::m_hardwareAddress [variable] cls.add_instance_attribute('m_hardwareAddress', 'ns3::Mac48Address', is_const=False) ## aodv-neighbor.h (module 'aodv'): ns3::aodv::Neighbors::Neighbor::m_neighborAddress [variable] cls.add_instance_attribute('m_neighborAddress', 'ns3::Ipv4Address', is_const=False) return def register_Ns3AodvQueueEntry_methods(root_module, cls): cls.add_binary_comparison_operator('==') ## aodv-rqueue.h (module 'aodv'): ns3::aodv::QueueEntry::QueueEntry(ns3::aodv::QueueEntry const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::QueueEntry const &', 'arg0')]) ## aodv-rqueue.h (module 'aodv'): ns3::aodv::QueueEntry::QueueEntry(ns3::Ptr<ns3::Packet const> pa=0, ns3::Ipv4Header const & h=ns3::Ipv4Header(), ns3::Callback<void, ns3::Ptr<ns3::Ipv4Route>, ns3::Ptr<ns3::Packet const>, ns3::Ipv4Header const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ucb=ns3::Callback<void, ns3::Ptr<ns3::Ipv4Route>, ns3::Ptr<const ns3::Packet>, const ns3::Ipv4Header&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty>(), ns3::Callback<void, ns3::Ptr<ns3::Packet const>, ns3::Ipv4Header const&, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ecb=ns3::Callback<void, ns3::Ptr<const ns3::Packet>, const ns3::Ipv4Header&, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty>(), ns3::Time exp=ns3::Simulator::Now( )) [constructor] cls.add_constructor([param('ns3::Ptr< ns3::Packet const >', 'pa', default_value='0'), param('ns3::Ipv4Header const &', 'h', default_value='ns3::Ipv4Header()'), param('ns3::Callback< void, ns3::Ptr< ns3::Ipv4Route >, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ucb', default_value='ns3::Callback<void, ns3::Ptr<ns3::Ipv4Route>, ns3::Ptr<const ns3::Packet>, const ns3::Ipv4Header&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty>()'), param('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ecb', default_value='ns3::Callback<void, ns3::Ptr<const ns3::Packet>, const ns3::Ipv4Header&, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty>()'), param('ns3::Time', 'exp', default_value='ns3::Simulator::Now( )')]) ## aodv-rqueue.h (module 'aodv'): ns3::Callback<void, ns3::Ptr<ns3::Packet const>, ns3::Ipv4Header const&, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ns3::aodv::QueueEntry::GetErrorCallback() const [member function] cls.add_method('GetErrorCallback', 'ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', [], is_const=True) ## aodv-rqueue.h (module 'aodv'): ns3::Time ns3::aodv::QueueEntry::GetExpireTime() const [member function] cls.add_method('GetExpireTime', 'ns3::Time', [], is_const=True) ## aodv-rqueue.h (module 'aodv'): ns3::Ipv4Header ns3::aodv::QueueEntry::GetIpv4Header() const [member function] cls.add_method('GetIpv4Header', 'ns3::Ipv4Header', [], is_const=True) ## aodv-rqueue.h (module 'aodv'): ns3::Ptr<ns3::Packet const> ns3::aodv::QueueEntry::GetPacket() const [member function] cls.add_method('GetPacket', 'ns3::Ptr< ns3::Packet const >', [], is_const=True) ## aodv-rqueue.h (module 'aodv'): ns3::Callback<void, ns3::Ptr<ns3::Ipv4Route>, ns3::Ptr<ns3::Packet const>, ns3::Ipv4Header const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ns3::aodv::QueueEntry::GetUnicastForwardCallback() const [member function] cls.add_method('GetUnicastForwardCallback', 'ns3::Callback< void, ns3::Ptr< ns3::Ipv4Route >, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', [], is_const=True) ## aodv-rqueue.h (module 'aodv'): void ns3::aodv::QueueEntry::SetErrorCallback(ns3::Callback<void, ns3::Ptr<ns3::Packet const>, ns3::Ipv4Header const&, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ecb) [member function] cls.add_method('SetErrorCallback', 'void', [param('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ecb')]) ## aodv-rqueue.h (module 'aodv'): void ns3::aodv::QueueEntry::SetExpireTime(ns3::Time exp) [member function] cls.add_method('SetExpireTime', 'void', [param('ns3::Time', 'exp')]) ## aodv-rqueue.h (module 'aodv'): void ns3::aodv::QueueEntry::SetIpv4Header(ns3::Ipv4Header h) [member function] cls.add_method('SetIpv4Header', 'void', [param('ns3::Ipv4Header', 'h')]) ## aodv-rqueue.h (module 'aodv'): void ns3::aodv::QueueEntry::SetPacket(ns3::Ptr<ns3::Packet const> p) [member function] cls.add_method('SetPacket', 'void', [param('ns3::Ptr< ns3::Packet const >', 'p')]) ## aodv-rqueue.h (module 'aodv'): void ns3::aodv::QueueEntry::SetUnicastForwardCallback(ns3::Callback<void, ns3::Ptr<ns3::Ipv4Route>, ns3::Ptr<ns3::Packet const>, ns3::Ipv4Header const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ucb) [member function] cls.add_method('SetUnicastForwardCallback', 'void', [param('ns3::Callback< void, ns3::Ptr< ns3::Ipv4Route >, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ucb')]) return def register_Ns3AodvRequestQueue_methods(root_module, cls): ## aodv-rqueue.h (module 'aodv'): ns3::aodv::RequestQueue::RequestQueue(ns3::aodv::RequestQueue const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::RequestQueue const &', 'arg0')]) ## aodv-rqueue.h (module 'aodv'): ns3::aodv::RequestQueue::RequestQueue(uint32_t maxLen, ns3::Time routeToQueueTimeout) [constructor] cls.add_constructor([param('uint32_t', 'maxLen'), param('ns3::Time', 'routeToQueueTimeout')]) ## aodv-rqueue.h (module 'aodv'): bool ns3::aodv::RequestQueue::Dequeue(ns3::Ipv4Address dst, ns3::aodv::QueueEntry & entry) [member function] cls.add_method('Dequeue', 'bool', [param('ns3::Ipv4Address', 'dst'), param('ns3::aodv::QueueEntry &', 'entry')]) ## aodv-rqueue.h (module 'aodv'): void ns3::aodv::RequestQueue::DropPacketWithDst(ns3::Ipv4Address dst) [member function] cls.add_method('DropPacketWithDst', 'void', [param('ns3::Ipv4Address', 'dst')]) ## aodv-rqueue.h (module 'aodv'): bool ns3::aodv::RequestQueue::Enqueue(ns3::aodv::QueueEntry & entry) [member function] cls.add_method('Enqueue', 'bool', [param('ns3::aodv::QueueEntry &', 'entry')]) ## aodv-rqueue.h (module 'aodv'): bool ns3::aodv::RequestQueue::Find(ns3::Ipv4Address dst) [member function] cls.add_method('Find', 'bool', [param('ns3::Ipv4Address', 'dst')]) ## aodv-rqueue.h (module 'aodv'): uint32_t ns3::aodv::RequestQueue::GetMaxQueueLen() const [member function] cls.add_method('GetMaxQueueLen', 'uint32_t', [], is_const=True) ## aodv-rqueue.h (module 'aodv'): ns3::Time ns3::aodv::RequestQueue::GetQueueTimeout() const [member function] cls.add_method('GetQueueTimeout', 'ns3::Time', [], is_const=True) ## aodv-rqueue.h (module 'aodv'): uint32_t ns3::aodv::RequestQueue::GetSize() [member function] cls.add_method('GetSize', 'uint32_t', []) ## aodv-rqueue.h (module 'aodv'): void ns3::aodv::RequestQueue::SetMaxQueueLen(uint32_t len) [member function] cls.add_method('SetMaxQueueLen', 'void', [param('uint32_t', 'len')]) ## aodv-rqueue.h (module 'aodv'): void ns3::aodv::RequestQueue::SetQueueTimeout(ns3::Time t) [member function] cls.add_method('SetQueueTimeout', 'void', [param('ns3::Time', 't')]) return def register_Ns3AodvRerrHeader_methods(root_module, cls): cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## aodv-packet.h (module 'aodv'): ns3::aodv::RerrHeader::RerrHeader(ns3::aodv::RerrHeader const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::RerrHeader const &', 'arg0')]) ## aodv-packet.h (module 'aodv'): ns3::aodv::RerrHeader::RerrHeader() [constructor] cls.add_constructor([]) ## aodv-packet.h (module 'aodv'): bool ns3::aodv::RerrHeader::AddUnDestination(ns3::Ipv4Address dst, uint32_t seqNo) [member function] cls.add_method('AddUnDestination', 'bool', [param('ns3::Ipv4Address', 'dst'), param('uint32_t', 'seqNo')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RerrHeader::Clear() [member function] cls.add_method('Clear', 'void', []) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::RerrHeader::Deserialize(ns3::Buffer::Iterator start) [member function] cls.add_method('Deserialize', 'uint32_t', [param('ns3::Buffer::Iterator', 'start')], is_virtual=True) ## aodv-packet.h (module 'aodv'): uint8_t ns3::aodv::RerrHeader::GetDestCount() const [member function] cls.add_method('GetDestCount', 'uint8_t', [], is_const=True) ## aodv-packet.h (module 'aodv'): ns3::TypeId ns3::aodv::RerrHeader::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): bool ns3::aodv::RerrHeader::GetNoDelete() const [member function] cls.add_method('GetNoDelete', 'bool', [], is_const=True) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::RerrHeader::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): static ns3::TypeId ns3::aodv::RerrHeader::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RerrHeader::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): bool ns3::aodv::RerrHeader::RemoveUnDestination(std::pair<ns3::Ipv4Address,unsigned int> & un) [member function] cls.add_method('RemoveUnDestination', 'bool', [param('std::pair< ns3::Ipv4Address, unsigned int > &', 'un')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RerrHeader::Serialize(ns3::Buffer::Iterator i) const [member function] cls.add_method('Serialize', 'void', [param('ns3::Buffer::Iterator', 'i')], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RerrHeader::SetNoDelete(bool f) [member function] cls.add_method('SetNoDelete', 'void', [param('bool', 'f')]) return def register_Ns3AodvRoutingProtocol_methods(root_module, cls): ## aodv-routing-protocol.h (module 'aodv'): ns3::aodv::RoutingProtocol::RoutingProtocol(ns3::aodv::RoutingProtocol const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::RoutingProtocol const &', 'arg0')]) ## aodv-routing-protocol.h (module 'aodv'): ns3::aodv::RoutingProtocol::RoutingProtocol() [constructor] cls.add_constructor([]) ## aodv-routing-protocol.h (module 'aodv'): int64_t ns3::aodv::RoutingProtocol::AssignStreams(int64_t stream) [member function] cls.add_method('AssignStreams', 'int64_t', [param('int64_t', 'stream')]) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::DoDispose() [member function] cls.add_method('DoDispose', 'void', [], is_virtual=True) ## aodv-routing-protocol.h (module 'aodv'): bool ns3::aodv::RoutingProtocol::GetBroadcastEnable() const [member function] cls.add_method('GetBroadcastEnable', 'bool', [], is_const=True) ## aodv-routing-protocol.h (module 'aodv'): bool ns3::aodv::RoutingProtocol::GetDesinationOnlyFlag() const [member function] cls.add_method('GetDesinationOnlyFlag', 'bool', [], is_const=True) ## aodv-routing-protocol.h (module 'aodv'): bool ns3::aodv::RoutingProtocol::GetGratuitousReplyFlag() const [member function] cls.add_method('GetGratuitousReplyFlag', 'bool', [], is_const=True) ## aodv-routing-protocol.h (module 'aodv'): bool ns3::aodv::RoutingProtocol::GetHelloEnable() const [member function] cls.add_method('GetHelloEnable', 'bool', [], is_const=True) ## aodv-routing-protocol.h (module 'aodv'): uint32_t ns3::aodv::RoutingProtocol::GetMaxQueueLen() const [member function] cls.add_method('GetMaxQueueLen', 'uint32_t', [], is_const=True) ## aodv-routing-protocol.h (module 'aodv'): ns3::Time ns3::aodv::RoutingProtocol::GetMaxQueueTime() const [member function] cls.add_method('GetMaxQueueTime', 'ns3::Time', [], is_const=True) ## aodv-routing-protocol.h (module 'aodv'): static ns3::TypeId ns3::aodv::RoutingProtocol::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::NotifyAddAddress(uint32_t interface, ns3::Ipv4InterfaceAddress address) [member function] cls.add_method('NotifyAddAddress', 'void', [param('uint32_t', 'interface'), param('ns3::Ipv4InterfaceAddress', 'address')], is_virtual=True) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::NotifyInterfaceDown(uint32_t interface) [member function] cls.add_method('NotifyInterfaceDown', 'void', [param('uint32_t', 'interface')], is_virtual=True) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::NotifyInterfaceUp(uint32_t interface) [member function] cls.add_method('NotifyInterfaceUp', 'void', [param('uint32_t', 'interface')], is_virtual=True) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::NotifyRemoveAddress(uint32_t interface, ns3::Ipv4InterfaceAddress address) [member function] cls.add_method('NotifyRemoveAddress', 'void', [param('uint32_t', 'interface'), param('ns3::Ipv4InterfaceAddress', 'address')], is_virtual=True) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::PrintRoutingTable(ns3::Ptr<ns3::OutputStreamWrapper> stream, ns3::Time::Unit unit=::ns3::Time::S) const [member function] cls.add_method('PrintRoutingTable', 'void', [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream'), param('ns3::Time::Unit', 'unit', default_value='::ns3::Time::S')], is_const=True, is_virtual=True) ## aodv-routing-protocol.h (module 'aodv'): bool ns3::aodv::RoutingProtocol::RouteInput(ns3::Ptr<ns3::Packet const> p, ns3::Ipv4Header const & header, ns3::Ptr<const ns3::NetDevice> idev, ns3::Callback<void, ns3::Ptr<ns3::Ipv4Route>, ns3::Ptr<ns3::Packet const>, ns3::Ipv4Header const&, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ucb, ns3::Callback<void,ns3::Ptr<ns3::Ipv4MulticastRoute>,ns3::Ptr<const ns3::Packet>,const ns3::Ipv4Header&,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> mcb, ns3::Callback<void,ns3::Ptr<const ns3::Packet>,const ns3::Ipv4Header&,unsigned int,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty,ns3::empty> lcb, ns3::Callback<void, ns3::Ptr<ns3::Packet const>, ns3::Ipv4Header const&, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty> ecb) [member function] cls.add_method('RouteInput', 'bool', [param('ns3::Ptr< ns3::Packet const >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::NetDevice const >', 'idev'), param('ns3::Callback< void, ns3::Ptr< ns3::Ipv4Route >, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ucb'), param('ns3::Callback< void, ns3::Ptr< ns3::Ipv4MulticastRoute >, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'mcb'), param('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, unsigned int, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'lcb'), param('ns3::Callback< void, ns3::Ptr< ns3::Packet const >, ns3::Ipv4Header const &, ns3::Socket::SocketErrno, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty, ns3::empty >', 'ecb')], is_virtual=True) ## aodv-routing-protocol.h (module 'aodv'): ns3::Ptr<ns3::Ipv4Route> ns3::aodv::RoutingProtocol::RouteOutput(ns3::Ptr<ns3::Packet> p, ns3::Ipv4Header const & header, ns3::Ptr<ns3::NetDevice> oif, ns3::Socket::SocketErrno & sockerr) [member function] cls.add_method('RouteOutput', 'ns3::Ptr< ns3::Ipv4Route >', [param('ns3::Ptr< ns3::Packet >', 'p'), param('ns3::Ipv4Header const &', 'header'), param('ns3::Ptr< ns3::NetDevice >', 'oif'), param('ns3::Socket::SocketErrno &', 'sockerr')], is_virtual=True) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::SetBroadcastEnable(bool f) [member function] cls.add_method('SetBroadcastEnable', 'void', [param('bool', 'f')]) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::SetDesinationOnlyFlag(bool f) [member function] cls.add_method('SetDesinationOnlyFlag', 'void', [param('bool', 'f')]) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::SetGratuitousReplyFlag(bool f) [member function] cls.add_method('SetGratuitousReplyFlag', 'void', [param('bool', 'f')]) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::SetHelloEnable(bool f) [member function] cls.add_method('SetHelloEnable', 'void', [param('bool', 'f')]) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::SetIpv4(ns3::Ptr<ns3::Ipv4> ipv4) [member function] cls.add_method('SetIpv4', 'void', [param('ns3::Ptr< ns3::Ipv4 >', 'ipv4')], is_virtual=True) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::SetMaxQueueLen(uint32_t len) [member function] cls.add_method('SetMaxQueueLen', 'void', [param('uint32_t', 'len')]) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::SetMaxQueueTime(ns3::Time t) [member function] cls.add_method('SetMaxQueueTime', 'void', [param('ns3::Time', 't')]) ## aodv-routing-protocol.h (module 'aodv'): ns3::aodv::RoutingProtocol::AODV_PORT [variable] cls.add_static_attribute('AODV_PORT', 'uint32_t const', is_const=True) ## aodv-routing-protocol.h (module 'aodv'): void ns3::aodv::RoutingProtocol::DoInitialize() [member function] cls.add_method('DoInitialize', 'void', [], visibility='protected', is_virtual=True) return def register_Ns3AodvRoutingTable_methods(root_module, cls): ## aodv-rtable.h (module 'aodv'): ns3::aodv::RoutingTable::RoutingTable(ns3::aodv::RoutingTable const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::RoutingTable const &', 'arg0')]) ## aodv-rtable.h (module 'aodv'): ns3::aodv::RoutingTable::RoutingTable(ns3::Time t) [constructor] cls.add_constructor([param('ns3::Time', 't')]) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTable::AddRoute(ns3::aodv::RoutingTableEntry & r) [member function] cls.add_method('AddRoute', 'bool', [param('ns3::aodv::RoutingTableEntry &', 'r')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTable::Clear() [member function] cls.add_method('Clear', 'void', []) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTable::DeleteAllRoutesFromInterface(ns3::Ipv4InterfaceAddress iface) [member function] cls.add_method('DeleteAllRoutesFromInterface', 'void', [param('ns3::Ipv4InterfaceAddress', 'iface')]) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTable::DeleteRoute(ns3::Ipv4Address dst) [member function] cls.add_method('DeleteRoute', 'bool', [param('ns3::Ipv4Address', 'dst')]) ## aodv-rtable.h (module 'aodv'): ns3::Time ns3::aodv::RoutingTable::GetBadLinkLifetime() const [member function] cls.add_method('GetBadLinkLifetime', 'ns3::Time', [], is_const=True) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTable::GetListOfDestinationWithNextHop(ns3::Ipv4Address nextHop, std::map<ns3::Ipv4Address, unsigned int, std::less<ns3::Ipv4Address>, std::allocator<std::pair<ns3::Ipv4Address const, unsigned int> > > & unreachable) [member function] cls.add_method('GetListOfDestinationWithNextHop', 'void', [param('ns3::Ipv4Address', 'nextHop'), param('std::map< ns3::Ipv4Address, unsigned int > &', 'unreachable')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTable::InvalidateRoutesWithDst(std::map<ns3::Ipv4Address, unsigned int, std::less<ns3::Ipv4Address>, std::allocator<std::pair<ns3::Ipv4Address const, unsigned int> > > const & unreachable) [member function] cls.add_method('InvalidateRoutesWithDst', 'void', [param('std::map< ns3::Ipv4Address, unsigned int > const &', 'unreachable')]) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTable::LookupRoute(ns3::Ipv4Address dst, ns3::aodv::RoutingTableEntry & rt) [member function] cls.add_method('LookupRoute', 'bool', [param('ns3::Ipv4Address', 'dst'), param('ns3::aodv::RoutingTableEntry &', 'rt')]) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTable::LookupValidRoute(ns3::Ipv4Address dst, ns3::aodv::RoutingTableEntry & rt) [member function] cls.add_method('LookupValidRoute', 'bool', [param('ns3::Ipv4Address', 'dst'), param('ns3::aodv::RoutingTableEntry &', 'rt')]) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTable::MarkLinkAsUnidirectional(ns3::Ipv4Address neighbor, ns3::Time blacklistTimeout) [member function] cls.add_method('MarkLinkAsUnidirectional', 'bool', [param('ns3::Ipv4Address', 'neighbor'), param('ns3::Time', 'blacklistTimeout')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTable::Print(ns3::Ptr<ns3::OutputStreamWrapper> stream) const [member function] cls.add_method('Print', 'void', [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream')], is_const=True) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTable::Purge() [member function] cls.add_method('Purge', 'void', []) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTable::SetBadLinkLifetime(ns3::Time t) [member function] cls.add_method('SetBadLinkLifetime', 'void', [param('ns3::Time', 't')]) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTable::SetEntryState(ns3::Ipv4Address dst, ns3::aodv::RouteFlags state) [member function] cls.add_method('SetEntryState', 'bool', [param('ns3::Ipv4Address', 'dst'), param('ns3::aodv::RouteFlags', 'state')]) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTable::Update(ns3::aodv::RoutingTableEntry & rt) [member function] cls.add_method('Update', 'bool', [param('ns3::aodv::RoutingTableEntry &', 'rt')]) return def register_Ns3AodvRoutingTableEntry_methods(root_module, cls): ## aodv-rtable.h (module 'aodv'): ns3::aodv::RoutingTableEntry::RoutingTableEntry(ns3::aodv::RoutingTableEntry const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::RoutingTableEntry const &', 'arg0')]) ## aodv-rtable.h (module 'aodv'): ns3::aodv::RoutingTableEntry::RoutingTableEntry(ns3::Ptr<ns3::NetDevice> dev=0, ns3::Ipv4Address dst=ns3::Ipv4Address(), bool vSeqNo=false, uint32_t m_seqNo=0, ns3::Ipv4InterfaceAddress iface=ns3::Ipv4InterfaceAddress(), uint16_t hops=0, ns3::Ipv4Address nextHop=ns3::Ipv4Address(), ns3::Time lifetime=ns3::Simulator::Now( )) [constructor] cls.add_constructor([param('ns3::Ptr< ns3::NetDevice >', 'dev', default_value='0'), param('ns3::Ipv4Address', 'dst', default_value='ns3::Ipv4Address()'), param('bool', 'vSeqNo', default_value='false'), param('uint32_t', 'm_seqNo', default_value='0'), param('ns3::Ipv4InterfaceAddress', 'iface', default_value='ns3::Ipv4InterfaceAddress()'), param('uint16_t', 'hops', default_value='0'), param('ns3::Ipv4Address', 'nextHop', default_value='ns3::Ipv4Address()'), param('ns3::Time', 'lifetime', default_value='ns3::Simulator::Now( )')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::DeleteAllPrecursors() [member function] cls.add_method('DeleteAllPrecursors', 'void', []) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTableEntry::DeletePrecursor(ns3::Ipv4Address id) [member function] cls.add_method('DeletePrecursor', 'bool', [param('ns3::Ipv4Address', 'id')]) ## aodv-rtable.h (module 'aodv'): ns3::Time ns3::aodv::RoutingTableEntry::GetBlacklistTimeout() const [member function] cls.add_method('GetBlacklistTimeout', 'ns3::Time', [], is_const=True) ## aodv-rtable.h (module 'aodv'): ns3::Ipv4Address ns3::aodv::RoutingTableEntry::GetDestination() const [member function] cls.add_method('GetDestination', 'ns3::Ipv4Address', [], is_const=True) ## aodv-rtable.h (module 'aodv'): ns3::aodv::RouteFlags ns3::aodv::RoutingTableEntry::GetFlag() const [member function] cls.add_method('GetFlag', 'ns3::aodv::RouteFlags', [], is_const=True) ## aodv-rtable.h (module 'aodv'): uint16_t ns3::aodv::RoutingTableEntry::GetHop() const [member function] cls.add_method('GetHop', 'uint16_t', [], is_const=True) ## aodv-rtable.h (module 'aodv'): ns3::Ipv4InterfaceAddress ns3::aodv::RoutingTableEntry::GetInterface() const [member function] cls.add_method('GetInterface', 'ns3::Ipv4InterfaceAddress', [], is_const=True) ## aodv-rtable.h (module 'aodv'): ns3::Time ns3::aodv::RoutingTableEntry::GetLifeTime() const [member function] cls.add_method('GetLifeTime', 'ns3::Time', [], is_const=True) ## aodv-rtable.h (module 'aodv'): ns3::Ipv4Address ns3::aodv::RoutingTableEntry::GetNextHop() const [member function] cls.add_method('GetNextHop', 'ns3::Ipv4Address', [], is_const=True) ## aodv-rtable.h (module 'aodv'): ns3::Ptr<ns3::NetDevice> ns3::aodv::RoutingTableEntry::GetOutputDevice() const [member function] cls.add_method('GetOutputDevice', 'ns3::Ptr< ns3::NetDevice >', [], is_const=True) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::GetPrecursors(std::vector<ns3::Ipv4Address, std::allocator<ns3::Ipv4Address> > & prec) const [member function] cls.add_method('GetPrecursors', 'void', [param('std::vector< ns3::Ipv4Address > &', 'prec')], is_const=True) ## aodv-rtable.h (module 'aodv'): ns3::Ptr<ns3::Ipv4Route> ns3::aodv::RoutingTableEntry::GetRoute() const [member function] cls.add_method('GetRoute', 'ns3::Ptr< ns3::Ipv4Route >', [], is_const=True) ## aodv-rtable.h (module 'aodv'): uint8_t ns3::aodv::RoutingTableEntry::GetRreqCnt() const [member function] cls.add_method('GetRreqCnt', 'uint8_t', [], is_const=True) ## aodv-rtable.h (module 'aodv'): uint32_t ns3::aodv::RoutingTableEntry::GetSeqNo() const [member function] cls.add_method('GetSeqNo', 'uint32_t', [], is_const=True) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTableEntry::GetValidSeqNo() const [member function] cls.add_method('GetValidSeqNo', 'bool', [], is_const=True) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::IncrementRreqCnt() [member function] cls.add_method('IncrementRreqCnt', 'void', []) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTableEntry::InsertPrecursor(ns3::Ipv4Address id) [member function] cls.add_method('InsertPrecursor', 'bool', [param('ns3::Ipv4Address', 'id')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::Invalidate(ns3::Time badLinkLifetime) [member function] cls.add_method('Invalidate', 'void', [param('ns3::Time', 'badLinkLifetime')]) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTableEntry::IsPrecursorListEmpty() const [member function] cls.add_method('IsPrecursorListEmpty', 'bool', [], is_const=True) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTableEntry::IsUnidirectional() const [member function] cls.add_method('IsUnidirectional', 'bool', [], is_const=True) ## aodv-rtable.h (module 'aodv'): bool ns3::aodv::RoutingTableEntry::LookupPrecursor(ns3::Ipv4Address id) [member function] cls.add_method('LookupPrecursor', 'bool', [param('ns3::Ipv4Address', 'id')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::Print(ns3::Ptr<ns3::OutputStreamWrapper> stream) const [member function] cls.add_method('Print', 'void', [param('ns3::Ptr< ns3::OutputStreamWrapper >', 'stream')], is_const=True) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::SetBlacklistTimeout(ns3::Time t) [member function] cls.add_method('SetBlacklistTimeout', 'void', [param('ns3::Time', 't')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::SetFlag(ns3::aodv::RouteFlags flag) [member function] cls.add_method('SetFlag', 'void', [param('ns3::aodv::RouteFlags', 'flag')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::SetHop(uint16_t hop) [member function] cls.add_method('SetHop', 'void', [param('uint16_t', 'hop')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::SetInterface(ns3::Ipv4InterfaceAddress iface) [member function] cls.add_method('SetInterface', 'void', [param('ns3::Ipv4InterfaceAddress', 'iface')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::SetLifeTime(ns3::Time lt) [member function] cls.add_method('SetLifeTime', 'void', [param('ns3::Time', 'lt')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::SetNextHop(ns3::Ipv4Address nextHop) [member function] cls.add_method('SetNextHop', 'void', [param('ns3::Ipv4Address', 'nextHop')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::SetOutputDevice(ns3::Ptr<ns3::NetDevice> dev) [member function] cls.add_method('SetOutputDevice', 'void', [param('ns3::Ptr< ns3::NetDevice >', 'dev')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::SetRoute(ns3::Ptr<ns3::Ipv4Route> r) [member function] cls.add_method('SetRoute', 'void', [param('ns3::Ptr< ns3::Ipv4Route >', 'r')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::SetRreqCnt(uint8_t n) [member function] cls.add_method('SetRreqCnt', 'void', [param('uint8_t', 'n')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::SetSeqNo(uint32_t sn) [member function] cls.add_method('SetSeqNo', 'void', [param('uint32_t', 'sn')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::SetUnidirectional(bool u) [member function] cls.add_method('SetUnidirectional', 'void', [param('bool', 'u')]) ## aodv-rtable.h (module 'aodv'): void ns3::aodv::RoutingTableEntry::SetValidSeqNo(bool s) [member function] cls.add_method('SetValidSeqNo', 'void', [param('bool', 's')]) ## aodv-rtable.h (module 'aodv'): ns3::aodv::RoutingTableEntry::m_ackTimer [variable] cls.add_instance_attribute('m_ackTimer', 'ns3::Timer', is_const=False) return def register_Ns3AodvRrepAckHeader_methods(root_module, cls): cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## aodv-packet.h (module 'aodv'): ns3::aodv::RrepAckHeader::RrepAckHeader(ns3::aodv::RrepAckHeader const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::RrepAckHeader const &', 'arg0')]) ## aodv-packet.h (module 'aodv'): ns3::aodv::RrepAckHeader::RrepAckHeader() [constructor] cls.add_constructor([]) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::RrepAckHeader::Deserialize(ns3::Buffer::Iterator start) [member function] cls.add_method('Deserialize', 'uint32_t', [param('ns3::Buffer::Iterator', 'start')], is_virtual=True) ## aodv-packet.h (module 'aodv'): ns3::TypeId ns3::aodv::RrepAckHeader::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::RrepAckHeader::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): static ns3::TypeId ns3::aodv::RrepAckHeader::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RrepAckHeader::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RrepAckHeader::Serialize(ns3::Buffer::Iterator start) const [member function] cls.add_method('Serialize', 'void', [param('ns3::Buffer::Iterator', 'start')], is_const=True, is_virtual=True) return def register_Ns3AodvRrepHeader_methods(root_module, cls): cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## aodv-packet.h (module 'aodv'): ns3::aodv::RrepHeader::RrepHeader(ns3::aodv::RrepHeader const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::RrepHeader const &', 'arg0')]) ## aodv-packet.h (module 'aodv'): ns3::aodv::RrepHeader::RrepHeader(uint8_t prefixSize=0, uint8_t hopCount=0, ns3::Ipv4Address dst=ns3::Ipv4Address(), uint32_t dstSeqNo=0, ns3::Ipv4Address origin=ns3::Ipv4Address(), ns3::Time lifetime=ns3::MilliSeconds( )) [constructor] cls.add_constructor([param('uint8_t', 'prefixSize', default_value='0'), param('uint8_t', 'hopCount', default_value='0'), param('ns3::Ipv4Address', 'dst', default_value='ns3::Ipv4Address()'), param('uint32_t', 'dstSeqNo', default_value='0'), param('ns3::Ipv4Address', 'origin', default_value='ns3::Ipv4Address()'), param('ns3::Time', 'lifetime', default_value='ns3::MilliSeconds(0)')]) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::RrepHeader::Deserialize(ns3::Buffer::Iterator start) [member function] cls.add_method('Deserialize', 'uint32_t', [param('ns3::Buffer::Iterator', 'start')], is_virtual=True) ## aodv-packet.h (module 'aodv'): bool ns3::aodv::RrepHeader::GetAckRequired() const [member function] cls.add_method('GetAckRequired', 'bool', [], is_const=True) ## aodv-packet.h (module 'aodv'): ns3::Ipv4Address ns3::aodv::RrepHeader::GetDst() const [member function] cls.add_method('GetDst', 'ns3::Ipv4Address', [], is_const=True) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::RrepHeader::GetDstSeqno() const [member function] cls.add_method('GetDstSeqno', 'uint32_t', [], is_const=True) ## aodv-packet.h (module 'aodv'): uint8_t ns3::aodv::RrepHeader::GetHopCount() const [member function] cls.add_method('GetHopCount', 'uint8_t', [], is_const=True) ## aodv-packet.h (module 'aodv'): ns3::TypeId ns3::aodv::RrepHeader::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): ns3::Time ns3::aodv::RrepHeader::GetLifeTime() const [member function] cls.add_method('GetLifeTime', 'ns3::Time', [], is_const=True) ## aodv-packet.h (module 'aodv'): ns3::Ipv4Address ns3::aodv::RrepHeader::GetOrigin() const [member function] cls.add_method('GetOrigin', 'ns3::Ipv4Address', [], is_const=True) ## aodv-packet.h (module 'aodv'): uint8_t ns3::aodv::RrepHeader::GetPrefixSize() const [member function] cls.add_method('GetPrefixSize', 'uint8_t', [], is_const=True) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::RrepHeader::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): static ns3::TypeId ns3::aodv::RrepHeader::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RrepHeader::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RrepHeader::Serialize(ns3::Buffer::Iterator start) const [member function] cls.add_method('Serialize', 'void', [param('ns3::Buffer::Iterator', 'start')], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RrepHeader::SetAckRequired(bool f) [member function] cls.add_method('SetAckRequired', 'void', [param('bool', 'f')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RrepHeader::SetDst(ns3::Ipv4Address a) [member function] cls.add_method('SetDst', 'void', [param('ns3::Ipv4Address', 'a')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RrepHeader::SetDstSeqno(uint32_t s) [member function] cls.add_method('SetDstSeqno', 'void', [param('uint32_t', 's')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RrepHeader::SetHello(ns3::Ipv4Address src, uint32_t srcSeqNo, ns3::Time lifetime) [member function] cls.add_method('SetHello', 'void', [param('ns3::Ipv4Address', 'src'), param('uint32_t', 'srcSeqNo'), param('ns3::Time', 'lifetime')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RrepHeader::SetHopCount(uint8_t count) [member function] cls.add_method('SetHopCount', 'void', [param('uint8_t', 'count')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RrepHeader::SetLifeTime(ns3::Time t) [member function] cls.add_method('SetLifeTime', 'void', [param('ns3::Time', 't')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RrepHeader::SetOrigin(ns3::Ipv4Address a) [member function] cls.add_method('SetOrigin', 'void', [param('ns3::Ipv4Address', 'a')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RrepHeader::SetPrefixSize(uint8_t sz) [member function] cls.add_method('SetPrefixSize', 'void', [param('uint8_t', 'sz')]) return def register_Ns3AodvRreqHeader_methods(root_module, cls): cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## aodv-packet.h (module 'aodv'): ns3::aodv::RreqHeader::RreqHeader(ns3::aodv::RreqHeader const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::RreqHeader const &', 'arg0')]) ## aodv-packet.h (module 'aodv'): ns3::aodv::RreqHeader::RreqHeader(uint8_t flags=0, uint8_t reserved=0, uint8_t hopCount=0, uint32_t requestID=0, ns3::Ipv4Address dst=ns3::Ipv4Address(), uint32_t dstSeqNo=0, ns3::Ipv4Address origin=ns3::Ipv4Address(), uint32_t originSeqNo=0) [constructor] cls.add_constructor([param('uint8_t', 'flags', default_value='0'), param('uint8_t', 'reserved', default_value='0'), param('uint8_t', 'hopCount', default_value='0'), param('uint32_t', 'requestID', default_value='0'), param('ns3::Ipv4Address', 'dst', default_value='ns3::Ipv4Address()'), param('uint32_t', 'dstSeqNo', default_value='0'), param('ns3::Ipv4Address', 'origin', default_value='ns3::Ipv4Address()'), param('uint32_t', 'originSeqNo', default_value='0')]) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::RreqHeader::Deserialize(ns3::Buffer::Iterator start) [member function] cls.add_method('Deserialize', 'uint32_t', [param('ns3::Buffer::Iterator', 'start')], is_virtual=True) ## aodv-packet.h (module 'aodv'): bool ns3::aodv::RreqHeader::GetDestinationOnly() const [member function] cls.add_method('GetDestinationOnly', 'bool', [], is_const=True) ## aodv-packet.h (module 'aodv'): ns3::Ipv4Address ns3::aodv::RreqHeader::GetDst() const [member function] cls.add_method('GetDst', 'ns3::Ipv4Address', [], is_const=True) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::RreqHeader::GetDstSeqno() const [member function] cls.add_method('GetDstSeqno', 'uint32_t', [], is_const=True) ## aodv-packet.h (module 'aodv'): bool ns3::aodv::RreqHeader::GetGratiousRrep() const [member function] cls.add_method('GetGratiousRrep', 'bool', [], is_const=True) ## aodv-packet.h (module 'aodv'): uint8_t ns3::aodv::RreqHeader::GetHopCount() const [member function] cls.add_method('GetHopCount', 'uint8_t', [], is_const=True) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::RreqHeader::GetId() const [member function] cls.add_method('GetId', 'uint32_t', [], is_const=True) ## aodv-packet.h (module 'aodv'): ns3::TypeId ns3::aodv::RreqHeader::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): ns3::Ipv4Address ns3::aodv::RreqHeader::GetOrigin() const [member function] cls.add_method('GetOrigin', 'ns3::Ipv4Address', [], is_const=True) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::RreqHeader::GetOriginSeqno() const [member function] cls.add_method('GetOriginSeqno', 'uint32_t', [], is_const=True) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::RreqHeader::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): static ns3::TypeId ns3::aodv::RreqHeader::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## aodv-packet.h (module 'aodv'): bool ns3::aodv::RreqHeader::GetUnknownSeqno() const [member function] cls.add_method('GetUnknownSeqno', 'bool', [], is_const=True) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RreqHeader::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RreqHeader::Serialize(ns3::Buffer::Iterator start) const [member function] cls.add_method('Serialize', 'void', [param('ns3::Buffer::Iterator', 'start')], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RreqHeader::SetDestinationOnly(bool f) [member function] cls.add_method('SetDestinationOnly', 'void', [param('bool', 'f')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RreqHeader::SetDst(ns3::Ipv4Address a) [member function] cls.add_method('SetDst', 'void', [param('ns3::Ipv4Address', 'a')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RreqHeader::SetDstSeqno(uint32_t s) [member function] cls.add_method('SetDstSeqno', 'void', [param('uint32_t', 's')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RreqHeader::SetGratiousRrep(bool f) [member function] cls.add_method('SetGratiousRrep', 'void', [param('bool', 'f')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RreqHeader::SetHopCount(uint8_t count) [member function] cls.add_method('SetHopCount', 'void', [param('uint8_t', 'count')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RreqHeader::SetId(uint32_t id) [member function] cls.add_method('SetId', 'void', [param('uint32_t', 'id')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RreqHeader::SetOrigin(ns3::Ipv4Address a) [member function] cls.add_method('SetOrigin', 'void', [param('ns3::Ipv4Address', 'a')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RreqHeader::SetOriginSeqno(uint32_t s) [member function] cls.add_method('SetOriginSeqno', 'void', [param('uint32_t', 's')]) ## aodv-packet.h (module 'aodv'): void ns3::aodv::RreqHeader::SetUnknownSeqno(bool f) [member function] cls.add_method('SetUnknownSeqno', 'void', [param('bool', 'f')]) return def register_Ns3AodvTypeHeader_methods(root_module, cls): cls.add_output_stream_operator() cls.add_binary_comparison_operator('==') ## aodv-packet.h (module 'aodv'): ns3::aodv::TypeHeader::TypeHeader(ns3::aodv::TypeHeader const & arg0) [copy constructor] cls.add_constructor([param('ns3::aodv::TypeHeader const &', 'arg0')]) ## aodv-packet.h (module 'aodv'): ns3::aodv::TypeHeader::TypeHeader(ns3::aodv::MessageType t=::ns3::aodv::AODVTYPE_RREQ) [constructor] cls.add_constructor([param('ns3::aodv::MessageType', 't', default_value='::ns3::aodv::AODVTYPE_RREQ')]) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::TypeHeader::Deserialize(ns3::Buffer::Iterator start) [member function] cls.add_method('Deserialize', 'uint32_t', [param('ns3::Buffer::Iterator', 'start')], is_virtual=True) ## aodv-packet.h (module 'aodv'): ns3::aodv::MessageType ns3::aodv::TypeHeader::Get() const [member function] cls.add_method('Get', 'ns3::aodv::MessageType', [], is_const=True) ## aodv-packet.h (module 'aodv'): ns3::TypeId ns3::aodv::TypeHeader::GetInstanceTypeId() const [member function] cls.add_method('GetInstanceTypeId', 'ns3::TypeId', [], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): uint32_t ns3::aodv::TypeHeader::GetSerializedSize() const [member function] cls.add_method('GetSerializedSize', 'uint32_t', [], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): static ns3::TypeId ns3::aodv::TypeHeader::GetTypeId() [member function] cls.add_method('GetTypeId', 'ns3::TypeId', [], is_static=True) ## aodv-packet.h (module 'aodv'): bool ns3::aodv::TypeHeader::IsValid() const [member function] cls.add_method('IsValid', 'bool', [], is_const=True) ## aodv-packet.h (module 'aodv'): void ns3::aodv::TypeHeader::Print(std::ostream & os) const [member function] cls.add_method('Print', 'void', [param('std::ostream &', 'os')], is_const=True, is_virtual=True) ## aodv-packet.h (module 'aodv'): void ns3::aodv::TypeHeader::Serialize(ns3::Buffer::Iterator start) const [member function] cls.add_method('Serialize', 'void', [param('ns3::Buffer::Iterator', 'start')], is_const=True, is_virtual=True) return def register_functions(root_module): module = root_module register_functions_ns3_FatalImpl(module.get_submodule('FatalImpl'), root_module) register_functions_ns3_Hash(module.get_submodule('Hash'), root_module) register_functions_ns3_TracedValueCallback(module.get_submodule('TracedValueCallback'), root_module) register_functions_ns3_aodv(module.get_submodule('aodv'), root_module) return def register_functions_ns3_FatalImpl(module, root_module): return def register_functions_ns3_Hash(module, root_module): register_functions_ns3_Hash_Function(module.get_submodule('Function'), root_module) return def register_functions_ns3_Hash_Function(module, root_module): return def register_functions_ns3_TracedValueCallback(module, root_module): return def register_functions_ns3_aodv(module, root_module): return def main(): out = FileCodeSink(sys.stdout) root_module = module_init() register_types(root_module) register_methods(root_module) register_functions(root_module) root_module.generate(out) if __name__ == '__main__': main()
gpl-2.0
victoredwardocallaghan/xen
tools/python/xen/xend/xenstore/xswatch.py
48
2418
# Copyright (C) 2005 Christian Limpach <Christian.Limpach@cl.cam.ac.uk> # Copyright (C) 2005 XenSource Ltd # This file is subject to the terms and conditions of the GNU General # Public License. See the file "COPYING" in the main directory of # this archive for more details. import errno import threading from xen.xend.xenstore.xsutil import xshandle class xswatch: ## # Create a watch on the given path in the store. The watch will fire # immediately, then subsequently each time the watched path is changed, # until the watch is deregistered, either by the return value from the # watch callback being False, or by an explicit call to unwatch. # # @param fn The function to be called when the watch fires. This function # should take the path that has changed as its first argument, followed by # the extra arguments given to this constructor, if any. It should return # True if the watch is to remain registered, or False if it is to be # deregistered. # def __init__(self, path, fn, *args, **kwargs): self.path = path self.fn = fn self.args = args self.kwargs = kwargs watchStart() xs.watch(path, self) def unwatch(self): xs.unwatch(self.path, self) watchThread = None xs = None xslock = threading.Lock() def watchStart(): global watchThread global xs xslock.acquire() try: if watchThread: return xs = xshandle() watchThread = threading.Thread(name="Watcher", target=watchMain) watchThread.setDaemon(True) watchThread.start() finally: xslock.release() def watchMain(): while True: try: we = xs.read_watch() watch = we[1] res = watch.fn(we[0], *watch.args, **watch.kwargs) if not res: try: watch.unwatch() except RuntimeError, exn: if exn.args[0] == errno.ENOENT: # The watch has already been unregistered -- that's # fine. pass else: raise except: pass # Ignore this exception -- there's no point throwing it # further on because that will just kill the watcher thread, # which achieves nothing.
gpl-2.0
Qalthos/ansible
lib/ansible/modules/windows/win_ping.py
146
1451
#!/usr/bin/python # -*- coding: utf-8 -*- # Copyright: (c) 2012, Michael DeHaan <michael.dehaan@gmail.com>, and others # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) # this is a windows documentation stub. actual code lives in the .ps1 # file of the same name ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['stableinterface'], 'supported_by': 'core'} DOCUMENTATION = r''' --- module: win_ping version_added: "1.7" short_description: A windows version of the classic ping module description: - Checks management connectivity of a windows host. - This is NOT ICMP ping, this is just a trivial test module. - For non-Windows targets, use the M(ping) module instead. - For Network targets, use the M(net_ping) module instead. options: data: description: - Alternate data to return instead of 'pong'. - If this parameter is set to C(crash), the module will cause an exception. type: str default: pong seealso: - module: ping author: - Chris Church (@cchurch) ''' EXAMPLES = r''' # Test connectivity to a windows host # ansible winserver -m win_ping - name: Example from an Ansible Playbook win_ping: - name: Induce an exception to see what happens win_ping: data: crash ''' RETURN = r''' ping: description: Value provided with the data parameter. returned: success type: str sample: pong '''
gpl-3.0
Purg/kwiver
vital/bindings/python/vital/tests/test_landmark.py
1
9106
""" ckwg +31 Copyright 2016 by Kitware, Inc. All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: * Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. * Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. * Neither name of Kitware, Inc. nor the names of any contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ============================================================================== Tests for Landmark interface """ import ctypes import unittest import nose.tools import numpy from vital.types import Landmark, Covariance, RGBColor class TestLandmark (unittest.TestCase): C_TYPES = [ctypes.c_double, ctypes.c_float] def test_new(self): Landmark() Landmark(c_type=ctypes.c_float) Landmark([1, 1, 1]) Landmark([1, 1, 1], c_type=ctypes.c_float) Landmark(scale=10) Landmark(scale=10, c_type=ctypes.c_float) def test_type_name(self): # Double default nose.tools.assert_equal(Landmark().type_name, 'd') nose.tools.assert_equal(Landmark(c_type=ctypes.c_float).type_name, 'f') nose.tools.assert_equal(Landmark([1, 2, 2]).type_name, 'd') nose.tools.assert_equal(Landmark([1, 2, 2], c_type=ctypes.c_float).type_name, 'f') def test_get_loc(self): for ct in self.C_TYPES: print ct l = Landmark(c_type=ct) numpy.testing.assert_equal(l.loc, [[0], [0], [0]]) l = Landmark([1, 2, 3], c_type=ct) numpy.testing.assert_equal(l.loc, [[1], [2], [3]]) def test_set_loc(self): for ct in self.C_TYPES: print ct l = Landmark(c_type=ct) l.loc = [[1], [1], [1]] numpy.testing.assert_equal(l.loc, [[1], [1], [1]]) l.loc = [[9.12], [4.1], [8.3]] numpy.testing.assert_almost_equal(l.loc, [[9.12], [4.1], [8.3]], 6) def test_get_scale(self): for ct in self.C_TYPES: l = Landmark(c_type=ct) print ct nose.tools.assert_equal(l.scale, 1) l = Landmark(scale=17, c_type=ct) nose.tools.assert_equal(l.scale, 17) l = Landmark(scale=2.22, c_type=ct) nose.tools.assert_almost_equal(l.scale, 2.22, 6) l = Landmark([3, 4, 5], 44.5, ct) nose.tools.assert_almost_equal(l.scale, 44.5, 6) def test_set_scale(self): for ct in self.C_TYPES: print ct l = Landmark(c_type=ct) l.scale = 1 nose.tools.assert_equal(l.scale, 1) l.scale = 2 nose.tools.assert_equal(l.scale, 2) l.scale = 2.456 nose.tools.assert_almost_equal(l.scale, 2.456, 6) l.scale = -2 nose.tools.assert_almost_equal(l.scale, -2, 6) def t(): l.scale = 'foo' nose.tools.assert_raises(ctypes.ArgumentError, t) def test_normal(self): for ct in self.C_TYPES: print ct l = Landmark(c_type=ct) # check default numpy.testing.assert_equal(l.normal, [[0], [0], [0]]) l.normal = [[0], [1], [0]] numpy.testing.assert_equal(l.normal, [[0], [1], [0]]) def test_covariance(self): for ct in self.C_TYPES: print ct l = Landmark(c_type=ct) # check default nose.tools.assert_equal(l.covariance, Covariance(3)) # set type-aligned covariance c = Covariance(3, ct, 7) l.covariance = c nose.tools.assert_equal(l.covariance, c) # set no-necessarily-aligned covariance c = Covariance(3, init_scalar_or_matrix=7) l.covariance = c nose.tools.assert_equal(l.covariance, c) def test_color(self): for ct in self.C_TYPES: print ct l = Landmark(c_type=ct) # default nose.tools.assert_equal(l.color, RGBColor()) c = RGBColor(0, 0, 0) l.color = c nose.tools.assert_equal(l.color, c) c = RGBColor(12, 240, 120) l.color = c nose.tools.assert_equal(l.color, c) def test_observations(self): for ct in self.C_TYPES: print ct l = Landmark(c_type=ct) # default nose.tools.assert_equal(l.observations, 0) l.observations = 42 nose.tools.assert_equal(l.observations, 42) def t(): l.observations = -6 nose.tools.assert_raises(ValueError, t) def test_from_cptr(self): l = Landmark() l2 = Landmark(from_cptr=l.c_pointer) l2._destroy = lambda: None # prevent double-free nose.tools.assert_equal(l.type_name, l2.type_name) numpy.testing.assert_equal(l.loc, l2.loc) nose.tools.assert_equal(l.scale, l2.scale) l = Landmark(c_type=ctypes.c_float) l2 = Landmark(from_cptr=l.c_pointer) l2._destroy = lambda: None # prevent double-free nose.tools.assert_equal(l.type_name, l2.type_name) numpy.testing.assert_equal(l.loc, l2.loc) nose.tools.assert_equal(l.scale, l2.scale) l = Landmark([42.1, 234, 0.1234], scale=123.456789) l2 = Landmark(from_cptr=l.c_pointer) l2._destroy = lambda: None # prevent double-free nose.tools.assert_equal(l.type_name, l2.type_name) numpy.testing.assert_equal(l.loc, l2.loc) nose.tools.assert_equal(l.scale, l2.scale) def test_equal(self): for ct in self.C_TYPES: print ct l = Landmark(c_type=ct) l2 = Landmark(c_type=ct) nose.tools.assert_equal(l, l2) l = Landmark([1, 1, 1], 42.2, c_type=ct) l2 = Landmark([1, 1, 1], 42.2, c_type=ct) nose.tools.assert_equal(l, l2) norm = [0, 0.5, 0.5] covar = Covariance(3, init_scalar_or_matrix=3) color = RGBColor(2, 1, 5) obs = 43 l.normal = l2.normal = norm l.covariance = l2.covariance = covar l.color = l2.color = color l.observations = l2.observations = obs nose.tools.assert_equal(l, l2) def test_clone(self): # Should be able to clone an instance, modify either and NOT see the # change in the other l1 = Landmark([1, 2, 3], 4) l2 = l1.clone() # They should be the same at this point numpy.testing.assert_equal(l1.loc, [[1], [2], [3]]) nose.tools.assert_equal(l1.scale, 4) numpy.testing.assert_equal(l2.loc, l1.loc) nose.tools.assert_equal(l1.scale, l2.scale) l1.loc = [[5], [6], [7]] numpy.testing.assert_equal(l1.loc, [[5], [6], [7]]) numpy.testing.assert_equal(l2.loc, [[1], [2], [3]]) l2.scale = 8 nose.tools.assert_equal(l1.scale, 4) nose.tools.assert_equal(l2.scale, 8)
bsd-3-clause
40223144/w16b_test
static/Brython3.1.3-20150514-095342/Lib/_struct.py
726
13787
# # This module is a pure Python version of pypy.module.struct. # It is only imported if the vastly faster pypy.module.struct is not # compiled in. For now we keep this version for reference and # because pypy.module.struct is not ootype-backend-friendly yet. # # this module 'borrowed' from # https://bitbucket.org/pypy/pypy/src/18626459a9b2/lib_pypy/_struct.py?at=py3k-listview_str """Functions to convert between Python values and C structs. Python strings are used to hold the data representing the C struct and also as format strings to describe the layout of data in the C struct. The optional first format char indicates byte order, size and alignment: @: native order, size & alignment (default) =: native order, std. size & alignment <: little-endian, std. size & alignment >: big-endian, std. size & alignment !: same as > The remaining chars indicate types of args and must match exactly; these can be preceded by a decimal repeat count: x: pad byte (no data); c:char; b:signed byte; B:unsigned byte; h:short; H:unsigned short; i:int; I:unsigned int; l:long; L:unsigned long; f:float; d:double. Special cases (preceding decimal count indicates length): s:string (array of char); p: pascal string (with count byte). Special case (only available in native format): P:an integer type that is wide enough to hold a pointer. Special case (not in native mode unless 'long long' in platform C): q:long long; Q:unsigned long long Whitespace between formats is ignored. The variable struct.error is an exception raised on errors.""" import math, sys # TODO: XXX Find a way to get information on native sizes and alignments class StructError(Exception): pass error = StructError def unpack_int(data,index,size,le): bytes = [b for b in data[index:index+size]] if le == 'little': bytes.reverse() number = 0 for b in bytes: number = number << 8 | b return int(number) def unpack_signed_int(data,index,size,le): number = unpack_int(data,index,size,le) max = 2**(size*8) if number > 2**(size*8 - 1) - 1: number = int(-1*(max - number)) return number INFINITY = 1e200 * 1e200 NAN = INFINITY / INFINITY def unpack_char(data,index,size,le): return data[index:index+size] def pack_int(number,size,le): x=number res=[] for i in range(size): res.append(x&0xff) x >>= 8 if le == 'big': res.reverse() return bytes(res) def pack_signed_int(number,size,le): if not isinstance(number, int): raise StructError("argument for i,I,l,L,q,Q,h,H must be integer") if number > 2**(8*size-1)-1 or number < -1*2**(8*size-1): raise OverflowError("Number:%i too large to convert" % number) return pack_int(number,size,le) def pack_unsigned_int(number,size,le): if not isinstance(number, int): raise StructError("argument for i,I,l,L,q,Q,h,H must be integer") if number < 0: raise TypeError("can't convert negative long to unsigned") if number > 2**(8*size)-1: raise OverflowError("Number:%i too large to convert" % number) return pack_int(number,size,le) def pack_char(char,size,le): return bytes(char) def isinf(x): return x != 0.0 and x / 2 == x def isnan(v): return v != v*1.0 or (v == 1.0 and v == 2.0) def pack_float(x, size, le): unsigned = float_pack(x, size) result = [] for i in range(8): result.append((unsigned >> (i * 8)) & 0xFF) if le == "big": result.reverse() return bytes(result) def unpack_float(data, index, size, le): binary = [data[i] for i in range(index, index + 8)] if le == "big": binary.reverse() unsigned = 0 for i in range(8): unsigned |= binary[i] << (i * 8) return float_unpack(unsigned, size, le) def round_to_nearest(x): """Python 3 style round: round a float x to the nearest int, but unlike the builtin Python 2.x round function: - return an int, not a float - do round-half-to-even, not round-half-away-from-zero. We assume that x is finite and nonnegative; except wrong results if you use this for negative x. """ int_part = int(x) frac_part = x - int_part if frac_part > 0.5 or frac_part == 0.5 and int_part & 1 == 1: int_part += 1 return int_part def float_unpack(Q, size, le): """Convert a 32-bit or 64-bit integer created by float_pack into a Python float.""" if size == 8: MIN_EXP = -1021 # = sys.float_info.min_exp MAX_EXP = 1024 # = sys.float_info.max_exp MANT_DIG = 53 # = sys.float_info.mant_dig BITS = 64 elif size == 4: MIN_EXP = -125 # C's FLT_MIN_EXP MAX_EXP = 128 # FLT_MAX_EXP MANT_DIG = 24 # FLT_MANT_DIG BITS = 32 else: raise ValueError("invalid size value") if Q >> BITS: raise ValueError("input out of range") # extract pieces sign = Q >> BITS - 1 exp = (Q & ((1 << BITS - 1) - (1 << MANT_DIG - 1))) >> MANT_DIG - 1 mant = Q & ((1 << MANT_DIG - 1) - 1) if exp == MAX_EXP - MIN_EXP + 2: # nan or infinity result = float('nan') if mant else float('inf') elif exp == 0: # subnormal or zero result = math.ldexp(float(mant), MIN_EXP - MANT_DIG) else: # normal mant += 1 << MANT_DIG - 1 result = math.ldexp(float(mant), exp + MIN_EXP - MANT_DIG - 1) return -result if sign else result def float_pack(x, size): """Convert a Python float x into a 64-bit unsigned integer with the same byte representation.""" if size == 8: MIN_EXP = -1021 # = sys.float_info.min_exp MAX_EXP = 1024 # = sys.float_info.max_exp MANT_DIG = 53 # = sys.float_info.mant_dig BITS = 64 elif size == 4: MIN_EXP = -125 # C's FLT_MIN_EXP MAX_EXP = 128 # FLT_MAX_EXP MANT_DIG = 24 # FLT_MANT_DIG BITS = 32 else: raise ValueError("invalid size value") sign = math.copysign(1.0, x) < 0.0 if math.isinf(x): mant = 0 exp = MAX_EXP - MIN_EXP + 2 elif math.isnan(x): mant = 1 << (MANT_DIG-2) # other values possible exp = MAX_EXP - MIN_EXP + 2 elif x == 0.0: mant = 0 exp = 0 else: m, e = math.frexp(abs(x)) # abs(x) == m * 2**e exp = e - (MIN_EXP - 1) if exp > 0: # Normal case. mant = round_to_nearest(m * (1 << MANT_DIG)) mant -= 1 << MANT_DIG - 1 else: # Subnormal case. if exp + MANT_DIG - 1 >= 0: mant = round_to_nearest(m * (1 << exp + MANT_DIG - 1)) else: mant = 0 exp = 0 # Special case: rounding produced a MANT_DIG-bit mantissa. assert 0 <= mant <= 1 << MANT_DIG - 1 if mant == 1 << MANT_DIG - 1: mant = 0 exp += 1 # Raise on overflow (in some circumstances, may want to return # infinity instead). if exp >= MAX_EXP - MIN_EXP + 2: raise OverflowError("float too large to pack in this format") # check constraints assert 0 <= mant < 1 << MANT_DIG - 1 assert 0 <= exp <= MAX_EXP - MIN_EXP + 2 assert 0 <= sign <= 1 return ((sign << BITS - 1) | (exp << MANT_DIG - 1)) | mant big_endian_format = { 'x':{ 'size' : 1, 'alignment' : 0, 'pack' : None, 'unpack' : None}, 'b':{ 'size' : 1, 'alignment' : 0, 'pack' : pack_signed_int, 'unpack' : unpack_signed_int}, 'B':{ 'size' : 1, 'alignment' : 0, 'pack' : pack_unsigned_int, 'unpack' : unpack_int}, 'c':{ 'size' : 1, 'alignment' : 0, 'pack' : pack_char, 'unpack' : unpack_char}, 's':{ 'size' : 1, 'alignment' : 0, 'pack' : None, 'unpack' : None}, 'p':{ 'size' : 1, 'alignment' : 0, 'pack' : None, 'unpack' : None}, 'h':{ 'size' : 2, 'alignment' : 0, 'pack' : pack_signed_int, 'unpack' : unpack_signed_int}, 'H':{ 'size' : 2, 'alignment' : 0, 'pack' : pack_unsigned_int, 'unpack' : unpack_int}, 'i':{ 'size' : 4, 'alignment' : 0, 'pack' : pack_signed_int, 'unpack' : unpack_signed_int}, 'I':{ 'size' : 4, 'alignment' : 0, 'pack' : pack_unsigned_int, 'unpack' : unpack_int}, 'l':{ 'size' : 4, 'alignment' : 0, 'pack' : pack_signed_int, 'unpack' : unpack_signed_int}, 'L':{ 'size' : 4, 'alignment' : 0, 'pack' : pack_unsigned_int, 'unpack' : unpack_int}, 'q':{ 'size' : 8, 'alignment' : 0, 'pack' : pack_signed_int, 'unpack' : unpack_signed_int}, 'Q':{ 'size' : 8, 'alignment' : 0, 'pack' : pack_unsigned_int, 'unpack' : unpack_int}, 'f':{ 'size' : 4, 'alignment' : 0, 'pack' : pack_float, 'unpack' : unpack_float}, 'd':{ 'size' : 8, 'alignment' : 0, 'pack' : pack_float, 'unpack' : unpack_float}, } default = big_endian_format formatmode={ '<' : (default, 'little'), '>' : (default, 'big'), '!' : (default, 'big'), '=' : (default, sys.byteorder), '@' : (default, sys.byteorder) } def getmode(fmt): try: formatdef,endianness = formatmode[fmt[0]] index = 1 except (IndexError, KeyError): formatdef,endianness = formatmode['@'] index = 0 return formatdef,endianness,index def getNum(fmt,i): num=None cur = fmt[i] while ('0'<= cur ) and ( cur <= '9'): if num == None: num = int(cur) else: num = 10*num + int(cur) i += 1 cur = fmt[i] return num,i def calcsize(fmt): """calcsize(fmt) -> int Return size of C struct described by format string fmt. See struct.__doc__ for more on format strings.""" formatdef,endianness,i = getmode(fmt) num = 0 result = 0 while i<len(fmt): num,i = getNum(fmt,i) cur = fmt[i] try: format = formatdef[cur] except KeyError: raise StructError("%s is not a valid format" % cur) if num != None : result += num*format['size'] else: result += format['size'] num = 0 i += 1 return result def pack(fmt,*args): """pack(fmt, v1, v2, ...) -> string Return string containing values v1, v2, ... packed according to fmt. See struct.__doc__ for more on format strings.""" formatdef,endianness,i = getmode(fmt) args = list(args) n_args = len(args) result = [] while i<len(fmt): num,i = getNum(fmt,i) cur = fmt[i] try: format = formatdef[cur] except KeyError: raise StructError("%s is not a valid format" % cur) if num == None : num_s = 0 num = 1 else: num_s = num if cur == 'x': result += [b'\0'*num] elif cur == 's': if isinstance(args[0], bytes): padding = num - len(args[0]) result += [args[0][:num] + b'\0'*padding] args.pop(0) else: raise StructError("arg for string format not a string") elif cur == 'p': if isinstance(args[0], bytes): padding = num - len(args[0]) - 1 if padding > 0: result += [bytes([len(args[0])]) + args[0][:num-1] + b'\0'*padding] else: if num<255: result += [bytes([num-1]) + args[0][:num-1]] else: result += [bytes([255]) + args[0][:num-1]] args.pop(0) else: raise StructError("arg for string format not a string") else: if len(args) < num: raise StructError("insufficient arguments to pack") for var in args[:num]: result += [format['pack'](var,format['size'],endianness)] args=args[num:] num = None i += 1 if len(args) != 0: raise StructError("too many arguments for pack format") return b''.join(result) def unpack(fmt,data): """unpack(fmt, string) -> (v1, v2, ...) Unpack the string, containing packed C structure data, according to fmt. Requires len(string)==calcsize(fmt). See struct.__doc__ for more on format strings.""" formatdef,endianness,i = getmode(fmt) j = 0 num = 0 result = [] length= calcsize(fmt) if length != len (data): raise StructError("unpack str size does not match format") while i<len(fmt): num,i=getNum(fmt,i) cur = fmt[i] i += 1 try: format = formatdef[cur] except KeyError: raise StructError("%s is not a valid format" % cur) if not num : num = 1 if cur == 'x': j += num elif cur == 's': result.append(data[j:j+num]) j += num elif cur == 'p': n=data[j] if n >= num: n = num-1 result.append(data[j+1:j+n+1]) j += num else: for n in range(num): result += [format['unpack'](data,j,format['size'],endianness)] j += format['size'] return tuple(result) def pack_into(fmt, buf, offset, *args): data = pack(fmt, *args) buffer(buf)[offset:offset+len(data)] = data def unpack_from(fmt, buf, offset=0): size = calcsize(fmt) data = buffer(buf)[offset:offset+size] if len(data) != size: raise error("unpack_from requires a buffer of at least %d bytes" % (size,)) return unpack(fmt, data) def _clearcache(): "Clear the internal cache." # No cache in this implementation
agpl-3.0
mattjj/pyhsmm-slds
examples/demo.py
2
2399
from __future__ import division import numpy as np np.random.seed(0) import matplotlib # matplotlib.use("macosx") # might be necessary for animation to work import matplotlib.pyplot as plt import matplotlib.gridspec as gridspec import autoregressive from pyhsmm.basic.distributions import PoissonDuration from pybasicbayes.distributions import AutoRegression from pyslds.models import DefaultSLDS ################### # generate data # ################### As = [np.array([[np.cos(theta), -np.sin(theta)], [np.sin(theta), np.cos(theta)]]) for alpha, theta in ((0.95,0.1), (0.95,-0.1), (1., 0.))] truemodel = autoregressive.models.ARHSMM( alpha=4., init_state_concentration=4., obs_distns=[AutoRegression(A=A, sigma=0.05*np.eye(2)) for A in As], dur_distns=[PoissonDuration(alpha_0=5*50, beta_0=5) for _ in As]) truemodel.prefix = np.array([[0.,3.]]) data, labels = truemodel.generate(1000) data = data[truemodel.nlags:] plt.figure() plt.plot(data[:,0],data[:,1],'x-') plt.xlabel("$y_1$") plt.ylabel("$y_2$") ################# # build model # ################# Kmax = 10 # number of latent discrete states D_latent = 2 # latent linear dynamics' dimension D_obs = 2 # data dimension Cs = np.eye(D_obs) # Shared emission matrix sigma_obss = 0.05 * np.eye(D_obs) # Emission noise covariance model = DefaultSLDS( K=Kmax, D_obs=D_obs, D_latent=D_latent, Cs=Cs, sigma_obss=sigma_obss) model.add_data(data) model.resample_states() ################## # run sampling # ################## n_show = 50 samples = np.empty((n_show, data.shape[0])) samples[:n_show] = model.stateseqs[0] fig = plt.figure(figsize=(8,3)) gs = gridspec.GridSpec(6,1) ax1 = fig.add_subplot(gs[:-1]) ax2 = fig.add_subplot(gs[-1], sharex=ax1) im = ax1.matshow(samples[::-1], aspect='auto') ax1.autoscale(False) ax1.set_xticks([]) ax1.set_yticks([]) ax1.set_ylabel("Discrete State") xo, yo, w, ht = ax1.bbox.bounds h = ht / n_show ax2.matshow(labels[None,:], aspect='auto') ax2.set_xticks([]) ax2.set_xlabel("Time") ax2.set_yticks([]) plt.draw() plt.ion() plt.show() print("Press Ctrl-C to stop...") from itertools import count for itr in count(): model.resample_model() samples[itr % n_show] = model.stateseqs[0] im.set_array(samples[::-1]) plt.pause(0.001)
mit
CINPLA/expipe-dev
exdir/tests/test_help_functions.py
1
9702
import os import pathlib import six import yaml import quantities as pq import numpy as np import pytest import exdir import exdir.core import exdir.core.exdir_object as exob import exdir.core.quantities_conversion as pqc from exdir.core import filename_validation as fv from conftest import remove def test_convert_quantities(): pq_value = pq.Quantity(1, "m") result = pqc.convert_quantities(pq_value) assert result == {"value": 1, "unit": "m"} pq_value = pq.Quantity([1, 2, 3], "m") result = pqc.convert_quantities(pq_value) assert result == {"value": [1, 2, 3], "unit": "m"} result = pqc.convert_quantities(np.array([1, 2, 3])) assert result == [1, 2, 3] result = pqc.convert_quantities(1) assert result == 1 result = pqc.convert_quantities(2.3) assert result == 2.3 pq_value = pq.UncertainQuantity([1, 2], "m", [3, 4]) result = pqc.convert_quantities(pq_value) assert result == {"unit": "m", "uncertainty": [3, 4], "value": [1.0, 2.0]} pq_values = {"quantity": pq.Quantity(1, "m"), "uq_quantity": pq.UncertainQuantity([1, 2], "m", [3, 4])} result = pqc.convert_quantities(pq_values) assert(result == {"quantity": {"unit": "m", "value": 1}, "uq_quantity": {"unit": "m", "uncertainty": [3, 4], "value": [1.0, 2.0]}}) pq_values = {"list": [1, 2, 3], "quantity": pq.Quantity(1, "m")} pq_dict = {"list": [1, 2, 3], "quantity": {"unit": "m", "value": 1}} result = pqc.convert_quantities(pq_values) assert result == pq_dict def test_convert_back_quantities(): pq_dict = {"value": 1, "unit": "m"} result = pqc.convert_back_quantities(pq_dict) assert result == pq.Quantity(1, "m") pq_dict = {"value": [1, 2, 3], "unit": "m"} result = pqc.convert_back_quantities(pq_dict) assert np.array_equal(result, pq.Quantity([1, 2, 3], "m")) pq_dict = {"value": [1, 2, 3]} result = pqc.convert_back_quantities(pq_dict) assert result == pq_dict result = pqc.convert_back_quantities(1) assert result == 1 result = pqc.convert_back_quantities(2.3) assert result == 2.3 pq_dict = {"unit": "m", "uncertainty": [3, 4], "value": [1.0, 2.0]} result = pqc.convert_back_quantities(pq_dict) pq_value = pq.UncertainQuantity([1, 2], "m", [3, 4]) assert isinstance(result, pq.UncertainQuantity) assert result.magnitude.tolist() == pq_value.magnitude.tolist() assert result.dimensionality.string == pq_value.dimensionality.string assert result.uncertainty.magnitude.tolist() == pq_value.uncertainty.magnitude.tolist() pq_dict = {"quantity": {"unit": "m", "value": 1}, "uq_quantity": {"unit": "m", "uncertainty": [3, 4], "value": [1.0, 2.0]}} pq_values = {"quantity": pq.Quantity(1, "m"), "uq_quantity": pq.UncertainQuantity([1, 2], "m", [3, 4])} result = pqc.convert_back_quantities(pq_values) assert result == pq_values pq_values = {"list": [1, 2, 3], "quantity": {"unit": "m", "value": 1}} result = pqc.convert_back_quantities(pq_values) assert result == {"list": [1, 2, 3], "quantity": pq.Quantity(1, "m")} def test_assert_valid_name_minimal(setup_teardown_folder): f = exdir.File(setup_teardown_folder[1], validate_name=fv.minimal) exob._assert_valid_name("abcdefghijklmnopqrstuvwxyz1234567890_-", f) with pytest.raises(NameError): exob._assert_valid_name("", f) exob._assert_valid_name("A", f) exob._assert_valid_name("\n", f) exob._assert_valid_name(six.unichr(0x4500), f) with pytest.raises(NameError): exob._assert_valid_name(exob.META_FILENAME, f) with pytest.raises(NameError): exob._assert_valid_name(exob.ATTRIBUTES_FILENAME, f) with pytest.raises(NameError): exob._assert_valid_name(exob.RAW_FOLDER_NAME, f) def test_assert_valid_name_thorough(setup_teardown_folder): f = exdir.File(setup_teardown_folder[1], validate_name=fv.thorough) exob._assert_valid_name("abcdefghijklmnopqrstuvwxyz1234567890_-", f) with pytest.raises(NameError): exob._assert_valid_name("", f) exob._assert_valid_name("A", f) with pytest.raises(NameError): exob._assert_valid_name("\n", f) with pytest.raises(NameError): exob._assert_valid_name(six.unichr(0x4500), f) with pytest.raises(NameError): exob._assert_valid_name(exob.META_FILENAME, f) with pytest.raises(NameError): exob._assert_valid_name(exob.ATTRIBUTES_FILENAME, f) with pytest.raises(NameError): exob._assert_valid_name(exob.RAW_FOLDER_NAME, f) def test_assert_valid_name_none(setup_teardown_folder): f = exdir.File(setup_teardown_folder[1], validate_name=fv.none) valid_name = ("abcdefghijklmnopqrstuvwxyz1234567890_-") exob._assert_valid_name(valid_name, f) invalid_name = " " exob._assert_valid_name(invalid_name, f) invalid_name = "A" exob._assert_valid_name(invalid_name, f) invalid_name = "\n" exob._assert_valid_name(invalid_name, f) invalid_name = six.unichr(0x4500) exob._assert_valid_name(invalid_name, f) exob._assert_valid_name(exob.META_FILENAME, f) exob._assert_valid_name(exob.ATTRIBUTES_FILENAME, f) exob._assert_valid_name(exob.RAW_FOLDER_NAME, f) def test_create_object_directory(setup_teardown_folder): with pytest.raises(ValueError): exob._create_object_directory(pathlib.Path(setup_teardown_folder[2]), "wrong_typename") exob._create_object_directory(pathlib.Path(setup_teardown_folder[2]), exob.DATASET_TYPENAME) assert setup_teardown_folder[2].is_dir() file_path = setup_teardown_folder[2] / exob.META_FILENAME assert file_path.is_file() compare_metadata = { exob.EXDIR_METANAME: { exob.TYPE_METANAME: exob.DATASET_TYPENAME, exob.VERSION_METANAME: 1} } with file_path.open("r", encoding="utf-8") as meta_file: metadata = yaml.safe_load(meta_file) assert metadata == compare_metadata with pytest.raises(IOError): exob._create_object_directory(pathlib.Path(setup_teardown_folder[2]), exob.DATASET_TYPENAME) def test_is_nonraw_object_directory(setup_teardown_folder): setup_teardown_folder[2].mkdir() result = exob.is_nonraw_object_directory(setup_teardown_folder[2]) assert result is False compare_metafile = setup_teardown_folder[2] / exob.META_FILENAME with compare_metafile.open("w", encoding="utf-8") as f: pass result = exob.is_nonraw_object_directory(setup_teardown_folder[2]) assert result is False remove(setup_teardown_folder[1]) with compare_metafile.open("w", encoding="utf-8") as meta_file: metadata = { exob.EXDIR_METANAME: { exob.VERSION_METANAME: 1} } yaml.safe_dump(metadata, meta_file, default_flow_style=False, allow_unicode=True) result = exob.is_nonraw_object_directory(setup_teardown_folder[2]) assert result is False remove(setup_teardown_folder[1]) with compare_metafile.open("w", encoding="utf-8") as meta_file: metadata = { exob.EXDIR_METANAME: { exob.TYPE_METANAME: "wrong_typename", exob.VERSION_METANAME: 1} } yaml.safe_dump(metadata, meta_file, default_flow_style=False, allow_unicode=True) result = exob.is_nonraw_object_directory(setup_teardown_folder[2]) assert result is False remove(setup_teardown_folder[1]) with compare_metafile.open("w", encoding="utf-8") as meta_file: metadata = { exob.EXDIR_METANAME: { exob.TYPE_METANAME: exob.DATASET_TYPENAME, exob.VERSION_METANAME: 1} } yaml.safe_dump(metadata, meta_file, default_flow_style=False, allow_unicode=True) result = exob.is_nonraw_object_directory(setup_teardown_folder[2]) assert result is True remove(setup_teardown_folder[2]) exob._create_object_directory(pathlib.Path(setup_teardown_folder[2]), exob.DATASET_TYPENAME) result = exob.is_nonraw_object_directory(setup_teardown_folder[2]) assert result is True def test_root_directory(setup_teardown_file): f = setup_teardown_file[3] grp = f.create_group("foo") grp.create_group("bar") assert not exob.root_directory(setup_teardown_file[2]) path = setup_teardown_file[1] / "foo" / "bar" assert pathlib.Path(setup_teardown_file[1]) == exob.root_directory(path) def test_is_inside_exdir(setup_teardown_file): f = setup_teardown_file[3] grp = f.create_group("foo") grp.create_group("bar") path = setup_teardown_file[1] / "foo" / "bar" assert exob.is_inside_exdir(path) assert not exob.is_inside_exdir(setup_teardown_file[2]) def test_assert_inside_exdir(setup_teardown_file): f = setup_teardown_file[3] grp = f.create_group("foo") grp.create_group("bar") path = setup_teardown_file[1] / "foo" / "bar" assert exob.assert_inside_exdir(path) is None with pytest.raises(FileNotFoundError): exob.assert_inside_exdir(setup_teardown_file[2]) def test_open_object(setup_teardown_file): f = setup_teardown_file[3] grp = f.create_group("foo") grp2 = grp.create_group("bar") path = setup_teardown_file[1] / "foo" / "bar" loaded_grp = exob.open_object(path) assert grp2 == loaded_grp with pytest.raises(FileNotFoundError): exob.open_object(setup_teardown_file[2])
gpl-3.0
mail-apps/translate
translate/tools/poconflicts.py
1
8509
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Copyright 2005-2008,2010 Zuza Software Foundation # # This file is part of translate. # # translate is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # translate is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, see <http://www.gnu.org/licenses/>. """Conflict finder for Gettext PO localization files. See: http://docs.translatehouse.org/projects/translate-toolkit/en/latest/commands/poconflicts.html for examples and usage instructions. """ import os import six import sys from translate.misc import optrecurse from translate.storage import factory, po class ConflictOptionParser(optrecurse.RecursiveOptionParser): """a specialized Option Parser for the conflict tool...""" def parse_args(self, args=None, values=None): """parses the command line options, handling implicit input/output args""" (options, args) = optrecurse.optparse.OptionParser.parse_args(self, args, values) # some intelligence as to what reasonable people might give on the command line if args and not options.input: if not options.output: options.input = args[:-1] args = args[-1:] else: options.input = args args = [] if args and not options.output: options.output = args[-1] args = args[:-1] if not options.output: self.error("output file is required") if args: self.error("You have used an invalid combination of --input, --output and freestanding args") if isinstance(options.input, list) and len(options.input) == 1: options.input = options.input[0] return (options, args) def set_usage(self, usage=None): """sets the usage string - if usage not given, uses getusagestring for each option""" if usage is None: self.usage = "%prog " + " ".join([self.getusagestring(option) for option in self.option_list]) + \ "\n input directory is searched for PO files, PO files with name of conflicting string are output in output directory" else: super(ConflictOptionParser, self).set_usage(usage) def run(self): """parses the arguments, and runs recursiveprocess with the resulting options""" (options, args) = self.parse_args() options.inputformats = self.inputformats options.outputoptions = self.outputoptions self.recursiveprocess(options) def recursiveprocess(self, options): """recurse through directories and process files""" if self.isrecursive(options.input, 'input') and getattr(options, "allowrecursiveinput", True): if not self.isrecursive(options.output, 'output'): try: self.warning("Output directory does not exist. Attempting to create") os.mkdir(options.output) except: self.error(optrecurse.optparse.OptionValueError("Output directory does not exist, attempt to create failed")) if isinstance(options.input, list): inputfiles = self.recurseinputfilelist(options) else: inputfiles = self.recurseinputfiles(options) else: if options.input: inputfiles = [os.path.basename(options.input)] options.input = os.path.dirname(options.input) else: inputfiles = [options.input] self.textmap = {} self.initprogressbar(inputfiles, options) for inputpath in inputfiles: fullinputpath = self.getfullinputpath(options, inputpath) try: success = self.processfile(None, options, fullinputpath) except Exception: self.warning("Error processing: input %s" % (fullinputpath), options, sys.exc_info()) success = False self.reportprogress(inputpath, success) del self.progressbar self.buildconflictmap() self.outputconflicts(options) def clean(self, string, options): """returns the cleaned string that contains the text to be matched""" if options.ignorecase: string = string.lower() for accelerator in options.accelchars: string = string.replace(accelerator, "") string = string.strip() return string def processfile(self, fileprocessor, options, fullinputpath): """process an individual file""" inputfile = self.openinputfile(options, fullinputpath) inputfile = factory.getobject(inputfile) for unit in inputfile.units: if unit.isheader() or not unit.istranslated(): continue if unit.hasplural(): continue if not options.invert: source = self.clean(unit.source, options) target = self.clean(unit.target, options) else: target = self.clean(unit.source, options) source = self.clean(unit.target, options) self.textmap.setdefault(source, []).append((target, unit, fullinputpath)) def flatten(self, text, joinchar): """flattens text to just be words""" flattext = "" for c in text: if c.isalnum(): flattext += c elif flattext[-1:].isalnum(): flattext += joinchar return flattext.rstrip(joinchar) def buildconflictmap(self): """work out which strings are conflicting""" self.conflictmap = {} for source, translations in six.iteritems(self.textmap): source = self.flatten(source, " ") if len(source) <= 1: continue if len(translations) > 1: uniquetranslations = dict.fromkeys([target for target, unit, filename in translations]) if len(uniquetranslations) > 1: self.conflictmap[source] = translations def outputconflicts(self, options): """saves the result of the conflict match""" print("%d/%d different strings have conflicts" % (len(self.conflictmap), len(self.textmap))) reducedmap = {} def str_len(x): return len(x) for source, translations in six.iteritems(self.conflictmap): words = source.split() words.sort(key=str_len) source = words[-1] reducedmap.setdefault(source, []).extend(translations) # reduce plurals plurals = {} for word in reducedmap: if word + "s" in reducedmap: plurals[word] = word + "s" for word, pluralword in six.iteritems(plurals): reducedmap[word].extend(reducedmap.pop(pluralword)) for source, translations in six.iteritems(reducedmap): flatsource = self.flatten(source, "-") fulloutputpath = os.path.join(options.output, flatsource + os.extsep + "po") conflictfile = po.pofile() for target, unit, filename in translations: unit.othercomments.append("# (poconflicts) %s\n" % filename) conflictfile.units.append(unit) open(fulloutputpath, "w").write(str(conflictfile)) def main(): formats = {"po": ("po", None), None: ("po", None)} parser = ConflictOptionParser(formats) parser.add_option("-I", "--ignore-case", dest="ignorecase", action="store_true", default=False, help="ignore case distinctions") parser.add_option("-v", "--invert", dest="invert", action="store_true", default=False, help="invert the conflicts thus extracting conflicting destination words") parser.add_option("", "--accelerator", dest="accelchars", default="", metavar="ACCELERATORS", help="ignores the given accelerator characters when matching") parser.set_usage() parser.description = __doc__ parser.run() if __name__ == '__main__': main()
gpl-2.0
shubhdev/edx-platform
lms/djangoapps/notes/tests.py
129
16454
""" Unit tests for the notes app. """ from mock import patch, Mock from opaque_keys.edx.locations import SlashSeparatedCourseKey from django.test import TestCase, RequestFactory from django.test.client import Client from django.core.urlresolvers import reverse from django.contrib.auth.models import User from django.core.exceptions import ValidationError import json from xmodule.modulestore.tests.django_utils import ModuleStoreTestCase from xmodule.modulestore.tests.factories import CourseFactory from courseware.tabs import get_course_tab_list, CourseTab from student.tests.factories import UserFactory, CourseEnrollmentFactory from notes import utils, api, models class UtilsTest(ModuleStoreTestCase): """ Tests for the notes utils. """ def setUp(self): ''' Setup a dummy course-like object with a tabs field that can be accessed via attribute lookup. ''' super(UtilsTest, self).setUp() self.course = CourseFactory.create() def test_notes_not_enabled(self): ''' Tests that notes are disabled when the course tab configuration does NOT contain a tab with type "notes." ''' self.assertFalse(utils.notes_enabled_for_course(self.course)) def test_notes_enabled(self): ''' Tests that notes are enabled when the course tab configuration contains a tab with type "notes." ''' with self.settings(FEATURES={'ENABLE_STUDENT_NOTES': True}): self.course.advanced_modules = ["notes"] self.assertTrue(utils.notes_enabled_for_course(self.course)) class CourseTabTest(ModuleStoreTestCase): """ Test that the course tab shows up the way we expect. """ def setUp(self): ''' Setup a dummy course-like object with a tabs field that can be accessed via attribute lookup. ''' super(CourseTabTest, self).setUp() self.course = CourseFactory.create() self.user = UserFactory() CourseEnrollmentFactory.create(user=self.user, course_id=self.course.id) def enable_notes(self): """Enable notes and add the tab to the course.""" self.course.tabs.append(CourseTab.load("notes")) self.course.advanced_modules = ["notes"] def has_notes_tab(self, course, user): """ Returns true if the current course and user have a notes tab, false otherwise. """ request = RequestFactory().request() request.user = user all_tabs = get_course_tab_list(request, course) return any([tab.name == u'My Notes' for tab in all_tabs]) def test_course_tab_not_visible(self): # module not enabled in the course self.assertFalse(self.has_notes_tab(self.course, self.user)) with self.settings(FEATURES={'ENABLE_STUDENT_NOTES': False}): # setting not enabled and the module is not enabled self.assertFalse(self.has_notes_tab(self.course, self.user)) # module is enabled and the setting is not enabled self.course.advanced_modules = ["notes"] self.assertFalse(self.has_notes_tab(self.course, self.user)) def test_course_tab_visible(self): self.enable_notes() self.assertTrue(self.has_notes_tab(self.course, self.user)) self.course.advanced_modules = [] self.assertFalse(self.has_notes_tab(self.course, self.user)) class ApiTest(TestCase): def setUp(self): super(ApiTest, self).setUp() self.client = Client() # Mocks patcher = patch.object(api, 'api_enabled', Mock(return_value=True)) patcher.start() self.addCleanup(patcher.stop) # Create two accounts self.password = 'abc' self.student = User.objects.create_user('student', 'student@test.com', self.password) self.student2 = User.objects.create_user('student2', 'student2@test.com', self.password) self.instructor = User.objects.create_user('instructor', 'instructor@test.com', self.password) self.course_key = SlashSeparatedCourseKey('HarvardX', 'CB22x', 'The_Ancient_Greek_Hero') self.note = { 'user': self.student, 'course_id': self.course_key, 'uri': '/', 'text': 'foo', 'quote': 'bar', 'range_start': 0, 'range_start_offset': 0, 'range_end': 100, 'range_end_offset': 0, 'tags': 'a,b,c' } # Make sure no note with this ID ever exists for testing purposes self.NOTE_ID_DOES_NOT_EXIST = 99999 def login(self, as_student=None): username = None password = self.password if as_student is None: username = self.student.username else: username = as_student.username self.client.login(username=username, password=password) def url(self, name, args={}): args.update({'course_id': self.course_key.to_deprecated_string()}) return reverse(name, kwargs=args) def create_notes(self, num_notes, create=True): notes = [] for n in range(num_notes): note = models.Note(**self.note) if create: note.save() notes.append(note) return notes def test_root(self): self.login() resp = self.client.get(self.url('notes_api_root')) self.assertEqual(resp.status_code, 200) self.assertNotEqual(resp.content, '') content = json.loads(resp.content) self.assertEqual(set(('name', 'version')), set(content.keys())) self.assertIsInstance(content['version'], int) self.assertEqual(content['name'], 'Notes API') def test_index_empty(self): self.login() resp = self.client.get(self.url('notes_api_notes')) self.assertEqual(resp.status_code, 200) self.assertNotEqual(resp.content, '') content = json.loads(resp.content) self.assertEqual(len(content), 0) def test_index_with_notes(self): num_notes = 3 self.login() self.create_notes(num_notes) resp = self.client.get(self.url('notes_api_notes')) self.assertEqual(resp.status_code, 200) self.assertNotEqual(resp.content, '') content = json.loads(resp.content) self.assertIsInstance(content, list) self.assertEqual(len(content), num_notes) def test_index_max_notes(self): self.login() MAX_LIMIT = api.API_SETTINGS.get('MAX_NOTE_LIMIT') num_notes = MAX_LIMIT + 1 self.create_notes(num_notes) resp = self.client.get(self.url('notes_api_notes')) self.assertEqual(resp.status_code, 200) self.assertNotEqual(resp.content, '') content = json.loads(resp.content) self.assertIsInstance(content, list) self.assertEqual(len(content), MAX_LIMIT) def test_create_note(self): self.login() notes = self.create_notes(1) self.assertEqual(len(notes), 1) note_dict = notes[0].as_dict() excluded_fields = ['id', 'user_id', 'created', 'updated'] note = dict([(k, v) for k, v in note_dict.items() if k not in excluded_fields]) resp = self.client.post(self.url('notes_api_notes'), json.dumps(note), content_type='application/json', HTTP_X_REQUESTED_WITH='XMLHttpRequest') self.assertEqual(resp.status_code, 303) self.assertEqual(len(resp.content), 0) def test_create_empty_notes(self): self.login() for empty_test in [None, [], '']: resp = self.client.post(self.url('notes_api_notes'), json.dumps(empty_test), content_type='application/json', HTTP_X_REQUESTED_WITH='XMLHttpRequest') self.assertEqual(resp.status_code, 400) def test_create_note_missing_ranges(self): self.login() notes = self.create_notes(1) self.assertEqual(len(notes), 1) note_dict = notes[0].as_dict() excluded_fields = ['id', 'user_id', 'created', 'updated'] + ['ranges'] note = dict([(k, v) for k, v in note_dict.items() if k not in excluded_fields]) resp = self.client.post(self.url('notes_api_notes'), json.dumps(note), content_type='application/json', HTTP_X_REQUESTED_WITH='XMLHttpRequest') self.assertEqual(resp.status_code, 400) def test_read_note(self): self.login() notes = self.create_notes(3) self.assertEqual(len(notes), 3) for note in notes: resp = self.client.get(self.url('notes_api_note', {'note_id': note.pk})) self.assertEqual(resp.status_code, 200) self.assertNotEqual(resp.content, '') content = json.loads(resp.content) self.assertEqual(content['id'], note.pk) self.assertEqual(content['user_id'], note.user_id) def test_note_doesnt_exist_to_read(self): self.login() resp = self.client.get(self.url('notes_api_note', { 'note_id': self.NOTE_ID_DOES_NOT_EXIST })) self.assertEqual(resp.status_code, 404) self.assertEqual(resp.content, '') def test_student_doesnt_have_permission_to_read_note(self): notes = self.create_notes(1) self.assertEqual(len(notes), 1) note = notes[0] # set the student id to a different student (not the one that created the notes) self.login(as_student=self.student2) resp = self.client.get(self.url('notes_api_note', {'note_id': note.pk})) self.assertEqual(resp.status_code, 403) self.assertEqual(resp.content, '') def test_delete_note(self): self.login() notes = self.create_notes(1) self.assertEqual(len(notes), 1) note = notes[0] resp = self.client.delete(self.url('notes_api_note', { 'note_id': note.pk })) self.assertEqual(resp.status_code, 204) self.assertEqual(resp.content, '') with self.assertRaises(models.Note.DoesNotExist): models.Note.objects.get(pk=note.pk) def test_note_does_not_exist_to_delete(self): self.login() resp = self.client.delete(self.url('notes_api_note', { 'note_id': self.NOTE_ID_DOES_NOT_EXIST })) self.assertEqual(resp.status_code, 404) self.assertEqual(resp.content, '') def test_student_doesnt_have_permission_to_delete_note(self): notes = self.create_notes(1) self.assertEqual(len(notes), 1) note = notes[0] self.login(as_student=self.student2) resp = self.client.delete(self.url('notes_api_note', { 'note_id': note.pk })) self.assertEqual(resp.status_code, 403) self.assertEqual(resp.content, '') try: models.Note.objects.get(pk=note.pk) except models.Note.DoesNotExist: self.fail('note should exist and not be deleted because the student does not have permission to do so') def test_update_note(self): notes = self.create_notes(1) note = notes[0] updated_dict = note.as_dict() updated_dict.update({ 'text': 'itchy and scratchy', 'tags': ['simpsons', 'cartoons', 'animation'] }) self.login() resp = self.client.put(self.url('notes_api_note', {'note_id': note.pk}), json.dumps(updated_dict), content_type='application/json', HTTP_X_REQUESTED_WITH='XMLHttpRequest') self.assertEqual(resp.status_code, 303) self.assertEqual(resp.content, '') actual = models.Note.objects.get(pk=note.pk) actual_dict = actual.as_dict() for field in ['text', 'tags']: self.assertEqual(actual_dict[field], updated_dict[field]) def test_search_note_params(self): self.login() total = 3 notes = self.create_notes(total) invalid_uri = ''.join([note.uri for note in notes]) tests = [{'limit': 0, 'offset': 0, 'expected_rows': total}, {'limit': 0, 'offset': 2, 'expected_rows': total - 2}, {'limit': 0, 'offset': total, 'expected_rows': 0}, {'limit': 1, 'offset': 0, 'expected_rows': 1}, {'limit': 2, 'offset': 0, 'expected_rows': 2}, {'limit': total, 'offset': 2, 'expected_rows': 1}, {'limit': total, 'offset': total, 'expected_rows': 0}, {'limit': total + 1, 'offset': total + 1, 'expected_rows': 0}, {'limit': total + 1, 'offset': 0, 'expected_rows': total}, {'limit': 0, 'offset': 0, 'uri': invalid_uri, 'expected_rows': 0, 'expected_total': 0}] for test in tests: params = dict([(k, str(test[k])) for k in ('limit', 'offset', 'uri') if k in test]) resp = self.client.get(self.url('notes_api_search'), params, content_type='application/json', HTTP_X_REQUESTED_WITH='XMLHttpRequest') self.assertEqual(resp.status_code, 200) self.assertNotEqual(resp.content, '') content = json.loads(resp.content) for expected_key in ('total', 'rows'): self.assertTrue(expected_key in content) if 'expected_total' in test: self.assertEqual(content['total'], test['expected_total']) else: self.assertEqual(content['total'], total) self.assertEqual(len(content['rows']), test['expected_rows']) for row in content['rows']: self.assertTrue('id' in row) class NoteTest(TestCase): def setUp(self): super(NoteTest, self).setUp() self.password = 'abc' self.student = User.objects.create_user('student', 'student@test.com', self.password) self.course_key = SlashSeparatedCourseKey('HarvardX', 'CB22x', 'The_Ancient_Greek_Hero') self.note = { 'user': self.student, 'course_id': self.course_key, 'uri': '/', 'text': 'foo', 'quote': 'bar', 'range_start': 0, 'range_start_offset': 0, 'range_end': 100, 'range_end_offset': 0, 'tags': 'a,b,c' } def test_clean_valid_note(self): reference_note = models.Note(**self.note) body = reference_note.as_dict() note = models.Note(course_id=self.course_key, user=self.student) try: note.clean(json.dumps(body)) self.assertEqual(note.uri, body['uri']) self.assertEqual(note.text, body['text']) self.assertEqual(note.quote, body['quote']) self.assertEqual(note.range_start, body['ranges'][0]['start']) self.assertEqual(note.range_start_offset, body['ranges'][0]['startOffset']) self.assertEqual(note.range_end, body['ranges'][0]['end']) self.assertEqual(note.range_end_offset, body['ranges'][0]['endOffset']) self.assertEqual(note.tags, ','.join(body['tags'])) except ValidationError: self.fail('a valid note should not raise an exception') def test_clean_invalid_note(self): note = models.Note(course_id=self.course_key, user=self.student) for empty_type in (None, '', 0, []): with self.assertRaises(ValidationError): note.clean(None) with self.assertRaises(ValidationError): note.clean(json.dumps({ 'text': 'foo', 'quote': 'bar', 'ranges': [{} for i in range(10)] # too many ranges })) def test_as_dict(self): note = models.Note(course_id=self.course_key, user=self.student) d = note.as_dict() self.assertNotIsInstance(d, basestring) self.assertEqual(d['user_id'], self.student.id) self.assertTrue('course_id' not in d)
agpl-3.0
geoscript/geoscript-py
geoscript/workspace/spatialite.py
1
1338
""" The :mod:`workspace.spatialite` module a workspace implementation based on the contents of a SpatiaLite database. """ import os from geoscript.workspace import Workspace from org.geotools.data.spatialite import SpatiaLiteDataStoreFactory class SpatiaLite(Workspace): """ A subclass of :class:`Workspace <geoscript.workspace.workspace.Workspace>` for a SpatiaLite database. Layers of the workspace correspond to tables in the database. *db* is the name of the database. *dir* is the optional path to a directory containing the SpatiaLite database. If the underlying SpatiaLite database does not exist it will be created. """ def __init__(self, db, dir=None): if dir: db = os.path.join(dir, db) params = {'database': db, 'dbtype': 'spatialite'} Workspace.__init__(self, SpatiaLiteDataStoreFactory(), params) def version(self): """ Provides version info about the SpatiaLite, Proj, and GEOS libraries. """ cx = self._store.getDataSource().getConnection() try: st = cx.createStatement(); rs = st.executeQuery( "SELECT spatialite_version(), proj4_version(), geos_version()"); rs.next() return { 'spatialite': rs.getString(1), 'proj': rs.getString(2), 'geos': rs.getString(3) } finally: cx.close()
mit
paweljasinski/ironpython3
Src/StdLib/Lib/test/test_colorsys.py
105
3927
import unittest import colorsys def frange(start, stop, step): while start <= stop: yield start start += step class ColorsysTest(unittest.TestCase): def assertTripleEqual(self, tr1, tr2): self.assertEqual(len(tr1), 3) self.assertEqual(len(tr2), 3) self.assertAlmostEqual(tr1[0], tr2[0]) self.assertAlmostEqual(tr1[1], tr2[1]) self.assertAlmostEqual(tr1[2], tr2[2]) def test_hsv_roundtrip(self): for r in frange(0.0, 1.0, 0.2): for g in frange(0.0, 1.0, 0.2): for b in frange(0.0, 1.0, 0.2): rgb = (r, g, b) self.assertTripleEqual( rgb, colorsys.hsv_to_rgb(*colorsys.rgb_to_hsv(*rgb)) ) def test_hsv_values(self): values = [ # rgb, hsv ((0.0, 0.0, 0.0), ( 0 , 0.0, 0.0)), # black ((0.0, 0.0, 1.0), (4./6., 1.0, 1.0)), # blue ((0.0, 1.0, 0.0), (2./6., 1.0, 1.0)), # green ((0.0, 1.0, 1.0), (3./6., 1.0, 1.0)), # cyan ((1.0, 0.0, 0.0), ( 0 , 1.0, 1.0)), # red ((1.0, 0.0, 1.0), (5./6., 1.0, 1.0)), # purple ((1.0, 1.0, 0.0), (1./6., 1.0, 1.0)), # yellow ((1.0, 1.0, 1.0), ( 0 , 0.0, 1.0)), # white ((0.5, 0.5, 0.5), ( 0 , 0.0, 0.5)), # grey ] for (rgb, hsv) in values: self.assertTripleEqual(hsv, colorsys.rgb_to_hsv(*rgb)) self.assertTripleEqual(rgb, colorsys.hsv_to_rgb(*hsv)) def test_hls_roundtrip(self): for r in frange(0.0, 1.0, 0.2): for g in frange(0.0, 1.0, 0.2): for b in frange(0.0, 1.0, 0.2): rgb = (r, g, b) self.assertTripleEqual( rgb, colorsys.hls_to_rgb(*colorsys.rgb_to_hls(*rgb)) ) def test_hls_values(self): values = [ # rgb, hls ((0.0, 0.0, 0.0), ( 0 , 0.0, 0.0)), # black ((0.0, 0.0, 1.0), (4./6., 0.5, 1.0)), # blue ((0.0, 1.0, 0.0), (2./6., 0.5, 1.0)), # green ((0.0, 1.0, 1.0), (3./6., 0.5, 1.0)), # cyan ((1.0, 0.0, 0.0), ( 0 , 0.5, 1.0)), # red ((1.0, 0.0, 1.0), (5./6., 0.5, 1.0)), # purple ((1.0, 1.0, 0.0), (1./6., 0.5, 1.0)), # yellow ((1.0, 1.0, 1.0), ( 0 , 1.0, 0.0)), # white ((0.5, 0.5, 0.5), ( 0 , 0.5, 0.0)), # grey ] for (rgb, hls) in values: self.assertTripleEqual(hls, colorsys.rgb_to_hls(*rgb)) self.assertTripleEqual(rgb, colorsys.hls_to_rgb(*hls)) def test_yiq_roundtrip(self): for r in frange(0.0, 1.0, 0.2): for g in frange(0.0, 1.0, 0.2): for b in frange(0.0, 1.0, 0.2): rgb = (r, g, b) self.assertTripleEqual( rgb, colorsys.yiq_to_rgb(*colorsys.rgb_to_yiq(*rgb)) ) def test_yiq_values(self): values = [ # rgb, yiq ((0.0, 0.0, 0.0), (0.0, 0.0, 0.0)), # black ((0.0, 0.0, 1.0), (0.11, -0.3217, 0.3121)), # blue ((0.0, 1.0, 0.0), (0.59, -0.2773, -0.5251)), # green ((0.0, 1.0, 1.0), (0.7, -0.599, -0.213)), # cyan ((1.0, 0.0, 0.0), (0.3, 0.599, 0.213)), # red ((1.0, 0.0, 1.0), (0.41, 0.2773, 0.5251)), # purple ((1.0, 1.0, 0.0), (0.89, 0.3217, -0.3121)), # yellow ((1.0, 1.0, 1.0), (1.0, 0.0, 0.0)), # white ((0.5, 0.5, 0.5), (0.5, 0.0, 0.0)), # grey ] for (rgb, yiq) in values: self.assertTripleEqual(yiq, colorsys.rgb_to_yiq(*rgb)) self.assertTripleEqual(rgb, colorsys.yiq_to_rgb(*yiq)) if __name__ == "__main__": unittest.main()
apache-2.0
takeshineshiro/swift
test/unit/container/test_replicator.py
12
46738
# Copyright (c) 2010-2012 OpenStack Foundation # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or # implied. # See the License for the specific language governing permissions and # limitations under the License. import os import time import shutil import itertools import unittest import mock import random import sqlite3 from swift.common import db_replicator from swift.container import replicator, backend, server from swift.container.reconciler import ( MISPLACED_OBJECTS_ACCOUNT, get_reconciler_container_name) from swift.common.utils import Timestamp from swift.common.storage_policy import POLICIES from test.unit.common import test_db_replicator from test.unit import patch_policies, make_timestamp_iter from contextlib import contextmanager @patch_policies class TestReplicatorSync(test_db_replicator.TestReplicatorSync): backend = backend.ContainerBroker datadir = server.DATADIR replicator_daemon = replicator.ContainerReplicator replicator_rpc = replicator.ContainerReplicatorRpc def test_report_up_to_date(self): broker = self._get_broker('a', 'c', node_index=0) broker.initialize(Timestamp(1).internal, int(POLICIES.default)) info = broker.get_info() broker.reported(info['put_timestamp'], info['delete_timestamp'], info['object_count'], info['bytes_used']) full_info = broker.get_replication_info() expected_info = {'put_timestamp': Timestamp(1).internal, 'delete_timestamp': '0', 'count': 0, 'bytes_used': 0, 'reported_put_timestamp': Timestamp(1).internal, 'reported_delete_timestamp': '0', 'reported_object_count': 0, 'reported_bytes_used': 0} for key, value in expected_info.items(): msg = 'expected value for %r, %r != %r' % ( key, full_info[key], value) self.assertEqual(full_info[key], value, msg) repl = replicator.ContainerReplicator({}) self.assertTrue(repl.report_up_to_date(full_info)) full_info['delete_timestamp'] = Timestamp(2).internal self.assertFalse(repl.report_up_to_date(full_info)) full_info['reported_delete_timestamp'] = Timestamp(2).internal self.assertTrue(repl.report_up_to_date(full_info)) full_info['count'] = 1 self.assertFalse(repl.report_up_to_date(full_info)) full_info['reported_object_count'] = 1 self.assertTrue(repl.report_up_to_date(full_info)) full_info['bytes_used'] = 1 self.assertFalse(repl.report_up_to_date(full_info)) full_info['reported_bytes_used'] = 1 self.assertTrue(repl.report_up_to_date(full_info)) full_info['put_timestamp'] = Timestamp(3).internal self.assertFalse(repl.report_up_to_date(full_info)) full_info['reported_put_timestamp'] = Timestamp(3).internal self.assertTrue(repl.report_up_to_date(full_info)) def test_sync_remote_in_sync(self): # setup a local container broker = self._get_broker('a', 'c', node_index=0) put_timestamp = time.time() broker.initialize(put_timestamp, POLICIES.default.idx) # "replicate" to same database node = {'device': 'sdb', 'replication_ip': '127.0.0.1'} daemon = replicator.ContainerReplicator({}) # replicate part, node = self._get_broker_part_node(broker) info = broker.get_replication_info() success = daemon._repl_to_node(node, broker, part, info) # nothing to do self.assertTrue(success) self.assertEqual(1, daemon.stats['no_change']) def test_sync_remote_with_timings(self): ts_iter = make_timestamp_iter() # setup a local container broker = self._get_broker('a', 'c', node_index=0) put_timestamp = next(ts_iter) broker.initialize(put_timestamp.internal, POLICIES.default.idx) broker.update_metadata( {'x-container-meta-test': ('foo', put_timestamp.internal)}) # setup remote container remote_broker = self._get_broker('a', 'c', node_index=1) remote_broker.initialize(next(ts_iter).internal, POLICIES.default.idx) timestamp = next(ts_iter) for db in (broker, remote_broker): db.put_object( '/a/c/o', timestamp.internal, 0, 'content-type', 'etag', storage_policy_index=db.storage_policy_index) # replicate daemon = replicator.ContainerReplicator({}) part, node = self._get_broker_part_node(remote_broker) info = broker.get_replication_info() with mock.patch.object(db_replicator, 'DEBUG_TIMINGS_THRESHOLD', -1): success = daemon._repl_to_node(node, broker, part, info) # nothing to do self.assertTrue(success) self.assertEqual(1, daemon.stats['no_change']) expected_timings = ('info', 'update_metadata', 'merge_timestamps', 'get_sync', 'merge_syncs') debug_lines = self.rpc.logger.logger.get_lines_for_level('debug') self.assertEqual(len(expected_timings), len(debug_lines), 'Expected %s debug lines but only got %s: %s' % (len(expected_timings), len(debug_lines), debug_lines)) for metric in expected_timings: expected = 'replicator-rpc-sync time for %s:' % metric self.assertTrue(any(expected in line for line in debug_lines), 'debug timing %r was not in %r' % ( expected, debug_lines)) def test_sync_remote_missing(self): broker = self._get_broker('a', 'c', node_index=0) put_timestamp = time.time() broker.initialize(put_timestamp, POLICIES.default.idx) # "replicate" part, node = self._get_broker_part_node(broker) daemon = self._run_once(node) # complete rsync to all other nodes self.assertEqual(2, daemon.stats['rsync']) for i in range(1, 3): remote_broker = self._get_broker('a', 'c', node_index=i) self.assertTrue(os.path.exists(remote_broker.db_file)) remote_info = remote_broker.get_info() local_info = self._get_broker( 'a', 'c', node_index=0).get_info() for k, v in local_info.items(): if k == 'id': continue self.assertEqual(remote_info[k], v, "mismatch remote %s %r != %r" % ( k, remote_info[k], v)) def test_rsync_failure(self): broker = self._get_broker('a', 'c', node_index=0) put_timestamp = time.time() broker.initialize(put_timestamp, POLICIES.default.idx) # "replicate" to different device daemon = replicator.ContainerReplicator({}) def _rsync_file(*args, **kwargs): return False daemon._rsync_file = _rsync_file # replicate part, local_node = self._get_broker_part_node(broker) node = random.choice([n for n in self._ring.devs if n['id'] != local_node['id']]) info = broker.get_replication_info() success = daemon._repl_to_node(node, broker, part, info) self.assertFalse(success) def test_sync_remote_missing_most_rows(self): put_timestamp = time.time() # create "local" broker broker = self._get_broker('a', 'c', node_index=0) broker.initialize(put_timestamp, POLICIES.default.idx) # create "remote" broker remote_broker = self._get_broker('a', 'c', node_index=1) remote_broker.initialize(put_timestamp, POLICIES.default.idx) # add a row to "local" db broker.put_object('/a/c/o', time.time(), 0, 'content-type', 'etag', storage_policy_index=broker.storage_policy_index) # replicate node = {'device': 'sdc', 'replication_ip': '127.0.0.1'} daemon = replicator.ContainerReplicator({}) def _rsync_file(db_file, remote_file, **kwargs): remote_server, remote_path = remote_file.split('/', 1) dest_path = os.path.join(self.root, remote_path) shutil.copy(db_file, dest_path) return True daemon._rsync_file = _rsync_file part, node = self._get_broker_part_node(remote_broker) info = broker.get_replication_info() success = daemon._repl_to_node(node, broker, part, info) self.assertTrue(success) # row merge self.assertEqual(1, daemon.stats['remote_merge']) local_info = self._get_broker( 'a', 'c', node_index=0).get_info() remote_info = self._get_broker( 'a', 'c', node_index=1).get_info() for k, v in local_info.items(): if k == 'id': continue self.assertEqual(remote_info[k], v, "mismatch remote %s %r != %r" % ( k, remote_info[k], v)) def test_sync_remote_missing_one_rows(self): put_timestamp = time.time() # create "local" broker broker = self._get_broker('a', 'c', node_index=0) broker.initialize(put_timestamp, POLICIES.default.idx) # create "remote" broker remote_broker = self._get_broker('a', 'c', node_index=1) remote_broker.initialize(put_timestamp, POLICIES.default.idx) # add some rows to both db for i in range(10): put_timestamp = time.time() for db in (broker, remote_broker): path = '/a/c/o_%s' % i db.put_object(path, put_timestamp, 0, 'content-type', 'etag', storage_policy_index=db.storage_policy_index) # now a row to the "local" broker only broker.put_object('/a/c/o_missing', time.time(), 0, 'content-type', 'etag', storage_policy_index=broker.storage_policy_index) # replicate daemon = replicator.ContainerReplicator({}) part, node = self._get_broker_part_node(remote_broker) info = broker.get_replication_info() success = daemon._repl_to_node(node, broker, part, info) self.assertTrue(success) # row merge self.assertEqual(1, daemon.stats['diff']) local_info = self._get_broker( 'a', 'c', node_index=0).get_info() remote_info = self._get_broker( 'a', 'c', node_index=1).get_info() for k, v in local_info.items(): if k == 'id': continue self.assertEqual(remote_info[k], v, "mismatch remote %s %r != %r" % ( k, remote_info[k], v)) def test_sync_remote_can_not_keep_up(self): put_timestamp = time.time() # create "local" broker broker = self._get_broker('a', 'c', node_index=0) broker.initialize(put_timestamp, POLICIES.default.idx) # create "remote" broker remote_broker = self._get_broker('a', 'c', node_index=1) remote_broker.initialize(put_timestamp, POLICIES.default.idx) # add some rows to both db's for i in range(10): put_timestamp = time.time() for db in (broker, remote_broker): obj_name = 'o_%s' % i db.put_object(obj_name, put_timestamp, 0, 'content-type', 'etag', storage_policy_index=db.storage_policy_index) # setup REPLICATE callback to simulate adding rows during merge_items missing_counter = itertools.count() def put_more_objects(op, *args): if op != 'merge_items': return path = '/a/c/o_missing_%s' % next(missing_counter) broker.put_object(path, time.time(), 0, 'content-type', 'etag', storage_policy_index=db.storage_policy_index) test_db_replicator.FakeReplConnection = \ test_db_replicator.attach_fake_replication_rpc( self.rpc, replicate_hook=put_more_objects) db_replicator.ReplConnection = test_db_replicator.FakeReplConnection # and add one extra to local db to trigger merge_items put_more_objects('merge_items') # limit number of times we'll call merge_items daemon = replicator.ContainerReplicator({'max_diffs': 10}) # replicate part, node = self._get_broker_part_node(remote_broker) info = broker.get_replication_info() success = daemon._repl_to_node(node, broker, part, info) self.assertFalse(success) # back off on the PUTs during replication... FakeReplConnection = test_db_replicator.attach_fake_replication_rpc( self.rpc, replicate_hook=None) db_replicator.ReplConnection = FakeReplConnection # retry replication info = broker.get_replication_info() success = daemon._repl_to_node(node, broker, part, info) self.assertTrue(success) # row merge self.assertEqual(2, daemon.stats['diff']) self.assertEqual(1, daemon.stats['diff_capped']) local_info = self._get_broker( 'a', 'c', node_index=0).get_info() remote_info = self._get_broker( 'a', 'c', node_index=1).get_info() for k, v in local_info.items(): if k == 'id': continue self.assertEqual(remote_info[k], v, "mismatch remote %s %r != %r" % ( k, remote_info[k], v)) def test_diff_capped_sync(self): ts = (Timestamp(t).internal for t in itertools.count(int(time.time()))) put_timestamp = next(ts) # start off with with a local db that is way behind broker = self._get_broker('a', 'c', node_index=0) broker.initialize(put_timestamp, POLICIES.default.idx) for i in range(50): broker.put_object( 'o%s' % i, next(ts), 0, 'content-type-old', 'etag', storage_policy_index=broker.storage_policy_index) # remote primary db has all the new bits... remote_broker = self._get_broker('a', 'c', node_index=1) remote_broker.initialize(put_timestamp, POLICIES.default.idx) for i in range(100): remote_broker.put_object( 'o%s' % i, next(ts), 0, 'content-type-new', 'etag', storage_policy_index=remote_broker.storage_policy_index) # except there's *one* tiny thing in our local broker that's newer broker.put_object( 'o101', next(ts), 0, 'content-type-new', 'etag', storage_policy_index=broker.storage_policy_index) # setup daemon with smaller per_diff and max_diffs part, node = self._get_broker_part_node(broker) daemon = self._get_daemon(node, conf_updates={'per_diff': 10, 'max_diffs': 3}) self.assertEqual(daemon.per_diff, 10) self.assertEqual(daemon.max_diffs, 3) # run once and verify diff capped self._run_once(node, daemon=daemon) self.assertEqual(1, daemon.stats['diff']) self.assertEqual(1, daemon.stats['diff_capped']) # run again and verify fully synced self._run_once(node, daemon=daemon) self.assertEqual(1, daemon.stats['diff']) self.assertEqual(0, daemon.stats['diff_capped']) # now that we're synced the new item should be in remote db remote_names = set() for item in remote_broker.list_objects_iter(500, '', '', '', ''): name, ts, size, content_type, etag = item remote_names.add(name) self.assertEqual(content_type, 'content-type-new') self.assertTrue('o101' in remote_names) self.assertEqual(len(remote_names), 101) self.assertEqual(remote_broker.get_info()['object_count'], 101) def test_sync_status_change(self): # setup a local container broker = self._get_broker('a', 'c', node_index=0) put_timestamp = time.time() broker.initialize(put_timestamp, POLICIES.default.idx) # setup remote container remote_broker = self._get_broker('a', 'c', node_index=1) remote_broker.initialize(put_timestamp, POLICIES.default.idx) # delete local container broker.delete_db(time.time()) # replicate daemon = replicator.ContainerReplicator({}) part, node = self._get_broker_part_node(remote_broker) info = broker.get_replication_info() success = daemon._repl_to_node(node, broker, part, info) # nothing to do self.assertTrue(success) self.assertEqual(1, daemon.stats['no_change']) # status in sync self.assertTrue(remote_broker.is_deleted()) info = broker.get_info() remote_info = remote_broker.get_info() self.assertTrue(Timestamp(remote_info['status_changed_at']) > Timestamp(remote_info['put_timestamp']), 'remote status_changed_at (%s) is not ' 'greater than put_timestamp (%s)' % ( remote_info['status_changed_at'], remote_info['put_timestamp'])) self.assertTrue(Timestamp(remote_info['status_changed_at']) > Timestamp(info['status_changed_at']), 'remote status_changed_at (%s) is not ' 'greater than local status_changed_at (%s)' % ( remote_info['status_changed_at'], info['status_changed_at'])) @contextmanager def _wrap_merge_timestamps(self, broker, calls): def fake_merge_timestamps(*args, **kwargs): calls.append(args[0]) orig_merge_timestamps(*args, **kwargs) orig_merge_timestamps = broker.merge_timestamps broker.merge_timestamps = fake_merge_timestamps try: yield True finally: broker.merge_timestamps = orig_merge_timestamps def test_sync_merge_timestamps(self): ts = (Timestamp(t).internal for t in itertools.count(int(time.time()))) # setup a local container broker = self._get_broker('a', 'c', node_index=0) put_timestamp = next(ts) broker.initialize(put_timestamp, POLICIES.default.idx) # setup remote container remote_broker = self._get_broker('a', 'c', node_index=1) remote_put_timestamp = next(ts) remote_broker.initialize(remote_put_timestamp, POLICIES.default.idx) # replicate, expect call to merge_timestamps on remote and local daemon = replicator.ContainerReplicator({}) part, node = self._get_broker_part_node(remote_broker) info = broker.get_replication_info() local_calls = [] remote_calls = [] with self._wrap_merge_timestamps(broker, local_calls): with self._wrap_merge_timestamps(broker, remote_calls): success = daemon._repl_to_node(node, broker, part, info) self.assertTrue(success) self.assertEqual(1, len(remote_calls)) self.assertEqual(1, len(local_calls)) self.assertEqual(remote_put_timestamp, broker.get_info()['put_timestamp']) self.assertEqual(remote_put_timestamp, remote_broker.get_info()['put_timestamp']) # replicate again, no changes so expect no calls to merge_timestamps info = broker.get_replication_info() local_calls = [] remote_calls = [] with self._wrap_merge_timestamps(broker, local_calls): with self._wrap_merge_timestamps(broker, remote_calls): success = daemon._repl_to_node(node, broker, part, info) self.assertTrue(success) self.assertEqual(0, len(remote_calls)) self.assertEqual(0, len(local_calls)) self.assertEqual(remote_put_timestamp, broker.get_info()['put_timestamp']) self.assertEqual(remote_put_timestamp, remote_broker.get_info()['put_timestamp']) def test_sync_bogus_db_quarantines(self): ts = (Timestamp(t).internal for t in itertools.count(int(time.time()))) policy = random.choice(list(POLICIES)) # create "local" broker local_broker = self._get_broker('a', 'c', node_index=0) local_broker.initialize(next(ts), policy.idx) # create "remote" broker remote_broker = self._get_broker('a', 'c', node_index=1) remote_broker.initialize(next(ts), policy.idx) db_path = local_broker.db_file self.assertTrue(os.path.exists(db_path)) # sanity check old_inode = os.stat(db_path).st_ino _orig_get_info = backend.ContainerBroker.get_info def fail_like_bad_db(broker): if broker.db_file == local_broker.db_file: raise sqlite3.OperationalError("no such table: container_info") else: return _orig_get_info(broker) part, node = self._get_broker_part_node(remote_broker) with mock.patch('swift.container.backend.ContainerBroker.get_info', fail_like_bad_db): # Have the remote node replicate to local; local should see its # corrupt DB, quarantine it, and act like the DB wasn't ever there # in the first place. daemon = self._run_once(node) self.assertTrue(os.path.exists(db_path)) # Make sure we didn't just keep the old DB, but quarantined it and # made a fresh copy. new_inode = os.stat(db_path).st_ino self.assertNotEqual(old_inode, new_inode) self.assertEqual(daemon.stats['failure'], 0) def _replication_scenarios(self, *scenarios, **kwargs): remote_wins = kwargs.get('remote_wins', False) # these tests are duplicated because of the differences in replication # when row counts cause full rsync vs. merge scenarios = scenarios or ( 'no_row', 'local_row', 'remote_row', 'both_rows') for scenario_name in scenarios: ts = itertools.count(int(time.time())) policy = random.choice(list(POLICIES)) remote_policy = random.choice( [p for p in POLICIES if p is not policy]) broker = self._get_broker('a', 'c', node_index=0) remote_broker = self._get_broker('a', 'c', node_index=1) yield ts, policy, remote_policy, broker, remote_broker # variations on different replication scenarios variations = { 'no_row': (), 'local_row': (broker,), 'remote_row': (remote_broker,), 'both_rows': (broker, remote_broker), } dbs = variations[scenario_name] obj_ts = next(ts) for db in dbs: db.put_object('/a/c/o', obj_ts, 0, 'content-type', 'etag', storage_policy_index=db.storage_policy_index) # replicate part, node = self._get_broker_part_node(broker) daemon = self._run_once(node) self.assertEqual(0, daemon.stats['failure']) # in sync local_info = self._get_broker( 'a', 'c', node_index=0).get_info() remote_info = self._get_broker( 'a', 'c', node_index=1).get_info() if remote_wins: expected = remote_policy.idx err = 'local policy did not change to match remote ' \ 'for replication row scenario %s' % scenario_name else: expected = policy.idx err = 'local policy changed to match remote ' \ 'for replication row scenario %s' % scenario_name self.assertEqual(local_info['storage_policy_index'], expected, err) self.assertEqual(remote_info['storage_policy_index'], local_info['storage_policy_index']) test_db_replicator.TestReplicatorSync.tearDown(self) test_db_replicator.TestReplicatorSync.setUp(self) def test_sync_local_create_policy_over_newer_remote_create(self): for setup in self._replication_scenarios(): ts, policy, remote_policy, broker, remote_broker = setup # create "local" broker broker.initialize(next(ts), policy.idx) # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) def test_sync_local_create_policy_over_newer_remote_delete(self): for setup in self._replication_scenarios(): ts, policy, remote_policy, broker, remote_broker = setup # create older "local" broker broker.initialize(next(ts), policy.idx) # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # delete "remote" broker remote_broker.delete_db(next(ts)) def test_sync_local_create_policy_over_older_remote_delete(self): # remote_row & both_rows cases are covered by # "test_sync_remote_half_delete_policy_over_newer_local_create" for setup in self._replication_scenarios( 'no_row', 'local_row'): ts, policy, remote_policy, broker, remote_broker = setup # create older "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # delete older "remote" broker remote_broker.delete_db(next(ts)) # create "local" broker broker.initialize(next(ts), policy.idx) def test_sync_local_half_delete_policy_over_newer_remote_create(self): # no_row & remote_row cases are covered by # "test_sync_remote_create_policy_over_older_local_delete" for setup in self._replication_scenarios('local_row', 'both_rows'): ts, policy, remote_policy, broker, remote_broker = setup # create older "local" broker broker.initialize(next(ts), policy.idx) # half delete older "local" broker broker.delete_db(next(ts)) # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) def test_sync_local_recreate_policy_over_newer_remote_create(self): for setup in self._replication_scenarios(): ts, policy, remote_policy, broker, remote_broker = setup # create "local" broker broker.initialize(next(ts), policy.idx) # older recreate "local" broker broker.delete_db(next(ts)) recreate_timestamp = next(ts) broker.update_put_timestamp(recreate_timestamp) broker.update_status_changed_at(recreate_timestamp) # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) def test_sync_local_recreate_policy_over_older_remote_create(self): for setup in self._replication_scenarios(): ts, policy, remote_policy, broker, remote_broker = setup # create older "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # create "local" broker broker.initialize(next(ts), policy.idx) # recreate "local" broker broker.delete_db(next(ts)) recreate_timestamp = next(ts) broker.update_put_timestamp(recreate_timestamp) broker.update_status_changed_at(recreate_timestamp) def test_sync_local_recreate_policy_over_newer_remote_delete(self): for setup in self._replication_scenarios(): ts, policy, remote_policy, broker, remote_broker = setup # create "local" broker broker.initialize(next(ts), policy.idx) # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # recreate "local" broker broker.delete_db(next(ts)) recreate_timestamp = next(ts) broker.update_put_timestamp(recreate_timestamp) broker.update_status_changed_at(recreate_timestamp) # older delete "remote" broker remote_broker.delete_db(next(ts)) def test_sync_local_recreate_policy_over_older_remote_delete(self): for setup in self._replication_scenarios(): ts, policy, remote_policy, broker, remote_broker = setup # create "local" broker broker.initialize(next(ts), policy.idx) # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # older delete "remote" broker remote_broker.delete_db(next(ts)) # recreate "local" broker broker.delete_db(next(ts)) recreate_timestamp = next(ts) broker.update_put_timestamp(recreate_timestamp) broker.update_status_changed_at(recreate_timestamp) def test_sync_local_recreate_policy_over_older_remote_recreate(self): for setup in self._replication_scenarios(): ts, policy, remote_policy, broker, remote_broker = setup # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # create "local" broker broker.initialize(next(ts), policy.idx) # older recreate "remote" broker remote_broker.delete_db(next(ts)) remote_recreate_timestamp = next(ts) remote_broker.update_put_timestamp(remote_recreate_timestamp) remote_broker.update_status_changed_at(remote_recreate_timestamp) # recreate "local" broker broker.delete_db(next(ts)) local_recreate_timestamp = next(ts) broker.update_put_timestamp(local_recreate_timestamp) broker.update_status_changed_at(local_recreate_timestamp) def test_sync_remote_create_policy_over_newer_local_create(self): for setup in self._replication_scenarios(remote_wins=True): ts, policy, remote_policy, broker, remote_broker = setup # create older "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # create "local" broker broker.initialize(next(ts), policy.idx) def test_sync_remote_create_policy_over_newer_local_delete(self): for setup in self._replication_scenarios(remote_wins=True): ts, policy, remote_policy, broker, remote_broker = setup # create older "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # create "local" broker broker.initialize(next(ts), policy.idx) # delete "local" broker broker.delete_db(next(ts)) def test_sync_remote_create_policy_over_older_local_delete(self): # local_row & both_rows cases are covered by # "test_sync_local_half_delete_policy_over_newer_remote_create" for setup in self._replication_scenarios( 'no_row', 'remote_row', remote_wins=True): ts, policy, remote_policy, broker, remote_broker = setup # create older "local" broker broker.initialize(next(ts), policy.idx) # delete older "local" broker broker.delete_db(next(ts)) # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) def test_sync_remote_half_delete_policy_over_newer_local_create(self): # no_row & both_rows cases are covered by # "test_sync_local_create_policy_over_older_remote_delete" for setup in self._replication_scenarios('remote_row', 'both_rows', remote_wins=True): ts, policy, remote_policy, broker, remote_broker = setup # create older "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # half delete older "remote" broker remote_broker.delete_db(next(ts)) # create "local" broker broker.initialize(next(ts), policy.idx) def test_sync_remote_recreate_policy_over_newer_local_create(self): for setup in self._replication_scenarios(remote_wins=True): ts, policy, remote_policy, broker, remote_broker = setup # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # older recreate "remote" broker remote_broker.delete_db(next(ts)) recreate_timestamp = next(ts) remote_broker.update_put_timestamp(recreate_timestamp) remote_broker.update_status_changed_at(recreate_timestamp) # create "local" broker broker.initialize(next(ts), policy.idx) def test_sync_remote_recreate_policy_over_older_local_create(self): for setup in self._replication_scenarios(remote_wins=True): ts, policy, remote_policy, broker, remote_broker = setup # create older "local" broker broker.initialize(next(ts), policy.idx) # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # recreate "remote" broker remote_broker.delete_db(next(ts)) recreate_timestamp = next(ts) remote_broker.update_put_timestamp(recreate_timestamp) remote_broker.update_status_changed_at(recreate_timestamp) def test_sync_remote_recreate_policy_over_newer_local_delete(self): for setup in self._replication_scenarios(remote_wins=True): ts, policy, remote_policy, broker, remote_broker = setup # create "local" broker broker.initialize(next(ts), policy.idx) # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # recreate "remote" broker remote_broker.delete_db(next(ts)) remote_recreate_timestamp = next(ts) remote_broker.update_put_timestamp(remote_recreate_timestamp) remote_broker.update_status_changed_at(remote_recreate_timestamp) # older delete "local" broker broker.delete_db(next(ts)) def test_sync_remote_recreate_policy_over_older_local_delete(self): for setup in self._replication_scenarios(remote_wins=True): ts, policy, remote_policy, broker, remote_broker = setup # create "local" broker broker.initialize(next(ts), policy.idx) # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # older delete "local" broker broker.delete_db(next(ts)) # recreate "remote" broker remote_broker.delete_db(next(ts)) remote_recreate_timestamp = next(ts) remote_broker.update_put_timestamp(remote_recreate_timestamp) remote_broker.update_status_changed_at(remote_recreate_timestamp) def test_sync_remote_recreate_policy_over_older_local_recreate(self): for setup in self._replication_scenarios(remote_wins=True): ts, policy, remote_policy, broker, remote_broker = setup # create older "local" broker broker.initialize(next(ts), policy.idx) # create "remote" broker remote_broker.initialize(next(ts), remote_policy.idx) # older recreate "local" broker broker.delete_db(next(ts)) local_recreate_timestamp = next(ts) broker.update_put_timestamp(local_recreate_timestamp) broker.update_status_changed_at(local_recreate_timestamp) # recreate "remote" broker remote_broker.delete_db(next(ts)) remote_recreate_timestamp = next(ts) remote_broker.update_put_timestamp(remote_recreate_timestamp) remote_broker.update_status_changed_at(remote_recreate_timestamp) def test_sync_to_remote_with_misplaced(self): ts = (Timestamp(t).internal for t in itertools.count(int(time.time()))) # create "local" broker policy = random.choice(list(POLICIES)) broker = self._get_broker('a', 'c', node_index=0) broker.initialize(next(ts), policy.idx) # create "remote" broker remote_policy = random.choice([p for p in POLICIES if p is not policy]) remote_broker = self._get_broker('a', 'c', node_index=1) remote_broker.initialize(next(ts), remote_policy.idx) # add misplaced row to remote_broker remote_broker.put_object( '/a/c/o', next(ts), 0, 'content-type', 'etag', storage_policy_index=remote_broker.storage_policy_index) # since this row matches policy index or remote, it shows up in count self.assertEqual(remote_broker.get_info()['object_count'], 1) self.assertEqual([], remote_broker.get_misplaced_since(-1, 1)) # replicate part, node = self._get_broker_part_node(broker) daemon = self._run_once(node) # since our local broker has no rows to push it logs as no_change self.assertEqual(1, daemon.stats['no_change']) self.assertEqual(0, broker.get_info()['object_count']) # remote broker updates it's policy index; this makes the remote # broker's object count change info = remote_broker.get_info() expectations = { 'object_count': 0, 'storage_policy_index': policy.idx, } for key, value in expectations.items(): self.assertEqual(info[key], value) # but it also knows those objects are misplaced now misplaced = remote_broker.get_misplaced_since(-1, 100) self.assertEqual(len(misplaced), 1) # we also pushed out to node 3 with rsync self.assertEqual(1, daemon.stats['rsync']) third_broker = self._get_broker('a', 'c', node_index=2) info = third_broker.get_info() for key, value in expectations.items(): self.assertEqual(info[key], value) def test_misplaced_rows_replicate_and_enqueue(self): ts = (Timestamp(t).internal for t in itertools.count(int(time.time()))) policy = random.choice(list(POLICIES)) broker = self._get_broker('a', 'c', node_index=0) broker.initialize(next(ts), policy.idx) remote_policy = random.choice([p for p in POLICIES if p is not policy]) remote_broker = self._get_broker('a', 'c', node_index=1) remote_broker.initialize(next(ts), remote_policy.idx) # add a misplaced row to *local* broker obj_put_timestamp = next(ts) broker.put_object( 'o', obj_put_timestamp, 0, 'content-type', 'etag', storage_policy_index=remote_policy.idx) misplaced = broker.get_misplaced_since(-1, 1) self.assertEqual(len(misplaced), 1) # since this row is misplaced it doesn't show up in count self.assertEqual(broker.get_info()['object_count'], 0) # replicate part, node = self._get_broker_part_node(broker) daemon = self._run_once(node) # push to remote, and third node was missing (also maybe reconciler) self.assertTrue(2 < daemon.stats['rsync'] <= 3) # grab the rsynced instance of remote_broker remote_broker = self._get_broker('a', 'c', node_index=1) # remote has misplaced rows too now misplaced = remote_broker.get_misplaced_since(-1, 1) self.assertEqual(len(misplaced), 1) # and the correct policy_index and object_count info = remote_broker.get_info() expectations = { 'object_count': 0, 'storage_policy_index': policy.idx, } for key, value in expectations.items(): self.assertEqual(info[key], value) # and we should have also enqeued these rows in the reconciler reconciler = daemon.get_reconciler_broker(misplaced[0]['created_at']) # but it may not be on the same node as us anymore though... reconciler = self._get_broker(reconciler.account, reconciler.container, node_index=0) self.assertEqual(reconciler.get_info()['object_count'], 1) objects = reconciler.list_objects_iter( 1, '', None, None, None, None, storage_policy_index=0) self.assertEqual(len(objects), 1) expected = ('%s:/a/c/o' % remote_policy.idx, obj_put_timestamp, 0, 'application/x-put', obj_put_timestamp) self.assertEqual(objects[0], expected) # having safely enqueued to the reconciler we can advance # our sync pointer self.assertEqual(broker.get_reconciler_sync(), 1) def test_multiple_out_sync_reconciler_enqueue_normalize(self): ts = (Timestamp(t).internal for t in itertools.count(int(time.time()))) policy = random.choice(list(POLICIES)) broker = self._get_broker('a', 'c', node_index=0) broker.initialize(next(ts), policy.idx) remote_policy = random.choice([p for p in POLICIES if p is not policy]) remote_broker = self._get_broker('a', 'c', node_index=1) remote_broker.initialize(next(ts), remote_policy.idx) # add some rows to brokers for db in (broker, remote_broker): for p in (policy, remote_policy): db.put_object('o-%s' % p.name, next(ts), 0, 'content-type', 'etag', storage_policy_index=p.idx) db._commit_puts() expected_policy_stats = { policy.idx: {'object_count': 1, 'bytes_used': 0}, remote_policy.idx: {'object_count': 1, 'bytes_used': 0}, } for db in (broker, remote_broker): policy_stats = db.get_policy_stats() self.assertEqual(policy_stats, expected_policy_stats) # each db has 2 rows, 4 total all_items = set() for db in (broker, remote_broker): items = db.get_items_since(-1, 4) all_items.update( (item['name'], item['created_at']) for item in items) self.assertEqual(4, len(all_items)) # replicate both ways part, node = self._get_broker_part_node(broker) self._run_once(node) part, node = self._get_broker_part_node(remote_broker) self._run_once(node) # only the latest timestamps should survive most_recent_items = {} for name, timestamp in all_items: most_recent_items[name] = max( timestamp, most_recent_items.get(name, -1)) self.assertEqual(2, len(most_recent_items)) for db in (broker, remote_broker): items = db.get_items_since(-1, 4) self.assertEqual(len(items), len(most_recent_items)) for item in items: self.assertEqual(most_recent_items[item['name']], item['created_at']) # and the reconciler also collapses updates reconciler_containers = set() for item in all_items: _name, timestamp = item reconciler_containers.add( get_reconciler_container_name(timestamp)) reconciler_items = set() for reconciler_container in reconciler_containers: for node_index in range(3): reconciler = self._get_broker(MISPLACED_OBJECTS_ACCOUNT, reconciler_container, node_index=node_index) items = reconciler.get_items_since(-1, 4) reconciler_items.update( (item['name'], item['created_at']) for item in items) # they can't *both* be in the wrong policy ;) self.assertEqual(1, len(reconciler_items)) for reconciler_name, timestamp in reconciler_items: _policy_index, path = reconciler_name.split(':', 1) a, c, name = path.lstrip('/').split('/') self.assertEqual(most_recent_items[name], timestamp) @contextmanager def _wrap_update_reconciler_sync(self, broker, calls): def wrapper_function(*args, **kwargs): calls.append(args) orig_function(*args, **kwargs) orig_function = broker.update_reconciler_sync broker.update_reconciler_sync = wrapper_function try: yield True finally: broker.update_reconciler_sync = orig_function def test_post_replicate_hook(self): ts = (Timestamp(t).internal for t in itertools.count(int(time.time()))) broker = self._get_broker('a', 'c', node_index=0) broker.initialize(next(ts), 0) broker.put_object('foo', next(ts), 0, 'text/plain', 'xyz', deleted=0, storage_policy_index=0) info = broker.get_replication_info() self.assertEqual(1, info['max_row']) self.assertEqual(-1, broker.get_reconciler_sync()) daemon = replicator.ContainerReplicator({}) calls = [] with self._wrap_update_reconciler_sync(broker, calls): daemon._post_replicate_hook(broker, info, []) self.assertEqual(1, len(calls)) # repeated call to _post_replicate_hook with no change to info # should not call update_reconciler_sync calls = [] with self._wrap_update_reconciler_sync(broker, calls): daemon._post_replicate_hook(broker, info, []) self.assertEqual(0, len(calls)) if __name__ == '__main__': unittest.main()
apache-2.0
gojira/tensorflow
tensorflow/python/ops/distributions/student_t.py
13
13767
# Copyright 2016 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # ============================================================================== """Student's t distribution class.""" from __future__ import absolute_import from __future__ import division from __future__ import print_function import numpy as np from tensorflow.python.framework import constant_op from tensorflow.python.framework import dtypes from tensorflow.python.framework import ops from tensorflow.python.framework import tensor_shape from tensorflow.python.ops import array_ops from tensorflow.python.ops import check_ops from tensorflow.python.ops import control_flow_ops from tensorflow.python.ops import math_ops from tensorflow.python.ops import nn from tensorflow.python.ops import random_ops from tensorflow.python.ops import special_math_ops from tensorflow.python.ops.distributions import distribution from tensorflow.python.ops.distributions import util as distribution_util from tensorflow.python.util.tf_export import tf_export __all__ = [ "StudentT", "StudentTWithAbsDfSoftplusScale", ] @tf_export("distributions.StudentT") class StudentT(distribution.Distribution): """Student's t-distribution. This distribution has parameters: degree of freedom `df`, location `loc`, and `scale`. #### Mathematical details The probability density function (pdf) is, ```none pdf(x; df, mu, sigma) = (1 + y**2 / df)**(-0.5 (df + 1)) / Z where, y = (x - mu) / sigma Z = abs(sigma) sqrt(df pi) Gamma(0.5 df) / Gamma(0.5 (df + 1)) ``` where: * `loc = mu`, * `scale = sigma`, and, * `Z` is the normalization constant, and, * `Gamma` is the [gamma function]( https://en.wikipedia.org/wiki/Gamma_function). The StudentT distribution is a member of the [location-scale family]( https://en.wikipedia.org/wiki/Location-scale_family), i.e., it can be constructed as, ```none X ~ StudentT(df, loc=0, scale=1) Y = loc + scale * X ``` Notice that `scale` has semantics more similar to standard deviation than variance. However it is not actually the std. deviation; the Student's t-distribution std. dev. is `scale sqrt(df / (df - 2))` when `df > 2`. Samples of this distribution are reparameterized (pathwise differentiable). The derivatives are computed using the approach described in the paper [Michael Figurnov, Shakir Mohamed, Andriy Mnih. Implicit Reparameterization Gradients, 2018](https://arxiv.org/abs/1805.08498) #### Examples Examples of initialization of one or a batch of distributions. ```python # Define a single scalar Student t distribution. single_dist = tf.distributions.StudentT(df=3) # Evaluate the pdf at 1, returning a scalar Tensor. single_dist.prob(1.) # Define a batch of two scalar valued Student t's. # The first has degrees of freedom 2, mean 1, and scale 11. # The second 3, 2 and 22. multi_dist = tf.distributions.StudentT(df=[2, 3], loc=[1, 2.], scale=[11, 22.]) # Evaluate the pdf of the first distribution on 0, and the second on 1.5, # returning a length two tensor. multi_dist.prob([0, 1.5]) # Get 3 samples, returning a 3 x 2 tensor. multi_dist.sample(3) ``` Arguments are broadcast when possible. ```python # Define a batch of two Student's t distributions. # Both have df 2 and mean 1, but different scales. dist = tf.distributions.StudentT(df=2, loc=1, scale=[11, 22.]) # Evaluate the pdf of both distributions on the same point, 3.0, # returning a length 2 tensor. dist.prob(3.0) ``` Compute the gradients of samples w.r.t. the parameters: ```python df = tf.constant(2.0) loc = tf.constant(2.0) scale = tf.constant(11.0) dist = tf.distributions.StudentT(df=df, loc=loc, scale=scale) samples = dist.sample(5) # Shape [5] loss = tf.reduce_mean(tf.square(samples)) # Arbitrary loss function # Unbiased stochastic gradients of the loss function grads = tf.gradients(loss, [df, loc, scale]) ``` """ # pylint: enable=line-too-long def __init__(self, df, loc, scale, validate_args=False, allow_nan_stats=True, name="StudentT"): """Construct Student's t distributions. The distributions have degree of freedom `df`, mean `loc`, and scale `scale`. The parameters `df`, `loc`, and `scale` must be shaped in a way that supports broadcasting (e.g. `df + loc + scale` is a valid operation). Args: df: Floating-point `Tensor`. The degrees of freedom of the distribution(s). `df` must contain only positive values. loc: Floating-point `Tensor`. The mean(s) of the distribution(s). scale: Floating-point `Tensor`. The scaling factor(s) for the distribution(s). Note that `scale` is not technically the standard deviation of this distribution but has semantics more similar to standard deviation than variance. validate_args: Python `bool`, default `False`. When `True` distribution parameters are checked for validity despite possibly degrading runtime performance. When `False` invalid inputs may silently render incorrect outputs. allow_nan_stats: Python `bool`, default `True`. When `True`, statistics (e.g., mean, mode, variance) use the value "`NaN`" to indicate the result is undefined. When `False`, an exception is raised if one or more of the statistic's batch members are undefined. name: Python `str` name prefixed to Ops created by this class. Raises: TypeError: if loc and scale are different dtypes. """ parameters = dict(locals()) with ops.name_scope(name, values=[df, loc, scale]) as name: with ops.control_dependencies([check_ops.assert_positive(df)] if validate_args else []): self._df = array_ops.identity(df, name="df") self._loc = array_ops.identity(loc, name="loc") self._scale = array_ops.identity(scale, name="scale") check_ops.assert_same_float_dtype( (self._df, self._loc, self._scale)) super(StudentT, self).__init__( dtype=self._scale.dtype, reparameterization_type=distribution.FULLY_REPARAMETERIZED, validate_args=validate_args, allow_nan_stats=allow_nan_stats, parameters=parameters, graph_parents=[self._df, self._loc, self._scale], name=name) @staticmethod def _param_shapes(sample_shape): return dict( zip(("df", "loc", "scale"), ( [ops.convert_to_tensor( sample_shape, dtype=dtypes.int32)] * 3))) @property def df(self): """Degrees of freedom in these Student's t distribution(s).""" return self._df @property def loc(self): """Locations of these Student's t distribution(s).""" return self._loc @property def scale(self): """Scaling factors of these Student's t distribution(s).""" return self._scale def _batch_shape_tensor(self): return array_ops.broadcast_dynamic_shape( array_ops.shape(self.df), array_ops.broadcast_dynamic_shape( array_ops.shape(self.loc), array_ops.shape(self.scale))) def _batch_shape(self): return array_ops.broadcast_static_shape( array_ops.broadcast_static_shape(self.df.get_shape(), self.loc.get_shape()), self.scale.get_shape()) def _event_shape_tensor(self): return constant_op.constant([], dtype=math_ops.int32) def _event_shape(self): return tensor_shape.scalar() def _sample_n(self, n, seed=None): # The sampling method comes from the fact that if: # X ~ Normal(0, 1) # Z ~ Chi2(df) # Y = X / sqrt(Z / df) # then: # Y ~ StudentT(df). shape = array_ops.concat([[n], self.batch_shape_tensor()], 0) normal_sample = random_ops.random_normal(shape, dtype=self.dtype, seed=seed) df = self.df * array_ops.ones(self.batch_shape_tensor(), dtype=self.dtype) gamma_sample = random_ops.random_gamma( [n], 0.5 * df, beta=0.5, dtype=self.dtype, seed=distribution_util.gen_new_seed(seed, salt="student_t")) samples = normal_sample * math_ops.rsqrt(gamma_sample / df) return samples * self.scale + self.loc # Abs(scale) not wanted. def _log_prob(self, x): return self._log_unnormalized_prob(x) - self._log_normalization() def _log_unnormalized_prob(self, x): y = (x - self.loc) / self.scale # Abs(scale) superfluous. return -0.5 * (self.df + 1.) * math_ops.log1p(y**2. / self.df) def _log_normalization(self): return (math_ops.log(math_ops.abs(self.scale)) + 0.5 * math_ops.log(self.df) + 0.5 * np.log(np.pi) + math_ops.lgamma(0.5 * self.df) - math_ops.lgamma(0.5 * (self.df + 1.))) def _cdf(self, x): # Take Abs(scale) to make subsequent where work correctly. y = (x - self.loc) / math_ops.abs(self.scale) x_t = self.df / (y**2. + self.df) neg_cdf = 0.5 * math_ops.betainc(0.5 * self.df, 0.5, x_t) return array_ops.where(math_ops.less(y, 0.), neg_cdf, 1. - neg_cdf) def _entropy(self): v = array_ops.ones(self.batch_shape_tensor(), dtype=self.dtype)[..., array_ops.newaxis] u = v * self.df[..., array_ops.newaxis] beta_arg = array_ops.concat([u, v], -1) / 2. return (math_ops.log(math_ops.abs(self.scale)) + 0.5 * math_ops.log(self.df) + special_math_ops.lbeta(beta_arg) + 0.5 * (self.df + 1.) * (math_ops.digamma(0.5 * (self.df + 1.)) - math_ops.digamma(0.5 * self.df))) @distribution_util.AppendDocstring( """The mean of Student's T equals `loc` if `df > 1`, otherwise it is `NaN`. If `self.allow_nan_stats=True`, then an exception will be raised rather than returning `NaN`.""") def _mean(self): mean = self.loc * array_ops.ones(self.batch_shape_tensor(), dtype=self.dtype) if self.allow_nan_stats: nan = np.array(np.nan, dtype=self.dtype.as_numpy_dtype()) return array_ops.where( math_ops.greater( self.df, array_ops.ones(self.batch_shape_tensor(), dtype=self.dtype)), mean, array_ops.fill(self.batch_shape_tensor(), nan, name="nan")) else: return control_flow_ops.with_dependencies( [ check_ops.assert_less( array_ops.ones([], dtype=self.dtype), self.df, message="mean not defined for components of df <= 1"), ], mean) @distribution_util.AppendDocstring(""" The variance for Student's T equals ``` df / (df - 2), when df > 2 infinity, when 1 < df <= 2 NaN, when df <= 1 ``` """) def _variance(self): # We need to put the tf.where inside the outer tf.where to ensure we never # hit a NaN in the gradient. denom = array_ops.where(math_ops.greater(self.df, 2.), self.df - 2., array_ops.ones_like(self.df)) # Abs(scale) superfluous. var = (array_ops.ones(self.batch_shape_tensor(), dtype=self.dtype) * math_ops.square(self.scale) * self.df / denom) # When 1 < df <= 2, variance is infinite. inf = np.array(np.inf, dtype=self.dtype.as_numpy_dtype()) result_where_defined = array_ops.where( self.df > array_ops.fill(self.batch_shape_tensor(), 2.), var, array_ops.fill(self.batch_shape_tensor(), inf, name="inf")) if self.allow_nan_stats: nan = np.array(np.nan, dtype=self.dtype.as_numpy_dtype()) return array_ops.where( math_ops.greater( self.df, array_ops.ones(self.batch_shape_tensor(), dtype=self.dtype)), result_where_defined, array_ops.fill(self.batch_shape_tensor(), nan, name="nan")) else: return control_flow_ops.with_dependencies( [ check_ops.assert_less( array_ops.ones([], dtype=self.dtype), self.df, message="variance not defined for components of df <= 1"), ], result_where_defined) def _mode(self): return array_ops.identity(self.loc) class StudentTWithAbsDfSoftplusScale(StudentT): """StudentT with `df = floor(abs(df))` and `scale = softplus(scale)`.""" def __init__(self, df, loc, scale, validate_args=False, allow_nan_stats=True, name="StudentTWithAbsDfSoftplusScale"): parameters = dict(locals()) with ops.name_scope(name, values=[df, scale]) as name: super(StudentTWithAbsDfSoftplusScale, self).__init__( df=math_ops.floor(math_ops.abs(df)), loc=loc, scale=nn.softplus(scale, name="softplus_scale"), validate_args=validate_args, allow_nan_stats=allow_nan_stats, name=name) self._parameters = parameters
apache-2.0
gergap/binutils-gdb
gdb/testsuite/gdb.python/py-pp-re-notag.py
32
1208
# Copyright (C) 2013-2014 Free Software Foundation, Inc. # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. from time import asctime, gmtime import gdb # silence pyflakes class TimePrinter: def __init__(self, val): self.val = val def to_string(self): secs = int(self.val) return "%s (%d)" % (asctime(gmtime(secs)), secs) def build_pretty_printer(): pp = gdb.printing.RegexpCollectionPrettyPrinter("pp-notag") pp.add_printer('time_t', 'time_t', TimePrinter) return pp my_pretty_printer = build_pretty_printer() gdb.printing.register_pretty_printer(gdb, my_pretty_printer)
gpl-2.0
dkorolev/omim
3party/Alohalytics/tests/googletest/scripts/gen_gtest_pred_impl.py
2538
21986
#!/usr/bin/env python # # Copyright 2006, Google Inc. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # * Redistributions in binary form must reproduce the above # copyright notice, this list of conditions and the following disclaimer # in the documentation and/or other materials provided with the # distribution. # * Neither the name of Google Inc. nor the names of its # contributors may be used to endorse or promote products derived from # this software without specific prior written permission. # # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. """gen_gtest_pred_impl.py v0.1 Generates the implementation of Google Test predicate assertions and accompanying tests. Usage: gen_gtest_pred_impl.py MAX_ARITY where MAX_ARITY is a positive integer. The command generates the implementation of up-to MAX_ARITY-ary predicate assertions, and writes it to file gtest_pred_impl.h in the directory where the script is. It also generates the accompanying unit test in file gtest_pred_impl_unittest.cc. """ __author__ = 'wan@google.com (Zhanyong Wan)' import os import sys import time # Where this script is. SCRIPT_DIR = os.path.dirname(sys.argv[0]) # Where to store the generated header. HEADER = os.path.join(SCRIPT_DIR, '../include/gtest/gtest_pred_impl.h') # Where to store the generated unit test. UNIT_TEST = os.path.join(SCRIPT_DIR, '../test/gtest_pred_impl_unittest.cc') def HeaderPreamble(n): """Returns the preamble for the header file. Args: n: the maximum arity of the predicate macros to be generated. """ # A map that defines the values used in the preamble template. DEFS = { 'today' : time.strftime('%m/%d/%Y'), 'year' : time.strftime('%Y'), 'command' : '%s %s' % (os.path.basename(sys.argv[0]), n), 'n' : n } return ( """// Copyright 2006, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are // met: // // * Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // * Redistributions in binary form must reproduce the above // copyright notice, this list of conditions and the following disclaimer // in the documentation and/or other materials provided with the // distribution. // * Neither the name of Google Inc. nor the names of its // contributors may be used to endorse or promote products derived from // this software without specific prior written permission. // // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. // This file is AUTOMATICALLY GENERATED on %(today)s by command // '%(command)s'. DO NOT EDIT BY HAND! // // Implements a family of generic predicate assertion macros. #ifndef GTEST_INCLUDE_GTEST_GTEST_PRED_IMPL_H_ #define GTEST_INCLUDE_GTEST_GTEST_PRED_IMPL_H_ // Makes sure this header is not included before gtest.h. #ifndef GTEST_INCLUDE_GTEST_GTEST_H_ # error Do not include gtest_pred_impl.h directly. Include gtest.h instead. #endif // GTEST_INCLUDE_GTEST_GTEST_H_ // This header implements a family of generic predicate assertion // macros: // // ASSERT_PRED_FORMAT1(pred_format, v1) // ASSERT_PRED_FORMAT2(pred_format, v1, v2) // ... // // where pred_format is a function or functor that takes n (in the // case of ASSERT_PRED_FORMATn) values and their source expression // text, and returns a testing::AssertionResult. See the definition // of ASSERT_EQ in gtest.h for an example. // // If you don't care about formatting, you can use the more // restrictive version: // // ASSERT_PRED1(pred, v1) // ASSERT_PRED2(pred, v1, v2) // ... // // where pred is an n-ary function or functor that returns bool, // and the values v1, v2, ..., must support the << operator for // streaming to std::ostream. // // We also define the EXPECT_* variations. // // For now we only support predicates whose arity is at most %(n)s. // Please email googletestframework@googlegroups.com if you need // support for higher arities. // GTEST_ASSERT_ is the basic statement to which all of the assertions // in this file reduce. Don't use this in your code. #define GTEST_ASSERT_(expression, on_failure) \\ GTEST_AMBIGUOUS_ELSE_BLOCKER_ \\ if (const ::testing::AssertionResult gtest_ar = (expression)) \\ ; \\ else \\ on_failure(gtest_ar.failure_message()) """ % DEFS) def Arity(n): """Returns the English name of the given arity.""" if n < 0: return None elif n <= 3: return ['nullary', 'unary', 'binary', 'ternary'][n] else: return '%s-ary' % n def Title(word): """Returns the given word in title case. The difference between this and string's title() method is that Title('4-ary') is '4-ary' while '4-ary'.title() is '4-Ary'.""" return word[0].upper() + word[1:] def OneTo(n): """Returns the list [1, 2, 3, ..., n].""" return range(1, n + 1) def Iter(n, format, sep=''): """Given a positive integer n, a format string that contains 0 or more '%s' format specs, and optionally a separator string, returns the join of n strings, each formatted with the format string on an iterator ranged from 1 to n. Example: Iter(3, 'v%s', sep=', ') returns 'v1, v2, v3'. """ # How many '%s' specs are in format? spec_count = len(format.split('%s')) - 1 return sep.join([format % (spec_count * (i,)) for i in OneTo(n)]) def ImplementationForArity(n): """Returns the implementation of n-ary predicate assertions.""" # A map the defines the values used in the implementation template. DEFS = { 'n' : str(n), 'vs' : Iter(n, 'v%s', sep=', '), 'vts' : Iter(n, '#v%s', sep=', '), 'arity' : Arity(n), 'Arity' : Title(Arity(n)) } impl = """ // Helper function for implementing {EXPECT|ASSERT}_PRED%(n)s. Don't use // this in your code. template <typename Pred""" % DEFS impl += Iter(n, """, typename T%s""") impl += """> AssertionResult AssertPred%(n)sHelper(const char* pred_text""" % DEFS impl += Iter(n, """, const char* e%s""") impl += """, Pred pred""" impl += Iter(n, """, const T%s& v%s""") impl += """) { if (pred(%(vs)s)) return AssertionSuccess(); """ % DEFS impl += ' return AssertionFailure() << pred_text << "("' impl += Iter(n, """ << e%s""", sep=' << ", "') impl += ' << ") evaluates to false, where"' impl += Iter(n, """ << "\\n" << e%s << " evaluates to " << v%s""") impl += """; } // Internal macro for implementing {EXPECT|ASSERT}_PRED_FORMAT%(n)s. // Don't use this in your code. #define GTEST_PRED_FORMAT%(n)s_(pred_format, %(vs)s, on_failure)\\ GTEST_ASSERT_(pred_format(%(vts)s, %(vs)s), \\ on_failure) // Internal macro for implementing {EXPECT|ASSERT}_PRED%(n)s. Don't use // this in your code. #define GTEST_PRED%(n)s_(pred, %(vs)s, on_failure)\\ GTEST_ASSERT_(::testing::AssertPred%(n)sHelper(#pred""" % DEFS impl += Iter(n, """, \\ #v%s""") impl += """, \\ pred""" impl += Iter(n, """, \\ v%s""") impl += """), on_failure) // %(Arity)s predicate assertion macros. #define EXPECT_PRED_FORMAT%(n)s(pred_format, %(vs)s) \\ GTEST_PRED_FORMAT%(n)s_(pred_format, %(vs)s, GTEST_NONFATAL_FAILURE_) #define EXPECT_PRED%(n)s(pred, %(vs)s) \\ GTEST_PRED%(n)s_(pred, %(vs)s, GTEST_NONFATAL_FAILURE_) #define ASSERT_PRED_FORMAT%(n)s(pred_format, %(vs)s) \\ GTEST_PRED_FORMAT%(n)s_(pred_format, %(vs)s, GTEST_FATAL_FAILURE_) #define ASSERT_PRED%(n)s(pred, %(vs)s) \\ GTEST_PRED%(n)s_(pred, %(vs)s, GTEST_FATAL_FAILURE_) """ % DEFS return impl def HeaderPostamble(): """Returns the postamble for the header file.""" return """ #endif // GTEST_INCLUDE_GTEST_GTEST_PRED_IMPL_H_ """ def GenerateFile(path, content): """Given a file path and a content string, overwrites it with the given content.""" print 'Updating file %s . . .' % path f = file(path, 'w+') print >>f, content, f.close() print 'File %s has been updated.' % path def GenerateHeader(n): """Given the maximum arity n, updates the header file that implements the predicate assertions.""" GenerateFile(HEADER, HeaderPreamble(n) + ''.join([ImplementationForArity(i) for i in OneTo(n)]) + HeaderPostamble()) def UnitTestPreamble(): """Returns the preamble for the unit test file.""" # A map that defines the values used in the preamble template. DEFS = { 'today' : time.strftime('%m/%d/%Y'), 'year' : time.strftime('%Y'), 'command' : '%s %s' % (os.path.basename(sys.argv[0]), sys.argv[1]), } return ( """// Copyright 2006, Google Inc. // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions are // met: // // * Redistributions of source code must retain the above copyright // notice, this list of conditions and the following disclaimer. // * Redistributions in binary form must reproduce the above // copyright notice, this list of conditions and the following disclaimer // in the documentation and/or other materials provided with the // distribution. // * Neither the name of Google Inc. nor the names of its // contributors may be used to endorse or promote products derived from // this software without specific prior written permission. // // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR // A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT // OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT // LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, // DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. // This file is AUTOMATICALLY GENERATED on %(today)s by command // '%(command)s'. DO NOT EDIT BY HAND! // Regression test for gtest_pred_impl.h // // This file is generated by a script and quite long. If you intend to // learn how Google Test works by reading its unit tests, read // gtest_unittest.cc instead. // // This is intended as a regression test for the Google Test predicate // assertions. We compile it as part of the gtest_unittest target // only to keep the implementation tidy and compact, as it is quite // involved to set up the stage for testing Google Test using Google // Test itself. // // Currently, gtest_unittest takes ~11 seconds to run in the testing // daemon. In the future, if it grows too large and needs much more // time to finish, we should consider separating this file into a // stand-alone regression test. #include <iostream> #include "gtest/gtest.h" #include "gtest/gtest-spi.h" // A user-defined data type. struct Bool { explicit Bool(int val) : value(val != 0) {} bool operator>(int n) const { return value > Bool(n).value; } Bool operator+(const Bool& rhs) const { return Bool(value + rhs.value); } bool operator==(const Bool& rhs) const { return value == rhs.value; } bool value; }; // Enables Bool to be used in assertions. std::ostream& operator<<(std::ostream& os, const Bool& x) { return os << (x.value ? "true" : "false"); } """ % DEFS) def TestsForArity(n): """Returns the tests for n-ary predicate assertions.""" # A map that defines the values used in the template for the tests. DEFS = { 'n' : n, 'es' : Iter(n, 'e%s', sep=', '), 'vs' : Iter(n, 'v%s', sep=', '), 'vts' : Iter(n, '#v%s', sep=', '), 'tvs' : Iter(n, 'T%s v%s', sep=', '), 'int_vs' : Iter(n, 'int v%s', sep=', '), 'Bool_vs' : Iter(n, 'Bool v%s', sep=', '), 'types' : Iter(n, 'typename T%s', sep=', '), 'v_sum' : Iter(n, 'v%s', sep=' + '), 'arity' : Arity(n), 'Arity' : Title(Arity(n)), } tests = ( """// Sample functions/functors for testing %(arity)s predicate assertions. // A %(arity)s predicate function. template <%(types)s> bool PredFunction%(n)s(%(tvs)s) { return %(v_sum)s > 0; } // The following two functions are needed to circumvent a bug in // gcc 2.95.3, which sometimes has problem with the above template // function. bool PredFunction%(n)sInt(%(int_vs)s) { return %(v_sum)s > 0; } bool PredFunction%(n)sBool(%(Bool_vs)s) { return %(v_sum)s > 0; } """ % DEFS) tests += """ // A %(arity)s predicate functor. struct PredFunctor%(n)s { template <%(types)s> bool operator()(""" % DEFS tests += Iter(n, 'const T%s& v%s', sep=""", """) tests += """) { return %(v_sum)s > 0; } }; """ % DEFS tests += """ // A %(arity)s predicate-formatter function. template <%(types)s> testing::AssertionResult PredFormatFunction%(n)s(""" % DEFS tests += Iter(n, 'const char* e%s', sep=""", """) tests += Iter(n, """, const T%s& v%s""") tests += """) { if (PredFunction%(n)s(%(vs)s)) return testing::AssertionSuccess(); return testing::AssertionFailure() << """ % DEFS tests += Iter(n, 'e%s', sep=' << " + " << ') tests += """ << " is expected to be positive, but evaluates to " << %(v_sum)s << "."; } """ % DEFS tests += """ // A %(arity)s predicate-formatter functor. struct PredFormatFunctor%(n)s { template <%(types)s> testing::AssertionResult operator()(""" % DEFS tests += Iter(n, 'const char* e%s', sep=""", """) tests += Iter(n, """, const T%s& v%s""") tests += """) const { return PredFormatFunction%(n)s(%(es)s, %(vs)s); } }; """ % DEFS tests += """ // Tests for {EXPECT|ASSERT}_PRED_FORMAT%(n)s. class Predicate%(n)sTest : public testing::Test { protected: virtual void SetUp() { expected_to_finish_ = true; finished_ = false;""" % DEFS tests += """ """ + Iter(n, 'n%s_ = ') + """0; } """ tests += """ virtual void TearDown() { // Verifies that each of the predicate's arguments was evaluated // exactly once.""" tests += ''.join([""" EXPECT_EQ(1, n%s_) << "The predicate assertion didn't evaluate argument %s " "exactly once.";""" % (i, i + 1) for i in OneTo(n)]) tests += """ // Verifies that the control flow in the test function is expected. if (expected_to_finish_ && !finished_) { FAIL() << "The predicate assertion unexpactedly aborted the test."; } else if (!expected_to_finish_ && finished_) { FAIL() << "The failed predicate assertion didn't abort the test " "as expected."; } } // true iff the test function is expected to run to finish. static bool expected_to_finish_; // true iff the test function did run to finish. static bool finished_; """ % DEFS tests += Iter(n, """ static int n%s_;""") tests += """ }; bool Predicate%(n)sTest::expected_to_finish_; bool Predicate%(n)sTest::finished_; """ % DEFS tests += Iter(n, """int Predicate%%(n)sTest::n%s_; """) % DEFS tests += """ typedef Predicate%(n)sTest EXPECT_PRED_FORMAT%(n)sTest; typedef Predicate%(n)sTest ASSERT_PRED_FORMAT%(n)sTest; typedef Predicate%(n)sTest EXPECT_PRED%(n)sTest; typedef Predicate%(n)sTest ASSERT_PRED%(n)sTest; """ % DEFS def GenTest(use_format, use_assert, expect_failure, use_functor, use_user_type): """Returns the test for a predicate assertion macro. Args: use_format: true iff the assertion is a *_PRED_FORMAT*. use_assert: true iff the assertion is a ASSERT_*. expect_failure: true iff the assertion is expected to fail. use_functor: true iff the first argument of the assertion is a functor (as opposed to a function) use_user_type: true iff the predicate functor/function takes argument(s) of a user-defined type. Example: GenTest(1, 0, 0, 1, 0) returns a test that tests the behavior of a successful EXPECT_PRED_FORMATn() that takes a functor whose arguments have built-in types.""" if use_assert: assrt = 'ASSERT' # 'assert' is reserved, so we cannot use # that identifier here. else: assrt = 'EXPECT' assertion = assrt + '_PRED' if use_format: pred_format = 'PredFormat' assertion += '_FORMAT' else: pred_format = 'Pred' assertion += '%(n)s' % DEFS if use_functor: pred_format_type = 'functor' pred_format += 'Functor%(n)s()' else: pred_format_type = 'function' pred_format += 'Function%(n)s' if not use_format: if use_user_type: pred_format += 'Bool' else: pred_format += 'Int' test_name = pred_format_type.title() if use_user_type: arg_type = 'user-defined type (Bool)' test_name += 'OnUserType' if expect_failure: arg = 'Bool(n%s_++)' else: arg = 'Bool(++n%s_)' else: arg_type = 'built-in type (int)' test_name += 'OnBuiltInType' if expect_failure: arg = 'n%s_++' else: arg = '++n%s_' if expect_failure: successful_or_failed = 'failed' expected_or_not = 'expected.' test_name += 'Failure' else: successful_or_failed = 'successful' expected_or_not = 'UNEXPECTED!' test_name += 'Success' # A map that defines the values used in the test template. defs = DEFS.copy() defs.update({ 'assert' : assrt, 'assertion' : assertion, 'test_name' : test_name, 'pf_type' : pred_format_type, 'pf' : pred_format, 'arg_type' : arg_type, 'arg' : arg, 'successful' : successful_or_failed, 'expected' : expected_or_not, }) test = """ // Tests a %(successful)s %(assertion)s where the // predicate-formatter is a %(pf_type)s on a %(arg_type)s. TEST_F(%(assertion)sTest, %(test_name)s) {""" % defs indent = (len(assertion) + 3)*' ' extra_indent = '' if expect_failure: extra_indent = ' ' if use_assert: test += """ expected_to_finish_ = false; EXPECT_FATAL_FAILURE({ // NOLINT""" else: test += """ EXPECT_NONFATAL_FAILURE({ // NOLINT""" test += '\n' + extra_indent + """ %(assertion)s(%(pf)s""" % defs test = test % defs test += Iter(n, ',\n' + indent + extra_indent + '%(arg)s' % defs) test += ');\n' + extra_indent + ' finished_ = true;\n' if expect_failure: test += ' }, "");\n' test += '}\n' return test # Generates tests for all 2**6 = 64 combinations. tests += ''.join([GenTest(use_format, use_assert, expect_failure, use_functor, use_user_type) for use_format in [0, 1] for use_assert in [0, 1] for expect_failure in [0, 1] for use_functor in [0, 1] for use_user_type in [0, 1] ]) return tests def UnitTestPostamble(): """Returns the postamble for the tests.""" return '' def GenerateUnitTest(n): """Returns the tests for up-to n-ary predicate assertions.""" GenerateFile(UNIT_TEST, UnitTestPreamble() + ''.join([TestsForArity(i) for i in OneTo(n)]) + UnitTestPostamble()) def _Main(): """The entry point of the script. Generates the header file and its unit test.""" if len(sys.argv) != 2: print __doc__ print 'Author: ' + __author__ sys.exit(1) n = int(sys.argv[1]) GenerateHeader(n) GenerateUnitTest(n) if __name__ == '__main__': _Main()
apache-2.0
Philippe12/external_chromium_org
tools/perf/metrics/io.py
24
2489
# Copyright 2013 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file. from metrics import Metric class IOMetric(Metric): """IO-related metrics, obtained via telemetry.core.Browser.""" @classmethod def CustomizeBrowserOptions(cls, options): options.AppendExtraBrowserArgs('--no-sandbox') def Start(self, page, tab): raise NotImplementedError() def Stop(self, page, tab): raise NotImplementedError() def AddResults(self, tab, results): # This metric currently only returns summary results, not per-page results. raise NotImplementedError() def AddSummaryResults(self, browser, results): """Add summary results to the results object.""" io_stats = browser.io_stats if not io_stats['Browser']: return def AddSummariesForProcessType(process_type_io, process_type_trace): """For a given process type, add all relevant summary results. Args: process_type_io: Type of process (eg Browser or Renderer). process_type_trace: String to be added to the trace name in the results. """ if 'ReadOperationCount' in io_stats[process_type_io]: results.AddSummary('read_operations_' + process_type_trace, 'count', io_stats[process_type_io] ['ReadOperationCount'], data_type='unimportant') if 'WriteOperationCount' in io_stats[process_type_io]: results.AddSummary('write_operations_' + process_type_trace, 'count', io_stats[process_type_io] ['WriteOperationCount'], data_type='unimportant') if 'ReadTransferCount' in io_stats[process_type_io]: results.AddSummary('read_bytes_' + process_type_trace, 'kb', io_stats[process_type_io] ['ReadTransferCount'] / 1024, data_type='unimportant') if 'WriteTransferCount' in io_stats[process_type_io]: results.AddSummary('write_bytes_' + process_type_trace, 'kb', io_stats[process_type_io] ['WriteTransferCount'] / 1024, data_type='unimportant') AddSummariesForProcessType('Browser', 'browser') AddSummariesForProcessType('Renderer', 'renderer') AddSummariesForProcessType('Gpu', 'gpu')
bsd-3-clause
OpenAcademy-OpenStack/nova-scheduler
nova/tests/objects/test_aggregate.py
7
5514
# Copyright 2013 IBM Corp. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations # under the License. from nova import db from nova import exception from nova.objects import aggregate from nova.openstack.common import timeutils from nova.tests.objects import test_objects NOW = timeutils.utcnow().replace(microsecond=0) fake_aggregate = { 'created_at': NOW, 'updated_at': None, 'deleted_at': None, 'deleted': False, 'id': 123, 'name': 'fake-aggregate', 'hosts': ['foo', 'bar'], 'metadetails': {'this': 'that'}, } SUBS = {'metadata': 'metadetails'} class _TestAggregateObject(object): def test_get_by_id(self): self.mox.StubOutWithMock(db, 'aggregate_get') db.aggregate_get(self.context, 123).AndReturn(fake_aggregate) self.mox.ReplayAll() agg = aggregate.Aggregate.get_by_id(self.context, 123) self.compare_obj(agg, fake_aggregate, subs=SUBS) def test_create(self): self.mox.StubOutWithMock(db, 'aggregate_create') db.aggregate_create(self.context, {'name': 'foo'}, metadata={'one': 'two'}).AndReturn(fake_aggregate) self.mox.ReplayAll() agg = aggregate.Aggregate() agg.name = 'foo' agg.metadata = {'one': 'two'} agg.create(self.context) self.compare_obj(agg, fake_aggregate, subs=SUBS) def test_save(self): self.mox.StubOutWithMock(db, 'aggregate_update') db.aggregate_update(self.context, 123, {'name': 'baz'}).AndReturn( fake_aggregate) self.mox.ReplayAll() agg = aggregate.Aggregate() agg.id = 123 agg.name = 'baz' agg.save(self.context) self.compare_obj(agg, fake_aggregate, subs=SUBS) def test_save_and_create_no_hosts(self): agg = aggregate.Aggregate() agg.id = 123 agg.hosts = ['foo', 'bar'] self.assertRaises(exception.ObjectActionError, agg.create, self.context) self.assertRaises(exception.ObjectActionError, agg.save, self.context) def test_update_metadata(self): self.mox.StubOutWithMock(db, 'aggregate_metadata_delete') self.mox.StubOutWithMock(db, 'aggregate_metadata_add') db.aggregate_metadata_delete(self.context, 123, 'todelete') db.aggregate_metadata_add(self.context, 123, {'toadd': 'myval'}) self.mox.ReplayAll() agg = aggregate.Aggregate() agg._context = self.context agg.id = 123 agg.metadata = {'foo': 'bar'} agg.obj_reset_changes() agg.update_metadata({'todelete': None, 'toadd': 'myval'}) self.assertEqual({'foo': 'bar', 'toadd': 'myval'}, agg.metadata) def test_destroy(self): self.mox.StubOutWithMock(db, 'aggregate_delete') db.aggregate_delete(self.context, 123) self.mox.ReplayAll() agg = aggregate.Aggregate() agg.id = 123 agg.destroy(self.context) def test_add_host(self): self.mox.StubOutWithMock(db, 'aggregate_host_add') db.aggregate_host_add(self.context, 123, 'bar' ).AndReturn({'host': 'bar'}) self.mox.ReplayAll() agg = aggregate.Aggregate() agg.id = 123 agg.hosts = ['foo'] agg._context = self.context agg.add_host('bar') self.assertEqual(agg.hosts, ['foo', 'bar']) def test_delete_host(self): self.mox.StubOutWithMock(db, 'aggregate_host_delete') db.aggregate_host_delete(self.context, 123, 'foo') self.mox.ReplayAll() agg = aggregate.Aggregate() agg.id = 123 agg.hosts = ['foo', 'bar'] agg._context = self.context agg.delete_host('foo') self.assertEqual(agg.hosts, ['bar']) def test_availability_zone(self): agg = aggregate.Aggregate() agg.metadata = {'availability_zone': 'foo'} self.assertEqual('foo', agg.availability_zone) def test_get_all(self): self.mox.StubOutWithMock(db, 'aggregate_get_all') db.aggregate_get_all(self.context).AndReturn([fake_aggregate]) self.mox.ReplayAll() aggs = aggregate.AggregateList.get_all(self.context) self.assertEqual(1, len(aggs)) self.compare_obj(aggs[0], fake_aggregate, subs=SUBS) def test_by_host(self): self.mox.StubOutWithMock(db, 'aggregate_get_by_host') db.aggregate_get_by_host(self.context, 'fake-host', key=None, ).AndReturn([fake_aggregate]) self.mox.ReplayAll() aggs = aggregate.AggregateList.get_by_host(self.context, 'fake-host') self.assertEqual(1, len(aggs)) self.compare_obj(aggs[0], fake_aggregate, subs=SUBS) class TestAggregateObject(test_objects._LocalTest, _TestAggregateObject): pass class TestRemoteAggregateObject(test_objects._RemoteTest, _TestAggregateObject): pass
apache-2.0
sintrb/pyBaidu
BaiduUser.py
1
2577
# -*- coding: UTF-8 -* ''' Created on 2013-10-14 @author: RobinTang ''' import time from HttpHolder import HttpHolder import sys try: sys.setdefaultencoding("utf-8") except: pass def strbetween(s, ss, es): si = s.index(ss) return s[si:s.index(es, si)] class BaseBaiduUser(): ''' 基础百度用户 ''' def __init__(self, cookies): ''' 创建一个BaseBaiduUser实例,需指定可用的Cookie,主要是BDUSS值 ''' self.http = HttpHolder(headers={'User-Agent':'Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/29.0.1547.57 Safari/537.36'}) self.http.set_cookiesdict(cookies) def verifyCookie(self): ''' 检查当前Cookie是否可用 ''' url = 'http://i.baidu.com/center' self.http.open_html('http://i.baidu.com/center') return self.http.geturl() == url def sendMessage(self, touser, message='message'): ''' 发送消息 touser, 消息目的用户名 message, 消息内容 ''' form = { 'msgcontent':message, 'msgreceiver':touser, 'refmid':'5255694744', 'vcode':'', 'msgvcode':'', 'bdstoken':'7e1fee8373e8883e95da301f7d2194ec', 'qing_request_source':'' } head = { 'Origin':'http://msg.baidu.com', 'Referer':'http://msg.baidu.com/?t=%d' % (time.time() - 100), 'X-Requested-With':'XMLHttpRequest' } html = self.http.open_html(url='http://msg.baidu.com/msg/writing/submit/msg', headers=head, data=form) return html.find('errorNo : "0"') >= 0 def createText(self, title='Title', content='Content'): form = { 'title':title, 'content':'<p>%s</p>' % content, 'private':'', 'imgnum':'0', 'bdstoken':'7e1fee8373e8883e95da301f7d2194ec', 'qbid':'', 'refer:http':'//hi.baidu.com/home/?from=index', 'multimedia[]':'', 'synflag':'', 'private1':'', 'qing_request_source':'new_request' } head = { 'Origin':'http://hi.baidu.com', 'Referer':'http://hi.baidu.com/pub/show/createtext', 'X-Requested-With':'XMLHttpRequest' } html = self.http.open_html(url='http://hi.baidu.com/pub/submit/createtext', headers=head, data=form) return html.find('"errorNo" : "0"') >= 0 if __name__ == '__main__': import config # cookies值现在测试出来只需要BDUSS即可 bdu = BaseBaiduUser(cookies=config.baiducookie) # 验证Cookie是否可以使用 if bdu.verifyCookie(): # 发私信消息 print bdu.sendMessage(touser='trbbadboy', message='小道消息:%d' % time.time()) # 在百度空间创建文章 print bdu.createText(title='标题%d' % time.time(), content='内容啊内容%d' % time.time())
gpl-2.0
offlinehacker/flumotion
flumotion/common/process.py
2
11302
# -*- Mode: Python; test-case-name: flumotion.test.test_common_process -*- # vi:si:et:sw=4:sts=4:ts=4 # # Flumotion - a streaming media server # Copyright (C) 2004,2005,2006,2007,2008 Fluendo, S.L. (www.fluendo.com). # All rights reserved. # This file may be distributed and/or modified under the terms of # the GNU General Public License version 2 as published by # the Free Software Foundation. # This file is distributed without any warranty; without even the implied # warranty of merchantability or fitness for a particular purpose. # See "LICENSE.GPL" in the source distribution for more information. # Licensees having purchased or holding a valid Flumotion Advanced # Streaming Server license may use this file in accordance with the # Flumotion Advanced Streaming Server Commercial License Agreement. # See "LICENSE.Flumotion" in the source distribution for more information. # Headers in this file shall remain intact. """utilities for interacting with processes""" import errno import os import signal import sys import time from flumotion.common import log from flumotion.common.common import ensureDir from flumotion.configure import configure __version__ = "$Rev: 6690 $" def startup(processType, processName, daemonize=False, daemonizeTo='/'): """ Prepare a process for starting, logging appropriate standarised messages. First daemonizes the process, if daemonize is true. @param processType: The process type, for example 'worker'. Used as the first part of the log file and PID file names. @type processType: str @param processName: The service name of the process. Used to disambiguate different instances of the same daemon. Used as the second part of log file and PID file names. @type processName: str @param daemonize: whether to daemonize the current process. @type daemonize: bool @param daemonizeTo: The directory that the daemon should run in. @type daemonizeTo: str """ log.info(processType, "Starting %s '%s'", processType, processName) if daemonize: _daemonizeHelper(processType, daemonizeTo, processName) log.info(processType, "Started %s '%s'", processType, processName) def shutdownStarted(): log.info(processType, "Stopping %s '%s'", processType, processName) def shutdownEnded(): log.info(processType, "Stopped %s '%s'", processType, processName) # import inside function so we avoid affecting startup from twisted.internet import reactor reactor.addSystemEventTrigger('before', 'shutdown', shutdownStarted) reactor.addSystemEventTrigger('after', 'shutdown', shutdownEnded) def daemonize(stdin='/dev/null', stdout='/dev/null', stderr='/dev/null', directory='/'): ''' This forks the current process into a daemon. The stdin, stdout, and stderr arguments are file names that will be opened and be used to replace the standard file descriptors in sys.stdin, sys.stdout, and sys.stderr. These arguments are optional and default to /dev/null. The fork will switch to the given directory. Used by external projects (ft). ''' # Redirect standard file descriptors. si = open(stdin, 'r') os.dup2(si.fileno(), sys.stdin.fileno()) try: log.outputToFiles(stdout, stderr) except IOError, e: if e.errno == errno.EACCES: log.error('common', 'Permission denied writing to log file %s.', e.filename) # first fork try: pid = os.fork() if pid > 0: sys.exit(0) # exit first parent except OSError, e: sys.stderr.write("Failed to fork: (%d) %s\n" % (e.errno, e.strerror)) sys.exit(1) # decouple from parent environment try: os.chdir(directory) except OSError, e: from flumotion.common import errors raise errors.FatalError, "Failed to change directory to %s: %s" % ( directory, e.strerror) os.umask(0) os.setsid() # do second fork try: pid = os.fork() if pid > 0: sys.exit(0) # exit second parent except OSError, e: sys.stderr.write("Failed to fork: (%d) %s\n" % (e.errno, e.strerror)) sys.exit(1) # Now I am a daemon! # don't add stuff here that can fail, because from now on the program # will keep running regardless of tracebacks def _daemonizeHelper(processType, daemonizeTo='/', processName=None): """ Daemonize a process, writing log files and PID files to conventional locations. @param processType: The process type, for example 'worker'. Used as the first part of the log file and PID file names. @type processType: str @param daemonizeTo: The directory that the daemon should run in. @type daemonizeTo: str @param processName: The service name of the process. Used to disambiguate different instances of the same daemon. Used as the second part of log file and PID file names. @type processName: str """ ensureDir(configure.logdir, "log dir") ensureDir(configure.rundir, "run dir") ensureDir(configure.cachedir, "cache dir") ensureDir(configure.registrydir, "registry dir") pid = getPid(processType, processName) if pid: raise SystemError( "A %s service%s is already running with pid %d" % ( processType, processName and ' named %s' % processName or '', pid)) log.debug(processType, "%s service named '%s' daemonizing", processType, processName) if processName: logPath = os.path.join(configure.logdir, '%s.%s.log' % (processType, processName)) else: logPath = os.path.join(configure.logdir, '%s.log' % (processType, )) log.debug(processType, 'Further logging will be done to %s', logPath) pidFile = _acquirePidFile(processType, processName) # here we daemonize; so we also change our pid daemonize(stdout=logPath, stderr=logPath, directory=daemonizeTo) log.debug(processType, 'Started daemon') # from now on I should keep running until killed, whatever happens path = writePidFile(processType, processName, file=pidFile) log.debug(processType, 'written pid file %s', path) # import inside function so we avoid affecting startup from twisted.internet import reactor def _deletePidFile(): log.debug(processType, 'deleting pid file') deletePidFile(processType, processName) reactor.addSystemEventTrigger('after', 'shutdown', _deletePidFile) def _getPidPath(type, name=None): """ Get the full path to the pid file for the given process type and name. """ path = os.path.join(configure.rundir, '%s.pid' % type) if name: path = os.path.join(configure.rundir, '%s.%s.pid' % (type, name)) log.debug('common', 'getPidPath for type %s, name %r: %s' % ( type, name, path)) return path def writePidFile(type, name=None, file=None): """ Write a pid file in the run directory, using the given process type and process name for the filename. @rtype: str @returns: full path to the pid file that was written """ # don't shadow builtin file pidFile = file if pidFile is None: ensureDir(configure.rundir, "rundir") filename = _getPidPath(type, name) pidFile = open(filename, 'w') else: filename = pidFile.name pidFile.write("%d\n" % (os.getpid(), )) pidFile.close() os.chmod(filename, 0644) return filename def _acquirePidFile(type, name=None): """ Open a PID file for writing, using the given process type and process name for the filename. The returned file can be then passed to writePidFile after forking. @rtype: str @returns: file object, open for writing """ ensureDir(configure.rundir, "rundir") path = _getPidPath(type, name) return open(path, 'w') def deletePidFile(type, name=None, force=False): """ Delete the pid file in the run directory, using the given process type and process name for the filename. @param force: if errors due to the file not existing should be ignored @type force: bool @rtype: str @returns: full path to the pid file that was written """ path = _getPidPath(type, name) try: os.unlink(path) except OSError, e: if e.errno == errno.ENOENT and force: pass else: raise return path def getPid(type, name=None): """ Get the pid from the pid file in the run directory, using the given process type and process name for the filename. @returns: pid of the process, or None if not running or file not found. """ pidPath = _getPidPath(type, name) log.log('common', 'pidfile for %s %s is %s' % (type, name, pidPath)) if not os.path.exists(pidPath): return pidFile = open(pidPath, 'r') pid = pidFile.readline() pidFile.close() if not pid or int(pid) == 0: return return int(pid) def signalPid(pid, signum): """ Send the given process a signal. @returns: whether or not the process with the given pid was running """ try: os.kill(pid, signum) return True except OSError, e: # see man 2 kill if e.errno == errno.EPERM: # exists but belongs to a different user return True if e.errno == errno.ESRCH: # pid does not exist return False raise def termPid(pid): """ Send the given process a TERM signal. @returns: whether or not the process with the given pid was running """ return signalPid(pid, signal.SIGTERM) def killPid(pid): """ Send the given process a KILL signal. @returns: whether or not the process with the given pid was running """ return signalPid(pid, signal.SIGKILL) def checkPidRunning(pid): """ Check if the given pid is currently running. @returns: whether or not a process with that pid is active. """ return signalPid(pid, 0) def waitPidFile(type, name=None): """ Wait for the given process type and name to have started and created a pid file. Return the pid. """ # getting it from the start avoids an unneeded time.sleep pid = getPid(type, name) while not pid: time.sleep(0.1) pid = getPid(type, name) return pid def waitForTerm(): """ Wait until we get killed by a TERM signal (from someone else). """ class Waiter: def __init__(self): self.sleeping = True import signal self.oldhandler = signal.signal(signal.SIGTERM, self._SIGTERMHandler) def _SIGTERMHandler(self, number, frame): self.sleeping = False def sleep(self): while self.sleeping: time.sleep(0.1) waiter = Waiter() waiter.sleep()
gpl-2.0
SerCeMan/intellij-community
python/helpers/pydev/pydevd_signature.py
19
4907
import inspect import os try: import trace except ImportError: pass else: trace._warn = lambda *args: None # workaround for http://bugs.python.org/issue17143 (PY-8706) import gc from pydevd_comm import CMD_SIGNATURE_CALL_TRACE, NetCommand import pydevd_vars from pydevd_constants import xrange class Signature(object): def __init__(self, file, name): self.file = file self.name = name self.args = [] self.args_str = [] def add_arg(self, name, type): self.args.append((name, type)) self.args_str.append("%s:%s"%(name, type)) def __str__(self): return "%s %s(%s)"%(self.file, self.name, ", ".join(self.args_str)) class SignatureFactory(object): def __init__(self): self._caller_cache = {} self.project_roots = os.getenv('IDE_PROJECT_ROOTS', '').split(os.pathsep) def is_in_scope(self, filename): filename = os.path.normcase(filename) for root in self.project_roots: root = os.path.normcase(root) if filename.startswith(root): return True return False def create_signature(self, frame): try: code = frame.f_code locals = frame.f_locals filename, modulename, funcname = self.file_module_function_of(frame) res = Signature(filename, funcname) for i in xrange(0, code.co_argcount): name = code.co_varnames[i] tp = type(locals[name]) class_name = tp.__name__ if class_name == 'instance': # old-style classes tp = locals[name].__class__ class_name = tp.__name__ if tp.__module__ and tp.__module__ != '__main__': class_name = "%s.%s"%(tp.__module__, class_name) res.add_arg(name, class_name) return res except: import traceback traceback.print_exc() def file_module_function_of(self, frame): #this code is take from trace module and fixed to work with new-style classes code = frame.f_code filename = code.co_filename if filename: modulename = trace.modname(filename) else: modulename = None funcname = code.co_name clsname = None if code in self._caller_cache: if self._caller_cache[code] is not None: clsname = self._caller_cache[code] else: self._caller_cache[code] = None ## use of gc.get_referrers() was suggested by Michael Hudson # all functions which refer to this code object funcs = [f for f in gc.get_referrers(code) if inspect.isfunction(f)] # require len(func) == 1 to avoid ambiguity caused by calls to # new.function(): "In the face of ambiguity, refuse the # temptation to guess." if len(funcs) == 1: dicts = [d for d in gc.get_referrers(funcs[0]) if isinstance(d, dict)] if len(dicts) == 1: classes = [c for c in gc.get_referrers(dicts[0]) if hasattr(c, "__bases__") or inspect.isclass(c)] elif len(dicts) > 1: #new-style classes classes = [c for c in gc.get_referrers(dicts[1]) if hasattr(c, "__bases__") or inspect.isclass(c)] else: classes = [] if len(classes) == 1: # ditto for new.classobj() clsname = classes[0].__name__ # cache the result - assumption is that new.* is # not called later to disturb this relationship # _caller_cache could be flushed if functions in # the new module get called. self._caller_cache[code] = clsname if clsname is not None: funcname = "%s.%s" % (clsname, funcname) return filename, modulename, funcname def create_signature_message(signature): cmdTextList = ["<xml>"] cmdTextList.append('<call_signature file="%s" name="%s">' % (pydevd_vars.makeValidXmlValue(signature.file), pydevd_vars.makeValidXmlValue(signature.name))) for arg in signature.args: cmdTextList.append('<arg name="%s" type="%s"></arg>' % (pydevd_vars.makeValidXmlValue(arg[0]), pydevd_vars.makeValidXmlValue(arg[1]))) cmdTextList.append("</call_signature></xml>") cmdText = ''.join(cmdTextList) return NetCommand(CMD_SIGNATURE_CALL_TRACE, 0, cmdText) def sendSignatureCallTrace(dbg, frame, filename): if dbg.signature_factory.is_in_scope(filename): dbg.writer.addCommand(create_signature_message(dbg.signature_factory.create_signature(frame)))
apache-2.0
eresearchrmit/mavrec
smra/smra_portal/management/commands/bonza.py
2
2454
# -*- coding: utf-8 -*- # # Copyright (c) 2011,2012 RMIT e-Research Office # (RMIT University, Australia) # All rights reserved. # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are met: # # * Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # * Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # * Neither the name of RMIT University nor the # names of its contributors may be used to endorse or promote products # derived from this software without specific prior written permission. # # THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND ANY # EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED # WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE # DISCLAIMED. IN NO EVENT SHALL THE REGENTS AND CONTRIBUTORS BE LIABLE FOR ANY # DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES # (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; # LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND # ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS # SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # import logging from django.core.management.base import BaseCommand, CommandError from smra.smra_portal.repos import Bonza2 from smra.smra_portal.ReposPlugin import ReposPlugin logger = logging.getLogger(__name__) class Command(BaseCommand): args = '' help = 'Utility functions for the Bonza2 DB.\nmakeschemas : creates' \ 'SMRA schemas for Bonza data' def handle(self, *args, **options): if len(args) < 1: self.stdout.write("no command specified\n") return if args[0] == 'makeschemas': repos = ReposPlugin() afi = Bonza2.ReposConverter() afi.setup_schemas(repos) self.stdout.write('done') else: self.stdout.write("no command specified\n")
bsd-3-clause
2uller/LotF
App/Lib/site-packages/scipy/integrate/tests/test_quadpack.py
4
5503
from __future__ import division, print_function, absolute_import from numpy import sqrt, cos, sin, arctan, exp, log, pi, Inf from numpy.testing import assert_, TestCase, run_module_suite, dec from scipy.integrate import quad, dblquad, tplquad from scipy.lib.six.moves import xrange import sys import math try: import ctypes _ctypes_missing = False except ImportError: _ctypes_missing = True def assert_quad(value_and_err, tabledValue, errTol=1.5e-8): value, err = value_and_err assert_(abs(value-tabledValue) < err, (value, tabledValue, err)) if errTol is not None: assert_(err < errTol, (err, errTol)) class TestCtypesQuad(TestCase): @dec.skipif(_ctypes_missing, msg="Ctypes library could not be found") def setUp(self): if sys.platform == 'win32': file = 'msvcrt.dll' elif sys.platform == 'darwin': file = 'libm.dylib' else: file = 'libm.so' self.lib = ctypes.CDLL(file) restype = ctypes.c_double argtypes = (ctypes.c_double,) for name in ['sin', 'cos', 'tan']: func = getattr(self.lib, name) func.restype = restype func.argtypes = argtypes @dec.skipif(_ctypes_missing, msg="Ctypes library could not be found") def test_typical(self): assert_quad(quad(self.lib.sin,0,5),quad(math.sin,0,5)[0]) assert_quad(quad(self.lib.cos,0,5),quad(math.cos,0,5)[0]) assert_quad(quad(self.lib.tan,0,1),quad(math.tan,0,1)[0]) #@dec.skipif(_ctypes_missing, msg="Ctypes library could not be found") # This doesn't seem to always work. Need a better way to figure out # whether the fast path is called. @dec.knownfailureif(True, msg="Unreliable test, see ticket 1684.") def test_improvement(self): import time start = time.time() for i in xrange(100): quad(self.lib.sin, 0, 100) fast = time.time() - start start = time.time() for i in xrange(100): quad(math.sin, 0, 100) slow = time.time() - start assert_(fast < 0.5*slow, (fast, slow)) class TestQuad(TestCase): def test_typical(self): # 1) Typical function with two extra arguments: def myfunc(x,n,z): # Bessel function integrand return cos(n*x-z*sin(x))/pi assert_quad(quad(myfunc,0,pi,(2,1.8)), 0.30614353532540296487) def test_indefinite(self): # 2) Infinite integration limits --- Euler's constant def myfunc(x): # Euler's constant integrand return -exp(-x)*log(x) assert_quad(quad(myfunc,0,Inf), 0.577215664901532860606512) def test_singular(self): # 3) Singular points in region of integration. def myfunc(x): if x > 0 and x < 2.5: return sin(x) elif x>= 2.5 and x <= 5.0: return exp(-x) else: return 0.0 assert_quad(quad(myfunc,0,10,points=[2.5,5.0]), 1 - cos(2.5) + exp(-2.5) - exp(-5.0)) def test_sine_weighted_finite(self): # 4) Sine weighted integral (finite limits) def myfunc(x,a): return exp(a*(x-1)) ome = 2.0**3.4 assert_quad(quad(myfunc,0,1,args=20,weight='sin',wvar=ome), (20*sin(ome)-ome*cos(ome)+ome*exp(-20))/(20**2 + ome**2)) def test_sine_weighted_infinite(self): # 5) Sine weighted integral (infinite limits) def myfunc(x,a): return exp(-x*a) a = 4.0 ome = 3.0 assert_quad(quad(myfunc,0,Inf,args=a,weight='sin',wvar=ome), ome/(a**2 + ome**2)) def test_cosine_weighted_infinite(self): # 6) Cosine weighted integral (negative infinite limits) def myfunc(x,a): return exp(x*a) a = 2.5 ome = 2.3 assert_quad(quad(myfunc,-Inf,0,args=a,weight='cos',wvar=ome), a/(a**2 + ome**2)) def test_algebraic_log_weight(self): # 6) Algebraic-logarithmic weight. def myfunc(x,a): return 1/(1+x+2**(-a)) a = 1.5 assert_quad(quad(myfunc,-1,1,args=a,weight='alg',wvar=(-0.5,-0.5)), pi/sqrt((1+2**(-a))**2 - 1)) def test_cauchypv_weight(self): # 7) Cauchy prinicpal value weighting w(x) = 1/(x-c) def myfunc(x,a): return 2.0**(-a)/((x-1)**2+4.0**(-a)) a = 0.4 tabledValue = (2.0**(-0.4)*log(1.5)-2.0**(-1.4)*log((4.0**(-a)+16)/(4.0**(-a)+1)) - arctan(2.0**(a+2)) - arctan(2.0**a))/(4.0**(-a) + 1) assert_quad(quad(myfunc,0,5,args=0.4,weight='cauchy',wvar=2.0), tabledValue, errTol=1.9e-8) def test_double_integral(self): # 8) Double Integral test def simpfunc(y,x): # Note order of arguments. return x+y a, b = 1.0, 2.0 assert_quad(dblquad(simpfunc,a,b,lambda x: x, lambda x: 2*x), 5/6.0 * (b**3.0-a**3.0)) def test_triple_integral(self): # 9) Triple Integral test def simpfunc(z,y,x): # Note order of arguments. return x+y+z a, b = 1.0, 2.0 assert_quad(tplquad(simpfunc,a,b, lambda x: x, lambda x: 2*x, lambda x,y: x-y, lambda x,y: x+y), 8/3.0 * (b**4.0 - a**4.0)) if __name__ == "__main__": run_module_suite()
gpl-2.0
akashlevy/Yaklient
yaklient/objects/user.py
3
19663
# -*- coding: utf-8 -*- """Class for a user on Yik Yak""" from yaklient import helper from yaklient import settings from yaklient.api import notifyapi, parseapi, yikyakapi from yaklient.objects.comment import Comment from yaklient.objects.location import Location from yaklient.objects.message import Message from yaklient.objects.notification import Notification, check_notif_error from yaklient.objects.peeklocation import PeekLocation from yaklient.objects.yak import Yak from yaklient.config import locationize_endpoint from yaklient.helper import ParsingResponseError class User(object): """A user who interacts with Yik Yak""" def __init__(self, location, user_id=None): """Initialize user with location and user_id""" self.basecamp_location = None self.basecamp_name = None self.basecamp_set = False self.location = location self.user_id = user_id self.yakarma = None # Set endpoint to nearest server if required if settings.LOCATIONIZE_ENDPOINT: locationize_endpoint(self.location) # If no user ID specified, register new user if self.user_id is None: self.user_id = helper.generate_id(dashes=False, upper=True) # Do not register with Parse if APPID or CLIENTKEY is missing if None in [settings.PARSE_APPID, settings.PARSE_CLIENTKEY]: self.register(parse_register=False) else: self.register() # Log user ID in file if required if settings.LOG_USERIDS: with open("userids", "a") as userid_file: userid_file.write(self.user_id + "\n") # Update user properties from server self.update() def __str__(self): """Return user (user ID) as string""" return "User(%s) at %s" % (self.user_id, str(self.location)) def _convert_to_comment_id(self, comment, yak): """Return comment_id and message_id from comment and yak""" # Get message_id from yak if yak is not None: message_id = self._convert_to_message_id(yak) # If comment is a Comment, use comment's comment_id and message_id if isinstance(comment, Comment): comment_id = comment.comment_id message_id = comment.message_id # If comment is a string, treat comment as the comment_id elif isinstance(comment, basestring): comment_id = comment # Otherwise, TypeError else: raise TypeError("comment is not Message/string: " + str(comment)) try: return comment_id, message_id except NameError: raise NameError("No Yak specified") @staticmethod def _convert_to_message_id(yak): """Return message_id from yak""" # If yak is a Message, use yak's message_id if isinstance(yak, Message): message_id = yak.message_id # If yak is a string, treat yak as the message_id elif isinstance(yak, basestring): message_id = yak # Otherwise, TypeError else: raise TypeError("yak is not Message/string: " + str(yak)) return message_id @staticmethod def _convert_to_peek_id(peek): """Return peek_id from peek""" # If peek is a PeekLocation, use peek's peek_id if isinstance(peek, PeekLocation): peek_id = peek.peek_id # If peek is a string, treat peek as the peek_id elif isinstance(peek, basestring): peek_id = peek # Otherwise, TypeError else: raise TypeError("peek is not Message/string" + str(peek)) return peek_id def _get_comment_list(self, raw_data): """Return list of comments from raw""" try: return [Comment(raw, self) for raw in raw_data.json()["comments"]] except (KeyError, ValueError): raise ParsingResponseError("Getting comment list failed", raw_data) def _get_notification_list(self, raw_data): """Return list of Yaks from raw server response""" try: return [Notification(raw, self) for raw in raw_data.json()["data"]] except (KeyError, ValueError): raise ParsingResponseError("Getting notifs failed", raw_data) def _get_peek_location_list(self, raw_data, categ): """Return list of peek locations in category (categ) from raw""" try: return [PeekLocation(raw, self) for raw in raw_data.json()[categ]] except (KeyError, ValueError): raise ParsingResponseError("Getting peek list failed", raw_data) def _get_yak_list(self, raw_data): """Return list of Yaks from raw""" #try: yaks = [Yak(raw, self) for raw in raw_data.json()["messages"]] #except (KeyError, ValueError): # raise ParsingResponseError("Getting Yak list failed", raw_data) # If no Yaks, return empty list if yaks == []: return yaks # If no user-created Yaks in given area, return empty list if yaks[0].message_id == settings.NO_YAKS_MESSAGE_ID: return [] # If too close to school, raise exception elif yaks[0].message_id == settings.TOO_CLOSE_TO_SCHOOL_MESSAGE_ID: raise TooCloseToSchoolException("School nearby/invalid location") return yaks def _validate_basecamp(self, basecamp): """Raise error if basecamp is True but user has not set basecamp""" if basecamp and not self.basecamp_set: raise NoBasecampSetError("Tried to use basecamp when not set") def register(self, parse_register=True, yikyak_register=True): """Register with Parse (if parse_register is True) and Yik Yak (if yikyak_register is True). Return True if successful, False if unsuccessful""" if parse_register: parseapi.register_user(self.user_id) if yikyak_register: yikyakapi.register_user(self) def update(self): """Update Yakarma and basecamp information""" raw = yikyakapi.get_messages(self, self.location, basecamp=True) # Check if too close to school self._get_yak_list(raw) try: self.yakarma = int(raw.json()["yakarma"]) except (KeyError, ValueError): raise ParsingResponseError("Getting Yakarma failed", raw) try: self.basecamp_set = bool(int(raw.json()["bcEligible"])) except (KeyError, ValueError): raise ParsingResponseError("Getting bcEligible failed", raw) try: latitude = float(raw.json()["bcLat"]) longitude = float(raw.json()["bcLong"]) self.basecamp_name = raw.json()["bcName"] self.basecamp_location = Location(latitude, longitude) except (KeyError, ValueError): pass def get_yak(self, yak): """Return Yak (or None if it does not exist)""" message_id = self._convert_to_message_id(yak) raw = yikyakapi.get_message(self, message_id) try: return self._get_yak_list(raw)[0] except IndexError: return None def get_yaks(self, location=None, basecamp=False): """Return a list of Yaks at particular location (optionally at basecamp)""" # Set location if not None, otherwise set to user's location location = location if location else self.location self._validate_basecamp(basecamp) raw = yikyakapi.get_messages(self, location, basecamp) return self._get_yak_list(raw) def get_featured_peek_locations(self): """Return a list of featured peek locations""" raw = yikyakapi.get_messages(self, self.location) return self._get_peek_location_list(raw, "featuredLocations") def get_other_peek_locations(self): """Return a list of other peek locations""" raw = yikyakapi.get_messages(self, self.location) return self._get_peek_location_list(raw, "otherLocations") def get_peek_yaks(self, location): """Return a list of Yaks at particular location/peek location""" # If location is a PeekLocation, use get_peek_messages if isinstance(location, PeekLocation): raw = yikyakapi.get_peek_messages(self, location.peek_id) # If location is a Location, use yaks elif isinstance(location, Location): raw = yikyakapi.yaks(self, location) # Otherwise, TypeError else: raise TypeError("location is not Location or PeekLocation") return self._get_yak_list(raw) def get_top_yaks(self, location=None, basecamp=False): """Return a list of the top Yaks at location/basecamp""" # Set location if not None, otherwise set to user's location location = location if location else self.location self._validate_basecamp(basecamp) raw = yikyakapi.hot(self, location, basecamp) return self._get_yak_list(raw) def get_user_recent_yaks(self): """Return a list of recent Yaks by user""" raw = yikyakapi.get_my_recent_yaks(self) return self._get_yak_list(raw) def get_user_recent_commented(self): """Return a list of Yaks with comments by user""" raw = yikyakapi.get_my_recent_replies(self) return self._get_yak_list(raw) def get_user_top_yaks(self): """Return a list of top Yaks by user""" raw = yikyakapi.get_my_tops(self) return self._get_yak_list(raw) def get_area_top_yaks(self): """Return a list of top Yaks in the area""" raw = yikyakapi.get_area_tops(self) return self._get_yak_list(raw) def get_comment(self, comment, yak=None, basecamp=False): """Return comment on a Yak (or None if it does not exist, optionally at basecamp)""" self._validate_basecamp(basecamp) (comment_id, message_id) = self._convert_to_comment_id(comment, yak) for comment in self.get_comments(message_id, basecamp=basecamp): if comment_id == comment.comment_id: return comment return None def get_comments(self, yak, basecamp=False): """Return a list of comments on a Yak (optionally at basecamp)""" self._validate_basecamp(basecamp) message_id = self._convert_to_message_id(yak) raw = yikyakapi.get_comments(self, message_id, basecamp) return self._get_comment_list(raw) def upvote(self, message, basecamp=False): """Upvote/unupvote a message (Yak/comment, optionally at basecamp). Return True if successful, False if unsuccessful""" self._validate_basecamp(basecamp) if isinstance(message, Yak): return self.upvote_yak(message, basecamp=basecamp) elif isinstance(message, Comment): return self.upvote_comment(message, basecamp=basecamp) else: raise TypeError("yak is not Message") def downvote(self, message, basecamp=False): """Downvote/undownvote a message (Yak/comment, optionally at basecamp). Return True if successful, False if unsuccessful""" self._validate_basecamp(basecamp) if isinstance(message, Yak): return self.downvote_yak(message, basecamp=basecamp) elif isinstance(message, Comment): return self.downvote_comment(message, basecamp=basecamp) else: raise TypeError("yak is not Message") def upvote_yak(self, yak, basecamp=False): """Upvote/unupvote a Yak (optionally at basecamp). Return True if successful, False if unsuccessful""" self._validate_basecamp(basecamp) message_id = self._convert_to_message_id(yak) liked = self.get_yak(message_id).liked yikyakapi.like_message(self, message_id, basecamp) self.update() return self.get_yak(message_id).liked != liked def downvote_yak(self, yak, basecamp=False): """Downvote/undownvote a Yak (optionally at basecamp). Return True if successful, False if unsuccessful""" self._validate_basecamp(basecamp) message_id = self._convert_to_message_id(yak) liked = self.get_yak(message_id).liked yikyakapi.downvote_message(self, message_id, basecamp) self.update() return self.get_yak(message_id).liked != liked def upvote_comment(self, comment, yak=None, basecamp=False): """Upvote/unupvote a comment (optionally at basecamp). Return True if successful, False if unsuccessful""" self._validate_basecamp(basecamp) (comment_id, message_id) = self._convert_to_comment_id(comment, yak) liked = self.get_comment(message_id, comment_id).liked yikyakapi.like_comment(self, comment_id, basecamp) self.update() return self.get_comment(message_id, comment_id).liked != liked def downvote_comment(self, comment, yak=None, basecamp=False): """Downvote/undownvote a comment (optionally at basecamp). Return True if successful, False if unsuccessful""" self._validate_basecamp(basecamp) (comment_id, message_id) = self._convert_to_comment_id(comment, yak) liked = self.get_comment(message_id, comment_id).liked yikyakapi.downvote_comment(self, comment_id, basecamp) self.update() return self.get_comment(message_id, comment_id).liked != liked def report(self, message, reason, basecamp=False): """Report a message (Yak/comment) for reason (optionally at basecamp)""" self._validate_basecamp(basecamp) if isinstance(message, Yak): self.report_yak(message, reason, basecamp=basecamp) elif isinstance(message, Comment): self.report_comment(message, reason, basecamp=basecamp) else: raise TypeError("yak is not Message") def report_yak(self, yak, reason, basecamp=False): """Report a Yak for reason (optionally at basecamp)""" self._validate_basecamp(basecamp) message_id = self._convert_to_message_id(yak) yikyakapi.report_message(self, message_id, reason, basecamp) def report_comment(self, comment, reason, yak=None, basecamp=False): """Report a comment for reason (optionally at basecamp)""" self._validate_basecamp(basecamp) (comment_id, message_id) = self._convert_to_comment_id(comment, yak) yikyakapi.report_comment(self, comment_id, message_id, reason, basecamp) def delete(self, message, basecamp=False): """Delete a message (Yak/comment, optionally at basecamp). Return True if successful, False if unsuccessful""" self._validate_basecamp(basecamp) if isinstance(message, Yak): return self.delete_yak(message, basecamp=basecamp) elif isinstance(message, Comment): return self.delete_comment(message, basecamp=basecamp) else: raise TypeError("yak is not Message") def delete_yak(self, yak, basecamp=False): """Delete a Yak (optionally at basecamp). Return True if successful, False if unsuccessful""" self._validate_basecamp(basecamp) message_id = self._convert_to_message_id(yak) yikyakapi.delete_message(self, message_id, basecamp) return self.get_yak(message_id) is None def delete_comment(self, comment, yak=None, basecamp=False): """Delete a comment (optionally at basecamp). Return True if successful, False if unsuccessful""" self._validate_basecamp(basecamp) (comment_id, message_id) = self._convert_to_comment_id(comment, yak) print comment_id, message_id yikyakapi.delete_comment(self, comment_id, message_id, basecamp) return self.get_comment(comment_id, message_id) is None def post_yak(self, message, handle=None, btp=False, basecamp=False): """Post a Yak with optional handle (optionally at basecamp and optionally with parameter bypassedThreatPopup as btp). Return the Yak once loaded (or None if not posted)""" self._validate_basecamp(basecamp) raw = yikyakapi.send_message(self, message, handle, btp, basecamp) # Yaks only post if get_messages is called directly after yikyakapi.get_messages(self, self.location, basecamp=basecamp) self.update() # If success is reported if bool(int(raw.text)): try: return self.get_yaks(basecamp=basecamp)[0] except IndexError: return None else: return None def post_comment(self, comment, yak, btp=False, basecamp=False): """Post a comment on a yak (optionally at basecamp and optionally with parameter bypassedThreatPopup as btp). Return the comment (or None if not posted)""" self._validate_basecamp(basecamp) message_id = self._convert_to_message_id(yak) raw = yikyakapi.post_comment(self, comment, message_id, btp, basecamp) # Comments only post properly if get_comments is called directly after yikyakapi.get_comments(self, message_id, basecamp=basecamp) self.update() # If success is reported if bool(int(raw.text)): try: return self.get_comments(message_id, basecamp=basecamp)[-1] except IndexError: return None else: return None def submit_peek_yak(self, message, peek, handle=None, btp=False): """Submit a message with optional handle for review to a peek location (ID: peek_id)""" peek_id = self._convert_to_peek_id(peek) yikyakapi.submit_peek_message(self, message, peek_id, handle, btp) def contact_yikyak(self, message, category, email): """Send Yik Yak a message in particular category with specified email""" yikyakapi.contact_us(self, message, category, email) def get_notifications(self): """Get all notifications for user""" raw = notifyapi.get_all_for_user(self.user_id) return self._get_notification_list(raw) def _mark_notifications(self, status): """Mark all notifications for user as read""" notif_ids = [notif.notif_id for notif in self.get_notifications()] raw = notifyapi.update_batch(notif_ids, status, self.user_id) check_notif_error(raw) def mark_notifications_read(self): """Mark all notifications for user as read""" return self._mark_notifications("read") def mark_notifications_unread(self): """Mark all notifications for user as unread""" return self._mark_notifications("unread") def set_basecamp(self, name, location=None): """Set the basecamp to location with name. Return True if successful, False if unsuccessful""" # Set location if not None, otherwise set to user's location location = location if location else self.location raw = yikyakapi.save_basecamp(self, name, location) self.update() try: return raw.json()["saveBasecamp"] except (KeyError, ValueError): raise ParsingResponseError("Setting basecamp failed", raw) class NoBasecampSetError(Exception): """Exception that is raised when trying to access non-existent basecamp""" pass class TooCloseToSchoolException(Exception): """Exception that is raised when location is too close to a school""" pass
mit
WillisXChen/django-oscar
oscar/lib/python2.7/site-packages/phonenumbers/geodata/data4.py
1
690490
"""Per-prefix data, mapping each prefix to a dict of locale:name. Auto-generated file, do not edit by hand. """ from ..util import u # Copyright (C) 2011-2014 The Libphonenumber Authors # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. data = { '35236':{'de': 'Hesperingen/Kockelscheuer/Roeser', 'en': 'Hesperange/Kockelscheuer/Roeser', 'fr': 'Hesperange/Kockelscheuer/Roeser'}, '35237':{'de': 'Leudelingen/Ehlingen/Monnerich', 'en': 'Leudelange/Ehlange/Mondercange', 'fr': 'Leudelange/Ehlange/Mondercange'}, '35234':{'de': 'Rammeldingen/Senningerberg', 'en': 'Rameldange/Senningerberg', 'fr': 'Rameldange/Senningerberg'}, '35235':{'de': 'Sandweiler/Mutfort/Roodt-sur-Syre', 'en': 'Sandweiler/Moutfort/Roodt-sur-Syre', 'fr': 'Sandweiler/Moutfort/Roodt-sur-Syre'}, '35232':{'de': 'Kanton Mersch', 'en': 'Mersch', 'fr': 'Mersch'}, '35233':{'de': 'Walferdingen', 'en': 'Walferdange', 'fr': 'Walferdange'}, '35230':{'de': 'Kanton Capellen/Kehlen', 'en': 'Capellen/Kehlen', 'fr': 'Capellen/Kehlen'}, '35547':{'en': u('Kam\u00ebz/Vor\u00eb/Paskuqan/Zall-Herr/Burxull\u00eb/Prez\u00eb, Tiran\u00eb')}, '35548':{'en': u('Kashar/Vaqar/Ndroq/Pez\u00eb/Fark\u00eb/Dajt, Tiran\u00eb')}, '35549':{'en': u('Petrel\u00eb/Baldushk/B\u00ebrzhit\u00eb/Krrab\u00eb/Shengjergj/Zall-Bastar, Tiran\u00eb')}, '35239':{'de': 'Windhof/Steinfort', 'en': 'Windhof/Steinfort', 'fr': 'Windhof/Steinfort'}, '3332660':{'en': 'Sainte-Menehould', 'fr': 'Sainte-Menehould'}, '35231':{'de': 'Bartringen', 'en': 'Bertrange', 'fr': 'Bertrange'}, '3593120':{'bg': u('\u0425\u0440\u0430\u0431\u0440\u0438\u043d\u043e'), 'en': 'Hrabrino'}, '3332669':{'en': u('Ch\u00e2lons-en-Champagne'), 'fr': u('Ch\u00e2lons-en-Champagne')}, '435550':{'de': u('Th\u00fcringen'), 'en': u('Th\u00fcringen')}, '441779':{'en': 'Peterhead'}, '441778':{'en': 'Bourne'}, '441777':{'en': 'Retford'}, '441776':{'en': 'Stranraer'}, '441775':{'en': 'Spalding'}, '441773':{'en': 'Ripley'}, '441772':{'en': 'Preston'}, '441771':{'en': 'Maud'}, '441770':{'en': 'Isle of Arran'}, '3596026':{'bg': u('\u041c\u0430\u043a\u0430\u0440\u0438\u043e\u043f\u043e\u043b\u0441\u043a\u043e'), 'en': 'Makariopolsko'}, '3596027':{'bg': u('\u0414\u0440\u0430\u043b\u0444\u0430'), 'en': 'Dralfa'}, '3596024':{'bg': u('\u0420\u0443\u0435\u0446'), 'en': 'Ruets'}, '3596025':{'bg': u('\u0410\u043b\u0432\u0430\u043d\u043e\u0432\u043e'), 'en': 'Alvanovo'}, '3316468':{'en': 'Champs-sur-Marne', 'fr': 'Champs-sur-Marne'}, '3316469':{'en': 'Fontainebleau', 'fr': 'Fontainebleau'}, '3596020':{'bg': u('\u041b\u0438\u043b\u044f\u043a'), 'en': 'Lilyak'}, '3346758':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3316464':{'en': 'Melun', 'fr': 'Melun'}, '3316465':{'en': 'Coulommiers', 'fr': 'Coulommiers'}, '3316466':{'en': 'Bussy-Saint-Georges', 'fr': 'Bussy-Saint-Georges'}, '3316467':{'en': 'Villeparisis', 'fr': 'Villeparisis'}, '3316460':{'en': 'Provins', 'fr': 'Provins'}, '3316461':{'en': 'Champs-sur-Marne', 'fr': 'Champs-sur-Marne'}, '3316462':{'en': 'Lognes', 'fr': 'Lognes'}, '3316463':{'en': u('Cr\u00e9cy-la-Chapelle'), 'fr': u('Cr\u00e9cy-la-Chapelle')}, '3349008':{'en': 'Lauris', 'fr': 'Lauris'}, '3349009':{'en': 'Pertuis', 'fr': 'Pertuis'}, '435556':{'de': 'Schruns', 'en': 'Schruns'}, '3349002':{'en': u('Mori\u00e8res-l\u00e8s-Avignon'), 'fr': u('Mori\u00e8res-l\u00e8s-Avignon')}, '3349003':{'en': 'Le Pontet', 'fr': 'Le Pontet'}, '3349001':{'en': 'Caumont-sur-Durance', 'fr': 'Caumont-sur-Durance'}, '3349006':{'en': 'Cavaillon', 'fr': 'Cavaillon'}, '3349007':{'en': 'La Tour d\'Aigues', 'fr': 'La Tour d\'Aigues'}, '3349004':{'en': 'Apt', 'fr': 'Apt'}, '3349005':{'en': 'Roussillon', 'fr': 'Roussillon'}, '435558':{'de': 'Gaschurn', 'en': 'Gaschurn'}, '37426699':{'am': u('\u053f\u0578\u0569\u056b'), 'en': 'Koti', 'ru': u('\u041a\u043e\u0447\u0438')}, '37426696':{'am': u('\u0548\u057d\u056f\u0565\u057a\u0561\u0580'), 'en': 'Voskepar', 'ru': u('\u0412\u043e\u0441\u043a\u0435\u043f\u0430\u0440')}, '37426695':{'am': u('\u0536\u0578\u0580\u0561\u056f\u0561\u0576'), 'en': 'Zorakan', 'ru': u('\u0417\u043e\u0440\u0430\u043a\u0430\u043d')}, '37426693':{'am': u('\u0532\u0561\u0572\u0561\u0576\u056b\u057d'), 'en': 'Baghanis', 'ru': u('\u0411\u0430\u0433\u0430\u043d\u0438\u0441')}, '37426692':{'am': u('\u0531\u0580\u0573\u056b\u057d'), 'en': 'Archis', 'ru': u('\u0410\u0440\u0447\u0438\u0441')}, '35931397':{'bg': u('\u0425\u0440\u0438\u0441\u0442\u043e \u0414\u0430\u043d\u043e\u0432\u043e'), 'en': 'Hristo Danovo'}, '35931396':{'bg': u('\u0414\u043e\u043c\u043b\u044f\u043d'), 'en': 'Domlyan'}, '35931395':{'bg': u('\u0418\u0433\u0430\u043d\u043e\u0432\u043e'), 'en': 'Iganovo'}, '35931394':{'bg': u('\u0412\u0430\u0441\u0438\u043b \u041b\u0435\u0432\u0441\u043a\u0438, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Vasil Levski, Plovdiv'}, '35931393':{'bg': u('\u0412\u043e\u0439\u043d\u044f\u0433\u043e\u0432\u043e'), 'en': 'Voynyagovo'}, '35931392':{'bg': u('\u0414\u044a\u0431\u0435\u043d\u0435'), 'en': 'Dabene'}, '3323560':{'en': 'Bois-Guillaume', 'fr': 'Bois-Guillaume'}, '35931390':{'bg': u('\u041c\u043e\u0441\u043a\u043e\u0432\u0435\u0446'), 'en': 'Moskovets'}, '35931398':{'bg': u('\u0421\u043b\u0430\u0442\u0438\u043d\u0430, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Slatina, Plovdiv'}, '3522735':{'de': 'Sandweiler/Mutfort/Roodt-sur-Syre', 'en': 'Sandweiler/Moutfort/Roodt-sur-Syre', 'fr': 'Sandweiler/Moutfort/Roodt-sur-Syre'}, '3522734':{'de': 'Rammeldingen/Senningerberg', 'en': 'Rameldange/Senningerberg', 'fr': 'Rameldange/Senningerberg'}, '3522737':{'de': 'Leudelingen/Ehlingen/Monnerich', 'en': 'Leudelange/Ehlange/Mondercange', 'fr': 'Leudelange/Ehlange/Mondercange'}, '3522736':{'de': 'Hesperingen/Kockelscheuer/Roeser', 'en': 'Hesperange/Kockelscheuer/Roeser', 'fr': 'Hesperange/Kockelscheuer/Roeser'}, '3522731':{'de': 'Bartringen', 'en': 'Bertrange', 'fr': 'Bertrange'}, '3522730':{'de': 'Kanton Capellen/Kehlen', 'en': 'Capellen/Kehlen', 'fr': 'Capellen/Kehlen'}, '3522733':{'de': 'Walferdingen', 'en': 'Walferdange', 'fr': 'Walferdange'}, '3522732':{'de': 'Lintgen/Kanton Mersch/Steinfort', 'en': 'Lintgen/Mersch/Steinfort', 'fr': 'Lintgen/Mersch/Steinfort'}, '3349913':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3522739':{'de': 'Windhof/Steinfort', 'en': 'Windhof/Steinfort', 'fr': 'Windhof/Steinfort'}, '35937422':{'bg': u('\u0414\u043e\u043b\u043d\u0438 \u0413\u043b\u0430\u0432\u0430\u043d\u0430\u043a'), 'en': 'Dolni Glavanak'}, '35937421':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u043f\u043e\u043b\u0435'), 'en': 'Dolno pole'}, '35937420':{'bg': u('\u041f\u043e\u0434\u043a\u0440\u0435\u043f\u0430'), 'en': 'Podkrepa'}, '441368':{'en': 'Dunbar'}, '441369':{'en': 'Dunoon'}, '441364':{'en': 'Ashburton'}, '441366':{'en': 'Downham Market'}, '441367':{'en': 'Faringdon'}, '441360':{'en': 'Killearn'}, '441361':{'en': 'Duns'}, '441362':{'en': 'Dereham'}, '441363':{'en': 'Crediton'}, '3338792':{'en': 'Saint-Avold', 'fr': 'Saint-Avold'}, '3338793':{'en': 'Creutzwald', 'fr': 'Creutzwald'}, '3338822':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338791':{'en': 'Saint-Avold', 'fr': 'Saint-Avold'}, '3338796':{'en': 'Bitche', 'fr': 'Bitche'}, '3338797':{'en': 'Sarralbe', 'fr': 'Sarralbe'}, '3338794':{'en': 'Faulquemont', 'fr': 'Faulquemont'}, '3338795':{'en': 'Sarreguemines', 'fr': 'Sarreguemines'}, '3338828':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338829':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338798':{'en': 'Sarreguemines', 'fr': 'Sarreguemines'}, '3323138':{'en': 'Caen', 'fr': 'Caen'}, '437619':{'de': 'Kirchham', 'en': 'Kirchham'}, '3323130':{'en': 'Caen', 'fr': 'Caen'}, '3323131':{'en': 'Lisieux', 'fr': 'Lisieux'}, '3323137':{'en': 'Courseulles-sur-Mer', 'fr': 'Courseulles-sur-Mer'}, '3323134':{'en': 'Caen', 'fr': 'Caen'}, '3323135':{'en': 'Mondeville', 'fr': 'Mondeville'}, '432289':{'de': 'Matzen', 'en': 'Matzen'}, '432288':{'de': 'Auersthal', 'en': 'Auersthal'}, '432283':{'de': 'Angern an der March', 'en': 'Angern an der March'}, '432282':{'de': u('G\u00e4nserndorf'), 'en': u('G\u00e4nserndorf')}, '432285':{'de': 'Marchegg', 'en': 'Marchegg'}, '432284':{'de': 'Oberweiden', 'en': 'Oberweiden'}, '432287':{'de': 'Strasshof an der Nordbahn', 'en': 'Strasshof an der Nordbahn'}, '432286':{'de': 'Obersiebenbrunn', 'en': 'Obersiebenbrunn'}, '437614':{'de': 'Vorchdorf', 'en': 'Vorchdorf'}, '3323394':{'en': 'Cherbourg-Octeville', 'fr': 'Cherbourg-Octeville'}, '3323395':{'en': 'Valognes', 'fr': 'Valognes'}, '3323393':{'en': 'Cherbourg-Octeville', 'fr': 'Cherbourg-Octeville'}, '3323390':{'en': 'Granville', 'fr': 'Granville'}, '3323391':{'en': 'Granville', 'fr': 'Granville'}, '3355308':{'en': u('P\u00e9rigueux'), 'fr': u('P\u00e9rigueux')}, '3355309':{'en': u('P\u00e9rigueux'), 'fr': u('P\u00e9rigueux')}, '3346970':{'en': 'Lyon', 'fr': 'Lyon'}, '437612':{'de': 'Gmunden', 'en': 'Gmunden'}, '441942':{'en': 'Wigan'}, '441943':{'en': 'Guiseley'}, '441944':{'en': 'West Heslerton'}, '441945':{'en': 'Wisbech'}, '441947':{'en': 'Whitby'}, '441948':{'en': 'Whitchurch'}, '441949':{'en': 'Whatton'}, '433857':{'de': u('Neuberg an der M\u00fcrz'), 'en': u('Neuberg an der M\u00fcrz')}, '35930517':{'bg': u('\u0417\u0430\u0431\u044a\u0440\u0434\u043e'), 'en': 'Zabardo'}, '3332530':{'en': 'Chaumont', 'fr': 'Chaumont'}, '432756':{'de': 'Sankt Leonhard am Forst', 'en': 'St. Leonhard am Forst'}, '3332532':{'en': 'Chaumont', 'fr': 'Chaumont'}, '37428494':{'am': u('\u053d\u0576\u0571\u0578\u0580\u0565\u057d\u056f'), 'en': 'Khndzoresk', 'ru': u('\u0425\u043d\u0434\u0437\u043e\u0440\u0435\u0441\u043a')}, '432753':{'de': 'Gansbach', 'en': 'Gansbach'}, '3332535':{'en': 'Chaumont', 'fr': 'Chaumont'}, '37428491':{'am': u('\u0540\u0561\u0580\u056a\u056b\u057d'), 'en': 'Harzhis', 'ru': u('\u0410\u0440\u0436\u0438\u0441')}, '3332539':{'en': 'Nogent-sur-Seine', 'fr': 'Nogent-sur-Seine'}, '37428499':{'am': u('\u053f\u0578\u057c\u0576\u056b\u0571\u0578\u0580'), 'en': 'Kornidzor', 'ru': u('\u041a\u043e\u0440\u043d\u0438\u0434\u0437\u043e\u0440')}, '390586':{'en': 'Livorno', 'it': 'Livorno'}, '46243':{'en': u('Borl\u00e4nge'), 'sv': u('Borl\u00e4nge')}, '4412291':{'en': 'Barrow-in-Furness/Millom'}, '4412290':{'en': 'Barrow-in-Furness/Millom'}, '4412293':{'en': 'Millom'}, '4412292':{'en': 'Barrow-in-Furness'}, '4412295':{'en': 'Barrow-in-Furness'}, '4412294':{'en': 'Barrow-in-Furness'}, '4412297':{'en': 'Millom'}, '4412296':{'en': 'Barrow-in-Furness'}, '4412299':{'en': 'Millom'}, '4412298':{'en': 'Barrow-in-Furness'}, '3593762':{'bg': u('\u0418\u0437\u0432\u043e\u0440\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Izvorovo, Hask.'}, '3593763':{'bg': u('\u0411\u044a\u043b\u0433\u0430\u0440\u0438\u043d'), 'en': 'Balgarin'}, '3593766':{'bg': u('\u0411\u0438\u0441\u0435\u0440'), 'en': 'Biser'}, '3593767':{'bg': u('\u0411\u0440\u0430\u043d\u0438\u0446\u0430'), 'en': 'Branitsa'}, '3593764':{'bg': u('\u041f\u043e\u043b\u044f\u043d\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Polyanovo, Hask.'}, '3593765':{'bg': u('\u0418\u0432\u0430\u043d\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Ivanovo, Hask.'}, '3593768':{'bg': u('\u0414\u043e\u0441\u0438\u0442\u0435\u0435\u0432\u043e'), 'en': 'Dositeevo'}, '3593769':{'bg': u('\u041e\u0440\u0435\u0448\u0435\u0446, \u0425\u0430\u0441\u043a.'), 'en': 'Oreshets, Hask.'}, '359722':{'bg': u('\u0421\u0430\u043c\u043e\u043a\u043e\u0432'), 'en': 'Samokov'}, '434842':{'de': 'Sillian', 'en': 'Sillian'}, '433884':{'de': 'Wegscheid', 'en': 'Wegscheid'}, '433885':{'de': 'Greith', 'en': 'Greith'}, '433886':{'de': 'Weichselboden', 'en': 'Weichselboden'}, '433882':{'de': 'Mariazell', 'en': 'Mariazell'}, '3353305':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3332151':{'en': 'Arras', 'fr': 'Arras'}, '433619':{'de': 'Oppenberg', 'en': 'Oppenberg'}, '441562':{'en': 'Kidderminster'}, '441563':{'en': 'Kilmarnock'}, '441560':{'en': 'Moscow'}, '441561':{'en': 'Laurencekirk'}, '441566':{'en': 'Launceston'}, '441567':{'en': 'Killin'}, '441564':{'en': 'Lapworth'}, '441565':{'en': 'Knutsford'}, '441568':{'en': 'Leominster'}, '441569':{'en': 'Stonehaven'}, '355597':{'en': u('Kodovjat/Poro\u00e7an/Kukur/Lenie, Gramsh')}, '355596':{'en': u('Pishaj/Sult/Tunj\u00eb/Kushov\u00eb/Sk\u00ebnderbegas, Gramsh')}, '355595':{'en': u('Quk\u00ebs/Rajc\u00eb, Librazhd')}, '355594':{'en': 'Hotolisht/Polis/Stravaj, Librazhd'}, '355593':{'en': u('Lunik/Orenj\u00eb/Stebleve, Librazhd')}, '355592':{'en': u('Qend\u00ebr, Librazhd')}, '355591':{'en': u('P\u00ebrrenjas, Librazhd')}, '437945':{'de': 'Sankt Oswald bei Freistadt', 'en': 'St. Oswald bei Freistadt'}, '437944':{'de': 'Sandl', 'en': 'Sandl'}, '437947':{'de': 'Kefermarkt', 'en': 'Kefermarkt'}, '437946':{'de': 'Gutau', 'en': 'Gutau'}, '3596909':{'bg': u('\u041c\u0430\u043b\u043a\u0430 \u0416\u0435\u043b\u044f\u0437\u043d\u0430'), 'en': 'Malka Zhelyazna'}, '3596908':{'bg': u('\u0413\u043b\u043e\u0433\u043e\u0432\u043e'), 'en': 'Glogovo'}, '437943':{'de': 'Windhaag bei Freistadt', 'en': 'Windhaag bei Freistadt'}, '437942':{'de': 'Freistadt', 'en': 'Freistadt'}, '3596905':{'bg': u('\u0414\u0438\u0432\u0447\u043e\u0432\u043e\u0442\u043e'), 'en': 'Divchovoto'}, '3596907':{'bg': u('\u0413\u0440\u0430\u0434\u0435\u0436\u043d\u0438\u0446\u0430'), 'en': 'Gradezhnitsa'}, '3596906':{'bg': u('\u0427\u0435\u0440\u043d\u0438 \u0412\u0438\u0442'), 'en': 'Cherni Vit'}, '3596901':{'bg': u('\u0413\u043b\u043e\u0436\u0435\u043d\u0435, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Glozhene, Lovech'}, '3596900':{'bg': u('\u0412\u0430\u0441\u0438\u043b\u044c\u043e\u0432\u043e'), 'en': 'Vasilyovo'}, '3596902':{'bg': u('\u0420\u0438\u0431\u0430\u0440\u0438\u0446\u0430, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Ribaritsa, Lovech'}, '35938':{'bg': u('\u0425\u0430\u0441\u043a\u043e\u0432\u043e'), 'en': 'Haskovo'}, '35932':{'bg': u('\u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Plovdiv'}, '35934':{'bg': u('\u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Pazardzhik'}, '3324072':{'en': 'Nort-sur-Erdre', 'fr': 'Nort-sur-Erdre'}, '3324073':{'en': 'Nantes', 'fr': 'Nantes'}, '3324070':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '3324071':{'en': 'Nantes', 'fr': 'Nantes'}, '3324076':{'en': 'Nantes', 'fr': 'Nantes'}, '3324077':{'en': u('Suc\u00e9-sur-Erdre'), 'fr': u('Suc\u00e9-sur-Erdre')}, '3324074':{'en': 'Nantes', 'fr': 'Nantes'}, '3324075':{'en': u('Rez\u00e9'), 'fr': u('Rez\u00e9')}, '3324078':{'en': 'Saint-Philbert-de-Grand-Lieu', 'fr': 'Saint-Philbert-de-Grand-Lieu'}, '3324079':{'en': 'Blain', 'fr': 'Blain'}, '354462':{'en': 'Akureyri'}, '43463':{'de': 'Klagenfurt', 'en': 'Klagenfurt'}, '3329919':{'en': 'Saint-Malo', 'fr': 'Saint-Malo'}, '3347615':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347342':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3347617':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347340':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3347611':{'en': 'Le Bourg d\'Oisans', 'fr': 'Le Bourg d\'Oisans'}, '3347344':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3596022':{'bg': u('\u041f\u0440\u043e\u0431\u0443\u0434\u0430, \u0422\u044a\u0440\u0433.'), 'en': 'Probuda, Targ.'}, '3347618':{'en': 'Meylan', 'fr': 'Meylan'}, '3596023':{'bg': u('\u041f\u043e\u0434\u0433\u043e\u0440\u0438\u0446\u0430'), 'en': 'Podgoritsa'}, '3329951':{'en': 'Rennes', 'fr': 'Rennes'}, '3596021':{'bg': u('\u0411\u0443\u0445\u043e\u0432\u0446\u0438'), 'en': 'Buhovtsi'}, '3329957':{'en': 'Guichen', 'fr': 'Guichen'}, '3346757':{'en': 'Gignac', 'fr': 'Gignac'}, '3323898':{'en': 'Montargis', 'fr': 'Montargis'}, '4626':{'en': u('G\u00e4vle-Sandviken'), 'sv': u('G\u00e4vle-Sandviken')}, '3346756':{'en': 'La Grande Motte', 'fr': 'La Grande Motte'}, '3323895':{'en': u('Ch\u00e2teau-Renard'), 'fr': u('Ch\u00e2teau-Renard')}, '3323897':{'en': 'Courtenay', 'fr': 'Courtenay'}, '3323896':{'en': u('Ferri\u00e8res-en-G\u00e2tinais'), 'fr': u('Ferri\u00e8res-en-G\u00e2tinais')}, '3323891':{'en': 'Neuville-aux-Bois', 'fr': 'Neuville-aux-Bois'}, '3323890':{'en': 'Bellegarde', 'fr': 'Bellegarde'}, '3323893':{'en': 'Montargis', 'fr': 'Montargis'}, '3323892':{'en': 'Dordives', 'fr': 'Dordives'}, '3346754':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346753':{'en': u('S\u00e8te'), 'fr': u('S\u00e8te')}, '3346752':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346751':{'en': u('S\u00e8te'), 'fr': u('S\u00e8te')}, '3346750':{'en': u('P\u00e9rols'), 'fr': u('P\u00e9rols')}, '3323096':{'en': 'Rennes', 'fr': 'Rennes'}, '390766':{'it': 'Civitavecchia'}, '3347964':{'en': 'Saint-Jean-de-Maurienne', 'fr': 'Saint-Jean-de-Maurienne'}, '3347962':{'en': u('Chamb\u00e9ry'), 'fr': u('Chamb\u00e9ry')}, '3347961':{'en': 'Aix-les-Bains', 'fr': 'Aix-les-Bains'}, '3347960':{'en': u('Chamb\u00e9ry'), 'fr': u('Chamb\u00e9ry')}, '3347969':{'en': u('Chamb\u00e9ry'), 'fr': u('Chamb\u00e9ry')}, '3347968':{'en': u('Chamb\u00e9ry'), 'fr': u('Chamb\u00e9ry')}, '3329640':{'en': 'Guingamp', 'fr': 'Guingamp'}, '3329641':{'en': 'Saint-Cast-le-Guildo', 'fr': 'Saint-Cast-le-Guildo'}, '3329646':{'en': 'Lannion', 'fr': 'Lannion'}, '3329647':{'en': 'Ploubezre', 'fr': 'Ploubezre'}, '3329644':{'en': 'Guingamp', 'fr': 'Guingamp'}, '3329645':{'en': u('B\u00e9gard'), 'fr': u('B\u00e9gard')}, '3329648':{'en': 'Lannion', 'fr': 'Lannion'}, '3329649':{'en': 'Perros-Guirec', 'fr': 'Perros-Guirec'}, '3323271':{'en': 'Vernon', 'fr': 'Vernon'}, '3323270':{'en': 'Yvetot', 'fr': 'Yvetot'}, '3323274':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323277':{'en': 'Gaillon', 'fr': 'Gaillon'}, '3323276':{'en': 'Rouen', 'fr': 'Rouen'}, '3323279':{'en': 'Montivilliers', 'fr': 'Montivilliers'}, '3351685':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '390985':{'it': 'Scalea'}, '390984':{'it': 'Cosenza'}, '390983':{'it': 'Rossano'}, '390982':{'it': 'Paola'}, '390981':{'it': 'Castrovillari'}, '3358274':{'en': 'Toulouse', 'fr': 'Toulouse'}, '42158':{'en': u('Ro\u017e\u0148ava')}, '42151':{'en': u('Pre\u0161ov')}, '42153':{'en': u('Spi\u0161sk\u00e1 Nov\u00e1 Ves')}, '42152':{'en': 'Poprad'}, '42155':{'en': u('Ko\u0161ice')}, '42154':{'en': 'Bardejov'}, '42157':{'en': u('Humenn\u00e9')}, '42156':{'en': 'Michalovce'}, '390187':{'en': 'La Spezia', 'it': 'La Spezia'}, '390185':{'en': 'Genoa', 'it': 'Rapallo'}, '390184':{'it': 'Sanremo'}, '390183':{'en': 'Imperia', 'it': 'Imperia'}, '390182':{'it': 'Albenga'}, '390174':{'it': u('Mondov\u00ec')}, '3345069':{'en': 'Seynod', 'fr': 'Seynod'}, '3345062':{'en': u('Valli\u00e8res'), 'fr': u('Valli\u00e8res')}, '3345064':{'en': 'Rumilly', 'fr': 'Rumilly'}, '3345065':{'en': 'Annecy', 'fr': 'Annecy'}, '3345066':{'en': 'Annecy', 'fr': 'Annecy'}, '3345067':{'en': 'Annecy', 'fr': 'Annecy'}, '3317430':{'en': 'Paris', 'fr': 'Paris'}, '3338587':{'en': 'Chagny', 'fr': 'Chagny'}, '3338586':{'en': 'Autun', 'fr': 'Autun'}, '3338585':{'en': 'Gueugnon', 'fr': 'Gueugnon'}, '3338581':{'en': 'Paray-le-Monial', 'fr': 'Paray-le-Monial'}, '3338580':{'en': 'Le Creusot', 'fr': 'Le Creusot'}, '3338589':{'en': 'Bourbon-Lancy', 'fr': 'Bourbon-Lancy'}, '3338588':{'en': 'Digoin', 'fr': 'Digoin'}, '3332277':{'en': 'Doullens', 'fr': 'Doullens'}, '3332275':{'en': 'Albert', 'fr': 'Albert'}, '3332274':{'en': 'Albert', 'fr': 'Albert'}, '3332272':{'en': 'Amiens', 'fr': 'Amiens'}, '3332271':{'en': 'Amiens', 'fr': 'Amiens'}, '3332270':{'en': 'Rivery', 'fr': 'Rivery'}, '3347145':{'en': 'Aurillac', 'fr': 'Aurillac'}, '3332278':{'en': 'Montdidier', 'fr': 'Montdidier'}, '437718':{'de': 'Waldkirchen am Wesen', 'en': 'Waldkirchen am Wesen'}, '437719':{'de': 'Taufkirchen an der Pram', 'en': 'Taufkirchen an der Pram'}, '437711':{'de': 'Suben', 'en': 'Suben'}, '437712':{'de': u('Sch\u00e4rding'), 'en': u('Sch\u00e4rding')}, '437713':{'de': 'Schardenberg', 'en': 'Schardenberg'}, '437714':{'de': 'Esternberg', 'en': 'Esternberg'}, '437716':{'de': u('M\u00fcnzkirchen'), 'en': u('M\u00fcnzkirchen')}, '437717':{'de': 'Sankt Aegidi', 'en': 'St. Aegidi'}, '37166':{'en': 'Riga'}, '37167':{'en': 'Riga'}, '3352460':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3352461':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '37424297':{'am': u('\u0531\u0576\u056b \u053f\u0561\u0575\u0561\u0580\u0561\u0576'), 'en': 'Ani Kayaran', 'ru': u('\u0410\u043d\u0438 \u041a\u0430\u044f\u0440\u0430\u043d')}, '3356363':{'en': 'Montauban', 'fr': 'Montauban'}, '3356362':{'en': 'Castres', 'fr': 'Castres'}, '3356361':{'en': 'Mazamet', 'fr': 'Mazamet'}, '3356360':{'en': 'Albi', 'fr': 'Albi'}, '3356366':{'en': 'Montauban', 'fr': 'Montauban'}, '3347428':{'en': 'Bourgoin-Jallieu', 'fr': 'Bourgoin-Jallieu'}, '3347429':{'en': 'Roussillon', 'fr': 'Roussillon'}, '3347422':{'en': 'Bourg-en-Bresse', 'fr': 'Bourg-en-Bresse'}, '3347423':{'en': 'Bourg-en-Bresse', 'fr': 'Bourg-en-Bresse'}, '3347420':{'en': u('La C\u00f4te Saint Andr\u00e9'), 'fr': u('La C\u00f4te Saint Andr\u00e9')}, '3347421':{'en': 'Bourg-en-Bresse', 'fr': 'Bourg-en-Bresse'}, '3347427':{'en': 'L\'Isle d\'Abeau', 'fr': 'L\'Isle d\'Abeau'}, '3347424':{'en': 'Bourg-en-Bresse', 'fr': 'Bourg-en-Bresse'}, '3347425':{'en': 'Viriat', 'fr': 'Viriat'}, '3598192':{'bg': u('\u0425\u043e\u0442\u0430\u043d\u0446\u0430'), 'en': 'Hotantsa'}, '3598194':{'bg': u('\u0421\u0430\u043d\u0434\u0440\u043e\u0432\u043e'), 'en': 'Sandrovo'}, '333839':{'en': 'Nancy', 'fr': 'Nancy'}, '3598196':{'bg': u('\u041d\u0438\u0441\u043e\u0432\u043e'), 'en': 'Nisovo'}, '333835':{'en': u('Vand\u0153uvre-l\u00e8s-Nancy'), 'fr': u('Vand\u0153uvre-l\u00e8s-Nancy')}, '432949':{'de': 'Niederfladnitz', 'en': 'Niederfladnitz'}, '3329888':{'en': 'Morlaix', 'fr': 'Morlaix'}, '35937424':{'bg': u('\u041a\u043e\u0437\u043b\u0435\u0446'), 'en': 'Kozlets'}, '35937423':{'bg': u('\u0413\u043e\u043b\u0435\u043c\u0430\u043d\u0446\u0438'), 'en': 'Golemantsi'}, '3347288':{'en': 'Beynost', 'fr': 'Beynost'}, '3347289':{'en': u('V\u00e9nissieux'), 'fr': u('V\u00e9nissieux')}, '3347284':{'en': 'Lyon', 'fr': 'Lyon'}, '3347285':{'en': 'Lyon', 'fr': 'Lyon'}, '3347282':{'en': 'Villeurbanne', 'fr': 'Villeurbanne'}, '3347283':{'en': 'Lyon', 'fr': 'Lyon'}, '3347280':{'en': 'Lyon', 'fr': 'Lyon'}, '3347281':{'en': 'Bron', 'fr': 'Bron'}, '3316446':{'en': 'Orsay', 'fr': 'Orsay'}, '3316447':{'en': 'Massy', 'fr': 'Massy'}, '3316445':{'en': 'Montigny-sur-Loing', 'fr': 'Montigny-sur-Loing'}, '3316443':{'en': 'Pontault-Combault', 'fr': 'Pontault-Combault'}, '3316440':{'en': u('Ozoir-la-Ferri\u00e8re'), 'fr': u('Ozoir-la-Ferri\u00e8re')}, '3316441':{'en': 'Savigny-le-Temple', 'fr': 'Savigny-le-Temple'}, '3316448':{'en': 'Longjumeau', 'fr': 'Longjumeau'}, '3316449':{'en': 'Marcoussis', 'fr': 'Marcoussis'}, '3346779':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3329880':{'en': 'Brest', 'fr': 'Brest'}, '3596042':{'bg': u('\u0418\u043b\u0438\u0439\u043d\u043e'), 'en': 'Iliyno'}, '3596043':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u041d\u043e\u0432\u043a\u043e\u0432\u043e'), 'en': 'Dolno Novkovo'}, '3596044':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u041a\u043e\u0437\u0430\u0440\u0435\u0432\u043e'), 'en': 'Dolno Kozarevo'}, '3596046':{'bg': u('\u0412\u0440\u0430\u043d\u0438 \u043a\u043e\u043d'), 'en': 'Vrani kon'}, '3329881':{'en': u('Ch\u00e2teauneuf-du-Faou'), 'fr': u('Ch\u00e2teauneuf-du-Faou')}, '3346771':{'en': 'Lunel', 'fr': 'Lunel'}, '3596049':{'bg': u('\u041a\u0430\u043c\u0431\u0443\u0440\u043e\u0432\u043e'), 'en': 'Kamburovo'}, '3346773':{'en': 'Ganges', 'fr': 'Ganges'}, '3346772':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346775':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346774':{'en': u('S\u00e8te'), 'fr': u('S\u00e8te')}, '3346777':{'en': 'Marseillan', 'fr': 'Marseillan'}, '3346776':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3329883':{'en': 'Lesneven', 'fr': 'Lesneven'}, '3329884':{'en': 'Guipavas', 'fr': 'Guipavas'}, '34920':{'en': u('\u00c1vila'), 'es': u('\u00c1vila')}, '3329886':{'en': 'Chateaulin', 'fr': 'Chateaulin'}, '436548':{'de': 'Niedernsill', 'en': 'Niedernsill'}, '436549':{'de': 'Piesendorf', 'en': 'Piesendorf'}, '436546':{'de': u('Fusch an der Gro\u00dfglocknerstra\u00dfe'), 'en': 'Fusch an der Grossglocknerstrasse'}, '436547':{'de': 'Kaprun', 'en': 'Kaprun'}, '436544':{'de': 'Rauris', 'en': 'Rauris'}, '3329887':{'en': u('Pont-l\'Abb\u00e9'), 'fr': u('Pont-l\'Abb\u00e9')}, '436542':{'de': 'Zell am See', 'en': 'Zell am See'}, '436543':{'de': 'Taxenbach', 'en': 'Taxenbach'}, '436541':{'de': 'Saalbach', 'en': 'Saalbach'}, '3338618':{'en': 'Auxerre', 'fr': 'Auxerre'}, '3338820':{'en': 'Souffelweyersheim', 'fr': 'Souffelweyersheim'}, '3338821':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338823':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '333225':{'en': 'Amiens', 'fr': 'Amiens'}, '3338824':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338825':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338808':{'en': 'Barr', 'fr': 'Barr'}, '3338809':{'en': 'Niederbronn-les-Bains', 'fr': 'Niederbronn-les-Bains'}, '3338778':{'en': 'Bouzonville', 'fr': 'Bouzonville'}, '3338779':{'en': 'Boulay-Moselle', 'fr': 'Boulay-Moselle'}, '3338802':{'en': 'Saverne', 'fr': 'Saverne'}, '3338803':{'en': 'Saverne', 'fr': 'Saverne'}, '3338776':{'en': 'Metz', 'fr': 'Metz'}, '3338777':{'en': 'Vigy', 'fr': 'Vigy'}, '3338806':{'en': 'Haguenau', 'fr': 'Haguenau'}, '3338771':{'en': 'Hagondange', 'fr': 'Hagondange'}, '3338772':{'en': 'Hagondange', 'fr': 'Hagondange'}, '3338805':{'en': 'Haguenau', 'fr': 'Haguenau'}, '35947201':{'bg': u('\u0418\u0437\u0433\u0440\u0435\u0432, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Izgrev, Yambol'}, '35947202':{'bg': u('\u0416\u0440\u0435\u0431\u0438\u043d\u043e'), 'en': 'Zhrebino'}, '35947203':{'bg': u('\u0422\u0440\u044a\u043d\u043a\u043e\u0432\u043e, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Trankovo, Yambol'}, '35947204':{'bg': u('\u041f\u0447\u0435\u043b\u0430'), 'en': 'Pchela'}, '3354639':{'en': 'Royan', 'fr': 'Royan'}, '3354638':{'en': 'Royan', 'fr': 'Royan'}, '3354637':{'en': 'Nieul-sur-Mer', 'fr': 'Nieul-sur-Mer'}, '3354636':{'en': 'La Tremblade', 'fr': 'La Tremblade'}, '331835':{'en': 'Paris', 'fr': 'Paris'}, '3354632':{'en': u('Saint-Jean-d\'Ang\u00e9ly'), 'fr': u('Saint-Jean-d\'Ang\u00e9ly')}, '3354631':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3354630':{'en': u('Sainte-Marie-de-R\u00e9'), 'fr': u('Sainte-Marie-de-R\u00e9')}, '3531':{'en': 'Dublin'}, '331838':{'en': 'Paris', 'fr': 'Paris'}, '331839':{'en': 'Paris', 'fr': 'Paris'}, '3355323':{'en': 'Eymet', 'fr': 'Eymet'}, '3355320':{'en': 'Marmande', 'fr': 'Marmande'}, '3355327':{'en': 'Bergerac', 'fr': 'Bergerac'}, '3349281':{'en': 'Barcelonnette', 'fr': 'Barcelonnette'}, '3349283':{'en': 'Castellane', 'fr': 'Castellane'}, '3349284':{'en': 'Pra-Loup', 'fr': 'Pra-Loup'}, '3349285':{'en': u('La Br\u00e9ole'), 'fr': u('La Br\u00e9ole')}, '3349287':{'en': 'Manosque', 'fr': 'Manosque'}, '390864':{'it': 'Sulmona'}, '3349289':{'en': u('Saint-Andr\u00e9-les-Alpes'), 'fr': u('Saint-Andr\u00e9-les-Alpes')}, '390861':{'it': 'Teramo'}, '390862':{'en': 'L\'Aquila', 'it': 'L\'Aquila'}, '390863':{'it': 'Avezzano'}, '3354989':{'en': 'Vivonne', 'fr': 'Vivonne'}, '3354988':{'en': 'Poitiers', 'fr': 'Poitiers'}, '441928':{'en': 'Runcorn'}, '441929':{'en': 'Wareham'}, '3354981':{'en': u('Maul\u00e9on'), 'fr': u('Maul\u00e9on')}, '3354980':{'en': 'Cerizay', 'fr': 'Cerizay'}, '3354983':{'en': 'Montmorillon', 'fr': 'Montmorillon'}, '3354982':{'en': 'Bressuire', 'fr': 'Bressuire'}, '3354985':{'en': u('Ch\u00e2tellerault'), 'fr': u('Ch\u00e2tellerault')}, '441924':{'en': 'Wakefield'}, '441925':{'en': 'Warrington'}, '371645':{'en': 'Balvi'}, '371644':{'en': 'Gulbene'}, '371647':{'en': 'Valka'}, '371646':{'en': u('R\u0113zekne')}, '371641':{'en': u('C\u0113sis')}, '371640':{'en': u('Limba\u017ei')}, '371643':{'en': u('Al\u016bksne')}, '371642':{'en': 'Valmiera'}, '371649':{'en': 'Aizkraukle'}, '371648':{'en': 'Madona'}, '3593561':{'bg': u('\u0421\u0435\u043f\u0442\u0435\u043c\u0432\u0440\u0438'), 'en': 'Septemvri'}, '3593562':{'bg': u('\u0421\u043b\u0430\u0432\u043e\u0432\u0438\u0446\u0430, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Slavovitsa, Pazardzhik'}, '3593563':{'bg': u('\u0412\u0430\u0440\u0432\u0430\u0440\u0430, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Varvara, Pazardzhik'}, '3593564':{'bg': u('\u0421\u0435\u043c\u0447\u0438\u043d\u043e\u0432\u043e'), 'en': 'Semchinovo'}, '3593566':{'bg': u('\u0411\u043e\u0448\u0443\u043b\u044f'), 'en': 'Boshulya'}, '3593567':{'bg': u('\u041a\u043e\u0432\u0430\u0447\u0435\u0432\u043e, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Kovachevo, Pazardzhik'}, '3593568':{'bg': u('\u0412\u0438\u043d\u043e\u0433\u0440\u0430\u0434\u0435\u0446'), 'en': 'Vinogradets'}, '3593569':{'bg': u('\u041a\u0430\u0440\u0430\u0431\u0443\u043d\u0430\u0440'), 'en': 'Karabunar'}, '3346710':{'en': 'Montpellier', 'fr': 'Montpellier'}, '432731':{'de': 'Idolsberg', 'en': 'Idolsberg'}, '432733':{'de': u('Sch\u00f6nberg am Kamp'), 'en': u('Sch\u00f6nberg am Kamp')}, '432732':{'de': 'Krems an der Donau', 'en': 'Krems an der Donau'}, '3332048':{'en': 'Nieppe', 'fr': 'Nieppe'}, '3332049':{'en': 'Lille', 'fr': 'Lille'}, '432736':{'de': 'Paudorf', 'en': 'Paudorf'}, '432739':{'de': 'Tiefenfucha', 'en': 'Tiefenfucha'}, '3332045':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332047':{'en': 'Villeneuve-d\'Ascq', 'fr': 'Villeneuve-d\'Ascq'}, '3332040':{'en': 'Lille', 'fr': 'Lille'}, '3332041':{'en': 'Villeneuve-d\'Ascq', 'fr': 'Villeneuve-d\'Ascq'}, '3332042':{'en': 'Lille', 'fr': 'Lille'}, '3332043':{'en': 'Villeneuve-d\'Ascq', 'fr': 'Villeneuve-d\'Ascq'}, '3323514':{'en': 'Rouen', 'fr': 'Rouen'}, '3323515':{'en': 'Rouen', 'fr': 'Rouen'}, '3323510':{'en': u('F\u00e9camp'), 'fr': u('F\u00e9camp')}, '3323512':{'en': 'Mont-Saint-Aignan', 'fr': 'Mont-Saint-Aignan'}, '3355589':{'en': 'Dun-le-Palestel', 'fr': 'Dun-le-Palestel'}, '3355586':{'en': 'Brive-la-Gaillarde', 'fr': 'Brive-la-Gaillarde'}, '3355587':{'en': 'Brive-la-Gaillarde', 'fr': 'Brive-la-Gaillarde'}, '3355584':{'en': 'Allassac', 'fr': 'Allassac'}, '3329923':{'en': u('Saint-Gr\u00e9goire'), 'fr': u('Saint-Gr\u00e9goire')}, '3323519':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3329921':{'en': 'Saint-Malo', 'fr': 'Saint-Malo'}, '3329920':{'en': 'Saint-Malo', 'fr': 'Saint-Malo'}, '3349424':{'en': 'Toulon', 'fr': 'Toulon'}, '3349425':{'en': 'Six-Fours-les-Plages', 'fr': 'Six-Fours-les-Plages'}, '3349426':{'en': 'Saint-Cyr-sur-Mer', 'fr': 'Saint-Cyr-sur-Mer'}, '3349427':{'en': 'Toulon', 'fr': 'Toulon'}, '3349420':{'en': 'Toulon', 'fr': 'Toulon'}, '3349421':{'en': 'La Garde', 'fr': 'La Garde'}, '3349422':{'en': 'Toulon', 'fr': 'Toulon'}, '3349423':{'en': 'Toulon', 'fr': 'Toulon'}, '3593784':{'bg': u('\u041a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u0438\u043d\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Konstantinovo, Hask.'}, '3593785':{'bg': u('\u0414\u0440\u044f\u043d\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Dryanovo, Hask.'}, '3593786':{'bg': u('\u041d\u0430\u0432\u044a\u0441\u0435\u043d'), 'en': 'Navasen'}, '3593787':{'bg': u('\u0422\u044f\u043d\u0435\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Tyanevo, Hask.'}, '3349428':{'en': 'Cuers', 'fr': 'Cuers'}, '3349429':{'en': 'Bandol', 'fr': 'Bandol'}, '3593782':{'bg': u('\u041a\u0430\u043b\u0443\u0433\u0435\u0440\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Kalugerovo, Hask.'}, '3593783':{'bg': u('\u0421\u0432\u0438\u0440\u043a\u043e\u0432\u043e'), 'en': 'Svirkovo'}, '44241':{'en': 'Coventry'}, '44247':{'en': 'Coventry'}, '441548':{'en': 'Kingsbridge'}, '441549':{'en': 'Lairg'}, '441544':{'en': 'Kington'}, '441545':{'en': 'Llanarth'}, '441546':{'en': 'Lochgilphead'}, '441547':{'en': 'Knighton'}, '441540':{'en': 'Kingussie'}, '441542':{'en': 'Keith'}, '441543':{'en': 'Cannock'}, '3324896':{'en': 'Saint-Amand-Montrond', 'fr': 'Saint-Amand-Montrond'}, '3599110':{'bg': u('\u0412\u0438\u0440\u043e\u0432\u0441\u043a\u043e'), 'en': 'Virovsko'}, '373263':{'en': 'Leova', 'ro': 'Leova', 'ru': u('\u041b\u0435\u043e\u0432\u0430')}, '373262':{'en': 'Singerei', 'ro': u('S\u00eengerei'), 'ru': u('\u0421\u044b\u043d\u0436\u0435\u0440\u0435\u0439')}, '373265':{'en': 'Anenii Noi', 'ro': 'Anenii Noi', 'ru': u('\u0410\u043d\u0435\u043d\u0438\u0439 \u041d\u043e\u0439')}, '373264':{'en': 'Nisporeni', 'ro': 'Nisporeni', 'ru': u('\u041d\u0438\u0441\u043f\u043e\u0440\u0435\u043d\u044c')}, '373269':{'en': 'Hincesti', 'ro': u('H\u00eence\u015fti'), 'ru': u('\u0425\u044b\u043d\u0447\u0435\u0448\u0442\u044c')}, '373268':{'en': 'Ialoveni', 'ro': 'Ialoveni', 'ru': u('\u042f\u043b\u043e\u0432\u0435\u043d\u044c')}, '3355302':{'en': u('P\u00e9rigueux'), 'fr': u('P\u00e9rigueux')}, '3324094':{'en': u('Treilli\u00e8res'), 'fr': u('Treilli\u00e8res')}, '3324095':{'en': 'Nantes', 'fr': 'Nantes'}, '3324096':{'en': 'Ancenis', 'fr': 'Ancenis'}, '435522':{'de': 'Feldkirch', 'en': 'Feldkirch'}, '3324090':{'en': 'Trignac', 'fr': 'Trignac'}, '3324091':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '3324092':{'en': 'Saint-Herblain', 'fr': 'Saint-Herblain'}, '3324093':{'en': 'Nantes', 'fr': 'Nantes'}, '3355306':{'en': u('P\u00e9rigueux'), 'fr': u('P\u00e9rigueux')}, '441467':{'en': 'Inverurie'}, '355311':{'en': u('Ku\u00e7ov\u00eb')}, '355313':{'en': u('Ballsh, Mallakast\u00ebr')}, '355312':{'en': u('\u00c7orovod\u00eb, Skrapar')}, '441465':{'en': 'Girvan'}, '3356272':{'en': 'Toulouse', 'fr': 'Toulouse'}, '441463':{'en': 'Inverness'}, '441461':{'en': 'Gretna'}, '441460':{'en': 'Chard'}, '3595784':{'bg': u('\u0412\u0440\u0430\u0447\u0430\u043d\u0446\u0438'), 'en': 'Vrachantsi'}, '3347369':{'en': 'Cournon-d\'Auvergne', 'fr': 'Cournon-d\'Auvergne'}, '3595783':{'bg': u('\u041a\u043e\u0442\u043b\u0435\u043d\u0446\u0438'), 'en': 'Kotlentsi'}, '3595781':{'bg': u('\u0421\u0432\u043e\u0431\u043e\u0434\u0430, \u0414\u043e\u0431\u0440.'), 'en': 'Svoboda, Dobr.'}, '3347365':{'en': 'Le Mont Dore', 'fr': 'Le Mont Dore'}, '3347364':{'en': 'Riom', 'fr': 'Riom'}, '3347367':{'en': 'Riom', 'fr': 'Riom'}, '3347361':{'en': 'Lempdes', 'fr': 'Lempdes'}, '3347360':{'en': 'Nohanent', 'fr': 'Nohanent'}, '3359095':{'en': 'Petit Bourg', 'fr': 'Petit Bourg'}, '3347362':{'en': 'Orcines', 'fr': 'Orcines'}, '3596527':{'bg': u('\u041e\u0434\u044a\u0440\u043d\u0435'), 'en': 'Odarne'}, '3596526':{'bg': u('\u0412\u044a\u0440\u0431\u0438\u0446\u0430, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Varbitsa, Pleven'}, '3596525':{'bg': u('\u0411\u044a\u0440\u043a\u0430\u0447'), 'en': 'Barkach'}, '3596524':{'bg': u('\u041f\u0435\u0442\u044a\u0440\u043d\u0438\u0446\u0430'), 'en': 'Petarnitsa'}, '3596523':{'bg': u('\u041a\u0440\u0443\u0448\u043e\u0432\u0438\u0446\u0430, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Krushovitsa, Pleven'}, '3596522':{'bg': u('\u0417\u0433\u0430\u043b\u0435\u0432\u043e'), 'en': 'Zgalevo'}, '3596521':{'bg': u('\u0421\u0430\u0434\u043e\u0432\u0435\u0446'), 'en': 'Sadovets'}, '3596520':{'bg': u('\u041d\u0438\u043a\u043e\u043b\u0430\u0435\u0432\u043e, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Nikolaevo, Pleven'}, '3596529':{'bg': u('\u041a\u043e\u0438\u043b\u043e\u0432\u0446\u0438'), 'en': 'Koilovtsi'}, '3596528':{'bg': u('\u0412\u044a\u043b\u0447\u0438\u0442\u0440\u044a\u043d'), 'en': 'Valchitran'}, '436229':{'de': 'Hof bei Salzburg', 'en': 'Hof bei Salzburg'}, '4414349':{'en': 'Bellingham'}, '4414348':{'en': 'Hexham'}, '4414345':{'en': 'Haltwhistle'}, '4414344':{'en': 'Bellingham'}, '4414347':{'en': 'Hexham'}, '4414346':{'en': 'Hexham'}, '4414341':{'en': 'Bellingham/Haltwhistle/Hexham'}, '4414340':{'en': 'Bellingham/Haltwhistle/Hexham'}, '4414343':{'en': 'Haltwhistle'}, '4414342':{'en': 'Bellingham'}, '359570':{'bg': u('\u041a\u0430\u0432\u0430\u0440\u043d\u0430'), 'en': 'Kavarna'}, '359579':{'bg': u('\u0410\u043b\u0431\u0435\u043d\u0430'), 'en': 'Albena'}, '35961203':{'bg': u('\u0415\u043c\u0435\u043d'), 'en': 'Emen'}, '3347941':{'en': u('Val-d\'Is\u00e8re'), 'fr': u('Val-d\'Is\u00e8re')}, '3343440':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3347942':{'en': 'Belley', 'fr': 'Belley'}, '3347944':{'en': u('Chamb\u00e9ry'), 'fr': u('Chamb\u00e9ry')}, '3597438':{'bg': u('\u041a\u0430\u0442\u0443\u043d\u0446\u0438'), 'en': 'Katuntsi'}, '3343443':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3597928':{'bg': u('\u0413\u044a\u0440\u043b\u044f\u043d\u043e'), 'en': 'Garlyano'}, '3597929':{'bg': u('\u0421\u043e\u0432\u043e\u043b\u044f\u043d\u043e'), 'en': 'Sovolyano'}, '3323218':{'en': 'Rouen', 'fr': 'Rouen'}, '390473':{'it': 'Merano'}, '390472':{'it': 'Bressanone'}, '390471':{'en': 'Bolzano/Bozen', 'it': 'Bolzano'}, '3323212':{'en': 'Rouen', 'fr': 'Rouen'}, '3323211':{'en': 'Le Grand Quevilly', 'fr': 'Le Grand Quevilly'}, '3323210':{'en': 'Rouen', 'fr': 'Rouen'}, '3323214':{'en': 'Dieppe', 'fr': 'Dieppe'}, '3597124':{'bg': u('\u0411\u0435\u043b\u0447\u0438\u043d\u0441\u043a\u0438 \u0431\u0430\u043d\u0438'), 'en': 'Belchinski bani'}, '3597125':{'bg': u('\u0413\u043e\u0432\u0435\u0434\u0430\u0440\u0446\u0438'), 'en': 'Govedartsi'}, '3597126':{'bg': u('\u0413\u043e\u0440\u043d\u0438 \u041e\u043a\u043e\u043b'), 'en': 'Gorni Okol'}, '3597127':{'bg': u('\u0428\u0438\u0440\u043e\u043a\u0438 \u0434\u043e\u043b'), 'en': 'Shiroki dol'}, '3597120':{'bg': u('\u0414\u043e\u043b\u043d\u0430 \u0431\u0430\u043d\u044f'), 'en': 'Dolna banya'}, '3597123':{'bg': u('\u041a\u043e\u0432\u0430\u0447\u0435\u0432\u0446\u0438, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Kovachevtsi, Sofia'}, '3597129':{'bg': u('\u0420\u0430\u0434\u0443\u0438\u043b'), 'en': 'Raduil'}, '3597436':{'bg': u('\u041b\u0435\u0432\u0443\u043d\u043e\u0432\u043e'), 'en': 'Levunovo'}, '3597437':{'bg': u('\u041c\u0435\u043b\u043d\u0438\u043a'), 'en': 'Melnik'}, '3342244':{'en': 'Toulon', 'fr': 'Toulon'}, '3597434':{'bg': u('\u0421\u0442\u0440\u0443\u043c\u044f\u043d\u0438'), 'en': 'Strumyani'}, '3597923':{'bg': u('\u0412\u0440\u0430\u0442\u0446\u0430'), 'en': 'Vrattsa'}, '3345042':{'en': 'Saint-Genis-Pouilly', 'fr': 'Saint-Genis-Pouilly'}, '3597744':{'bg': u('\u0415\u043b\u043e\u0432\u0434\u043e\u043b, \u041f\u0435\u0440\u043d\u0438\u043a'), 'en': 'Elovdol, Pernik'}, '3345040':{'en': 'Ferney-Voltaire', 'fr': 'Ferney-Voltaire'}, '3345041':{'en': 'Gex', 'fr': 'Gex'}, '3345045':{'en': 'Annecy', 'fr': 'Annecy'}, '3345048':{'en': 'Bellegarde-sur-Valserine', 'fr': 'Bellegarde-sur-Valserine'}, '3345049':{'en': 'Saint-Julien-en-Genevois', 'fr': 'Saint-Julien-en-Genevois'}, '3345739':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3326249':{'en': 'Saint-Pierre', 'fr': 'Saint-Pierre'}, '3326248':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326247':{'en': 'Salazie', 'fr': 'Salazie'}, '3326246':{'en': u('Saint-Andr\u00e9'), 'fr': u('Saint-Andr\u00e9')}, '3326245':{'en': 'Saint-Paul', 'fr': 'Saint-Paul'}, '3326244':{'en': 'Saint-Paul', 'fr': 'Saint-Paul'}, '3326243':{'en': 'Le Port', 'fr': 'Le Port'}, '3326242':{'en': 'Le Port', 'fr': 'Le Port'}, '3326241':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326240':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3317413':{'en': 'Saint-Germain-en-Laye', 'fr': 'Saint-Germain-en-Laye'}, '3597743':{'bg': u('\u0414\u0438\u0432\u043b\u044f'), 'en': 'Divlya'}, '3751562':{'be': u('\u0421\u043b\u043e\u043d\u0456\u043c'), 'en': 'Slonim', 'ru': u('\u0421\u043b\u043e\u043d\u0438\u043c')}, '3751563':{'be': u('\u0414\u0437\u044f\u0442\u043b\u0430\u0432\u0430, \u0413\u0440\u043e\u0434\u0437\u0435\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Dyatlovo, Grodno Region', 'ru': u('\u0414\u044f\u0442\u043b\u043e\u0432\u043e, \u0413\u0440\u043e\u0434\u043d\u0435\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751564':{'be': u('\u0417\u044d\u043b\u044c\u0432\u0430, \u0413\u0440\u043e\u0434\u0437\u0435\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Zelva, Grodno Region', 'ru': u('\u0417\u0435\u043b\u044c\u0432\u0430, \u0413\u0440\u043e\u0434\u043d\u0435\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3329939':{'en': 'Saint-Aubin-du-Cormier', 'fr': 'Saint-Aubin-du-Cormier'}, '442885':{'en': 'Ballygawley'}, '3332709':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '3332708':{'en': 'Douai', 'fr': 'Douai'}, '433473':{'de': 'Straden', 'en': 'Straden'}, '433472':{'de': 'Mureck', 'en': 'Mureck'}, '433475':{'de': u('H\u00fcrth'), 'en': u('H\u00fcrth')}, '433474':{'de': 'Deutsch Goritz', 'en': 'Deutsch Goritz'}, '433477':{'de': 'Sankt Peter am Ottersbach', 'en': 'St. Peter am Ottersbach'}, '433476':{'de': 'Bad Radkersburg', 'en': 'Bad Radkersburg'}, '375222':{'be': u('\u041c\u0430\u0433\u0456\u043b\u0451\u045e'), 'en': 'Mogilev', 'ru': u('\u041c\u043e\u0433\u0438\u043b\u0435\u0432')}, '375225':{'be': u('\u0411\u0430\u0431\u0440\u0443\u0439\u0441\u043a'), 'en': 'Babruysk', 'ru': u('\u0411\u043e\u0431\u0440\u0443\u0439\u0441\u043a')}, '35963202':{'bg': u('\u0414\u0440\u0430\u0433\u043e\u043c\u0438\u0440\u043e\u0432\u043e, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Dragomirovo, V. Tarnovo'}, '35963203':{'bg': u('\u0425\u0430\u0434\u0436\u0438\u0434\u0438\u043c\u0438\u0442\u0440\u043e\u0432\u043e, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Hadzhidimitrovo, V. Tarnovo'}, '35963204':{'bg': u('\u0414\u0435\u043b\u044f\u043d\u043e\u0432\u0446\u0438'), 'en': 'Delyanovtsi'}, '35963205':{'bg': u('\u0427\u0435\u0440\u0432\u0435\u043d\u0430'), 'en': 'Chervena'}, '35346':{'en': 'Navan/Kells/Trim/Edenderry/Enfield'}, '35347':{'en': 'Monaghan/Clones'}, '3356161':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356160':{'en': 'Pamiers', 'fr': 'Pamiers'}, '3356163':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356162':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356165':{'en': 'Foix', 'fr': 'Foix'}, '35344':{'en': 'Mullingar/Castlepollard/Tyrrellspass'}, '3356167':{'en': 'Pamiers', 'fr': 'Pamiers'}, '3356166':{'en': 'Saint-Girons', 'fr': 'Saint-Girons'}, '3344262':{'en': 'Aubagne', 'fr': 'Aubagne'}, '35342':{'en': 'Dundalk/Carrickmacross/Castleblaney'}, '3344264':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '432757':{'de': u('P\u00f6chlarn'), 'en': u('P\u00f6chlarn')}, '35341':{'en': 'Drogheda/Ardee'}, '37428495':{'am': u('\u0547\u056b\u0576\u0578\u0582\u0570\u0561\u0575\u0580'), 'en': 'Shinuhayr', 'ru': u('\u0428\u0438\u043d\u0443\u0430\u0439\u0440')}, '34983':{'en': 'Valladolid', 'es': 'Valladolid'}, '34982':{'en': 'Lugo', 'es': 'Lugo'}, '34981':{'en': u('Coru\u00f1a'), 'es': u('Coru\u00f1a')}, '34980':{'en': 'Zamora', 'es': 'Zamora'}, '3593043':{'bg': u('\u0417\u043c\u0435\u0438\u0446\u0430'), 'en': 'Zmeitsa'}, '34986':{'en': 'Pontevedra', 'es': 'Pontevedra'}, '3593041':{'bg': u('\u0414\u0435\u0432\u0438\u043d'), 'en': 'Devin'}, '34984':{'en': 'Asturias', 'es': 'Asturias'}, '34988':{'en': 'Ourense', 'es': 'Orense'}, '3593049':{'bg': u('\u0411\u0435\u0434\u0435\u043d'), 'en': 'Beden'}, '3751514':{'be': u('\u0428\u0447\u0443\u0447\u044b\u043d, \u0413\u0440\u043e\u0434\u0437\u0435\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Shchuchin, Grodno Region', 'ru': u('\u0429\u0443\u0447\u0438\u043d, \u0413\u0440\u043e\u0434\u043d\u0435\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3599559':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u041a\u043e\u0432\u0430\u0447\u0438\u0446\u0430'), 'en': 'Gorna Kovachitsa'}, '3599558':{'bg': u('\u0413\u0430\u0432\u0440\u0438\u043b \u0413\u0435\u043d\u043e\u0432\u043e'), 'en': 'Gavril Genovo'}, '3599557':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u0426\u0435\u0440\u043e\u0432\u0435\u043d\u0435'), 'en': 'Gorno Tserovene'}, '3599556':{'bg': u('\u0413\u043e\u0432\u0435\u0436\u0434\u0430'), 'en': 'Govezhda'}, '3599555':{'bg': u('\u041a\u043e\u043f\u0438\u043b\u043e\u0432\u0446\u0438, \u041c\u043e\u043d\u0442.'), 'en': 'Kopilovtsi, Mont.'}, '3599554':{'bg': u('\u0427\u0438\u043f\u0440\u043e\u0432\u0446\u0438'), 'en': 'Chiprovtsi'}, '3599553':{'bg': u('\u041f\u0440\u0435\u0432\u0430\u043b\u0430'), 'en': 'Prevala'}, '3599552':{'bg': u('\u0411\u0435\u043b\u0438\u043c\u0435\u043b'), 'en': 'Belimel'}, '3347638':{'en': 'Saint-Marcellin', 'fr': 'Saint-Marcellin'}, '3599550':{'bg': u('\u041c\u0438\u0442\u0440\u043e\u0432\u0446\u0438'), 'en': 'Mitrovtsi'}, '3324793':{'en': 'Chinon', 'fr': 'Chinon'}, '3324791':{'en': 'Loches', 'fr': 'Loches'}, '3324797':{'en': 'Bourgueil', 'fr': 'Bourgueil'}, '3324796':{'en': 'Langeais', 'fr': 'Langeais'}, '3324798':{'en': 'Chinon', 'fr': 'Chinon'}, '35278':{'de': 'Junglinster', 'en': 'Junglinster', 'fr': 'Junglinster'}, '35279':{'de': 'Berdorf/Consdorf', 'en': 'Berdorf/Consdorf', 'fr': 'Berdorf/Consdorf'}, '3598628':{'bg': u('\u0426\u0430\u0440 \u0410\u0441\u0435\u043d, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Tsar Asen, Silistra'}, '35272':{'de': 'Echternach', 'en': 'Echternach', 'fr': 'Echternach'}, '35273':{'de': 'Rosport', 'en': 'Rosport', 'fr': 'Rosport'}, '35271':{'de': 'Betzdorf', 'en': 'Betzdorf', 'fr': 'Betzdorf'}, '35276':{'de': 'Wormeldingen', 'en': 'Wormeldange', 'fr': 'Wormeldange'}, '35274':{'de': 'Wasserbillig', 'en': 'Wasserbillig', 'fr': 'Wasserbillig'}, '35275':{'de': 'Distrikt Grevenmacher', 'en': 'Grevenmacher', 'fr': 'Grevenmacher'}, '3353531':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '359361':{'bg': u('\u041a\u044a\u0440\u0434\u0436\u0430\u043b\u0438'), 'en': 'Kardzhali'}, '441489':{'en': 'Bishops Waltham'}, '441488':{'en': 'Hungerford'}, '441481':{'en': 'Guernsey'}, '3598622':{'bg': u('\u0410\u043b\u0435\u043a\u043e\u0432\u043e, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Alekovo, Silistra'}, '441483':{'en': 'Guildford'}, '441482':{'en': 'Kingston-upon-Hull'}, '441485':{'en': 'Hunstanton'}, '441484':{'en': 'Huddersfield'}, '441487':{'en': 'Warboys'}, '3598623':{'bg': u('\u0413\u043e\u043b\u0435\u0448, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Golesh, Silistra'}, '3356345':{'en': u('Saint-Ju\u00e9ry'), 'fr': u('Saint-Ju\u00e9ry')}, '3356347':{'en': 'Albi', 'fr': 'Albi'}, '3356346':{'en': 'Albi', 'fr': 'Albi'}, '3356343':{'en': 'Albi', 'fr': 'Albi'}, '3356342':{'en': 'Graulhet', 'fr': 'Graulhet'}, '3356349':{'en': 'Albi', 'fr': 'Albi'}, '3356348':{'en': 'Albi', 'fr': 'Albi'}, '351274':{'en': u('Proen\u00e7a-a-Nova'), 'pt': u('Proen\u00e7a-a-Nova')}, '441733':{'en': 'Peterborough'}, '441732':{'en': 'Sevenoaks'}, '351275':{'en': u('Covilh\u00e3'), 'pt': u('Covilh\u00e3')}, '441737':{'en': 'Redhill'}, '441736':{'en': 'Penzance'}, '441738':{'en': 'Perth'}, '3324137':{'en': 'Angers', 'fr': 'Angers'}, '3324136':{'en': 'Angers', 'fr': 'Angers'}, '3324135':{'en': 'Angers', 'fr': 'Angers'}, '3324134':{'en': 'Angers', 'fr': 'Angers'}, '3346716':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346715':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3324130':{'en': u('Chemill\u00e9'), 'fr': u('Chemill\u00e9')}, '3346718':{'en': u('S\u00e8te'), 'fr': u('S\u00e8te')}, '35584':{'en': u('Gjirokast\u00ebr')}, '35585':{'en': u('Sarand\u00eb')}, '3596068':{'bg': u('\u0411\u043e\u0436\u0443\u0440\u043a\u0430'), 'en': 'Bozhurka'}, '3596069':{'bg': u('\u0412\u0430\u0441\u0438\u043b \u041b\u0435\u0432\u0441\u043a\u0438, \u0422\u044a\u0440\u0433.'), 'en': 'Vasil Levski, Targ.'}, '39039':{'en': 'Monza', 'it': 'Monza'}, '35582':{'en': u('Kor\u00e7\u00eb')}, '35583':{'en': 'Pogradec'}, '3596062':{'bg': u('\u0421\u0442\u0440\u0430\u0436\u0430, \u0422\u044a\u0440\u0433.'), 'en': 'Strazha, Targ.'}, '3596063':{'bg': u('\u0411\u0430\u044f\u0447\u0435\u0432\u043e'), 'en': 'Bayachevo'}, '3596060':{'bg': u('\u041e\u0432\u0447\u0430\u0440\u043e\u0432\u043e, \u0422\u044a\u0440\u0433.'), 'en': 'Ovcharovo, Targ.'}, '3596061':{'bg': u('\u0413\u043e\u043b\u044f\u043c\u043e \u0421\u043e\u043a\u043e\u043b\u043e\u0432\u043e'), 'en': 'Golyamo Sokolovo'}, '3596066':{'bg': u('\u0411\u0443\u0439\u043d\u043e\u0432\u043e, \u0422\u044a\u0440\u0433.'), 'en': 'Buynovo, Targ.'}, '3596067':{'bg': u('\u041a\u0440\u0430\u043b\u0435\u0432\u043e, \u0422\u044a\u0440\u0433.'), 'en': 'Kralevo, Targ.'}, '3596064':{'bg': u('\u0413\u043e\u043b\u044f\u043c\u043e \u041d\u043e\u0432\u043e'), 'en': 'Golyamo Novo'}, '3596065':{'bg': u('\u0411\u0438\u0441\u0442\u0440\u0430, \u0422\u044a\u0440\u0433.'), 'en': 'Bistra, Targ.'}, '3336707':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3336708':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '351278':{'en': 'Mirandela', 'pt': 'Mirandela'}, '3324038':{'en': u('Cou\u00ebron'), 'fr': u('Cou\u00ebron')}, '436562':{'de': 'Mittersill', 'en': 'Mittersill'}, '3347685':{'en': 'Grenoble', 'fr': 'Grenoble'}, '436564':{'de': 'Krimml', 'en': 'Krimml'}, '436565':{'de': u('Neukirchen am Gro\u00dfvenediger'), 'en': 'Neukirchen am Grossvenediger'}, '436566':{'de': 'Bramberg am Wildkogel', 'en': 'Bramberg am Wildkogel'}, '3338631':{'en': 'Avallon', 'fr': 'Avallon'}, '3338630':{'en': 'Luzy', 'fr': 'Luzy'}, '3338635':{'en': 'Saint-Florentin', 'fr': 'Saint-Florentin'}, '3338634':{'en': 'Avallon', 'fr': 'Avallon'}, '3338636':{'en': 'Nevers', 'fr': 'Nevers'}, '3338639':{'en': 'Pouilly-sur-Loire', 'fr': 'Pouilly-sur-Loire'}, '3338756':{'en': 'Metz', 'fr': 'Metz'}, '441874':{'en': 'Brecon'}, '3338755':{'en': 'Metz', 'fr': 'Metz'}, '3338753':{'en': 'Amanvillers', 'fr': 'Amanvillers'}, '3338750':{'en': 'Metz', 'fr': 'Metz'}, '3338751':{'en': u('Maizi\u00e8res-l\u00e8s-Metz'), 'fr': u('Maizi\u00e8res-l\u00e8s-Metz')}, '3751775':{'be': u('\u0416\u043e\u0434\u0437\u0456\u043d\u0430'), 'en': 'Zhodino', 'ru': u('\u0416\u043e\u0434\u0438\u043d\u043e')}, '3751774':{'be': u('\u041b\u0430\u0433\u043e\u0439\u0441\u043a'), 'en': 'Lahoysk', 'ru': u('\u041b\u043e\u0433\u043e\u0439\u0441\u043a')}, '3751776':{'be': u('\u0421\u043c\u0430\u043b\u044f\u0432\u0456\u0447\u044b'), 'en': 'Smalyavichy', 'ru': u('\u0421\u043c\u043e\u043b\u0435\u0432\u0438\u0447\u0438')}, '3751771':{'be': u('\u0412\u0456\u043b\u0435\u0439\u043a\u0430'), 'en': 'Vileyka', 'ru': u('\u0412\u0438\u043b\u0435\u0439\u043a\u0430')}, '3751770':{'be': u('\u041d\u044f\u0441\u0432\u0456\u0436'), 'en': 'Nesvizh', 'ru': u('\u041d\u0435\u0441\u0432\u0438\u0436')}, '3338758':{'en': 'Moyeuvre-Grande', 'fr': 'Moyeuvre-Grande'}, '3751772':{'be': u('\u0412\u0430\u043b\u043e\u0436\u044b\u043d'), 'en': 'Volozhin', 'ru': u('\u0412\u043e\u043b\u043e\u0436\u0438\u043d')}, '35955504':{'bg': u('\u0411\u043e\u0433\u0434\u0430\u043d\u043e\u0432\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Bogdanovo, Burgas'}, '35955505':{'bg': u('\u0414\u0440\u0430\u0447\u0435\u0432\u043e'), 'en': 'Drachevo'}, '35955502':{'bg': u('\u0421\u0443\u0445\u043e\u0434\u043e\u043b, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Suhodol, Burgas'}, '3338258':{'en': 'Florange', 'fr': 'Florange'}, '3332066':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332067':{'en': 'Villeneuve-d\'Ascq', 'fr': 'Villeneuve-d\'Ascq'}, '3593548':{'bg': u('\u041f\u0430\u0448\u043e\u0432\u043e'), 'en': 'Pashovo'}, '3593549':{'bg': u('\u0413\u0440\u0430\u0448\u0435\u0432\u043e'), 'en': 'Grashevo'}, '3332062':{'en': 'Seclin', 'fr': 'Seclin'}, '3332063':{'en': 'Lille', 'fr': 'Lille'}, '3332060':{'en': 'Wattignies', 'fr': 'Wattignies'}, '3593542':{'bg': u('\u0420\u0430\u043a\u0438\u0442\u043e\u0432\u043e'), 'en': 'Rakitovo'}, '3593543':{'bg': u('\u0414\u043e\u0440\u043a\u043e\u0432\u043e'), 'en': 'Dorkovo'}, '3593547':{'bg': u('\u0421\u044a\u0440\u043d\u0438\u0446\u0430, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Sarnitsa, Pazardzhik'}, '3593544':{'bg': u('\u041a\u043e\u0441\u0442\u0430\u043d\u0434\u043e\u0432\u043e'), 'en': 'Kostandovo'}, '3593545':{'bg': u('\u0414\u0440\u0430\u0433\u0438\u043d\u043e\u0432\u043e'), 'en': 'Draginovo'}, '432719':{'de': u('Dro\u00df'), 'en': 'Dross'}, '432718':{'de': 'Lichtenau im Waldviertel', 'en': 'Lichtenau im Waldviertel'}, '432249':{'de': u('Gro\u00df-Enzersdorf'), 'en': 'Gross-Enzersdorf'}, '34875':{'en': 'Soria', 'es': 'Soria'}, '3338436':{'en': 'Delle', 'fr': 'Delle'}, '432245':{'de': 'Wolkersdorf im Weinviertel', 'en': 'Wolkersdorf im Weinviertel'}, '432244':{'de': 'Langenzersdorf', 'en': 'Langenzersdorf'}, '432247':{'de': 'Deutsch-Wagram', 'en': 'Deutsch-Wagram'}, '432246':{'de': 'Gerasdorf bei Wien', 'en': 'Gerasdorf bei Wien'}, '432717':{'de': 'Unter-Meisling', 'en': 'Unter-Meisling'}, '432716':{'de': u('Gf\u00f6hl'), 'en': u('Gf\u00f6hl')}, '432243':{'de': 'Klosterneuburg', 'en': 'Klosterneuburg'}, '432242':{'de': u('Sankt Andr\u00e4-W\u00f6rdern'), 'en': u('St. Andr\u00e4-W\u00f6rdern')}, '3355876':{'en': 'Saint-Sever', 'fr': 'Saint-Sever'}, '3355877':{'en': 'Saint-Vincent-de-Tyrosse', 'fr': 'Saint-Vincent-de-Tyrosse'}, '3355874':{'en': 'Dax', 'fr': 'Dax'}, '3355875':{'en': 'Mont-de-Marsan', 'fr': 'Mont-de-Marsan'}, '3355872':{'en': 'Capbreton', 'fr': 'Capbreton'}, '3355873':{'en': 'Peyrehorade', 'fr': 'Peyrehorade'}, '3355871':{'en': 'Aire-sur-l\'Adour', 'fr': 'Aire-sur-l\'Adour'}, '3338921':{'en': 'Colmar', 'fr': 'Colmar'}, '3355878':{'en': 'Biscarrosse', 'fr': 'Biscarrosse'}, '3355879':{'en': 'Hagetmau', 'fr': 'Hagetmau'}, '3329909':{'en': 'Montfort-sur-Meu', 'fr': 'Montfort-sur-Meu'}, '3341359':{'en': 'Marseille', 'fr': 'Marseille'}, '3323538':{'en': 'Lillebonne', 'fr': 'Lillebonne'}, '3323536':{'en': 'Canteleu', 'fr': 'Canteleu'}, '3323537':{'en': 'Duclair', 'fr': 'Duclair'}, '3338430':{'en': 'Lure', 'fr': 'Lure'}, '3329905':{'en': 'Bruz', 'fr': 'Bruz'}, '3323530':{'en': 'Montivilliers', 'fr': 'Montivilliers'}, '3323531':{'en': 'Bolbec', 'fr': 'Bolbec'}, '4419755':{'en': 'Alford (Aberdeen)'}, '4419754':{'en': 'Alford (Aberdeen)'}, '4419757':{'en': 'Strathdon'}, '3332393':{'en': 'Soissons', 'fr': 'Soissons'}, '4419751':{'en': 'Alford (Aberdeen)/Strathdon'}, '4419750':{'en': 'Alford (Aberdeen)/Strathdon'}, '3349408':{'en': 'La Garde', 'fr': 'La Garde'}, '3349409':{'en': 'Toulon', 'fr': 'Toulon'}, '3349406':{'en': 'La Seyne sur Mer', 'fr': 'La Seyne sur Mer'}, '3349407':{'en': 'Six-Fours-les-Plages', 'fr': 'Six-Fours-les-Plages'}, '3349404':{'en': u('Carc\u00e8s'), 'fr': u('Carc\u00e8s')}, '4419759':{'en': 'Alford (Aberdeen)'}, '3349403':{'en': 'Toulon', 'fr': 'Toulon'}, '3349400':{'en': u('Hy\u00e8res'), 'fr': u('Hy\u00e8res')}, '3349401':{'en': u('Hy\u00e8res'), 'fr': u('Hy\u00e8res')}, '441904':{'en': 'York'}, '441905':{'en': 'Worcester'}, '441900':{'en': 'Workington'}, '441902':{'en': 'Wolverhampton'}, '441903':{'en': 'Worthing'}, '441908':{'en': 'Milton Keynes'}, '432611':{'de': 'Mannersdorf an der Rabnitz', 'en': 'Mannersdorf an der Rabnitz'}, '3355701':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '433883':{'de': 'Terz', 'en': 'Terz'}, '3323301':{'en': 'Cherbourg-Octeville', 'fr': 'Cherbourg-Octeville'}, '437232':{'de': u('Sankt Martin im M\u00fchlkreis'), 'en': u('St. Martin im M\u00fchlkreis')}, '3329828':{'en': 'Le Relecq Kerhuon', 'fr': 'Le Relecq Kerhuon'}, '3332934':{'en': u('\u00c9pinal'), 'fr': u('\u00c9pinal')}, '3332935':{'en': u('\u00c9pinal'), 'fr': u('\u00c9pinal')}, '3332937':{'en': 'Mirecourt', 'fr': 'Mirecourt'}, '3332930':{'en': 'Le Val-d\'Ajol', 'fr': 'Le Val-d\'Ajol'}, '3332931':{'en': u('\u00c9pinal'), 'fr': u('\u00c9pinal')}, '3332932':{'en': u('\u00c9loyes'), 'fr': u('\u00c9loyes')}, '3332933':{'en': u('\u00c9pinal'), 'fr': u('\u00c9pinal')}, '3324304':{'en': 'Mayenne', 'fr': 'Mayenne'}, '3324305':{'en': u('Ern\u00e9e'), 'fr': u('Ern\u00e9e')}, '3324307':{'en': u('Ch\u00e2teau-Gontier'), 'fr': u('Ch\u00e2teau-Gontier')}, '3332938':{'en': 'Charmes', 'fr': 'Charmes'}, '3324301':{'en': u('\u00c9vron'), 'fr': u('\u00c9vron')}, '437231':{'de': 'Herzogsdorf', 'en': 'Herzogsdorf'}, '433624':{'de': 'Pichl-Kainisch', 'en': 'Pichl-Kainisch'}, '3355393':{'en': 'Casteljaloux', 'fr': 'Casteljaloux'}, '433622':{'de': 'Bad Aussee', 'en': 'Bad Aussee'}, '3323308':{'en': u('\u00c9queurdreville-Hainneville'), 'fr': u('\u00c9queurdreville-Hainneville')}, '373249':{'en': 'Glodeni', 'ro': 'Glodeni', 'ru': u('\u0413\u043b\u043e\u0434\u0435\u043d\u044c')}, '3329821':{'en': 'Landerneau', 'fr': 'Landerneau'}, '3596770':{'bg': u('\u041f\u043b\u0430\u0447\u043a\u043e\u0432\u0446\u0438'), 'en': 'Plachkovtsi'}, '373243':{'en': 'Causeni', 'ro': u('C\u0103u\u015feni'), 'ru': u('\u041a\u044d\u0443\u0448\u0435\u043d\u044c')}, '3329826':{'en': 'Pleyben', 'fr': 'Pleyben'}, '373241':{'en': 'Cimislia', 'ro': u('Cimi\u015flia'), 'ru': u('\u0427\u0438\u043c\u0438\u0448\u043b\u0438\u044f')}, '373247':{'en': 'Briceni', 'ro': 'Briceni', 'ru': u('\u0411\u0440\u0438\u0447\u0435\u043d\u044c')}, '373246':{'en': u('Edine\u0163'), 'ro': u('Edine\u0163'), 'ru': u('\u0415\u0434\u0438\u043d\u0435\u0446')}, '373533':{'en': 'Tiraspol', 'ro': 'Tiraspol', 'ru': u('\u0422\u0438\u0440\u0430\u0441\u043f\u043e\u043b')}, '3329827':{'en': 'Crozon', 'fr': 'Crozon'}, '3329824':{'en': 'Landivisiau', 'fr': 'Landivisiau'}, '35953223':{'bg': u('\u0426\u044a\u0440\u043a\u0432\u0438\u0446\u0430'), 'en': 'Tsarkvitsa'}, '35953222':{'bg': u('\u041c\u0430\u0440\u043a\u043e\u0432\u043e, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Markovo, Shumen'}, '35953221':{'bg': u('\u0421\u0442\u043e\u044f\u043d \u041c\u0438\u0445\u0430\u0439\u043b\u043e\u0432\u0441\u043a\u0438'), 'en': 'Stoyan Mihaylovski'}, '35953220':{'bg': u('\u041f\u0430\u043c\u0443\u043a\u0447\u0438\u0438, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Pamukchii, Shumen'}, '354421':{'en': u('Keflav\u00edk')}, '437236':{'de': 'Pregarten', 'en': 'Pregarten'}, '355885':{'en': u('Memaliaj, Tepelen\u00eb')}, '43316':{'de': 'Graz', 'en': 'Graz'}, '441877':{'en': 'Callander'}, '3347535':{'en': 'Aubenas', 'fr': 'Aubenas'}, '437234':{'de': 'Ottensheim', 'en': 'Ottensheim'}, '441824':{'en': 'Ruthin'}, '359559':{'bg': u('\u041a\u0430\u0440\u043d\u043e\u0431\u0430\u0442'), 'en': 'Karnobat'}, '359558':{'bg': u('\u0410\u0439\u0442\u043e\u0441'), 'en': 'Aytos'}, '359556':{'bg': u('\u041e\u0431\u0437\u043e\u0440'), 'en': 'Obzor'}, '359554':{'bg': u('\u0421\u043b\u044a\u043d\u0447\u0435\u0432 \u0431\u0440\u044f\u0433'), 'en': 'Sunny Beach'}, '359550':{'bg': u('\u0421\u043e\u0437\u043e\u043f\u043e\u043b'), 'en': 'Sozopol'}, '434826':{'de': u('M\u00f6rtschach'), 'en': u('M\u00f6rtschach')}, '434825':{'de': u('Gro\u00dfkirchheim'), 'en': 'Grosskirchheim'}, '434824':{'de': 'Heiligenblut', 'en': 'Heiligenblut'}, '434823':{'de': 'Tresdorf, Rangersdorf', 'en': 'Tresdorf, Rangersdorf'}, '434822':{'de': 'Winklern', 'en': 'Winklern'}, '441828':{'en': 'Coupar Angus'}, '3329687':{'en': 'Dinan', 'fr': 'Dinan'}, '3329684':{'en': u('Planco\u00ebt'), 'fr': u('Planco\u00ebt')}, '3329685':{'en': 'Dinan', 'fr': 'Dinan'}, '3329680':{'en': 'Broons', 'fr': 'Broons'}, '37422298':{'am': u('\u0531\u057c\u056b\u0576\u057b'), 'en': 'Arinj', 'ru': u('\u0410\u0440\u0438\u043d\u0434\u0436')}, '37422297':{'am': u('\u0533\u0565\u0572\u0561\u0577\u0565\u0576'), 'en': 'Geghashen', 'ru': u('\u0413\u0435\u0445\u0430\u0448\u0435\u043d')}, '37422296':{'am': u('\u054a\u057f\u0572\u0576\u056b'), 'en': 'Ptghni', 'ru': u('\u041f\u0442\u0445\u043d\u0438')}, '3347920':{'en': 'Aussois', 'fr': 'Aussois'}, '37422293':{'am': u('\u0531\u0580\u0561\u0574\u0578\u0582\u057d'), 'en': 'Aramus', 'ru': u('\u0410\u0440\u0430\u043c\u0443\u0441')}, '3347925':{'en': 'La Motte Servolex', 'fr': 'La Motte Servolex'}, '3347924':{'en': 'Moutiers Tarentaise', 'fr': 'Moutiers Tarentaise'}, '3316986':{'en': 'Gif-sur-Yvette', 'fr': 'Gif-sur-Yvette'}, '3316983':{'en': 'Yerres', 'fr': 'Yerres'}, '3316981':{'en': 'Massy', 'fr': 'Massy'}, '3342004':{'en': 'Ajaccio', 'fr': 'Ajaccio'}, '435526':{'de': 'Laterns', 'en': 'Laterns'}, '3316989':{'en': 'Soisy-sur-Seine', 'fr': 'Soisy-sur-Seine'}, '3316988':{'en': u('Br\u00e9tigny-sur-Orge'), 'fr': u('Br\u00e9tigny-sur-Orge')}, '3597106':{'bg': u('\u042f\u043c\u043d\u0430'), 'en': 'Yamna'}, '3597104':{'bg': u('\u041b\u044a\u0433\u0430'), 'en': 'Laga'}, '3597105':{'bg': u('\u041c\u0430\u043b\u043a\u0438 \u0418\u0441\u043a\u044a\u0440'), 'en': 'Malki Iskar'}, '3597102':{'bg': u('\u041b\u043e\u043f\u044f\u043d'), 'en': 'Lopyan'}, '3597103':{'bg': u('\u0411\u0440\u0443\u0441\u0435\u043d, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Brusen, Sofia'}, '3336138':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '441228':{'en': 'Carlisle'}, '441225':{'en': 'Bath'}, '441224':{'en': 'Aberdeen'}, '441227':{'en': 'Canterbury'}, '441226':{'en': 'Barnsley'}, '441223':{'en': 'Cambridge'}, '3338010':{'en': 'Dijon', 'fr': 'Dijon'}, '3345713':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3323231':{'en': u('\u00c9vreux'), 'fr': u('\u00c9vreux')}, '3323230':{'en': 'Conches-en-Ouche', 'fr': 'Conches-en-Ouche'}, '3323233':{'en': u('\u00c9vreux'), 'fr': u('\u00c9vreux')}, '3323232':{'en': 'Verneuil-sur-Avre', 'fr': 'Verneuil-sur-Avre'}, '3323239':{'en': u('\u00c9vreux'), 'fr': u('\u00c9vreux')}, '3323238':{'en': u('\u00c9vreux'), 'fr': u('\u00c9vreux')}, '3355398':{'en': 'Agen', 'fr': 'Agen'}, '437759':{'de': 'Antiesenhofen', 'en': 'Antiesenhofen'}, '3332233':{'en': 'Amiens', 'fr': 'Amiens'}, '3332232':{'en': 'Doullens', 'fr': 'Doullens'}, '3332231':{'en': 'Abbeville', 'fr': 'Abbeville'}, '437757':{'de': 'Gurten', 'en': 'Gurten'}, '3355512':{'en': 'Limoges', 'fr': 'Limoges'}, '437751':{'de': 'Sankt Martin im Innkreis', 'en': 'St. Martin im Innkreis'}, '3332235':{'en': 'Moreuil', 'fr': 'Moreuil'}, '437753':{'de': 'Eberschwang', 'en': 'Eberschwang'}, '437941':{'de': u('Neumarkt im M\u00fchlkreis'), 'en': u('Neumarkt im M\u00fchlkreis')}, '433453':{'de': 'Ehrenhausen', 'en': 'Ehrenhausen'}, '433452':{'de': 'Leibnitz', 'en': 'Leibnitz'}, '433457':{'de': u('Gleinst\u00e4tten'), 'en': u('Gleinst\u00e4tten')}, '433456':{'de': 'Fresing', 'en': 'Fresing'}, '433455':{'de': 'Arnfels', 'en': 'Arnfels'}, '433454':{'de': 'Leutschach', 'en': 'Leutschach'}, '3593933':{'bg': u('\u0421\u0442\u0440\u0430\u043d\u0441\u043a\u043e'), 'en': 'Stransko'}, '3593932':{'bg': u('\u0411\u043e\u0434\u0440\u043e\u0432\u043e'), 'en': 'Bodrovo'}, '3593931':{'bg': u('\u041a\u0430\u0441\u043d\u0430\u043a\u043e\u0432\u043e'), 'en': 'Kasnakovo'}, '3593937':{'bg': u('\u042f\u0431\u044a\u043b\u043a\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Yabalkovo, Hask.'}, '3593936':{'bg': u('\u0413\u043e\u0440\u0441\u043a\u0438 \u0438\u0437\u0432\u043e\u0440, \u0425\u0430\u0441\u043a.'), 'en': 'Gorski izvor, Hask.'}, '3593935':{'bg': u('\u0412\u044a\u0440\u0431\u0438\u0446\u0430, \u0425\u0430\u0441\u043a.'), 'en': 'Varbitsa, Hask.'}, '3593934':{'bg': u('\u0421\u043a\u043e\u0431\u0435\u043b\u0435\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Skobelevo, Hask.'}, '40269':{'en': 'Sibiu', 'ro': 'Sibiu'}, '40268':{'en': u('Bra\u0219ov'), 'ro': u('Bra\u0219ov')}, '40261':{'en': 'Satu Mare', 'ro': 'Satu Mare'}, '40260':{'en': u('S\u0103laj'), 'ro': u('S\u0103laj')}, '40263':{'en': u('Bistri\u021ba-N\u0103s\u0103ud'), 'ro': u('Bistri\u021ba-N\u0103s\u0103ud')}, '40262':{'en': u('Maramure\u0219'), 'ro': u('Maramure\u0219')}, '40265':{'en': u('Mure\u0219'), 'ro': u('Mure\u0219')}, '40264':{'en': 'Cluj', 'ro': 'Cluj'}, '40267':{'en': 'Covasna', 'ro': 'Covasna'}, '40266':{'en': 'Harghita', 'ro': 'Harghita'}, '46226':{'en': 'Avesta-Krylbo', 'sv': 'Avesta-Krylbo'}, '35963579':{'bg': u('\u0420\u0430\u043b\u0435\u0432\u043e'), 'en': 'Ralevo'}, '3598185':{'bg': u('\u0421\u0435\u043d\u043e\u0432\u043e'), 'en': 'Senovo'}, '370451':{'en': 'Pasvalys'}, '370450':{'en': u('Bir\u017eai')}, '370459':{'en': u('Kupi\u0161kis')}, '370458':{'en': u('Roki\u0161kis')}, '434229':{'de': u('Krumpendorf am W\u00f6rther See'), 'en': u('Krumpendorf am W\u00f6rther See')}, '434228':{'de': 'Feistritz im Rosental', 'en': 'Feistritz im Rosental'}, '441872':{'en': 'Truro'}, '434225':{'de': 'Grafenstein', 'en': 'Grafenstein'}, '3593111':{'bg': u('\u041f\u044a\u0440\u0432\u0435\u043d\u0435\u0446, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Parvenets, Plovdiv'}, '3349378':{'en': 'Beausoleil', 'fr': 'Beausoleil'}, '434226':{'de': 'Sankt Margareten im Rosental', 'en': 'St. Margareten im Rosental'}, '434221':{'de': 'Gallizien', 'en': 'Gallizien'}, '434220':{'de': u('K\u00f6ttmannsdorf'), 'en': u('K\u00f6ttmannsdorf')}, '434223':{'de': 'Maria Saal', 'en': 'Maria Saal'}, '3593112':{'bg': u('\u041c\u0430\u0440\u043a\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Markovo, Plovdiv'}, '3356102':{'en': 'Foix', 'fr': 'Foix'}, '3356101':{'en': 'Lavelanet', 'fr': 'Lavelanet'}, '3356100':{'en': u('Lab\u00e8ge'), 'fr': u('Lab\u00e8ge')}, '3356107':{'en': 'Tournefeuille', 'fr': 'Tournefeuille'}, '3356105':{'en': u('Tarascon-sur-Ari\u00e8ge'), 'fr': u('Tarascon-sur-Ari\u00e8ge')}, '3356104':{'en': 'Saint-Girons', 'fr': 'Saint-Girons'}, '359301':{'bg': u('\u0421\u043c\u043e\u043b\u044f\u043d'), 'en': 'Smolyan'}, '359306':{'bg': u('\u0420\u0443\u0434\u043e\u0437\u0435\u043c'), 'en': 'Rudozem'}, '359308':{'bg': u('\u041c\u0430\u0434\u0430\u043d, \u0421\u043c\u043e\u043b.'), 'en': 'Madan, Smol.'}, '359309':{'bg': u('\u041f\u0430\u043c\u043f\u043e\u0440\u043e\u0432\u043e'), 'en': 'Pamporovo'}, '34850':{'en': u('Almer\u00eda'), 'es': u('\u00c1lmer\u00eda')}, '441255':{'en': 'Clacton-on-Sea'}, '46221':{'en': u('K\u00f6ping'), 'sv': u('K\u00f6ping')}, '3355390':{'en': u('Rib\u00e9rac'), 'fr': u('Rib\u00e9rac')}, '35951537':{'bg': u('\u0427\u0435\u0440\u043d\u0435\u0432\u043e'), 'en': 'Chernevo'}, '35951536':{'bg': u('\u041d\u0438\u043a\u043e\u043b\u0430\u0435\u0432\u043a\u0430'), 'en': 'Nikolaevka'}, '35951539':{'bg': u('\u041b\u0435\u0432\u0441\u043a\u0438, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Levski, Varna'}, '35951538':{'bg': u('\u0418\u0437\u0433\u0440\u0435\u0432, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Izgrev, Varna'}, '441253':{'en': 'Blackpool'}, '3343276':{'en': 'Avignon', 'fr': 'Avignon'}, '3343274':{'en': 'Avignon', 'fr': 'Avignon'}, '3343270':{'en': 'Avignon', 'fr': 'Avignon'}, '3338381':{'en': u('Pont-\u00e0-Mousson'), 'fr': u('Pont-\u00e0-Mousson')}, '3338380':{'en': u('Pont-\u00e0-Mousson'), 'fr': u('Pont-\u00e0-Mousson')}, '3338383':{'en': u('Pont-\u00e0-Mousson'), 'fr': u('Pont-\u00e0-Mousson')}, '3338382':{'en': u('Pont-\u00e0-Mousson'), 'fr': u('Pont-\u00e0-Mousson')}, '3338385':{'en': 'Nancy', 'fr': 'Nancy'}, '3338384':{'en': u('Pont-\u00e0-Mousson'), 'fr': u('Pont-\u00e0-Mousson')}, '3346735':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3324118':{'en': 'Angers', 'fr': 'Angers'}, '3346736':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3346731':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3346730':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3346732':{'en': u('S\u00e9rignan'), 'fr': u('S\u00e9rignan')}, '35250':{'de': 'Bascharage/Petingen/Rodingen', 'en': 'Bascharage/Petange/Rodange', 'fr': 'Bascharage/Petange/Rodange'}, '35251':{'de': u('D\u00fcdelingen/Bettemburg/Livingen'), 'en': 'Dudelange/Bettembourg/Livange', 'fr': 'Dudelange/Bettembourg/Livange'}, '35252':{'de': u('D\u00fcdelingen'), 'en': 'Dudelange', 'fr': 'Dudelange'}, '35253':{'de': 'Esch-sur-Alzette', 'en': 'Esch-sur-Alzette', 'fr': 'Esch-sur-Alzette'}, '35254':{'de': 'Esch-sur-Alzette', 'en': 'Esch-sur-Alzette', 'fr': 'Esch-sur-Alzette'}, '35255':{'de': 'Esch-sur-Alzette/Monnerich', 'en': 'Esch-sur-Alzette/Mondercange', 'fr': 'Esch-sur-Alzette/Mondercange'}, '35256':{'de': u('R\u00fcmelingen'), 'en': 'Rumelange', 'fr': 'Rumelange'}, '35257':{'de': 'Esch-sur-Alzette/Schifflingen', 'en': 'Esch-sur-Alzette/Schifflange', 'fr': 'Esch-sur-Alzette/Schifflange'}, '35258':{'de': 'Differdingen', 'en': 'Differdange', 'fr': 'Differdange'}, '35259':{'de': 'Soleuvre', 'en': 'Soleuvre', 'fr': 'Soleuvre'}, '39050':{'en': 'Pisa', 'it': 'Pisa'}, '3332652':{'en': 'Vertus', 'fr': 'Vertus'}, '39055':{'en': 'Florence', 'it': 'Firenze'}, '3347028':{'en': u('Montlu\u00e7on'), 'fr': u('Montlu\u00e7on')}, '3347029':{'en': u('Montlu\u00e7on'), 'fr': u('Montlu\u00e7on')}, '3343010':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3343017':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3347020':{'en': 'Moulins', 'fr': 'Moulins'}, '3338659':{'en': 'Nevers', 'fr': 'Nevers'}, '3338653':{'en': 'Appoigny', 'fr': 'Appoigny'}, '3338652':{'en': 'Auxerre', 'fr': 'Auxerre'}, '3338651':{'en': 'Auxerre', 'fr': 'Auxerre'}, '3338657':{'en': 'Nevers', 'fr': 'Nevers'}, '3338656':{'en': u('Brienon-sur-Arman\u00e7on'), 'fr': u('Brienon-sur-Arman\u00e7on')}, '3338655':{'en': 'Tonnerre', 'fr': 'Tonnerre'}, '3338654':{'en': 'Tonnerre', 'fr': 'Tonnerre'}, '3338730':{'en': 'Metz', 'fr': 'Metz'}, '3338731':{'en': 'Metz', 'fr': 'Metz'}, '3338732':{'en': 'Metz', 'fr': 'Metz'}, '3338733':{'en': 'Metz', 'fr': 'Metz'}, '3338734':{'en': 'Metz', 'fr': 'Metz'}, '3338735':{'en': 'Metz', 'fr': 'Metz'}, '3338736':{'en': 'Metz', 'fr': 'Metz'}, '3338737':{'en': 'Metz', 'fr': 'Metz'}, '3338738':{'en': 'Augny', 'fr': 'Augny'}, '3338739':{'en': 'Metz', 'fr': 'Metz'}, '3645':{'en': 'Kisvarda', 'hu': u('Kisv\u00e1rda')}, '3644':{'en': u('M\u00e1t\u00e9szalka'), 'hu': u('M\u00e1t\u00e9szalka')}, '3642':{'en': 'Nyiregyhaza', 'hu': u('Ny\u00edregyh\u00e1za')}, '3335580':{'en': 'Metz', 'fr': 'Metz'}, '35961503':{'bg': u('\u0427\u0430\u043a\u0430\u043b\u0438'), 'en': 'Chakali'}, '35961502':{'bg': u('\u0413\u043e\u0440\u0441\u043a\u043e \u041d\u043e\u0432\u043e \u0421\u0435\u043b\u043e'), 'en': 'Gorsko Novo Selo'}, '3522792':{'de': 'Kanton Clerf/Fischbach/Hosingen', 'en': 'Clervaux/Fischbach/Hosingen', 'fr': 'Clervaux/Fischbach/Hosingen'}, '3522797':{'de': 'Huldingen', 'en': 'Huldange', 'fr': 'Huldange'}, '3522795':{'de': 'Wiltz', 'en': 'Wiltz', 'fr': 'Wiltz'}, '3522799':{'de': 'Ulflingen', 'en': 'Troisvierges', 'fr': 'Troisvierges'}, '35930205':{'bg': u('\u0421\u0442\u044a\u0440\u043d\u0438\u0446\u0430'), 'en': 'Starnitsa'}, '35930200':{'bg': u('\u0417\u0430\u0433\u0440\u0430\u0436\u0434\u0435\u043d, \u0421\u043c\u043e\u043b.'), 'en': 'Zagrazhden, Smol.'}, '432267':{'de': 'Sierndorf', 'en': 'Sierndorf'}, '3332001':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '3332002':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332003':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '3332004':{'en': u('Mons-en-Bar\u0153ul'), 'fr': u('Mons-en-Bar\u0153ul')}, '3332005':{'en': 'Villeneuve-d\'Ascq', 'fr': 'Villeneuve-d\'Ascq'}, '3332006':{'en': 'Lille', 'fr': 'Lille'}, '3332007':{'en': 'Loos', 'fr': 'Loos'}, '3332008':{'en': u('P\u00e9renchies'), 'fr': u('P\u00e9renchies')}, '3332009':{'en': 'Lomme', 'fr': 'Lomme'}, '432269':{'de': 'Niederfellabrunn', 'en': 'Niederfellabrunn'}, '432268':{'de': u('Gro\u00dfmugl'), 'en': 'Grossmugl'}, '3354676':{'en': u('Saint-Georges-d\'Ol\u00e9ron'), 'fr': u('Saint-Georges-d\'Ol\u00e9ron')}, '3354675':{'en': u('Dolus-d\'Ol\u00e9ron'), 'fr': u('Dolus-d\'Ol\u00e9ron')}, '3354674':{'en': 'Saintes', 'fr': 'Saintes'}, '3324048':{'en': 'Nantes', 'fr': 'Nantes'}, '3329963':{'en': 'Rennes', 'fr': 'Rennes'}, '3329962':{'en': 'Vern-sur-Seiche', 'fr': 'Vern-sur-Seiche'}, '3329961':{'en': u('Pl\u00e9lan-le-Grand'), 'fr': u('Pl\u00e9lan-le-Grand')}, '3329960':{'en': u('Pac\u00e9'), 'fr': u('Pac\u00e9')}, '3329967':{'en': 'Rennes', 'fr': 'Rennes'}, '3329966':{'en': 'Melesse', 'fr': 'Melesse'}, '3329965':{'en': 'Rennes', 'fr': 'Rennes'}, '3329964':{'en': 'Saint-Gilles', 'fr': 'Saint-Gilles'}, '3329969':{'en': u('G\u00e9vez\u00e9'), 'fr': u('G\u00e9vez\u00e9')}, '3329968':{'en': u('Liffr\u00e9'), 'fr': u('Liffr\u00e9')}, '3323559':{'en': 'Bois-Guillaume', 'fr': 'Bois-Guillaume'}, '3323550':{'en': 'Eu', 'fr': 'Eu'}, '3323551':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323552':{'en': 'Rouen', 'fr': 'Rouen'}, '3323553':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323554':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323556':{'en': 'Yvetot', 'fr': 'Yvetot'}, '3323557':{'en': 'Saint-Valery-en-Caux', 'fr': 'Saint-Valery-en-Caux'}, '3349468':{'en': 'Draguignan', 'fr': 'Draguignan'}, '3349469':{'en': 'Brignoles', 'fr': 'Brignoles'}, '3349460':{'en': 'Le Luc', 'fr': 'Le Luc'}, '3349461':{'en': 'Toulon', 'fr': 'Toulon'}, '3349462':{'en': 'Toulon', 'fr': 'Toulon'}, '3349463':{'en': 'Ollioules', 'fr': 'Ollioules'}, '3349464':{'en': 'Cavalaire-sur-Mer', 'fr': 'Cavalaire-sur-Mer'}, '3349465':{'en': u('Hy\u00e8res'), 'fr': u('Hy\u00e8res')}, '3349466':{'en': 'La Crau', 'fr': 'La Crau'}, '3349467':{'en': 'Draguignan', 'fr': 'Draguignan'}, '35941489':{'bg': u('\u0411\u043e\u0437\u0434\u0443\u0433\u0430\u043d\u043e\u0432\u043e'), 'en': 'Bozduganovo'}, '3355729':{'en': 'Merignac', 'fr': u('M\u00e9rignac')}, '3355726':{'en': 'Pessac', 'fr': 'Pessac'}, '3355724':{'en': u('Saint-\u00c9milion'), 'fr': u('Saint-\u00c9milion')}, '3355725':{'en': 'Libourne', 'fr': 'Libourne'}, '3355722':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '433535':{'de': 'Krakaudorf', 'en': 'Krakaudorf'}, '3324326':{'en': 'Laval', 'fr': 'Laval'}, '3324324':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324323':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324321':{'en': 'Arnage', 'fr': 'Arnage'}, '3324328':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324329':{'en': u('Bonn\u00e9table'), 'fr': u('Bonn\u00e9table')}, '437255':{'de': 'Losenstein', 'en': 'Losenstein'}, '437254':{'de': u('Gro\u00dframing'), 'en': 'Grossraming'}, '437257':{'de': u('Gr\u00fcnburg'), 'en': u('Gr\u00fcnburg')}, '437256':{'de': 'Ternberg', 'en': 'Ternberg'}, '437251':{'de': 'Schiedlberg', 'en': 'Schiedlberg'}, '437250':{'de': 'Maria Neustift', 'en': 'Maria Neustift'}, '437253':{'de': 'Wolfern', 'en': 'Wolfern'}, '437252':{'de': 'Steyr', 'en': 'Steyr'}, '437259':{'de': 'Sierning', 'en': 'Sierning'}, '437258':{'de': 'Bad Hall', 'en': 'Bad Hall'}, '381290':{'en': 'Urosevac', 'sr': u('Uro\u0161evac')}, '4418518':{'en': 'Stornoway'}, '4418519':{'en': 'Great Bernera'}, '437282':{'de': 'Neufelden', 'en': 'Neufelden'}, '441709':{'en': 'Rotherham'}, '4418510':{'en': 'Great Bernera/Stornoway'}, '4418511':{'en': 'Great Bernera/Stornoway'}, '4418512':{'en': 'Stornoway'}, '3356733':{'en': 'Toulouse', 'fr': 'Toulouse'}, '4418514':{'en': 'Great Bernera'}, '4418515':{'en': 'Stornoway'}, '435633':{'de': u('H\u00e4gerau'), 'en': u('H\u00e4gerau')}, '4418517':{'en': 'Stornoway'}, '46120':{'en': u('\u00c5tvidaberg'), 'sv': u('\u00c5tvidaberg')}, '46121':{'en': u('S\u00f6derk\u00f6ping'), 'sv': u('S\u00f6derk\u00f6ping')}, '46122':{'en': u('Finsp\u00e5ng'), 'sv': u('Finsp\u00e5ng')}, '432813':{'de': 'Arbesbach', 'en': 'Arbesbach'}, '46125':{'en': 'Vikbolandet', 'sv': 'Vikbolandet'}, '3599748':{'bg': u('\u0414\u044a\u043b\u0433\u043e\u0434\u0435\u043b\u0446\u0438'), 'en': 'Dalgodeltsi'}, '3599749':{'bg': u('\u0427\u0435\u0440\u043d\u0438 \u0432\u0440\u044a\u0445, \u041c\u043e\u043d\u0442.'), 'en': 'Cherni vrah, Mont.'}, '3599746':{'bg': u('\u0420\u0430\u0437\u0433\u0440\u0430\u0434, \u041c\u043e\u043d\u0442.'), 'en': 'Razgrad, Mont.'}, '3599747':{'bg': u('\u041c\u043e\u043a\u0440\u0435\u0448, \u041c\u043e\u043d\u0442.'), 'en': 'Mokresh, Mont.'}, '3599744':{'bg': u('\u0412\u044a\u043b\u0447\u0435\u0434\u0440\u044a\u043c'), 'en': 'Valchedram'}, '3599745':{'bg': u('\u0417\u043b\u0430\u0442\u0438\u044f, \u041c\u043e\u043d\u0442.'), 'en': 'Zlatia, Mont.'}, '3599742':{'bg': u('\u042f\u043a\u0438\u043c\u043e\u0432\u043e'), 'en': 'Yakimovo'}, '3599740':{'bg': u('\u0421\u0435\u043f\u0442\u0435\u043c\u0432\u0440\u0438\u0439\u0446\u0438, \u041c\u043e\u043d\u0442.'), 'en': 'Septemvriytsi, Mont.'}, '3599741':{'bg': u('\u0414\u043e\u043b\u043d\u0438 \u0426\u0438\u0431\u044a\u0440'), 'en': 'Dolni Tsibar'}, '374237':{'am': u('\u0531\u0580\u0561\u0584\u057d/\u0531\u0580\u0574\u0561\u057e\u056b\u0580/\u0540\u0578\u056f\u057f\u0565\u0574\u0562\u0565\u0580/\u053c\u0565\u0576\u0578\u0582\u0572\u056b/\u0544\u0565\u056e\u0561\u0574\u0578\u0580/\u0536\u0561\u0580\u0569\u0578\u0576\u0584'), 'en': 'Araks/Armavir/Hoktember/Lenughi/Metsamor/Zartonk', 'ru': u('\u0410\u0440\u0430\u043a\u0441/\u0410\u0440\u043c\u0430\u0432\u0438\u0440/\u041e\u043a\u0442\u0435\u043c\u0431\u0435\u0440/\u041b\u0435\u043d\u0443\u0445\u0438/\u041c\u0435\u0446\u0430\u043c\u043e\u0440/\u0417\u0430\u0440\u0442\u043e\u043d\u043a')}, '374236':{'am': u('\u0531\u0575\u0576\u0569\u0561\u057a/\u0544\u0561\u057d\u056b\u057d/\u0546\u0578\u0580 \u053d\u0561\u0580\u0562\u0565\u0580\u0564/\u0546\u0578\u0580\u0561\u0562\u0561\u0581'), 'en': 'Ayntap/Masis/Nor Kharberd/Norabats', 'ru': u('\u041c\u0430\u0441\u0438\u0441/\u041d\u043e\u0440 \u0425\u0430\u0440\u0431\u0435\u0440\u0434/\u041d\u043e\u0440\u0430\u0431\u0430\u0446')}, '374235':{'am': u('\u0531\u0580\u057f\u0561\u0577\u0561\u057f/\u0531\u0575\u0563\u0565\u0566\u0561\u0580\u0564/\u0534\u0561\u056c\u0561\u0580/\u0554\u0561\u0572\u0581\u0580\u0561\u0577\u0565\u0576/\u0544\u056d\u0579\u0575\u0561\u0576/\u0547\u0561\u0570\u0578\u0582\u0574\u0575\u0561\u0576'), 'en': 'Artashat/Aygezard/Dalar/Kaghtsrashen/Mkhchyan/Shahumyan', 'ru': u('\u0410\u0440\u0442\u0430\u0448\u0430\u0442/\u0410\u0439\u0433\u0435\u0437\u0430\u0440\u0434/\u0414\u0430\u043b\u0430\u0440/\u041a\u0430\u0445\u0446\u0440\u0430\u0448\u0435\u043d/\u041c\u0445\u0447\u044f\u043d/\u0428\u0430\u0443\u043c\u044f\u043d')}, '374234':{'am': u('\u054e\u0565\u0564\u056b/\u0548\u057d\u056f\u0565\u057f\u0561\u0583/\u0531\u0580\u0561\u0580\u0561\u057f'), 'en': 'Vedi/Vosketap/Ararat', 'ru': u('\u0412\u0435\u0434\u0438/\u0412\u043e\u0441\u043a\u0435\u0442\u0430\u043f/\u0410\u0440\u0430\u0440\u0430\u0442')}, '374233':{'am': u('\u0532\u0561\u0572\u0580\u0561\u0574\u0575\u0561\u0576/\u053c\u0565\u057c\u0576\u0561\u0563\u0578\u0563'), 'en': 'Baghramyan/Lernagog', 'ru': u('\u0411\u0430\u0433\u0440\u0430\u043c\u044f\u043d/\u041b\u0435\u0440\u043d\u0430\u0433\u043e\u0433')}, '374232':{'am': u('\u0531\u0577\u057f\u0561\u0580\u0561\u056f/\u0531\u0572\u0571\u0584/\u053f\u0561\u0580\u0562\u056b/\u0555\u0577\u0561\u056f\u0561\u0576'), 'en': 'Aghdzq/Ashtarak/Karbi/Oshakan', 'ru': u('\u0410\u0448\u0442\u0430\u0440\u0430\u043a/\u0410\u0445\u0446\u043a/\u041a\u0430\u0440\u0431\u0438/\u041e\u0448\u0430\u043a\u0430\u043d')}, '374231':{'am': u('\u054e\u0561\u0572\u0561\u0580\u0577\u0561\u057a\u0561\u057f/\u0544\u0578\u0582\u057d\u0561\u056c\u0565\u057c/\u0553\u0561\u0580\u0561\u0584\u0561\u0580/\u0536\u057e\u0561\u0580\u0569\u0576\u0578\u0581'), 'en': 'Echmiadzin/Musaler/Parakar/Zvartnots', 'ru': u('\u042d\u0447\u043c\u0438\u0430\u0434\u0437\u0438\u043d/\u041c\u0443\u0441\u0430\u043b\u0435\u0440/\u041f\u0430\u0440\u0430\u043a\u044f\u0440/\u0417\u0432\u0430\u0440\u0442\u043d\u043e\u0446')}, '374238':{'am': u('\u0531\u0580\u0561\u0580\u0561\u057f/\u0531\u057e\u0577\u0561\u0580/\u054d\u0578\u0582\u0580\u0565\u0576\u0561\u057e\u0561\u0576/\u0535\u0580\u0561\u057d\u056d'), 'en': 'Ararat/Avshar/Surenavan/Yeraskh', 'ru': u('\u0410\u0440\u0430\u0440\u0430\u0442/\u0410\u0432\u0448\u0430\u0440/\u0421\u0443\u0440\u0435\u043d\u0430\u0432\u0430\u043d/\u0415\u0440\u0430\u0441\u0445')}, '3596569':{'bg': u('\u041b\u0435\u043d\u043a\u043e\u0432\u043e'), 'en': 'Lenkovo'}, '3596568':{'bg': u('\u0414\u044a\u0431\u043e\u0432\u0430\u043d'), 'en': 'Dabovan'}, '3596563':{'bg': u('\u0411\u0440\u0435\u0441\u0442, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Brest, Pleven'}, '3596562':{'bg': u('\u0413\u0438\u0433\u0435\u043d'), 'en': 'Gigen'}, '3596561':{'bg': u('\u0413\u0443\u043b\u044f\u043d\u0446\u0438'), 'en': 'Gulyantsi'}, '3347612':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3596567':{'bg': u('\u0421\u043e\u043c\u043e\u0432\u0438\u0442'), 'en': 'Somovit'}, '3596566':{'bg': u('\u0414\u043e\u043b\u043d\u0438 \u0412\u0438\u0442'), 'en': 'Dolni Vit'}, '3596565':{'bg': u('\u041c\u0438\u043b\u043a\u043e\u0432\u0438\u0446\u0430'), 'en': 'Milkovitsa'}, '3596564':{'bg': u('\u0417\u0430\u0433\u0440\u0430\u0436\u0434\u0435\u043d, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Zagrazhden, Pleven'}, '441676':{'en': 'Meriden'}, '359538':{'bg': u('\u0412\u0435\u043b\u0438\u043a\u0438 \u041f\u0440\u0435\u0441\u043b\u0430\u0432'), 'en': 'Veliki Preslav'}, '441674':{'en': 'Montrose'}, '3346747':{'en': 'Montpellier', 'fr': 'Montpellier'}, '441672':{'en': 'Marlborough'}, '441673':{'en': 'Market Rasen'}, '441670':{'en': 'Morpeth'}, '441671':{'en': 'Newton Stewart'}, '359537':{'bg': u('\u041d\u043e\u0432\u0438 \u043f\u0430\u0437\u0430\u0440, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Novi pazar, Shumen'}, '3346741':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346742':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346743':{'en': u('M\u00e8ze'), 'fr': u('M\u00e8ze')}, '3347905':{'en': 'Modane', 'fr': 'Modane'}, '3347904':{'en': 'Bourg-Saint-Maurice', 'fr': 'Bourg-Saint-Maurice'}, '3347907':{'en': 'Bourg-Saint-Maurice', 'fr': 'Bourg-Saint-Maurice'}, '3347906':{'en': u('Val-d\'Is\u00e8re'), 'fr': u('Val-d\'Is\u00e8re')}, '434847':{'de': 'Obertilliach', 'en': 'Obertilliach'}, '434846':{'de': 'Abfaltersbach', 'en': 'Abfaltersbach'}, '434848':{'de': 'Kartitsch', 'en': 'Kartitsch'}, '3347908':{'en': 'Courchevel Saint Bon', 'fr': 'Courchevel Saint Bon'}, '390439':{'it': 'Feltre'}, '390438':{'it': 'Conegliano'}, '432216':{'de': 'Leopoldsdorf im Marchfelde', 'en': 'Leopoldsdorf im Marchfelde'}, '390433':{'it': 'Tolmezzo'}, '390432':{'en': 'Udine', 'it': 'Udine'}, '390431':{'it': 'Cervignano del Friuli'}, '390437':{'it': 'Belluno'}, '390436':{'it': 'Cortina d\'Ampezzo'}, '390435':{'it': 'Pieve di Cadore'}, '390434':{'it': 'Pordenone'}, '3597168':{'bg': u('\u0411\u043e\u0432'), 'en': 'Bov'}, '3597169':{'bg': u('\u0422\u043e\u043c\u043f\u0441\u044a\u043d'), 'en': 'Tompsan'}, '441205':{'en': 'Boston'}, '441204':{'en': 'Bolton'}, '441202':{'en': 'Bournemouth'}, '441200':{'en': 'Clitheroe'}, '374322':{'am': u('\u054e\u0561\u0576\u0561\u0571\u0578\u0580/\u0533\u0578\u0582\u0563\u0561\u0580\u0584'), 'en': 'Vanadzor/Gugark region', 'ru': u('\u0412\u0430\u043d\u0430\u0434\u0437\u043e\u0440/\u0413\u0443\u0433\u0430\u0440\u043a')}, '3343737':{'en': 'Lyon', 'fr': 'Lyon'}, '3597162':{'bg': u('\u041b\u0430\u043a\u0430\u0442\u043d\u0438\u043a'), 'en': 'Lakatnik'}, '3597163':{'bg': u('\u0418\u0441\u043a\u0440\u0435\u0446'), 'en': 'Iskrets'}, '3597164':{'bg': u('\u0420\u0435\u0431\u0440\u043e\u0432\u043e'), 'en': 'Rebrovo'}, '3597165':{'bg': u('\u041c\u0438\u043b\u0430\u043d\u043e\u0432\u043e, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Milanovo, Sofia'}, '3597166':{'bg': u('\u0412\u043b\u0430\u0434\u043e \u0422\u0440\u0438\u0447\u043a\u043e\u0432'), 'en': 'Vlado Trichkov'}, '3597167':{'bg': u('\u0426\u0435\u0440\u043e\u0432\u043e, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Tserovo, Sofia'}, '3742549':{'am': u('\u0544\u0565\u056e\u0561\u057e\u0561\u0576'), 'en': 'Metsavan', 'ru': u('\u041c\u0435\u0446\u0430\u0432\u0430\u043d')}, '3752239':{'be': u('\u0428\u043a\u043b\u043e\u045e'), 'en': 'Shklov', 'ru': u('\u0428\u043a\u043b\u043e\u0432')}, '3752238':{'be': u('\u041a\u0440\u0430\u0441\u043d\u0430\u043f\u043e\u043b\u043b\u0435, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Krasnopolye, Mogilev Region', 'ru': u('\u041a\u0440\u0430\u0441\u043d\u043e\u043f\u043e\u043b\u044c\u0435, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752235':{'be': u('\u0410\u0441\u0456\u043f\u043e\u0432\u0456\u0447\u044b'), 'en': 'Osipovichi', 'ru': u('\u041e\u0441\u0438\u043f\u043e\u0432\u0438\u0447\u0438')}, '3752234':{'be': u('\u041a\u0440\u0443\u0433\u043b\u0430\u0435, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Krugloye, Mogilev Region', 'ru': u('\u041a\u0440\u0443\u0433\u043b\u043e\u0435, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752237':{'be': u('\u041a\u0456\u0440\u0430\u045e\u0441\u043a, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Kirovsk, Mogilev Region', 'ru': u('\u041a\u0438\u0440\u043e\u0432\u0441\u043a, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752236':{'be': u('\u041a\u043b\u0456\u0447\u0430\u045e, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Klichev, Mogilev Region', 'ru': u('\u041a\u043b\u0438\u0447\u0435\u0432, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752231':{'be': u('\u0411\u044b\u0445\u0430\u045e, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Byhov, Mogilev Region', 'ru': u('\u0411\u044b\u0445\u043e\u0432, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752230':{'be': u('\u0413\u043b\u0443\u0441\u043a, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Glusk, Mogilev Region', 'ru': u('\u0413\u043b\u0443\u0441\u043a, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752233':{'be': u('\u0413\u043e\u0440\u043a\u0456, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Gorki, Mogilev Region', 'ru': u('\u0413\u043e\u0440\u043a\u0438, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752232':{'be': u('\u0411\u044f\u043b\u044b\u043d\u0456\u0447\u044b, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Belynichi, Mogilev Region', 'ru': u('\u0411\u0435\u043b\u044b\u043d\u0438\u0447\u0438, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '37410':{'am': u('\u0535\u0580\u0587\u0561\u0576/\u054b\u0580\u057e\u0565\u056a'), 'en': 'Yerevan/Jrvezh', 'ru': u('\u0415\u0440\u0435\u0432\u0430\u043d/\u0414\u0436\u0440\u0432\u0435\u0436')}, '37411':{'am': u('\u0535\u0580\u0587\u0561\u0576'), 'en': 'Yerevan', 'ru': u('\u0415\u0440\u0435\u0432\u0430\u043d')}, '35963570':{'bg': u('\u0421\u0442\u0430\u0440\u043e\u0441\u0435\u043b\u0446\u0438'), 'en': 'Staroseltsi'}, '3595517':{'bg': u('\u0420\u0430\u0432\u043d\u0435\u0446, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Ravnets, Burgas'}, '35963573':{'bg': u('\u0414\u0438\u0441\u0435\u0432\u0438\u0446\u0430'), 'en': 'Disevitsa'}, '35963574':{'bg': u('\u0422\u043e\u0434\u043e\u0440\u043e\u0432\u043e, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Todorovo, Pleven'}, '3323788':{'en': 'Chartres', 'fr': 'Chartres'}, '35963576':{'bg': u('\u0422\u0443\u0447\u0435\u043d\u0438\u0446\u0430'), 'en': 'Tuchenitsa'}, '3595516':{'bg': u('\u0418\u043d\u0434\u0436\u0435 \u0432\u043e\u0439\u0432\u043e\u0434\u0430'), 'en': 'Indzhe voyvoda'}, '35963578':{'bg': u('\u041e\u043f\u0430\u043d\u0435\u0446, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Opanets, Pleven'}, '3323784':{'en': 'Chartres', 'fr': 'Chartres'}, '3323781':{'en': 'La Loupe', 'fr': 'La Loupe'}, '3595515':{'bg': u('\u041a\u0430\u043c\u0435\u043d\u043e'), 'en': 'Kameno'}, '3323783':{'en': u('\u00c9pernon'), 'fr': u('\u00c9pernon')}, '35971227':{'bg': u('\u0411\u0435\u043b\u0438 \u0418\u0441\u043a\u044a\u0440'), 'en': 'Beli Iskar'}, '432522':{'de': 'Laa an der Thaya', 'en': 'Laa an der Thaya'}, '432523':{'de': 'Kirchstetten, Neudorf bei Staatz', 'en': 'Kirchstetten, Neudorf bei Staatz'}, '432524':{'de': 'Kautendorf', 'en': 'Kautendorf'}, '432525':{'de': 'Gnadendorf', 'en': 'Gnadendorf'}, '432526':{'de': 'Stronsdorf', 'en': 'Stronsdorf'}, '432527':{'de': 'Wulzeshofen', 'en': 'Wulzeshofen'}, '3595511':{'bg': u('\u041b\u0443\u043a\u043e\u0439\u043b \u041d\u0435\u0444\u0442\u043e\u0445\u0438\u043c'), 'en': 'Lukoil Neftochim'}, '35971224':{'bg': u('\u0428\u0438\u043f\u043e\u0447\u0430\u043d\u0435'), 'en': 'Shipochane'}, '3345087':{'en': 'Annemasse', 'fr': 'Annemasse'}, '3345084':{'en': 'Annemasse', 'fr': 'Annemasse'}, '3345083':{'en': 'Thonon-les-Bains', 'fr': 'Thonon-les-Bains'}, '3345081':{'en': 'Thonon-les-Bains', 'fr': 'Thonon-les-Bains'}, '3593667':{'bg': u('\u041f\u043e\u043a\u0440\u043e\u0432\u0430\u043d'), 'en': 'Pokrovan'}, '3593666':{'bg': u('\u041f\u043e\u043f\u0441\u043a\u043e'), 'en': 'Popsko'}, '3593665':{'bg': u('\u0421\u0432\u0438\u0440\u0430\u0447\u0438'), 'en': 'Svirachi'}, '3593664':{'bg': u('\u041f\u043b\u0435\u0432\u0443\u043d'), 'en': 'Plevun'}, '3593662':{'bg': u('\u0416\u0435\u043b\u0435\u0437\u0438\u043d\u043e'), 'en': 'Zhelezino'}, '3345088':{'en': 'Annecy', 'fr': 'Annecy'}, '3345089':{'en': 'Cluses', 'fr': 'Cluses'}, '3332743':{'en': 'Denain', 'fr': 'Denain'}, '3332742':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '3332741':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '3332740':{'en': u('Vieux-Cond\u00e9'), 'fr': u('Vieux-Cond\u00e9')}, '3332747':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '3332746':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '3332745':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '3332744':{'en': 'Denain', 'fr': 'Denain'}, '3332748':{'en': 'Saint-Amand-les-Eaux', 'fr': 'Saint-Amand-les-Eaux'}, '3332219':{'en': 'Abbeville', 'fr': 'Abbeville'}, '40247':{'en': 'Teleorman', 'ro': 'Teleorman'}, '40246':{'en': 'Giurgiu', 'ro': 'Giurgiu'}, '40245':{'en': u('D\u00e2mbovi\u021ba'), 'ro': u('D\u00e2mbovi\u021ba')}, '40244':{'en': 'Prahova', 'ro': 'Prahova'}, '3356129':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3352407':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '40241':{'en': u('Constan\u021ba'), 'ro': u('Constan\u021ba')}, '3347553':{'en': u('Mont\u00e9limar'), 'fr': u('Mont\u00e9limar')}, '3356125':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356124':{'en': 'Balma', 'fr': 'Balma'}, '3356126':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356121':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356120':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356123':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356122':{'en': 'Toulouse', 'fr': 'Toulouse'}, '37423191':{'am': u('\u054e\u0561\u0579\u0565'), 'en': 'Vache', 'ru': u('\u0412\u0430\u0447\u0435')}, '37423190':{'am': u('\u0532\u0561\u0572\u0580\u0561\u0574\u0575\u0561\u0576'), 'en': 'Baghramyan', 'ru': u('\u0411\u0430\u0433\u0440\u0430\u043c\u044f\u043d')}, '37423195':{'am': u('\u0546\u0578\u0580\u0561\u056f\u0565\u0580\u057f'), 'en': 'Norakert', 'ru': u('\u041d\u043e\u0440\u0430\u043a\u0435\u0440\u0442')}, '37423199':{'am': u('\u053d\u0578\u0580\u0578\u0576\u0584'), 'en': 'Khoronk', 'ru': u('\u0425\u043e\u0440\u043e\u043d\u043a')}, '37423198':{'am': u('\u054b\u0580\u0561\u057c\u0561\u057f'), 'en': 'Jrarat', 'ru': u('\u0414\u0436\u0440\u0430\u0440\u0430\u0442')}, '433834':{'de': u('Wald am Schoberpa\u00df'), 'en': 'Wald am Schoberpass'}, '437475':{'de': 'Hausmening, Neuhofen an der Ybbs', 'en': 'Hausmening, Neuhofen an der Ybbs'}, '441449':{'en': 'Stowmarket'}, '437474':{'de': 'Euratsfeld', 'en': 'Euratsfeld'}, '441445':{'en': 'Gairloch'}, '441444':{'en': 'Haywards Heath'}, '441446':{'en': 'Barry'}, '437477':{'de': 'Sankt Peter in der Au', 'en': 'St. Peter in der Au'}, '441443':{'en': 'Pontypridd'}, '441442':{'en': 'Hemel Hempstead'}, '437476':{'de': 'Aschbach-Markt', 'en': 'Aschbach-Markt'}, '437471':{'de': 'Neustadtl an der Donau', 'en': 'Neustadtl an der Donau'}, '3599513':{'bg': u('\u0411\u043e\u0439\u0447\u0438\u043d\u043e\u0432\u0446\u0438'), 'en': 'Boychinovtsi'}, '3599512':{'bg': u('\u0411\u0435\u043b\u0438 \u0431\u0440\u0435\u0433'), 'en': 'Beli breg'}, '3599517':{'bg': u('\u041a\u043e\u0431\u0438\u043b\u044f\u043a'), 'en': 'Kobilyak'}, '3599516':{'bg': u('\u041b\u0435\u0445\u0447\u0435\u0432\u043e'), 'en': 'Lehchevo'}, '3599515':{'bg': u('\u041c\u0430\u0434\u0430\u043d, \u041c\u043e\u043d\u0442.'), 'en': 'Madan, Mont.'}, '3599514':{'bg': u('\u0412\u043b\u0430\u0434\u0438\u043c\u0438\u0440\u043e\u0432\u043e, \u041c\u043e\u043d\u0442.'), 'en': 'Vladimirovo, Mont.'}, '3356381':{'en': 'Gaillac', 'fr': 'Gaillac'}, '3356380':{'en': 'Albi', 'fr': 'Albi'}, '3356383':{'en': 'Lavaur', 'fr': 'Lavaur'}, '3599518':{'bg': u('\u041c\u044a\u0440\u0447\u0435\u0432\u043e'), 'en': 'Marchevo'}, '3347228':{'en': 'Saint-Priest', 'fr': 'Saint-Priest'}, '3347596':{'en': 'Pierrelatte', 'fr': 'Pierrelatte'}, '3343250':{'en': 'Cavaillon', 'fr': 'Cavaillon'}, '3347226':{'en': u('Saint-Andr\u00e9-de-Corcy'), 'fr': u('Saint-Andr\u00e9-de-Corcy')}, '3347227':{'en': 'Caluire-et-Cuire', 'fr': 'Caluire-et-Cuire'}, '3347592':{'en': u('Mont\u00e9limar'), 'fr': u('Mont\u00e9limar')}, '3347221':{'en': u('V\u00e9nissieux'), 'fr': u('V\u00e9nissieux')}, '3347222':{'en': u('Lyon Saint Exup\u00e9ry A\u00e9roport'), 'fr': u('Lyon Saint Exup\u00e9ry A\u00e9roport')}, '3347591':{'en': u('Mont\u00e9limar'), 'fr': u('Mont\u00e9limar')}, '3593036':{'bg': u('\u041c\u043e\u0433\u0438\u043b\u0438\u0446\u0430'), 'en': 'Mogilitsa'}, '3593037':{'bg': u('\u0421\u0438\u0432\u0438\u043d\u043e'), 'en': 'Sivino'}, '39070':{'en': 'Cagliari', 'it': 'Cagliari'}, '39071':{'en': 'Ancona', 'it': 'Ancona'}, '3324179':{'en': 'Angers', 'fr': 'Angers'}, '3324178':{'en': 'Chalonnes-sur-Loire', 'fr': 'Chalonnes-sur-Loire'}, '39075':{'en': 'Perugia', 'it': 'Perugia'}, '3324173':{'en': 'Angers', 'fr': 'Angers'}, '3324172':{'en': 'Angers', 'fr': 'Angers'}, '3324171':{'en': 'Cholet', 'fr': 'Cholet'}, '3593035':{'bg': u('\u0412\u044a\u0440\u0431\u0438\u043d\u0430'), 'en': 'Varbina'}, '35935418':{'bg': u('\u041a\u0440\u044a\u0441\u0442\u0430\u0432\u0430'), 'en': 'Krastava'}, '35935419':{'bg': u('\u0421\u0432\u0435\u0442\u0430 \u041f\u0435\u0442\u043a\u0430'), 'en': 'Sveta Petka'}, '42144':{'en': u('Liptovsk\u00fd Mikul\u00e1\u0161')}, '3347048':{'en': 'Moulins', 'fr': 'Moulins'}, '3593039':{'bg': u('\u041f\u043e\u043b\u043a\u043e\u0432\u043d\u0438\u043a \u0421\u0435\u0440\u0430\u0444\u0438\u043c\u043e\u0432\u043e'), 'en': 'Polkovnik Serafimovo'}, '3347044':{'en': 'Moulins', 'fr': 'Moulins'}, '3347045':{'en': u('Saint-Pour\u00e7ain-sur-Sioule'), 'fr': u('Saint-Pour\u00e7ain-sur-Sioule')}, '3347046':{'en': 'Moulins', 'fr': 'Moulins'}, '435331':{'de': 'Brandenberg', 'en': 'Brandenberg'}, '3338677':{'en': 'Decize', 'fr': 'Decize'}, '3338676':{'en': 'Moux-en-Morvan', 'fr': 'Moux-en-Morvan'}, '3338671':{'en': 'Nevers', 'fr': 'Nevers'}, '3338670':{'en': u('La Charit\u00e9 sur Loire'), 'fr': u('La Charit\u00e9 sur Loire')}, '435336':{'de': 'Alpbach', 'en': 'Alpbach'}, '3338672':{'en': 'Auxerre', 'fr': 'Auxerre'}, '435338':{'de': 'Kundl', 'en': 'Kundl'}, '435339':{'de': u('Wildsch\u00f6nau'), 'en': u('Wildsch\u00f6nau')}, '433578':{'de': 'Obdach', 'en': 'Obdach'}, '35984269':{'bg': u('\u041d\u0435\u0434\u043e\u043a\u043b\u0430\u043d'), 'en': 'Nedoklan'}, '35984266':{'bg': u('\u041f\u0440\u043e\u0441\u0442\u043e\u0440\u043d\u043e'), 'en': 'Prostorno'}, '3666':{'en': 'Bekescsaba', 'hu': u('B\u00e9k\u00e9scsaba')}, '3663':{'en': 'Szentes', 'hu': 'Szentes'}, '3662':{'en': 'Szeged', 'hu': 'Szeged'}, '432556':{'de': u('Gro\u00dfkrut'), 'en': 'Grosskrut'}, '3669':{'en': 'Mohacs', 'hu': u('Moh\u00e1cs')}, '3668':{'en': 'Oroshaza', 'hu': u('Orosh\u00e1za')}, '3596174':{'bg': u('\u0414\u0440\u0430\u0433\u0430\u043d\u043e\u0432\u043e, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Draganovo, V. Tarnovo'}, '3596175':{'bg': u('\u041f\u044a\u0440\u0432\u043e\u043c\u0430\u0439\u0446\u0438'), 'en': 'Parvomaytsi'}, '3338718':{'en': 'Metz', 'fr': 'Metz'}, '3596177':{'bg': u('\u042f\u043d\u0442\u0440\u0430, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Yantra, V. Tarnovo'}, '3596173':{'bg': u('\u0414\u043e\u043b\u043d\u0430 \u041e\u0440\u044f\u0445\u043e\u0432\u0438\u0446\u0430'), 'en': 'Dolna Oryahovitsa'}, '3338713':{'en': 'Forbach', 'fr': 'Forbach'}, '3338716':{'en': 'Metz', 'fr': 'Metz'}, '3338717':{'en': 'Metz', 'fr': 'Metz'}, '3338715':{'en': 'Metz', 'fr': 'Metz'}, '3338815':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '433576':{'de': 'Bretstein', 'en': 'Bretstein'}, '3338814':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3343038':{'en': u('Al\u00e8s'), 'fr': u('Al\u00e8s')}, '3592':{'bg': u('\u0421\u043e\u0444\u0438\u044f'), 'en': 'Sofia'}, '3693':{'en': 'Nagykanizsa', 'hu': 'Nagykanizsa'}, '334938':{'en': 'Nice', 'fr': 'Nice'}, '3338810':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338813':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338812':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '4415074':{'en': 'Alford (Lincs)'}, '3349991':{'en': u('Clermont-l\'H\u00e9rault'), 'fr': u('Clermont-l\'H\u00e9rault')}, '434255':{'de': 'Arnoldstein', 'en': 'Arnoldstein'}, '437284':{'de': 'Oberkappel', 'en': 'Oberkappel'}, '434253':{'de': 'Sankt Jakob im Rosental', 'en': 'St. Jakob im Rosental'}, '3332028':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '3332029':{'en': u('La Bass\u00e9e'), 'fr': u('La Bass\u00e9e')}, '35951314':{'bg': u('\u0412\u043e\u0439\u0432\u043e\u0434\u0438\u043d\u043e'), 'en': 'Voyvodino'}, '437218':{'de': u('Gro\u00dftraberg'), 'en': 'Grosstraberg'}, '3332022':{'en': 'Lomme', 'fr': 'Lomme'}, '3332023':{'en': 'Bondues', 'fr': 'Bondues'}, '3332020':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332021':{'en': 'Lille', 'fr': 'Lille'}, '3332026':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '3332027':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '3332024':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '3332025':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '3354659':{'en': u('Saint-Jean-d\'Ang\u00e9ly'), 'fr': u('Saint-Jean-d\'Ang\u00e9ly')}, '3354658':{'en': 'Matha', 'fr': 'Matha'}, '3354656':{'en': u('Ch\u00e2telaillon-Plage'), 'fr': u('Ch\u00e2telaillon-Plage')}, '3354650':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3354652':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3323572':{'en': 'Rouen', 'fr': 'Rouen'}, '3323573':{'en': 'Rouen', 'fr': 'Rouen'}, '3323570':{'en': 'Rouen', 'fr': 'Rouen'}, '3323571':{'en': 'Rouen', 'fr': 'Rouen'}, '3329949':{'en': u('Val-d\'Iz\u00e9'), 'fr': u('Val-d\'Iz\u00e9')}, '3329948':{'en': 'Dol-de-Bretagne', 'fr': 'Dol-de-Bretagne'}, '3323574':{'en': u('D\u00e9ville-l\u00e8s-Rouen'), 'fr': u('D\u00e9ville-l\u00e8s-Rouen')}, '37425691':{'am': u('\u053f\u0578\u0582\u0580\u0569\u0561\u0576'), 'en': 'Kurtan', 'ru': u('\u041a\u0443\u0440\u0442\u0430\u043d')}, '3355524':{'en': 'Brive-la-Gaillarde', 'fr': 'Brive-la-Gaillarde'}, '3323578':{'en': 'Elbeuf', 'fr': 'Elbeuf'}, '3329946':{'en': 'Dinard', 'fr': 'Dinard'}, '3329941':{'en': 'Chantepie', 'fr': 'Chantepie'}, '3329940':{'en': 'Saint-Malo', 'fr': 'Saint-Malo'}, '3355522':{'en': 'Brive-la-Gaillarde', 'fr': 'Brive-la-Gaillarde'}, '3355835':{'en': u('Saint-Paul-l\u00e8s-Dax'), 'fr': u('Saint-Paul-l\u00e8s-Dax')}, '3349334':{'en': 'Antibes Juan les Pins', 'fr': 'Antibes Juan les Pins'}, '3349335':{'en': 'Menton', 'fr': 'Menton'}, '3349336':{'en': 'Grasse', 'fr': 'Grasse'}, '3349337':{'en': 'Nice', 'fr': 'Nice'}, '3349446':{'en': 'Toulon', 'fr': 'Toulon'}, '3349331':{'en': 'Saint-Laurent-du-Var', 'fr': 'Saint-Laurent-du-Var'}, '3349332':{'en': 'La Colle sur Loup', 'fr': 'La Colle sur Loup'}, '3349445':{'en': 'Puget-sur-Argens', 'fr': 'Puget-sur-Argens'}, '3349449':{'en': 'Sainte-Maxime', 'fr': 'Sainte-Maxime'}, '3349338':{'en': 'Cannes', 'fr': 'Cannes'}, '3349339':{'en': 'Cannes', 'fr': 'Cannes'}, '437212':{'de': 'Zwettl an der Rodl', 'en': 'Zwettl an der Rodl'}, '3327202':{'en': 'Nantes', 'fr': 'Nantes'}, '437214':{'de': 'Reichenthal', 'en': 'Reichenthal'}, '3324023':{'en': 'Batz-sur-Mer', 'fr': 'Batz-sur-Mer'}, '3355748':{'en': 'Libourne', 'fr': 'Libourne'}, '3355749':{'en': 'Coutras', 'fr': 'Coutras'}, '3355740':{'en': 'Castillon-la-Bataille', 'fr': 'Castillon-la-Bataille'}, '3355742':{'en': 'Blaye', 'fr': 'Blaye'}, '3355743':{'en': u('Saint-Andr\u00e9-de-Cubzac'), 'fr': u('Saint-Andr\u00e9-de-Cubzac')}, '3355746':{'en': 'Sainte-Foy-la-Grande', 'fr': 'Sainte-Foy-la-Grande'}, '3332688':{'en': 'Reims', 'fr': 'Reims'}, '3332689':{'en': 'Reims', 'fr': 'Reims'}, '3332686':{'en': 'Reims', 'fr': 'Reims'}, '3332687':{'en': 'Reims', 'fr': 'Reims'}, '3332684':{'en': 'Reims', 'fr': 'Reims'}, '3332685':{'en': 'Reims', 'fr': 'Reims'}, '3332682':{'en': 'Reims', 'fr': 'Reims'}, '3332683':{'en': 'Reims', 'fr': 'Reims'}, '3332680':{'en': u('S\u00e9zanne'), 'fr': u('S\u00e9zanne')}, '3594729':{'bg': u('\u041a\u0438\u0440\u0438\u043b\u043e\u0432\u043e, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Kirilovo, Yambol'}, '3594728':{'bg': u('\u041c\u0435\u043b\u043d\u0438\u0446\u0430'), 'en': 'Melnitsa'}, '3594727':{'bg': u('\u041c\u0430\u043b\u044a\u043a \u043c\u0430\u043d\u0430\u0441\u0442\u0438\u0440'), 'en': 'Malak manastir'}, '3594726':{'bg': u('\u041c\u0430\u043b\u043e\u043c\u0438\u0440\u043e\u0432\u043e'), 'en': 'Malomirovo'}, '3594725':{'bg': u('\u041b\u0435\u0441\u043e\u0432\u043e'), 'en': 'Lesovo'}, '3594724':{'bg': u('\u0420\u0430\u0437\u0434\u0435\u043b, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Razdel, Yambol'}, '3594723':{'bg': u('\u0411\u043e\u044f\u043d\u043e\u0432\u043e, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Boyanovo, Yambol'}, '3524':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '3324340':{'en': u('Chang\u00e9'), 'fr': u('Chang\u00e9')}, '3324341':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324342':{'en': u('\u00c9commoy'), 'fr': u('\u00c9commoy')}, '3324343':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324344':{'en': u('Ch\u00e2teau-du-Loir'), 'fr': u('Ch\u00e2teau-du-Loir')}, '3324348':{'en': u('La Fl\u00e8che'), 'fr': u('La Fl\u00e8che')}, '3324349':{'en': 'Laval', 'fr': 'Laval'}, '3332978':{'en': 'Ligny-en-Barrois', 'fr': 'Ligny-en-Barrois'}, '3332979':{'en': 'Bar-le-Duc', 'fr': 'Bar-le-Duc'}, '437279':{'de': 'Haibach ob der Donau', 'en': 'Haibach ob der Donau'}, '437278':{'de': 'Neukirchen am Walde', 'en': 'Neukirchen am Walde'}, '437277':{'de': 'Waizenkirchen', 'en': 'Waizenkirchen'}, '437276':{'de': 'Peuerbach', 'en': 'Peuerbach'}, '437274':{'de': 'Alkoven', 'en': 'Alkoven'}, '437273':{'de': 'Aschach an der Donau', 'en': 'Aschach an der Donau'}, '437272':{'de': 'Eferding', 'en': 'Eferding'}, '3332976':{'en': 'Bar-le-Duc', 'fr': 'Bar-le-Duc'}, '3332977':{'en': 'Bar-le-Duc', 'fr': 'Bar-le-Duc'}, '3348311':{'en': 'Draguignan', 'fr': 'Draguignan'}, '3348312':{'en': u('Fr\u00e9jus'), 'fr': u('Fr\u00e9jus')}, '3348315':{'en': 'Antibes', 'fr': 'Antibes'}, '3348314':{'en': 'Cannes', 'fr': 'Cannes'}, '3348316':{'en': 'Toulon', 'fr': 'Toulon'}, '3726':{'en': 'Tallinn/Harju County'}, '3356244':{'en': 'Tarbes', 'fr': 'Tarbes'}, '3356246':{'en': 'Lourdes', 'fr': 'Lourdes'}, '3356711':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356241':{'en': u('Saint-P\u00e9-de-Bigorre'), 'fr': u('Saint-P\u00e9-de-Bigorre')}, '3356242':{'en': 'Lourdes', 'fr': 'Lourdes'}, '3356248':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3325167':{'en': 'Les Herbiers', 'fr': 'Les Herbiers'}, '3325166':{'en': 'Les Herbiers', 'fr': 'Les Herbiers'}, '3325165':{'en': u('Mortagne-sur-S\u00e8vre'), 'fr': u('Mortagne-sur-S\u00e8vre')}, '3325164':{'en': 'Les Herbiers', 'fr': 'Les Herbiers'}, '3325163':{'en': u('Mortagne-sur-S\u00e8vre'), 'fr': u('Mortagne-sur-S\u00e8vre')}, '3325162':{'en': 'La Roche sur Yon', 'fr': 'La Roche sur Yon'}, '3325160':{'en': 'Saint-Gilles-Croix-de-Vie', 'fr': 'Saint-Gilles-Croix-de-Vie'}, '3325169':{'en': 'Fontenay-le-Comte', 'fr': 'Fontenay-le-Comte'}, '3325168':{'en': 'Challans', 'fr': 'Challans'}, '3346960':{'en': 'Lyon', 'fr': 'Lyon'}, '3595733':{'bg': u('\u041a\u0430\u0440\u0434\u0430\u043c, \u0414\u043e\u0431\u0440.'), 'en': 'Kardam, Dobr.'}, '331830':{'en': 'Paris', 'fr': 'Paris'}, '3595732':{'bg': u('\u041f\u0435\u0442\u043b\u0435\u0448\u043a\u043e\u0432\u043e'), 'en': 'Petleshkovo'}, '3344254':{'en': 'Venelles', 'fr': 'Venelles'}, '3344255':{'en': 'Istres', 'fr': 'Istres'}, '3344256':{'en': 'Istres', 'fr': 'Istres'}, '3344257':{'en': 'Lambesc', 'fr': 'Lambesc'}, '35351':{'en': 'Waterford/Carrick-on-Suir/New Ross/Kilmacthomas'}, '3344251':{'en': 'Gardanne', 'fr': 'Gardanne'}, '3344252':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '35352':{'en': 'Clonmel/Cahir/Killenaule'}, '35359':{'en': 'Carlow/Muine Bheag/Athy/Baltinglass'}, '35358':{'en': 'Dungarvan'}, '3599728':{'bg': u('\u0421\u043b\u0438\u0432\u0430\u0442\u0430'), 'en': 'Slivata'}, '3599729':{'bg': u('\u0420\u0430\u0441\u043e\u0432\u043e'), 'en': 'Rasovo'}, '3599720':{'bg': u('\u041a\u043e\u0432\u0430\u0447\u0438\u0446\u0430'), 'en': 'Kovachitsa'}, '3599721':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u0426\u0435\u0440\u043e\u0432\u0435\u043d\u0435'), 'en': 'Dolno Tserovene'}, '3599722':{'bg': u('\u0421\u0442\u0430\u043b\u0438\u0439\u0441\u043a\u0430 \u043c\u0430\u0445\u0430\u043b\u0430'), 'en': 'Staliyska mahala'}, '3599723':{'bg': u('\u0422\u0440\u0430\u0439\u043a\u043e\u0432\u043e'), 'en': 'Traykovo'}, '3599724':{'bg': u('\u0421\u0442\u0430\u043d\u0435\u0432\u043e'), 'en': 'Stanevo'}, '3599725':{'bg': u('\u041a\u043e\u043c\u043e\u0449\u0438\u0446\u0430'), 'en': 'Komoshtitsa'}, '3349957':{'en': u('S\u00e8te'), 'fr': u('S\u00e8te')}, '3599727':{'bg': u('\u041c\u0435\u0434\u043a\u043e\u0432\u0435\u0446'), 'en': 'Medkovets'}, '3347699':{'en': 'Claix', 'fr': 'Claix'}, '3347698':{'en': 'Claix', 'fr': 'Claix'}, '3347695':{'en': 'Villard-de-Lans', 'fr': 'Villard-de-Lans'}, '3347694':{'en': 'Villard-de-Lans', 'fr': 'Villard-de-Lans'}, '3347697':{'en': 'Pontcharra', 'fr': 'Pontcharra'}, '3347696':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347691':{'en': 'Rives', 'fr': 'Rives'}, '3347690':{'en': 'Meylan', 'fr': 'Meylan'}, '3347692':{'en': 'Crolles', 'fr': 'Crolles'}, '374253':{'am': u('\u0531\u056c\u0561\u057e\u0565\u0580\u0564\u056b/\u0555\u0571\u0578\u0582\u0576/\u053e\u0561\u0572\u056f\u0561\u0577\u0561\u057f/\u0539\u0578\u0582\u0574\u0561\u0576\u0575\u0561\u0576'), 'en': 'Alaverdi/Odzun/Tsaghkashat/Tumanyan', 'ru': u('\u0410\u043b\u0430\u0432\u0435\u0440\u0434\u0438/\u041e\u0434\u0437\u0443\u043d/\u0426\u0430\u0445\u043a\u0430\u0448\u0430\u0442/\u0422\u0443\u043c\u0430\u043d\u044f\u043d')}, '374252':{'am': u('\u0531\u057a\u0561\u0580\u0561\u0576'), 'en': 'Aparan', 'ru': u('\u0410\u043f\u0430\u0440\u0430\u043d')}, '374255':{'am': u('\u054d\u057a\u056b\u057f\u0561\u056f'), 'en': 'Spitak region', 'ru': u('\u0421\u043f\u0438\u0442\u0430\u043a')}, '3595739':{'bg': u('\u041f\u0447\u0435\u043b\u0430\u0440\u043e\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'Pchelarovo, Dobr.'}, '374257':{'am': u('\u0531\u0580\u0561\u0563\u0561\u056e'), 'en': 'Aragats', 'ru': u('\u0410\u0440\u0430\u0433\u0430\u0446')}, '374256':{'am': u('\u054d\u057f\u0565\u0583\u0561\u0576\u0561\u057e\u0561\u0576/\u0532\u0578\u057e\u0561\u0571\u0578\u0580'), 'en': 'Bovadzor/Stepanavan', 'ru': u('\u0421\u0442\u0435\u043f\u0430\u043d\u0430\u0432\u0430\u043d/\u0411\u043e\u0432\u0430\u0434\u0437\u043e\u0440')}, '3595738':{'bg': u('\u0421\u043f\u0430\u0441\u043e\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'Spasovo, Dobr.'}, '3349923':{'en': 'Montpellier', 'fr': 'Montpellier'}, '435510':{'de': u('Dam\u00fcls'), 'en': u('Dam\u00fcls')}, '373293':{'en': 'Vulcanesti', 'ro': u('Vulc\u0103ne\u015fti'), 'ru': u('\u0412\u0443\u043b\u043a\u044d\u043d\u0435\u0448\u0442\u044c')}, '359517':{'bg': u('\u0414\u044a\u043b\u0433\u043e\u043f\u043e\u043b'), 'en': 'Dalgopol'}, '359519':{'bg': u('\u0414\u0435\u0432\u043d\u044f'), 'en': 'Devnya'}, '359518':{'bg': u('\u041f\u0440\u043e\u0432\u0430\u0434\u0438\u044f'), 'en': 'Provadia'}, '441650':{'en': 'Cemmaes Road'}, '441651':{'en': 'Oldmeldrum'}, '441652':{'en': 'Brigg'}, '441653':{'en': 'Malton'}, '441654':{'en': 'Machynlleth'}, '441655':{'en': 'Maybole'}, '441656':{'en': 'Bridgend'}, '441659':{'en': 'Sanquhar'}, '355373':{'en': u('Krutje/Bubullim\u00eb/Allkaj, Lushnj\u00eb')}, '355372':{'en': u('Karbunar\u00eb/Fier-Shegan/Hysgjokaj/Ballagat, Lushnj\u00eb')}, '355371':{'en': u('Divjak\u00eb, Lushnj\u00eb')}, '355377':{'en': u('Qend\u00ebr/Greshic\u00eb/Hekal, Mallakast\u00ebr')}, '355376':{'en': u('Dushk/T\u00ebrbuf, Lushnj\u00eb')}, '355375':{'en': u('Golem/Grabian/Remas, Lushnj\u00eb')}, '355374':{'en': u('Gradisht\u00eb/Kolonj\u00eb, Lushnj\u00eb')}, '355378':{'en': u('Aranitas/Ngracan/Selit\u00eb/Fratar/Kut\u00eb, Mallakast\u00ebr')}, '3597918':{'bg': u('\u042f\u0431\u044a\u043b\u043a\u043e\u0432\u043e, \u041a\u044e\u0441\u0442.'), 'en': 'Yabalkovo, Kyust.'}, '3596545':{'bg': u('\u041b\u044e\u0431\u0435\u043d\u043e\u0432\u043e, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Lyubenovo, Pleven'}, '3596544':{'bg': u('\u041d\u043e\u0432\u0430\u0447\u0435\u043d\u0435, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Novachene, Pleven'}, '3596547':{'bg': u('\u0414\u0440\u0430\u0433\u0430\u0448 \u0432\u043e\u0439\u0432\u043e\u0434\u0430'), 'en': 'Dragash voyvoda'}, '3596546':{'bg': u('\u041b\u043e\u0437\u0438\u0446\u0430, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Lozitsa, Pleven'}, '3596541':{'bg': u('\u041d\u0438\u043a\u043e\u043f\u043e\u043b'), 'en': 'Nikopol'}, '3596540':{'bg': u('\u0410\u0441\u0435\u043d\u043e\u0432\u043e, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Asenovo, Pleven'}, '3596543':{'bg': u('\u041c\u0443\u0441\u0435\u043b\u0438\u0435\u0432\u043e'), 'en': 'Muselievo'}, '3596542':{'bg': u('\u0412\u044a\u0431\u0435\u043b, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Vabel, Pleven'}, '3596549':{'bg': u('\u0421\u0430\u043d\u0430\u0434\u0438\u043d\u043e\u0432\u043e'), 'en': 'Sanadinovo'}, '3596548':{'bg': u('\u0414\u0435\u0431\u043e\u0432\u043e'), 'en': 'Debovo'}, '3332471':{'en': 'Vouziers', 'fr': 'Vouziers'}, '3597142':{'bg': u('\u041a\u043e\u0441\u0442\u0435\u043d\u0435\u0446'), 'en': 'Kostenets'}, '3597143':{'bg': u('\u0412\u0430\u043a\u0430\u0440\u0435\u043b'), 'en': 'Vakarel'}, '3597146':{'bg': u('\u0427\u0435\u0440\u043d\u044c\u043e\u0432\u043e'), 'en': 'Chernyovo'}, '3597147':{'bg': u('\u041f\u0447\u0435\u043b\u0438\u043d, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Pchelin, Sofia'}, '3597144':{'bg': u('\u041a\u043e\u0441\u0442\u0435\u043d\u0435\u0446'), 'en': 'Kostenets'}, '3597145':{'bg': u('\u041c\u0438\u0440\u043e\u0432\u043e, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Mirovo, Sofia'}, '3597148':{'bg': u('\u041c\u0443\u0445\u043e\u0432\u043e'), 'en': 'Muhovo'}, '3597149':{'bg': u('\u0416\u0438\u0432\u043a\u043e\u0432\u043e, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Zhivkovo, Sofia'}, '441261':{'en': 'Banff'}, '441260':{'en': 'Congleton'}, '441263':{'en': 'Cromer'}, '441262':{'en': 'Bridlington'}, '441264':{'en': 'Andover'}, '441267':{'en': 'Carmarthen'}, '441269':{'en': 'Ammanford'}, '441268':{'en': 'Basildon'}, '3332357':{'en': 'Tergnier', 'fr': 'Tergnier'}, '3597913':{'bg': u('\u0420\u0430\u0448\u043a\u0430 \u0413\u0440\u0430\u0449\u0438\u0446\u0430'), 'en': 'Rashka Grashtitsa'}, '3343757':{'en': 'Lyon', 'fr': 'Lyon'}, '35974401':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u0414\u0440\u0430\u0433\u043b\u0438\u0449\u0435'), 'en': 'Gorno Draglishte'}, '35974402':{'bg': u('\u0413\u043e\u0434\u043b\u0435\u0432\u043e'), 'en': 'Godlevo'}, '35974403':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u0414\u0440\u0430\u0433\u043b\u0438\u0449\u0435'), 'en': 'Dolno Draglishte'}, '35974404':{'bg': u('\u0411\u0430\u0431\u044f\u043a'), 'en': 'Babyak'}, '35974405':{'bg': u('\u041a\u0440\u0430\u0438\u0449\u0435, \u0411\u043b\u0430\u0433.'), 'en': 'Kraishte, Blag.'}, '35974406':{'bg': u('\u0414\u043e\u0431\u044a\u0440\u0441\u043a\u043e'), 'en': 'Dobarsko'}, '35974407':{'bg': u('\u041a\u0440\u0435\u043c\u0435\u043d, \u0411\u043b\u0430\u0433.'), 'en': 'Kremen, Blag.'}, '35974408':{'bg': u('\u041e\u0431\u0438\u0434\u0438\u043c'), 'en': 'Obidim'}, '35974409':{'bg': u('\u041c\u0435\u0441\u0442\u0430'), 'en': 'Mesta'}, '35984749':{'bg': u('\u0421\u0435\u0432\u0430\u0440'), 'en': 'Sevar'}, '35984740':{'bg': u('\u0411\u0438\u0441\u0435\u0440\u0446\u0438'), 'en': 'Bisertsi'}, '35984743':{'bg': u('\u0411\u0440\u0435\u0441\u0442\u043e\u0432\u0435\u043d\u0435'), 'en': 'Brestovene'}, '35984744':{'bg': u('\u0411\u0435\u043b\u043e\u0432\u0435\u0446'), 'en': 'Belovets'}, '35984745':{'bg': u('\u0412\u043b\u0430\u0434\u0438\u043c\u0438\u0440\u043e\u0432\u0446\u0438'), 'en': 'Vladimirovtsi'}, '3326229':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326228':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326225':{'en': 'Saint-Pierre', 'fr': 'Saint-Pierre'}, '3326224':{'en': 'Saint-Paul', 'fr': 'Saint-Paul'}, '3326227':{'en': 'Le Tampon', 'fr': 'Le Tampon'}, '3326226':{'en': 'Saint-Louis', 'fr': 'Saint-Louis'}, '3326221':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326220':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326223':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326222':{'en': 'Saint-Paul', 'fr': 'Saint-Paul'}, '35967394':{'bg': u('\u0411\u043e\u0433\u0430\u0442\u043e\u0432\u043e'), 'en': 'Bogatovo'}, '35967395':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u0420\u043e\u0441\u0438\u0446\u0430'), 'en': 'Gorna Rositsa'}, '35967396':{'bg': u('\u0411\u0435\u0440\u0438\u0435\u0432\u043e'), 'en': 'Berievo'}, '35967397':{'bg': u('\u0420\u044f\u0445\u043e\u0432\u0446\u0438\u0442\u0435'), 'en': 'Ryahovtsite'}, '35967390':{'bg': u('\u0428\u0443\u043c\u0430\u0442\u0430'), 'en': 'Shumata'}, '35967391':{'bg': u('\u0421\u0442\u043e\u043b\u044a\u0442'), 'en': 'Stolat'}, '35967392':{'bg': u('\u042f\u0432\u043e\u0440\u0435\u0446'), 'en': 'Yavorets'}, '35967393':{'bg': u('\u0414\u0443\u0448\u0435\u0432\u043e'), 'en': 'Dushevo'}, '35967398':{'bg': u('\u0414\u0430\u043c\u044f\u043d\u043e\u0432\u043e'), 'en': 'Damyanovo'}, '35967399':{'bg': u('\u041c\u0430\u043b\u043a\u0438 \u0412\u044a\u0440\u0448\u0435\u0446'), 'en': 'Malki Varshets'}, '3599529':{'bg': u('\u0411\u043e\u0440\u043e\u0432\u0446\u0438'), 'en': 'Borovtsi'}, '441885':{'en': 'Pencombe'}, '441884':{'en': 'Tiverton'}, '441887':{'en': 'Aberfeldy'}, '441886':{'en': 'Bromyard (Knightwick/Leigh Sinton)'}, '441880':{'en': 'Tarbert'}, '441883':{'en': 'Caterham'}, '441882':{'en': 'Kinloch Rannoch'}, '4415399':{'en': 'Kendal'}, '441889':{'en': 'Rugeley'}, '441888':{'en': 'Turriff'}, '433843':{'de': 'Sankt Michael in Obersteiermark', 'en': 'St. Michael in Obersteiermark'}, '3359638':{'en': 'Le Robert', 'fr': 'Le Robert'}, '3359639':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3593648':{'bg': u('\u0413\u043e\u043b\u044f\u043c\u043e \u041a\u0430\u043c\u0435\u043d\u044f\u043d\u0435'), 'en': 'Golyamo Kamenyane'}, '3593641':{'bg': u('\u041a\u0440\u0443\u043c\u043e\u0432\u0433\u0440\u0430\u0434'), 'en': 'Krumovgrad'}, '3593643':{'bg': u('\u0413\u043e\u043b\u044f\u043c\u0430 \u0427\u0438\u043d\u043a\u0430'), 'en': 'Golyama Chinka'}, '3593642':{'bg': u('\u041f\u043e\u0442\u043e\u0447\u043d\u0438\u0446\u0430'), 'en': 'Potochnitsa'}, '3593645':{'bg': u('\u0410\u0432\u0440\u0435\u043d, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Avren, Kardzh.'}, '3593644':{'bg': u('\u0415\u0433\u0440\u0435\u043a'), 'en': 'Egrek'}, '3593647':{'bg': u('\u0427\u0435\u0440\u043d\u0438\u0447\u0435\u0432\u043e, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Chernichevo, Kardzh.'}, '3593646':{'bg': u('\u0422\u043e\u043a\u0430\u0447\u043a\u0430'), 'en': 'Tokachka'}, '3355990':{'en': 'Pau', 'fr': 'Pau'}, '3355993':{'en': 'Ustaritz', 'fr': 'Ustaritz'}, '3355992':{'en': 'Pau', 'fr': 'Pau'}, '3355998':{'en': 'Pau', 'fr': 'Pau'}, '4419642':{'en': 'Hornsea'}, '3593025':{'bg': u('\u0411\u0430\u043d\u0438\u0442\u0435'), 'en': 'Banite'}, '3593024':{'bg': u('\u0422\u044a\u0440\u044a\u043d'), 'en': 'Taran'}, '3593027':{'bg': u('\u0421\u043b\u0430\u0432\u0435\u0439\u043d\u043e'), 'en': 'Slaveyno'}, '3593026':{'bg': u('\u0421\u043c\u0438\u043b\u044f\u043d'), 'en': 'Smilyan'}, '3593020':{'bg': u('\u0414\u0430\u0432\u0438\u0434\u043a\u043e\u0432\u043e'), 'en': 'Davidkovo'}, '3593023':{'bg': u('\u041c\u043e\u043c\u0447\u0438\u043b\u043e\u0432\u0446\u0438'), 'en': 'Momchilovtsi'}, '3593022':{'bg': u('\u0412\u0438\u0435\u0432\u043e'), 'en': 'Vievo'}, '34925':{'en': 'Toledo', 'es': 'Toledo'}, '34924':{'en': 'Badajoz', 'es': 'Badajoz'}, '3329882':{'en': u('Pont-l\'Abb\u00e9'), 'fr': u('Pont-l\'Abb\u00e9')}, '34926':{'en': 'Ciudad Real', 'es': 'Ciudad Real'}, '3593029':{'bg': u('\u041f\u0435\u0442\u043a\u043e\u0432\u043e, \u0421\u043c\u043e\u043b.'), 'en': 'Petkovo, Smol.'}, '3593028':{'bg': u('\u0410\u0440\u0434\u0430'), 'en': 'Arda'}, '34923':{'en': 'Salamanca', 'es': 'Salamanca'}, '34922':{'en': 'Tenerife', 'es': 'Tenerife'}, '3332765':{'en': 'Maubeuge', 'fr': 'Maubeuge'}, '3332764':{'en': 'Maubeuge', 'fr': 'Maubeuge'}, '3332761':{'en': 'Avesnes-sur-Helpe', 'fr': 'Avesnes-sur-Helpe'}, '3332760':{'en': 'Fourmies', 'fr': 'Fourmies'}, '3332763':{'en': 'Hautmont', 'fr': 'Hautmont'}, '3332762':{'en': 'Maubeuge', 'fr': 'Maubeuge'}, '437744':{'de': 'Munderfing', 'en': 'Munderfing'}, '434263':{'de': u('H\u00fcttenberg'), 'en': u('H\u00fcttenberg')}, '434262':{'de': 'Treibach', 'en': 'Treibach'}, '434265':{'de': 'Weitensfeld im Gurktal', 'en': 'Weitensfeld im Gurktal'}, '434264':{'de': 'Klein Sankt Paul', 'en': 'Klein St. Paul'}, '434267':{'de': 'Metnitz', 'en': 'Metnitz'}, '434266':{'de': u('Stra\u00dfburg'), 'en': 'Strassburg'}, '434269':{'de': 'Flattnitz', 'en': 'Flattnitz'}, '434268':{'de': 'Friesach', 'en': 'Friesach'}, '432725':{'de': 'Frankenfels', 'en': 'Frankenfels'}, '3332505':{'en': 'Saint-Dizier', 'fr': 'Saint-Dizier'}, '3344271':{'en': 'La Ciotat', 'fr': 'La Ciotat'}, '3332507':{'en': 'Saint-Dizier', 'fr': 'Saint-Dizier'}, '3332506':{'en': 'Saint-Dizier', 'fr': 'Saint-Dizier'}, '3332501':{'en': 'Chaumont', 'fr': 'Chaumont'}, '3332503':{'en': 'Chaumont', 'fr': 'Chaumont'}, '3595395':{'bg': u('\u0427\u0435\u0440\u043d\u043e\u043e\u043a\u043e\u0432\u043e, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Chernookovo, Shumen'}, '3595394':{'bg': u('\u0411\u044f\u043b\u0430 \u0440\u0435\u043a\u0430, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Byala reka, Shumen'}, '3595397':{'bg': u('\u041c\u0435\u0442\u043e\u0434\u0438\u0435\u0432\u043e, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Metodievo, Shumen'}, '3595396':{'bg': u('\u041b\u043e\u0432\u0435\u0446, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Lovets, Shumen'}, '3595391':{'bg': u('\u0412\u044a\u0440\u0431\u0438\u0446\u0430, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Varbitsa, Shumen'}, '441462':{'en': 'Hitchin'}, '3595393':{'bg': u('\u0418\u0432\u0430\u043d\u043e\u0432\u043e, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Ivanovo, Shumen'}, '3595392':{'bg': u('\u041c\u0435\u043d\u0433\u0438\u0448\u0435\u0432\u043e'), 'en': 'Mengishevo'}, '441469':{'en': 'Killingholme'}, '437684':{'de': 'Frankenmarkt', 'en': 'Frankenmarkt'}, '437682':{'de': u('V\u00f6cklamarkt'), 'en': u('V\u00f6cklamarkt')}, '437683':{'de': 'Frankenburg am Hausruck', 'en': 'Frankenburg am Hausruck'}, '3594554':{'bg': u('\u0422\u0440\u0430\u043f\u043e\u043a\u043b\u043e\u0432\u043e'), 'en': 'Trapoklovo'}, '3594556':{'bg': u('\u0421\u043e\u0442\u0438\u0440\u044f'), 'en': 'Sotirya'}, '3594557':{'bg': u('\u0411\u0438\u043a\u043e\u0432\u043e'), 'en': 'Bikovo'}, '3594551':{'bg': u('\u0411\u044f\u043b\u0430, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Byala, Sliven'}, '3594552':{'bg': u('\u0421\u0442\u0430\u0440\u0430 \u0440\u0435\u043a\u0430, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Stara reka, Sliven'}, '3594553':{'bg': u('\u0420\u0430\u043a\u043e\u0432\u043e, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Rakovo, Sliven'}, '441790':{'en': 'Spilsby'}, '441793':{'en': 'Swindon'}, '441792':{'en': 'Swansea'}, '441795':{'en': 'Sittingbourne'}, '441794':{'en': 'Romsey'}, '441797':{'en': 'Rye'}, '441796':{'en': 'Pitlochry'}, '441799':{'en': 'Saffron Walden'}, '441798':{'en': 'Pulborough'}, '3324151':{'en': 'Saumur', 'fr': 'Saumur'}, '3324150':{'en': 'Saumur', 'fr': 'Saumur'}, '3324153':{'en': 'Saumur', 'fr': 'Saumur'}, '3598629':{'bg': u('\u0421\u043c\u0438\u043b\u0435\u0446, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Smilets, Silistra'}, '3598626':{'bg': u('\u0421\u0440\u0435\u0434\u0438\u0449\u0435, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Sredishte, Silistra'}, '3598627':{'bg': u('\u0411\u0430\u0431\u0443\u043a'), 'en': 'Babuk'}, '3598624':{'bg': u('\u041a\u0430\u043b\u0438\u043f\u0435\u0442\u0440\u043e\u0432\u043e'), 'en': 'Kalipetrovo'}, '3598625':{'bg': u('\u041e\u0432\u0435\u043d'), 'en': 'Oven'}, '3324159':{'en': u('Dou\u00e9-la-Fontaine'), 'fr': u('Dou\u00e9-la-Fontaine')}, '3324158':{'en': 'Cholet', 'fr': 'Cholet'}, '35295':{'de': 'Wiltz', 'en': 'Wiltz', 'fr': 'Wiltz'}, '35297':{'de': 'Huldingen', 'en': 'Huldange', 'fr': 'Huldange'}, '35292':{'de': 'Kanton Clerf/Fischbach/Hosingen', 'en': 'Clervaux/Fischbach/Hosingen', 'fr': 'Clervaux/Fischbach/Hosingen'}, '39099':{'en': 'Taranto'}, '39095':{'en': 'Catania', 'it': 'Catania'}, '35299':{'de': 'Ulflingen', 'en': 'Troisvierges', 'fr': 'Troisvierges'}, '39090':{'en': 'Messina', 'it': 'Messina'}, '39091':{'en': 'Palermo', 'it': 'Palermo'}, '3355595':{'en': 'Meymac', 'fr': 'Meymac'}, '354561':{'en': u('Reykjav\u00edk/Vesturb\u00e6r/Mi\u00f0b\u00e6rinn')}, '354562':{'en': u('Reykjav\u00edk/Vesturb\u00e6r/Mi\u00f0b\u00e6rinn')}, '35931993':{'bg': u('\u0421\u044a\u0440\u043d\u0435\u0433\u043e\u0440'), 'en': 'Sarnegor'}, '35931992':{'bg': u('\u041f\u044a\u0434\u0430\u0440\u0441\u043a\u043e'), 'en': 'Padarsko'}, '35931995':{'bg': u('\u0421\u0442\u0440\u0435\u043b\u0446\u0438, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Streltsi, Plovdiv'}, '35931997':{'bg': u('\u0417\u043b\u0430\u0442\u043e\u0441\u0435\u043b'), 'en': 'Zlatosel'}, '35931996':{'bg': u('\u0421\u0432\u0435\u0436\u0435\u043d'), 'en': 'Svezhen'}, '35931998':{'bg': u('\u0427\u043e\u0431\u0430'), 'en': 'Choba'}, '3355848':{'en': 'Vieux-Boucau-les-Bains', 'fr': 'Vieux-Boucau-les-Bains'}, '435358':{'de': 'Ellmau', 'en': 'Ellmau'}, '435359':{'de': 'Hochfilzen', 'en': 'Hochfilzen'}, '435352':{'de': 'Sankt Johann in Tirol', 'en': 'St. Johann in Tirol'}, '435353':{'de': 'Waidring', 'en': 'Waidring'}, '3338695':{'en': 'Sens', 'fr': 'Sens'}, '3338694':{'en': 'Auxerre', 'fr': 'Auxerre'}, '3338693':{'en': 'Nevers', 'fr': 'Nevers'}, '3338692':{'en': 'Migennes', 'fr': 'Migennes'}, '435354':{'de': 'Fieberbrunn', 'en': 'Fieberbrunn'}, '435355':{'de': 'Jochberg', 'en': 'Jochberg'}, '35953436':{'bg': u('\u0427\u0435\u0440\u043d\u043e\u0433\u043b\u0430\u0432\u0446\u0438'), 'en': 'Chernoglavtsi'}, '35953437':{'bg': u('\u0413\u0430\u0431\u0440\u0438\u0446\u0430, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Gabritsa, Shumen'}, '35953434':{'bg': u('\u042f\u0441\u0435\u043d\u043a\u043e\u0432\u043e'), 'en': 'Yasenkovo'}, '35953435':{'bg': u('\u0418\u0437\u0433\u0440\u0435\u0432, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Izgrev, Shumen'}, '3347207':{'en': 'Lyon', 'fr': 'Lyon'}, '3347204':{'en': 'Vaulx-en-Velin', 'fr': 'Vaulx-en-Velin'}, '3347205':{'en': u('D\u00e9cines-Charpieu'), 'fr': u('D\u00e9cines-Charpieu')}, '3355841':{'en': 'Soustons', 'fr': 'Soustons'}, '3347200':{'en': 'Lyon', 'fr': 'Lyon'}, '3347201':{'en': 'Rillieux-la-Pape', 'fr': 'Rillieux-la-Pape'}, '3347208':{'en': u('Neuville-sur-Sa\u00f4ne'), 'fr': u('Neuville-sur-Sa\u00f4ne')}, '3347209':{'en': 'Saint-Priest', 'fr': 'Saint-Priest'}, '3596158':{'bg': u('\u0421\u0440\u0435\u0434\u043d\u0438 \u043a\u043e\u043b\u0438\u0431\u0438'), 'en': 'Sredni kolibi'}, '3596156':{'bg': u('\u0420\u043e\u0434\u0438\u043d\u0430'), 'en': 'Rodina'}, '3596157':{'bg': u('\u0421\u043b\u0438\u0432\u043e\u0432\u0438\u0446\u0430'), 'en': 'Slivovitsa'}, '3596154':{'bg': u('\u0411\u0443\u0439\u043d\u043e\u0432\u0446\u0438'), 'en': 'Buynovtsi'}, '3596155':{'bg': u('\u041a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u0438\u043d'), 'en': 'Konstantin'}, '3596152':{'bg': u('\u0411\u0435\u0431\u0440\u043e\u0432\u043e'), 'en': 'Bebrovo'}, '3596151':{'bg': u('\u0415\u043b\u0435\u043d\u0430, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Elena, V. Tarnovo'}, '3349080':{'en': 'Avignon', 'fr': 'Avignon'}, '3347067':{'en': 'Bourbon-l\'Archambault', 'fr': 'Bourbon-l\'Archambault'}, '3347064':{'en': 'Commentry', 'fr': 'Commentry'}, '3351607':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3593320':{'bg': u('\u041e\u0440\u0435\u0448\u0435\u0446, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Oreshets, Plovdiv'}, '359707':{'bg': u('\u0421\u0430\u043f\u0430\u0440\u0435\u0432\u0430 \u0431\u0430\u043d\u044f'), 'en': 'Sapareva banya'}, '3593321':{'bg': u('\u0422\u043e\u043f\u043e\u043b\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Topolovo, Plovdiv'}, '359702':{'bg': u('\u0411\u043e\u0431\u043e\u0432 \u0434\u043e\u043b'), 'en': 'Bobov dol'}, '359701':{'bg': u('\u0414\u0443\u043f\u043d\u0438\u0446\u0430'), 'en': 'Dupnitsa'}, '3329056':{'en': 'Rennes', 'fr': 'Rennes'}, '3339023':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3339022':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3339020':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '35943616':{'bg': u('\u0422\u0443\u0440\u0438\u044f'), 'en': 'Turia'}, '390578':{'it': 'Chianciano Terme'}, '390577':{'en': 'Siena', 'it': 'Siena'}, '390574':{'en': 'Prato', 'it': 'Prato'}, '390575':{'en': 'Arezzo', 'it': 'Arezzo'}, '390572':{'it': 'Montecatini Terme'}, '390573':{'it': 'Pistoia'}, '390571':{'it': 'Empoli'}, '3338932':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3348805':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3338426':{'en': 'Belfort', 'fr': 'Belfort'}, '3323598':{'en': 'Rouen', 'fr': 'Rouen'}, '3323595':{'en': 'Yvetot', 'fr': 'Yvetot'}, '3323597':{'en': 'Saint-Valery-en-Caux', 'fr': 'Saint-Valery-en-Caux'}, '3323590':{'en': 'Gournay-en-Bray', 'fr': 'Gournay-en-Bray'}, '3323591':{'en': 'Barentin', 'fr': 'Barentin'}, '3323592':{'en': 'Barentin', 'fr': 'Barentin'}, '3347246':{'en': u('Pont-de-Ch\u00e9ruy'), 'fr': u('Pont-de-Ch\u00e9ruy')}, '3349318':{'en': 'Nice', 'fr': 'Nice'}, '3349319':{'en': 'Saint-Laurent-du-Var', 'fr': 'Saint-Laurent-du-Var'}, '3349316':{'en': 'Nice', 'fr': 'Nice'}, '3349317':{'en': 'Nice', 'fr': 'Nice'}, '3349314':{'en': 'Saint-Laurent-du-Var', 'fr': 'Saint-Laurent-du-Var'}, '3349312':{'en': 'Valbonne', 'fr': 'Valbonne'}, '3349313':{'en': 'Nice', 'fr': 'Nice'}, '3347247':{'en': 'Chassieu', 'fr': 'Chassieu'}, '3751641':{'be': u('\u0416\u0430\u0431\u0456\u043d\u043a\u0430, \u0411\u0440\u044d\u0441\u0446\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Zhabinka, Brest Region', 'ru': u('\u0416\u0430\u0431\u0438\u043d\u043a\u0430, \u0411\u0440\u0435\u0441\u0442\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751643':{'be': u('\u0411\u044f\u0440\u043e\u0437\u0430, \u0411\u0440\u044d\u0441\u0446\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Bereza, Brest Region', 'ru': u('\u0411\u0435\u0440\u0435\u0437\u0430, \u0411\u0440\u0435\u0441\u0442\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751642':{'be': u('\u041a\u043e\u0431\u0440\u044b\u043d'), 'en': 'Kobryn', 'ru': u('\u041a\u043e\u0431\u0440\u0438\u043d')}, '3751645':{'be': u('\u0406\u0432\u0430\u0446\u044d\u0432\u0456\u0447\u044b, \u0411\u0440\u044d\u0441\u0446\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Ivatsevichi, Brest Region', 'ru': u('\u0418\u0432\u0430\u0446\u0435\u0432\u0438\u0447\u0438, \u0411\u0440\u0435\u0441\u0442\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751644':{'be': u('\u0414\u0440\u0430\u0433\u0456\u0447\u044b\u043d, \u0411\u0440\u044d\u0441\u0446\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Drogichin, Brest Region', 'ru': u('\u0414\u0440\u043e\u0433\u0438\u0447\u0438\u043d, \u0411\u0440\u0435\u0441\u0442\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751647':{'be': u('\u041b\u0443\u043d\u0456\u043d\u0435\u0446, \u0411\u0440\u044d\u0441\u0446\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Luninets, Brest Region', 'ru': u('\u041b\u0443\u043d\u0438\u043d\u0435\u0446, \u0411\u0440\u0435\u0441\u0442\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751646':{'be': u('\u0413\u0430\u043d\u0446\u0430\u0432\u0456\u0447\u044b, \u0411\u0440\u044d\u0441\u0446\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Gantsevichi, Brest Region', 'ru': u('\u0413\u0430\u043d\u0446\u0435\u0432\u0438\u0447\u0438, \u0411\u0440\u0435\u0441\u0442\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '37041':{'en': u('\u0160iauliai')}, '37046':{'en': u('Klaip\u0117da')}, '37045':{'en': u('Panev\u0117\u017eys')}, '331755':{'en': 'Paris', 'fr': 'Paris'}, '3329787':{'en': 'Lorient', 'fr': 'Lorient'}, '432959':{'de': 'Sitzendorf an der Schmida', 'en': 'Sitzendorf an der Schmida'}, '432958':{'de': 'Maissau', 'en': 'Maissau'}, '432955':{'de': u('Gro\u00dfweikersdorf'), 'en': 'Grossweikersdorf'}, '432954':{'de': u('G\u00f6llersdorf'), 'en': u('G\u00f6llersdorf')}, '432957':{'de': 'Hohenwarth', 'en': 'Hohenwarth'}, '432956':{'de': 'Ziersdorf', 'en': 'Ziersdorf'}, '432951':{'de': 'Guntersdorf', 'en': 'Guntersdorf'}, '432953':{'de': 'Nappersdorf', 'en': 'Nappersdorf'}, '432952':{'de': 'Hollabrunn', 'en': 'Hollabrunn'}, '3355506':{'en': 'Limoges', 'fr': 'Limoges'}, '433579':{'de': u('P\u00f6ls'), 'en': u('P\u00f6ls')}, '3355504':{'en': 'Limoges', 'fr': 'Limoges'}, '3355505':{'en': 'Limoges', 'fr': 'Limoges'}, '3355502':{'en': 'Saint-Junien', 'fr': 'Saint-Junien'}, '3355503':{'en': 'Rochechouart', 'fr': 'Rochechouart'}, '3355501':{'en': 'Limoges', 'fr': 'Limoges'}, '433571':{'de': u('M\u00f6derbrugg'), 'en': u('M\u00f6derbrugg')}, '433572':{'de': 'Judenburg', 'en': 'Judenburg'}, '433573':{'de': 'Fohnsdorf', 'en': 'Fohnsdorf'}, '433574':{'de': 'Pusterwald', 'en': 'Pusterwald'}, '433575':{'de': 'Sankt Johann am Tauern', 'en': 'St. Johann am Tauern'}, '3355508':{'en': 'Saint-Yrieix-la-Perche', 'fr': 'Saint-Yrieix-la-Perche'}, '433577':{'de': 'Zeltweg', 'en': 'Zeltweg'}, '3332952':{'en': u('Saint-Di\u00e9-des-Vosges'), 'fr': u('Saint-Di\u00e9-des-Vosges')}, '3324369':{'en': 'Laval', 'fr': 'Laval'}, '3332956':{'en': u('Saint-Di\u00e9-des-Vosges'), 'fr': u('Saint-Di\u00e9-des-Vosges')}, '3332957':{'en': 'Senones', 'fr': 'Senones'}, '3332955':{'en': u('Saint-Di\u00e9-des-Vosges'), 'fr': u('Saint-Di\u00e9-des-Vosges')}, '3324362':{'en': u('Sabl\u00e9-sur-Sarthe'), 'fr': u('Sabl\u00e9-sur-Sarthe')}, '3324363':{'en': 'Saint-Calais', 'fr': 'Saint-Calais'}, '3324360':{'en': u('La Fert\u00e9 Bernard'), 'fr': u('La Fert\u00e9 Bernard')}, '3324366':{'en': 'Laval', 'fr': 'Laval'}, '3324367':{'en': 'Laval', 'fr': 'Laval'}, '437219':{'de': u('Vorderwei\u00dfenbach'), 'en': 'Vorderweissenbach'}, '3594122':{'bg': u('\u0415\u043b\u0435\u043d\u0438\u043d\u043e'), 'en': 'Elenino'}, '437211':{'de': u('Reichenau im M\u00fchlkreis'), 'en': u('Reichenau im M\u00fchlkreis')}, '35996':{'bg': u('\u041c\u043e\u043d\u0442\u0430\u043d\u0430'), 'en': 'Montana'}, '437213':{'de': 'Bad Leonfelden', 'en': 'Bad Leonfelden'}, '35994':{'bg': u('\u0412\u0438\u0434\u0438\u043d'), 'en': 'Vidin'}, '437215':{'de': u('Hellmons\u00f6dt'), 'en': u('Hellmons\u00f6dt')}, '35992':{'bg': u('\u0412\u0440\u0430\u0446\u0430'), 'en': 'Vratsa'}, '437217':{'de': u('Sankt Veit im M\u00fchlkreis'), 'en': u('St. Veit im M\u00fchlkreis')}, '437216':{'de': 'Helfenberg', 'en': 'Helfenberg'}, '433682':{'de': 'Stainach', 'en': 'Stainach'}, '433683':{'de': 'Donnersbach', 'en': 'Donnersbach'}, '433680':{'de': 'Donnersbachwald', 'en': 'Donnersbachwald'}, '433686':{'de': 'Haus', 'en': 'Haus'}, '433687':{'de': 'Schladming', 'en': 'Schladming'}, '433684':{'de': 'Sankt Martin am Grimming', 'en': 'St. Martin am Grimming'}, '433685':{'de': u('Gr\u00f6bming'), 'en': u('Gr\u00f6bming')}, '433688':{'de': 'Tauplitz', 'en': 'Tauplitz'}, '433689':{'de': u('Sankt Nikolai im S\u00f6lktal'), 'en': u('St. Nikolai im S\u00f6lktal')}, '432632':{'de': 'Pernitz', 'en': 'Pernitz'}, '3356268':{'en': 'Lectoure', 'fr': 'Lectoure'}, '4212':{'en': 'Bratislava'}, '3356267':{'en': 'Gimont', 'fr': 'Gimont'}, '3356262':{'en': 'Samatan', 'fr': 'Samatan'}, '3356263':{'en': 'Auch', 'fr': 'Auch'}, '3356260':{'en': 'Auch', 'fr': 'Auch'}, '3356261':{'en': 'Auch', 'fr': 'Auch'}, '4416866':{'en': 'Newtown'}, '3325144':{'en': 'La Roche sur Yon', 'fr': 'La Roche sur Yon'}, '3325147':{'en': 'La Roche sur Yon', 'fr': 'La Roche sur Yon'}, '4416867':{'en': 'Llanidloes'}, '3325149':{'en': 'Challans', 'fr': 'Challans'}, '4416864':{'en': 'Llanidloes'}, '4416865':{'en': 'Newtown'}, '4416862':{'en': 'Llanidloes'}, '35371':{'en': 'Sligo/Manorhamilton/Carrick-on-Shannon'}, '4416860':{'en': 'Newtown/Llanidloes'}, '3344278':{'en': 'Rognac', 'fr': 'Rognac'}, '3344279':{'en': 'Vitrolles', 'fr': 'Vitrolles'}, '3344276':{'en': u('Ch\u00e2teauneuf-les-Martigues'), 'fr': u('Ch\u00e2teauneuf-les-Martigues')}, '3344277':{'en': 'Marignane', 'fr': 'Marignane'}, '3344274':{'en': u('Berre-l\'\u00c9tang'), 'fr': u('Berre-l\'\u00c9tang')}, '3344275':{'en': 'Vitrolles', 'fr': 'Vitrolles'}, '3344272':{'en': 'Aubagne', 'fr': 'Aubagne'}, '3344273':{'en': 'Carnoux-en-Provence', 'fr': 'Carnoux-en-Provence'}, '3344270':{'en': 'Aubagne', 'fr': 'Aubagne'}, '3324001':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '390331':{'en': 'Varese', 'it': 'Busto Arsizio'}, '390332':{'en': 'Varese', 'it': 'Varese'}, '351265':{'en': u('Set\u00fabal'), 'pt': u('Set\u00fabal')}, '351266':{'en': u('\u00c9vora'), 'pt': u('\u00c9vora')}, '351261':{'en': 'Torres Vedras', 'pt': 'Torres Vedras'}, '351263':{'en': 'Vila Franca de Xira', 'pt': 'Vila Franca de Xira'}, '351262':{'en': 'Caldas da Rainha', 'pt': 'Caldas da Rainha'}, '351269':{'en': u('Santiago do Cac\u00e9m'), 'pt': u('Santiago do Cac\u00e9m')}, '351268':{'en': 'Estremoz', 'pt': 'Estremoz'}, '373552':{'en': 'Bender', 'ro': 'Bender', 'ru': u('\u0411\u0435\u043d\u0434\u0435\u0440')}, '441685':{'en': 'Merthyr Tydfil'}, '373557':{'en': 'Slobozia', 'ro': 'Slobozia', 'ru': u('\u0421\u043b\u043e\u0431\u043e\u0437\u0438\u044f')}, '373555':{'en': 'Ribnita', 'ro': u('R\u00eebni\u0163a'), 'ru': u('\u0420\u044b\u0431\u043d\u0438\u0446\u0430')}, '371684':{'en': u('Liep\u0101ja')}, '441638':{'en': 'Newmarket'}, '441639':{'en': 'Neath'}, '441633':{'en': 'Newport'}, '441630':{'en': 'Market Drayton'}, '441631':{'en': 'Oban'}, '441636':{'en': 'Newark-on-Trent'}, '441637':{'en': 'Newquay'}, '441634':{'en': 'Medway'}, '441635':{'en': 'Newbury'}, '432638':{'de': 'Winzendorf-Muthmannsdorf', 'en': 'Winzendorf-Muthmannsdorf'}, '355398':{'en': u('Sevaster/Brataj/Hore-Vranisht, Vlor\u00eb')}, '355395':{'en': u('Novosel\u00eb, Vlor\u00eb')}, '355394':{'en': u('Qend\u00ebr, Vlor\u00eb')}, '355397':{'en': u('Vllahin\u00eb/Kote, Vlor\u00eb')}, '355396':{'en': u('Shushic\u00eb/Armen, Vlor\u00eb')}, '355391':{'en': u('Orikum, Vlor\u00eb')}, '355393':{'en': u('Himar\u00eb, Vlor\u00eb')}, '355392':{'en': u('Selenic\u00eb, Vlor\u00eb')}, '35941179':{'bg': u('\u0425\u0430\u043d \u0410\u0441\u043f\u0430\u0440\u0443\u0445\u043e\u0432\u043e'), 'en': 'Han Asparuhovo'}, '436483':{'de': u('G\u00f6riach'), 'en': u('G\u00f6riach')}, '37426791':{'am': u('\u0546\u0561\u057e\u0578\u0582\u0580'), 'en': 'Navur', 'ru': u('\u041d\u0430\u0432\u0443\u0440')}, '35977229':{'bg': u('\u0413\u044a\u043b\u044a\u0431\u043d\u0438\u043a'), 'en': 'Galabnik'}, '37426797':{'am': u('\u0546\u0578\u0580\u0561\u0577\u0565\u0576'), 'en': 'Norashen', 'ru': u('\u041d\u043e\u0440\u0430\u0448\u0435\u043d')}, '37426794':{'am': u('\u0539\u0578\u057e\u0578\u0582\u0566'), 'en': 'Tovuz', 'ru': u('\u0422\u043e\u0432\u0443\u0437')}, '436484':{'de': 'Lessach', 'en': 'Lessach'}, '3336664':{'en': 'Lille', 'fr': 'Lille'}, '35977226':{'bg': u('\u0414\u0435\u0431\u0435\u043b\u0438 \u043b\u0430\u0433'), 'en': 'Debeli lag'}, '35977221':{'bg': u('\u041a\u043e\u043d\u0434\u043e\u0444\u0440\u0435\u0439'), 'en': 'Kondofrey'}, '35977222':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u0414\u0438\u043a\u0430\u043d\u044f'), 'en': 'Gorna Dikanya'}, '3343770':{'en': 'Lyon', 'fr': 'Lyon'}, '3355645':{'en': 'Pessac', 'fr': 'Pessac'}, '441248':{'en': 'Bangor (Gwynedd)'}, '432672':{'de': 'Berndorf', 'en': 'Berndorf'}, '441243':{'en': 'Chichester'}, '441242':{'en': 'Cheltenham'}, '441241':{'en': 'Arbroath'}, '441246':{'en': 'Chesterfield'}, '441245':{'en': 'Chelmsford'}, '441244':{'en': 'Chester'}, '3355644':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '35984768':{'bg': u('\u0421\u0438\u043d\u044f \u0432\u043e\u0434\u0430'), 'en': 'Sinya voda'}, '35984769':{'bg': u('\u0413\u043e\u0440\u043e\u0446\u0432\u0435\u0442'), 'en': 'Gorotsvet'}, '35984766':{'bg': u('\u041a\u0430\u043c\u0435\u043d\u0430\u0440, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Kamenar, Razgrad'}, '35984764':{'bg': u('\u0421\u0435\u0439\u0434\u043e\u043b'), 'en': 'Seydol'}, '35984765':{'bg': u('\u0412\u0435\u0441\u0435\u043b\u0438\u043d\u0430'), 'en': 'Veselina'}, '35984763':{'bg': u('\u0411\u0435\u043b\u0438 \u041b\u043e\u043c'), 'en': 'Beli Lom'}, '35984760':{'bg': u('\u0422\u0440\u0430\u043f\u0438\u0449\u0435'), 'en': 'Trapishte'}, '35984761':{'bg': u('\u0413\u0440\u0430\u0434\u0438\u043d\u0430, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Gradina, Razgrad'}, '3354592':{'en': u('Angoul\u00eame'), 'fr': u('Angoul\u00eame')}, '3354593':{'en': u('Angoul\u00eame'), 'fr': u('Angoul\u00eame')}, '3354590':{'en': u('Angoul\u00eame'), 'fr': u('Angoul\u00eame')}, '3354591':{'en': u('Angoul\u00eame'), 'fr': u('Angoul\u00eame')}, '3354594':{'en': u('Angoul\u00eame'), 'fr': u('Angoul\u00eame')}, '3354595':{'en': u('Angoul\u00eame'), 'fr': u('Angoul\u00eame')}, '3354598':{'en': 'Chalais', 'fr': 'Chalais'}, '3338529':{'en': u('M\u00e2con'), 'fr': u('M\u00e2con')}, '3338528':{'en': 'La Clayette', 'fr': 'La Clayette'}, '3323291':{'en': u('Saint-\u00c9tienne-du-Rouvray'), 'fr': u('Saint-\u00c9tienne-du-Rouvray')}, '3323290':{'en': 'Dieppe', 'fr': 'Dieppe'}, '3323297':{'en': u('Neufch\u00e2tel-en-Bray'), 'fr': u('Neufch\u00e2tel-en-Bray')}, '3323296':{'en': 'Elbeuf', 'fr': 'Elbeuf'}, '3323294':{'en': 'Barentin', 'fr': 'Barentin'}, '3338521':{'en': u('M\u00e2con'), 'fr': u('M\u00e2con')}, '3338520':{'en': u('M\u00e2con'), 'fr': u('M\u00e2con')}, '3338522':{'en': u('M\u00e2con'), 'fr': u('M\u00e2con')}, '3338525':{'en': 'Marcigny', 'fr': 'Marcigny'}, '3338526':{'en': 'Chauffailles', 'fr': 'Chauffailles'}, '390961':{'en': 'Catanzaro', 'it': 'Catanzaro'}, '390963':{'en': 'Vibo Valentia', 'it': 'Vibo Valentia'}, '390962':{'en': 'Crotone', 'it': 'Crotone'}, '3349811':{'en': u('Saint-Rapha\u00ebl'), 'fr': u('Saint-Rapha\u00ebl')}, '3349810':{'en': 'Draguignan', 'fr': 'Draguignan'}, '390967':{'it': 'Soverato'}, '3349812':{'en': u('Fr\u00e9jus'), 'fr': u('Fr\u00e9jus')}, '390968':{'it': 'Lamezia Terme'}, '3593623':{'bg': u('\u0411\u043e\u0439\u043d\u043e'), 'en': 'Boyno'}, '3593622':{'bg': u('\u0421\u0442\u0440\u0435\u043c\u0446\u0438'), 'en': 'Stremtsi'}, '3593626':{'bg': u('\u041f\u0435\u0440\u043f\u0435\u0440\u0435\u043a'), 'en': 'Perperek'}, '3593625':{'bg': u('\u0428\u0438\u0440\u043e\u043a\u043e \u043f\u043e\u043b\u0435'), 'en': 'Shiroko pole'}, '3593624':{'bg': u('\u0427\u0438\u0444\u043b\u0438\u043a, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Chiflik, Kardzh.'}, '3593629':{'bg': u('\u041c\u043e\u0441\u0442'), 'en': 'Most'}, '3593628':{'bg': u('\u041c\u0438\u043b\u0430\u0434\u0438\u043d\u043e\u0432\u043e'), 'en': 'Miladinovo'}, '3355977':{'en': 'Lescar', 'fr': 'Lescar'}, '3355974':{'en': 'Anglet', 'fr': 'Anglet'}, '3355972':{'en': 'Lons', 'fr': 'Lons'}, '3355970':{'en': 'Hasparren', 'fr': 'Hasparren'}, '390385':{'it': 'Stradella'}, '390384':{'it': 'Mortara'}, '390386':{'it': 'Ostiglia'}, '390381':{'it': 'Vigevano'}, '390383':{'it': 'Voghera'}, '390382':{'en': 'Pavia', 'it': 'Pavia'}, '35941173':{'bg': u('\u0411\u0440\u0430\u0442\u044f \u041a\u0443\u043d\u0447\u0435\u0432\u0438'), 'en': 'Bratya Kunchevi'}, '3752159':{'be': u('\u0420\u0430\u0441\u043e\u043d\u044b, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Rossony, Vitebsk Region', 'ru': u('\u0420\u043e\u0441\u0441\u043e\u043d\u044b, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '434248':{'de': 'Treffen', 'en': 'Treffen'}, '434243':{'de': 'Bodensdorf', 'en': 'Bodensdorf'}, '434242':{'de': 'Villach', 'en': 'Villach'}, '434240':{'de': 'Bad Kleinkirchheim', 'en': 'Bad Kleinkirchheim'}, '434247':{'de': 'Afritz', 'en': 'Afritz'}, '434246':{'de': 'Radenthein', 'en': 'Radenthein'}, '3355526':{'en': 'Tulle', 'fr': 'Tulle'}, '434244':{'de': 'Bad Bleiberg', 'en': 'Bad Bleiberg'}, '3593104':{'bg': u('\u042f\u0433\u043e\u0434\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Yagodovo, Plovdiv'}, '37246':{'en': u('K\u00e4rdla')}, '441249':{'en': 'Chippenham'}, '441400':{'en': 'Honington'}, '441403':{'en': 'Horsham'}, '441405':{'en': 'Goole'}, '441404':{'en': 'Honiton'}, '441407':{'en': 'Holyhead'}, '441406':{'en': 'Holbeach'}, '441409':{'en': 'Holsworthy'}, '441408':{'en': 'Golspie'}, '3598424':{'bg': u('\u0426\u0430\u0440 \u041a\u0430\u043b\u043e\u044f\u043d, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Tsar Kaloyan, Razgrad'}, '3317852':{'en': 'Versailles', 'fr': 'Versailles'}, '3317853':{'en': u('Asni\u00e8res-sur-Seine'), 'fr': u('Asni\u00e8res-sur-Seine')}, '3317854':{'en': u('Cr\u00e9teil'), 'fr': u('Cr\u00e9teil')}, '3334476':{'en': 'Thourotte', 'fr': 'Thourotte'}, '3595119':{'bg': u('\u0418\u0433\u043d\u0430\u0442\u0438\u0435\u0432\u043e'), 'en': 'Ignatievo'}, '3334474':{'en': 'Nogent-sur-Oise', 'fr': 'Nogent-sur-Oise'}, '3334473':{'en': 'Liancourt', 'fr': 'Liancourt'}, '3334472':{'en': 'Pont-Sainte-Maxence', 'fr': 'Pont-Sainte-Maxence'}, '3334471':{'en': 'Nogent-sur-Oise', 'fr': 'Nogent-sur-Oise'}, '3334470':{'en': 'Pont-Sainte-Maxence', 'fr': 'Pont-Sainte-Maxence'}, '3595112':{'bg': u('\u0411\u0435\u043b\u043e\u0441\u043b\u0430\u0432'), 'en': 'Beloslav'}, '3595117':{'bg': u('\u0411\u043e\u0442\u0435\u0432\u043e, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Botevo, Varna'}, '3595116':{'bg': u('\u041a\u0440\u0443\u043c\u043e\u0432\u043e, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Krumovo, Varna'}, '3334479':{'en': 'Troissereux', 'fr': 'Troissereux'}, '3334478':{'en': u('Saint-Just-en-Chauss\u00e9e'), 'fr': u('Saint-Just-en-Chauss\u00e9e')}, '3598648':{'bg': u('\u0421\u0435\u043a\u0443\u043b\u043e\u0432\u043e'), 'en': 'Sekulovo'}, '3598649':{'bg': u('\u042f\u0440\u0435\u0431\u0438\u0446\u0430'), 'en': 'Yarebitsa'}, '4418475':{'en': 'Thurso'}, '4418474':{'en': 'Thurso'}, '4418473':{'en': 'Thurso'}, '4418472':{'en': 'Thurso'}, '4418471':{'en': 'Thurso/Tongue'}, '3338328':{'en': 'Nancy', 'fr': 'Nancy'}, '3338327':{'en': 'Nancy', 'fr': 'Nancy'}, '3598641':{'bg': u('\u041e\u043a\u043e\u0440\u0448'), 'en': 'Okorsh'}, '3338325':{'en': 'Ludres', 'fr': 'Ludres'}, '3338324':{'en': 'Liverdun', 'fr': 'Liverdun'}, '3338323':{'en': 'Velaine-en-Haye', 'fr': 'Velaine-en-Haye'}, '3338322':{'en': u('Bouxi\u00e8res-aux-Dames'), 'fr': u('Bouxi\u00e8res-aux-Dames')}, '3598646':{'bg': u('\u0412\u043e\u043a\u0438\u043b'), 'en': 'Vokil'}, '3598647':{'bg': u('\u041f\u0430\u0438\u0441\u0438\u0435\u0432\u043e'), 'en': 'Paisievo'}, '3332641':{'en': u('Vitry-le-Fran\u00e7ois'), 'fr': u('Vitry-le-Fran\u00e7ois')}, '3332646':{'en': 'Reims', 'fr': 'Reims'}, '3332647':{'en': 'Reims', 'fr': 'Reims'}, '435374':{'de': 'Walchsee', 'en': 'Walchsee'}, '3332354':{'en': 'Vailly-sur-Aisne', 'fr': 'Vailly-sur-Aisne'}, '435376':{'de': 'Thiersee', 'en': 'Thiersee'}, '42037':{'en': u('Plze\u0148 Region')}, '435372':{'de': 'Kufstein', 'en': 'Kufstein'}, '435373':{'de': 'Ebbs', 'en': 'Ebbs'}, '3332356':{'en': u('La F\u00e8re'), 'fr': u('La F\u00e8re')}, '3356520':{'en': 'Cahors', 'fr': 'Cahors'}, '3356523':{'en': 'Cahors', 'fr': 'Cahors'}, '3356522':{'en': 'Cahors', 'fr': 'Cahors'}, '3356527':{'en': 'Souillac', 'fr': 'Souillac'}, '3332824':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '3332825':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '3347260':{'en': 'Lyon', 'fr': 'Lyon'}, '3347261':{'en': 'Lyon', 'fr': 'Lyon'}, '3347265':{'en': 'Villeurbanne', 'fr': 'Villeurbanne'}, '3347266':{'en': 'Oullins', 'fr': 'Oullins'}, '3347267':{'en': 'Saint-Genis-Laval', 'fr': 'Saint-Genis-Laval'}, '3347268':{'en': 'Lyon', 'fr': 'Lyon'}, '3347269':{'en': 'Lyon', 'fr': 'Lyon'}, '3356768':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3629':{'en': 'Monor', 'hu': 'Monor'}, '3346680':{'en': u('Sommi\u00e8res'), 'fr': u('Sommi\u00e8res')}, '3346685':{'en': 'Saint-Jean-du-Gard', 'fr': 'Saint-Jean-du-Gard'}, '3346684':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346687':{'en': 'Saint-Gilles', 'fr': 'Saint-Gilles'}, '3346686':{'en': u('Al\u00e8s'), 'fr': u('Al\u00e8s')}, '3346689':{'en': u('Bagnols-sur-C\u00e8ze'), 'fr': u('Bagnols-sur-C\u00e8ze')}, '3346688':{'en': 'Vauvert', 'fr': 'Vauvert'}, '3623':{'en': u('Biatorb\u00e1gy'), 'hu': u('Biatorb\u00e1gy')}, '3622':{'en': u('Sz\u00e9kesfeh\u00e9rv\u00e1r'), 'hu': u('Sz\u00e9kesfeh\u00e9rv\u00e1r')}, '3625':{'en': 'Dunaujvaros', 'hu': u('Duna\u00fajv\u00e1ros')}, '3624':{'en': u('Szigetszentmikl\u00f3s'), 'hu': u('Szigetszentmikl\u00f3s')}, '3627':{'en': 'Vac', 'hu': u('V\u00e1c')}, '3626':{'en': 'Szentendre', 'hu': 'Szentendre'}, '3596138':{'bg': u('\u041d\u0435\u0434\u0430\u043d'), 'en': 'Nedan'}, '3599116':{'bg': u('\u041a\u043e\u0441\u0442\u0435\u043b\u0435\u0432\u043e'), 'en': 'Kostelevo'}, '3599115':{'bg': u('\u0427\u0438\u0440\u0435\u043d'), 'en': 'Chiren'}, '3599113':{'bg': u('\u041c\u0440\u0430\u043c\u043e\u0440\u0435\u043d'), 'en': 'Mramoren'}, '3599112':{'bg': u('\u0411\u0430\u043d\u0438\u0446\u0430'), 'en': 'Banitsa'}, '3599111':{'bg': u('\u0427\u0435\u043b\u043e\u043f\u0435\u043a'), 'en': 'Chelopek'}, '3329885':{'en': 'Landerneau', 'fr': 'Landerneau'}, '3596132':{'bg': u('\u041a\u0430\u0440\u0430\u0438\u0441\u0435\u043d'), 'en': 'Karaisen'}, '3596133':{'bg': u('\u041c\u0438\u0445\u0430\u043b\u0446\u0438'), 'en': 'Mihaltsi'}, '3596134':{'bg': u('\u0411\u044f\u043b\u0430 \u0447\u0435\u0440\u043a\u0432\u0430, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Byala cherkva, V. Tarnovo'}, '3596135':{'bg': u('\u0412\u044a\u0440\u0431\u043e\u0432\u043a\u0430'), 'en': 'Varbovka'}, '3596136':{'bg': u('\u0421\u0443\u0445\u0438\u043d\u0434\u043e\u043b'), 'en': 'Suhindol'}, '3596137':{'bg': u('\u0411\u0443\u0442\u043e\u0432\u043e'), 'en': 'Butovo'}, '3594583':{'bg': u('\u041a\u0438\u043f\u0438\u043b\u043e\u0432\u043e'), 'en': 'Kipilovo'}, '3594582':{'bg': u('\u0413\u0440\u0430\u0434\u0435\u0446, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Gradets, Sliven'}, '432674':{'de': u('Wei\u00dfenbach an der Triesting'), 'en': 'Weissenbach an der Triesting'}, '3594580':{'bg': u('\u0411\u043e\u0440\u0438\u043d\u0446\u0438'), 'en': 'Borintsi'}, '3594587':{'bg': u('\u042f\u0431\u043b\u0430\u043d\u043e\u0432\u043e'), 'en': 'Yablanovo'}, '3594585':{'bg': u('\u0416\u0435\u0440\u0430\u0432\u043d\u0430'), 'en': 'Zheravna'}, '3594584':{'bg': u('\u0422\u0438\u0447\u0430'), 'en': 'Ticha'}, '42038':{'en': 'South Bohemian Region'}, '3347884':{'en': 'Villeurbanne', 'fr': 'Villeurbanne'}, '3347885':{'en': 'Villeurbanne', 'fr': 'Villeurbanne'}, '3347886':{'en': 'Oullins', 'fr': 'Oullins'}, '3347887':{'en': u('Charbonni\u00e8res-les-Bains'), 'fr': u('Charbonni\u00e8res-les-Bains')}, '3347880':{'en': 'Vaulx-en-Velin', 'fr': 'Vaulx-en-Velin'}, '359725':{'bg': u('\u0415\u043b\u0438\u043d \u041f\u0435\u043b\u0438\u043d'), 'en': 'Elin Pelin'}, '359726':{'bg': u('\u0421\u0432\u043e\u0433\u0435'), 'en': 'Svoge'}, '3347883':{'en': 'Lyon', 'fr': 'Lyon'}, '359728':{'bg': u('\u0417\u043b\u0430\u0442\u0438\u0446\u0430'), 'en': 'Zlatitsa'}, '359729':{'bg': u('\u0413\u043e\u0434\u0435\u0447'), 'en': 'Godech'}, '3347888':{'en': 'Rillieux-la-Pape', 'fr': 'Rillieux-la-Pape'}, '3347889':{'en': 'Lyon', 'fr': 'Lyon'}, '433137':{'de': u('S\u00f6ding'), 'en': u('S\u00f6ding')}, '3329078':{'en': 'Rennes', 'fr': 'Rennes'}, '3522488':{'de': 'Mertzig/Wahl', 'en': 'Mertzig/Wahl', 'fr': 'Mertzig/Wahl'}, '3358134':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3522483':{'de': 'Vianden', 'en': 'Vianden', 'fr': 'Vianden'}, '3522481':{'de': u('Ettelbr\u00fcck/Reckange-sur-Mess'), 'en': 'Ettelbruck/Reckange-sur-Mess', 'fr': 'Ettelbruck/Reckange-sur-Mess'}, '3522480':{'de': 'Diekirch', 'en': 'Diekirch', 'fr': 'Diekirch'}, '3522487':{'de': 'Fels', 'en': 'Larochette', 'fr': 'Larochette'}, '3522485':{'de': 'Bissen/Roost', 'en': 'Bissen/Roost', 'fr': 'Bissen/Roost'}, '3522484':{'de': 'Han/Lesse', 'en': 'Han/Lesse', 'fr': 'Han/Lesse'}, '37424293':{'am': u('\u0547\u056b\u0580\u0561\u056f\u0561\u057e\u0561\u0576'), 'en': 'Shirakavan', 'ru': u('\u0428\u0438\u0440\u0430\u043a\u0430\u0432\u0430\u043d')}, '390734':{'en': 'Fermo', 'it': 'Fermo'}, '3349487':{'en': 'La Seyne sur Mer', 'fr': 'La Seyne sur Mer'}, '390736':{'it': 'Ascoli Piceno'}, '3349485':{'en': 'Draguignan', 'fr': 'Draguignan'}, '3349482':{'en': u('Saint-Rapha\u00ebl'), 'fr': u('Saint-Rapha\u00ebl')}, '3349483':{'en': u('Saint-Rapha\u00ebl'), 'fr': u('Saint-Rapha\u00ebl')}, '390732':{'en': 'Ancona', 'it': 'Fabriano'}, '3349481':{'en': u('Fr\u00e9jus'), 'fr': u('Fr\u00e9jus')}, '3349488':{'en': 'Sanary-sur-Mer', 'fr': 'Sanary-sur-Mer'}, '3349489':{'en': 'Toulon', 'fr': 'Toulon'}, '3522627':{'de': 'Belair, Luxemburg', 'en': 'Belair, Luxembourg', 'fr': 'Belair, Luxembourg'}, '3349379':{'en': 'Contes', 'fr': 'Contes'}, '3522625':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '3522623':{'de': 'Bad Mondorf', 'en': 'Mondorf-les-Bains', 'fr': 'Mondorf-les-Bains'}, '3522622':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '3522621':{'de': 'Weicherdingen', 'en': 'Weicherdange', 'fr': 'Weicherdange'}, '3349370':{'en': 'Grasse', 'fr': 'Grasse'}, '3349371':{'en': 'Nice', 'fr': 'Nice'}, '3349372':{'en': 'Nice', 'fr': 'Nice'}, '3349373':{'en': 'Cagnes-sur-Mer', 'fr': 'Cagnes-sur-Mer'}, '3349374':{'en': 'Antibes Juan les Pins', 'fr': 'Antibes Juan les Pins'}, '3349375':{'en': 'Mougins', 'fr': 'Mougins'}, '3522629':{'de': 'Luxemburg/Kockelscheuer', 'en': 'Luxembourg/Kockelscheuer', 'fr': 'Luxembourg/Kockelscheuer'}, '3349377':{'en': 'Roquefort-les-Pins', 'fr': 'Roquefort-les-Pins'}, '441988':{'en': 'Wigtown'}, '441989':{'en': 'Ross-on-Wye'}, '390341':{'en': 'Lecco', 'it': 'Lecco'}, '441985':{'en': 'Warminster'}, '441986':{'en': 'Bungay'}, '441987':{'en': 'Ebbsfleet'}, '441980':{'en': 'Amesbury'}, '441981':{'en': 'Wormbridge'}, '441982':{'en': 'Builth Wells'}, '441983':{'en': 'Isle of Wight'}, '432673':{'de': 'Altenmarkt an der Triesting', 'en': 'Altenmarkt an der Triesting'}, '3355605':{'en': u('Saint-M\u00e9dard-en-Jalles'), 'fr': u('Saint-M\u00e9dard-en-Jalles')}, '3594763':{'bg': u('\u0418\u0440\u0435\u0447\u0435\u043a\u043e\u0432\u043e'), 'en': 'Irechekovo'}, '3594762':{'bg': u('\u0412\u043e\u0434\u0435\u043d\u0438\u0447\u0430\u043d\u0435'), 'en': 'Vodenichane'}, '3594761':{'bg': u('\u0421\u0442\u0440\u0430\u043b\u0434\u0436\u0430'), 'en': 'Straldzha'}, '3594764':{'bg': u('\u041c\u0430\u043b\u0435\u043d\u043e\u0432\u043e'), 'en': 'Malenovo'}, '3594768':{'bg': u('\u0417\u0438\u043c\u043d\u0438\u0446\u0430, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Zimnitsa, Yambol'}, '4419641':{'en': 'Hornsea/Patrington'}, '433512':{'de': 'Knittelfeld', 'en': 'Knittelfeld'}, '433513':{'de': 'Bischoffeld', 'en': 'Bischoffeld'}, '3355604':{'en': 'Talence', 'fr': 'Talence'}, '433516':{'de': 'Kleinlobming', 'en': 'Kleinlobming'}, '433514':{'de': 'Seckau', 'en': 'Seckau'}, '433515':{'de': 'Sankt Lorenzen bei Knittelfeld', 'en': 'St. Lorenzen bei Knittelfeld'}, '3348681':{'en': 'Avignon', 'fr': 'Avignon'}, '4419646':{'en': 'Patrington'}, '3355561':{'en': u('Gu\u00e9ret'), 'fr': u('Gu\u00e9ret')}, '3355563':{'en': 'La Souterraine', 'fr': 'La Souterraine'}, '3355564':{'en': 'Bourganeuf', 'fr': 'Bourganeuf'}, '4419645':{'en': 'Hornsea'}, '3355566':{'en': 'Aubusson', 'fr': 'Aubusson'}, '3355568':{'en': 'Bellac', 'fr': 'Bellac'}, '3355569':{'en': 'Eymoutiers', 'fr': 'Eymoutiers'}, '4419644':{'en': 'Patrington'}, '40346':{'en': 'Giurgiu', 'ro': 'Giurgiu'}, '3355607':{'en': 'Pessac', 'fr': 'Pessac'}, '40344':{'en': 'Prahova', 'ro': 'Prahova'}, '40345':{'en': u('D\u00e2mbovi\u021ba'), 'ro': u('D\u00e2mbovi\u021ba')}, '40342':{'en': u('C\u0103l\u0103ra\u0219i'), 'ro': u('C\u0103l\u0103ra\u0219i')}, '40343':{'en': u('Ialomi\u021ba'), 'ro': u('Ialomi\u021ba')}, '40340':{'en': 'Tulcea', 'ro': 'Tulcea'}, '3332429':{'en': 'Sedan', 'fr': 'Sedan'}, '3332427':{'en': 'Sedan', 'fr': 'Sedan'}, '437239':{'de': 'Lichtenberg', 'en': 'Lichtenberg'}, '437238':{'de': 'Mauthausen', 'en': 'Mauthausen'}, '40348':{'en': u('Arge\u0219'), 'ro': u('Arge\u0219')}, '40349':{'en': 'Olt', 'ro': 'Olt'}, '3348426':{'en': 'Marseille', 'fr': 'Marseille'}, '3348357':{'en': 'Toulon', 'fr': 'Toulon'}, '3348350':{'en': 'Nice', 'fr': 'Nice'}, '3355788':{'en': u('Ludon-M\u00e9doc'), 'fr': u('Ludon-M\u00e9doc')}, '3355789':{'en': 'Pessac', 'fr': 'Pessac'}, '3355785':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355787':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355780':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355781':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355783':{'en': 'Cestas', 'fr': 'Cestas'}, '3356200':{'en': 'Saint-Gaudens', 'fr': 'Saint-Gaudens'}, '390966':{'it': 'Palmi'}, '3356205':{'en': 'Auch', 'fr': 'Auch'}, '3356206':{'en': 'Fleurance', 'fr': 'Fleurance'}, '3356207':{'en': 'L\'Isle Jourdain', 'fr': 'L\'Isle Jourdain'}, '3325129':{'en': u('Lu\u00e7on'), 'fr': u('Lu\u00e7on')}, '3325123':{'en': 'Les Sables d\'Olonne', 'fr': 'Les Sables d\'Olonne'}, '3325121':{'en': 'Les Sables d\'Olonne', 'fr': 'Les Sables d\'Olonne'}, '3325126':{'en': 'Saint-Gilles-Croix-de-Vie', 'fr': 'Saint-Gilles-Croix-de-Vie'}, '435475':{'de': 'Feichten', 'en': 'Feichten'}, '3325124':{'en': 'La Roche sur Yon', 'fr': 'La Roche sur Yon'}, '3324830':{'en': 'Saint-Germain-du-Puy', 'fr': 'Saint-Germain-du-Puy'}, '3344218':{'en': 'Aubagne', 'fr': 'Aubagne'}, '3344210':{'en': 'Vitrolles', 'fr': 'Vitrolles'}, '3344211':{'en': 'Istres', 'fr': 'Istres'}, '3344212':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '435474':{'de': 'Pfunds', 'en': 'Pfunds'}, '3344215':{'en': 'Vitrolles', 'fr': 'Vitrolles'}, '3344216':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344217':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '434761':{'de': 'Stockenboi', 'en': 'Stockenboi'}, '434762':{'de': 'Spittal an der Drau', 'en': 'Spittal an der Drau'}, '434766':{'de': 'Millstatt', 'en': 'Millstatt'}, '434767':{'de': 'Rothenthurn', 'en': 'Rothenthurn'}, '432614':{'de': 'Kleinwarasdorf', 'en': 'Kleinwarasdorf'}, '434769':{'de': u('M\u00f6llbr\u00fccke'), 'en': u('M\u00f6llbr\u00fccke')}, '351249':{'en': 'Torres Novas', 'pt': 'Torres Novas'}, '3347603':{'en': 'Grenoble', 'fr': 'Grenoble'}, '351245':{'en': 'Portalegre', 'pt': 'Portalegre'}, '351244':{'en': 'Leiria', 'pt': 'Leiria'}, '351243':{'en': u('Santar\u00e9m'), 'pt': u('Santar\u00e9m')}, '351242':{'en': u('Ponte de S\u00f4r'), 'pt': u('Ponte de S\u00f4r')}, '351241':{'en': 'Abrantes', 'pt': 'Abrantes'}, '3347601':{'en': 'Grenoble', 'fr': 'Grenoble'}, '435332':{'de': u('W\u00f6rgl'), 'en': u('W\u00f6rgl')}, '435583':{'de': 'Lech', 'en': 'Lech'}, '435582':{'de': u('Kl\u00f6sterle'), 'en': u('Kl\u00f6sterle')}, '435585':{'de': 'Dalaas', 'en': 'Dalaas'}, '3347607':{'en': 'Tullins', 'fr': 'Tullins'}, '39010':{'en': 'Genoa', 'it': 'Genova'}, '3596047':{'bg': u('\u0417\u0435\u043b\u0435\u043d\u0430 \u043c\u043e\u0440\u0430\u0432\u0430'), 'en': 'Zelena morava'}, '3596048':{'bg': u('\u0418\u0437\u0432\u043e\u0440\u043e\u0432\u043e, \u0422\u044a\u0440\u0433.'), 'en': 'Izvorovo, Targ.'}, '3595580':{'bg': u('\u0422\u0440\u043e\u044f\u043d\u043e\u0432\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Troyanovo, Burgas'}, '3595589':{'bg': u('\u0412\u0438\u043d\u0430\u0440\u0441\u043a\u043e'), 'en': 'Vinarsko'}, '441780':{'en': 'Stamford'}, '441875':{'en': 'Tranent'}, '3596728':{'bg': u('\u0411\u0443\u0440\u044f'), 'en': 'Burya'}, '3596725':{'bg': u('\u0413\u043e\u0441\u0442\u0438\u043b\u0438\u0446\u0430'), 'en': 'Gostilitsa'}, '3596724':{'bg': u('\u042f\u043d\u0442\u0440\u0430, \u0413\u0430\u0431\u0440.'), 'en': 'Yantra, Gabr.'}, '3596727':{'bg': u('\u0413\u0430\u043d\u0447\u043e\u0432\u0435\u0446'), 'en': 'Ganchovets'}, '3596726':{'bg': u('\u0421\u043a\u0430\u043b\u0441\u043a\u043e'), 'en': 'Skalsko'}, '3596720':{'bg': u('\u041a\u0435\u0440\u0435\u043a\u0430'), 'en': 'Kereka'}, '3596723':{'bg': u('\u0426\u0430\u0440\u0435\u0432\u0430 \u043b\u0438\u0432\u0430\u0434\u0430'), 'en': 'Tsareva livada'}, '3596722':{'bg': u('\u0421\u043e\u043a\u043e\u043b\u043e\u0432\u043e, \u0413\u0430\u0431\u0440.'), 'en': 'Sokolovo, Gabr.'}, '3347747':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347746':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347744':{'en': 'Roanne', 'fr': 'Roanne'}, '3347743':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347742':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347741':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347740':{'en': 'Firminy', 'fr': 'Firminy'}, '441876':{'en': 'Lochmaddy'}, '3347749':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '432610':{'de': 'Horitschon', 'en': 'Horitschon'}, '3349363':{'en': 'Vallauris', 'fr': 'Vallauris'}, '436468':{'de': 'Werfen', 'en': 'Werfen'}, '35965617':{'bg': u('\u0418\u0441\u043a\u044a\u0440, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Iskar, Pleven'}, '436467':{'de': u('M\u00fchlbach am Hochk\u00f6nig'), 'en': u('M\u00fchlbach am Hochk\u00f6nig')}, '436466':{'de': 'Werfenweng', 'en': 'Werfenweng'}, '436461':{'de': u('Dienten am Hochk\u00f6nig'), 'en': u('Dienten am Hochk\u00f6nig')}, '3349361':{'en': 'Antibes Juan les Pins', 'fr': 'Antibes Juan les Pins'}, '436463':{'de': u('Annaberg-Lung\u00f6tz'), 'en': u('Annaberg-Lung\u00f6tz')}, '436462':{'de': 'Bischofshofen', 'en': 'Bischofshofen'}, '3338156':{'en': 'Valdahon', 'fr': 'Valdahon'}, '3338150':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3338151':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3338152':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3338153':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3316907':{'en': 'Gif-sur-Yvette', 'fr': 'Gif-sur-Yvette'}, '3349367':{'en': 'Antibes Juan les Pins', 'fr': 'Antibes Juan les Pins'}, '3316905':{'en': 'Savigny-sur-Orge', 'fr': 'Savigny-sur-Orge'}, '3316904':{'en': 'Morsang-sur-Orge', 'fr': 'Morsang-sur-Orge'}, '3316903':{'en': 'Montgeron', 'fr': 'Montgeron'}, '3316902':{'en': 'Ris-Orangis', 'fr': 'Ris-Orangis'}, '3316901':{'en': u('Montlh\u00e9ry'), 'fr': u('Montlh\u00e9ry')}, '3349366':{'en': 'Peymeinade', 'fr': 'Peymeinade'}, '3596589':{'bg': u('\u041a\u0443\u043b\u0438\u043d\u0430 \u0432\u043e\u0434\u0430'), 'en': 'Kulina voda'}, '3596588':{'bg': u('\u0414\u0435\u043a\u043e\u0432'), 'en': 'Dekov'}, '3349497':{'en': 'Saint-Tropez', 'fr': 'Saint-Tropez'}, '3596581':{'bg': u('\u0411\u044f\u043b\u0430 \u0432\u043e\u0434\u0430, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Byala voda, Pleven'}, '3596580':{'bg': u('\u0422\u0430\u0442\u0430\u0440\u0438'), 'en': 'Tatari'}, '3349364':{'en': 'Vallauris', 'fr': 'Vallauris'}, '3596587':{'bg': u('\u041f\u0435\u0442\u043e\u043a\u043b\u0430\u0434\u0435\u043d\u0446\u0438'), 'en': 'Petokladentsi'}, '441870':{'en': 'Isle of Benbecula'}, '3332640':{'en': 'Reims', 'fr': 'Reims'}, '3343790':{'en': 'Lyon', 'fr': 'Lyon'}, '3343791':{'en': 'Lyon', 'fr': 'Lyon'}, '441784':{'en': 'Staines'}, '3683':{'en': 'Keszthely', 'hu': 'Keszthely'}, '4414372':{'en': 'Clynderwen (Clunderwen)'}, '4414373':{'en': 'Clynderwen (Clunderwen)'}, '441785':{'en': 'Stafford'}, '3682':{'en': 'Kaposvar', 'hu': u('Kaposv\u00e1r')}, '3354578':{'en': 'Barbezieux-Saint-Hilaire', 'fr': 'Barbezieux-Saint-Hilaire'}, '3329711':{'en': 'Plouay', 'fr': 'Plouay'}, '46250':{'en': 'Mora-Orsa', 'sv': 'Mora-Orsa'}, '46251':{'en': u('\u00c4lvdalen'), 'sv': u('\u00c4lvdalen')}, '3354570':{'en': 'Montbron', 'fr': 'Montbron'}, '3354571':{'en': u('Roumazi\u00e8res-Loubert'), 'fr': u('Roumazi\u00e8res-Loubert')}, '4414379':{'en': 'Haverfordwest'}, '436545':{'de': u('Bruck an der Gro\u00dfglocknerstra\u00dfe'), 'en': 'Bruck an der Grossglocknerstrasse'}, '390934':{'en': 'Caltanissetta and Enna', 'it': 'Caltanissetta'}, '3597186':{'bg': u('\u0410\u043d\u0442\u043e\u043d'), 'en': 'Anton'}, '3597187':{'bg': u('\u0411\u0443\u043d\u043e\u0432\u043e, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Bunovo, Sofia'}, '3597184':{'bg': u('\u041a\u043e\u043f\u0440\u0438\u0432\u0449\u0438\u0446\u0430'), 'en': 'Koprivshtitsa'}, '3597185':{'bg': u('\u0427\u0435\u043b\u043e\u043f\u0435\u0447'), 'en': 'Chelopech'}, '3597182':{'bg': u('\u041c\u0438\u0440\u043a\u043e\u0432\u043e'), 'en': 'Mirkovo'}, '3597183':{'bg': u('\u0414\u0443\u0448\u0430\u043d\u0446\u0438'), 'en': 'Dushantsi'}, '3597181':{'bg': u('\u041f\u0438\u0440\u0434\u043e\u043f'), 'en': 'Pirdop'}, '390942':{'en': 'Catania', 'it': 'Taormina'}, '390941':{'it': 'Patti'}, '3597188':{'bg': u('\u041f\u0435\u0442\u0440\u0438\u0447, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Petrich, Sofia'}, '3597189':{'bg': u('\u0427\u0430\u0432\u0434\u0430\u0440, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Chavdar, Sofia'}, '3359670':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3359671':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3359672':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3359673':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3359674':{'en': 'Le Vauclin', 'fr': 'Le Vauclin'}, '3359675':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3359676':{'en': 'Sainte-Anne', 'fr': 'Sainte-Anne'}, '3359677':{'en': 'Ducos', 'fr': 'Ducos'}, '3359678':{'en': 'Basse-Pointe', 'fr': 'Basse-Pointe'}, '3359679':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3322728':{'en': 'Eu', 'fr': 'Eu'}, '435278':{'de': 'Navis', 'en': 'Navis'}, '3355660':{'en': u('L\u00e8ge-Cap-Ferret'), 'fr': u('L\u00e8ge-Cap-Ferret')}, '34961':{'en': 'Valencia', 'es': 'Valencia'}, '34960':{'en': 'Valencia', 'es': 'Valencia'}, '34963':{'en': 'Valencia', 'es': 'Valencia'}, '34962':{'en': 'Valencia', 'es': 'Valencia'}, '34965':{'en': 'Alicante', 'es': 'Alicante'}, '34964':{'en': u('Castell\u00f3n'), 'es': u('Castell\u00f3n')}, '34967':{'en': 'Albacete', 'es': 'Albacete'}, '34966':{'en': 'Alicante', 'es': 'Alicante'}, '3355951':{'en': 'Saint-Jean-de-Luz', 'fr': 'Saint-Jean-de-Luz'}, '34968':{'en': 'Murcia', 'es': 'Murcia'}, '3355953':{'en': 'Pontacq', 'fr': 'Pontacq'}, '3355952':{'en': 'Anglet', 'fr': 'Anglet'}, '3355955':{'en': 'Bayonne', 'fr': 'Bayonne'}, '3329841':{'en': 'Brest', 'fr': 'Brest'}, '3355957':{'en': 'Anglet', 'fr': 'Anglet'}, '3355956':{'en': 'Saint-Martin-de-Seignanx', 'fr': 'Saint-Martin-de-Seignanx'}, '333884':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3684':{'en': 'Siofok', 'hu': u('Si\u00f3fok')}, '35993212':{'bg': u('\u041a\u0430\u0440\u0431\u0438\u043d\u0446\u0438'), 'en': 'Karbintsi'}, '435272':{'de': 'Steinach am Brenner', 'en': 'Steinach am Brenner'}, '3359094':{'en': 'Petit Bourg', 'fr': 'Petit Bourg'}, '35391':{'en': 'Galway/Gort/Loughrea'}, '3359097':{'en': 'Grand-Bourg', 'fr': 'Grand-Bourg'}, '3359090':{'en': u('Pointe-\u00e0-Pitre'), 'fr': u('Pointe-\u00e0-Pitre')}, '3359091':{'en': 'Les Abymes', 'fr': 'Les Abymes'}, '3359092':{'en': 'Trois Rivieres', 'fr': 'Trois Rivieres'}, '35390':{'en': 'Athlone/Ballinasloe/Portumna/Roscommon'}, '3359098':{'en': 'Vieux Habitants', 'fr': 'Vieux Habitants'}, '3359099':{'en': 'Basse Terre', 'fr': 'Basse Terre'}, '35395':{'en': 'Clifden'}, '35394':{'en': 'Castlebar/Claremorris/Castlerea/Ballinrobe'}, '437448':{'de': 'Kematen an der Ybbs', 'en': 'Kematen an der Ybbs'}, '35397':{'en': 'Belmullet'}, '35396':{'en': 'Ballina'}, '35399':{'en': 'Kilronan'}, '35398':{'en': 'Westport'}, '3332624':{'en': 'Reims', 'fr': 'Reims'}, '441429':{'en': 'Hartlepool'}, '441428':{'en': 'Haslemere'}, '3595351':{'bg': u('\u0421\u043c\u044f\u0434\u043e\u0432\u043e'), 'en': 'Smyadovo'}, '441422':{'en': 'Halifax'}, '3595353':{'bg': u('\u0412\u0435\u0441\u0435\u043b\u0438\u043d\u043e\u0432\u043e, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Veselinovo, Shumen'}, '3595352':{'bg': u('\u042f\u043d\u043a\u043e\u0432\u043e'), 'en': 'Yankovo'}, '441427':{'en': 'Gainsborough'}, '3595354':{'bg': u('\u0420\u0438\u0448'), 'en': 'Rish'}, '441425':{'en': 'Ringwood'}, '441424':{'en': 'Hastings'}, '35974207':{'bg': u('\u0413\u0435\u043d\u0435\u0440\u0430\u043b \u0422\u043e\u0434\u043e\u0440\u043e\u0432'), 'en': 'General Todorov'}, '3332855':{'en': 'Lille', 'fr': 'Lille'}, '3332853':{'en': 'Lille', 'fr': 'Lille'}, '3332852':{'en': 'Lille', 'fr': 'Lille'}, '3332851':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '3332850':{'en': 'Bailleul', 'fr': 'Bailleul'}, '437442':{'de': 'Waidhofen an der Ybbs', 'en': 'Waidhofen an der Ybbs'}, '3332859':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '3332858':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '35937705':{'bg': u('\u041f\u044a\u0441\u0442\u0440\u043e\u0433\u043e\u0440'), 'en': 'Pastrogor'}, '437444':{'de': 'Opponitz', 'en': 'Opponitz'}, '437445':{'de': 'Hollenstein an der Ybbs', 'en': 'Hollenstein an der Ybbs'}, '3594518':{'bg': u('\u0422\u043e\u043f\u043e\u043b\u0447\u0430\u043d\u0435'), 'en': 'Topolchane'}, '3594519':{'bg': u('\u0421\u0430\u043c\u0443\u0438\u043b\u043e\u0432\u043e, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Samuilovo, Sliven'}, '3594510':{'bg': u('\u0416\u0435\u043b\u044e \u0432\u043e\u0439\u0432\u043e\u0434\u0430'), 'en': 'Zhelyu voyvoda'}, '3594511':{'bg': u('\u0421\u043b\u0438\u0432\u0435\u043d\u0441\u043a\u0438 \u043c\u0438\u043d\u0435\u0440\u0430\u043b\u043d\u0438 \u0431\u0430\u043d\u0438'), 'en': 'Slivenski mineralni bani'}, '3594512':{'bg': u('\u0411\u043b\u0430\u0442\u0435\u0446, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Blatets, Sliven'}, '3594513':{'bg': u('\u0413\u0430\u0432\u0440\u0430\u0438\u043b\u043e\u0432\u043e'), 'en': 'Gavrailovoc'}, '3594514':{'bg': u('\u041a\u0440\u0443\u0448\u0430\u0440\u0435'), 'en': 'Krushare'}, '3594515':{'bg': u('\u041c\u043e\u043a\u0440\u0435\u043d'), 'en': 'Mokren'}, '3594516':{'bg': u('\u041a\u0435\u0440\u043c\u0435\u043d'), 'en': 'Kermen'}, '3594517':{'bg': u('\u0418\u0447\u0435\u0440\u0430'), 'en': 'Ichera'}, '3598662':{'bg': u('\u0414\u043e\u0431\u0440\u043e\u0442\u0438\u0446\u0430, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Dobrotitsa, Silistra'}, '3334450':{'en': 'Clermont', 'fr': 'Clermont'}, '3334453':{'en': 'Senlis', 'fr': 'Senlis'}, '3334452':{'en': u('M\u00e9ru'), 'fr': u('M\u00e9ru')}, '3334455':{'en': 'Creil', 'fr': 'Creil'}, '3598667':{'bg': u('\u0411\u0435\u043b\u0438\u0446\u0430, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Belitsa, Silistra'}, '3334457':{'en': 'Chantilly', 'fr': 'Chantilly'}, '3334456':{'en': 'Saint-Leu-d\'Esserent', 'fr': 'Saint-Leu-d\'Esserent'}, '3334459':{'en': u('Cr\u00e9py-en-Valois'), 'fr': u('Cr\u00e9py-en-Valois')}, '35936700':{'bg': u('\u0428\u043e\u043f\u0446\u0438'), 'en': 'Shoptsi'}, '3598668':{'bg': u('\u041f\u043e\u043f\u0438\u043d\u0430'), 'en': 'Popina'}, '35936702':{'bg': u('\u0413\u043e\u0440\u0441\u043a\u0438 \u0438\u0437\u0432\u043e\u0440, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Gorski izvor, Kardzh.'}, '432248':{'de': 'Markgrafneusiedl', 'en': 'Markgrafneusiedl'}, '3324191':{'en': u('Brissac-Quinc\u00e9'), 'fr': u('Brissac-Quinc\u00e9')}, '3324190':{'en': u('Chevir\u00e9-le-Rouge'), 'fr': u('Chevir\u00e9-le-Rouge')}, '3324193':{'en': u('Saint-Barth\u00e9lemy-d\'Anjou'), 'fr': u('Saint-Barth\u00e9lemy-d\'Anjou')}, '3324192':{'en': u('Segr\u00e9'), 'fr': u('Segr\u00e9')}, '355211':{'en': 'Koplik'}, '355212':{'en': u('Puk\u00eb')}, '355213':{'en': 'Bajram Curri'}, '355214':{'en': u('Krum\u00eb')}, '355215':{'en': u('Lezh\u00eb')}, '355216':{'en': u('Rr\u00ebshen')}, '355217':{'en': 'Burrel'}, '355218':{'en': 'Peshkopi'}, '355219':{'en': u('Bulqiz\u00eb')}, '3349456':{'en': 'Grimaud', 'fr': 'Grimaud'}, '3356549':{'en': 'Saint-Affrique', 'fr': 'Saint-Affrique'}, '4021':{'en': 'Bucharest and Ilfov County', 'ro': u('Bucure\u0219ti \u0219i jude\u021bul Ilfov')}, '3356543':{'en': 'Decazeville', 'fr': 'Decazeville'}, '3356542':{'en': 'Rodez', 'fr': 'Rodez'}, '3356541':{'en': 'Gourdon', 'fr': 'Gourdon'}, '3356545':{'en': 'Villefranche-de-Rouergue', 'fr': 'Villefranche-de-Rouergue'}, '42057':{'en': u('Zl\u00edn Region')}, '4418906':{'en': 'Ayton'}, '3595135':{'bg': u('\u0421\u0442\u0435\u0444\u0430\u043d \u041a\u0430\u0440\u0430\u0434\u0436\u0430, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Stefan Karadzha, Varna'}, '3595134':{'bg': u('\u0427\u0435\u0440\u0432\u0435\u043d\u0446\u0438'), 'en': 'Cherventsi'}, '3347248':{'en': 'Saint-Pierre-de-Chandieu', 'fr': 'Saint-Pierre-de-Chandieu'}, '3347249':{'en': 'Givors', 'fr': 'Givors'}, '3595131':{'bg': u('\u0412\u044a\u043b\u0447\u0438 \u0434\u043e\u043b'), 'en': 'Valchi dol'}, '3595130':{'bg': u('\u0413\u0435\u043d\u0435\u0440\u0430\u043b \u041a\u0438\u0441\u0435\u043b\u043e\u0432\u043e'), 'en': 'General Kiselovo'}, '3595133':{'bg': u('\u0413\u0435\u043d\u0435\u0440\u0430\u043b \u041a\u043e\u043b\u0435\u0432\u043e, \u0412\u0430\u0440\u043d\u0430'), 'en': 'General Kolevo, Varna'}, '3595132':{'bg': u('\u041c\u0438\u0445\u0430\u043b\u0438\u0447, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Mihalich, Varna'}, '3347242':{'en': u('Fontaines-sur-Sa\u00f4ne'), 'fr': u('Fontaines-sur-Sa\u00f4ne')}, '3343892':{'en': 'Crolles', 'fr': 'Crolles'}, '3347240':{'en': 'Lyon', 'fr': 'Lyon'}, '3347241':{'en': 'Lyon', 'fr': 'Lyon'}, '3347530':{'en': u('Saint-Agr\u00e8ve'), 'fr': u('Saint-Agr\u00e8ve')}, '3347531':{'en': 'Saint-Rambert-d\'Albon', 'fr': 'Saint-Rambert-d\'Albon'}, '3347244':{'en': 'Villeurbanne', 'fr': 'Villeurbanne'}, '3347245':{'en': 'Meyzieu', 'fr': 'Meyzieu'}, '3596112':{'bg': u('\u0421\u0430\u043c\u043e\u0432\u043e\u0434\u0435\u043d\u0435'), 'en': 'Samovodene'}, '3596113':{'bg': u('\u0411\u0430\u043b\u0432\u0430\u043d'), 'en': 'Balvan'}, '3596111':{'bg': u('\u041a\u044a\u043f\u0438\u043d\u043e\u0432\u043e, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Kapinovo, V. Tarnovo'}, '3596116':{'bg': u('\u0413\u043e\u043b\u0435\u043c\u0430\u043d\u0438\u0442\u0435'), 'en': 'Golemanite'}, '3596117':{'bg': u('\u0414\u0435\u0431\u0435\u043b\u0435\u0446, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Debelets, V. Tarnovo'}, '3596114':{'bg': u('\u041a\u0438\u043b\u0438\u0444\u0430\u0440\u0435\u0432\u043e'), 'en': 'Kilifarevo'}, '3596115':{'bg': u('\u0420\u0435\u0441\u0435\u043d'), 'en': 'Resen'}, '3596118':{'bg': u('\u0412\u043e\u043d\u0435\u0449\u0430 \u0432\u043e\u0434\u0430'), 'en': 'Voneshta voda'}, '3596119':{'bg': u('\u0414\u0438\u0447\u0438\u043d'), 'en': 'Dichin'}, '3689':{'en': 'Papa', 'hu': u('P\u00e1pa')}, '3599131':{'bg': u('\u0414\u043e\u0431\u0440\u043e\u043b\u0435\u0432\u043e'), 'en': 'Dobrolevo'}, '3599130':{'bg': u('\u0422\u043b\u0430\u0447\u0435\u043d\u0435'), 'en': 'Tlachene'}, '3599133':{'bg': u('\u041a\u043e\u043c\u0430\u0440\u0435\u0432\u043e, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Komarevo, Vratsa'}, '3599132':{'bg': u('\u041a\u043d\u0435\u0436\u0430'), 'en': 'Knezha'}, '3599135':{'bg': u('\u0411\u044a\u0440\u0434\u0430\u0440\u0441\u043a\u0438 \u0433\u0435\u0440\u0430\u043d'), 'en': 'Bardarski geran'}, '3599134':{'bg': u('\u0422\u044a\u0440\u043d\u0430\u043a'), 'en': 'Tarnak'}, '3599137':{'bg': u('\u041f\u043e\u043f\u0438\u0446\u0430'), 'en': 'Popitsa'}, '3599136':{'bg': u('\u0413\u0430\u043b\u0438\u0447\u0435'), 'en': 'Galiche'}, '3599139':{'bg': u('\u0422\u044a\u0440\u043d\u0430\u0432\u0430, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Tarnava, Vratsa'}, '3599138':{'bg': u('\u0410\u043b\u0442\u0438\u043c\u0438\u0440'), 'en': 'Altimir'}, '435554':{'de': 'Sonntag', 'en': 'Sonntag'}, '3353441':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3353440':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3353443':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3353442':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3353445':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3353444':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3353446':{'en': 'Muret', 'fr': 'Muret'}, '3338774':{'en': 'Metz', 'fr': 'Metz'}, '3338775':{'en': 'Metz', 'fr': 'Metz'}, '432616':{'de': 'Lockenhaus', 'en': 'Lockenhaus'}, '432617':{'de': u('Dra\u00dfmarkt'), 'en': 'Drassmarkt'}, '35984393':{'bg': u('\u0412\u0430\u0437\u043e\u0432\u043e'), 'en': 'Vazovo'}, '3338770':{'en': 'Hagondange', 'fr': 'Hagondange'}, '40357':{'en': 'Arad', 'ro': 'Arad'}, '35984394':{'bg': u('\u0414\u0443\u0445\u043e\u0432\u0435\u0446'), 'en': 'Duhovets'}, '432615':{'de': 'Lutzmannsburg', 'en': 'Lutzmannsburg'}, '3685':{'en': 'Marcali', 'hu': 'Marcali'}, '432612':{'de': 'Oberpullendorf', 'en': 'Oberpullendorf'}, '3338773':{'en': 'Ennery', 'fr': 'Ennery'}, '4413878':{'en': 'Dumfries'}, '432613':{'de': 'Deutschkreutz', 'en': 'Deutschkreutz'}, '42054':{'en': 'South Moravian Region'}, '42055':{'en': 'Moravian-Silesian Region'}, '359748':{'bg': u('\u0421\u0438\u043c\u0438\u0442\u043b\u0438'), 'en': 'Simitli'}, '359749':{'bg': u('\u0411\u0430\u043d\u0441\u043a\u043e'), 'en': 'Bansko'}, '40353':{'en': 'Gorj', 'ro': 'Gorj'}, '42053':{'en': 'South Moravian Region'}, '40352':{'en': u('Mehedin\u021bi'), 'ro': u('Mehedin\u021bi')}, '359746':{'bg': u('\u0421\u0430\u043d\u0434\u0430\u043d\u0441\u043a\u0438'), 'en': 'Sandanski'}, '359747':{'bg': u('\u0420\u0430\u0437\u043b\u043e\u0433'), 'en': 'Razlog'}, '359745':{'bg': u('\u041f\u0435\u0442\u0440\u0438\u0447, \u0411\u043b\u0430\u0433.'), 'en': 'Petrich, Blag.'}, '435417':{'de': 'Roppen', 'en': 'Roppen'}, '435557':{'de': 'Sankt Gallenkirch', 'en': 'St. Gallenkirch'}, '390532':{'en': 'Ferrara', 'it': 'Ferrara'}, '390533':{'it': 'Comacchio'}, '390536':{'it': 'Sassuolo'}, '390534':{'it': 'Porretta Terme'}, '390535':{'it': 'Mirandola'}, '437228':{'de': 'Kematen an der Krems', 'en': 'Kematen an der Krems'}, '437229':{'de': 'Traun', 'en': 'Traun'}, '35969248':{'bg': u('\u0421\u043a\u043e\u0431\u0435\u043b\u0435\u0432\u043e, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Skobelevo, Lovech'}, '35969249':{'bg': u('\u0414\u043e\u0439\u0440\u0435\u043d\u0446\u0438'), 'en': 'Doyrentsi'}, '434245':{'de': 'Feistritz an der Drau', 'en': 'Feistritz an der Drau'}, '35969240':{'bg': u('\u0425\u043b\u0435\u0432\u0435\u043d\u0435'), 'en': 'Hlevene'}, '35969241':{'bg': u('\u0419\u043e\u0433\u043b\u0430\u0432'), 'en': 'Yoglav'}, '35969242':{'bg': u('\u041f\u0440\u0435\u0441\u044f\u043a\u0430'), 'en': 'Presyaka'}, '35969243':{'bg': u('\u041a\u0430\u0437\u0430\u0447\u0435\u0432\u043e'), 'en': 'Kazachevo'}, '35969244':{'bg': u('\u0422\u0435\u043f\u0430\u0432\u0430'), 'en': 'Tepava'}, '35969245':{'bg': u('\u0414\u0435\u0432\u0435\u0442\u0430\u043a\u0438'), 'en': 'Devetaki'}, '35969247':{'bg': u('\u0413\u043e\u0441\u0442\u0438\u043d\u044f'), 'en': 'Gostinya'}, '3349352':{'en': 'Nice', 'fr': 'Nice'}, '3349353':{'en': 'Nice', 'fr': 'Nice'}, '3349351':{'en': 'Nice', 'fr': 'Nice'}, '3349356':{'en': 'Nice', 'fr': 'Nice'}, '3349357':{'en': 'Menton', 'fr': 'Menton'}, '3349354':{'en': 'Nice', 'fr': 'Nice'}, '3349355':{'en': 'Nice', 'fr': 'Nice'}, '3349358':{'en': 'Vence', 'fr': 'Vence'}, '3349359':{'en': 'Tourrettes-sur-Loup', 'fr': 'Tourrettes-sur-Loup'}, '390965':{'en': 'Reggio Calabria', 'it': 'Reggio di Calabria'}, '44238':{'en': 'Southampton'}, '435356':{'de': u('Kitzb\u00fchel'), 'en': u('Kitzb\u00fchel')}, '44239':{'en': 'Portsmouth'}, '371683':{'en': u('J\u0113kabpils')}, '371682':{'en': 'Valmiera'}, '3338958':{'en': 'Sainte-Marie-aux-Mines', 'fr': 'Sainte-Marie-aux-Mines'}, '3338959':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '371686':{'en': 'Jelgava'}, '3338486':{'en': 'Lons-le-Saunier', 'fr': 'Lons-le-Saunier'}, '3338487':{'en': 'Lons-le-Saunier', 'fr': 'Lons-le-Saunier'}, '3338956':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3338482':{'en': 'Dole', 'fr': 'Dole'}, '3338951':{'en': 'Wittenheim', 'fr': 'Wittenheim'}, '3338952':{'en': 'Wittenheim', 'fr': 'Wittenheim'}, '3338953':{'en': 'Wittenheim', 'fr': 'Wittenheim'}, '331719':{'en': 'Paris', 'fr': 'Paris'}, '3354634':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '432915':{'de': 'Drosendorf-Zissersdorf', 'en': 'Drosendorf-Zissersdorf'}, '432914':{'de': 'Japons', 'en': 'Japons'}, '3332198':{'en': 'Saint-Omer', 'fr': 'Saint-Omer'}, '3332199':{'en': 'Boulogne-sur-Mer', 'fr': 'Boulogne-sur-Mer'}, '331713':{'en': 'Paris', 'fr': 'Paris'}, '331712':{'en': 'Paris', 'fr': 'Paris'}, '3332194':{'en': u('\u00c9taples'), 'fr': u('\u00c9taples')}, '3596982':{'bg': u('\u042a\u0433\u043b\u0435\u043d'), 'en': 'aglen'}, '331717':{'en': 'Paris', 'fr': 'Paris'}, '331716':{'en': 'Paris', 'fr': 'Paris'}, '331715':{'en': 'Paris', 'fr': 'Paris'}, '3594749':{'bg': u('\u0420\u0443\u0436\u0438\u0446\u0430, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Ruzhitsa, Yambol'}, '3594748':{'bg': u('\u0412\u043e\u0434\u0435\u043d, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Voden, Yambol'}, '3594745':{'bg': u('\u0428\u0430\u0440\u043a\u043e\u0432\u043e'), 'en': 'Sharkovo'}, '3594744':{'bg': u('\u0413\u043e\u043b\u044f\u043c\u043e \u041a\u0440\u0443\u0448\u0435\u0432\u043e'), 'en': 'Golyamo Krushevo'}, '3594747':{'bg': u('\u0414\u0435\u043d\u043d\u0438\u0446\u0430, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Dennitsa, Yambol'}, '3594746':{'bg': u('\u041f\u043e\u043f\u043e\u0432\u043e, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Popovo, Yambol'}, '3594741':{'bg': u('\u0411\u043e\u043b\u044f\u0440\u043e\u0432\u043e'), 'en': 'Bolyarovo'}, '3594743':{'bg': u('\u041c\u0430\u043c\u0430\u0440\u0447\u0435\u0432\u043e'), 'en': 'Mamarchevo'}, '3594742':{'bg': u('\u0421\u0442\u0435\u0444\u0430\u043d \u041a\u0430\u0440\u0430\u0434\u0436\u043e\u0432\u043e'), 'en': 'Stefan Karadzhovo'}, '3346805':{'en': 'Prades', 'fr': 'Prades'}, '433534':{'de': 'Stadl an der Mur', 'en': 'Stadl an der Mur'}, '3596989':{'bg': u('\u0422\u043e\u0440\u043e\u0441'), 'en': 'Toros'}, '433536':{'de': 'Sankt Peter am Kammersberg', 'en': 'St. Peter am Kammersberg'}, '433537':{'de': 'Sankt Georgen ob Murau', 'en': 'St. Georgen ob Murau'}, '433532':{'de': 'Murau', 'en': 'Murau'}, '3346808':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3355549':{'en': 'Limoges', 'fr': 'Limoges'}, '3355542':{'en': 'Limoges', 'fr': 'Limoges'}, '3355543':{'en': 'Limoges', 'fr': 'Limoges'}, '3355541':{'en': u('Gu\u00e9ret'), 'fr': u('Gu\u00e9ret')}, '3355546':{'en': 'Ussel', 'fr': 'Ussel'}, '3355545':{'en': 'Limoges', 'fr': 'Limoges'}, '40368':{'en': u('Bra\u0219ov'), 'ro': u('Bra\u0219ov')}, '40369':{'en': 'Sibiu', 'ro': 'Sibiu'}, '432629':{'de': u('Warth, Nieder\u00f6sterreich'), 'en': 'Warth, Lower Austria'}, '432628':{'de': 'Felixdorf', 'en': 'Felixdorf'}, '3332440':{'en': 'Revin', 'fr': 'Revin'}, '3332441':{'en': 'Fumay', 'fr': 'Fumay'}, '3332442':{'en': 'Givet', 'fr': 'Givet'}, '40367':{'en': 'Covasna', 'ro': 'Covasna'}, '40360':{'en': u('S\u0103laj'), 'ro': u('S\u0103laj')}, '40361':{'en': 'Satu Mare', 'ro': 'Satu Mare'}, '40362':{'en': u('Maramure\u0219'), 'ro': u('Maramure\u0219')}, '40363':{'en': u('Bistri\u021ba-N\u0103s\u0103ud'), 'ro': u('Bistri\u021ba-N\u0103s\u0103ud')}, '44292':{'en': 'Cardiff'}, '3359425':{'en': 'Cayenne', 'fr': 'Cayenne'}, '3359427':{'en': 'Saint-Laurent-du-Maroni', 'fr': 'Saint-Laurent-du-Maroni'}, '3359422':{'en': 'Kourou', 'fr': 'Kourou'}, '390964':{'it': 'Locri'}, '3359429':{'en': 'Cayenne', 'fr': 'Cayenne'}, '3359428':{'en': 'Cayenne', 'fr': 'Cayenne'}, '3593164':{'bg': u('\u0414\u044a\u043b\u0431\u043e\u043a \u0438\u0437\u0432\u043e\u0440'), 'en': 'Dalbok izvor'}, '3593165':{'bg': u('\u041a\u0430\u0440\u0430\u0434\u0436\u0430\u043b\u043e\u0432\u043e'), 'en': 'Karadzhalovo'}, '3593166':{'bg': u('\u0411\u044f\u043b\u0430 \u0440\u0435\u043a\u0430, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Byala reka, Plovdiv'}, '3593167':{'bg': u('\u0411\u0440\u044f\u0433\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Bryagovo, Plovdiv'}, '3597139':{'bg': u('\u0414\u0436\u0443\u0440\u043e\u0432\u043e'), 'en': 'Dzhurovo'}, '3593162':{'bg': u('\u0413\u0440\u0430\u0434\u0438\u043d\u0430, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Gradina, Plovdiv'}, '3593163':{'bg': u('\u0418\u0441\u043a\u0440\u0430, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Iskra, Plovdiv'}, '3593168':{'bg': u('\u0415\u0437\u0435\u0440\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Ezerovo, Plovdiv'}, '3317956':{'en': u('Cr\u00e9teil'), 'fr': u('Cr\u00e9teil')}, '3317951':{'en': 'Argenteuil', 'fr': 'Argenteuil'}, '3595145':{'bg': u('\u0413\u0440\u043e\u0437\u0434\u044c\u043e\u0432\u043e'), 'en': 'Grozdyovo'}, '3325105':{'en': 'La Roche sur Yon', 'fr': 'La Roche sur Yon'}, '3325456':{'en': 'Blois', 'fr': 'Blois'}, '3325455':{'en': 'Blois', 'fr': 'Blois'}, '3325453':{'en': u('Ch\u00e2teauroux'), 'fr': u('Ch\u00e2teauroux')}, '3325451':{'en': 'Blois', 'fr': 'Blois'}, '3325450':{'en': 'Vineuil', 'fr': 'Vineuil'}, '3325108':{'en': 'La Roche sur Yon', 'fr': 'La Roche sur Yon'}, '37425694':{'am': u('\u0531\u0563\u0561\u0580\u0561\u056f'), 'en': 'Agarak', 'ru': u('\u0410\u0433\u0430\u0440\u0430\u043a')}, '3325458':{'en': 'Blois', 'fr': 'Blois'}, '3595724':{'bg': u('\u0414\u0440\u043e\u043f\u043b\u0430, \u0414\u043e\u0431\u0440.'), 'en': 'Dropla, Dobr.'}, '3324850':{'en': 'Bourges', 'fr': 'Bourges'}, '3324852':{'en': 'Vierzon', 'fr': 'Vierzon'}, '3324854':{'en': 'Sancerre', 'fr': 'Sancerre'}, '3324855':{'en': 'Saint-Florent-sur-Cher', 'fr': 'Saint-Florent-sur-Cher'}, '3324857':{'en': u('Mehun-sur-Y\u00e8vre'), 'fr': u('Mehun-sur-Y\u00e8vre')}, '3324858':{'en': u('Aubigny-sur-N\u00e8re'), 'fr': u('Aubigny-sur-N\u00e8re')}, '3324859':{'en': 'Dun-sur-Auron', 'fr': 'Dun-sur-Auron'}, '37425695':{'am': u('\u053c\u0565\u057b\u0561\u0576'), 'en': 'Lejan', 'ru': u('\u041b\u0435\u0436\u0430\u043d')}, '370315':{'en': 'Alytus'}, '370310':{'en': u('Var\u0117na')}, '370313':{'en': 'Druskininkai'}, '370318':{'en': 'Lazdijai'}, '370319':{'en': u('Bir\u0161tonas/Prienai')}, '333254':{'en': 'Troyes', 'fr': 'Troyes'}, '4413885':{'en': 'Stanhope (Eastgate)'}, '3356220':{'en': 'Portet-sur-Garonne', 'fr': 'Portet-sur-Garonne'}, '3356221':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356226':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356227':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356224':{'en': u('Lab\u00e8ge'), 'fr': u('Lab\u00e8ge')}, '4417685':{'en': 'Penrith'}, '4417684':{'en': 'Pooley Bridge'}, '3356228':{'en': 'Condom', 'fr': 'Condom'}, '3356229':{'en': u('Montr\u00e9al'), 'fr': u('Montr\u00e9al')}, '4417681':{'en': 'Penrith'}, '4417680':{'en': 'Penrith'}, '4417683':{'en': 'Appleby'}, '4417682':{'en': 'Penrith'}, '4413884':{'en': 'Bishop Auckland'}, '359697':{'bg': u('\u041b\u0443\u043a\u043e\u0432\u0438\u0442'), 'en': 'Lukovit'}, '390865':{'en': 'Isernia', 'it': 'Isernia'}, '4413883':{'en': 'Bishop Auckland'}, '42147':{'en': u('Lu\u010denec')}, '3344232':{'en': u('G\u00e9menos'), 'fr': u('G\u00e9menos')}, '3344230':{'en': 'Gignac-la-Nerthe', 'fr': 'Gignac-la-Nerthe'}, '3344231':{'en': 'Marignane', 'fr': 'Marignane'}, '3344236':{'en': 'Aubagne', 'fr': 'Aubagne'}, '3344237':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344234':{'en': 'Vitrolles', 'fr': 'Vitrolles'}, '3344238':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344239':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3347761':{'en': 'Firminy', 'fr': 'Firminy'}, '3347760':{'en': 'Charlieu', 'fr': 'Charlieu'}, '35969031':{'bg': u('\u0413\u0430\u043b\u0430\u0442\u0430'), 'en': 'Galata'}, '3347989':{'en': 'Ugine', 'fr': 'Ugine'}, '3347988':{'en': 'Aix-les-Bains', 'fr': 'Aix-les-Bains'}, '3347767':{'en': 'Roanne', 'fr': 'Roanne'}, '3343404':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3347984':{'en': u('Montm\u00e9lian'), 'fr': u('Montm\u00e9lian')}, '3343400':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3347983':{'en': 'Saint-Jean-de-Maurienne', 'fr': 'Saint-Jean-de-Maurienne'}, '4413881':{'en': 'Bishop Auckland/Stanhope (Eastgate)'}, '35931258':{'bg': u('\u0413\u043b\u0430\u0432\u0430\u0442\u0430\u0440'), 'en': 'Glavatar'}, '3316929':{'en': 'Orsay', 'fr': 'Orsay'}, '3316928':{'en': 'Orsay', 'fr': 'Orsay'}, '3316921':{'en': 'Juvisy-sur-Orge', 'fr': 'Juvisy-sur-Orge'}, '3316920':{'en': 'Massy', 'fr': 'Massy'}, '3316923':{'en': 'Cerny', 'fr': 'Cerny'}, '3316925':{'en': u('Sainte-Genevi\u00e8ve-des-Bois'), 'fr': u('Sainte-Genevi\u00e8ve-des-Bois')}, '3316924':{'en': u('Viry-Ch\u00e2tillon'), 'fr': u('Viry-Ch\u00e2tillon')}, '3316927':{'en': 'Lardy', 'fr': 'Lardy'}, '3316926':{'en': 'Arpajon', 'fr': 'Arpajon'}, '441922':{'en': 'Walsall'}, '441923':{'en': 'Watford'}, '3355680':{'en': 'Talence', 'fr': 'Talence'}, '4413880':{'en': 'Bishop Auckland/Stanhope (Eastgate)'}, '441920':{'en': 'Ware'}, '441926':{'en': 'Warwick'}, '35984728':{'bg': u('\u0420\u0430\u043a\u043e\u0432\u0441\u043a\u0438, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Rakovski, Razgrad'}, '35984729':{'bg': u('\u0415\u0437\u0435\u0440\u0447\u0435'), 'en': 'Ezerche'}, '3327776':{'en': 'Rouen', 'fr': 'Rouen'}, '35984722':{'bg': u('\u042f\u0441\u0435\u043d\u043e\u0432\u0435\u0446'), 'en': 'Yasenovets'}, '35984723':{'bg': u('\u0414\u044f\u043d\u043a\u043e\u0432\u043e'), 'en': 'Dyankovo'}, '35984720':{'bg': u('\u0422\u043e\u043f\u0447\u0438\u0438'), 'en': 'Topchii'}, '3325159':{'en': 'Saint-Jean-de-Monts', 'fr': 'Saint-Jean-de-Monts'}, '35984726':{'bg': u('\u0423\u0448\u0438\u043d\u0446\u0438'), 'en': 'Ushintsi'}, '35984727':{'bg': u('\u041a\u0430\u043c\u0435\u043d\u043e\u0432\u043e, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Kamenovo, Razgrad'}, '35984725':{'bg': u('\u041a\u0438\u0447\u0435\u043d\u0438\u0446\u0430'), 'en': 'Kichenitsa'}, '43512':{'de': 'Innsbruck', 'en': 'Innsbruck'}, '46278':{'en': u('Bolln\u00e4s'), 'sv': u('Bolln\u00e4s')}, '3329736':{'en': 'Hennebont', 'fr': 'Hennebont'}, '3329737':{'en': 'Lorient', 'fr': 'Lorient'}, '3329734':{'en': 'Guiscriff', 'fr': 'Guiscriff'}, '3329735':{'en': 'Lorient', 'fr': 'Lorient'}, '3329732':{'en': 'Pont-Scorff', 'fr': 'Pont-Scorff'}, '3329733':{'en': 'Plouay', 'fr': 'Plouay'}, '3329730':{'en': 'Quiberon', 'fr': 'Quiberon'}, '3329731':{'en': 'Le Palais', 'fr': 'Le Palais'}, '3595148':{'bg': u('\u0420\u0443\u0434\u043d\u0438\u043a, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Rudnik, Varna'}, '3338569':{'en': 'Montceau-les-Mines', 'fr': 'Montceau-les-Mines'}, '3338568':{'en': 'Blanzy', 'fr': 'Blanzy'}, '3338567':{'en': 'Montceau-les-Mines', 'fr': 'Montceau-les-Mines'}, '3595149':{'bg': u('\u0413\u043e\u043b\u0438\u0446\u0430'), 'en': 'Golitsa'}, '4417688':{'en': 'Penrith'}, '3359658':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3359652':{'en': 'Le Morne Rouge', 'fr': 'Le Morne Rouge'}, '3359653':{'en': 'Le Lorrain', 'fr': 'Le Lorrain'}, '3359650':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3359651':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3359656':{'en': 'Ducos', 'fr': 'Ducos'}, '3359657':{'en': 'Saint Joseph', 'fr': 'Saint Joseph'}, '3359654':{'en': u('Le Fran\u00e7ois'), 'fr': u('Le Fran\u00e7ois')}, '3359655':{'en': 'Le Morne Vert', 'fr': 'Le Morne Vert'}, '435224':{'de': 'Wattens', 'en': 'Wattens'}, '3329866':{'en': u('Pont-l\'Abb\u00e9'), 'fr': u('Pont-l\'Abb\u00e9')}, '3355684':{'en': 'Talence', 'fr': 'Talence'}, '3355687':{'en': 'Villenave-d\'Ornon', 'fr': 'Villenave-d\'Ornon'}, '3355686':{'en': 'Cenon', 'fr': 'Cenon'}, '3355681':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3329863':{'en': 'Morlaix', 'fr': 'Morlaix'}, '3355683':{'en': 'Arcachon', 'fr': 'Arcachon'}, '3329861':{'en': u('Ploun\u00e9vez-Lochrist'), 'fr': u('Ploun\u00e9vez-Lochrist')}, '3355939':{'en': 'Oloron-Sainte-Marie', 'fr': 'Oloron-Sainte-Marie'}, '3355938':{'en': u('Salies-de-B\u00e9arn'), 'fr': u('Salies-de-B\u00e9arn')}, '3355689':{'en': 'Gradignan', 'fr': 'Gradignan'}, '3355688':{'en': 'Salles', 'fr': 'Salles'}, '3329868':{'en': 'Landivisiau', 'fr': 'Landivisiau'}, '3329869':{'en': u('Saint-Pol-de-L\u00e9on'), 'fr': u('Saint-Pol-de-L\u00e9on')}, '3595118':{'bg': u('\u0412\u043e\u0434\u0438\u0446\u0430, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Voditsa, Varna'}, '34949':{'en': 'Guadalajara', 'es': 'Guadalajara'}, '34948':{'en': 'Navarre', 'es': 'Navarra'}, '34947':{'en': 'Burgos', 'es': 'Burgos'}, '34946':{'en': 'Vizcaya', 'es': 'Vizcaya'}, '34945':{'en': u('\u00c1lava'), 'es': u('\u00c1lava')}, '34944':{'en': 'Vizcaya', 'es': 'Vizcaya'}, '34943':{'en': u('Guip\u00fazcoa'), 'es': u('Guip\u00fazcoa')}, '34942':{'en': 'Cantabria', 'es': 'Cantabria'}, '34941':{'en': 'La Rioja', 'es': 'La Rioja'}, '35971337':{'bg': u('\u041a\u0430\u043b\u0443\u0433\u0435\u0440\u043e\u0432\u043e, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Kalugerovo, Sofia'}, '3332295':{'en': 'Amiens', 'fr': 'Amiens'}, '3332294':{'en': 'Hangest-en-Santerre', 'fr': 'Hangest-en-Santerre'}, '3332297':{'en': 'Amiens', 'fr': 'Amiens'}, '3332296':{'en': 'Corbie', 'fr': 'Corbie'}, '3332291':{'en': 'Amiens', 'fr': 'Amiens'}, '3332292':{'en': 'Amiens', 'fr': 'Amiens'}, '441395':{'en': 'Budleigh Salterton'}, '3344203':{'en': 'Aubagne', 'fr': 'Aubagne'}, '441397':{'en': 'Fort William'}, '3344202':{'en': 'Les Pennes Mirabeau', 'fr': 'Les Pennes Mirabeau'}, '432735':{'de': 'Hadersdorf am Kamp', 'en': 'Hadersdorf am Kamp'}, '3344201':{'en': 'Cassis', 'fr': 'Cassis'}, '432734':{'de': 'Langenlois', 'en': 'Langenlois'}, '35361':{'en': 'Limerick/Scariff'}, '35362':{'en': 'Tipperary/Cashel'}, '432738':{'de': 'Fels am Wagram', 'en': 'Fels am Wagram'}, '441466':{'en': 'Huntly'}, '35363':{'en': 'Charleville'}, '3594356':{'bg': u('\u0425\u0430\u0434\u0436\u0438\u0434\u0438\u043c\u0438\u0442\u0440\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Hadzhidimitrovo, St. Zagora'}, '3594357':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u0421\u0430\u0445\u0440\u0430\u043d\u0435'), 'en': 'Gorno Sahrane'}, '3594354':{'bg': u('\u0417\u0438\u043c\u043d\u0438\u0446\u0430, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Zimnitsa, St. Zagora'}, '3594355':{'bg': u('\u0411\u0443\u0437\u043e\u0432\u0433\u0440\u0430\u0434'), 'en': 'Buzovgrad'}, '3594352':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u0427\u0435\u0440\u043a\u043e\u0432\u0438\u0449\u0435'), 'en': 'Gorno Cherkovishte'}, '3594353':{'bg': u('\u0421\u0440\u0435\u0434\u043d\u043e\u0433\u043e\u0440\u043e\u0432\u043e'), 'en': 'Srednogorovo'}, '3594350':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u0418\u0437\u0432\u043e\u0440\u043e\u0432\u043e'), 'en': 'Gorno Izvorovo'}, '3594351':{'bg': u('\u041a\u043e\u043f\u0440\u0438\u043d\u043a\u0430'), 'en': 'Koprinka'}, '3594358':{'bg': u('\u0421\u043a\u043e\u0431\u0435\u043b\u0435\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Skobelevo, St. Zagora'}, '3594359':{'bg': u('\u0410\u0441\u0435\u043d, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Asen, St. Zagora'}, '4418470':{'en': 'Thurso/Tongue'}, '3598640':{'bg': u('\u041f\u0440\u0430\u0432\u0434\u0430, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Pravda, Silistra'}, '441464':{'en': 'Insch'}, '435357':{'de': 'Kirchberg in Tirol', 'en': 'Kirchberg in Tirol'}, '3598643':{'bg': u('\u0417\u043b\u0430\u0442\u043e\u043a\u043b\u0430\u0441'), 'en': 'Zlatoklas'}, '3598644':{'bg': u('\u0427\u0435\u0440\u043d\u043e\u043b\u0438\u043a'), 'en': 'Chernolik'}, '3598645':{'bg': u('\u041c\u0435\u0436\u0434\u0435\u043d'), 'en': 'Mezhden'}, '3317549':{'en': 'Boulogne-Billancourt', 'fr': 'Boulogne-Billancourt'}, '4418479':{'en': 'Tongue'}, '3317540':{'en': 'Argenteuil', 'fr': 'Argenteuil'}, '3317542':{'en': 'Paris', 'fr': 'Paris'}, '4418478':{'en': 'Thurso'}, '3338363':{'en': 'Toul', 'fr': 'Toul'}, '3334439':{'en': u('Cr\u00e9py-en-Valois'), 'fr': u('Cr\u00e9py-en-Valois')}, '3334438':{'en': u('Compi\u00e8gne'), 'fr': u('Compi\u00e8gne')}, '3338367':{'en': 'Nancy', 'fr': 'Nancy'}, '3338364':{'en': 'Toul', 'fr': 'Toul'}, '3334432':{'en': 'Senlis', 'fr': 'Senlis'}, '3334431':{'en': 'Pont-Sainte-Maxence', 'fr': 'Pont-Sainte-Maxence'}, '3334430':{'en': u('Compi\u00e8gne'), 'fr': u('Compi\u00e8gne')}, '3334437':{'en': 'Jaux', 'fr': 'Jaux'}, '3334436':{'en': u('Compi\u00e8gne'), 'fr': u('Compi\u00e8gne')}, '441440':{'en': 'Haverhill'}, '3355608':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3595333':{'bg': u('\u0425\u0430\u043d \u041a\u0440\u0443\u043c'), 'en': 'Han Krum'}, '3595332':{'bg': u('\u0414\u0440\u0430\u0433\u043e\u0435\u0432\u043e'), 'en': 'Dragoevo'}, '3595330':{'bg': u('\u0417\u043b\u0430\u0442\u0430\u0440'), 'en': 'Zlatar'}, '3595337':{'bg': u('\u041a\u043e\u0447\u043e\u0432\u043e'), 'en': 'Kochovo'}, '3595336':{'bg': u('\u0418\u043c\u0440\u0435\u043d\u0447\u0435\u0432\u043e'), 'en': 'Imrenchevo'}, '3595335':{'bg': u('\u041c\u0438\u043b\u0430\u043d\u043e\u0432\u043e, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Milanovo, Shumen'}, '3595334':{'bg': u('\u041e\u0441\u043c\u0430\u0440'), 'en': 'Osmar'}, '35941279':{'bg': u('\u0421\u0442\u0440\u0435\u043b\u0435\u0446, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Strelets, St. Zagora'}, '3355858':{'en': 'Dax', 'fr': 'Dax'}, '3595338':{'bg': u('\u0422\u0440\u043e\u0438\u0446\u0430'), 'en': 'Troitsa'}, '3356565':{'en': 'Rieupeyroux', 'fr': 'Rieupeyroux'}, '3356567':{'en': 'Rodez', 'fr': 'Rodez'}, '355279':{'en': u('Gryk-\u00c7aj\u00eb/Ujmisht/Bushtrice/Kalis, Kuk\u00ebs')}, '3356561':{'en': 'Millau', 'fr': 'Millau'}, '3329929':{'en': 'Rennes', 'fr': 'Rennes'}, '355272':{'en': u('Qerret/Qel\u00ebz/Gjegjan, Puk\u00eb')}, '355273':{'en': u('Iball\u00eb/Fierz\u00eb/Blerim/Qaf\u00eb-Mali, Puk\u00eb')}, '355270':{'en': u('Kolsh/Surroj/Arren/Malzi, Kuk\u00ebs')}, '355271':{'en': u('Fush\u00eb-Arr\u00ebz/Rrap\u00eb, Puk\u00eb')}, '355276':{'en': 'Fajza/Golaj/Gjinaj, Has'}, '3356568':{'en': 'Rodez', 'fr': 'Rodez'}, '355274':{'en': u('Tropoj\u00eb/Llugaj/Margegaj, Tropoj\u00eb')}, '355275':{'en': u('Bujan/Fierz\u00eb/Bytyc/Lekbiba, Tropoj\u00eb')}, '3329927':{'en': 'Rennes', 'fr': 'Rennes'}, '3597925':{'bg': u('\u0413\u044e\u0435\u0448\u0435\u0432\u043e'), 'en': 'Gyueshevo'}, '3599339':{'bg': u('\u041c\u0430\u043a\u0440\u0435\u0448'), 'en': 'Makresh'}, '3329926':{'en': 'Rennes', 'fr': 'Rennes'}, '3599337':{'bg': u('\u0413\u0440\u0430\u043c\u0430\u0434\u0430'), 'en': 'Gramada'}, '3599336':{'bg': u('\u0421\u0442\u0430\u0440\u043e\u043f\u0430\u0442\u0438\u0446\u0430'), 'en': 'Staropatitsa'}, '3599335':{'bg': u('\u0426\u0430\u0440 \u041f\u0435\u0442\u0440\u043e\u0432\u043e'), 'en': 'Tsar Petrovo'}, '3599333':{'bg': u('\u0411\u043e\u0439\u043d\u0438\u0446\u0430'), 'en': 'Boynitsa'}, '3355856':{'en': 'Dax', 'fr': 'Dax'}, '3599330':{'bg': u('\u0420\u0430\u0431\u0440\u043e\u0432\u043e'), 'en': 'Rabrovo'}, '3329922':{'en': 'Rennes', 'fr': 'Rennes'}, '3597926':{'bg': u('\u041a\u043e\u043d\u044f\u0432\u043e'), 'en': 'Konyavo'}, '3355852':{'en': 'Saint-Martin-d\'Oney', 'fr': 'Saint-Martin-d\'Oney'}, '433463':{'de': 'Stainz', 'en': 'Stainz'}, '3353428':{'en': 'Auterive', 'fr': 'Auterive'}, '3597920':{'bg': u('\u0421\u043a\u0440\u0438\u043d\u044f\u043d\u043e'), 'en': 'Skrinyano'}, '3353425':{'en': 'Toulouse', 'fr': 'Toulouse'}, '433113':{'de': 'Pischelsdorf in der Steiermark', 'en': 'Pischelsdorf in der Steiermark'}, '433468':{'de': 'Sankt Oswald ob Eibiswald', 'en': 'St. Oswald ob Eibiswald'}, '437443':{'de': 'Ybbsitz', 'en': 'Ybbsitz'}, '435375':{'de': u('K\u00f6ssen'), 'en': u('K\u00f6ssen')}, '3597921':{'bg': u('\u0416\u0438\u043b\u0435\u043d\u0446\u0438'), 'en': 'Zhilentsi'}, '3593781':{'bg': u('\u0421\u0438\u043c\u0435\u043e\u043d\u043e\u0432\u0433\u0440\u0430\u0434'), 'en': 'Simeonovgrad'}, '3339180':{'en': u('Bruay-la-Buissi\u00e8re'), 'fr': u('Bruay-la-Buissi\u00e8re')}, '3339183':{'en': 'Carvin', 'fr': 'Carvin'}, '42032':{'en': 'Central Bohemian Region'}, '37422393':{'am': u('\u0544\u0565\u0572\u0580\u0561\u0571\u0578\u0580'), 'en': 'Meghradzor', 'ru': u('\u041c\u0435\u0445\u0440\u0430\u0434\u0437\u043e\u0440')}, '37422391':{'am': u('\u053c\u0565\u057c\u0576\u0561\u0576\u056b\u057d\u057f'), 'en': 'Lernanist', 'ru': u('\u041b\u0435\u0440\u043d\u0430\u043d\u0438\u0441\u0442')}, '37422397':{'am': u('\u054d\u0578\u056c\u0561\u056f'), 'en': 'Solak', 'ru': u('\u0421\u043e\u043b\u0430\u043a')}, '37422394':{'am': u('\u0553\u0575\u0578\u0582\u0576\u056b\u0584'), 'en': 'Pyunik', 'ru': u('\u041f\u044e\u043d\u0438\u043a')}, '42035':{'en': 'Karlovy Vary Region'}, '3597922':{'bg': u('\u0414\u0440\u0430\u0433\u043e\u0432\u0438\u0449\u0438\u0446\u0430, \u041a\u044e\u0441\u0442.'), 'en': 'Dragovishtitsa, Kyust.'}, '37422398':{'am': u('\u0532\u057b\u0576\u056b'), 'en': 'Bjni', 'ru': u('\u0411\u0436\u043d\u0438')}, '42039':{'en': 'South Bohemian Region'}, '3347772':{'en': 'Roanne', 'fr': 'Roanne'}, '3522449':{'de': 'Howald', 'en': 'Howald', 'fr': 'Howald'}, '3522448':{'de': 'Contern/Foetz', 'en': 'Contern/Foetz', 'fr': 'Contern/Foetz'}, '3522447':{'de': 'Lintgen', 'en': 'Lintgen', 'fr': 'Lintgen'}, '3596966':{'bg': u('\u0428\u0438\u043f\u043a\u043e\u0432\u043e'), 'en': 'Shipkovo'}, '3522445':{'de': 'Diedrich', 'en': 'Diedrich', 'fr': 'Diedrich'}, '3522443':{'de': 'Findel/Kirchberg', 'en': 'Findel/Kirchberg', 'fr': 'Findel/Kirchberg'}, '3522442':{'de': 'Plateau de Kirchberg', 'en': 'Plateau de Kirchberg', 'fr': 'Plateau de Kirchberg'}, '3522440':{'de': 'Howald', 'en': 'Howald', 'fr': 'Howald'}, '3742680':{'am': u('\u0534\u056b\u056c\u056b\u057b\u0561\u0576'), 'en': 'Dilijan', 'ru': u('\u0414\u0438\u043b\u0438\u0436\u0430\u043d')}, '3596965':{'bg': u('\u0411\u0435\u043b\u0438 \u041e\u0441\u044a\u043c'), 'en': 'Beli Osam'}, '437563':{'de': 'Spital am Pyhrn', 'en': 'Spital am Pyhrn'}, '40237':{'en': 'Vrancea', 'ro': 'Vrancea'}, '3345617':{'en': 'Grenoble', 'fr': 'Grenoble'}, '40232':{'en': u('Ia\u0219i'), 'ro': u('Ia\u0219i')}, '3522667':{'de': u('D\u00fcdelingen'), 'en': 'Dudelange', 'fr': 'Dudelange'}, '37424496':{'am': u('\u0544\u0565\u056e \u0544\u0561\u0576\u0569\u0561\u0577'), 'en': 'Mets Mantash', 'ru': u('\u041c\u0435\u0446 \u041c\u0430\u043d\u0442\u0430\u0448')}, '3338976':{'en': 'Guebwiller', 'fr': 'Guebwiller'}, '3338977':{'en': 'Munster', 'fr': 'Munster'}, '3338974':{'en': 'Guebwiller', 'fr': 'Guebwiller'}, '3338975':{'en': 'Cernay', 'fr': 'Cernay'}, '3338973':{'en': 'Ribeauville', 'fr': 'Ribeauville'}, '3338970':{'en': 'Saint-Louis', 'fr': 'Saint-Louis'}, '3338971':{'en': 'Orbey', 'fr': 'Orbey'}, '437564':{'de': 'Hinterstoder', 'en': 'Hinterstoder'}, '3338978':{'en': 'Kaysersberg', 'fr': 'Kaysersberg'}, '3338979':{'en': 'Colmar', 'fr': 'Colmar'}, '3323864':{'en': 'Saint-Denis-en-Val', 'fr': 'Saint-Denis-en-Val'}, '3323865':{'en': 'Loury', 'fr': 'Loury'}, '3323866':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323867':{'en': 'Gien', 'fr': 'Gien'}, '3323861':{'en': 'Saint-Jean-de-Braye', 'fr': 'Saint-Jean-de-Braye'}, '3323862':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323863':{'en': 'Olivet', 'fr': 'Olivet'}, '3323868':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323869':{'en': 'Olivet', 'fr': 'Olivet'}, '437413':{'de': 'Marbach an der Donau', 'en': 'Marbach an der Donau'}, '437412':{'de': 'Ybbs an der Donau', 'en': 'Ybbs an der Donau'}, '44131':{'en': 'Edinburgh'}, '437416':{'de': 'Wieselburg', 'en': 'Wieselburg'}, '437415':{'de': 'Altenmarkt, Yspertal', 'en': 'Altenmarkt, Yspertal'}, '437414':{'de': 'Weins-Isperdorf', 'en': 'Weins-Isperdorf'}, '40238':{'en': u('Buz\u0103u'), 'ro': u('Buz\u0103u')}, '40239':{'en': u('Br\u0103ila'), 'ro': u('Br\u0103ila')}, '3346821':{'en': 'Saint-Cyprien', 'fr': 'Saint-Cyprien'}, '3346820':{'en': 'Quillan', 'fr': 'Quillan'}, '3346823':{'en': 'Castelnaudary', 'fr': 'Castelnaudary'}, '3346822':{'en': 'Elne', 'fr': 'Elne'}, '3346825':{'en': 'Carcassonne', 'fr': 'Carcassonne'}, '3346827':{'en': u('L\u00e9zignan-Corbi\u00e8res'), 'fr': u('L\u00e9zignan-Corbi\u00e8res')}, '3346826':{'en': 'Carcassonne', 'fr': 'Carcassonne'}, '3346829':{'en': 'Estagel', 'fr': 'Estagel'}, '3346828':{'en': 'Saint-Laurent-de-la-Salanque', 'fr': 'Saint-Laurent-de-la-Salanque'}, '432649':{'de': u('M\u00f6nichkirchen'), 'en': u('M\u00f6nichkirchen')}, '432648':{'de': 'Hochneukirchen', 'en': 'Hochneukirchen'}, '432641':{'de': 'Kirchberg am Wechsel', 'en': 'Kirchberg am Wechsel'}, '432643':{'de': 'Lichtenegg', 'en': 'Lichtenegg'}, '381230':{'en': 'Kikinda', 'sr': 'Kikinda'}, '432645':{'de': 'Wiesmath', 'en': 'Wiesmath'}, '3596960':{'bg': u('\u0411\u0435\u043b\u0438\u0448'), 'en': 'Belish'}, '432647':{'de': u('Krumbach, Nieder\u00f6sterreich'), 'en': 'Krumbach, Lower Austria'}, '432646':{'de': 'Kirchschlag in der Buckligen Welt', 'en': 'Kirchschlag in der Buckligen Welt'}, '390324':{'en': 'Verbano-Cusio-Ossola', 'it': 'Domodossola'}, '441626':{'en': 'Newton Abbot'}, '34888':{'en': 'Ourense', 'es': 'Orense'}, '3593148':{'bg': u('\u0419\u043e\u0430\u043a\u0438\u043c \u0413\u0440\u0443\u0435\u0432\u043e'), 'en': 'Yoakim Gruevo'}, '3593149':{'bg': u('\u0426\u0430\u043b\u0430\u043f\u0438\u0446\u0430'), 'en': 'Tsalapitsa'}, '3593146':{'bg': u('\u041a\u0443\u0440\u0442\u043e\u0432\u043e \u041a\u043e\u043d\u0430\u0440\u0435'), 'en': 'Kurtovo Konare'}, '3593147':{'bg': u('\u041d\u043e\u0432\u043e \u0441\u0435\u043b\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Novo selo, Plovdiv'}, '34880':{'en': 'Zamora', 'es': 'Zamora'}, '34881':{'en': u('La Coru\u00f1a'), 'es': u('La Coru\u00f1a')}, '3593142':{'bg': u('\u0411\u0440\u0435\u0441\u0442\u043e\u0432\u0438\u0446\u0430, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Brestovitsa, Plovdiv'}, '3593143':{'bg': u('\u041f\u0435\u0440\u0443\u0449\u0438\u0446\u0430'), 'en': 'Perushtitsa'}, '34884':{'en': 'Asturias', 'es': 'Asturias'}, '3325470':{'en': u('Mont-pr\u00e9s-Chambord'), 'fr': u('Mont-pr\u00e9s-Chambord')}, '3325473':{'en': u('Vend\u00f4me'), 'fr': u('Vend\u00f4me')}, '3325475':{'en': 'Saint-Aignan', 'fr': 'Saint-Aignan'}, '3325474':{'en': 'Blois', 'fr': 'Blois'}, '3325477':{'en': u('Vend\u00f4me'), 'fr': u('Vend\u00f4me')}, '3325476':{'en': 'Romorantin-Lanthenay', 'fr': 'Romorantin-Lanthenay'}, '3325479':{'en': 'Contres', 'fr': 'Contres'}, '3325478':{'en': 'Blois', 'fr': 'Blois'}, '3324878':{'en': 'Sancerre', 'fr': 'Sancerre'}, '42031':{'en': 'Central Bohemian Region'}, '3324873':{'en': 'Argent-sur-Sauldre', 'fr': 'Argent-sur-Sauldre'}, '3324870':{'en': 'Bourges', 'fr': 'Bourges'}, '3324871':{'en': 'Vierzon', 'fr': 'Vierzon'}, '3324874':{'en': 'Sancoins', 'fr': 'Sancoins'}, '3324875':{'en': 'Vierzon', 'fr': 'Vierzon'}, '433116':{'de': 'Kirchbach in Steiermark', 'en': 'Kirchbach in Steiermark'}, '433117':{'de': 'Eggersdorf bei Graz', 'en': 'Eggersdorf bei Graz'}, '375162':{'be': u('\u0411\u0440\u044d\u0441\u0442'), 'en': 'Brest', 'ru': u('\u0411\u0440\u0435\u0441\u0442')}, '375163':{'be': u('\u0411\u0430\u0440\u0430\u043d\u0430\u0432\u0456\u0447\u044b'), 'en': 'Baranovichi', 'ru': u('\u0411\u0430\u0440\u0430\u043d\u043e\u0432\u0438\u0447\u0438')}, '433112':{'de': 'Gleisdorf', 'en': 'Gleisdorf'}, '375165':{'be': u('\u041f\u0456\u043d\u0441\u043a'), 'en': 'Pinsk', 'ru': u('\u041f\u0438\u043d\u0441\u043a')}, '3628':{'en': 'Godollo', 'hu': u('G\u00f6d\u00f6ll\u0151')}, '433118':{'de': 'Sinabelkirchen', 'en': 'Sinabelkirchen'}, '433119':{'de': 'Sankt Marein bei Graz', 'en': 'St. Marein bei Graz'}, '3597447':{'bg': u('\u0414\u043e\u0431\u0440\u0438\u043d\u0438\u0449\u0435'), 'en': 'Dobrinishte'}, '3347168':{'en': 'Mauriac', 'fr': 'Mauriac'}, '3347167':{'en': 'Mauriac', 'fr': 'Mauriac'}, '3347166':{'en': 'Monistrol-sur-Loire', 'fr': 'Monistrol-sur-Loire'}, '3347165':{'en': 'Yssingeaux', 'fr': 'Yssingeaux'}, '3347164':{'en': 'Aurillac', 'fr': 'Aurillac'}, '3347163':{'en': 'Aurillac', 'fr': 'Aurillac'}, '359596':{'bg': u('\u041f\u043e\u043c\u043e\u0440\u0438\u0435'), 'en': 'Pomorie'}, '3347160':{'en': 'Saint-Flour', 'fr': 'Saint-Flour'}, '3598147':{'bg': u('\u0411\u0430\u043d\u0438\u0441\u043a\u0430'), 'en': 'Baniska'}, '3598145':{'bg': u('\u0422\u0440\u044a\u0441\u0442\u0435\u043d\u0438\u043a, \u0420\u0443\u0441\u0435'), 'en': 'Trastenik, Ruse'}, '3598144':{'bg': u('\u0411\u0430\u0442\u0438\u0448\u043d\u0438\u0446\u0430'), 'en': 'Batishnitsa'}, '3598143':{'bg': u('\u041e\u0431\u0440\u0435\u0442\u0435\u043d\u0438\u043a'), 'en': 'Obretenik'}, '3598142':{'bg': u('\u0411\u044a\u0437\u043e\u0432\u0435\u0446, \u0420\u0443\u0441\u0435'), 'en': 'Bazovets, Ruse'}, '3598141':{'bg': u('\u0414\u0432\u0435 \u043c\u043e\u0433\u0438\u043b\u0438'), 'en': 'Dve mogili'}, '3598140':{'bg': u('\u0411\u043e\u0440\u043e\u0432\u043e, \u0420\u0443\u0441\u0435'), 'en': 'Borovo, Ruse'}, '3598149':{'bg': u('\u041a\u0430\u0446\u0435\u043b\u043e\u0432\u043e'), 'en': 'Katselovo'}, '3598148':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u0410\u0431\u043b\u0430\u043d\u043e\u0432\u043e'), 'en': 'Gorno Ablanovo'}, '3599117':{'bg': u('\u041a\u0440\u0438\u0432\u043e\u0434\u043e\u043b'), 'en': 'Krivodol'}, '3336978':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3347702':{'en': u('Andr\u00e9zieux-Bouth\u00e9on'), 'fr': u('Andr\u00e9zieux-Bouth\u00e9on')}, '3347701':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3336977':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3347706':{'en': 'Veauche', 'fr': 'Veauche'}, '3316943':{'en': 'Ris-Orangis', 'fr': 'Ris-Orangis'}, '3316942':{'en': 'Draveil', 'fr': 'Draveil'}, '3316941':{'en': 'Igny', 'fr': 'Igny'}, '3316940':{'en': 'Draveil', 'fr': 'Draveil'}, '3316947':{'en': u('\u00c9vry'), 'fr': u('\u00c9vry')}, '3316946':{'en': u('Sainte-Genevi\u00e8ve-des-Bois'), 'fr': u('Sainte-Genevi\u00e8ve-des-Bois')}, '3316945':{'en': 'Juvisy-sur-Orge', 'fr': 'Juvisy-sur-Orge'}, '3316944':{'en': 'Savigny-sur-Orge', 'fr': 'Savigny-sur-Orge'}, '3316949':{'en': 'Yerres', 'fr': 'Yerres'}, '3316948':{'en': 'Yerres', 'fr': 'Yerres'}, '3599119':{'bg': u('\u0422\u0438\u0448\u0435\u0432\u0438\u0446\u0430'), 'en': 'Tishevitsa'}, '3343426':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3343422':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3597415':{'bg': u('\u0421\u0435\u043b\u0438\u0449\u0435, \u0411\u043b\u0430\u0433.'), 'en': 'Selishte, Blag.'}, '3343428':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3343429':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3329758':{'en': 'Baden', 'fr': 'Baden'}, '3329750':{'en': 'Quiberon', 'fr': 'Quiberon'}, '3329752':{'en': 'Carnac', 'fr': 'Carnac'}, '3329753':{'en': 'Elven', 'fr': 'Elven'}, '3329754':{'en': 'Vannes', 'fr': 'Vannes'}, '3329755':{'en': 'Belz', 'fr': 'Belz'}, '3329756':{'en': 'Auray', 'fr': 'Auray'}, '3329757':{'en': 'Baden', 'fr': 'Baden'}, '3596321':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u0421\u0442\u0443\u0434\u0435\u043d\u0430'), 'en': 'Gorna Studena'}, '3596323':{'bg': u('\u0411\u044a\u043b\u0433\u0430\u0440\u0441\u043a\u043e \u0441\u043b\u0438\u0432\u043e\u0432\u043e'), 'en': 'Balgarsko slivovo'}, '3596322':{'bg': u('\u0410\u043b\u0435\u043a\u043e\u0432\u043e, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Alekovo, V. Tarnovo'}, '3596325':{'bg': u('\u041a\u043e\u0437\u043b\u043e\u0432\u0435\u0446'), 'en': 'Kozlovets'}, '3596324':{'bg': u('\u0412\u0430\u0440\u0434\u0438\u043c'), 'en': 'Vardim'}, '3596327':{'bg': u('\u041e\u0432\u0447\u0430 \u043c\u043e\u0433\u0438\u043b\u0430'), 'en': 'Ovcha mogila'}, '3596326':{'bg': u('\u041c\u043e\u0440\u0430\u0432\u0430'), 'en': 'Morava'}, '3596329':{'bg': u('\u0426\u0430\u0440\u0435\u0432\u0435\u0446, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Tsarevets, V. Tarnovo'}, '3596328':{'bg': u('\u041e\u0440\u0435\u0448'), 'en': 'Oresh'}, '3323189':{'en': 'Honfleur', 'fr': 'Honfleur'}, '3323188':{'en': 'Deauville', 'fr': 'Deauville'}, '3323183':{'en': 'Caen', 'fr': 'Caen'}, '3323182':{'en': 'Caen', 'fr': 'Caen'}, '3323181':{'en': 'Deauville', 'fr': 'Deauville'}, '3323187':{'en': 'Villers-sur-Mer', 'fr': 'Villers-sur-Mer'}, '3323186':{'en': 'Caen', 'fr': 'Caen'}, '3323185':{'en': 'Caen', 'fr': 'Caen'}, '3323184':{'en': 'Caen', 'fr': 'Caen'}, '3322854':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '3322853':{'en': 'Saint-Brevin-les-Pins', 'fr': 'Saint-Brevin-les-Pins'}, '432859':{'de': 'Brand-Nagelberg', 'en': 'Brand-Nagelberg'}, '3354531':{'en': 'Ruffec', 'fr': 'Ruffec'}, '3354532':{'en': 'Cognac', 'fr': 'Cognac'}, '3354535':{'en': 'Cognac', 'fr': 'Cognac'}, '3354536':{'en': 'Cognac', 'fr': 'Cognac'}, '3354537':{'en': u('Angoul\u00eame'), 'fr': u('Angoul\u00eame')}, '3354538':{'en': u('Angoul\u00eame'), 'fr': u('Angoul\u00eame')}, '3354539':{'en': 'Chasseneuil-sur-Bonnieure', 'fr': 'Chasseneuil-sur-Bonnieure'}, '3597741':{'bg': u('\u0417\u0435\u043c\u0435\u043d'), 'en': 'Zemen'}, '3329800':{'en': 'Brest', 'fr': 'Brest'}, '3323326':{'en': u('Alen\u00e7on'), 'fr': u('Alen\u00e7on')}, '3329802':{'en': 'Brest', 'fr': 'Brest'}, '3323324':{'en': 'L\'Aigle', 'fr': 'L\'Aigle'}, '3323323':{'en': 'Cherbourg-Octeville', 'fr': 'Cherbourg-Octeville'}, '3323322':{'en': 'Tourlaville', 'fr': 'Tourlaville'}, '3355669':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3323320':{'en': 'Cherbourg-Octeville', 'fr': 'Cherbourg-Octeville'}, '3355915':{'en': 'Anglet', 'fr': 'Anglet'}, '3329809':{'en': 'Pont-Aven', 'fr': 'Pont-Aven'}, '3355664':{'en': u('L\u00e9ognan'), 'fr': u('L\u00e9ognan')}, '3355663':{'en': 'Langon', 'fr': 'Langon'}, '3323329':{'en': u('Alen\u00e7on'), 'fr': u('Alen\u00e7on')}, '3323328':{'en': u('Alen\u00e7on'), 'fr': u('Alen\u00e7on')}, '3349257':{'en': 'Veynes', 'fr': 'Veynes'}, '3349256':{'en': 'Gap', 'fr': 'Gap'}, '3349255':{'en': u('Orci\u00e8res'), 'fr': u('Orci\u00e8res')}, '355860':{'en': u('Trebinj\u00eb/Proptisht/Vel\u00e7an, Pogradec')}, '3349253':{'en': 'Gap', 'fr': 'Gap'}, '3349252':{'en': 'Gap', 'fr': 'Gap'}, '3349251':{'en': 'Gap', 'fr': 'Gap'}, '3349702':{'en': 'Cagnes-sur-Mer', 'fr': 'Cagnes-sur-Mer'}, '355869':{'en': u('\u00c7\u00ebrav\u00eb/Dardhas, Pogradec')}, '355868':{'en': u('Bu\u00e7imas/Udenisht, Pogradec')}, '3349708':{'en': 'Nice', 'fr': 'Nice'}, '3349259':{'en': 'Cannes', 'fr': 'Cannes'}, '3349258':{'en': 'Veynes', 'fr': 'Veynes'}, '432855':{'de': 'Waldenstein', 'en': 'Waldenstein'}, '441809':{'en': 'Tomdoun'}, '441808':{'en': 'Tomatin'}, '441805':{'en': 'Torrington'}, '441807':{'en': 'Ballindalloch'}, '441806':{'en': 'Shetland'}, '3597193':{'bg': u('\u0413\u043e\u043b\u0435\u0448, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Golesh, Sofia'}, '441803':{'en': 'Torquay'}, '3594330':{'bg': u('\u041d\u0438\u043a\u043e\u043b\u0430\u0435\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Nikolaevo, St. Zagora'}, '3594331':{'bg': u('\u0413\u0443\u0440\u043a\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Gurkovo, St. Zagora'}, '3594332':{'bg': u('\u0412\u0435\u0442\u0440\u0435\u043d, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Vetren, St. Zagora'}, '3594333':{'bg': u('\u0414\u044a\u0431\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Dabovo, St. Zagora'}, '3317702':{'en': 'Argenteuil', 'fr': 'Argenteuil'}, '3594335':{'bg': u('\u0420\u044a\u0436\u0435\u043d\u0430'), 'en': 'Razhena'}, '3594336':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u0418\u0437\u0432\u043e\u0440\u043e\u0432\u043e'), 'en': 'Dolno Izvorovo'}, '3594337':{'bg': u('\u042f\u0441\u0435\u043d\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Yasenovo, St. Zagora'}, '3594338':{'bg': u('\u041a\u0440\u044a\u043d'), 'en': 'Kran'}, '3594339':{'bg': u('\u042e\u043b\u0438\u0435\u0432\u043e'), 'en': 'Yulievo'}, '3598448':{'bg': u('\u0422\u0435\u0440\u0442\u0435\u0440'), 'en': 'Terter'}, '3598442':{'bg': u('\u0417\u0430\u0432\u0435\u0442, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Zavet, Razgrad'}, '35981262':{'bg': u('\u0411\u0438\u0441\u0442\u0440\u0435\u043d\u0446\u0438'), 'en': 'Bistrentsi'}, '3598445':{'bg': u('\u042e\u043f\u0435\u0440'), 'en': 'Yuper'}, '3322325':{'en': u('Saint-Gr\u00e9goire'), 'fr': u('Saint-Gr\u00e9goire')}, '437353':{'de': 'Gaflenz', 'en': 'Gaflenz'}, '3322320':{'en': 'Rennes', 'fr': 'Rennes'}, '3322321':{'en': 'Rennes', 'fr': 'Rennes'}, '3322322':{'en': 'Montreuil-sur-Ille', 'fr': 'Montreuil-sur-Ille'}, '437357':{'de': 'Kleinreifling', 'en': 'Kleinreifling'}, '34874':{'en': 'Huesca', 'es': 'Huesca'}, '3332816':{'en': 'Seclin', 'fr': 'Seclin'}, '3332814':{'en': 'Lille', 'fr': 'Lille'}, '359720':{'bg': u('\u0415\u0442\u0440\u043e\u043f\u043e\u043b\u0435'), 'en': 'Etropole'}, '3338349':{'en': 'Pompey', 'fr': 'Pompey'}, '3338348':{'en': 'Dombasle-sur-Meurthe', 'fr': 'Dombasle-sur-Meurthe'}, '359721':{'bg': u('\u041a\u043e\u0441\u0442\u0438\u043d\u0431\u0440\u043e\u0434'), 'en': 'Kostinbrod'}, '3338345':{'en': 'Dombasle-sur-Meurthe', 'fr': 'Dombasle-sur-Meurthe'}, '3338344':{'en': u('Vand\u0153uvre-l\u00e8s-Nancy'), 'fr': u('Vand\u0153uvre-l\u00e8s-Nancy')}, '3338347':{'en': 'Neuves-Maisons', 'fr': 'Neuves-Maisons'}, '3338341':{'en': 'Nancy', 'fr': 'Nancy'}, '3338340':{'en': 'Nancy', 'fr': 'Nancy'}, '3338343':{'en': 'Toul', 'fr': 'Toul'}, '359723':{'bg': u('\u0411\u043e\u0442\u0435\u0432\u0433\u0440\u0430\u0434'), 'en': 'Botevgrad'}, '359724':{'bg': u('\u0418\u0445\u0442\u0438\u043c\u0430\u043d'), 'en': 'Ihtiman'}, '434224':{'de': 'Pischeldorf', 'en': 'Pischeldorf'}, '359727':{'bg': u('\u0421\u043b\u0438\u0432\u043d\u0438\u0446\u0430, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Slivnitsa, Sofia'}, '3595319':{'bg': u('\u0414\u0440\u0443\u043c\u0435\u0432\u043e'), 'en': 'Drumevo'}, '3595318':{'bg': u('\u0421\u0440\u0435\u0434\u043d\u044f'), 'en': 'Srednya'}, '3595315':{'bg': u('\u0426\u0430\u0440\u0435\u0432 \u0431\u0440\u043e\u0434'), 'en': 'Tsarev brod'}, '3595314':{'bg': u('\u0411\u0435\u043b\u043e\u043a\u043e\u043f\u0438\u0442\u043e\u0432\u043e'), 'en': 'Belokopitovo'}, '3595317':{'bg': u('\u0418\u0432\u0430\u043d\u0441\u043a\u0438'), 'en': 'Ivanski'}, '3595316':{'bg': u('\u0421\u0430\u043b\u043c\u0430\u043d\u043e\u0432\u043e'), 'en': 'Salmanovo'}, '3595311':{'bg': u('\u0413\u0440\u0430\u0434\u0438\u0449\u0435, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Gradishte, Shumen'}, '3595310':{'bg': u('\u0420\u0430\u0434\u043a\u043e \u0414\u0438\u043c\u0438\u0442\u0440\u0438\u0435\u0432\u043e'), 'en': 'Radko Dimitrievo'}, '3595313':{'bg': u('\u041c\u0430\u0434\u0430\u0440\u0430'), 'en': 'Madara'}, '3595312':{'bg': u('\u0414\u0438\u0431\u0438\u0447'), 'en': 'Dibich'}, '432146':{'de': 'Nickelsdorf', 'en': 'Nickelsdorf'}, '433329':{'de': 'Jennersdorf', 'en': 'Jennersdorf'}, '3356580':{'en': 'Montbazens', 'fr': 'Montbazens'}, '3599319':{'bg': u('\u0413\u044a\u043c\u0437\u043e\u0432\u043e'), 'en': 'Gamzovo'}, '3599318':{'bg': u('\u0411\u0443\u043a\u043e\u0432\u0435\u0446, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Bukovets, Vidin'}, '432145':{'de': 'Prellenkirchen', 'en': 'Prellenkirchen'}, '3599311':{'bg': u('\u041a\u0443\u0442\u043e\u0432\u043e'), 'en': 'Kutovo'}, '432142':{'de': 'Gattendorf', 'en': 'Gattendorf'}, '3599313':{'bg': u('\u041a\u0430\u043f\u0438\u0442\u0430\u043d\u043e\u0432\u0446\u0438'), 'en': 'Kapitanovtsi'}, '3599312':{'bg': u('\u0411\u0440\u0435\u0433\u043e\u0432\u043e, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Bregovo, Vidin'}, '3599315':{'bg': u('\u0413\u0440\u0430\u0434\u0435\u0446, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Gradets, Vidin'}, '3599314':{'bg': u('\u0414\u0443\u043d\u0430\u0432\u0446\u0438, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Dunavtsi, Vidin'}, '3599317':{'bg': u('\u0410\u0440\u0447\u0430\u0440'), 'en': 'Archar'}, '3599316':{'bg': u('\u041d\u043e\u0432\u043e \u0441\u0435\u043b\u043e, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Novo selo, Vidin'}, '3347570':{'en': u('Romans-sur-Is\u00e8re'), 'fr': u('Romans-sur-Is\u00e8re')}, '3347571':{'en': u('Romans-sur-Is\u00e8re'), 'fr': u('Romans-sur-Is\u00e8re')}, '3347572':{'en': u('Romans-sur-Is\u00e8re'), 'fr': u('Romans-sur-Is\u00e8re')}, '3347575':{'en': 'Valence', 'fr': 'Valence'}, '3347576':{'en': 'Crest', 'fr': 'Crest'}, '433858':{'de': u('Mitterdorf im M\u00fcrztal'), 'en': u('Mitterdorf im M\u00fcrztal')}, '3347578':{'en': 'Valence', 'fr': 'Valence'}, '3347579':{'en': 'Valence', 'fr': 'Valence'}, '433855':{'de': 'Krieglach', 'en': 'Krieglach'}, '433854':{'de': 'Langenwang', 'en': 'Langenwang'}, '433853':{'de': 'Spital am Semmering', 'en': 'Spital am Semmering'}, '433852':{'de': u('M\u00fcrzzuschlag'), 'en': u('M\u00fcrzzuschlag')}, '435524':{'de': 'Satteins', 'en': 'Satteins'}, '3334415':{'en': 'Beauvais', 'fr': 'Beauvais'}, '3334414':{'en': 'Beauvais', 'fr': 'Beauvais'}, '3334411':{'en': 'Beauvais', 'fr': 'Beauvais'}, '3334410':{'en': 'Beauvais', 'fr': 'Beauvais'}, '3334412':{'en': 'Beauvais', 'fr': 'Beauvais'}, '35971398':{'bg': u('\u041e\u0441\u0438\u043a\u043e\u0432\u0438\u0446\u0430'), 'en': 'Osikovitsa'}, '35981268':{'bg': u('\u041a\u0440\u0438\u0432\u0438\u043d\u0430, \u0420\u0443\u0441\u0435'), 'en': 'Krivina, Ruse'}, '3599175':{'bg': u('\u041e\u0441\u0442\u0440\u043e\u0432'), 'en': 'Ostrov'}, '3599174':{'bg': u('\u0413\u043e\u0440\u043d\u0438 \u0412\u0430\u0434\u0438\u043d'), 'en': 'Gorni Vadin'}, '3599176':{'bg': u('\u041b\u0435\u0441\u043a\u043e\u0432\u0435\u0446, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Leskovets, Vratsa'}, '3599171':{'bg': u('\u041e\u0440\u044f\u0445\u043e\u0432\u043e, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Oryahovo, Vratsa'}, '3599173':{'bg': u('\u0413\u0430\u043b\u043e\u0432\u043e'), 'en': 'Galovo'}, '3599172':{'bg': u('\u0421\u0435\u043b\u0430\u043d\u043e\u0432\u0446\u0438'), 'en': 'Selanovtsi'}, '433583':{'de': 'Unzmarkt', 'en': 'Unzmarkt'}, '3353154':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3353401':{'en': 'Pamiers', 'fr': 'Pamiers'}, '35984778':{'bg': u('\u0411\u043e\u0433\u0434\u0430\u043d\u0446\u0438, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Bogdantsi, Razgrad'}, '3353409':{'en': 'Foix', 'fr': 'Foix'}, '3594593':{'bg': u('\u0428\u0438\u0432\u0430\u0447\u0435\u0432\u043e'), 'en': 'Shivachevo'}, '435248':{'de': 'Steinberg am Rofan', 'en': 'Steinberg am Rofan'}, '3594597':{'bg': u('\u0411\u043e\u0440\u043e\u0432 \u0434\u043e\u043b'), 'en': 'Borov dol'}, '46247':{'en': u('Leksand-Insj\u00f6n'), 'sv': u('Leksand-Insj\u00f6n')}, '3347394':{'en': 'Puy-Guillaume', 'fr': 'Puy-Guillaume'}, '3347390':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3347391':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3347392':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3347393':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3347398':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '46240':{'en': 'Ludvika-Smedjebacken', 'sv': 'Ludvika-Smedjebacken'}, '3329701':{'en': 'Vannes', 'fr': 'Vannes'}, '3346629':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346628':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346627':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346626':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346625':{'en': u('Bess\u00e8ges'), 'fr': u('Bess\u00e8ges')}, '3346624':{'en': 'Saint-Ambroix', 'fr': 'Saint-Ambroix'}, '3346623':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346622':{'en': u('Uz\u00e8s'), 'fr': u('Uz\u00e8s')}, '3346621':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346620':{'en': 'Bouillargues', 'fr': 'Bouillargues'}, '3597755':{'bg': u('\u0412\u0435\u043b\u043a\u043e\u0432\u0446\u0438, \u041f\u0435\u0440\u043d\u0438\u043a'), 'en': 'Velkovtsi, Pernik'}, '3597754':{'bg': u('\u041a\u043e\u0448\u0430\u0440\u0435\u0432\u043e'), 'en': 'Kosharevo'}, '3597753':{'bg': u('\u041d\u043e\u0435\u0432\u0446\u0438'), 'en': 'Noevtsi'}, '3597752':{'bg': u('\u0420\u0435\u0436\u0430\u043d\u0446\u0438'), 'en': 'Rezhantsi'}, '3597751':{'bg': u('\u0411\u0440\u0435\u0437\u043d\u0438\u043a'), 'en': 'Breznik'}, '433326':{'de': 'Stegersbach', 'en': 'Stegersbach'}, '3522467':{'de': u('D\u00fcdelingen'), 'en': 'Dudelange', 'fr': 'Dudelange'}, '3522645':{'de': 'Diedrich', 'en': 'Diedrich', 'fr': 'Diedrich'}, '3522647':{'de': 'Lintgen', 'en': 'Lintgen', 'fr': 'Lintgen'}, '3522640':{'de': 'Howald', 'en': 'Howald', 'fr': 'Howald'}, '3522643':{'de': 'Findel/Kirchberg', 'en': 'Findel/Kirchberg', 'fr': 'Findel/Kirchberg'}, '3522642':{'de': 'Plateau de Kirchberg', 'en': 'Plateau de Kirchberg', 'fr': 'Plateau de Kirchberg'}, '3522649':{'de': 'Howald', 'en': 'Howald', 'fr': 'Howald'}, '3522648':{'de': 'Contern/Foetz', 'en': 'Contern/Foetz', 'fr': 'Contern/Foetz'}, '3742377':{'am': u('\u0544\u0580\u0563\u0561\u0577\u0561\u057f'), 'en': 'Mrgashat', 'ru': u('\u041c\u0440\u0433\u0430\u0448\u0430\u0442')}, '37517':{'be': u('\u041c\u0456\u043d\u0441\u043a'), 'en': 'Minsk', 'ru': u('\u041c\u0438\u043d\u0441\u043a')}, '3742379':{'am': u('\u0546\u0561\u056c\u0562\u0561\u0576\u0564\u0575\u0561\u0576'), 'en': 'Nalbandian', 'ru': u('\u041d\u0430\u043b\u0431\u0430\u043d\u0434\u044f\u043d')}, '3323849':{'en': 'Olivet', 'fr': 'Olivet'}, '3323844':{'en': 'Beaugency', 'fr': 'Beaugency'}, '3323845':{'en': u('Cl\u00e9ry-Saint-Andr\u00e9'), 'fr': u('Cl\u00e9ry-Saint-Andr\u00e9')}, '3323842':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323843':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323841':{'en': 'Sandillon', 'fr': 'Sandillon'}, '4415391':{'en': 'Kendal'}, '4415390':{'en': 'Kendal'}, '4415393':{'en': 'Kendal'}, '44118':{'en': 'Reading'}, '4415395':{'en': 'Grange-over-Sands'}, '4415394':{'en': 'Hawkshead'}, '4415397':{'en': 'Kendal'}, '4415396':{'en': 'Sedbergh'}, '44113':{'en': 'Leeds'}, '4415398':{'en': 'Kendal'}, '44117':{'en': 'Bristol'}, '44116':{'en': 'Leicester'}, '44115':{'en': 'Nottingham'}, '44114':{'en': 'Sheffield'}, '3355914':{'en': 'Pau', 'fr': 'Pau'}, '3348665':{'en': 'Avignon', 'fr': 'Avignon'}, '3346849':{'en': 'Gruissan', 'fr': 'Gruissan'}, '3346848':{'en': 'Sigean', 'fr': 'Sigean'}, '3346842':{'en': 'Narbonne', 'fr': 'Narbonne'}, '3346841':{'en': 'Narbonne', 'fr': 'Narbonne'}, '3346840':{'en': 'Leucate', 'fr': 'Leucate'}, '3346847':{'en': 'Carcassonne', 'fr': 'Carcassonne'}, '441726':{'en': 'St Austell'}, '3346844':{'en': 'Saint-Laurent-de-la-Cabrerisse', 'fr': 'Saint-Laurent-de-la-Cabrerisse'}, '3349396':{'en': 'Nice', 'fr': 'Nice'}, '3349397':{'en': 'Nice', 'fr': 'Nice'}, '3349394':{'en': 'Cannes', 'fr': 'Cannes'}, '3349395':{'en': 'Antibes Juan les Pins', 'fr': 'Antibes Juan les Pins'}, '3349392':{'en': 'Nice', 'fr': 'Nice'}, '3349393':{'en': 'Mandelieu-la-Napoule', 'fr': 'Mandelieu-la-Napoule'}, '3349390':{'en': 'Cannes', 'fr': 'Cannes'}, '442838':{'en': 'Portadown'}, '3349398':{'en': 'Nice', 'fr': 'Nice'}, '3349399':{'en': 'Cannes', 'fr': 'Cannes'}, '3348914':{'en': 'Nice', 'fr': 'Nice'}, '433148':{'de': 'Kainach bei Voitsberg', 'en': 'Kainach bei Voitsberg'}, '3596988':{'bg': u('\u041f\u0435\u0449\u0435\u0440\u043d\u0430'), 'en': 'Peshterna'}, '3593128':{'bg': u('\u0417\u043b\u0430\u0442\u0438\u0442\u0440\u0430\u043f'), 'en': 'Zlatitrap'}, '3593129':{'bg': u('\u0421\u043a\u0443\u0442\u0430\u0440\u0435'), 'en': 'Skutare'}, '3332662':{'en': u('Vitry-le-Fran\u00e7ois'), 'fr': u('Vitry-le-Fran\u00e7ois')}, '3332664':{'en': u('Ch\u00e2lons-en-Champagne'), 'fr': u('Ch\u00e2lons-en-Champagne')}, '3332665':{'en': u('Ch\u00e2lons-en-Champagne'), 'fr': u('Ch\u00e2lons-en-Champagne')}, '3332668':{'en': u('Ch\u00e2lons-en-Champagne'), 'fr': u('Ch\u00e2lons-en-Champagne')}, '3593121':{'bg': u('\u0420\u043e\u0433\u043e\u0448'), 'en': 'Rogosh'}, '3593122':{'bg': u('\u041c\u0430\u043d\u043e\u043b\u0435'), 'en': 'Manole'}, '3593123':{'bg': u('\u041a\u0430\u043b\u043e\u044f\u043d\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Kaloyanovo, Plovdiv'}, '3593124':{'bg': u('\u041a\u0430\u043b\u0435\u043a\u043e\u0432\u0435\u0446'), 'en': 'Kalekovets'}, '3593125':{'bg': u('\u0420\u044a\u0436\u0435\u0432\u043e \u041a\u043e\u043d\u0430\u0440\u0435'), 'en': 'Razhevo Konare'}, '3593126':{'bg': u('\u0422\u0440\u0443\u0434'), 'en': 'Trud'}, '3593127':{'bg': u('\u0426\u0430\u0440\u0430\u0446\u043e\u0432\u043e'), 'en': 'Tsaratsovo'}, '435243':{'de': 'Maurach', 'en': 'Maurach'}, '3355588':{'en': 'Brive-la-Gaillarde', 'fr': 'Brive-la-Gaillarde'}, '435244':{'de': 'Jenbach', 'en': 'Jenbach'}, '390131':{'en': 'Alessandria', 'it': 'Alessandria'}, '35959409':{'bg': u('\u0427\u0435\u0440\u0435\u0448\u0430'), 'en': 'Cheresha'}, '35959408':{'bg': u('\u0420\u044a\u0436\u0438\u0446\u0430'), 'en': 'Razhitsa'}, '432667':{'de': 'Schwarzau im Gebirge', 'en': 'Schwarzau im Gebirge'}, '432666':{'de': 'Reichenau', 'en': 'Reichenau'}, '432665':{'de': 'Prein an der Rax', 'en': 'Prein an der Rax'}, '432664':{'de': 'Semmering', 'en': 'Semmering'}, '35959400':{'bg': u('\u0414\u044a\u0441\u043a\u043e\u0442\u043d\u0430'), 'en': 'Daskotna'}, '35959403':{'bg': u('\u0420\u0435\u0447\u0438\u0446\u0430'), 'en': 'Rechitsa'}, '35959405':{'bg': u('\u0417\u0430\u0439\u0447\u0430\u0440'), 'en': 'Zaychar'}, '35959404':{'bg': u('\u042f\u0441\u0435\u043d\u043e\u0432\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Yasenovo, Burgas'}, '35959407':{'bg': u('\u0421\u0438\u043d\u0438 \u0440\u0438\u0434'), 'en': 'Sini rid'}, '35959406':{'bg': u('\u0420\u0430\u0437\u0431\u043e\u0439\u043d\u0430, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Razboyna, Burgas'}, '433132':{'de': 'Kumberg', 'en': 'Kumberg'}, '433133':{'de': 'Nestelbach', 'en': 'Nestelbach'}, '433134':{'de': 'Heiligenkreuz am Waasen', 'en': 'Heiligenkreuz am Waasen'}, '433135':{'de': 'Kalsdorf bei Graz', 'en': 'Kalsdorf bei Graz'}, '433136':{'de': 'Dobl', 'en': 'Dobl'}, '390735':{'en': 'Ascoli Piceno', 'it': 'San Benedetto del Tronto'}, '390737':{'en': 'Macerata', 'it': 'Camerino'}, '435246':{'de': 'Achenkirch', 'en': 'Achenkirch'}, '390731':{'en': 'Ancona', 'it': 'Jesi'}, '35974386':{'bg': u('\u041f\u0438\u0440\u0438\u043d'), 'en': 'Pirin'}, '390345':{'it': 'San Pellegrino Terme'}, '390733':{'en': 'Macerata', 'it': 'Macerata'}, '35974388':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u0421\u043f\u0430\u043d\u0447\u0435\u0432\u043e'), 'en': 'Gorno Spanchevo'}, '3595782':{'bg': u('\u0411\u0435\u043d\u043a\u043e\u0432\u0441\u043a\u0438, \u0414\u043e\u0431\u0440.'), 'en': 'Benkovski, Dobr.'}, '3347148':{'en': 'Aurillac', 'fr': 'Aurillac'}, '3347498':{'en': 'Villars-les-Dombes', 'fr': 'Villars-les-Dombes'}, '3347493':{'en': 'Bourgoin-Jallieu', 'fr': 'Bourgoin-Jallieu'}, '3347143':{'en': 'Aurillac', 'fr': 'Aurillac'}, '3347490':{'en': u('Cr\u00e9mieu'), 'fr': u('Cr\u00e9mieu')}, '3347497':{'en': 'La Tour du Pin', 'fr': 'La Tour du Pin'}, '3347496':{'en': 'Villefontaine', 'fr': 'Villefontaine'}, '3347495':{'en': 'Saint-Quentin-Fallavier', 'fr': 'Saint-Quentin-Fallavier'}, '3347494':{'en': 'Saint-Quentin-Fallavier', 'fr': 'Saint-Quentin-Fallavier'}, '3598161':{'bg': u('\u0412\u0435\u0442\u043e\u0432\u043e'), 'en': 'Vetovo'}, '3598163':{'bg': u('\u0411\u044a\u0437\u044a\u043d'), 'en': 'Bazan'}, '3598165':{'bg': u('\u0421\u043c\u0438\u0440\u043d\u0435\u043d\u0441\u043a\u0438, \u0420\u0443\u0441\u0435'), 'en': 'Smirnenski, Ruse'}, '3598164':{'bg': u('\u041f\u0438\u0441\u0430\u043d\u0435\u0446'), 'en': 'Pisanets'}, '3598167':{'bg': u('\u0426\u0435\u0440\u043e\u0432\u0435\u0446'), 'en': 'Tserovets'}, '3598166':{'bg': u('\u0421\u0432\u0430\u043b\u0435\u043d\u0438\u043a'), 'en': 'Svalenik'}, '3338288':{'en': 'Thionville', 'fr': 'Thionville'}, '3338289':{'en': 'Villerupt', 'fr': 'Villerupt'}, '4416971':{'en': 'Brampton'}, '3338282':{'en': 'Thionville', 'fr': 'Thionville'}, '3338284':{'en': 'Hayange', 'fr': 'Hayange'}, '3338285':{'en': 'Hayange', 'fr': 'Hayange'}, '3338286':{'en': 'Uckange', 'fr': 'Uckange'}, '4416973':{'en': 'Wigton'}, '3599782':{'bg': u('\u0411\u0443\u043a\u043e\u0432\u0435\u0446, \u041c\u043e\u043d\u0442.'), 'en': 'Bukovets, Mont.'}, '3599783':{'bg': u('\u0411\u0440\u0443\u0441\u0430\u0440\u0446\u0438'), 'en': 'Brusartsi'}, '3599787':{'bg': u('\u0421\u043c\u0438\u0440\u043d\u0435\u043d\u0441\u043a\u0438, \u041c\u043e\u043d\u0442.'), 'en': 'Smirnenski, Mont.'}, '3599784':{'bg': u('\u041a\u0438\u0441\u0435\u043b\u0435\u0432\u043e'), 'en': 'Kiselevo'}, '3599785':{'bg': u('\u0412\u0430\u0441\u0438\u043b\u043e\u0432\u0446\u0438, \u041c\u043e\u043d\u0442.'), 'en': 'Vasilovtsi, Mont.'}, '4416976':{'en': 'Brampton'}, '4416977':{'en': 'Brampton'}, '3338132':{'en': u('Montb\u00e9liard'), 'fr': u('Montb\u00e9liard')}, '3338130':{'en': 'Audincourt', 'fr': 'Audincourt'}, '3338131':{'en': u('Montb\u00e9liard'), 'fr': u('Montb\u00e9liard')}, '3338136':{'en': 'Audincourt', 'fr': 'Audincourt'}, '3338137':{'en': 'Valentigney', 'fr': 'Valentigney'}, '3338134':{'en': 'Audincourt', 'fr': 'Audincourt'}, '3338135':{'en': 'Audincourt', 'fr': 'Audincourt'}, '435477':{'de': u('T\u00f6sens'), 'en': u('T\u00f6sens')}, '435476':{'de': 'Serfaus', 'en': 'Serfaus'}, '3338138':{'en': 'Pontarlier', 'fr': 'Pontarlier'}, '3338139':{'en': 'Pontarlier', 'fr': 'Pontarlier'}, '435473':{'de': 'Nauders', 'en': 'Nauders'}, '435472':{'de': 'Prutz', 'en': 'Prutz'}, '390771':{'it': 'Formia'}, '433587':{'de': u('Sch\u00f6nberg-Lachtal'), 'en': u('Sch\u00f6nberg-Lachtal')}, '4162':{'de': 'Olten', 'en': 'Olten', 'fr': 'Olten', 'it': 'Olten'}, '4161':{'de': 'Basel', 'en': 'Basel', 'fr': u('B\u00e2le'), 'it': 'Basilea'}, '3349376':{'en': 'Saint-Jean-Cap-Ferrat', 'fr': 'Saint-Jean-Cap-Ferrat'}, '3522628':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '4416970':{'en': 'Brampton'}, '35951125':{'bg': u('\u041a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u0438\u043d\u043e\u0432\u043e, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Konstantinovo, Varna'}, '390773':{'it': 'Latina'}, '3594111':{'bg': u('\u0421\u0442\u0430\u0440\u043e\u0437\u0430\u0433\u043e\u0440\u0441\u043a\u0438 \u0431\u0430\u043d\u0438'), 'en': 'Starozagorski bani'}, '3347725':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '441984':{'en': 'Watchet (Williton)'}, '3347727':{'en': 'Feurs', 'fr': 'Feurs'}, '3347726':{'en': 'Feurs', 'fr': 'Feurs'}, '3347721':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3343445':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3347723':{'en': 'Roanne', 'fr': 'Roanne'}, '3347722':{'en': 'Saint-Chamond', 'fr': 'Saint-Chamond'}, '3597924':{'bg': u('\u0428\u0438\u0448\u043a\u043e\u0432\u0446\u0438'), 'en': 'Shishkovtsi'}, '3597433':{'bg': u('\u041a\u0440\u0435\u0441\u043d\u0430'), 'en': 'Kresna'}, '3597430':{'bg': u('\u0414\u0430\u043c\u044f\u043d\u0438\u0446\u0430'), 'en': 'Damyanitsa'}, '3597927':{'bg': u('\u0422\u0440\u0435\u043a\u043b\u044f\u043d\u043e'), 'en': 'Treklyano'}, '3347729':{'en': 'Saint-Chamond', 'fr': 'Saint-Chamond'}, '3347728':{'en': u('Panissi\u00e8res'), 'fr': u('Panissi\u00e8res')}, '3336958':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3597435':{'bg': u('\u0421\u043a\u043b\u0430\u0432\u0435'), 'en': 'Sklave'}, '4416972':{'en': 'Brampton'}, '3493':{'en': 'Barcelona', 'es': 'Barcelona'}, '3491':{'en': 'Madrid', 'es': 'Madrid'}, '441688':{'en': 'Isle of Mull - Tobermory'}, '390775':{'it': 'Frosinone'}, '390776':{'en': 'Frosinone', 'it': 'Cassino'}, '441681':{'en': 'Isle of Mull - Fionnphort'}, '4416974':{'en': 'Raughton Head'}, '441680':{'en': 'Isle of Mull - Craignure'}, '441687':{'en': 'Mallaig'}, '3349094':{'en': u('Ch\u00e2teaurenard'), 'fr': u('Ch\u00e2teaurenard')}, '3349097':{'en': 'Saintes-Maries-de-la-Mer', 'fr': 'Saintes-Maries-de-la-Mer'}, '3349096':{'en': 'Arles', 'fr': 'Arles'}, '3349091':{'en': 'Tarascon', 'fr': 'Tarascon'}, '3349090':{'en': u('Ch\u00e2teaurenard'), 'fr': u('Ch\u00e2teaurenard')}, '3349093':{'en': 'Arles', 'fr': 'Arles'}, '3349092':{'en': u('Saint-R\u00e9my-de-Provence'), 'fr': u('Saint-R\u00e9my-de-Provence')}, '441684':{'en': 'Malvern'}, '3349098':{'en': 'Arles', 'fr': 'Arles'}, '3598118':{'bg': u('\u041d\u0438\u043a\u043e\u043b\u043e\u0432\u043e, \u0420\u0443\u0441\u0435'), 'en': 'Nikolovo, Ruse'}, '3329772':{'en': u('Plo\u00ebrmel'), 'fr': u('Plo\u00ebrmel')}, '3329773':{'en': u('Plo\u00ebrmel'), 'fr': u('Plo\u00ebrmel')}, '3329770':{'en': 'Guer', 'fr': 'Guer'}, '3329776':{'en': 'Lanester', 'fr': 'Lanester'}, '3329774':{'en': u('Plo\u00ebrmel'), 'fr': u('Plo\u00ebrmel')}, '3355649':{'en': u('B\u00e8gles'), 'fr': u('B\u00e8gles')}, '3355648':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3323303':{'en': u('\u00c9queurdreville-Hainneville'), 'fr': u('\u00c9queurdreville-Hainneville')}, '3329829':{'en': u('Saint-Pol-de-L\u00e9on'), 'fr': u('Saint-Pol-de-L\u00e9on')}, '3323305':{'en': u('Saint-L\u00f4'), 'fr': u('Saint-L\u00f4')}, '3323306':{'en': u('Saint-L\u00f4'), 'fr': u('Saint-L\u00f4')}, '3355641':{'en': u('Lesparre-M\u00e9doc'), 'fr': u('Lesparre-M\u00e9doc')}, '3355640':{'en': 'Cenon', 'fr': 'Cenon'}, '3355643':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355642':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355397':{'en': u('N\u00e9rac'), 'fr': u('N\u00e9rac')}, '3355396':{'en': 'Agen', 'fr': 'Agen'}, '3355647':{'en': 'Merignac', 'fr': u('M\u00e9rignac')}, '3355646':{'en': 'Pessac', 'fr': 'Pessac'}, '3349271':{'en': 'Manosque', 'fr': 'Manosque'}, '3349270':{'en': 'Manosque', 'fr': 'Manosque'}, '3349273':{'en': 'Banon', 'fr': 'Banon'}, '3349272':{'en': 'Manosque', 'fr': 'Manosque'}, '3349275':{'en': 'Forcalquier', 'fr': 'Forcalquier'}, '3349276':{'en': 'Reillanne', 'fr': 'Reillanne'}, '3349279':{'en': 'Oraison', 'fr': 'Oraison'}, '355884':{'en': u('Dropull i Posht\u00ebm/Dropull i Sip\u00ebrm, Gjirokast\u00ebr')}, '355887':{'en': u('Qesarat/Krah\u00ebs/Luftinje/Buz, Tepelen\u00eb')}, '355886':{'en': u('Qend\u00ebr/Kurvelesh/Lop\u00ebz, Tepelen\u00eb')}, '355881':{'en': u('Libohov\u00eb/Qend\u00ebr, Gjirokast\u00ebr')}, '435242':{'de': 'Schwaz', 'en': 'Schwaz'}, '355883':{'en': u('Lunxheri/Odrie/Zagorie/Pogon, Gjirokast\u00ebr')}, '355882':{'en': u('Cepo/Picar/Lazarat/Atigon, Gjirokast\u00ebr')}, '441827':{'en': 'Tamworth'}, '40253':{'en': 'Gorj', 'ro': 'Gorj'}, '441825':{'en': 'Uckfield'}, '3598113':{'bg': u('\u041d\u043e\u0432\u043e \u0441\u0435\u043b\u043e, \u0420\u0443\u0441\u0435'), 'en': 'Novo selo, Ruse'}, '441823':{'en': 'Taunton'}, '441822':{'en': 'Tavistock'}, '441821':{'en': 'Kinrossie'}, '3598114':{'bg': u('\u041f\u0438\u0440\u0433\u043e\u0432\u043e'), 'en': 'Pirgovo'}, '441829':{'en': 'Tarporley'}, '3598115':{'bg': u('\u0427\u0435\u0440\u0432\u0435\u043d\u0430 \u0432\u043e\u0434\u0430'), 'en': 'Chervena voda'}, '3598116':{'bg': u('\u0418\u0432\u0430\u043d\u043e\u0432\u043e, \u0420\u0443\u0441\u0435'), 'en': 'Ivanovo, Ruse'}, '432878':{'de': 'Traunstein', 'en': 'Traunstein'}, '432876':{'de': 'Els', 'en': 'Els'}, '432877':{'de': 'Grainbrunn', 'en': 'Grainbrunn'}, '432874':{'de': 'Martinsberg', 'en': 'Martinsberg'}, '432875':{'de': 'Grafenschlag', 'en': 'Grafenschlag'}, '432872':{'de': 'Ottenschlag', 'en': 'Ottenschlag'}, '432873':{'de': 'Kottes', 'en': 'Kottes'}, '37235':{'en': u('Narva/Sillam\u00e4e')}, '3596738':{'bg': u('\u0414\u043e\u0431\u0440\u043e\u043c\u0438\u0440\u043a\u0430'), 'en': 'Dobromirka'}, '37232':{'en': 'Rakvere'}, '37233':{'en': u('Kohtla-J\u00e4rve')}, '37238':{'en': 'Paide'}, '35941276':{'bg': u('\u041c\u043e\u0433\u0438\u043b\u0430, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Mogila, St. Zagora'}, '3332836':{'en': 'Lille', 'fr': 'Lille'}, '35941275':{'bg': u('\u041b\u044f\u0441\u043a\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Lyaskovo, St. Zagora'}, '3332833':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332340':{'en': 'Chauny', 'fr': 'Chauny'}, '35941274':{'bg': u('\u0421\u0430\u043c\u0443\u0438\u043b\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Samuilovo, St. Zagora'}, '3332838':{'en': 'Lille', 'fr': 'Lille'}, '3329857':{'en': 'Briec', 'fr': 'Briec'}, '3329856':{'en': 'Fouesnant', 'fr': 'Fouesnant'}, '3329855':{'en': 'Quimper', 'fr': 'Quimper'}, '390521':{'en': 'Parma', 'it': 'Parma'}, '3329854':{'en': 'Plogastel-Saint-Germain', 'fr': 'Plogastel-Saint-Germain'}, '3329853':{'en': 'Quimper', 'fr': 'Quimper'}, '3317581':{'en': 'Cergy', 'fr': 'Cergy'}, '3329852':{'en': 'Quimper', 'fr': 'Quimper'}, '3329851':{'en': 'Fouesnant', 'fr': 'Fouesnant'}, '40258':{'en': 'Alba', 'ro': 'Alba'}, '35941484':{'bg': u('\u0417\u0435\u043c\u043b\u0435\u043d'), 'en': 'Zemlen'}, '3329850':{'en': 'Concarneau', 'fr': 'Concarneau'}, '35941480':{'bg': u('\u041a\u043e\u043b\u0430\u0440\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Kolarovo, St. Zagora'}, '390523':{'en': 'Piacenza', 'it': 'Piacenza'}, '38129':{'en': 'Prizren', 'sr': 'Prizren'}, '38128':{'en': 'Kosovska Mitrovica', 'sr': 'Kosovska Mitrovica'}, '38121':{'en': 'Novi Sad', 'sr': 'Novi Sad'}, '38120':{'en': 'Novi Pazar', 'sr': 'Novi Pazar'}, '38123':{'en': 'Zrenjanin', 'sr': 'Zrenjanin'}, '38122':{'en': 'Sremska Mitrovica', 'sr': 'Sremska Mitrovica'}, '38125':{'en': 'Sombor', 'sr': 'Sombor'}, '38124':{'en': 'Subotica', 'sr': 'Subotica'}, '38127':{'en': 'Prokuplje', 'sr': 'Prokuplje'}, '38126':{'en': 'Smederevo', 'sr': 'Smederevo'}, '37447732':{'am': u('\u0532\u0565\u0580\u0571\u0578\u0580/\u0554\u0561\u0577\u0561\u0569\u0561\u0572\u056b \u0577\u0580\u057b\u0561\u0576'), 'en': 'Berdzor/Kashatagh', 'ru': u('\u0411\u0435\u0440\u0434\u0437\u043e\u0440/\u041a\u0430\u0448\u0430\u0442\u0430\u0445')}, '37423376':{'am': u('\u0534\u0561\u056c\u0561\u0580\u056b\u056f'), 'en': 'Dalarik', 'ru': u('\u0414\u0430\u043b\u0430\u0440\u0438\u043a')}, '37423375':{'am': u('\u0554\u0561\u0580\u0561\u056f\u0565\u0580\u057f'), 'en': 'Karakert', 'ru': u('\u041a\u0430\u0440\u0430\u043a\u0435\u0440\u0442')}, '37423374':{'am': u('\u0544\u0575\u0561\u057d\u0576\u056b\u056f\u0575\u0561\u0576'), 'en': 'Myasnikyan', 'ru': u('\u041c\u044f\u0441\u043d\u0438\u043a\u044f\u043d')}, '3347559':{'en': 'Chabeuil', 'fr': 'Chabeuil'}, '3343870':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347550':{'en': u('Mont\u00e9limar'), 'fr': u('Mont\u00e9limar')}, '3347551':{'en': u('Mont\u00e9limar'), 'fr': u('Mont\u00e9limar')}, '3347556':{'en': 'Valence', 'fr': 'Valence'}, '3347557':{'en': u('Portes-l\u00e8s-Valence'), 'fr': u('Portes-l\u00e8s-Valence')}, '3347554':{'en': u('Bourg-Saint-And\u00e9ol'), 'fr': u('Bourg-Saint-And\u00e9ol')}, '3347555':{'en': 'Valence', 'fr': 'Valence'}, '3347940':{'en': 'Tignes', 'fr': 'Tignes'}, '359418':{'bg': u('\u0413\u044a\u043b\u044a\u0431\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Galabovo, St. Zagora'}, '370528':{'en': u('Elektr\u0117nai/Trakai')}, '359416':{'bg': u('\u0427\u0438\u0440\u043f\u0430\u043d'), 'en': 'Chirpan'}, '359417':{'bg': u('\u0420\u0430\u0434\u043d\u0435\u0432\u043e'), 'en': 'Radnevo'}, '441599':{'en': 'Kyle'}, '441598':{'en': 'Lynton'}, '441597':{'en': 'Llandrindod Wells'}, '441595':{'en': 'Lerwick, Foula & Fair Isle'}, '35991888':{'bg': u('\u0412\u0435\u0441\u043b\u0435\u0446, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Veslets, Vratsa'}, '441593':{'en': 'Lybster'}, '441592':{'en': 'Kirkcaldy'}, '441591':{'en': 'Llanwrtyd Wells'}, '432728':{'de': 'Wienerbruck', 'en': 'Wienerbruck'}, '35957308':{'bg': u('\u0427\u0435\u0440\u043d\u043e\u043e\u043a\u043e\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'Chernookovo, Dobr.'}, '437233':{'de': 'Feldkirchen an der Donau', 'en': 'Feldkirchen an der Donau'}, '40347':{'en': 'Teleorman', 'ro': 'Teleorman'}, '35957304':{'bg': u('\u0414\u044a\u0431\u043e\u0432\u0438\u043a'), 'en': 'Dabovik'}, '35957305':{'bg': u('\u0420\u043e\u0441\u0438\u0446\u0430, \u0414\u043e\u0431\u0440.'), 'en': 'Rositsa, Dobr.'}, '35957306':{'bg': u('\u0418\u0437\u0432\u043e\u0440\u043e\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'Izvorovo, Dobr.'}, '35957307':{'bg': u('\u0416\u0438\u0442\u0435\u043d, \u0414\u043e\u0431\u0440.'), 'en': 'Zhiten, Dobr.'}, '3595737':{'bg': u('\u041b\u044e\u043b\u044f\u043a\u043e\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'Lyulyakovo, Dobr.'}, '3595736':{'bg': u('\u0412\u0430\u0441\u0438\u043b\u0435\u0432\u043e'), 'en': 'Vasilevo'}, '3595735':{'bg': u('\u041a\u0440\u0430\u0441\u0435\u043d, \u0414\u043e\u0431\u0440.'), 'en': 'Krasen, Dobr.'}, '3595734':{'bg': u('\u041f\u0440\u0435\u0441\u0435\u043b\u0435\u043d\u0446\u0438'), 'en': 'Preselentsi'}, '3347808':{'en': 'Caluire-et-Cuire', 'fr': 'Caluire-et-Cuire'}, '3347809':{'en': 'Lyon', 'fr': 'Lyon'}, '3595731':{'bg': u('\u0413\u0435\u043d\u0435\u0440\u0430\u043b \u0422\u043e\u0448\u0435\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'General Toshevo, Dobr.'}, '4413886':{'en': 'Bishop Auckland'}, '3347804':{'en': 'Meyzieu', 'fr': 'Meyzieu'}, '3347805':{'en': 'Brignais', 'fr': 'Brignais'}, '3347806':{'en': 'Montluel', 'fr': 'Montluel'}, '3347807':{'en': 'Givors', 'fr': 'Givors'}, '3347800':{'en': 'Lyon', 'fr': 'Lyon'}, '3347801':{'en': 'Lyon', 'fr': 'Lyon'}, '3347802':{'en': 'Saint-Symphorien-d\'Ozon', 'fr': 'Saint-Symphorien-d\'Ozon'}, '3347803':{'en': 'Villeurbanne', 'fr': 'Villeurbanne'}, '373291':{'en': 'Ceadir Lunga', 'ro': u('Cead\u00eer Lunga'), 'ru': u('\u0427\u0430\u0434\u044b\u0440-\u041b\u0443\u043d\u0433\u0430')}, '3355933':{'en': 'Serres-Castet', 'fr': 'Serres-Castet'}, '35984462':{'bg': u('\u041e\u0441\u0442\u0440\u043e\u0432\u043e'), 'en': 'Ostrovo'}, '373294':{'en': 'Taraclia', 'ro': 'Taraclia', 'ru': u('\u0422\u0430\u0440\u0430\u043a\u043b\u0438\u044f')}, '437235':{'de': 'Gallneukirchen', 'en': 'Gallneukirchen'}, '373297':{'en': 'Basarabeasca', 'ro': 'Basarabeasca', 'ru': u('\u0411\u0430\u0441\u0430\u0440\u0430\u0431\u044f\u0441\u043a\u0430')}, '373298':{'en': 'Comrat', 'ro': 'Comrat', 'ru': u('\u041a\u043e\u043c\u0440\u0430\u0442')}, '373299':{'en': 'Cahul', 'ro': 'Cahul', 'ru': u('\u041a\u0430\u0433\u0443\u043b')}, '40341':{'en': u('Constan\u021ba'), 'ro': u('Constan\u021ba')}, '3596737':{'bg': u('\u041a\u0440\u0443\u0448\u0435\u0432\u043e, \u0413\u0430\u0431\u0440.'), 'en': 'Krushevo, Gabr.'}, '4413882':{'en': 'Stanhope (Eastgate)'}, '35984467':{'bg': u('\u0421\u0435\u0441\u043b\u0430\u0432'), 'en': 'Seslav'}, '3346601':{'en': 'Bellegarde', 'fr': 'Bellegarde'}, '3346603':{'en': u('Uz\u00e8s'), 'fr': u('Uz\u00e8s')}, '3346602':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346605':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346604':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '40233':{'en': u('Neam\u021b'), 'ro': u('Neam\u021b')}, '436219':{'de': 'Obertrum am See', 'en': 'Obertrum am See'}, '436216':{'de': 'Neumarkt am Wallersee', 'en': 'Neumarkt am Wallersee'}, '436217':{'de': 'Mattsee', 'en': 'Mattsee'}, '436214':{'de': 'Henndorf am Wallersee', 'en': 'Henndorf am Wallersee'}, '436215':{'de': u('Stra\u00dfwalchen'), 'en': 'Strasswalchen'}, '436212':{'de': 'Seekirchen am Wallersee', 'en': 'Seekirchen am Wallersee'}, '436213':{'de': 'Oberhofen am Irrsee', 'en': 'Oberhofen am Irrsee'}, '3355931':{'en': 'Anglet', 'fr': 'Anglet'}, '40230':{'en': 'Suceava', 'ro': 'Suceava'}, '3694':{'en': 'Szombathely', 'hu': 'Szombathely'}, '37426299':{'am': u('\u0535\u0580\u0561\u0576\u0578\u057d'), 'en': 'Eranos', 'ru': u('\u0415\u0440\u0430\u043d\u043e\u0441')}, '35931792':{'bg': u('\u0427\u0435\u0440\u043d\u0438\u0447\u0435\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Chernichevo, Plovdiv'}, '35931791':{'bg': u('\u0411\u0435\u0433\u043e\u0432\u043e'), 'en': 'Begovo'}, '390474':{'it': 'Brunico'}, '3338939':{'en': 'Cernay', 'fr': 'Cernay'}, '3338428':{'en': 'Belfort', 'fr': 'Belfort'}, '3338424':{'en': 'Lons-le-Saunier', 'fr': 'Lons-le-Saunier'}, '3338933':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3338930':{'en': 'Colmar', 'fr': 'Colmar'}, '3338931':{'en': 'Sausheim', 'fr': 'Sausheim'}, '3338936':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3338421':{'en': 'Belfort', 'fr': 'Belfort'}, '3338422':{'en': 'Belfort', 'fr': 'Belfort'}, '3338935':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3323828':{'en': 'Montargis', 'fr': 'Montargis'}, '3323821':{'en': 'Saint-Jean-de-Braye', 'fr': 'Saint-Jean-de-Braye'}, '3323822':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323824':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323825':{'en': 'Olivet', 'fr': 'Olivet'}, '3346865':{'en': 'Narbonne', 'fr': 'Narbonne'}, '3346864':{'en': 'Rivesaltes', 'fr': 'Rivesaltes'}, '3346867':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3346866':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3346861':{'en': 'Perpignan', 'fr': 'Perpignan'}, '4416863':{'en': 'Llanidloes'}, '3346863':{'en': 'Pia', 'fr': 'Pia'}, '3346862':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3354623':{'en': 'Saint-Palais-sur-Mer', 'fr': 'Saint-Palais-sur-Mer'}, '3346868':{'en': 'Perpignan', 'fr': 'Perpignan'}, '4416868':{'en': 'Newtown'}, '4416869':{'en': 'Newtown'}, '355293':{'en': u('Kastriot/Muhur/Selisht\u00eb, Dib\u00ebr')}, '355296':{'en': u('Fush\u00eb-Bulqiz\u00eb/Shupenz\u00eb/Zerqan, Bulqiz\u00eb')}, '355297':{'en': u('Gjorice/Ostren/Trebisht/Martanesh, Bulqiz\u00eb')}, '3752154':{'be': u('\u0428\u0430\u0440\u043a\u043e\u045e\u0448\u0447\u044b\u043d\u0430, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Sharkovshchina, Vitebsk Region', 'ru': u('\u0428\u0430\u0440\u043a\u043e\u0432\u0449\u0438\u043d\u0430, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752155':{'be': u('\u041f\u0430\u0441\u0442\u0430\u0432\u044b'), 'en': 'Postavy', 'ru': u('\u041f\u043e\u0441\u0442\u0430\u0432\u044b')}, '3752156':{'be': u('\u0413\u043b\u044b\u0431\u043e\u043a\u0430\u0435'), 'en': 'Glubokoye', 'ru': u('\u0413\u043b\u0443\u0431\u043e\u043a\u043e\u0435')}, '3752157':{'be': u('\u0414\u043e\u043a\u0448\u044b\u0446\u044b, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Dokshitsy, Vitebsk Region', 'ru': u('\u0414\u043e\u043a\u0448\u0438\u0446\u044b, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752151':{'be': u('\u0412\u0435\u0440\u0445\u043d\u044f\u0434\u0437\u0432\u0456\u043d\u0441\u043a, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Verhnedvinsk, Vitebsk Region', 'ru': u('\u0412\u0435\u0440\u0445\u043d\u0435\u0434\u0432\u0438\u043d\u0441\u043a, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752152':{'be': u('\u041c\u0456\u0451\u0440\u044b, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Miory, Vitebsk Region', 'ru': u('\u041c\u0438\u043e\u0440\u044b, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752153':{'be': u('\u0411\u0440\u0430\u0441\u043b\u0430\u045e'), 'en': 'Braslav', 'ru': u('\u0411\u0440\u0430\u0441\u043b\u0430\u0432')}, '3325651':{'en': 'Rennes', 'fr': 'Rennes'}, '3752158':{'be': u('\u0423\u0448\u0430\u0447\u044b, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Ushachi, Vitebsk Region', 'ru': u('\u0423\u0448\u0430\u0447\u0438, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3325654':{'en': 'Lorient', 'fr': 'Lorient'}, '3593102':{'bg': u('\u041a\u0430\u0440\u0430\u0434\u0436\u043e\u0432\u043e'), 'en': 'Karadzhovo'}, '3593103':{'bg': u('\u041c\u0438\u043b\u0435\u0432\u043e'), 'en': 'Milevo'}, '3593100':{'bg': u('\u0411\u0435\u043b\u0430\u0449\u0438\u0446\u0430'), 'en': 'Belashtitsa'}, '3593101':{'bg': u('\u0412\u043e\u0439\u0432\u043e\u0434\u0438\u043d\u043e\u0432\u043e'), 'en': 'Voyvodinovo'}, '3593106':{'bg': u('\u0421\u0442\u0440\u043e\u0435\u0432\u043e'), 'en': 'Stroevo'}, '3593107':{'bg': u('\u0413\u0440\u0430\u0444 \u0418\u0433\u043d\u0430\u0442\u0438\u0435\u0432\u043e'), 'en': 'Graf Ignatievo'}, '34848':{'en': 'Navarre', 'es': 'Navarra'}, '3593105':{'bg': u('\u041c\u0430\u043d\u043e\u043b\u0441\u043a\u043e \u041a\u043e\u043d\u0430\u0440\u0435'), 'en': 'Manolsko Konare'}, '34847':{'en': 'Burgos', 'es': 'Burgos'}, '3593108':{'bg': u('\u0411\u043e\u0439\u043a\u043e\u0432\u043e'), 'en': 'Boykovo'}, '3593109':{'bg': u('\u041b\u0438\u043b\u043a\u043e\u0432\u043e'), 'en': 'Lilkovo'}, '34842':{'en': 'Cantabria', 'es': 'Cantabria'}, '34843':{'en': u('Guip\u00fazcoa'), 'es': u('Guip\u00fazcoa')}, '3332648':{'en': 'Fismes', 'fr': 'Fismes'}, '3332138':{'en': 'Saint-Omer', 'fr': 'Saint-Omer'}, '3332134':{'en': 'Calais', 'fr': 'Calais'}, '3332136':{'en': 'Calais', 'fr': 'Calais'}, '3332137':{'en': 'Carvin', 'fr': 'Carvin'}, '3332130':{'en': 'Boulogne-sur-Mer', 'fr': 'Boulogne-sur-Mer'}, '3332131':{'en': 'Boulogne-sur-Mer', 'fr': 'Boulogne-sur-Mer'}, '3325435':{'en': 'Levroux', 'fr': 'Levroux'}, '3325434':{'en': u('Ch\u00e2teauroux'), 'fr': u('Ch\u00e2teauroux')}, '3325437':{'en': 'Le Blanc', 'fr': 'Le Blanc'}, '3325436':{'en': 'Ardentes', 'fr': 'Ardentes'}, '3325431':{'en': 'Cluis', 'fr': 'Cluis'}, '433338':{'de': 'Lafnitz', 'en': 'Lafnitz'}, '3325432':{'en': 'Montrichard', 'fr': 'Montrichard'}, '433336':{'de': 'Waldbach', 'en': 'Waldbach'}, '433337':{'de': 'Vorau', 'en': 'Vorau'}, '433334':{'de': 'Kaindorf', 'en': 'Kaindorf'}, '433335':{'de': u('P\u00f6llau'), 'en': u('P\u00f6llau')}, '433332':{'de': 'Hartberg', 'en': 'Hartberg'}, '3325438':{'en': u('Ch\u00e2tillon-sur-Indre'), 'fr': u('Ch\u00e2tillon-sur-Indre')}, '433331':{'de': 'Sankt Lorenzen am Wechsel', 'en': 'St. Lorenzen am Wechsel'}, '35941019':{'bg': u('\u0412\u0435\u043d\u0435\u0446, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Venets, St. Zagora'}, '35941018':{'bg': u('\u041a\u043d\u044f\u0436\u0435\u0432\u0441\u043a\u043e'), 'en': 'Knyazhevsko'}, '3349510':{'en': 'Ajaccio', 'fr': 'Ajaccio'}, '35960458':{'bg': u('\u0412\u0435\u0440\u0435\u043d\u0446\u0438'), 'en': 'Verentsi'}, '35960454':{'bg': u('\u0417\u043c\u0435\u0439\u043d\u043e'), 'en': 'Zmeyno'}, '35960453':{'bg': u('\u041c\u043e\u0440\u0430\u0432\u043a\u0430'), 'en': 'Moravka'}, '35960450':{'bg': u('\u0414\u043e\u043b\u043d\u0430 \u0425\u0443\u0431\u0430\u0432\u043a\u0430'), 'en': 'Dolna Hubavka'}, '35960451':{'bg': u('\u041e\u0431\u0438\u0442\u0435\u043b'), 'en': 'Obitel'}, '4419649':{'en': 'Hornsea'}, '4419648':{'en': 'Hornsea'}, '432689':{'de': 'Hornstein', 'en': 'Hornstein'}, '432688':{'de': 'Steinbrunn', 'en': 'Steinbrunn'}, '432685':{'de': 'Rust', 'en': 'Rust'}, '432684':{'de': u('Sch\u00fctzen am Gebirge'), 'en': u('Sch\u00fctzen am Gebirge')}, '432687':{'de': 'Siegendorf', 'en': 'Siegendorf'}, '432686':{'de': u('Dra\u00dfburg'), 'en': 'Drassburg'}, '4419647':{'en': 'Patrington'}, '432680':{'de': 'Sankt Margarethen im Burgenland', 'en': 'St. Margarethen im Burgenland'}, '432683':{'de': 'Purbach am Neusiedler See', 'en': 'Purbach am Neusiedler See'}, '432682':{'de': 'Eisenstadt', 'en': 'Eisenstadt'}, '433158':{'de': 'Sankt Anna am Aigen', 'en': 'St. Anna am Aigen'}, '433159':{'de': 'Bad Gleichenberg', 'en': 'Bad Gleichenberg'}, '441436':{'en': 'Helensburgh'}, '433152':{'de': 'Feldbach', 'en': 'Feldbach'}, '433153':{'de': 'Riegersburg', 'en': 'Riegersburg'}, '433150':{'de': 'Paldau', 'en': 'Paldau'}, '433151':{'de': 'Gnas', 'en': 'Gnas'}, '433157':{'de': 'Kapfenstein', 'en': 'Kapfenstein'}, '433155':{'de': 'Fehring', 'en': 'Fehring'}, '441438':{'en': 'Stevenage'}, '3356287':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356288':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356289':{'en': 'Saint-Jean', 'fr': 'Saint-Jean'}, '3317930':{'en': 'Rueil-Malmaison', 'fr': 'Rueil-Malmaison'}, '3594109':{'bg': u('\u0422\u0440\u0430\u043a\u0438\u044f'), 'en': 'Trakia'}, '3594108':{'bg': u('\u0412\u0430\u0441\u0438\u043b \u041b\u0435\u0432\u0441\u043a\u0438, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Vasil Levski, St. Zagora'}, '3594107':{'bg': u('\u0421\u0440\u0435\u0434\u0435\u0446, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Sredets, St. Zagora'}, '3594106':{'bg': u('\u041f\u044a\u0441\u0442\u0440\u0435\u043d'), 'en': 'Pastren'}, '3594105':{'bg': u('\u0411\u044f\u043b\u043e \u043f\u043e\u043b\u0435'), 'en': 'Byalo pole'}, '3594104':{'bg': u('\u041a\u0440\u0430\u0432\u0438\u043d\u043e'), 'en': 'Kravino'}, '3594103':{'bg': u('\u0411\u044f\u043b \u0438\u0437\u0432\u043e\u0440, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Byal izvor, St. Zagora'}, '3594102':{'bg': u('\u042f\u0441\u0442\u0440\u0435\u0431\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Yastrebovo, St. Zagora'}, '3594101':{'bg': u('\u041e\u043f\u0430\u043d'), 'en': 'Opan'}, '3594100':{'bg': u('\u0421\u0442\u043e\u043b\u0435\u0442\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Stoletovo, St. Zagora'}, '441698':{'en': 'Motherwell'}, '355291':{'en': u('Tomin/Luzni, Dib\u00ebr')}, '441694':{'en': 'Church Stretton'}, '441695':{'en': 'Skelmersdale'}, '441690':{'en': 'Betws-y-Coed'}, '441691':{'en': 'Oswestry'}, '441692':{'en': 'North Walsham'}, '441431':{'en': 'Helmsdale'}, '3324744':{'en': 'Saint-Pierre-des-Corps', 'fr': 'Saint-Pierre-des-Corps'}, '3324745':{'en': 'Azay-le-Rideau', 'fr': 'Azay-le-Rideau'}, '3324746':{'en': 'Tours', 'fr': 'Tours'}, '3324747':{'en': 'Tours', 'fr': 'Tours'}, '435279':{'de': 'Sankt Jodok am Brenner', 'en': 'St. Jodok am Brenner'}, '3324741':{'en': 'Tours', 'fr': 'Tours'}, '3324742':{'en': 'Fondettes', 'fr': 'Fondettes'}, '3324743':{'en': 'Truyes', 'fr': 'Truyes'}, '435275':{'de': 'Trins', 'en': 'Trins'}, '435274':{'de': 'Gries am Brenner', 'en': 'Gries am Brenner'}, '435276':{'de': 'Gschnitz', 'en': 'Gschnitz'}, '3324748':{'en': u('Chambray-l\u00e8s-Tours'), 'fr': u('Chambray-l\u00e8s-Tours')}, '3324749':{'en': 'Fondettes', 'fr': 'Fondettes'}, '435273':{'de': 'Matrei am Brenner', 'en': 'Matrei am Brenner'}, '3597439':{'bg': u('\u041f\u043b\u043e\u0441\u043a\u0438'), 'en': 'Ploski'}, '3344290':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344291':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344292':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344293':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344294':{'en': 'Bouc-Bel-air', 'fr': 'Bouc-Bel-air'}, '3344295':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344296':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344297':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344298':{'en': 'La Ciotat', 'fr': 'La Ciotat'}, '3344299':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3324000':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '4413872':{'en': 'Dumfries'}, '435418':{'de': u('Sch\u00f6nwies'), 'en': u('Sch\u00f6nwies')}, '4413870':{'en': 'Dumfries'}, '4413871':{'en': 'Dumfries'}, '4413876':{'en': 'Dumfries'}, '4413877':{'en': 'Dumfries'}, '4413874':{'en': 'Dumfries'}, '4413875':{'en': 'Dumfries'}, '435413':{'de': 'Sankt Leonhard im Pitztal', 'en': 'St. Leonhard im Pitztal'}, '435412':{'de': 'Imst', 'en': 'Imst'}, '435414':{'de': 'Wenns', 'en': 'Wenns'}, '331812':{'en': 'Paris', 'fr': 'Paris'}, '4144':{'de': u('Z\u00fcrich'), 'en': 'Zurich', 'fr': 'Zurich', 'it': 'Zurigo'}, '4141':{'de': 'Luzern', 'en': 'Lucerne', 'fr': 'Lucerne', 'it': 'Lucerna'}, '4143':{'de': u('Z\u00fcrich'), 'en': 'Zurich', 'fr': 'Zurich', 'it': 'Zurigo'}, '3347120':{'en': 'Murat', 'fr': 'Murat'}, '3595759':{'bg': u('\u041a\u043e\u0447\u043c\u0430\u0440'), 'en': 'Kochmar'}, '35535':{'en': 'Lushnje'}, '35534':{'en': 'Fier'}, '35533':{'en': u('Vlor\u00eb')}, '35532':{'en': 'Berat'}, '355278':{'en': u('Bicaj/Topojan/Shishtavec, Kuk\u00ebs')}, '3595758':{'bg': u('\u041a\u043b\u0430\u0434\u0435\u043d\u0446\u0438'), 'en': 'Kladentsi'}, '3356247':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3597713':{'bg': u('\u0420\u0443\u0434\u0430\u0440\u0446\u0438'), 'en': 'Rudartsi'}, '37426596':{'am': u('\u054e\u0561\u0570\u0561\u0576'), 'en': 'Vahan', 'ru': u('\u0412\u0430\u0430\u043d')}, '3597711':{'bg': u('\u041a\u043b\u0430\u0434\u043d\u0438\u0446\u0430'), 'en': 'Kladnitsa'}, '3323148':{'en': 'Lisieux', 'fr': 'Lisieux'}, '3323147':{'en': 'Caen', 'fr': 'Caen'}, '3323146':{'en': 'Caen', 'fr': 'Caen'}, '3323144':{'en': 'Caen', 'fr': 'Caen'}, '3323143':{'en': 'Caen', 'fr': 'Caen'}, '3323140':{'en': 'Falaise', 'fr': 'Falaise'}, '3597715':{'bg': u('\u0421\u0442\u0443\u0434\u0435\u043d\u0430, \u041f\u0435\u0440\u043d\u0438\u043a'), 'en': 'Studena, Pernik'}, '3349079':{'en': 'Pertuis', 'fr': 'Pertuis'}, '3349078':{'en': 'Cavaillon', 'fr': 'Cavaillon'}, '3349077':{'en': 'Cucuron', 'fr': 'Cucuron'}, '3349076':{'en': 'Cavaillon', 'fr': 'Cavaillon'}, '3349074':{'en': 'Apt', 'fr': 'Apt'}, '3349073':{'en': 'Plan-d\'Orgon', 'fr': 'Plan-d\'Orgon'}, '3349072':{'en': 'Gordes', 'fr': 'Gordes'}, '3349071':{'en': 'Cavaillon', 'fr': 'Cavaillon'}, '3349070':{'en': u('Courth\u00e9zon'), 'fr': u('Courth\u00e9zon')}, '3322812':{'en': 'Challans', 'fr': 'Challans'}, '3322813':{'en': 'Fontenay-le-Comte', 'fr': 'Fontenay-le-Comte'}, '3322811':{'en': 'Saint-Jean-de-Monts', 'fr': 'Saint-Jean-de-Monts'}, '3595108':{'bg': u('\u0421\u0430\u0434\u043e\u0432\u043e, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Sadovo, Varna'}, '3323368':{'en': 'Avranches', 'fr': 'Avranches'}, '390323':{'it': 'Baveno'}, '390322':{'en': 'Novara', 'it': 'Arona'}, '390321':{'en': 'Novara', 'it': 'Novara'}, '3323362':{'en': 'Flers', 'fr': 'Flers'}, '3323367':{'en': 'Argentan', 'fr': 'Argentan'}, '3598677':{'bg': u('\u0421\u0440\u0435\u0431\u044a\u0440\u043d\u0430'), 'en': 'Srebarna'}, '3323365':{'en': 'Flers', 'fr': 'Flers'}, '3323364':{'en': 'Flers', 'fr': 'Flers'}, '3349219':{'en': 'La Roquette sur Siagne', 'fr': 'La Roquette sur Siagne'}, '3349218':{'en': 'Le Cannet', 'fr': 'Le Cannet'}, '37424996':{'am': u('\u0546\u0565\u0580\u0584\u056b\u0576 \u0532\u0561\u0566\u0574\u0561\u0562\u0565\u0580\u0564'), 'en': 'Nerkin Bazmaberd', 'ru': u('\u041d\u0435\u0440\u043a\u0438\u043d \u0411\u0430\u0437\u043c\u0430\u0431\u0435\u0440\u0434')}, '37424997':{'am': u('\u0544\u0561\u057d\u057f\u0561\u0580\u0561'), 'en': 'Mastara', 'ru': u('\u041c\u0430\u0441\u0442\u0430\u0440\u0430')}, '3349213':{'en': 'Cagnes-sur-Mer', 'fr': 'Cagnes-sur-Mer'}, '3349212':{'en': 'Saint-Laurent-du-Var', 'fr': 'Saint-Laurent-du-Var'}, '3349210':{'en': 'Menton', 'fr': 'Menton'}, '3349217':{'en': 'Nice', 'fr': 'Nice'}, '436232':{'de': 'Mondsee', 'en': 'Mondsee'}, '3349215':{'en': 'Nice', 'fr': 'Nice'}, '3349214':{'en': 'Nice', 'fr': 'Nice'}, '441841':{'en': 'Newquay (Padstow)'}, '441840':{'en': 'Camelford'}, '441843':{'en': 'Thanet'}, '441842':{'en': 'Thetford'}, '441845':{'en': 'Thirsk'}, '3598673':{'bg': u('\u0410\u043b\u0444\u0430\u0442\u0430\u0440'), 'en': 'Alfatar'}, '441848':{'en': 'Thornhill'}, '3598672':{'bg': u('\u0411\u0440\u0430\u0434\u0432\u0430\u0440\u0438'), 'en': 'Bradvari'}, '3338895':{'en': 'Obernai', 'fr': 'Obernai'}, '3338894':{'en': 'Wissembourg', 'fr': 'Wissembourg'}, '3338891':{'en': 'Saverne', 'fr': 'Saverne'}, '3338893':{'en': 'Haguenau', 'fr': 'Haguenau'}, '3338892':{'en': u('S\u00e9lestat'), 'fr': u('S\u00e9lestat')}, '3338898':{'en': 'Erstein', 'fr': 'Erstein'}, '3332587':{'en': 'Langres', 'fr': 'Langres'}, '3332581':{'en': 'Troyes', 'fr': 'Troyes'}, '3332580':{'en': 'Troyes', 'fr': 'Troyes'}, '3332583':{'en': 'Troyes', 'fr': 'Troyes'}, '3332582':{'en': 'Troyes', 'fr': 'Troyes'}, '3598678':{'bg': u('\u0421\u0440\u0430\u0446\u0438\u043c\u0438\u0440, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Sratsimir, Silistra'}, '432858':{'de': 'Moorbad Harbach', 'en': 'Moorbad Harbach'}, '432256':{'de': 'Leobersdorf', 'en': 'Leobersdorf'}, '432257':{'de': 'Klausen-Leopoldsdorf', 'en': 'Klausen-Leopoldsdorf'}, '432852':{'de': u('Gm\u00fcnd'), 'en': u('Gm\u00fcnd')}, '432853':{'de': 'Schrems', 'en': 'Schrems'}, '432854':{'de': 'Kirchberg am Walde', 'en': 'Kirchberg am Walde'}, '432254':{'de': 'Ebreichsdorf', 'en': 'Ebreichsdorf'}, '432856':{'de': 'Weitra', 'en': 'Weitra'}, '432857':{'de': u('Bad Gro\u00dfpertholz'), 'en': 'Bad Grosspertholz'}, '432255':{'de': 'Deutsch Brodersdorf', 'en': 'Deutsch Brodersdorf'}, '432252':{'de': 'Baden', 'en': 'Baden'}, '432253':{'de': 'Oberwaltersdorf', 'en': 'Oberwaltersdorf'}, '3355622':{'en': 'Arcachon', 'fr': 'Arcachon'}, '3355627':{'en': 'Podensac', 'fr': 'Podensac'}, '3355626':{'en': 'Mios', 'fr': 'Mios'}, '3355625':{'en': 'Bazas', 'fr': 'Bazas'}, '3355624':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355629':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355628':{'en': 'Eysines', 'fr': 'Eysines'}, '3332361':{'en': 'Guise', 'fr': 'Guise'}, '432147':{'de': 'Zurndorf', 'en': 'Zurndorf'}, '432144':{'de': 'Deutsch Jahrndorf', 'en': 'Deutsch Jahrndorf'}, '3332362':{'en': 'Saint-Quentin', 'fr': 'Saint-Quentin'}, '3332365':{'en': 'Saint-Quentin', 'fr': 'Saint-Quentin'}, '3332364':{'en': 'Saint-Quentin', 'fr': 'Saint-Quentin'}, '3332367':{'en': 'Saint-Quentin', 'fr': 'Saint-Quentin'}, '3332369':{'en': u('Ch\u00e2teau-Thierry'), 'fr': u('Ch\u00e2teau-Thierry')}, '3332368':{'en': 'Saint-Quentin', 'fr': 'Saint-Quentin'}, '434768':{'de': 'Kleblach-Lind', 'en': 'Kleblach-Lind'}, '3594592':{'bg': u('\u0411\u044f\u043b\u0430 \u043f\u0430\u043b\u0430\u043d\u043a\u0430'), 'en': 'Byala palanka'}, '3354937':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354930':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3594595':{'bg': u('\u0421\u0431\u043e\u0440\u0438\u0449\u0435'), 'en': 'Sborishte'}, '3354932':{'en': 'Aiffres', 'fr': 'Aiffres'}, '3354933':{'en': 'Niort', 'fr': 'Niort'}, '3594599':{'bg': u('\u0427\u0435\u0440\u0432\u0435\u043d\u0430\u043a\u043e\u0432\u043e'), 'en': 'Chervenakovo'}, '3354938':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354939':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3348038':{'en': 'Grenoble', 'fr': 'Grenoble'}, '437433':{'de': 'Wallsee', 'en': 'Wallsee'}, '355277':{'en': u('Shtiqen/T\u00ebrthore/Zapod, Kuk\u00ebs')}, '441432':{'en': 'Hereford'}, '35941116':{'bg': u('\u0421\u043b\u0430\u0434\u044a\u043a \u041a\u043b\u0430\u0434\u0435\u043d\u0435\u0446'), 'en': 'Sladak Kladenets'}, '3593717':{'bg': u('\u041a\u043e\u043d\u0443\u0448, \u0425\u0430\u0441\u043a.'), 'en': 'Konush, Hask.'}, '35941115':{'bg': u('\u0411\u043e\u0440\u0438\u043b\u043e\u0432\u043e'), 'en': 'Borilovo'}, '3593713':{'bg': u('\u0414\u0438\u043d\u0435\u0432\u043e'), 'en': 'Dinevo'}, '3593712':{'bg': u('\u041c\u0430\u043b\u0435\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Malevo, Hask.'}, '3593711':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u0411\u043e\u0442\u0435\u0432\u043e'), 'en': 'Dolno Botevo'}, '3593710':{'bg': u('\u0423\u0437\u0443\u043d\u0434\u0436\u043e\u0432\u043e'), 'en': 'Uzundzhovo'}, '3329938':{'en': 'Rennes', 'fr': 'Rennes'}, '3593719':{'bg': u('\u041a\u043d\u0438\u0436\u043e\u0432\u043d\u0438\u043a'), 'en': 'Knizhovnik'}, '3593718':{'bg': u('\u0412\u043e\u0439\u0432\u043e\u0434\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Voyvodovo, Hask.'}, '3329636':{'en': u('Plouguern\u00e9vel'), 'fr': u('Plouguern\u00e9vel')}, '3599355':{'bg': u('\u041a\u043e\u0441\u043e\u0432\u043e, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Kosovo, Vidin'}, '3599354':{'bg': u('\u0410\u043d\u0442\u0438\u043c\u043e\u0432\u043e, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Antimovo, Vidin'}, '3599356':{'bg': u('\u041a\u0430\u043b\u0435\u043d\u0438\u043a, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Kalenik, Vidin'}, '3599351':{'bg': u('\u0418\u0437\u0432\u043e\u0440, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Izvor, Vidin'}, '3599353':{'bg': u('\u041a\u043e\u0448\u0430\u0432\u0430'), 'en': 'Koshava'}, '3599352':{'bg': u('\u0414\u0440\u0443\u0436\u0431\u0430'), 'en': 'Druzhba'}, '3343812':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3329935':{'en': 'Rennes', 'fr': 'Rennes'}, '3325355':{'en': 'Nantes', 'fr': 'Nantes'}, '35941118':{'bg': u('\u041e\u0441\u0442\u0440\u0430 \u043c\u043e\u0433\u0438\u043b\u0430, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Ostra mogila, St. Zagora'}, '3598664':{'bg': u('\u041f\u043e\u043b\u044f\u043d\u0430, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Polyana, Silistra'}, '35941119':{'bg': u('\u0415\u043b\u0445\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Elhovo, St. Zagora'}, '35935252':{'bg': u('\u0422\u043e\u043f\u043e\u043b\u0438 \u0434\u043e\u043b'), 'en': 'Topoli dol'}, '3349411':{'en': 'La Seyne-sur-Mer', 'fr': 'La Seyne-sur-Mer'}, '35935251':{'bg': u('\u0411\u0440\u0430\u0442\u0430\u043d\u0438\u0446\u0430'), 'en': 'Bratanitsa'}, '35935256':{'bg': u('\u0421\u0431\u043e\u0440, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Sbor, Pazardzhik'}, '35935257':{'bg': u('\u0421\u0430\u0440\u0430\u044f'), 'en': 'Saraya'}, '35935254':{'bg': u('\u0414\u043e\u0431\u0440\u043e\u0432\u043d\u0438\u0446\u0430'), 'en': 'Dobrovnitsa'}, '35935255':{'bg': u('\u0420\u043e\u0441\u0435\u043d, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Rosen, Pazardzhik'}, '35935258':{'bg': u('\u0426\u0430\u0440 \u0410\u0441\u0435\u043d, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Tsar Asen, Pazardzhik'}, '3349413':{'en': u('Solli\u00e8s-Pont'), 'fr': u('Solli\u00e8s-Pont')}, '37428195':{'am': u('\u0544\u0561\u056c\u056b\u0577\u056f\u0561'), 'en': 'Malishka', 'ru': u('\u041c\u0430\u043b\u0438\u0448\u043a\u0430')}, '3329639':{'en': 'Dinan', 'fr': 'Dinan'}, '3598665':{'bg': u('\u0418\u0441\u043a\u0440\u0430, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Iskra, Silistra'}, '359431':{'bg': u('\u041a\u0430\u0437\u0430\u043d\u043b\u044a\u043a'), 'en': 'Kazanlak'}, '37428191':{'am': u('\u0531\u0580\u0583\u056b'), 'en': 'Arpi', 'ru': u('\u0410\u0440\u043f\u0438')}, '3596992':{'bg': u('\u0417\u043b\u0430\u0442\u043d\u0430 \u041f\u0430\u043d\u0435\u0433\u0430'), 'en': 'Zlatna Panega'}, '3596990':{'bg': u('\u041c\u0430\u043b\u044a\u043a \u0438\u0437\u0432\u043e\u0440, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Malak izvor, Lovech'}, '3596991':{'bg': u('\u042f\u0431\u043b\u0430\u043d\u0438\u0446\u0430'), 'en': 'Yablanitsa'}, '3596997':{'bg': u('\u0414\u043e\u0431\u0440\u0435\u0432\u0446\u0438, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Dobrevtsi, Lovech'}, '3596994':{'bg': u('\u0411\u0440\u0435\u0441\u0442\u043d\u0438\u0446\u0430, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Brestnitsa, Lovech'}, '355562':{'en': 'Milot/Fushe-Kuqe, Kurbin'}, '355563':{'en': u('Fush\u00eb-Kruj\u00eb')}, '355292':{'en': u('Maqellar\u00eb/Melan, Dib\u00ebr')}, '355561':{'en': 'Mamurras, Kurbin'}, '355294':{'en': u('Arras/Fush\u00eb-\u00c7idh\u00ebn/Lur\u00eb, Dib\u00ebr')}, '355295':{'en': u('Sllov\u00eb/Zall-Dardh\u00eb/Zall-Re\u00e7/Kala e Dodes, Dib\u00ebr')}, '355564':{'en': u('Nik\u00ebl/Bubq, Kruje')}, '355565':{'en': 'Koder-Thumane/Cudhi, Kruje'}, '3347826':{'en': 'Bron', 'fr': 'Bron'}, '3347827':{'en': 'Lyon', 'fr': 'Lyon'}, '3347824':{'en': 'Lyon', 'fr': 'Lyon'}, '3347825':{'en': 'Lyon', 'fr': 'Lyon'}, '3347822':{'en': u('Fontaines-sur-Sa\u00f4ne'), 'fr': u('Fontaines-sur-Sa\u00f4ne')}, '3347823':{'en': 'Caluire-et-Cuire', 'fr': 'Caluire-et-Cuire'}, '3347820':{'en': 'Saint-Priest', 'fr': 'Saint-Priest'}, '3347821':{'en': 'Saint-Priest', 'fr': 'Saint-Priest'}, '3347828':{'en': 'Lyon', 'fr': 'Lyon'}, '3347829':{'en': 'Lyon', 'fr': 'Lyon'}, '3595711':{'bg': u('\u041e\u0432\u0447\u0430\u0440\u043e\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'Ovcharovo, Dobr.'}, '3595710':{'bg': u('\u041f\u043e\u0431\u0435\u0434\u0430, \u0414\u043e\u0431\u0440.'), 'en': 'Pobeda, Dobr.'}, '3595713':{'bg': u('\u0421\u0442\u0435\u0444\u0430\u043d\u043e\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'Stefanovo, Dobr.'}, '3595712':{'bg': u('\u0421\u0442\u043e\u0436\u0435\u0440'), 'en': 'Stozher'}, '3595715':{'bg': u('\u041f\u043e\u043f\u0433\u0440\u0438\u0433\u043e\u0440\u043e\u0432\u043e'), 'en': 'Popgrigorovo'}, '3595714':{'bg': u('\u041a\u0430\u0440\u0430\u043f\u0435\u043b\u0438\u0442'), 'en': 'Karapelit'}, '3595717':{'bg': u('\u0412\u0435\u0434\u0440\u0438\u043d\u0430'), 'en': 'Vedrina'}, '3595716':{'bg': u('\u041f\u0430\u0441\u043a\u0430\u043b\u0435\u0432\u043e'), 'en': 'Paskalevo'}, '3595719':{'bg': u('\u0414\u043e\u043d\u0447\u0435\u0432\u043e'), 'en': 'Donchevo'}, '3595718':{'bg': u('\u0421\u043c\u043e\u043b\u043d\u0438\u0446\u0430'), 'en': 'Smolnitsa'}, '3324007':{'en': 'Derval', 'fr': 'Derval'}, '3346662':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346661':{'en': 'Anduze', 'fr': 'Anduze'}, '3346660':{'en': u('Saint-Christol-l\u00e8s-Al\u00e8s'), 'fr': u('Saint-Christol-l\u00e8s-Al\u00e8s')}, '3346667':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3324002':{'en': 'Sainte-Pazanne', 'fr': 'Sainte-Pazanne'}, '3346665':{'en': 'Mende', 'fr': 'Mende'}, '3346664':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346669':{'en': 'Langogne', 'fr': 'Langogne'}, '3346668':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3324009':{'en': u('Lir\u00e9'), 'fr': u('Lir\u00e9')}, '3324008':{'en': 'Nantes', 'fr': 'Nantes'}, '3597719':{'bg': u('\u042f\u0440\u0434\u0436\u0438\u043b\u043e\u0432\u0446\u0438'), 'en': 'Yardzhilovtsi'}, '3597718':{'bg': u('\u0414\u0440\u0430\u0433\u0438\u0447\u0435\u0432\u043e'), 'en': 'Dragichevo'}, '3522429':{'de': 'Luxemburg/Kockelscheuer', 'en': 'Luxembourg/Kockelscheuer', 'fr': 'Luxembourg/Kockelscheuer'}, '3522428':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '3522425':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '3597712':{'bg': u('\u0411\u0430\u0442\u0430\u043d\u043e\u0432\u0446\u0438'), 'en': 'Batanovtsi'}, '3522427':{'de': 'Belair, Luxemburg', 'en': 'Belair, Luxembourg', 'fr': 'Belair, Luxembourg'}, '3522421':{'de': 'Weicherdingen', 'en': 'Weicherdange', 'fr': 'Weicherdange'}, '3522423':{'de': 'Bad Mondorf', 'en': 'Mondorf-les-Bains', 'fr': 'Mondorf-les-Bains'}, '3522422':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '35931403':{'bg': u('\u0422\u0440\u0438\u0432\u043e\u0434\u0438\u0446\u0438'), 'en': 'Trivoditsi'}, '35931402':{'bg': u('\u0421\u043a\u043e\u0431\u0435\u043b\u0435\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Skobelevo, Plovdiv'}, '35931401':{'bg': u('\u041a\u0430\u0434\u0438\u0435\u0432\u043e'), 'en': 'Kadievo'}, '3742625':{'am': u('\u054e\u0561\u0580\u0564\u0565\u0576\u056b\u056f'), 'en': 'Vardenik', 'ru': u('\u0412\u0430\u0440\u0434\u0435\u043d\u0438\u043a')}, '436233':{'de': 'Oberwang', 'en': 'Oberwang'}, '436234':{'de': 'Zell am Moos', 'en': 'Zell am Moos'}, '436235':{'de': 'Thalgau', 'en': 'Thalgau'}, '3329637':{'en': 'Lannion', 'fr': 'Lannion'}, '3522688':{'de': 'Mertzig/Wahl', 'en': 'Mertzig/Wahl', 'fr': 'Mertzig/Wahl'}, '3329635':{'en': u('Plestin-les-Gr\u00e8ves'), 'fr': u('Plestin-les-Gr\u00e8ves')}, '3329633':{'en': 'Saint-Brieuc', 'fr': 'Saint-Brieuc'}, '3329631':{'en': 'Lamballe', 'fr': 'Lamballe'}, '3329630':{'en': 'Lamballe', 'fr': 'Lamballe'}, '3522681':{'de': u('Ettelbr\u00fcck/Reckange-sur-Mess'), 'en': 'Ettelbruck/Reckange-sur-Mess', 'fr': 'Ettelbruck/Reckange-sur-Mess'}, '3522680':{'de': 'Diekirch', 'en': 'Diekirch', 'fr': 'Diekirch'}, '3522683':{'de': 'Vianden', 'en': 'Vianden', 'fr': 'Vianden'}, '3522685':{'de': 'Bissen/Roost', 'en': 'Bissen/Roost', 'fr': 'Bissen/Roost'}, '3522684':{'de': 'Han/Lesse', 'en': 'Han/Lesse', 'fr': 'Han/Lesse'}, '3522687':{'de': 'Fels', 'en': 'Larochette', 'fr': 'Larochette'}, '3329638':{'en': 'Plouaret', 'fr': 'Plouaret'}, '3323807':{'en': 'Montargis', 'fr': 'Montargis'}, '3354729':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '433615':{'de': 'Trieben', 'en': 'Trieben'}, '433617':{'de': 'Gaishorn am See', 'en': 'Gaishorn am See'}, '3346888':{'en': 'Banyuls-sur-Mer', 'fr': 'Banyuls-sur-Mer'}, '3346887':{'en': u('C\u00e9ret'), 'fr': u('C\u00e9ret')}, '3346886':{'en': u('Le Barcar\u00e8s'), 'fr': u('Le Barcar\u00e8s')}, '3346885':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3346884':{'en': u('Ille-sur-T\u00eat'), 'fr': u('Ille-sur-T\u00eat')}, '3346883':{'en': 'Le Boulou', 'fr': 'Le Boulou'}, '3346882':{'en': 'Collioure', 'fr': 'Collioure'}, '3346881':{'en': u('Argel\u00e8s-sur-Mer'), 'fr': u('Argel\u00e8s-sur-Mer')}, '3346880':{'en': 'Canet-en-Roussillon', 'fr': 'Canet-en-Roussillon'}, '442879':{'en': 'Magherafelt'}, '442871':{'en': 'Londonderry'}, '442870':{'en': 'Coleraine'}, '442877':{'en': 'Limavady'}, '34860':{'en': 'Valencia', 'es': 'Valencia'}, '34868':{'en': 'Murcia', 'es': 'Murcia'}, '34869':{'en': 'Cuenca', 'es': 'Cuenca'}, '3332116':{'en': 'Arras', 'fr': 'Arras'}, '3332117':{'en': 'Calais', 'fr': 'Calais'}, '3332114':{'en': 'Lens', 'fr': 'Lens'}, '3332115':{'en': 'Arras', 'fr': 'Arras'}, '3332113':{'en': 'Lens', 'fr': 'Lens'}, '3332110':{'en': 'Boulogne-sur-Mer', 'fr': 'Boulogne-sur-Mer'}, '3332119':{'en': 'Calais', 'fr': 'Calais'}, '355866':{'en': u('Libonik/Vreshtaz, Kor\u00e7\u00eb')}, '44151':{'en': 'Liverpool'}, '3325189':{'en': 'Nantes', 'fr': 'Nantes'}, '3325185':{'en': 'Sainte-Luce-sur-Loire', 'fr': 'Sainte-Luce-sur-Loire'}, '3325184':{'en': 'Nantes', 'fr': 'Nantes'}, '3325186':{'en': 'Nantes', 'fr': 'Nantes'}, '3325181':{'en': 'Nantes', 'fr': 'Nantes'}, '3325180':{'en': 'Nantes', 'fr': 'Nantes'}, '3325183':{'en': 'Nantes', 'fr': 'Nantes'}, '3325182':{'en': 'Nantes', 'fr': 'Nantes'}, '3347257':{'en': 'Lyon', 'fr': 'Lyon'}, '3522757':{'de': 'Esch-sur-Alzette/Schifflingen', 'en': 'Esch-sur-Alzette/Schifflange', 'fr': 'Esch-sur-Alzette/Schifflange'}, '435282':{'de': 'Zell am Ziller', 'en': 'Zell am Ziller'}, '3522756':{'de': u('R\u00fcmelingen'), 'en': 'Rumelange', 'fr': 'Rumelange'}, '390172':{'it': 'Savigliano'}, '3349537':{'en': 'Saint-Florent', 'fr': 'Saint-Florent'}, '3349534':{'en': 'Bastia', 'fr': 'Bastia'}, '390171':{'en': 'Cuneo', 'it': 'Cuneo'}, '3349532':{'en': 'Bastia', 'fr': 'Bastia'}, '3349533':{'en': 'Bastia', 'fr': 'Bastia'}, '3349530':{'en': 'Bastia', 'fr': 'Bastia'}, '3349531':{'en': 'Bastia', 'fr': 'Bastia'}, '35974347':{'bg': u('\u0420\u0430\u0437\u0434\u043e\u043b'), 'en': 'Razdol'}, '35974346':{'bg': u('\u0426\u0430\u043f\u0430\u0440\u0435\u0432\u043e'), 'en': 'Tsaparevo'}, '35974348':{'bg': u('\u0418\u0433\u0440\u0430\u043b\u0438\u0449\u0435'), 'en': 'Igralishte'}, '3593046':{'bg': u('\u0411\u0430\u0440\u0443\u0442\u0438\u043d'), 'en': 'Barutin'}, '3593045':{'bg': u('\u0414\u043e\u0441\u043f\u0430\u0442'), 'en': 'Dospat'}, '3594129':{'bg': u('\u041c\u0430\u0434\u0436\u0435\u0440\u0438\u0442\u043e'), 'en': 'Madzherito'}, '3593044':{'bg': u('\u041b\u044f\u0441\u043a\u043e\u0432\u043e, \u0421\u043c\u043e\u043b.'), 'en': 'Lyaskovo, Smol.'}, '3594121':{'bg': u('\u041b\u044e\u043b\u044f\u043a'), 'en': 'Lyulyak'}, '34987':{'en': u('Le\u00f3n'), 'es': u('Le\u00f3n')}, '3594123':{'bg': u('\u0411\u043e\u0433\u043e\u043c\u0438\u043b\u043e\u0432\u043e'), 'en': 'Bogomilovo'}, '3522758':{'de': 'Soleuvre/Differdingen', 'en': 'Soleuvre/Differdange', 'fr': 'Soleuvre/Differdange'}, '3594125':{'bg': u('\u041c\u0438\u0445\u0430\u0439\u043b\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Mihaylovo, St. Zagora'}, '3594124':{'bg': u('\u0417\u043c\u0435\u0439\u043e\u0432\u043e'), 'en': 'Zmeyovo'}, '3593042':{'bg': u('\u0411\u043e\u0440\u0438\u043d\u043e'), 'en': 'Borino'}, '3598125':{'bg': u('\u041a\u043e\u043f\u0440\u0438\u0432\u0435\u0446'), 'en': 'Koprivets'}, '3598124':{'bg': u('\u041d\u043e\u0432\u0433\u0440\u0430\u0434'), 'en': 'Novgrad'}, '3598127':{'bg': u('\u041a\u0430\u0440\u0430\u043c\u0430\u043d\u043e\u0432\u043e'), 'en': 'Karamanovo'}, '435254':{'de': u('S\u00f6lden'), 'en': u('S\u00f6lden')}, '435253':{'de': u('L\u00e4ngenfeld'), 'en': u('L\u00e4ngenfeld')}, '34985':{'en': 'Asturias', 'es': 'Asturias'}, '3598123':{'bg': u('\u0411\u043e\u0441\u0438\u043b\u043a\u043e\u0432\u0446\u0438'), 'en': 'Bosilkovtsi'}, '3598122':{'bg': u('\u0426\u0435\u043d\u043e\u0432\u043e, \u0420\u0443\u0441\u0435'), 'en': 'Tsenovo, Ruse'}, '3593040':{'bg': u('\u0422\u0440\u0438\u0433\u0440\u0430\u0434'), 'en': 'Trigrad'}, '3598129':{'bg': u('\u041b\u043e\u043c \u0427\u0435\u0440\u043a\u043e\u0432\u043d\u0430'), 'en': 'Lom Cherkovna'}, '3598128':{'bg': u('\u041f\u043e\u043b\u0441\u043a\u043e \u041a\u043e\u0441\u043e\u0432\u043e'), 'en': 'Polsko Kosovo'}, '3324768':{'en': u('Jou\u00e9-l\u00e8s-Tours'), 'fr': u('Jou\u00e9-l\u00e8s-Tours')}, '3324766':{'en': 'Tours', 'fr': 'Tours'}, '3324767':{'en': u('Jou\u00e9-l\u00e8s-Tours'), 'fr': u('Jou\u00e9-l\u00e8s-Tours')}, '3324764':{'en': 'Tours', 'fr': 'Tours'}, '3324765':{'en': 'Sainte-Maure-de-Touraine', 'fr': 'Sainte-Maure-de-Touraine'}, '3324763':{'en': 'Saint-Pierre-des-Corps', 'fr': 'Saint-Pierre-des-Corps'}, '3324760':{'en': 'Tours', 'fr': 'Tours'}, '3324761':{'en': 'Tours', 'fr': 'Tours'}, '433174':{'de': 'Birkfeld', 'en': 'Birkfeld'}, '433175':{'de': 'Anger', 'en': 'Anger'}, '433176':{'de': 'Stubenberg', 'en': 'Stubenberg'}, '433177':{'de': 'Puch bei Weiz', 'en': 'Puch bei Weiz'}, '433170':{'de': 'Fischbach', 'en': 'Fischbach'}, '433171':{'de': 'Gasen', 'en': 'Gasen'}, '433172':{'de': 'Weiz', 'en': 'Weiz'}, '433173':{'de': 'Ratten', 'en': 'Ratten'}, '433178':{'de': 'Sankt Ruprecht an der Raab', 'en': 'St. Ruprecht an der Raab'}, '433179':{'de': 'Passail', 'en': 'Passail'}, '441305':{'en': 'Dorchester'}, '4418516':{'en': 'Great Bernera'}, '441302':{'en': 'Doncaster'}, '441871':{'en': 'Castlebay'}, '441300':{'en': 'Cerne Abbas'}, '441873':{'en': 'Abergavenny'}, '4122':{'de': 'Genf', 'en': 'Geneva', 'fr': u('Gen\u00e8ve'), 'it': 'Ginevra'}, '4121':{'de': 'Lausanne', 'en': 'Lausanne', 'fr': 'Lausanne', 'it': 'Losanna'}, '4127':{'de': 'Sitten', 'en': 'Sion', 'fr': 'Sion', 'it': 'Sion'}, '4126':{'de': 'Freiburg', 'en': 'Fribourg', 'fr': 'Fribourg', 'it': 'Friburgo'}, '4124':{'de': 'Yverdon/Aigle', 'en': 'Yverdon/Aigle', 'fr': 'Yverdon/Aigle', 'it': 'Yverdon/Aigle'}, '3595526':{'bg': u('\u041a\u043b\u0438\u043a\u0430\u0447'), 'en': 'Klikach'}, '3595527':{'bg': u('\u0421\u043e\u043a\u043e\u043b\u043e\u0432\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Sokolovo, Burgas'}, '3595524':{'bg': u('\u0415\u043a\u0437\u0430\u0440\u0445 \u0410\u043d\u0442\u0438\u043c\u043e\u0432\u043e'), 'en': 'Ekzarh Antimovo'}, '3595525':{'bg': u('\u0414\u0435\u0432\u0435\u0442\u0430\u043a'), 'en': 'Devetak'}, '3347109':{'en': 'Le Puy en Velay', 'fr': 'Le Puy en Velay'}, '3595523':{'bg': u('\u041a\u0440\u0443\u043c\u043e\u0432\u043e \u0433\u0440\u0430\u0434\u0438\u0449\u0435'), 'en': 'Krumovo gradishte'}, '3595520':{'bg': u('\u0427\u0435\u0440\u043a\u043e\u0432\u043e'), 'en': 'Cherkovo'}, '3595521':{'bg': u('\u0412\u0435\u043d\u0435\u0446, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Venets, Burgas'}, '3347105':{'en': 'Le Puy en Velay', 'fr': 'Le Puy en Velay'}, '3347456':{'en': 'Ampuis', 'fr': 'Ampuis'}, '3347455':{'en': u('Ch\u00e2tillon-sur-Chalaronne'), 'fr': u('Ch\u00e2tillon-sur-Chalaronne')}, '3347106':{'en': 'Le Puy en Velay', 'fr': 'Le Puy en Velay'}, '3347453':{'en': 'Vienne', 'fr': 'Vienne'}, '3595528':{'bg': u('\u041d\u0435\u0432\u0435\u0441\u0442\u0438\u043d\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Nevestino, Burgas'}, '3347102':{'en': 'Le Puy en Velay', 'fr': 'Le Puy en Velay'}, '38932':{'en': 'Stip/Probistip/Sveti Nikole/Radovis'}, '38933':{'en': 'Kocani/Berovo/Delcevo/Vinica'}, '38931':{'en': 'Kumanovo/Kriva Palanka/Kratovo'}, '38934':{'en': 'Gevgelija/Valandovo/Strumica/Dojran'}, '4419758':{'en': 'Strathdon'}, '3599551':{'bg': u('\u0413\u0435\u043e\u0440\u0433\u0438 \u0414\u0430\u043c\u044f\u043d\u043e\u0432\u043e'), 'en': 'Georgi Damyanovo'}, '3338784':{'en': 'Forbach', 'fr': 'Forbach'}, '3597157':{'bg': u('\u0421\u0430\u0440\u0430\u043d\u0446\u0438'), 'en': 'Sarantsi'}, '4191':{'de': 'Bellinzona', 'en': 'Bellinzona', 'fr': 'Bellinzona', 'it': 'Bellinzona'}, '3316909':{'en': 'Chilly-Mazarin', 'fr': 'Chilly-Mazarin'}, '3336919':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3316906':{'en': 'Ris-Orangis', 'fr': 'Ris-Orangis'}, '3336914':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3316900':{'en': u('Quincy-sous-S\u00e9nart'), 'fr': u('Quincy-sous-S\u00e9nart')}, '432841':{'de': 'Vitis', 'en': 'Vitis'}, '359608':{'bg': u('\u041f\u043e\u043f\u043e\u0432\u043e, \u0422\u044a\u0440\u0433.'), 'en': 'Popovo, Targ.'}, '359605':{'bg': u('\u041e\u043c\u0443\u0440\u0442\u0430\u0433'), 'en': 'Omurtag'}, '359601':{'bg': u('\u0422\u044a\u0440\u0433\u043e\u0432\u0438\u0449\u0435'), 'en': 'Targovishte'}, '3338781':{'en': 'Freyming-Merlebach', 'fr': 'Freyming-Merlebach'}, '46144':{'en': u('\u00d6desh\u00f6g'), 'sv': u('\u00d6desh\u00f6g')}, '46142':{'en': u('Mj\u00f6lby-Sk\u00e4nninge-Boxholm'), 'sv': u('Mj\u00f6lby-Sk\u00e4nninge-Boxholm')}, '46143':{'en': 'Vadstena', 'sv': 'Vadstena'}, '46140':{'en': u('Tran\u00e5s'), 'sv': u('Tran\u00e5s')}, '46141':{'en': 'Motala', 'sv': 'Motala'}, '3323169':{'en': u('Cond\u00e9-sur-Noireau'), 'fr': u('Cond\u00e9-sur-Noireau')}, '3323168':{'en': 'Vire', 'fr': 'Vire'}, '3323161':{'en': 'Lisieux', 'fr': 'Lisieux'}, '44200':{'en': 'London'}, '3323162':{'en': 'Lisieux', 'fr': 'Lisieux'}, '3323165':{'en': u('Pont-l\'\u00c9v\u00eaque'), 'fr': u('Pont-l\'\u00c9v\u00eaque')}, '3323164':{'en': u('Pont-l\'\u00c9v\u00eaque'), 'fr': u('Pont-l\'\u00c9v\u00eaque')}, '3323167':{'en': 'Vire', 'fr': 'Vire'}, '3323166':{'en': 'Vire', 'fr': 'Vire'}, '3349059':{'en': 'Mallemort', 'fr': 'Mallemort'}, '3349058':{'en': 'Miramas', 'fr': 'Miramas'}, '3349051':{'en': 'Orange', 'fr': 'Orange'}, '3349050':{'en': 'Miramas', 'fr': 'Miramas'}, '3349053':{'en': 'Salon-de-Provence', 'fr': 'Salon-de-Provence'}, '3349052':{'en': 'Arles', 'fr': 'Arles'}, '3349055':{'en': u('P\u00e9lissanne'), 'fr': u('P\u00e9lissanne')}, '3349054':{'en': 'Fontvieille', 'fr': 'Fontvieille'}, '3349057':{'en': u('Eygui\u00e8res'), 'fr': u('Eygui\u00e8res')}, '3349056':{'en': 'Salon-de-Provence', 'fr': 'Salon-de-Provence'}, '3354005':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3354007':{'en': 'Bayonne', 'fr': 'Bayonne'}, '3349235':{'en': 'Seyne-les-Alpes', 'fr': 'Seyne-les-Alpes'}, '390343':{'en': 'Sondrio', 'it': 'Chiavenna'}, '3349236':{'en': 'Digne-les-Bains', 'fr': 'Digne-les-Bains'}, '3349231':{'en': 'Digne-les-Bains', 'fr': 'Digne-les-Bains'}, '3349230':{'en': 'Digne-les-Bains', 'fr': 'Digne-les-Bains'}, '3349941':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3349232':{'en': 'Digne-les-Bains', 'fr': 'Digne-les-Bains'}, '35961602':{'bg': u('\u0426\u0430\u0440\u0441\u043a\u0438 \u0438\u0437\u0432\u043e\u0440'), 'en': 'Tsarski izvor'}, '35961603':{'bg': u('\u041b\u043e\u0437\u0435\u043d, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Lozen, V. Tarnovo'}, '35961604':{'bg': u('\u041c\u0438\u0440\u043e\u0432\u043e, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Mirovo, V. Tarnovo'}, '3349238':{'en': 'Vallauris', 'fr': 'Vallauris'}, '35961606':{'bg': u('\u0412\u043b\u0430\u0434\u0438\u0441\u043b\u0430\u0432'), 'en': 'Vladislav'}, '35961607':{'bg': u('\u0411\u0430\u043b\u043a\u0430\u043d\u0446\u0438, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Balkantsi, V. Tarnovo'}, '3522745':{'de': 'Diedrich', 'en': 'Diedrich', 'fr': 'Diedrich'}, '3522747':{'de': 'Lintgen', 'en': 'Lintgen', 'fr': 'Lintgen'}, '3522740':{'de': 'Howald', 'en': 'Howald', 'fr': 'Howald'}, '3522742':{'de': 'Plateau de Kirchberg', 'en': 'Plateau de Kirchberg', 'fr': 'Plateau de Kirchberg'}, '3522743':{'de': 'Findel/Kirchberg', 'en': 'Findel/Kirchberg', 'fr': 'Findel/Kirchberg'}, '3597036':{'bg': u('\u0411\u0430\u043b\u0430\u043d\u043e\u0432\u043e'), 'en': 'Balanovo'}, '3597034':{'bg': u('\u0414\u0436\u0435\u0440\u043c\u0430\u043d'), 'en': 'Dzherman'}, '3597035':{'bg': u('\u0427\u0435\u0440\u0432\u0435\u043d \u0431\u0440\u0435\u0433'), 'en': 'Cherven breg'}, '3522748':{'de': 'Contern/Foetz', 'en': 'Contern/Foetz', 'fr': 'Contern/Foetz'}, '3522749':{'de': 'Howald', 'en': 'Howald', 'fr': 'Howald'}, '3597030':{'bg': u('\u0420\u0435\u0441\u0438\u043b\u043e\u0432\u043e'), 'en': 'Resilovo'}, '3597031':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u041a\u043e\u0437\u043d\u0438\u0446\u0430'), 'en': 'Gorna Koznitsa'}, '441869':{'en': 'Bicester'}, '37428197':{'am': u('\u0535\u056c\u0583\u056b\u0576'), 'en': 'Yelpin', 'ru': u('\u0415\u043b\u043f\u0438\u043d')}, '441863':{'en': 'Ardgay'}, '441862':{'en': 'Tain'}, '3336265':{'en': 'Lille', 'fr': 'Lille'}, '441865':{'en': 'Oxford'}, '441864':{'en': 'Abington (Crawford)'}, '3338879':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338878':{'en': 'Lingolsheim', 'fr': 'Lingolsheim'}, '3338877':{'en': 'Lingolsheim', 'fr': 'Lingolsheim'}, '3338876':{'en': 'Lingolsheim', 'fr': 'Lingolsheim'}, '3338875':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338874':{'en': 'Benfeld', 'fr': 'Benfeld'}, '3338873':{'en': 'Haguenau', 'fr': 'Haguenau'}, '3338872':{'en': 'Schweighouse-sur-Moder', 'fr': 'Schweighouse-sur-Moder'}, '3338871':{'en': 'Saverne', 'fr': 'Saverne'}, '432784':{'de': 'Perschling', 'en': 'Perschling'}, '432786':{'de': u('Oberw\u00f6lbling'), 'en': u('Oberw\u00f6lbling')}, '37428194':{'am': u('\u0531\u0580\u0565\u0576\u056b'), 'en': 'Areni', 'ru': u('\u0410\u0440\u0435\u043d\u0438')}, '432782':{'de': 'Herzogenburg', 'en': 'Herzogenburg'}, '432783':{'de': 'Traismauer', 'en': 'Traismauer'}, '37278':{'en': u('V\u00f5ru')}, '37279':{'en': u('P\u00f5lva')}, '37273':{'en': 'Tartu'}, '37274':{'en': 'Tartu'}, '37275':{'en': 'Tartu'}, '37276':{'en': 'Valga'}, '37277':{'en': u('J\u00f5geva')}, '3323345':{'en': 'Coutances', 'fr': 'Coutances'}, '3323344':{'en': 'Cherbourg-Octeville', 'fr': 'Cherbourg-Octeville'}, '35981266':{'bg': u('\u0421\u0442\u044a\u0440\u043c\u0435\u043d, \u0420\u0443\u0441\u0435'), 'en': 'Starmen, Ruse'}, '3355609':{'en': 'Soulac-sur-Mer', 'fr': 'Soulac-sur-Mer'}, '3323340':{'en': 'Valognes', 'fr': 'Valognes'}, '3355359':{'en': u('Sarlat-la-Can\u00e9da'), 'fr': u('Sarlat-la-Can\u00e9da')}, '3323342':{'en': 'Carentan', 'fr': 'Carentan'}, '3355357':{'en': 'Bergerac', 'fr': 'Bergerac'}, '3355356':{'en': 'Nontron', 'fr': 'Nontron'}, '3355355':{'en': 'Thiviers', 'fr': 'Thiviers'}, '3355606':{'en': 'Lormont', 'fr': 'Lormont'}, '3355353':{'en': u('P\u00e9rigueux'), 'fr': u('P\u00e9rigueux')}, '3355600':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355603':{'en': 'Lacanau', 'fr': 'Lacanau'}, '3355602':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3322342':{'en': 'Rennes', 'fr': 'Rennes'}, '3322343':{'en': 'Montfort-sur-Meu', 'fr': 'Montfort-sur-Meu'}, '3322340':{'en': 'Rennes', 'fr': 'Rennes'}, '3332308':{'en': 'Saint-Quentin', 'fr': 'Saint-Quentin'}, '3322346':{'en': 'Rennes', 'fr': 'Rennes'}, '432165':{'de': 'Hainburg a.d. Donau', 'en': 'Hainburg a.d. Donau'}, '3322344':{'en': 'Rennes', 'fr': 'Rennes'}, '3322345':{'en': u('Cesson-S\u00e9vign\u00e9'), 'fr': u('Cesson-S\u00e9vign\u00e9')}, '432168':{'de': 'Mannersdorf am Leithagebirge', 'en': 'Mannersdorf am Leithagebirge'}, '432169':{'de': 'Trautmannsdorf an der Leitha', 'en': 'Trautmannsdorf an der Leitha'}, '3322348':{'en': 'Rennes', 'fr': 'Rennes'}, '437667':{'de': 'Sankt Georgen im Attergau', 'en': 'St. Georgen im Attergau'}, '3332307':{'en': 'Bohain-en-Vermandois', 'fr': 'Bohain-en-Vermandois'}, '3332306':{'en': 'Saint-Quentin', 'fr': 'Saint-Quentin'}, '3332305':{'en': 'Saint-Quentin', 'fr': 'Saint-Quentin'}, '3332304':{'en': 'Saint-Quentin', 'fr': 'Saint-Quentin'}, '435517':{'de': 'Riezlern', 'en': 'Riezlern'}, '3354918':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354919':{'en': u('Ch\u00e2tellerault'), 'fr': u('Ch\u00e2tellerault')}, '3354917':{'en': 'Niort', 'fr': 'Niort'}, '3354911':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3359032':{'en': 'Baie Mahault', 'fr': 'Baie Mahault'}, '3359038':{'en': 'Baie Mahault', 'fr': 'Baie Mahault'}, '432814':{'de': 'Langschlag', 'en': 'Langschlag'}, '435518':{'de': 'Mellau', 'en': 'Mellau'}, '435519':{'de': u('Schr\u00f6cken'), 'en': u('Schr\u00f6cken')}, '3595959':{'bg': u('\u0417\u0432\u0435\u0437\u0434\u0435\u0446'), 'en': 'Zvezdets'}, '3595958':{'bg': u('\u0413\u0440\u0430\u043c\u0430\u0442\u0438\u043a\u043e\u0432\u043e'), 'en': 'Gramatikovo'}, '3595952':{'bg': u('\u041c\u0430\u043b\u043a\u043e \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Malko Tarnovo'}, '432816':{'de': 'Karlstift', 'en': 'Karlstift'}, '3353351':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3343837':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3332379':{'en': 'Laon', 'fr': 'Laon'}, '359453':{'bg': u('\u041a\u043e\u0442\u0435\u043b'), 'en': 'Kotel'}, '35935502':{'bg': u('\u0424\u043e\u0442\u0438\u043d\u043e\u0432\u043e, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Fotinovo, Pazardzhik'}, '359457':{'bg': u('\u041d\u043e\u0432\u0430 \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Nova Zagora'}, '359454':{'bg': u('\u0422\u0432\u044a\u0440\u0434\u0438\u0446\u0430, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Tvarditsa, Sliven'}, '35935501':{'bg': u('\u0420\u0430\u0432\u043d\u043e\u0433\u043e\u0440'), 'en': 'Ravnogor'}, '3324395':{'en': u('Sabl\u00e9-sur-Sarthe'), 'fr': u('Sabl\u00e9-sur-Sarthe')}, '3324394':{'en': u('La Fl\u00e8che'), 'fr': u('La Fl\u00e8che')}, '3324392':{'en': u('Sabl\u00e9-sur-Sarthe'), 'fr': u('Sabl\u00e9-sur-Sarthe')}, '3324391':{'en': 'Laval', 'fr': 'Laval'}, '35960382':{'bg': u('\u041a\u043e\u0432\u0430\u0447\u0435\u0432\u0435\u0446'), 'en': 'Kovachevets'}, '35960383':{'bg': u('\u0411\u0435\u0440\u043a\u043e\u0432\u0441\u043a\u0438'), 'en': 'Berkovski'}, '35960380':{'bg': u('\u0414\u0440\u0438\u043d\u043e\u0432\u043e'), 'en': 'Drinovo'}, '35960386':{'bg': u('\u0412\u043e\u0434\u0438\u0446\u0430, \u0422\u044a\u0440\u0433.'), 'en': 'Voditsa, Targ.'}, '35960387':{'bg': u('\u0413\u043b\u043e\u0433\u0438\u043d\u043a\u0430'), 'en': 'Gloginka'}, '35960384':{'bg': u('\u0413\u0430\u0433\u043e\u0432\u043e'), 'en': 'Gagovo'}, '35960385':{'bg': u('\u041b\u043e\u043c\u0446\u0438'), 'en': 'Lomtsi'}, '441480':{'en': 'Huntingdon'}, '3347840':{'en': 'Heyrieux', 'fr': 'Heyrieux'}, '3347841':{'en': 'Bron', 'fr': 'Bron'}, '3347842':{'en': 'Lyon', 'fr': 'Lyon'}, '3347667':{'en': 'Voiron', 'fr': 'Voiron'}, '3347844':{'en': 'Mornant', 'fr': 'Mornant'}, '3347661':{'en': 'Meylan', 'fr': 'Meylan'}, '3347846':{'en': 'Irigny', 'fr': 'Irigny'}, '3347847':{'en': 'Lyon', 'fr': 'Lyon'}, '3347848':{'en': 'Saint-Martin-en-Haut', 'fr': 'Saint-Martin-en-Haut'}, '3347849':{'en': u('D\u00e9cines-Charpieu'), 'fr': u('D\u00e9cines-Charpieu')}, '3347668':{'en': 'Vizille', 'fr': 'Vizille'}, '374286':{'am': u('\u0544\u0565\u0572\u0580\u056b/\u0531\u0563\u0561\u0580\u0561\u056f'), 'en': 'Meghri/Agarak', 'ru': u('\u041c\u0435\u0433\u0440\u0438/\u0410\u0433\u0430\u0440\u0430\u043a')}, '374287':{'am': u('\u054b\u0565\u0580\u0574\u0578\u0582\u056f'), 'en': 'Jermuk', 'ru': u('\u0414\u0436\u0435\u0440\u043c\u0443\u043a')}, '374284':{'am': u('\u0533\u0578\u0580\u056b\u057d/\u054e\u0565\u0580\u056b\u0577\u0565\u0576'), 'en': 'Goris/Verishen', 'ru': u('\u0413\u043e\u0440\u0438\u0441/\u0412\u0435\u0440\u0438\u0448\u0435\u043d')}, '374285':{'am': u('\u0534\u0561\u057e\u056b\u0569 \u0532\u0565\u056f/\u0554\u0561\u057b\u0561\u0580\u0561\u0576/\u053f\u0561\u057a\u0561\u0576'), 'en': 'Davit Bek/Kajaran/Kapan', 'ru': u('\u0414\u0430\u0432\u0438\u0442 \u0411\u0435\u043a/\u041a\u0430\u0434\u0436\u0430\u0440\u0430\u043d/\u041a\u0430\u043f\u0430\u043d')}, '374282':{'am': u('\u054e\u0561\u0575\u0584'), 'en': 'Vayk region', 'ru': u('\u0412\u0430\u0439\u043a')}, '374281':{'am': u('\u0533\u0565\u057f\u0561\u0583/\u054d\u0561\u056c\u056c\u056b/\u0535\u0572\u0565\u0563\u0576\u0561\u0571\u0578\u0580'), 'en': 'Getap/Salli/Yeghegnadzor', 'ru': u('\u0413\u0435\u0442\u0430\u043f/\u0421\u0430\u043b\u043b\u0438/\u0415\u0445\u0435\u0433\u043d\u0430\u0434\u0437\u043e\u0440')}, '3595773':{'bg': u('\u041b\u043e\u0437\u0435\u043d\u0435\u0446, \u0414\u043e\u0431\u0440.'), 'en': 'Lozenets, Dobr.'}, '3595772':{'bg': u('\u0422\u0435\u043b\u0435\u0440\u0438\u0433'), 'en': 'Telerig'}, '3595771':{'bg': u('\u041a\u0440\u0443\u0448\u0430\u0440\u0438'), 'en': 'Krushari'}, '3595776':{'bg': u('\u0427\u0435\u0440\u043d\u0430, \u0414\u043e\u0431\u0440.'), 'en': 'Cherna, Dobr.'}, '3595775':{'bg': u('\u041f\u043e\u043b\u043a\u043e\u0432\u043d\u0438\u043a \u0414\u044f\u043a\u043e\u0432\u043e'), 'en': 'Polkovnik Dyakovo'}, '3595774':{'bg': u('\u041a\u043e\u0440\u0438\u0442\u0435\u043d'), 'en': 'Koriten'}, '3338051':{'en': u('Chen\u00f4ve'), 'fr': u('Chen\u00f4ve')}, '3338050':{'en': 'Dijon', 'fr': 'Dijon'}, '3338053':{'en': 'Dijon', 'fr': 'Dijon'}, '3338052':{'en': u('Chen\u00f4ve'), 'fr': u('Chen\u00f4ve')}, '3324025':{'en': 'Sainte-Luce-sur-Loire', 'fr': 'Sainte-Luce-sur-Loire'}, '3324024':{'en': u('Gu\u00e9rande'), 'fr': u('Gu\u00e9rande')}, '3338057':{'en': 'Talant', 'fr': 'Talant'}, '3338056':{'en': u('Fontaine-l\u00e8s-Dijon'), 'fr': u('Fontaine-l\u00e8s-Dijon')}, '3338059':{'en': 'Dijon', 'fr': 'Dijon'}, '3338058':{'en': 'Dijon', 'fr': 'Dijon'}, '3346640':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346643':{'en': u('Al\u00e8s'), 'fr': u('Al\u00e8s')}, '3346642':{'en': 'Aumont-Aubrac', 'fr': 'Aumont-Aubrac'}, '390173':{'it': 'Alba'}, '3329611':{'en': 'Ploumagoar', 'fr': 'Ploumagoar'}, '3329615':{'en': u('Tr\u00e9beurden'), 'fr': u('Tr\u00e9beurden')}, '3329614':{'en': 'Lannion', 'fr': 'Lannion'}, '3329616':{'en': u('Plou\u00e9zec'), 'fr': u('Plou\u00e9zec')}, '3338460':{'en': 'Les Rousses', 'fr': 'Les Rousses'}, '3338462':{'en': 'Lure', 'fr': 'Lure'}, '3338464':{'en': 'Gray', 'fr': 'Gray'}, '3338465':{'en': 'Gray', 'fr': 'Gray'}, '3338466':{'en': 'Arbois', 'fr': 'Arbois'}, '3338469':{'en': 'Dole', 'fr': 'Dole'}, '390175':{'it': 'Saluzzo'}, '3597735':{'bg': u('\u041b\u0435\u0432\u0430 \u0440\u0435\u043a\u0430'), 'en': 'Leva reka'}, '3597734':{'bg': u('\u0413\u043b\u0430\u0432\u0430\u043d\u043e\u0432\u0446\u0438, \u041f\u0435\u0440\u043d\u0438\u043a'), 'en': 'Glavanovtsi, Pernik'}, '3597731':{'bg': u('\u0422\u0440\u044a\u043d'), 'en': 'Tran'}, '3597733':{'bg': u('\u0424\u0438\u043b\u0438\u043f\u043e\u0432\u0446\u0438'), 'en': 'Filipovtsi'}, '3597732':{'bg': u('\u0412\u0443\u043a\u0430\u043d'), 'en': 'Vukan'}, '441730':{'en': 'Petersfield'}, '3323752':{'en': 'Nogent-le-Rotrou', 'fr': 'Nogent-le-Rotrou'}, '3323753':{'en': 'Nogent-le-Rotrou', 'fr': 'Nogent-le-Rotrou'}, '3323750':{'en': 'Dreux', 'fr': 'Dreux'}, '3323751':{'en': 'Nogent-le-Roi', 'fr': 'Nogent-le-Roi'}, '3332170':{'en': 'Lens', 'fr': 'Lens'}, '3332171':{'en': 'Arras', 'fr': 'Arras'}, '3332172':{'en': u('Li\u00e9vin'), 'fr': u('Li\u00e9vin')}, '3332174':{'en': 'Carvin', 'fr': 'Carvin'}, '3332175':{'en': u('H\u00e9nin-Beaumont'), 'fr': u('H\u00e9nin-Beaumont')}, '3332176':{'en': u('H\u00e9nin-Beaumont'), 'fr': u('H\u00e9nin-Beaumont')}, '3332177':{'en': 'Leforest', 'fr': 'Leforest'}, '3332178':{'en': 'Lens', 'fr': 'Lens'}, '390481':{'en': 'Gorizia', 'it': 'Gorizia'}, '3354747':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3346713':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346712':{'en': 'Mauguio', 'fr': 'Mauguio'}, '3346711':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '42051':{'en': 'South Moravian Region'}, '3345037':{'en': 'Annemasse', 'fr': 'Annemasse'}, '3345035':{'en': 'Saint-Julien-en-Genevois', 'fr': 'Saint-Julien-en-Genevois'}, '3345034':{'en': u('Samo\u00ebns'), 'fr': u('Samo\u00ebns')}, '3345033':{'en': 'Annecy', 'fr': 'Annecy'}, '3345038':{'en': 'Annemasse', 'fr': 'Annemasse'}, '3349558':{'en': 'Bastia', 'fr': 'Bastia'}, '3349559':{'en': 'Penta-di-Casinca', 'fr': 'Penta-di-Casinca'}, '3324131':{'en': 'Angers', 'fr': 'Angers'}, '3349550':{'en': 'Ajaccio', 'fr': 'Ajaccio'}, '3349551':{'en': 'Ajaccio', 'fr': 'Ajaccio'}, '3349552':{'en': 'Ajaccio', 'fr': 'Ajaccio'}, '3349555':{'en': 'Bastia', 'fr': 'Bastia'}, '3349556':{'en': 'Ghisonaccia', 'fr': 'Ghisonaccia'}, '3349557':{'en': u('Al\u00e9ria'), 'fr': u('Al\u00e9ria')}, '3348974':{'en': 'Nice', 'fr': 'Nice'}, '3317464':{'en': 'Paris', 'fr': 'Paris'}, '3348979':{'en': 'Toulon', 'fr': 'Toulon'}, '3317462':{'en': 'Boulogne-Billancourt', 'fr': 'Boulogne-Billancourt'}, '351289':{'en': 'Faro', 'pt': 'Faro'}, '390722':{'it': 'Urbino'}, '351283':{'en': 'Odemira', 'pt': 'Odemira'}, '351282':{'en': u('Portim\u00e3o'), 'pt': u('Portim\u00e3o')}, '351281':{'en': 'Tavira', 'pt': 'Tavira'}, '351286':{'en': 'Castro Verde', 'pt': 'Castro Verde'}, '351285':{'en': 'Moura', 'pt': 'Moura'}, '351284':{'en': 'Beja', 'pt': 'Beja'}, '3332794':{'en': 'Douai', 'fr': 'Douai'}, '3332795':{'en': 'Douai', 'fr': 'Douai'}, '3332796':{'en': 'Douai', 'fr': 'Douai'}, '3332797':{'en': 'Douai', 'fr': 'Douai'}, '3332792':{'en': 'Aniche', 'fr': 'Aniche'}, '3332793':{'en': 'Douai', 'fr': 'Douai'}, '3332798':{'en': 'Douai', 'fr': 'Douai'}, '3332799':{'en': 'Douai', 'fr': 'Douai'}, '3594143':{'bg': u('\u0421\u044a\u0440\u043d\u0435\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Sarnevo, St. Zagora'}, '3594142':{'bg': u('\u0422\u0440\u043e\u044f\u043d\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Troyanovo, St. Zagora'}, '3594140':{'bg': u('\u041f\u043e\u043b\u0441\u043a\u0438 \u0413\u0440\u0430\u0434\u0435\u0446'), 'en': 'Polski Gradets'}, '3594147':{'bg': u('\u041b\u044e\u0431\u0435\u043d\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Lyubenovo, St. Zagora'}, '3594146':{'bg': u('\u0414\u0438\u043d\u044f'), 'en': 'Dinya'}, '3594145':{'bg': u('\u0417\u043d\u0430\u043c\u0435\u043d\u043e\u0441\u0435\u0446'), 'en': 'Znamenosets'}, '3594144':{'bg': u('\u041a\u043e\u0432\u0430\u0447\u0435\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Kovachevo, St. Zagora'}, '3594149':{'bg': u('\u0422\u0440\u044a\u043d\u043a\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Trankovo, St. Zagora'}, '390143':{'it': 'Novi Ligure'}, '435230':{'de': 'Sellrain', 'en': 'Sellrain'}, '435232':{'de': 'Kematen in Tirol', 'en': 'Kematen in Tirol'}, '435234':{'de': 'Axams', 'en': 'Axams'}, '435236':{'de': 'Gries im Sellrain', 'en': 'Gries im Sellrain'}, '435239':{'de': u('K\u00fchtai'), 'en': u('K\u00fchtai')}, '435238':{'de': 'Zirl', 'en': 'Zirl'}, '39035':{'en': 'Bergamo', 'it': 'Bergamo'}, '390142':{'it': 'Casale Monferrato'}, '3324705':{'en': 'Tours', 'fr': 'Tours'}, '39030':{'en': 'Brescia', 'it': 'Brescia'}, '39031':{'en': 'Como', 'it': 'Como'}, '432715':{'de': u('Wei\u00dfenkirchen in der Wachau'), 'en': 'Weissenkirchen in der Wachau'}, '359848':{'bg': u('\u041a\u0443\u0431\u0440\u0430\u0442'), 'en': 'Kubrat'}, '3338190':{'en': u('Montb\u00e9liard'), 'fr': u('Montb\u00e9liard')}, '3338191':{'en': u('Montb\u00e9liard'), 'fr': u('Montb\u00e9liard')}, '3338192':{'en': 'Pont-de-Roide', 'fr': 'Pont-de-Roide'}, '3338194':{'en': u('Montb\u00e9liard'), 'fr': u('Montb\u00e9liard')}, '3338195':{'en': u('Montb\u00e9liard'), 'fr': u('Montb\u00e9liard')}, '3338197':{'en': u('Montb\u00e9liard'), 'fr': u('Montb\u00e9liard')}, '3338198':{'en': u('Montb\u00e9liard'), 'fr': u('Montb\u00e9liard')}, '3338199':{'en': u('Montb\u00e9liard'), 'fr': u('Montb\u00e9liard')}, '3347479':{'en': 'Beaurepaire', 'fr': 'Beaurepaire'}, '3347478':{'en': 'Vienne', 'fr': 'Vienne'}, '3892':{'en': 'Skopje'}, '3347473':{'en': 'Oyonnax', 'fr': 'Oyonnax'}, '3347475':{'en': 'Nantua', 'fr': 'Nantua'}, '3347477':{'en': 'Oyonnax', 'fr': 'Oyonnax'}, '3347476':{'en': u('Montr\u00e9al-la-Cluse'), 'fr': u('Montr\u00e9al-la-Cluse')}, '3346788':{'en': u('Clermont-l\'H\u00e9rault'), 'fr': u('Clermont-l\'H\u00e9rault')}, '3346789':{'en': 'Cessenon-sur-Orb', 'fr': 'Cessenon-sur-Orb'}, '3346780':{'en': 'Frontignan', 'fr': 'Frontignan'}, '3346781':{'en': 'Le Vigan', 'fr': 'Le Vigan'}, '3346783':{'en': 'Lunel', 'fr': 'Lunel'}, '3346784':{'en': u('Saint-G\u00e9ly-du-Fesc'), 'fr': u('Saint-G\u00e9ly-du-Fesc')}, '3346785':{'en': u('Fabr\u00e8gues'), 'fr': u('Fabr\u00e8gues')}, '434286':{'de': u('Wei\u00dfbriach'), 'en': 'Weissbriach'}, '437948':{'de': u('Hirschbach im M\u00fchlkreis'), 'en': u('Hirschbach im M\u00fchlkreis')}, '3347783':{'en': 'Rive-de-Gier', 'fr': 'Rive-de-Gier'}, '3347781':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347780':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347789':{'en': 'Firminy', 'fr': 'Firminy'}, '441993':{'en': 'Witney'}, '441992':{'en': 'Lea Valley'}, '3594126':{'bg': u('\u0425\u0440\u0438\u0449\u0435\u043d\u0438'), 'en': 'Hrishteni'}, '435256':{'de': 'Untergurgl', 'en': 'Untergurgl'}, '441997':{'en': 'Strathpeffer'}, '37428695':{'am': u('\u0547\u057e\u0561\u0576\u056b\u0571\u0578\u0580'), 'en': 'Shvanidzor', 'ru': u('\u0428\u0432\u0430\u043d\u0438\u0434\u0437\u043e\u0440')}, '435255':{'de': 'Umhausen', 'en': 'Umhausen'}, '437230':{'de': 'Altenberg bei Linz', 'en': 'Altenberg bei Linz'}, '4419643':{'en': 'Patrington'}, '441995':{'en': 'Garstang'}, '441994':{'en': 'St Clears'}, '435252':{'de': 'Oetz', 'en': 'Oetz'}, '441746':{'en': 'Bridgnorth'}, '441747':{'en': 'Shaftesbury'}, '441744':{'en': 'St Helens'}, '436563':{'de': 'Uttendorf', 'en': 'Uttendorf'}, '441743':{'en': 'Shrewsbury'}, '441740':{'en': 'Sedgefield'}, '441748':{'en': 'Richmond'}, '441749':{'en': 'Shepton Mallet'}, '3316494':{'en': u('\u00c9tampes'), 'fr': u('\u00c9tampes')}, '3316497':{'en': u('\u00c9vry'), 'fr': u('\u00c9vry')}, '3316496':{'en': 'Corbeil-Essonnes', 'fr': 'Corbeil-Essonnes'}, '3316491':{'en': 'Limours en Hurepoix', 'fr': 'Limours en Hurepoix'}, '3316490':{'en': 'Arpajon', 'fr': 'Arpajon'}, '3316493':{'en': 'Ballancourt-sur-Essonne', 'fr': 'Ballancourt-sur-Essonne'}, '3316492':{'en': 'Arpajon', 'fr': 'Arpajon'}, '3316499':{'en': 'Mennecy', 'fr': 'Mennecy'}, '3316498':{'en': u('Milly-la-For\u00eat'), 'fr': u('Milly-la-For\u00eat')}, '3349033':{'en': u('B\u00e9darrides'), 'fr': u('B\u00e9darrides')}, '3338937':{'en': 'Thann', 'fr': 'Thann'}, '3349031':{'en': 'Le Pontet', 'fr': 'Le Pontet'}, '3349030':{'en': u('Boll\u00e8ne'), 'fr': u('Boll\u00e8ne')}, '3349037':{'en': 'Camaret-sur-Aigues', 'fr': 'Camaret-sur-Aigues'}, '3349036':{'en': 'Vaison-la-Romaine', 'fr': 'Vaison-la-Romaine'}, '3349035':{'en': u('Valr\u00e9as'), 'fr': u('Valr\u00e9as')}, '3349034':{'en': 'Orange', 'fr': 'Orange'}, '3349039':{'en': 'Sorgues', 'fr': 'Sorgues'}, '3349038':{'en': 'L\'Isle sur la Sorgue', 'fr': 'L\'Isle sur la Sorgue'}, '3751631':{'be': u('\u041a\u0430\u043c\u044f\u043d\u0435\u0446, \u0411\u0440\u044d\u0441\u0446\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Kamenets, Brest Region', 'ru': u('\u041a\u0430\u043c\u0435\u043d\u0435\u0446, \u0411\u0440\u0435\u0441\u0442\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751632':{'be': u('\u041f\u0440\u0443\u0436\u0430\u043d\u044b, \u0411\u0440\u044d\u0441\u0446\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Pruzhany, Brest Region', 'ru': u('\u041f\u0440\u0443\u0436\u0430\u043d\u044b, \u0411\u0440\u0435\u0441\u0442\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '46292':{'en': u('T\u00e4rnsj\u00f6-\u00d6sterv\u00e5la'), 'sv': u('T\u00e4rnsj\u00f6-\u00d6sterv\u00e5la')}, '46293':{'en': u('Tierp-S\u00f6derfors'), 'sv': u('Tierp-S\u00f6derfors')}, '46290':{'en': 'Hofors-Storvik', 'sv': 'Hofors-Storvik'}, '3751633':{'be': u('\u041b\u044f\u0445\u0430\u0432\u0456\u0447\u044b, \u0411\u0440\u044d\u0441\u0446\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Lyakhovichi, Brest Region', 'ru': u('\u041b\u044f\u0445\u043e\u0432\u0438\u0447\u0438, \u0411\u0440\u0435\u0441\u0442\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '46294':{'en': u('Karlholmsbruk-Sk\u00e4rplinge'), 'sv': u('Karlholmsbruk-Sk\u00e4rplinge')}, '46295':{'en': u('\u00d6rbyhus-Dannemora'), 'sv': u('\u00d6rbyhus-Dannemora')}, '4419640':{'en': 'Hornsea/Patrington'}, '3342777':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3349961':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3349963':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3349962':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3349964':{'en': 'Montpellier', 'fr': 'Montpellier'}, '390363':{'en': 'Bergamo', 'it': 'Treviglio'}, '390362':{'en': 'Cremona/Monza', 'it': 'Seregno'}, '390365':{'en': 'Brescia', 'it': u('Sal\u00f2')}, '390364':{'en': 'Brescia', 'it': 'Breno'}, '3597058':{'bg': u('\u0421\u0442\u043e\u0431'), 'en': 'Stob'}, '441335':{'en': 'Ashbourne'}, '441334':{'en': 'St Andrews'}, '441333':{'en': 'Peat Inn (Leven (Fife))'}, '441332':{'en': 'Derby'}, '441330':{'en': 'Banchory'}, '3522767':{'de': u('D\u00fcdelingen'), 'en': 'Dudelange', 'fr': 'Dudelange'}, '3597052':{'bg': u('\u041f\u0430\u0441\u0442\u0440\u0430'), 'en': 'Pastra'}, '3597053':{'bg': u('\u041a\u043e\u0447\u0435\u0440\u0438\u043d\u043e\u0432\u043e'), 'en': 'Kocherinovo'}, '3597054':{'bg': u('\u0420\u0438\u043b\u0430'), 'en': 'Rila'}, '3338246':{'en': 'Briey', 'fr': 'Briey'}, '3597056':{'bg': u('\u041c\u0443\u0440\u0441\u0430\u043b\u0435\u0432\u043e'), 'en': 'Mursalevo'}, '3597057':{'bg': u('\u041c\u0430\u043b\u043e \u0441\u0435\u043b\u043e'), 'en': 'Malo selo'}, '437237':{'de': 'Sankt Georgen an der Gusen', 'en': 'St. Georgen an der Gusen'}, '333272':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '3338858':{'en': u('S\u00e9lestat'), 'fr': u('S\u00e9lestat')}, '3323106':{'en': 'Caen', 'fr': 'Caen'}, '3332188':{'en': 'Saint-Omer', 'fr': 'Saint-Omer'}, '3338851':{'en': 'Brumath', 'fr': 'Brumath'}, '3752344':{'be': u('\u0411\u0440\u0430\u0433\u0456\u043d, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Bragin, Gomel Region', 'ru': u('\u0411\u0440\u0430\u0433\u0438\u043d, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3323109':{'en': 'Vire', 'fr': 'Vire'}, '3338852':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338855':{'en': 'Geispolsheim', 'fr': 'Geispolsheim'}, '3338854':{'en': 'Betschdorf', 'fr': 'Betschdorf'}, '3338856':{'en': 'Oberhausbergen', 'fr': 'Oberhausbergen'}, '44291':{'en': 'Cardiff'}, '3332099':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332098':{'en': u('Marcq-en-Bar\u0153ul'), 'fr': u('Marcq-en-Bar\u0153ul')}, '432768':{'de': 'Sankt Aegyd am Neuwalde', 'en': 'St. Aegyd am Neuwalde'}, '432769':{'de': u('T\u00fcrnitz'), 'en': u('T\u00fcrnitz')}, '3332093':{'en': 'Lille', 'fr': 'Lille'}, '3332092':{'en': 'Lomme', 'fr': 'Lomme'}, '3332091':{'en': 'Villeneuve-d\'Ascq', 'fr': 'Villeneuve-d\'Ascq'}, '3332090':{'en': 'Seclin', 'fr': 'Seclin'}, '432762':{'de': 'Lilienfeld', 'en': 'Lilienfeld'}, '432763':{'de': u('Sankt Veit an der G\u00f6lsen'), 'en': u('St. Veit an der G\u00f6lsen')}, '3332095':{'en': 'Wattignies', 'fr': 'Wattignies'}, '3332094':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '3354688':{'en': 'Rochefort', 'fr': 'Rochefort'}, '3354687':{'en': 'Rochefort', 'fr': 'Rochefort'}, '3354684':{'en': 'Fouras', 'fr': 'Fouras'}, '3354685':{'en': 'Marennes', 'fr': 'Marennes'}, '3354682':{'en': 'Rochefort', 'fr': 'Rochefort'}, '3355959':{'en': 'Bayonne', 'fr': 'Bayonne'}, '3355958':{'en': 'Anglet', 'fr': 'Anglet'}, '3355379':{'en': 'Tonneins', 'fr': 'Tonneins'}, '3355371':{'en': 'Fumel', 'fr': 'Fumel'}, '3355370':{'en': 'Villeneuve-sur-Lot', 'fr': 'Villeneuve-sur-Lot'}, '3355373':{'en': 'Bergerac', 'fr': 'Bergerac'}, '3355375':{'en': 'Montayral', 'fr': 'Montayral'}, '3323561':{'en': 'Bois-Guillaume', 'fr': 'Bois-Guillaume'}, '3355377':{'en': 'Agen', 'fr': 'Agen'}, '3329849':{'en': 'Brest', 'fr': 'Brest'}, '34969':{'en': 'Cuenca', 'es': 'Cuenca'}, '3355950':{'en': 'Bayonne', 'fr': 'Bayonne'}, '3354971':{'en': 'Parthenay', 'fr': 'Parthenay'}, '3354973':{'en': 'Niort', 'fr': 'Niort'}, '3354974':{'en': 'Bressuire', 'fr': 'Bressuire'}, '3329846':{'en': 'Brest', 'fr': 'Brest'}, '3354977':{'en': 'Niort', 'fr': 'Niort'}, '434782':{'de': 'Obervellach', 'en': 'Obervellach'}, '3359052':{'en': u('Saint Barth\u00e9l\u00e9my'), 'fr': u('Saint Barth\u00e9l\u00e9my')}, '3329847':{'en': 'Brest', 'fr': 'Brest'}, '434783':{'de': u('Rei\u00dfeck'), 'en': 'Reisseck'}, '3329840':{'en': 'Plougastel-Daoulas', 'fr': 'Plougastel-Daoulas'}, '3329842':{'en': 'Brest', 'fr': 'Brest'}, '3593538':{'bg': u('\u0415\u043b\u0448\u0438\u0446\u0430'), 'en': 'Elshitsa'}, '3593537':{'bg': u('\u041f\u0430\u043d\u0430\u0433\u044e\u0440\u0441\u043a\u0438 \u043a\u043e\u043b\u043e\u043d\u0438\u0438'), 'en': 'Panagyurski kolonii'}, '3593536':{'bg': u('\u0411\u0430\u043d\u044f, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Banya, Pazardzhik'}, '3593535':{'bg': u('\u041b\u0435\u0432\u0441\u043a\u0438, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Levski, Pazardzhik'}, '3593534':{'bg': u('\u041f\u043e\u043f\u0438\u043d\u0446\u0438'), 'en': 'Popintsi'}, '3593533':{'bg': u('\u0411\u044a\u0442\u0430'), 'en': 'Bata'}, '3593532':{'bg': u('\u0421\u0442\u0440\u0435\u043b\u0447\u0430'), 'en': 'Strelcha'}, '3593530':{'bg': u('\u041f\u043e\u0438\u0431\u0440\u0435\u043d\u0435'), 'en': 'Poibrene'}, '434784':{'de': 'Mallnitz', 'en': 'Mallnitz'}, '434785':{'de': u('Au\u00dferfragant'), 'en': 'Ausserfragant'}, '3329998':{'en': u('Louvign\u00e9-du-D\u00e9sert'), 'fr': u('Louvign\u00e9-du-D\u00e9sert')}, '3329999':{'en': u('Foug\u00e8res'), 'fr': u('Foug\u00e8res')}, '3355883':{'en': 'Biscarrosse', 'fr': 'Biscarrosse'}, '3355882':{'en': 'Biscarrosse', 'fr': 'Biscarrosse'}, '3329994':{'en': u('Foug\u00e8res'), 'fr': u('Foug\u00e8res')}, '3329992':{'en': 'Guignen', 'fr': 'Guignen'}, '3329993':{'en': 'Carentoir', 'fr': 'Carentoir'}, '3355885':{'en': 'Mont-de-Marsan', 'fr': 'Mont-de-Marsan'}, '3341320':{'en': 'Marseille', 'fr': 'Marseille'}, '3593759':{'bg': u('\u0411\u043e\u0440\u0438\u0441\u043b\u0430\u0432\u0446\u0438'), 'en': 'Borislavtsi'}, '3593758':{'bg': u('\u0419\u0435\u0440\u0443\u0441\u0430\u043b\u0438\u043c\u043e\u0432\u043e'), 'en': 'Yerusalimovo'}, '3593753':{'bg': u('\u041e\u0440\u044f\u0445\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Oryahovo, Hask.'}, '3593752':{'bg': u('\u041c\u0430\u043b\u043a\u043e \u0433\u0440\u0430\u0434\u0438\u0449\u0435'), 'en': 'Malko gradishte'}, '3593751':{'bg': u('\u041b\u044e\u0431\u0438\u043c\u0435\u0446'), 'en': 'Lyubimets'}, '3593757':{'bg': u('\u0413\u0435\u043e\u0440\u0433\u0438 \u0414\u043e\u0431\u0440\u0435\u0432\u043e'), 'en': 'Georgi Dobrevo'}, '3593756':{'bg': u('\u0412\u044a\u043b\u0447\u0435 \u043f\u043e\u043b\u0435'), 'en': 'Valche pole'}, '3593755':{'bg': u('\u0411\u0435\u043b\u0438\u0446\u0430, \u0425\u0430\u0441\u043a.'), 'en': 'Belitsa, Hask.'}, '3593754':{'bg': u('\u041b\u043e\u0437\u0435\u043d, \u0425\u0430\u0441\u043a.'), 'en': 'Lozen, Hask.'}, '3325397':{'en': 'Nantes', 'fr': 'Nantes'}, '3334494':{'en': u('Cr\u00e9py-en-Valois'), 'fr': u('Cr\u00e9py-en-Valois')}, '3334497':{'en': u('Compi\u00e8gne'), 'fr': u('Compi\u00e8gne')}, '3334496':{'en': 'Thourotte', 'fr': 'Thourotte'}, '3334491':{'en': 'La Croix-Saint-Ouen', 'fr': 'La Croix-Saint-Ouen'}, '3334490':{'en': u('Compi\u00e8gne'), 'fr': u('Compi\u00e8gne')}, '3334493':{'en': 'Noyon', 'fr': 'Noyon'}, '359478':{'bg': u('\u0415\u043b\u0445\u043e\u0432\u043e, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Elhovo, Yambol'}, '359470':{'bg': u('\u0422\u043e\u043f\u043e\u043b\u043e\u0432\u0433\u0440\u0430\u0434'), 'en': 'Topolovgrad'}, '441538':{'en': 'Ipstones'}, '441535':{'en': 'Keighley'}, '441534':{'en': 'Jersey'}, '441536':{'en': 'Kettering'}, '441531':{'en': 'Ledbury'}, '441530':{'en': 'Coalville'}, '3596956':{'bg': u('\u041b\u043e\u043c\u0435\u0446, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Lomets, Lovech'}, '3596957':{'bg': u('\u0413\u043e\u043b\u044f\u043c\u0430 \u0416\u0435\u043b\u044f\u0437\u043d\u0430'), 'en': 'Golyama Zhelyazna'}, '3596954':{'bg': u('\u0412\u0440\u0430\u0431\u0435\u0432\u043e'), 'en': 'Vrabevo'}, '3596955':{'bg': u('\u0414\u044a\u043b\u0431\u043e\u043a \u0434\u043e\u043b'), 'en': 'Dalbok dol'}, '3329942':{'en': u('Laill\u00e9'), 'fr': u('Laill\u00e9')}, '3596953':{'bg': u('\u0411\u043e\u0440\u0438\u043c\u0430'), 'en': 'Borima'}, '3596950':{'bg': u('\u0413\u0443\u043c\u043e\u0449\u043d\u0438\u043a'), 'en': 'Gumoshtnik'}, '3596958':{'bg': u('\u0410\u043f\u0440\u0438\u043b\u0446\u0438, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Apriltsi, Lovech'}, '3596959':{'bg': u('\u0414\u0435\u0431\u043d\u0435\u0432\u043e'), 'en': 'Debnevo'}, '35966':{'bg': u('\u0413\u0430\u0431\u0440\u043e\u0432\u043e'), 'en': 'Gabrovo'}, '35964':{'bg': u('\u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Pleven'}, '35962':{'bg': u('\u0412\u0435\u043b\u0438\u043a\u043e \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Veliko Tarnovo'}, '35968':{'bg': u('\u041b\u043e\u0432\u0435\u0447'), 'en': 'Lovech'}, '3595755':{'bg': u('\u041a\u043e\u043b\u0430\u0440\u0446\u0438'), 'en': 'Kolartsi'}, '3595754':{'bg': u('\u0417\u044a\u0440\u043d\u0435\u0432\u043e'), 'en': 'Zarnevo'}, '3347868':{'en': 'Villeurbanne', 'fr': 'Villeurbanne'}, '3347869':{'en': 'Lyon', 'fr': 'Lyon'}, '3595751':{'bg': u('\u0422\u0435\u0440\u0432\u0435\u043b, \u0414\u043e\u0431\u0440.'), 'en': 'Tervel, Dobr.'}, '3595750':{'bg': u('\u041a\u0430\u0431\u043b\u0435\u0448\u043a\u043e\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'Kableshkovo, Dobr.'}, '3347648':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347649':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347862':{'en': 'Lyon', 'fr': 'Lyon'}, '3347647':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347860':{'en': 'Lyon', 'fr': 'Lyon'}, '3347861':{'en': 'Lyon', 'fr': 'Lyon'}, '3347866':{'en': 'Dardilly', 'fr': 'Dardilly'}, '3347643':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347864':{'en': 'Lyon', 'fr': 'Lyon'}, '3347865':{'en': 'Lyon', 'fr': 'Lyon'}, '435576':{'de': 'Hohenems', 'en': 'Hohenems'}, '435577':{'de': 'Lustenau', 'en': 'Lustenau'}, '435574':{'de': 'Bregenz', 'en': 'Bregenz'}, '432633':{'de': 'Markt Piesting', 'en': 'Markt Piesting'}, '435572':{'de': 'Dornbirn', 'en': 'Dornbirn'}, '435573':{'de': u('H\u00f6rbranz'), 'en': u('H\u00f6rbranz')}, '373236':{'en': 'Ungheni', 'ro': 'Ungheni', 'ru': u('\u0423\u043d\u0433\u0435\u043d\u044c')}, '373237':{'en': 'Straseni', 'ro': u('Str\u0103\u015feni'), 'ru': u('\u0421\u0442\u0440\u044d\u0448\u0435\u043d\u044c')}, '373235':{'en': 'Orhei', 'ro': 'Orhei', 'ru': u('\u041e\u0440\u0445\u0435\u0439')}, '373230':{'en': 'Soroca', 'ro': 'Soroca', 'ru': u('\u0421\u043e\u0440\u043e\u043a\u0430')}, '373231':{'en': u('Bal\u0163i'), 'ro': u('B\u0103l\u0163i'), 'ru': u('\u0411\u044d\u043b\u0446\u044c')}, '3324049':{'en': 'Nantes', 'fr': 'Nantes'}, '3338038':{'en': 'Dijon', 'fr': 'Dijon'}, '3324043':{'en': 'Nantes', 'fr': 'Nantes'}, '3338032':{'en': 'Brazey-en-Plaine', 'fr': 'Brazey-en-Plaine'}, '3338031':{'en': 'Auxonne', 'fr': 'Auxonne'}, '3338030':{'en': 'Dijon', 'fr': 'Dijon'}, '3338037':{'en': 'Auxonne', 'fr': 'Auxonne'}, '3324046':{'en': 'Nantes', 'fr': 'Nantes'}, '3324045':{'en': 'Donges', 'fr': 'Donges'}, '3338034':{'en': 'Gevrey-Chambertin', 'fr': 'Gevrey-Chambertin'}, '3332453':{'en': 'Nouzonville', 'fr': 'Nouzonville'}, '3597178':{'bg': u('\u041f\u0440\u043e\u043b\u0435\u0448\u0430'), 'en': 'Prolesha'}, '3742667':{'am': u('\u0532\u0565\u0580\u0564\u0561\u057e\u0561\u0576'), 'en': 'Berdavan', 'ru': u('\u0411\u0435\u0440\u0434\u0430\u0432\u0430\u043d')}, '3742665':{'am': u('\u053f\u0578\u0572\u0562'), 'en': 'Koghb', 'ru': u('\u041a\u043e\u0445\u0431')}, '436274':{'de': 'Lamprechtshausen', 'en': 'Lamprechtshausen'}, '436276':{'de': u('Nu\u00dfdorf am Haunsberg'), 'en': 'Nussdorf am Haunsberg'}, '436277':{'de': 'Sankt Pantaleon', 'en': 'St. Pantaleon'}, '436272':{'de': 'Oberndorf bei Salzburg', 'en': 'Oberndorf bei Salzburg'}, '3332456':{'en': u('Charleville-M\u00e9zi\u00e8res'), 'fr': u('Charleville-M\u00e9zi\u00e8res')}, '334700':{'en': u('Montlu\u00e7on'), 'fr': u('Montlu\u00e7on')}, '3597533':{'bg': u('\u041e\u0441\u0438\u043a\u043e\u0432\u043e, \u0411\u043b\u0430\u0433.'), 'en': 'Osikovo, Blag.'}, '3597532':{'bg': u('\u0411\u0443\u043a\u043e\u0432\u043e, \u0411\u043b\u0430\u0433.'), 'en': 'Bukovo, Blag.'}, '3597531':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u0414\u0440\u044f\u043d\u043e\u0432\u043e'), 'en': 'Dolno Dryanovo'}, '3329679':{'en': 'Pordic', 'fr': 'Pordic'}, '3329678':{'en': 'Saint-Brieuc', 'fr': 'Saint-Brieuc'}, '3329673':{'en': 'Binic', 'fr': 'Binic'}, '3329672':{'en': 'Erquy', 'fr': 'Erquy'}, '3329671':{'en': u('Tr\u00e9gueux'), 'fr': u('Tr\u00e9gueux')}, '3329670':{'en': 'Saint-Quay-Portrieux', 'fr': 'Saint-Quay-Portrieux'}, '3329677':{'en': 'Saint-Brieuc', 'fr': 'Saint-Brieuc'}, '3329676':{'en': 'Ploufragan', 'fr': 'Ploufragan'}, '3329675':{'en': 'Saint-Brieuc', 'fr': 'Saint-Brieuc'}, '3329674':{'en': u('Pl\u00e9rin'), 'fr': u('Pl\u00e9rin')}, '3338449':{'en': 'Fougerolles', 'fr': 'Fougerolles'}, '3338442':{'en': 'Moirans-en-Montagne', 'fr': 'Moirans-en-Montagne'}, '3338443':{'en': 'Lons-le-Saunier', 'fr': 'Lons-le-Saunier'}, '3338440':{'en': 'Luxeuil-les-Bains', 'fr': 'Luxeuil-les-Bains'}, '3338446':{'en': u('H\u00e9ricourt'), 'fr': u('H\u00e9ricourt')}, '3338447':{'en': 'Lons-le-Saunier', 'fr': 'Lons-le-Saunier'}, '3338445':{'en': 'Saint-Claude', 'fr': 'Saint-Claude'}, '441580':{'en': 'Cranbrook'}, '35961107':{'bg': u('\u041c\u043e\u043c\u0438\u043d \u0441\u0431\u043e\u0440'), 'en': 'Momin sbor'}, '35961106':{'bg': u('\u041d\u043e\u0432\u043e \u0441\u0435\u043b\u043e, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Novo selo, V. Tarnovo'}, '35961105':{'bg': u('\u041f\u0440\u0438\u0441\u043e\u0432\u043e'), 'en': 'Prisovo'}, '35961104':{'bg': u('\u0412\u043e\u0434\u043e\u043b\u0435\u0439'), 'en': 'Vodoley'}, '35961103':{'bg': u('\u0420\u0443\u0441\u0430\u043b\u044f'), 'en': 'Rusalya'}, '35961102':{'bg': u('\u041f\u0447\u0435\u043b\u0438\u0449\u0435'), 'en': 'Pchelishte'}, '35961101':{'bg': u('\u0412\u0435\u043b\u0447\u0435\u0432\u043e, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Velchevo, V. Tarnovo'}, '3595522':{'bg': u('\u0418\u0441\u043a\u0440\u0430, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Iskra, Burgas'}, '35961109':{'bg': u('\u0412\u044a\u0433\u043b\u0435\u0432\u0446\u0438'), 'en': 'Vaglevtsi'}, '35961108':{'bg': u('\u041f\u043b\u0430\u043a\u043e\u0432\u043e'), 'en': 'Plakovo'}, '3596967':{'bg': u('\u041a\u0430\u043b\u0435\u0439\u0446\u0430'), 'en': 'Kaleytsa'}, '3347104':{'en': 'Le Puy en Velay', 'fr': 'Le Puy en Velay'}, '3347107':{'en': 'Le Puy-en-Velay', 'fr': 'Le Puy-en-Velay'}, '3596964':{'bg': u('\u0412\u0435\u043b\u0447\u0435\u0432\u043e, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Velchevo, Lovech'}, '3596963':{'bg': u('\u0411\u0430\u043b\u043a\u0430\u043d\u0435\u0446'), 'en': 'Balkanets'}, '3596962':{'bg': u('\u0427\u0435\u0440\u043d\u0438 \u041e\u0441\u044a\u043c'), 'en': 'Cherni Osam'}, '3347450':{'en': 'Vonnas', 'fr': 'Vonnas'}, '441583':{'en': 'Carradale'}, '3752132':{'be': u('\u041b\u0435\u043f\u0435\u043b\u044c'), 'en': 'Lepel', 'ru': u('\u041b\u0435\u043f\u0435\u043b\u044c')}, '3347677':{'en': u('Dom\u00e8ne'), 'fr': u('Dom\u00e8ne')}, '3752130':{'be': u('\u0428\u0443\u043c\u0456\u043b\u0456\u043d\u0430, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Shumilino, Vitebsk Region', 'ru': u('\u0428\u0443\u043c\u0438\u043b\u0438\u043d\u043e, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752131':{'be': u('\u0411\u0435\u0448\u0430\u043d\u043a\u043e\u0432\u0456\u0447\u044b, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Beshenkovichi, Vitebsk Region', 'ru': u('\u0411\u0435\u0448\u0435\u043d\u043a\u043e\u0432\u0438\u0447\u0438, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3341363':{'en': 'Marseille', 'fr': 'Marseille'}, '3752137':{'be': u('\u0414\u0443\u0431\u0440\u043e\u045e\u043d\u0430, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Dubrovno, Vitebsk Region', 'ru': u('\u0414\u0443\u0431\u0440\u043e\u0432\u043d\u043e, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752135':{'be': u('\u0421\u044f\u043d\u043d\u043e, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Senno, Vitebsk Region', 'ru': u('\u0421\u0435\u043d\u043d\u043e, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752138':{'be': u('\u041b\u0451\u0437\u043d\u0430, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Liozno, Vitebsk Region', 'ru': u('\u041b\u0438\u043e\u0437\u043d\u043e, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752139':{'be': u('\u0413\u0430\u0440\u0430\u0434\u043e\u043a, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Gorodok, Vitebsk Region', 'ru': u('\u0413\u043e\u0440\u043e\u0434\u043e\u043a, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3347675':{'en': u('Saint-Egr\u00e8ve'), 'fr': u('Saint-Egr\u00e8ve')}, '34820':{'en': u('\u00c1vila'), 'es': u('\u00c1vila')}, '3323731':{'en': 'Auneau', 'fr': 'Auneau'}, '34822':{'en': 'Tenerife', 'es': 'Tenerife'}, '34823':{'en': 'Salamanca', 'es': 'Salamanca'}, '3323734':{'en': 'Chartres', 'fr': 'Chartres'}, '3323735':{'en': 'Chartres', 'fr': 'Chartres'}, '3323736':{'en': 'Chartres', 'fr': 'Chartres'}, '3347672':{'en': 'Vif', 'fr': 'Vif'}, '3332153':{'en': u('Bruay-la-Buissi\u00e8re'), 'fr': u('Bruay-la-Buissi\u00e8re')}, '3347670':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3332156':{'en': u('B\u00e9thune'), 'fr': u('B\u00e9thune')}, '3332157':{'en': u('B\u00e9thune'), 'fr': u('B\u00e9thune')}, '3332154':{'en': 'Lillers', 'fr': 'Lillers'}, '441290':{'en': 'Cumnock'}, '441291':{'en': 'Chepstow'}, '441292':{'en': 'Ayr'}, '441293':{'en': 'Crawley'}, '441294':{'en': 'Ardrossan'}, '441295':{'en': 'Banbury'}, '441296':{'en': 'Aylesbury'}, '441297':{'en': 'Axminster'}, '441298':{'en': 'Buxton'}, '3354764':{'en': 'Anglet', 'fr': 'Anglet'}, '3349572':{'en': 'Porto-Vecchio', 'fr': 'Porto-Vecchio'}, '3349573':{'en': 'Bonifacio', 'fr': 'Bonifacio'}, '3349570':{'en': 'Porto-Vecchio', 'fr': 'Porto-Vecchio'}, '3349576':{'en': 'Propriano', 'fr': 'Propriano'}, '3349577':{'en': u('Sart\u00e8ne'), 'fr': u('Sart\u00e8ne')}, '3345017':{'en': 'Thonon-les-Bains', 'fr': 'Thonon-les-Bains'}, '3345019':{'en': u('S\u00e9vrier'), 'fr': u('S\u00e9vrier')}, '3349578':{'en': 'Levie', 'fr': 'Levie'}, '35951103':{'bg': u('\u041b\u044e\u0431\u0435\u043d \u041a\u0430\u0440\u0430\u0432\u0435\u043b\u043e\u0432\u043e'), 'en': 'Lyuben Karavelovo'}, '441239':{'en': 'Cardigan'}, '3348999':{'en': u('Fr\u00e9jus'), 'fr': u('Fr\u00e9jus')}, '3348996':{'en': 'Toulon', 'fr': 'Toulon'}, '3348992':{'en': 'Nice', 'fr': 'Nice'}, '441235':{'en': 'Abingdon'}, '3325490':{'en': 'Blois', 'fr': 'Blois'}, '3325497':{'en': 'Salbris', 'fr': 'Salbris'}, '433359':{'de': 'Loipersdorf-Kitzladen', 'en': 'Loipersdorf-Kitzladen'}, '3325495':{'en': 'Romorantin-Lanthenay', 'fr': 'Romorantin-Lanthenay'}, '433354':{'de': 'Bernstein', 'en': 'Bernstein'}, '433355':{'de': 'Stadtschlaining', 'en': 'Stadtschlaining'}, '433356':{'de': 'Markt Allhau', 'en': 'Markt Allhau'}, '433357':{'de': 'Pinkafeld', 'en': 'Pinkafeld'}, '433352':{'de': 'Oberwart', 'en': 'Oberwart'}, '433353':{'de': u('Obersch\u00fctzen'), 'en': u('Obersch\u00fctzen')}, '35936402':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u043a\u0443\u043b\u0430'), 'en': 'Gorna kula'}, '3324014':{'en': 'Nantes', 'fr': 'Nantes'}, '3324720':{'en': 'Tours', 'fr': 'Tours'}, '35936401':{'bg': u('\u0421\u0442\u0440\u0430\u043d\u0434\u0436\u0435\u0432\u043e'), 'en': 'Strandzhevo'}, '3324727':{'en': 'Saint-Avertin', 'fr': 'Saint-Avertin'}, '3338065':{'en': 'Dijon', 'fr': 'Dijon'}, '435213':{'de': 'Scharnitz', 'en': 'Scharnitz'}, '435212':{'de': 'Seefeld in Tirol', 'en': 'Seefeld in Tirol'}, '3324728':{'en': u('Chambray-l\u00e8s-Tours'), 'fr': u('Chambray-l\u00e8s-Tours')}, '3324016':{'en': 'Nantes', 'fr': 'Nantes'}, '435214':{'de': 'Leutasch', 'en': 'Leutasch'}, '35995276':{'bg': u('\u0414\u0440\u0430\u0433\u0430\u043d\u0438\u0446\u0430'), 'en': 'Draganitsa'}, '3356199':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3338067':{'en': 'Dijon', 'fr': 'Dijon'}, '3346674':{'en': 'Milhaud', 'fr': 'Milhaud'}, '3356192':{'en': 'Cugnaux', 'fr': 'Cugnaux'}, '3356195':{'en': 'Saint-Gaudens', 'fr': 'Saint-Gaudens'}, '3356197':{'en': u('Caz\u00e8res'), 'fr': u('Caz\u00e8res')}, '359866':{'bg': u('\u0422\u0443\u0442\u0440\u0430\u043a\u0430\u043d'), 'en': 'Tutrakan'}, '359864':{'bg': u('\u0414\u0443\u043b\u043e\u0432\u043e'), 'en': 'Dulovo'}, '3346676':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3338063':{'en': 'Dijon', 'fr': 'Dijon'}, '35974204':{'bg': u('\u0413\u0435\u0433\u0430'), 'en': 'Gega'}, '35974202':{'bg': u('\u041a\u043b\u044e\u0447'), 'en': 'Klyuch'}, '35974203':{'bg': u('\u0420\u0443\u043f\u0438\u0442\u0435'), 'en': 'Rupite'}, '3356334':{'en': 'Graulhet', 'fr': 'Graulhet'}, '3356335':{'en': 'Castres', 'fr': 'Castres'}, '3356336':{'en': 'Carmaux', 'fr': 'Carmaux'}, '3356337':{'en': 'Lacaune', 'fr': 'Lacaune'}, '3356332':{'en': 'Castelsarrasin', 'fr': 'Castelsarrasin'}, '3338068':{'en': 'Dijon', 'fr': 'Dijon'}, '35974201':{'bg': u('\u041a\u0430\u043f\u0430\u0442\u043e\u0432\u043e'), 'en': 'Kapatovo'}, '3356338':{'en': 'Albi', 'fr': 'Albi'}, '3356339':{'en': 'Valence', 'fr': 'Valence'}, '3347412':{'en': 'Oyonnax', 'fr': 'Oyonnax'}, '3347411':{'en': 'Salaise-sur-Sanne', 'fr': 'Salaise-sur-Sanne'}, '3347416':{'en': 'Vienne', 'fr': 'Vienne'}, '3347414':{'en': 'Bourg-en-Bresse', 'fr': 'Bourg-en-Bresse'}, '3347419':{'en': 'Bourgoin-Jallieu', 'fr': 'Bourgoin-Jallieu'}, '35971506':{'bg': u('\u0413\u0430\u0431\u0440\u0430'), 'en': 'Gabra'}, '35971504':{'bg': u('\u0411\u0435\u043b\u043e\u043f\u043e\u043f\u0446\u0438'), 'en': 'Belopoptsi'}, '35971505':{'bg': u('\u0427\u0443\u0440\u0435\u043a'), 'en': 'Churek'}, '35971502':{'bg': u('\u0415\u043b\u0435\u0448\u043d\u0438\u0446\u0430, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Eleshnitsa, Sofia'}, '35971503':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u041a\u0430\u043c\u0430\u0440\u0446\u0438'), 'en': 'Dolno Kamartsi'}, '35225':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '35224':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '35555':{'en': u('Kavaj\u00eb')}, '35554':{'en': 'Elbasan'}, '35553':{'en': u('La\u00e7, Kurbin')}, '35552':{'en': u('Durr\u00ebs')}, '35223':{'de': 'Bad Mondorf', 'en': 'Mondorf-les-Bains', 'fr': 'Mondorf-les-Bains'}, '35222':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '3596030':{'bg': u('\u0421\u0432\u0435\u0442\u043b\u0435\u043d, \u0422\u044a\u0440\u0433.'), 'en': 'Svetlen, Targ.'}, '3596033':{'bg': u('\u041c\u0435\u0434\u043e\u0432\u0438\u043d\u0430'), 'en': 'Medovina'}, '3596032':{'bg': u('\u0417\u0430\u0440\u0430\u0435\u0432\u043e'), 'en': 'Zaraevo'}, '35229':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '35228':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '3596036':{'bg': u('\u0421\u0430\u0434\u0438\u043d\u0430'), 'en': 'Sadina'}, '359391':{'bg': u('\u0414\u0438\u043c\u0438\u0442\u0440\u043e\u0432\u0433\u0440\u0430\u0434'), 'en': 'Dimitrovgrad'}, '3329806':{'en': u('Riec-sur-B\u00e9lon'), 'fr': u('Riec-sur-B\u00e9lon')}, '437949':{'de': u('Rainbach im M\u00fchlkreis'), 'en': u('Rainbach im M\u00fchlkreis')}, '436226':{'de': 'Fuschl am See', 'en': 'Fuschl am See'}, '436224':{'de': 'Hintersee', 'en': 'Hintersee'}, '441760':{'en': 'Swaffham'}, '441761':{'en': 'Temple Cloud'}, '441763':{'en': 'Royston'}, '441764':{'en': 'Crieff'}, '441765':{'en': 'Ripon'}, '441766':{'en': 'Porthmadog'}, '441767':{'en': 'Sandy'}, '441769':{'en': 'South Molton'}, '3316479':{'en': 'Dammarie-les-Lys', 'fr': 'Dammarie-les-Lys'}, '3316478':{'en': 'Nemours', 'fr': 'Nemours'}, '3316477':{'en': 'Bussy-Saint-Georges', 'fr': 'Bussy-Saint-Georges'}, '3316476':{'en': 'Bussy-Saint-Georges', 'fr': 'Bussy-Saint-Georges'}, '3316475':{'en': 'Coulommiers', 'fr': 'Coulommiers'}, '3316472':{'en': 'Chelles', 'fr': 'Chelles'}, '3316471':{'en': 'Melun', 'fr': 'Melun'}, '3316470':{'en': 'Montereau-Fault-Yonne', 'fr': 'Montereau-Fault-Yonne'}, '435245':{'de': u('Hinterri\u00df'), 'en': 'Hinterriss'}, '3349018':{'en': 'Arles', 'fr': 'Arles'}, '3349014':{'en': 'Avignon', 'fr': 'Avignon'}, '3349017':{'en': 'Miramas', 'fr': 'Miramas'}, '3349016':{'en': 'Avignon', 'fr': 'Avignon'}, '3349011':{'en': 'Orange', 'fr': 'Orange'}, '3349013':{'en': 'Avignon', 'fr': 'Avignon'}, '35969613':{'bg': u('\u0427\u0438\u0444\u043b\u0438\u043a, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Chiflik, Lovech'}, '35969612':{'bg': u('\u0422\u0435\u0440\u0437\u0438\u0439\u0441\u043a\u043e, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Terziysko, Lovech'}, '3332065':{'en': u('Marcq-en-Bar\u0153ul'), 'fr': u('Marcq-en-Bar\u0153ul')}, '35969616':{'bg': u('\u0421\u0442\u0430\u0440\u043e \u0441\u0435\u043b\u043e, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Staro selo, Lovech'}, '35969615':{'bg': u('\u0411\u0430\u043b\u0430\u0431\u0430\u043d\u0441\u043a\u043e'), 'en': 'Balabansko'}, '35969614':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u0442\u0440\u0430\u043f\u0435'), 'en': 'Gorno trape'}, '436228':{'de': 'Faistenau', 'en': 'Faistenau'}, '35931387':{'bg': u('\u041f\u0440\u043e\u043b\u043e\u043c'), 'en': 'Prolom'}, '3349451':{'en': u('Fr\u00e9jus'), 'fr': u('Fr\u00e9jus')}, '35931388':{'bg': u('\u0411\u0435\u0433\u0443\u043d\u0446\u0438'), 'en': 'Beguntsi'}, '3598663':{'bg': u('\u0421\u0438\u0442\u043e\u0432\u043e, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Sitovo, Silistra'}, '3349902':{'en': u('S\u00e8te'), 'fr': u('S\u00e8te')}, '3349906':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3349904':{'en': u('S\u00e8te'), 'fr': u('S\u00e8te')}, '441350':{'en': 'Dunkeld'}, '441353':{'en': 'Ely'}, '441352':{'en': 'Mold'}, '441355':{'en': 'East Kilbride'}, '3332068':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '441357':{'en': 'Strathaven'}, '441356':{'en': 'Brechin'}, '441359':{'en': 'Pakenham'}, '441358':{'en': 'Ellon'}, '3332069':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '3338833':{'en': 'Schiltigheim', 'fr': 'Schiltigheim'}, '3338832':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338831':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338830':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338837':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338836':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338835':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338834':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338839':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338838':{'en': 'Molsheim', 'fr': 'Molsheim'}, '3338789':{'en': u('Far\u00e9bersviller'), 'fr': u('Far\u00e9bersviller')}, '3338788':{'en': 'Forbach', 'fr': 'Forbach'}, '334918':{'en': 'Marseille', 'fr': 'Marseille'}, '334919':{'en': 'Marseille', 'fr': 'Marseille'}, '3323129':{'en': 'Caen', 'fr': 'Caen'}, '3323128':{'en': 'Houlgate', 'fr': 'Houlgate'}, '3334458':{'en': 'Chantilly', 'fr': 'Chantilly'}, '334912':{'en': 'Marseille', 'fr': 'Marseille'}, '334913':{'en': 'Marseille', 'fr': 'Marseille'}, '3323127':{'en': 'Caen', 'fr': 'Caen'}, '334911':{'en': 'Marseille', 'fr': 'Marseille'}, '334917':{'en': 'Marseille', 'fr': 'Marseille'}, '334914':{'en': 'Marseille', 'fr': 'Marseille'}, '334915':{'en': 'Marseille', 'fr': 'Marseille'}, '432748':{'de': 'Kilb', 'en': 'Kilb'}, '432749':{'de': 'Prinzersdorf', 'en': 'Prinzersdorf'}, '3598669':{'bg': u('\u0413\u0430\u0440\u0432\u0430\u043d, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Garvan, Silistra'}, '35951108':{'bg': u('\u0418\u0437\u0432\u043e\u0440\u0441\u043a\u043e'), 'en': 'Izvorsko'}, '432741':{'de': 'Flinsbach', 'en': 'Flinsbach'}, '432742':{'de': u('Sankt P\u00f6lten'), 'en': u('St. P\u00f6lten')}, '432743':{'de': u('B\u00f6heimkirchen'), 'en': u('B\u00f6heimkirchen')}, '432744':{'de': u('Kasten bei B\u00f6heimkirchen'), 'en': u('Kasten bei B\u00f6heimkirchen')}, '432745':{'de': 'Pyhra', 'en': 'Pyhra'}, '432746':{'de': 'Wilhelmsburg', 'en': 'Wilhelmsburg'}, '432747':{'de': 'Ober-Grafendorf', 'en': 'Ober-Grafendorf'}, '432713':{'de': 'Spitz', 'en': 'Spitz'}, '432712':{'de': 'Aggsbach', 'en': 'Aggsbach'}, '432711':{'de': u('D\u00fcrnstein'), 'en': u('D\u00fcrnstein')}, '3355313':{'en': u('P\u00e9rigueux'), 'fr': u('P\u00e9rigueux')}, '44203':{'en': 'London'}, '3323389':{'en': 'Avranches', 'fr': 'Avranches'}, '3323388':{'en': 'Cherbourg-Octeville', 'fr': 'Cherbourg-Octeville'}, '390835':{'it': 'Matera'}, '390833':{'it': 'Gallipoli'}, '390832':{'en': 'Lecce', 'it': 'Lecce'}, '390831':{'it': 'Brindisi'}, '3323381':{'en': u('Alen\u00e7on'), 'fr': u('Alen\u00e7on')}, '3323380':{'en': u('Alen\u00e7on'), 'fr': u('Alen\u00e7on')}, '3323382':{'en': u('Alen\u00e7on'), 'fr': u('Alen\u00e7on')}, '3323385':{'en': 'Mortagne-au-Perche', 'fr': 'Mortagne-au-Perche'}, '3323384':{'en': 'L\'Aigle', 'fr': 'L\'Aigle'}, '3323387':{'en': 'Cherbourg-Octeville', 'fr': 'Cherbourg-Octeville'}, '441974':{'en': 'Llanon'}, '441977':{'en': 'Pontefract'}, '441971':{'en': 'Scourie'}, '441970':{'en': 'Aberystwyth'}, '441972':{'en': 'Glenborrodale'}, '441978':{'en': 'Wrexham'}, '35967774':{'bg': u('\u0411\u0435\u043b\u0438\u0446\u0430, \u0413\u0430\u0431\u0440.'), 'en': 'Belitsa, Gabr.'}, '437764':{'de': 'Riedau', 'en': 'Riedau'}, '35930528':{'bg': u('\u041c\u0430\u043d\u0430\u0441\u0442\u0438\u0440, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Manastir, Plovdiv'}, '437767':{'de': 'Eggerding', 'en': 'Eggerding'}, '437766':{'de': 'Andorf', 'en': 'Andorf'}, '3593519':{'bg': u('\u0412\u0435\u043b\u0438\u0447\u043a\u043e\u0432\u043e, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Velichkovo, Pazardzhik'}, '3593518':{'bg': u('\u0414\u0440\u0430\u0433\u043e\u0440'), 'en': 'Dragor'}, '3332527':{'en': 'Bar-sur-Aube', 'fr': 'Bar-sur-Aube'}, '3332525':{'en': 'Romilly-sur-Seine', 'fr': 'Romilly-sur-Seine'}, '3332524':{'en': 'Romilly-sur-Seine', 'fr': 'Romilly-sur-Seine'}, '3593511':{'bg': u('\u041e\u0433\u043d\u044f\u043d\u043e\u0432\u043e, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Ognyanovo, Pazardzhik'}, '3593510':{'bg': u('\u041e\u0432\u0447\u0435\u043f\u043e\u043b\u0446\u0438'), 'en': 'Ovchepoltsi'}, '3593513':{'bg': u('\u041c\u0430\u043b\u043e \u041a\u043e\u043d\u0430\u0440\u0435'), 'en': 'Malo Konare'}, '3593512':{'bg': u('\u0425\u0430\u0434\u0436\u0438\u0435\u0432\u043e'), 'en': 'Hadzhievo'}, '3593515':{'bg': u('\u041a\u0430\u043b\u0443\u0433\u0435\u0440\u043e\u0432\u043e, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Kalugerovo, Pazardzhik'}, '3593514':{'bg': u('\u0427\u0435\u0440\u043d\u043e\u0433\u043e\u0440\u043e\u0432\u043e, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Chernogorovo, Pazardzhik'}, '3593517':{'bg': u('\u041b\u0435\u0441\u0438\u0447\u043e\u0432\u043e'), 'en': 'Lesichovo'}, '3593516':{'bg': u('\u0426\u0440\u044a\u043d\u0447\u0430, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Tsrancha, Pazardzhik'}, '37423486':{'am': u('\u0548\u0582\u0580\u0581\u0561\u0571\u0578\u0580'), 'en': 'Urtsadzor', 'ru': u('\u0423\u0440\u0446\u0430\u0434\u0437\u043e\u0440')}, '37423481':{'am': u('\u0531\u0575\u0563\u0561\u057e\u0561\u0576'), 'en': 'Aygavan', 'ru': u('\u0410\u0439\u0433\u0430\u0432\u0430\u043d')}, '3595913':{'bg': u('\u041a\u0440\u0443\u0448\u0435\u0432\u0435\u0446'), 'en': 'Krushevets'}, '3595912':{'bg': u('\u041f\u043e\u043b\u0441\u043a\u0438 \u0438\u0437\u0432\u043e\u0440'), 'en': 'Polski izvor'}, '3595910':{'bg': u('\u0427\u0435\u0440\u043d\u0438 \u0432\u0440\u044a\u0445, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Cherni vrah, Burgas'}, '3595917':{'bg': u('\u0418\u0437\u0432\u043e\u0440, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Izvor, Burgas'}, '3595916':{'bg': u('\u0420\u043e\u0441\u0435\u043d, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Rosen, Burgas'}, '3595915':{'bg': u('\u0411\u044a\u043b\u0433\u0430\u0440\u043e\u0432\u043e'), 'en': 'Balgarovo'}, '3595914':{'bg': u('\u0410\u0442\u0438\u044f'), 'en': 'Atia'}, '3595919':{'bg': u('\u041c\u0430\u0440\u0438\u043d\u043a\u0430'), 'en': 'Marinka'}, '3595918':{'bg': u('\u0420\u0443\u0441\u043e\u043a\u0430\u0441\u0442\u0440\u043e'), 'en': 'Rusokastro'}, '3593775':{'bg': u('\u0413\u0435\u043d\u0435\u0440\u0430\u043b\u043e\u0432\u043e'), 'en': 'Generalovo'}, '3593774':{'bg': u('\u041b\u0435\u0432\u043a\u0430'), 'en': 'Levka'}, '3593777':{'bg': u('\u041c\u0435\u0437\u0435\u043a'), 'en': 'Mezek'}, '3593776':{'bg': u('\u0420\u0430\u0439\u043a\u043e\u0432\u0430 \u043c\u043e\u0433\u0438\u043b\u0430'), 'en': 'Raykova mogila'}, '3593773':{'bg': u('\u041a\u0430\u043f\u0438\u0442\u0430\u043d \u0410\u043d\u0434\u0440\u0435\u0435\u0432\u043e'), 'en': 'Kapitan Andreevo'}, '3593772':{'bg': u('\u041c\u043e\u043c\u043a\u043e\u0432\u043e'), 'en': 'Momkovo'}, '37428151':{'am': u('\u053d\u0561\u0579\u056b\u056f'), 'en': 'Khachik', 'ru': u('\u0425\u0430\u0447\u0438\u043a')}, '3593779':{'bg': u('\u0421\u0438\u0432\u0430 \u0440\u0435\u043a\u0430'), 'en': 'Siva reka'}, '3593778':{'bg': u('\u0421\u0442\u0443\u0434\u0435\u043d\u0430, \u0425\u0430\u0441\u043a.'), 'en': 'Studena, Hask.'}, '3341307':{'en': 'Carpentras', 'fr': 'Carpentras'}, '35961397':{'bg': u('\u041c\u0443\u0441\u0438\u043d\u0430'), 'en': 'Musina'}, '434350':{'de': 'Bad Sankt Leonhard im Lavanttal', 'en': 'Bad St. Leonhard im Lavanttal'}, '434353':{'de': 'Prebl', 'en': 'Prebl'}, '434352':{'de': 'Wolfsberg', 'en': 'Wolfsberg'}, '434355':{'de': 'Gemmersdorf', 'en': 'Gemmersdorf'}, '434354':{'de': 'Preitenegg', 'en': 'Preitenegg'}, '434357':{'de': 'Sankt Paul im Lavanttal', 'en': 'St. Paul im Lavanttal'}, '434356':{'de': u('Lavam\u00fcnd'), 'en': u('Lavam\u00fcnd')}, '434359':{'de': 'Reichenfels', 'en': 'Reichenfels'}, '434358':{'de': u('Sankt Andr\u00e4'), 'en': u('St. Andr\u00e4')}, '35941338':{'bg': u('\u0426\u0435\u043b\u0438\u043d\u0430'), 'en': 'Tselina'}, '3329900':{'en': u('Ch\u00e2teaubourg'), 'fr': u('Ch\u00e2teaubourg')}, '35941336':{'bg': u('\u042f\u0437\u0434\u0430\u0447'), 'en': 'Yazdach'}, '35941337':{'bg': u('\u0421\u044a\u0440\u043d\u0435\u0432\u0435\u0446'), 'en': 'Sarnevets'}, '35941334':{'bg': u('\u0421\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Saedinenie, St. Zagora'}, '35941335':{'bg': u('\u041c\u043e\u0433\u0438\u043b\u043e\u0432\u043e'), 'en': 'Mogilovo'}, '35941332':{'bg': u('\u041d\u0430\u0439\u0434\u0435\u043d\u043e\u0432\u043e'), 'en': 'Naydenovo'}, '35941333':{'bg': u('\u0421\u0440\u0435\u0434\u043d\u043e \u0433\u0440\u0430\u0434\u0438\u0449\u0435'), 'en': 'Sredno gradishte'}, '35941330':{'bg': u('\u0426\u0435\u043d\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Tsenovo, St. Zagora'}, '35941331':{'bg': u('\u0413\u0440\u0430\u043d\u0438\u0442'), 'en': 'Granit'}, '35951429':{'bg': u('\u0421\u043e\u043b\u043d\u0438\u043a'), 'en': 'Solnik'}, '35951428':{'bg': u('\u0413\u043e\u0441\u043f\u043e\u0434\u0438\u043d\u043e\u0432\u043e, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Gospodinovo, Varna'}, '3329906':{'en': 'Montauban-de-Bretagne', 'fr': 'Montauban-de-Bretagne'}, '4419756':{'en': 'Strathdon'}, '4418904':{'en': 'Coldstream'}, '355588':{'en': u('Rras\u00eb/Fierz\u00eb/Kajan/Grekan, Elbasan')}, '355589':{'en': u('Karin\u00eb/Gjocaj/Shez\u00eb, Peqin')}, '3596932':{'bg': u('\u041c\u0438\u043a\u0440\u0435'), 'en': 'Mikre'}, '3596933':{'bg': u('\u0413\u043e\u043b\u0435\u0446'), 'en': 'Golets'}, '3596934':{'bg': u('\u041a\u0430\u0442\u0443\u043d\u0435\u0446'), 'en': 'Katunets'}, '3332396':{'en': u('Villers-Cotter\u00eats'), 'fr': u('Villers-Cotter\u00eats')}, '3596937':{'bg': u('\u0421\u043e\u043a\u043e\u043b\u043e\u0432\u043e, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Sokolovo, Lovech'}, '355580':{'en': u('P\u00ebrparim/Pajov\u00eb, Peqin')}, '355581':{'en': u('C\u00ebrrik, Elbasan')}, '355582':{'en': 'Belsh, Elbasan'}, '355583':{'en': 'Bradashesh/Shirgjan, Elbasan'}, '355584':{'en': u('Labinot-Fush\u00eb/Labinot-Mal/Funar\u00eb/Gracen, Elbasan')}, '355585':{'en': u('Shushic\u00eb/Tregan/Gjinar/Zavalin\u00eb, Elbasan')}, '355586':{'en': u('Gjergjan/Pap\u00ebr/Shal\u00ebs, Elbasan')}, '355587':{'en': 'Gostime/Klos/Mollas, Elbasan'}, '4418903':{'en': 'Coldstream'}, '335345':{'en': 'Toulouse', 'fr': 'Toulouse'}, '335346':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3346649':{'en': 'Mende', 'fr': 'Mende'}, '35944':{'bg': u('\u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Sliven'}, '35946':{'bg': u('\u042f\u043c\u0431\u043e\u043b'), 'en': 'Yambol'}, '35942':{'bg': u('\u0421\u0442\u0430\u0440\u0430 \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Stara Zagora'}, '3338476':{'en': 'Vesoul', 'fr': 'Vesoul'}, '3347629':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347621':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347622':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347623':{'en': u('\u00c9chirolles'), 'fr': u('\u00c9chirolles')}, '3347624':{'en': 'Eybens', 'fr': 'Eybens'}, '3347625':{'en': u('Saint-Martin-d\'H\u00e8res'), 'fr': u('Saint-Martin-d\'H\u00e8res')}, '3347626':{'en': 'Fontaine', 'fr': 'Fontaine'}, '3347627':{'en': 'Fontaine', 'fr': 'Fontaine'}, '3324065':{'en': 'Bouguenais', 'fr': 'Bouguenais'}, '373219':{'en': 'Dnestrovsk', 'ro': 'Dnestrovsk', 'ru': u('\u0414\u043d\u0435\u0441\u0442\u0440\u043e\u0432\u0441\u043a')}, '435552':{'de': 'Bludenz', 'en': 'Bludenz'}, '3324066':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '3324061':{'en': 'Pornichet', 'fr': 'Pornichet'}, '3324060':{'en': 'La Baule Escoublac', 'fr': 'La Baule Escoublac'}, '3324063':{'en': 'Orvault', 'fr': 'Orvault'}, '3324062':{'en': u('Gu\u00e9rande'), 'fr': u('Gu\u00e9rande')}, '373210':{'en': 'Grigoriopol', 'ro': 'Grigoriopol', 'ru': u('\u0413\u0440\u0438\u0433\u043e\u0440\u0438\u043e\u043f\u043e\u043b\u044c')}, '435559':{'de': 'Brand', 'en': 'Brand'}, '3324069':{'en': 'Nantes', 'fr': 'Nantes'}, '3324068':{'en': 'Carquefou', 'fr': 'Carquefou'}, '373216':{'en': 'Camenca', 'ro': 'Camenca', 'ru': u('\u041a\u0430\u043c\u0435\u043d\u043a\u0430')}, '4418901':{'en': 'Coldstream/Ayton'}, '35991203':{'bg': u('\u041b\u0438\u043a'), 'en': 'Lik'}, '35991202':{'bg': u('\u041a\u0443\u043d\u0438\u043d\u043e'), 'en': 'Kunino'}, '35991201':{'bg': u('\u041b\u044e\u0442\u0438 \u0431\u0440\u043e\u0434'), 'en': 'Lyuti brod'}, '4418477':{'en': 'Tongue'}, '4418900':{'en': 'Coldstream/Ayton'}, '4418476':{'en': 'Tongue'}, '3355514':{'en': 'Limoges', 'fr': 'Limoges'}, '441909':{'en': 'Worksop'}, '3347336':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3347337':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3347334':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3347335':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3347333':{'en': 'Volvic', 'fr': 'Volvic'}, '3347330':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3347331':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3347338':{'en': 'Riom', 'fr': 'Riom'}, '35984721':{'bg': u('\u041b\u0438\u043f\u043d\u0438\u043a'), 'en': 'Lipnik'}, '3342216':{'en': 'Nice', 'fr': 'Nice'}, '3342210':{'en': 'Cannes', 'fr': 'Cannes'}, '442897':{'en': 'Saintfield'}, '442896':{'en': 'Belfast'}, '442895':{'en': 'Belfast'}, '442894':{'en': 'Antrim'}, '442893':{'en': 'Ballyclare'}, '442892':{'en': 'Lisburn'}, '442891':{'en': 'Bangor (Co. Down)'}, '442890':{'en': 'Belfast'}, '442898':{'en': 'Belfast'}, '3329655':{'en': 'Paimpol', 'fr': 'Paimpol'}, '3329654':{'en': u('Plestin-les-Gr\u00e8ves'), 'fr': u('Plestin-les-Gr\u00e8ves')}, '3329656':{'en': 'Illifaut', 'fr': 'Illifaut'}, '3329650':{'en': 'Lamballe', 'fr': 'Lamballe'}, '3329652':{'en': 'Langueux', 'fr': 'Langueux'}, '3329658':{'en': u('Pl\u00e9rin'), 'fr': u('Pl\u00e9rin')}, '35961608':{'bg': u('\u0413\u043e\u0440\u0441\u043a\u0438 \u0421\u0435\u043d\u043e\u0432\u0435\u0446'), 'en': 'Gorski Senovets'}, '3323246':{'en': 'Bernay', 'fr': 'Bernay'}, '3323247':{'en': 'Bernay', 'fr': 'Bernay'}, '3323240':{'en': 'Louviers', 'fr': 'Louviers'}, '3323241':{'en': 'Pont-Audemer', 'fr': 'Pont-Audemer'}, '3323243':{'en': 'Bernay', 'fr': 'Bernay'}, '3323718':{'en': 'Chartres', 'fr': 'Chartres'}, '390342':{'en': 'Sondrio', 'it': 'Sondrio'}, '3349943':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '390444':{'en': 'Vicenza', 'it': 'Vicenza'}, '390445':{'en': 'Vicenza', 'it': 'Schio'}, '390442':{'it': 'Legnago'}, '433832':{'de': 'Kraubath an der Mur', 'en': 'Kraubath an der Mur'}, '390344':{'en': 'Como', 'it': 'Menaggio'}, '390346':{'en': 'Bergamo', 'it': 'Clusone'}, '3595137':{'bg': u('\u041a\u0430\u043b\u043e\u044f\u043d'), 'en': 'Kaloyan'}, '3595136':{'bg': u('\u0411\u0440\u0435\u0441\u0442\u0430\u043a'), 'en': 'Brestak'}, '35961605':{'bg': u('\u041d\u043e\u0432\u043e \u0433\u0440\u0430\u0434\u0438\u0449\u0435'), 'en': 'Novo gradishte'}, '3345079':{'en': 'Morzine', 'fr': 'Morzine'}, '3345078':{'en': 'Passy', 'fr': 'Passy'}, '35951127':{'bg': u('\u0420\u0430\u0437\u0434\u0435\u043b\u043d\u0430, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Razdelna, Varna'}, '3347243':{'en': 'Villeurbanne', 'fr': 'Villeurbanne'}, '3345073':{'en': u('Ch\u00e2tel'), 'fr': u('Ch\u00e2tel')}, '3345072':{'en': 'Sciez', 'fr': 'Sciez'}, '3345071':{'en': 'Thonon-les-Bains', 'fr': 'Thonon-les-Bains'}, '3345070':{'en': 'Thonon-les-Bains', 'fr': 'Thonon-les-Bains'}, '3345076':{'en': 'Lugrin', 'fr': 'Lugrin'}, '3345075':{'en': u('\u00c9vian-les-Bains'), 'fr': u('\u00c9vian-les-Bains')}, '3345074':{'en': 'Morzine', 'fr': 'Morzine'}, '3326298':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326290':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326291':{'en': 'Saint-Louis', 'fr': 'Saint-Louis'}, '3326292':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326293':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326294':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326296':{'en': 'Saint-Pierre', 'fr': 'Saint-Pierre'}, '3326297':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3751511':{'be': u('\u0412\u044f\u043b\u0456\u043a\u0430\u044f \u0411\u0435\u0440\u0430\u0441\u0442\u0430\u0432\u0456\u0446\u0430, \u0413\u0440\u043e\u0434\u0437\u0435\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Vyalikaya Byerastavitsa, Grodno Region', 'ru': u('\u0411\u0435\u0440\u0435\u0441\u0442\u043e\u0432\u0438\u0446\u0430, \u0413\u0440\u043e\u0434\u043d\u0435\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751513':{'be': u('\u0421\u0432\u0456\u0441\u043b\u0430\u0447, \u0413\u0440\u043e\u0434\u0437\u0435\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Svisloch, Grodno Region', 'ru': u('\u0421\u0432\u0438\u0441\u043b\u043e\u0447\u044c, \u0413\u0440\u043e\u0434\u043d\u0435\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751512':{'be': u('\u0412\u0430\u045e\u043a\u0430\u0432\u044b\u0441\u043a'), 'en': 'Volkovysk', 'ru': u('\u0412\u043e\u043b\u043a\u043e\u0432\u044b\u0441\u043a')}, '3751515':{'be': u('\u041c\u0430\u0441\u0442\u044b, \u0413\u0440\u043e\u0434\u0437\u0435\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Mosty, Grodno Region', 'ru': u('\u041c\u043e\u0441\u0442\u044b, \u0413\u0440\u043e\u0434\u043d\u0435\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3347532':{'en': 'Annonay', 'fr': 'Annonay'}, '3347533':{'en': 'Annonay', 'fr': 'Annonay'}, '35974325':{'bg': u('\u041b\u0438\u043b\u044f\u043d\u043e\u0432\u043e'), 'en': 'Lilyanovo'}, '35974324':{'bg': u('\u0421\u0442\u0440\u0443\u043c\u0430'), 'en': 'Struma'}, '35974327':{'bg': u('\u041d\u043e\u0432\u043e \u0414\u0435\u043b\u0447\u0435\u0432\u043e'), 'en': 'Novo Delchevo'}, '3596736':{'bg': u('\u0413\u0440\u0430\u0434\u043d\u0438\u0446\u0430, \u0413\u0430\u0431\u0440.'), 'en': 'Gradnitsa, Gabr.'}, '35974323':{'bg': u('\u041b\u043e\u0437\u0435\u043d\u0438\u0446\u0430'), 'en': 'Lozenitsa'}, '35974322':{'bg': u('\u041f\u0435\u0442\u0440\u043e\u0432\u043e, \u0411\u043b\u0430\u0433.'), 'en': 'Petrovo, Blag.'}, '3597039':{'bg': u('\u0421\u0430\u043c\u043e\u0440\u0430\u043d\u043e\u0432\u043e'), 'en': 'Samoranovo'}, '437729':{'de': 'Neukirchen an der Enknach', 'en': 'Neukirchen an der Enknach'}, '437728':{'de': 'Schwand im Innkreis', 'en': 'Schwand im Innkreis'}, '437724':{'de': 'Mauerkirchen', 'en': 'Mauerkirchen'}, '437727':{'de': 'Ach', 'en': 'Ach'}, '437723':{'de': 'Altheim', 'en': 'Altheim'}, '437722':{'de': 'Braunau am Inn', 'en': 'Braunau am Inn'}, '375212':{'be': u('\u0412\u0456\u0446\u0435\u0431\u0441\u043a'), 'en': 'Vitebsk', 'ru': u('\u0412\u0438\u0442\u0435\u0431\u0441\u043a')}, '375216':{'be': u('\u041e\u0440\u0448\u0430'), 'en': 'Orsha', 'ru': u('\u041e\u0440\u0448\u0430')}, '375214':{'be': u('\u041f\u043e\u043b\u0430\u0446\u043a/\u041d\u0430\u0432\u0430\u043f\u043e\u043b\u0430\u0446\u043a'), 'en': 'Polotsk/Navapolatsk', 'ru': u('\u041f\u043e\u043b\u043e\u0446\u043a/\u041d\u043e\u0432\u043e\u043f\u043e\u043b\u043e\u0446\u043a')}, '3597032':{'bg': u('\u042f\u0445\u0438\u043d\u043e\u0432\u043e'), 'en': 'Yahinovo'}, '3597033':{'bg': u('\u041a\u0440\u0430\u0439\u043d\u0438\u0446\u0438'), 'en': 'Kraynitsi'}, '3338222':{'en': u('J\u0153uf'), 'fr': u('J\u0153uf')}, '3338223':{'en': 'Longwy', 'fr': 'Longwy'}, '3338226':{'en': 'Longuyon', 'fr': 'Longuyon'}, '3338224':{'en': 'Longwy', 'fr': 'Longwy'}, '3338225':{'en': 'Longwy', 'fr': 'Longwy'}, '441866':{'en': 'Kilchrenan'}, '37423290':{'am': u('\u0555\u0570\u0561\u0576\u0561\u057e\u0561\u0576'), 'en': 'Ohanavan', 'ru': u('\u041e\u0433\u0430\u043d\u0430\u0432\u0430\u043d')}, '37423294':{'am': u('\u0532\u0575\u0578\u0582\u0580\u0561\u056f\u0561\u0576'), 'en': 'Byurakan', 'ru': u('\u0411\u044e\u0440\u0430\u043a\u0430\u043d')}, '3347439':{'en': 'Pont-d\'Ain', 'fr': 'Pont-d\'Ain'}, '3347438':{'en': u('Amb\u00e9rieu-en-Bugey'), 'fr': u('Amb\u00e9rieu-en-Bugey')}, '3347435':{'en': 'Hauteville-Lompnes', 'fr': 'Hauteville-Lompnes'}, '3347434':{'en': u('Amb\u00e9rieu-en-Bugey'), 'fr': u('Amb\u00e9rieu-en-Bugey')}, '3347437':{'en': 'Poncin', 'fr': 'Poncin'}, '3347431':{'en': 'Vienne', 'fr': 'Vienne'}, '3347433':{'en': u('Les Aveni\u00e8res'), 'fr': u('Les Aveni\u00e8res')}, '3347432':{'en': 'Bourg-en-Bresse', 'fr': 'Bourg-en-Bresse'}, '4181':{'de': 'Chur', 'en': 'Chur', 'fr': 'Coire', 'it': 'Coira'}, '3598187':{'bg': u('\u0422\u0435\u0442\u043e\u0432\u043e'), 'en': 'Tetovo'}, '333807':{'en': 'Dijon', 'fr': 'Dijon'}, '3598184':{'bg': u('\u0413\u043b\u043e\u0434\u0436\u0435\u0432\u043e'), 'en': 'Glodzhevo'}, '3341175':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3599547':{'bg': u('\u0412\u0438\u043d\u0438\u0449\u0435'), 'en': 'Vinishte'}, '3338165':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3596590':{'bg': u('\u0420\u0430\u043a\u0438\u0442\u0430, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Rakita, Pleven'}, '3594722':{'bg': u('\u0413\u0440\u0430\u043d\u0438\u0442\u043e\u0432\u043e, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Granitovo, Yambol'}, '3324308':{'en': 'Gorron', 'fr': 'Gorron'}, '3324309':{'en': u('Ch\u00e2teau-Gontier'), 'fr': u('Ch\u00e2teau-Gontier')}, '3347291':{'en': 'Lyon', 'fr': 'Lyon'}, '3347290':{'en': u('V\u00e9nissieux'), 'fr': u('V\u00e9nissieux')}, '3347293':{'en': u('D\u00e9cines-Charpieu'), 'fr': u('D\u00e9cines-Charpieu')}, '434237':{'de': 'Miklauzhof', 'en': 'Miklauzhof'}, '3347298':{'en': 'Lyon', 'fr': 'Lyon'}, '441708':{'en': 'Romford'}, '434235':{'de': 'Bleiburg', 'en': 'Bleiburg'}, '441702':{'en': 'Southend-on-Sea'}, '434232':{'de': u('V\u00f6lkermarkt'), 'en': u('V\u00f6lkermarkt')}, '441700':{'en': 'Rothesay'}, '46123':{'en': 'Valdemarsvik', 'sv': 'Valdemarsvik'}, '441706':{'en': 'Rochdale'}, '441707':{'en': 'Welwyn Garden City'}, '441704':{'en': 'Southport'}, '3332939':{'en': 'Thaon-les-Vosges', 'fr': 'Thaon-les-Vosges'}, '3316459':{'en': 'Dourdan', 'fr': 'Dourdan'}, '3316458':{'en': 'Breuillet', 'fr': 'Breuillet'}, '3346748':{'en': 'Frontignan', 'fr': 'Frontignan'}, '3346749':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3346744':{'en': u('Lod\u00e8ve'), 'fr': u('Lod\u00e8ve')}, '3346745':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346746':{'en': u('S\u00e8te'), 'fr': u('S\u00e8te')}, '3316452':{'en': 'Melun', 'fr': 'Melun'}, '3346740':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3316454':{'en': 'Longjumeau', 'fr': 'Longjumeau'}, '3316457':{'en': 'Mennecy', 'fr': 'Mennecy'}, '3316456':{'en': u('Saint-Ch\u00e9ron'), 'fr': u('Saint-Ch\u00e9ron')}, '3522722':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '3522723':{'de': 'Bad Mondorf', 'en': 'Mondorf-les-Bains', 'fr': 'Mondorf-les-Bains'}, '3522721':{'de': 'Weicherdingen', 'en': 'Weicherdange', 'fr': 'Weicherdange'}, '3522727':{'de': 'Belair, Luxemburg', 'en': 'Belair, Luxembourg', 'fr': 'Belair, Luxembourg'}, '3522725':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '3522728':{'de': 'Luxemburg', 'en': 'Luxembourg', 'fr': 'Luxembourg'}, '3522729':{'de': 'Luxemburg/Kockelscheuer', 'en': 'Luxembourg/Kockelscheuer', 'fr': 'Luxembourg/Kockelscheuer'}, '333232':{'en': 'Laon', 'fr': 'Laon'}, '441379':{'en': 'Diss'}, '35931108':{'bg': u('\u0411\u043e\u0433\u0434\u0430\u043d\u0438\u0446\u0430'), 'en': 'Bogdanitsa'}, '441373':{'en': 'Frome'}, '441372':{'en': 'Esher'}, '441371':{'en': 'Great Dunmow'}, '441377':{'en': 'Driffield'}, '441376':{'en': 'Braintree'}, '441375':{'en': 'Grays Thurrock'}, '3699':{'en': 'Sopron', 'hu': 'Sopron'}, '3338819':{'en': 'Schiltigheim', 'fr': 'Schiltigheim'}, '3338818':{'en': 'Schiltigheim', 'fr': 'Schiltigheim'}, '3338769':{'en': 'Metz', 'fr': 'Metz'}, '3338768':{'en': 'Metz', 'fr': 'Metz'}, '3338767':{'en': 'Rombas', 'fr': 'Rombas'}, '3338766':{'en': 'Metz', 'fr': 'Metz'}, '3338765':{'en': 'Metz', 'fr': 'Metz'}, '3338816':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338763':{'en': 'Metz', 'fr': 'Metz'}, '3338762':{'en': 'Metz', 'fr': 'Metz'}, '3338761':{'en': u('Sainte-Marie-aux-Ch\u00eanes'), 'fr': u('Sainte-Marie-aux-Ch\u00eanes')}, '3338760':{'en': 'Ars-sur-Moselle', 'fr': 'Ars-sur-Moselle'}, '35984392':{'bg': u('\u0411\u0435\u043b\u0438\u043d\u0446\u0438'), 'en': 'Belintsi'}, '3324785':{'en': 'Tours', 'fr': 'Tours'}, '3346701':{'en': 'Agde', 'fr': 'Agde'}, '3324786':{'en': 'Tours', 'fr': 'Tours'}, '433623':{'de': 'Bad Mitterndorf', 'en': 'Bad Mitterndorf'}, '3342665':{'en': 'Lyon', 'fr': 'Lyon'}, '3342663':{'en': 'Lyon', 'fr': 'Lyon'}, '3596998':{'bg': u('\u0413\u043e\u043b\u044f\u043c \u0438\u0437\u0432\u043e\u0440, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Golyam izvor, Lovech'}, '3355335':{'en': u('P\u00e9rigueux'), 'fr': u('P\u00e9rigueux')}, '3355331':{'en': u('Sarlat-la-Can\u00e9da'), 'fr': u('Sarlat-la-Can\u00e9da')}, '3355330':{'en': u('Sarlat-la-Can\u00e9da'), 'fr': u('Sarlat-la-Can\u00e9da')}, '3349293':{'en': 'Antibes Juan les Pins', 'fr': 'Antibes Juan les Pins'}, '3349292':{'en': 'Mougins', 'fr': 'Mougins'}, '3349291':{'en': 'Antibes Juan les Pins', 'fr': 'Antibes Juan les Pins'}, '3349290':{'en': 'Antibes Juan les Pins', 'fr': 'Antibes Juan les Pins'}, '3349297':{'en': 'Mandelieu-la-Napoule', 'fr': 'Mandelieu-la-Napoule'}, '3349296':{'en': 'Valbonne', 'fr': 'Valbonne'}, '3349295':{'en': 'Vallauris', 'fr': 'Vallauris'}, '3349294':{'en': 'Valbonne', 'fr': 'Valbonne'}, '3349299':{'en': 'Cannes', 'fr': 'Cannes'}, '3349298':{'en': 'Cannes', 'fr': 'Cannes'}, '441959':{'en': 'Westerham'}, '441957':{'en': 'Mid Yell'}, '441955':{'en': 'Wick'}, '441954':{'en': 'Madingley'}, '441953':{'en': 'Wymondham'}, '441952':{'en': 'Telford'}, '441951':{'en': 'Colonsay'}, '441950':{'en': 'Sandwick'}, '371656':{'en': u('Kr\u0101slava')}, '371657':{'en': 'Ludza'}, '371654':{'en': 'Daugavpils'}, '371655':{'en': 'Ogre'}, '371652':{'en': u('J\u0113kabpils')}, '371653':{'en': u('Prei\u013ci')}, '371650':{'en': 'Ogre'}, '371651':{'en': 'Aizkraukle'}, '371658':{'en': 'Daugavpils'}, '371659':{'en': u('C\u0113sis')}, '35981264':{'bg': u('\u041f\u0438\u043f\u0435\u0440\u043a\u043e\u0432\u043e'), 'en': 'Piperkovo'}, '432722':{'de': 'Kirchberg an der Pielach', 'en': 'Kirchberg an der Pielach'}, '432723':{'de': 'Rabenstein an der Pielach', 'en': 'Rabenstein an der Pielach'}, '432726':{'de': 'Puchenstuben', 'en': 'Puchenstuben'}, '432724':{'de': 'Schwarzenbach an der Pielach', 'en': 'Schwarzenbach an der Pielach'}, '3332058':{'en': 'Wavrin', 'fr': 'Wavrin'}, '3332057':{'en': 'Lille', 'fr': 'Lille'}, '3332056':{'en': 'Lille', 'fr': 'Lille'}, '3332055':{'en': 'Lille', 'fr': 'Lille'}, '3332054':{'en': 'Lille', 'fr': 'Lille'}, '3332053':{'en': 'Lille', 'fr': 'Lille'}, '3332052':{'en': 'Lille', 'fr': 'Lille'}, '3332051':{'en': 'Lille', 'fr': 'Lille'}, '3332502':{'en': 'Chaumont', 'fr': 'Chaumont'}, '3323343':{'en': 'Cherbourg-Octeville', 'fr': 'Cherbourg-Octeville'}, '42056':{'en': u('Vyso\u010dina Region')}, '3323507':{'en': 'Rouen', 'fr': 'Rouen'}, '3323506':{'en': 'Dieppe', 'fr': 'Dieppe'}, '3355593':{'en': u('\u00c9gletons'), 'fr': u('\u00c9gletons')}, '3355592':{'en': u('Malemort-sur-Corr\u00e8ze'), 'fr': u('Malemort-sur-Corr\u00e8ze')}, '3323503':{'en': 'Rouen', 'fr': 'Rouen'}, '3355849':{'en': u('L\u00e9on'), 'fr': u('L\u00e9on')}, '3355596':{'en': 'Bort-les-Orgues', 'fr': 'Bort-les-Orgues'}, '3355847':{'en': 'Magescq', 'fr': 'Magescq'}, '3355846':{'en': 'Mont-de-Marsan', 'fr': 'Mont-de-Marsan'}, '373244':{'en': 'Calarasi', 'ro': u('C\u0103l\u0103ra\u015fi'), 'ru': u('\u041a\u044d\u043b\u044d\u0440\u0430\u0448\u044c')}, '3355843':{'en': 'Soorts-Hossegor', 'fr': 'Soorts-Hossegor'}, '3355842':{'en': 'Lit-et-Mixe', 'fr': 'Lit-et-Mixe'}, '3323509':{'en': 'Gournay-en-Bray', 'fr': 'Gournay-en-Bray'}, '3323508':{'en': u('Darn\u00e9tal'), 'fr': u('Darn\u00e9tal')}, '3349437':{'en': 'Brignoles', 'fr': 'Brignoles'}, '3349436':{'en': 'Toulon', 'fr': 'Toulon'}, '3349435':{'en': u('Hy\u00e8res'), 'fr': u('Hy\u00e8res')}, '3349434':{'en': 'Six-Fours-les-Plages', 'fr': 'Six-Fours-les-Plages'}, '3349433':{'en': u('Solli\u00e8s-Pont'), 'fr': u('Solli\u00e8s-Pont')}, '3349432':{'en': 'Bandol', 'fr': 'Bandol'}, '3349431':{'en': 'Toulon', 'fr': 'Toulon'}, '3349430':{'en': 'La Seyne sur Mer', 'fr': 'La Seyne sur Mer'}, '3355601':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3349439':{'en': 'Montauroux', 'fr': 'Montauroux'}, '3349438':{'en': u('Hy\u00e8res'), 'fr': u('Hy\u00e8res')}, '3355350':{'en': 'Terrasson-Lavilledieu', 'fr': 'Terrasson-Lavilledieu'}, '432160':{'de': 'Jois', 'en': 'Jois'}, '42058':{'en': 'Olomouc Region'}, '432162':{'de': 'Bruck an der Leitha', 'en': 'Bruck an der Leitha'}, '42059':{'en': 'Moravian-Silesian Region'}, '35941354':{'bg': u('\u041c\u0430\u043b\u043a\u043e \u0422\u0440\u044a\u043d\u043e\u0432\u043e'), 'en': 'Malko Tranovo'}, '35941355':{'bg': u('\u042f\u0432\u043e\u0440\u043e\u0432\u043e'), 'en': 'Yavorovo'}, '35941356':{'bg': u('\u0420\u0443\u043f\u043a\u0438\u0442\u0435'), 'en': 'Rupkite'}, '3322341':{'en': u('Br\u00e9al-sous-Montfort'), 'fr': u('Br\u00e9al-sous-Montfort')}, '35941350':{'bg': u('\u041c\u0438\u0440\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Mirovo, St. Zagora'}, '35941351':{'bg': u('\u041f\u0430\u0440\u0442\u0438\u0437\u0430\u043d\u0438\u043d'), 'en': 'Partizanin'}, '35941352':{'bg': u('\u0412\u0438\u043d\u0430\u0440\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Vinarovo, St. Zagora'}, '35941353':{'bg': u('\u041f\u043b\u043e\u0434\u043e\u0432\u0438\u0442\u043e\u0432\u043e'), 'en': 'Plodovitovo'}, '432164':{'de': 'Rohrau', 'en': 'Rohrau'}, '35941358':{'bg': u('\u041e\u043f\u044a\u043b\u0447\u0435\u043d\u0435\u0446'), 'en': 'Opalchenets'}, '35941359':{'bg': u('\u0418\u0437\u0432\u043e\u0440\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Izvorovo, St. Zagora'}, '432166':{'de': 'Parndorf', 'en': 'Parndorf'}, '432167':{'de': 'Neusiedl am See', 'en': 'Neusiedl am See'}, '437664':{'de': 'Weyregg am Attersee', 'en': 'Weyregg am Attersee'}, '437665':{'de': 'Unterach am Attersee', 'en': 'Unterach am Attersee'}, '437666':{'de': 'Attersee', 'en': 'Attersee'}, '441571':{'en': 'Lochinver'}, '441570':{'en': 'Lampeter'}, '441573':{'en': 'Kelso'}, '441572':{'en': 'Oakham'}, '441575':{'en': 'Kirriemuir'}, '441577':{'en': 'Kinross'}, '441576':{'en': 'Lockerbie'}, '441579':{'en': 'Liskeard'}, '441578':{'en': 'Lauder'}, '437662':{'de': 'Seewalchen am Attersee', 'en': 'Seewalchen am Attersee'}, '3324881':{'en': u('Aubigny-sur-N\u00e8re'), 'fr': u('Aubigny-sur-N\u00e8re')}, '3324880':{'en': 'Cuffy', 'fr': 'Cuffy'}, '437663':{'de': 'Steinbach am Attersee', 'en': 'Steinbach am Attersee'}, '3596918':{'bg': u('\u0414\u0440\u0435\u043d\u043e\u0432'), 'en': 'Drenov'}, '3596919':{'bg': u('\u0421\u043b\u0430\u0442\u0438\u043d\u0430, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Slatina, Lovech'}, '3596912':{'bg': u('\u0411\u0430\u0445\u043e\u0432\u0438\u0446\u0430'), 'en': 'Bahovitsa'}, '3596913':{'bg': u('\u0421\u043b\u0430\u0432\u044f\u043d\u0438'), 'en': 'Slavyani'}, '3596910':{'bg': u('\u041c\u0430\u043b\u0438\u043d\u043e\u0432\u043e'), 'en': 'Malinovo'}, '3596911':{'bg': u('\u041b\u0438\u0441\u0435\u0446, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Lisets, Lovech'}, '3596916':{'bg': u('\u0411\u0440\u0435\u0441\u0442\u043e\u0432\u043e, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Brestovo, Lovech'}, '3596917':{'bg': u('\u0411\u044a\u043b\u0433\u0430\u0440\u0435\u043d\u0435, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Balgarene, Lovech'}, '3596914':{'bg': u('\u0421\u043b\u0438\u0432\u0435\u043a'), 'en': 'Slivek'}, '3596915':{'bg': u('\u0421\u043c\u043e\u0447\u0430\u043d'), 'en': 'Smochan'}, '373272':{'en': 'Soldanesti', 'ro': u('\u015eold\u0103ne\u015fti'), 'ru': u('\u0428\u043e\u043b\u0434\u044d\u043d\u0435\u0448\u0442\u044c')}, '373273':{'en': 'Cantemir', 'ro': 'Cantemir', 'ru': u('\u041a\u0430\u043d\u0442\u0435\u043c\u0438\u0440')}, '373271':{'en': u('Ocni\u0163a'), 'ro': u('Ocni\u0163a'), 'ru': u('\u041e\u043a\u043d\u0438\u0446\u0430')}, '3324089':{'en': 'Nantes', 'fr': 'Nantes'}, '3324086':{'en': u('Cou\u00ebron'), 'fr': u('Cou\u00ebron')}, '3324085':{'en': 'Saint-Herblain', 'fr': 'Saint-Herblain'}, '3324084':{'en': 'Nantes', 'fr': 'Nantes'}, '3324083':{'en': 'Ancenis', 'fr': 'Ancenis'}, '3324082':{'en': 'Pornic', 'fr': 'Pornic'}, '3324081':{'en': u('Ch\u00e2teaubriant'), 'fr': u('Ch\u00e2teaubriant')}, '3324080':{'en': u('Saint-S\u00e9bastien-sur-Loire'), 'fr': u('Saint-S\u00e9bastien-sur-Loire')}, '433328':{'de': 'Kukmirn', 'en': 'Kukmirn'}, '3353198':{'en': 'Toulouse', 'fr': 'Toulouse'}, '4419466':{'en': 'Whitehaven'}, '3347351':{'en': 'Thiers', 'fr': 'Thiers'}, '3347600':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347353':{'en': u('Courpi\u00e8re'), 'fr': u('Courpi\u00e8re')}, '3347354':{'en': 'Brassac-les-Mines', 'fr': 'Brassac-les-Mines'}, '3347355':{'en': 'Issoire', 'fr': 'Issoire'}, '3347604':{'en': 'Meylan', 'fr': 'Meylan'}, '3347605':{'en': 'Voiron', 'fr': 'Voiron'}, '3347608':{'en': 'Crolles', 'fr': 'Crolles'}, '3347609':{'en': u('\u00c9chirolles'), 'fr': u('\u00c9chirolles')}, '3906':{'en': 'Rome', 'it': 'Roma'}, '3335412':{'en': 'Nancy', 'fr': 'Nancy'}, '4414371':{'en': 'Haverfordwest/Clynderwen (Clunderwen)'}, '3323888':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323889':{'en': 'Montargis', 'fr': 'Montargis'}, '4414374':{'en': 'Clynderwen (Clunderwen)'}, '4414375':{'en': 'Clynderwen (Clunderwen)'}, '4414376':{'en': 'Haverfordwest'}, '4414377':{'en': 'Haverfordwest'}, '4414378':{'en': 'Haverfordwest'}, '3323883':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323881':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323886':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323884':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323885':{'en': 'Montargis', 'fr': 'Montargis'}, '3325113':{'en': 'Nantes', 'fr': 'Nantes'}, '3752248':{'be': u('\u0414\u0440\u044b\u0431\u0456\u043d, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Dribin, Mogilev Region', 'ru': u('\u0414\u0440\u0438\u0431\u0438\u043d, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752244':{'be': u('\u041a\u043b\u0456\u043c\u0430\u0432\u0456\u0447\u044b, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Klimovichi, Mogilev Region', 'ru': u('\u041a\u043b\u0438\u043c\u043e\u0432\u0438\u0447\u0438, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752245':{'be': u('\u041a\u0430\u0441\u0446\u044e\u043a\u043e\u0432\u0456\u0447\u044b, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Kostyukovichi, Mogilev Region', 'ru': u('\u041a\u043e\u0441\u0442\u044e\u043a\u043e\u0432\u0438\u0447\u0438, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752246':{'be': u('\u0421\u043b\u0430\u045e\u0433\u0430\u0440\u0430\u0434, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Slavgorod, Mogilev Region', 'ru': u('\u0421\u043b\u0430\u0432\u0433\u043e\u0440\u043e\u0434, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752247':{'be': u('\u0425\u043e\u0446\u0456\u043c\u0441\u043a, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Khotimsk, Mogilev Region', 'ru': u('\u0425\u043e\u0442\u0438\u043c\u0441\u043a, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752240':{'be': u('\u041c\u0441\u0446\u0456\u0441\u043b\u0430\u045e'), 'en': 'Mstislavl', 'ru': u('\u041c\u0441\u0442\u0438\u0441\u043b\u0430\u0432\u043b\u044c')}, '3752241':{'be': u('\u041a\u0440\u044b\u0447\u0430\u045e, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Krichev, Mogilev Region', 'ru': u('\u041a\u0440\u0438\u0447\u0435\u0432, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752242':{'be': u('\u0427\u0430\u0432\u0443\u0441\u044b, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Chausy, Mogilev Region', 'ru': u('\u0427\u0430\u0443\u0441\u044b, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752243':{'be': u('\u0427\u044d\u0440\u044b\u043a\u0430\u045e, \u041c\u0430\u0433\u0456\u043b\u0451\u045e\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Cherikov, Mogilev Region', 'ru': u('\u0427\u0435\u0440\u0438\u043a\u043e\u0432, \u041c\u043e\u0433\u0438\u043b\u0435\u0432\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3347975':{'en': u('Chamb\u00e9ry'), 'fr': u('Chamb\u00e9ry')}, '3347970':{'en': u('Chamb\u00e9ry'), 'fr': u('Chamb\u00e9ry')}, '3347971':{'en': u('Chamb\u00e9ry'), 'fr': u('Chamb\u00e9ry')}, '3347972':{'en': 'Challes-les-Eaux', 'fr': 'Challes-les-Eaux'}, '4419461':{'en': 'Whitehaven'}, '3323269':{'en': u('\u00c9couis'), 'fr': u('\u00c9couis')}, '3323264':{'en': 'Vernon', 'fr': 'Vernon'}, '3323262':{'en': u('\u00c9vreux'), 'fr': u('\u00c9vreux')}, '3323261':{'en': 'Val-de-Reuil', 'fr': 'Val-de-Reuil'}, '3597137':{'bg': u('\u0421\u043a\u0440\u0430\u0432\u0435\u043d\u0430'), 'en': 'Skravena'}, '3597136':{'bg': u('\u041d\u043e\u0432\u0430\u0447\u0435\u043d\u0435, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Novachene, Sofia'}, '3597135':{'bg': u('\u0422\u0440\u0443\u0434\u043e\u0432\u0435\u0446'), 'en': 'Trudovets'}, '3597134':{'bg': u('\u0412\u0440\u0430\u0447\u0435\u0448'), 'en': 'Vrachesh'}, '3597133':{'bg': u('\u041f\u0440\u0430\u0432\u0435\u0446'), 'en': 'Pravets'}, '3597132':{'bg': u('\u0420\u0430\u0434\u043e\u0442\u0438\u043d\u0430'), 'en': 'Radotina'}, '4419460':{'en': 'Whitehaven'}, '390461':{'en': 'Trento', 'it': 'Trento'}, '390462':{'it': 'Cavalese'}, '390463':{'it': 'Cles'}, '390464':{'it': 'Rovereto'}, '390465':{'it': 'Tione di Trento'}, '35971221':{'bg': u('\u042f\u0440\u043b\u043e\u0432\u043e'), 'en': 'Yarlovo'}, '3597138':{'bg': u('\u041b\u0438\u0442\u0430\u043a\u043e\u0432\u043e'), 'en': 'Litakovo'}, '42148':{'en': u('Bansk\u00e1 Bystrica')}, '42142':{'en': u('Pova\u017esk\u00e1 Bystrica')}, '42143':{'en': 'Martin'}, '42141':{'en': u('\u017dilina')}, '42146':{'en': 'Prievidza'}, '35974496':{'bg': u('\u0424\u0438\u043b\u0438\u043f\u043e\u0432\u043e, \u0411\u043b\u0430\u0433.'), 'en': 'Filipovo, Blag.'}, '35974495':{'bg': u('\u042e\u0440\u0443\u043a\u043e\u0432\u043e'), 'en': 'Yurukovo'}, '42145':{'en': 'Zvolen'}, '3345055':{'en': 'Chamonix-Mont-Blanc', 'fr': 'Chamonix-Mont-Blanc'}, '3324124':{'en': 'Angers', 'fr': 'Angers'}, '3345057':{'en': 'Annecy', 'fr': 'Annecy'}, '3345056':{'en': 'Bellegarde-sur-Valserine', 'fr': 'Bellegarde-sur-Valserine'}, '3345051':{'en': 'Annecy', 'fr': 'Annecy'}, '3345053':{'en': 'Chamonix-Mont-Blanc', 'fr': 'Chamonix-Mont-Blanc'}, '3345052':{'en': 'Annecy', 'fr': 'Annecy'}, '3345058':{'en': 'Sallanches', 'fr': 'Sallanches'}, '3346703':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3324120':{'en': 'Angers', 'fr': 'Angers'}, '3324122':{'en': 'Angers', 'fr': 'Angers'}, '3324123':{'en': 'Angers', 'fr': 'Angers'}, '3338594':{'en': u('Chalon-sur-Sa\u00f4ne'), 'fr': u('Chalon-sur-Sa\u00f4ne')}, '3338597':{'en': u('Chalon-sur-Sa\u00f4ne'), 'fr': u('Chalon-sur-Sa\u00f4ne')}, '3338590':{'en': u('Chalon-sur-Sa\u00f4ne'), 'fr': u('Chalon-sur-Sa\u00f4ne')}, '3338592':{'en': 'Buxy', 'fr': 'Buxy'}, '3338593':{'en': u('Chalon-sur-Sa\u00f4ne'), 'fr': u('Chalon-sur-Sa\u00f4ne')}, '3338598':{'en': u('Ch\u00e2tenoy-le-Royal'), 'fr': u('Ch\u00e2tenoy-le-Royal')}, '3332266':{'en': 'Amiens', 'fr': 'Amiens'}, '3332260':{'en': 'Saint-Valery-sur-Somme', 'fr': 'Saint-Valery-sur-Somme'}, '3332261':{'en': 'Friville-Escarbotin', 'fr': 'Friville-Escarbotin'}, '3324129':{'en': 'Cholet', 'fr': 'Cholet'}, '35971225':{'bg': u('\u041d\u043e\u0432\u043e \u0441\u0435\u043b\u043e, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Novo selo, Sofia'}, '433462':{'de': 'Deutschlandsberg', 'en': 'Deutschlandsberg'}, '39049':{'en': 'Padova', 'it': 'Padova'}, '433460':{'de': 'Soboth', 'en': 'Soboth'}, '433461':{'de': u('Trah\u00fctten'), 'en': u('Trah\u00fctten')}, '433466':{'de': 'Eibiswald', 'en': 'Eibiswald'}, '433467':{'de': 'Schwanberg', 'en': 'Schwanberg'}, '433464':{'de': u('Gro\u00df Sankt Florian'), 'en': 'Gross St. Florian'}, '433465':{'de': u('P\u00f6lfing-Brunn'), 'en': u('P\u00f6lfing-Brunn')}, '375236':{'be': u('\u041c\u0430\u0437\u044b\u0440'), 'en': 'Mozyr', 'ru': u('\u041c\u043e\u0437\u044b\u0440\u044c')}, '433469':{'de': 'Sankt Oswald im Freiland', 'en': 'St. Oswald im Freiland'}, '375232':{'be': u('\u0413\u043e\u043c\u0435\u043b\u044c'), 'en': 'Gomel', 'ru': u('\u0413\u043e\u043c\u0435\u043b\u044c')}, '40236':{'en': u('Gala\u021bi'), 'ro': u('Gala\u021bi')}, '37424492':{'am': u('\u0553\u0561\u0576\u056b\u056f'), 'en': 'Panik', 'ru': u('\u041f\u0430\u043d\u0438\u043a')}, '40234':{'en': u('Bac\u0103u'), 'ro': u('Bac\u0103u')}, '40235':{'en': 'Vaslui', 'ro': 'Vaslui'}, '3356158':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356159':{'en': 'Toulouse', 'fr': 'Toulouse'}, '37424495':{'am': u('\u0531\u0580\u0587\u0577\u0561\u057f'), 'en': 'Arevshat', 'ru': u('\u0410\u0440\u0435\u0432\u0448\u0430\u0442')}, '40231':{'en': u('Boto\u0219ani'), 'ro': u('Boto\u0219ani')}, '3356154':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356155':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356156':{'en': 'Muret', 'fr': 'Muret'}, '3356157':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356150':{'en': 'Auterive', 'fr': 'Auterive'}, '3356151':{'en': 'Muret', 'fr': 'Muret'}, '3356152':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356153':{'en': 'Toulouse', 'fr': 'Toulouse'}, '39040':{'en': 'Trieste', 'it': 'Trieste'}, '3356378':{'en': 'Albi', 'fr': 'Albi'}, '3336710':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3336711':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3356371':{'en': 'Castres', 'fr': 'Castres'}, '3356372':{'en': 'Castres', 'fr': 'Castres'}, '3356373':{'en': u('Labrugui\u00e8re'), 'fr': u('Labrugui\u00e8re')}, '3356376':{'en': 'Carmaux', 'fr': 'Carmaux'}, '3356377':{'en': 'Albi', 'fr': 'Albi'}, '370469':{'en': 'Neringa'}, '370460':{'en': 'Palanga'}, '35267':{'de': u('D\u00fcdelingen'), 'en': 'Dudelange', 'fr': 'Dudelange'}, '359359':{'bg': u('\u0412\u0435\u043b\u0438\u043d\u0433\u0440\u0430\u0434'), 'en': 'Velingrad'}, '35971302':{'bg': u('\u0411\u043e\u0436\u0435\u043d\u0438\u0446\u0430'), 'en': 'Bozhenitsa'}, '359357':{'bg': u('\u041f\u0430\u043d\u0430\u0433\u044e\u0440\u0438\u0449\u0435'), 'en': 'Panagyurishte'}, '359350':{'bg': u('\u041f\u0435\u0449\u0435\u0440\u0430, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Peshtera, Pazardzhik'}, '441499':{'en': 'Inveraray'}, '441492':{'en': 'Colwyn Bay'}, '441493':{'en': 'Great Yarmouth'}, '441490':{'en': 'Corwen'}, '441491':{'en': 'Henley-on-Thames'}, '441496':{'en': 'Port Ellen'}, '441497':{'en': 'Hay-on-Wye'}, '441494':{'en': 'High Wycombe'}, '441495':{'en': 'Pontypool'}, '435223':{'de': 'Hall in Tirol', 'en': 'Hall in Tirol'}, '441724':{'en': 'Scunthorpe'}, '441725':{'en': 'Rockbourne'}, '35971304':{'bg': u('\u041b\u0438\u043f\u043d\u0438\u0446\u0430, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Lipnitsa, Sofia'}, '441727':{'en': 'St Albans'}, '441720':{'en': 'Isles of Scilly'}, '441721':{'en': 'Peebles'}, '441722':{'en': 'Salisbury'}, '441723':{'en': 'Scarborough'}, '435226':{'de': 'Neustift im Stubaital', 'en': 'Neustift im Stubaital'}, '441728':{'en': 'Saxmundham'}, '441729':{'en': 'Settle'}, '3346766':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346767':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346764':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346765':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346762':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3346763':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346760':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346761':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3316439':{'en': 'Melun', 'fr': 'Melun'}, '435225':{'de': 'Fulpmes', 'en': 'Fulpmes'}, '3346768':{'en': 'Palavas-les-Flots', 'fr': 'Palavas-les-Flots'}, '3346769':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3596074':{'bg': u('\u041b\u044e\u0431\u0438\u0447\u0435\u0432\u043e'), 'en': 'Lyubichevo'}, '3596077':{'bg': u('\u0421\u0442\u0435\u0432\u0440\u0435\u043a'), 'en': 'Stevrek'}, '3596076':{'bg': u('\u0422\u0430\u0439\u043c\u0438\u0449\u0435'), 'en': 'Taymishte'}, '3596071':{'bg': u('\u0410\u043d\u0442\u043e\u043d\u043e\u0432\u043e'), 'en': 'Antonovo'}, '3598138':{'bg': u('\u0411\u0440\u044a\u0448\u043b\u0435\u043d'), 'en': 'Brashlen'}, '3596072':{'bg': u('\u0414\u043e\u0431\u0440\u043e\u0442\u0438\u0446\u0430, \u0422\u044a\u0440\u0433.'), 'en': 'Dobrotitsa, Targ.'}, '3343044':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3338954':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3338955':{'en': 'Wittelsheim', 'fr': 'Wittelsheim'}, '3336807':{'en': 'Colmar', 'fr': 'Colmar'}, '37426397':{'am': u('\u0531\u0566\u0561\u057f\u0561\u0574\u0578\u0582\u057f'), 'en': 'Azatamut', 'ru': u('\u0410\u0437\u0430\u0442\u0430\u043c\u0443\u0442')}, '37426392':{'am': u('\u0531\u0579\u0561\u057b\u0578\u0582\u0580'), 'en': 'Achajur', 'ru': u('\u0410\u0447\u0430\u0434\u0436\u0443\u0440')}, '432913':{'de': u('H\u00f6tzelsdorf'), 'en': u('H\u00f6tzelsdorf')}, '432912':{'de': 'Geras', 'en': 'Geras'}, '437435':{'de': 'Sankt Valentin', 'en': 'St. Valentin'}, '3325378':{'en': 'Nantes', 'fr': 'Nantes'}, '437434':{'de': 'Haag', 'en': 'Haag'}, '432916':{'de': 'Riegersburg, Hardegg', 'en': 'Riegersburg, Hardegg'}, '3332196':{'en': 'Calais', 'fr': 'Calais'}, '441337':{'en': 'Ladybank'}, '3332197':{'en': 'Calais', 'fr': 'Calais'}, '3332626':{'en': u('Ch\u00e2lons-en-Champagne'), 'fr': u('Ch\u00e2lons-en-Champagne')}, '3354628':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3354629':{'en': u('Ars-en-R\u00e9'), 'fr': u('Ars-en-R\u00e9')}, '3354625':{'en': u('Authon-Eb\u00e9on'), 'fr': u('Authon-Eb\u00e9on')}, '3354627':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3332621':{'en': u('Ch\u00e2lons-en-Champagne'), 'fr': u('Ch\u00e2lons-en-Champagne')}, '3332622':{'en': u('Ch\u00e2lons-en-Champagne'), 'fr': u('Ch\u00e2lons-en-Champagne')}, '34973':{'en': u('L\u00e9rida'), 'es': u('L\u00e9rida')}, '390873':{'it': 'Vasto'}, '390872':{'it': 'Lanciano'}, '390871':{'it': 'Chieti'}, '390875':{'it': 'Termoli'}, '390874':{'en': 'Campobasso', 'it': 'Campobasso'}, '441939':{'en': 'Wem'}, '441938':{'en': 'Welshpool'}, '441931':{'en': 'Shap'}, '441933':{'en': 'Wellingborough'}, '441932':{'en': 'Weybridge'}, '441935':{'en': 'Yeovil'}, '441934':{'en': 'Weston-super-Mare'}, '441937':{'en': 'Wetherby'}, '34979':{'en': 'Palencia', 'es': 'Palencia'}, '3593559':{'bg': u('\u041a\u0430\u043f\u0438\u0442\u0430\u043d \u0414\u0438\u043c\u0438\u0442\u0440\u0438\u0435\u0432\u043e'), 'en': 'Kapitan Dimitrievo'}, '3593558':{'bg': u('\u0418\u0441\u043f\u0435\u0440\u0438\u0445\u043e\u0432\u043e'), 'en': 'Isperihovo'}, '3593555':{'bg': u('\u041d\u043e\u0432\u0430 \u043c\u0430\u0445\u0430\u043b\u0430, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Nova mahala, Pazardzhik'}, '3593554':{'bg': u('\u041a\u043e\u0437\u0430\u0440\u0441\u043a\u043e'), 'en': 'Kozarsko'}, '3593557':{'bg': u('\u0411\u044f\u0433\u0430'), 'en': 'Byaga'}, '3593556':{'bg': u('\u0420\u0430\u0434\u0438\u043b\u043e\u0432\u043e'), 'en': 'Radilovo'}, '3593553':{'bg': u('\u0411\u0430\u0442\u0430\u043a, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Batak, Pazardzhik'}, '3593552':{'bg': u('\u0411\u0440\u0430\u0446\u0438\u0433\u043e\u0432\u043e'), 'en': 'Bratsigovo'}, '3332078':{'en': 'Lille', 'fr': 'Lille'}, '432258':{'de': 'Alland', 'en': 'Alland'}, '432259':{'de': u('M\u00fcnchendorf'), 'en': u('M\u00fcnchendorf')}, '3332071':{'en': 'Orchies', 'fr': 'Orchies'}, '3332070':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332073':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332072':{'en': u('Marcq-en-Bar\u0153ul'), 'fr': u('Marcq-en-Bar\u0153ul')}, '3332075':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332074':{'en': 'Lille', 'fr': 'Lille'}, '3332077':{'en': u('Armenti\u00e8res'), 'fr': u('Armenti\u00e8res')}, '3332076':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '3323521':{'en': 'Le Havre', 'fr': 'Le Havre'}, '35941117':{'bg': u('\u041a\u0430\u0437\u0430\u043d\u043a\u0430'), 'en': 'Kazanka'}, '35941114':{'bg': u('\u041b\u043e\u0437\u0435\u043d, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Lozen, St. Zagora'}, '3323522':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323525':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323524':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323526':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323529':{'en': u('F\u00e9camp'), 'fr': u('F\u00e9camp')}, '3323528':{'en': u('F\u00e9camp'), 'fr': u('F\u00e9camp')}, '3329936':{'en': 'Rennes', 'fr': 'Rennes'}, '3329937':{'en': u('Ch\u00e2teaugiron'), 'fr': u('Ch\u00e2teaugiron')}, '3329930':{'en': 'Rennes', 'fr': 'Rennes'}, '3329931':{'en': 'Rennes', 'fr': 'Rennes'}, '3329932':{'en': 'Rennes', 'fr': 'Rennes'}, '3329933':{'en': 'Rennes', 'fr': 'Rennes'}, '3332383':{'en': u('Ch\u00e2teau-Thierry'), 'fr': u('Ch\u00e2teau-Thierry')}, '3349410':{'en': 'Six-Fours-les-Plages', 'fr': 'Six-Fours-les-Plages'}, '3332381':{'en': 'Ham', 'fr': 'Ham'}, '3349412':{'en': u('Hy\u00e8res'), 'fr': u('Hy\u00e8res')}, '3349415':{'en': 'Bormes-les-Mimosas', 'fr': 'Bormes-les-Mimosas'}, '37428193':{'am': u('\u0531\u0572\u0561\u057e\u0576\u0561\u0571\u0578\u0580'), 'en': 'Aghavnadzor', 'ru': u('\u0410\u0433\u0430\u0432\u043d\u0430\u0434\u0437\u043e\u0440')}, '3349417':{'en': u('Fr\u00e9jus'), 'fr': u('Fr\u00e9jus')}, '3332384':{'en': u('Ch\u00e2teau-Thierry'), 'fr': u('Ch\u00e2teau-Thierry')}, '3349419':{'en': u('Saint-Rapha\u00ebl'), 'fr': u('Saint-Rapha\u00ebl')}, '3349418':{'en': 'Toulon', 'fr': 'Toulon'}, '37428198':{'am': u('\u054c\u056b\u0576\u0564'), 'en': 'Rind', 'ru': u('\u0420\u0438\u043d\u0434')}, '37428199':{'am': u('\u0547\u0561\u057f\u056b\u0576'), 'en': 'Shatin', 'ru': u('\u0428\u0430\u0442\u0438\u043d')}, '3354996':{'en': 'Thouars', 'fr': 'Thouars'}, '3354997':{'en': 'Civray', 'fr': 'Civray'}, '3354994':{'en': 'Parthenay', 'fr': 'Parthenay'}, '3354993':{'en': u('Ch\u00e2tellerault'), 'fr': u('Ch\u00e2tellerault')}, '3354990':{'en': u('Naintr\u00e9'), 'fr': u('Naintr\u00e9')}, '3354991':{'en': 'Montmorillon', 'fr': 'Montmorillon'}, '3354998':{'en': 'Loudun', 'fr': 'Loudun'}, '3355717':{'en': 'Biganos', 'fr': 'Biganos'}, '433618':{'de': 'Hohentauern', 'en': 'Hohentauern'}, '3355715':{'en': 'La Teste de Buch', 'fr': 'La Teste de Buch'}, '3355714':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355712':{'en': 'Gradignan', 'fr': 'Gradignan'}, '3355710':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '433611':{'de': 'Johnsbach', 'en': 'Johnsbach'}, '433613':{'de': 'Admont', 'en': 'Admont'}, '433612':{'de': 'Liezen', 'en': 'Liezen'}, '3323737':{'en': 'Senonches', 'fr': 'Senonches'}, '433614':{'de': 'Rottenmann', 'en': 'Rottenmann'}, '3355719':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '433616':{'de': 'Selzthal', 'en': 'Selzthal'}, '433533':{'de': 'Turrach', 'en': 'Turrach'}, '3656':{'en': 'Szolnok', 'hu': 'Szolnok'}, '3657':{'en': 'Jaszbereny', 'hu': u('J\u00e1szber\u00e9ny')}, '46271':{'en': 'Alfta-Edsbyn', 'sv': 'Alfta-Edsbyn'}, '3594798':{'bg': u('\u0421\u0430\u0432\u0438\u043d\u043e'), 'en': 'Savino'}, '3594799':{'bg': u('\u0413\u043e\u043b\u044f\u043c \u043c\u0430\u043d\u0430\u0441\u0442\u0438\u0440'), 'en': 'Golyam manastir'}, '3594796':{'bg': u('\u0413\u0435\u043d\u0435\u0440\u0430\u043b \u0422\u043e\u0448\u0435\u0432\u043e, \u042f\u043c\u0431\u043e\u043b'), 'en': 'General Toshevo, Yambol'}, '3594797':{'bg': u('\u0413\u044a\u043b\u044a\u0431\u0438\u043d\u0446\u0438'), 'en': 'Galabintsi'}, '3594794':{'bg': u('\u041e\u0432\u0447\u0438 \u043a\u043b\u0430\u0434\u0435\u043d\u0435\u0446'), 'en': 'Ovchi kladenets'}, '3594795':{'bg': u('\u0421\u043a\u0430\u043b\u0438\u0446\u0430'), 'en': 'Skalitsa'}, '3594792':{'bg': u('\u0411\u043e\u0442\u0435\u0432\u043e, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Botevo, Yambol'}, '3594793':{'bg': u('\u0411\u043e\u044f\u0434\u0436\u0438\u043a'), 'en': 'Boyadzhik'}, '441559':{'en': 'Llandysul'}, '441558':{'en': 'Llandeilo'}, '441553':{'en': 'Kings Lynn'}, '441550':{'en': 'Llandovery'}, '441557':{'en': 'Kirkcudbright'}, '441556':{'en': 'Castle Douglas'}, '441555':{'en': 'Lanark'}, '441554':{'en': 'Llanelli'}, '3332925':{'en': 'La Bresse', 'fr': 'La Bresse'}, '3332923':{'en': 'Remiremont', 'fr': 'Remiremont'}, '3332922':{'en': 'Remiremont', 'fr': 'Remiremont'}, '3324316':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324314':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3332929':{'en': u('\u00c9pinal'), 'fr': u('\u00c9pinal')}, '37422299':{'am': u('\u053f\u0578\u057f\u0561\u0575\u0584'), 'en': 'Kotayk', 'ru': u('\u041a\u043e\u0442\u0430\u0439\u043a')}, '435514':{'de': 'Bezau', 'en': 'Bezau'}, '435515':{'de': 'Au', 'en': 'Au'}, '435516':{'de': 'Doren', 'en': 'Doren'}, '37422294':{'am': u('\u0531\u0580\u0566\u0576\u056b'), 'en': 'Arzni', 'ru': u('\u0410\u0440\u0437\u043d\u0438')}, '373258':{'en': 'Telenesti', 'ro': u('Telene\u015fti'), 'ru': u('\u0422\u0435\u043b\u0435\u043d\u0435\u0448\u0442\u044c')}, '373259':{'en': 'Falesti', 'ro': u('F\u0103le\u015fti'), 'ru': u('\u0424\u044d\u043b\u0435\u0448\u0442\u044c')}, '435512':{'de': 'Egg', 'en': 'Egg'}, '435513':{'de': 'Hittisau', 'en': 'Hittisau'}, '373254':{'en': 'Rezina', 'ro': 'Rezina', 'ru': u('\u0420\u0435\u0437\u0438\u043d\u0430')}, '373256':{'en': 'Riscani', 'ro': u('R\u00ee\u015fcani'), 'ru': u('\u0420\u044b\u0448\u043a\u0430\u043d\u044c')}, '373250':{'en': 'Floresti', 'ro': u('Flore\u015fti'), 'ru': u('\u0424\u043b\u043e\u0440\u0435\u0448\u0442\u044c')}, '373251':{'en': 'Donduseni', 'ro': u('Dondu\u015feni'), 'ru': u('\u0414\u043e\u043d\u0434\u0443\u0448\u0435\u043d\u044c')}, '373252':{'en': 'Drochia', 'ro': 'Drochia', 'ru': u('\u0414\u0440\u043e\u043a\u0438\u044f')}, '37422291':{'am': u('\u0532\u0561\u056c\u0561\u0570\u0578\u057e\u056b\u057f/\u053f\u0561\u0574\u0561\u0580\u056b\u057d'), 'en': 'Balahovit/Kamaris', 'ru': u('\u0411\u0430\u043b\u0430\u043e\u0432\u0438\u0442/\u041a\u0430\u043c\u0430\u0440\u0438\u0441')}, '37422290':{'am': u('\u0544\u0561\u0575\u0561\u056f\u0578\u057e\u057d\u056f\u056b'), 'en': 'Mayakovsky', 'ru': u('\u041c\u0430\u044f\u043a\u043e\u0432\u0441\u043a\u0438\u0439')}, '35953234':{'bg': u('\u0417\u043b\u0430\u0442\u043d\u0430 \u043d\u0438\u0432\u0430'), 'en': 'Zlatna niva'}, '40364':{'en': 'Cluj', 'ro': 'Cluj'}, '40365':{'en': u('Mure\u0219'), 'ro': u('Mure\u0219')}, '40366':{'en': 'Harghita', 'ro': 'Harghita'}, '432624':{'de': 'Ebenfurth', 'en': 'Ebenfurth'}, '432623':{'de': 'Pottendorf', 'en': 'Pottendorf'}, '3316980':{'en': u('Montlh\u00e9ry'), 'fr': u('Montlh\u00e9ry')}, '35960388':{'bg': u('\u0413\u043e\u0440\u0438\u0446\u0430, \u0422\u044a\u0440\u0433.'), 'en': 'Goritsa, Targ.'}, '432622':{'de': 'Wiener Neustadt', 'en': 'Wiener Neustadt'}, '35960389':{'bg': u('\u041a\u0430\u0440\u0434\u0430\u043c, \u0422\u044a\u0440\u0433.'), 'en': 'Kardam, Targ.'}, '432621':{'de': 'Sieggraben', 'en': 'Sieggraben'}, '3329848':{'en': u('Ploudalm\u00e9zeau'), 'fr': u('Ploudalm\u00e9zeau')}, '432620':{'de': 'Willendorf', 'en': 'Willendorf'}, '35961305':{'bg': u('\u041b\u0435\u0441\u0438\u0447\u0435\u0440\u0438'), 'en': 'Lesicheri'}, '35961304':{'bg': u('\u0414\u0438\u043c\u0447\u0430'), 'en': 'Dimcha'}, '35961307':{'bg': u('\u0421\u0442\u0430\u043c\u0431\u043e\u043b\u043e\u0432\u043e, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Stambolovo, V. Tarnovo'}, '35961306':{'bg': u('\u041f\u0430\u0442\u0440\u0435\u0448'), 'en': 'Patresh'}, '35961301':{'bg': u('\u0411\u044f\u043b\u0430 \u0440\u0435\u043a\u0430, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Byala reka, V. Tarnovo'}, '35961303':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u041b\u0438\u043f\u043d\u0438\u0446\u0430'), 'en': 'Gorna Lipnitsa'}, '35961302':{'bg': u('\u0411\u0430\u0442\u0430\u043a, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Batak, V. Tarnovo'}, '35961309':{'bg': u('\u0413\u043e\u0440\u0441\u043a\u043e \u041a\u0430\u043b\u0443\u0433\u0435\u0440\u043e\u0432\u043e'), 'en': 'Gorsko Kalugerovo'}, '35961308':{'bg': u('\u0412\u0438\u0448\u043e\u0432\u0433\u0440\u0430\u0434'), 'en': 'Vishovgrad'}, '3347373':{'en': 'Lezoux', 'fr': 'Lezoux'}, '3347377':{'en': 'Cournon-d\'Auvergne', 'fr': 'Cournon-d\'Auvergne'}, '3347374':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '3596534':{'bg': u('\u041c\u0430\u043b\u0447\u0438\u043a\u0430'), 'en': 'Malchika'}, '3596535':{'bg': u('\u041a\u043e\u0437\u0430\u0440 \u0411\u0435\u043b\u0435\u043d\u0435'), 'en': 'Kozar Belene'}, '3596536':{'bg': u('\u0410\u0441\u043f\u0430\u0440\u0443\u0445\u043e\u0432\u043e, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Asparuhovo, Pleven'}, '3596537':{'bg': u('\u0410\u0441\u0435\u043d\u043e\u0432\u0446\u0438'), 'en': 'Asenovtsi'}, '3596530':{'bg': u('\u0422\u0440\u044a\u043d\u0447\u043e\u0432\u0438\u0446\u0430'), 'en': 'Tranchovitsa'}, '3596531':{'bg': u('\u0418\u0437\u0433\u0440\u0435\u0432, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Izgrev, Pleven'}, '3596532':{'bg': u('\u0411\u044a\u043b\u0433\u0430\u0440\u0435\u043d\u0435, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Balgarene, Pleven'}, '3596533':{'bg': u('\u0421\u0442\u0435\u0436\u0435\u0440\u043e\u0432\u043e'), 'en': 'Stezherovo'}, '37428794':{'am': u('\u0533\u0576\u0564\u0565\u057e\u0561\u0566'), 'en': 'Gndevaz', 'ru': u('\u0413\u043d\u0434\u0435\u0432\u0430\u0437')}, '3596538':{'bg': u('\u041e\u0431\u043d\u043e\u0432\u0430'), 'en': 'Obnova'}, '3596539':{'bg': u('\u0413\u0440\u0430\u0434\u0438\u0449\u0435, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Gradishte, Pleven'}, '4619':{'en': u('\u00d6rebro-Kumla'), 'sv': u('\u00d6rebro-Kumla')}, '4618':{'en': 'Uppsala', 'sv': 'Uppsala'}, '4611':{'en': u('Norrk\u00f6ping'), 'sv': u('Norrk\u00f6ping')}, '4613':{'en': u('Link\u00f6ping'), 'sv': u('Link\u00f6ping')}, '4616':{'en': u('Eskilstuna-Torsh\u00e4lla'), 'sv': u('Eskilstuna-Torsh\u00e4lla')}, '3329844':{'en': 'Brest', 'fr': 'Brest'}, '437562':{'de': 'Windischgarsten', 'en': 'Windischgarsten'}, '3595559':{'bg': u('\u041a\u0443\u0431\u0430\u0434\u0438\u043d'), 'en': 'Kubadin'}, '3595558':{'bg': u('\u0414\u0435\u0431\u0435\u043b\u0442'), 'en': 'Debelt'}, '3347952':{'en': 'Aix-les-Bains', 'fr': 'Aix-les-Bains'}, '3329691':{'en': 'Perros-Guirec', 'fr': 'Perros-Guirec'}, '3329692':{'en': u('Tr\u00e9guier'), 'fr': u('Tr\u00e9guier')}, '3329695':{'en': 'Pontrieux', 'fr': 'Pontrieux'}, '3329694':{'en': 'Saint-Brieuc', 'fr': 'Saint-Brieuc'}, '3323208':{'en': 'Rouen', 'fr': 'Rouen'}, '3323209':{'en': 'Louviers', 'fr': 'Louviers'}, '3349620':{'en': 'Marseille', 'fr': 'Marseille'}, '3347665':{'en': 'Voiron', 'fr': 'Voiron'}, '441782':{'en': 'Stoke-on-Trent'}, '3347666':{'en': 'Entre-Deux-Guiers', 'fr': 'Entre-Deux-Guiers'}, '3597110':{'bg': u('\u041e\u043f\u0438\u0446\u0432\u0435\u0442'), 'en': 'Opitsvet'}, '3343703':{'en': 'Bourgoin-Jallieu', 'fr': 'Bourgoin-Jallieu'}, '3343702':{'en': 'Vienne', 'fr': 'Vienne'}, '3597117':{'bg': u('\u0413\u0440\u0430\u0434\u0435\u0446, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Gradets, Sofia'}, '3597116':{'bg': u('\u041f\u0435\u0442\u044a\u0440\u0447'), 'en': 'Petarch'}, '3597119':{'bg': u('\u0414\u0440\u044a\u043c\u0448\u0430'), 'en': 'Dramsha'}, '3597118':{'bg': u('\u0414\u0440\u0430\u0433\u043e\u0432\u0438\u0449\u0438\u0446\u0430, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Dragovishtitsa, Sofia'}, '3347845':{'en': 'Vaugneray', 'fr': 'Vaugneray'}, '3347662':{'en': u('Saint-Martin-d\'H\u00e8res'), 'fr': u('Saint-Martin-d\'H\u00e8res')}, '3742570':{'am': u('\u053e\u0561\u0572\u056f\u0561\u0570\u0578\u057e\u056b\u057f'), 'en': 'Tsakhkahovit region', 'ru': u('\u0426\u0430\u0445\u043a\u0430\u0445\u043e\u0432\u0438\u0442')}, '441236':{'en': 'Coatbridge'}, '441237':{'en': 'Bideford'}, '441234':{'en': 'Bedford'}, '3347663':{'en': 'Grenoble', 'fr': 'Grenoble'}, '441233':{'en': 'Ashford (Kent)'}, '437566':{'de': u('Rosenau am Hengstpa\u00df'), 'en': 'Rosenau am Hengstpass'}, '3326258':{'en': u('Saint-Andr\u00e9'), 'fr': u('Saint-Andr\u00e9')}, '3326259':{'en': 'Le Tampon', 'fr': 'Le Tampon'}, '3326254':{'en': 'Saint-Leu', 'fr': 'Saint-Leu'}, '3326255':{'en': 'Saint-Paul', 'fr': 'Saint-Paul'}, '3326256':{'en': 'Saint-Joseph', 'fr': 'Saint-Joseph'}, '3326257':{'en': 'Le Tampon', 'fr': 'Le Tampon'}, '3326250':{'en': u('Saint-Beno\u00eet'), 'fr': u('Saint-Beno\u00eet')}, '3326251':{'en': u('Saint-Beno\u00eet'), 'fr': u('Saint-Beno\u00eet')}, '3326252':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326253':{'en': 'Sainte-Marie', 'fr': 'Sainte-Marie'}, '437565':{'de': 'Sankt Pankraz', 'en': 'St. Pankraz'}, '437763':{'de': 'Kopfing im Innkreis', 'en': 'Kopfing im Innkreis'}, '437762':{'de': 'Raab', 'en': 'Raab'}, '437765':{'de': 'Lambrechten', 'en': 'Lambrechten'}, '3332719':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '3332248':{'en': 'Corbie', 'fr': 'Corbie'}, '3332249':{'en': 'Camon', 'fr': 'Camon'}, '3332246':{'en': 'Amiens', 'fr': 'Amiens'}, '3332247':{'en': 'Amiens', 'fr': 'Amiens'}, '3332244':{'en': 'Amiens', 'fr': 'Amiens'}, '3332245':{'en': 'Amiens', 'fr': 'Amiens'}, '3332243':{'en': 'Amiens', 'fr': 'Amiens'}, '3332241':{'en': 'Ailly-sur-Noye', 'fr': 'Ailly-sur-Noye'}, '35963564':{'bg': u('\u0411\u0438\u0432\u043e\u043b\u0430\u0440\u0435'), 'en': 'Bivolare'}, '3329843':{'en': 'Brest', 'fr': 'Brest'}, '437588':{'de': 'Ried im Traunkreis', 'en': 'Ried im Traunkreis'}, '3324020':{'en': 'Nantes', 'fr': 'Nantes'}, '437585':{'de': 'Klaus an der Pyhrnbahn', 'en': 'Klaus an der Pyhrnbahn'}, '437584':{'de': 'Molln', 'en': 'Molln'}, '437587':{'de': 'Wartberg an der Krems', 'en': 'Wartberg an der Krems'}, '437586':{'de': 'Pettenbach', 'en': 'Pettenbach'}, '3352436':{'en': 'Pau', 'fr': 'Pau'}, '437583':{'de': u('Kremsm\u00fcnster'), 'en': u('Kremsm\u00fcnster')}, '437582':{'de': 'Kirchdorf an der Krems', 'en': 'Kirchdorf an der Krems'}, '3324022':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '3338055':{'en': 'Dijon', 'fr': 'Dijon'}, '3338054':{'en': 'Dijon', 'fr': 'Dijon'}, '3324027':{'en': 'Saint-Brevin-les-Pins', 'fr': 'Saint-Brevin-les-Pins'}, '3593054':{'bg': u('\u041f\u043e\u0434\u0432\u0438\u0441, \u0421\u043c\u043e\u043b.'), 'en': 'Podvis, Smol.'}, '3593055':{'bg': u('\u0415\u043b\u0445\u043e\u0432\u0435\u0446'), 'en': 'Elhovets'}, '3593056':{'bg': u('\u0427\u0435\u043f\u0438\u043d\u0446\u0438, \u0421\u043c\u043e\u043b.'), 'en': 'Chepintsi, Smol.'}, '3593057':{'bg': u('\u041f\u043b\u043e\u0432\u0434\u0438\u0432\u0446\u0438'), 'en': 'Plovdivtsi'}, '3593050':{'bg': u('\u0411\u0443\u043a\u043e\u0432\u0430 \u043f\u043e\u043b\u044f\u043d\u0430'), 'en': 'Bukova polyana'}, '3593051':{'bg': u('\u0427\u0435\u043f\u0435\u043b\u0430\u0440\u0435'), 'en': 'Chepelare'}, '3593052':{'bg': u('\u041b\u044a\u043a\u0438, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Laki, Plovdiv'}, '3593053':{'bg': u('\u0425\u0432\u043e\u0439\u043d\u0430'), 'en': 'Hvoyna'}, '3593058':{'bg': u('\u041c\u0443\u0433\u043b\u0430'), 'en': 'Mugla'}, '3593059':{'bg': u('\u041a\u0443\u0442\u0435\u043b\u0430'), 'en': 'Kutela'}, '3599548':{'bg': u('\u041a\u0440\u0430\u043f\u0447\u0435\u043d\u0435'), 'en': 'Krapchene'}, '3599549':{'bg': u('\u0414\u043e\u043b\u043d\u0430 \u0420\u0438\u043a\u0441\u0430'), 'en': 'Dolna Riksa'}, '3599544':{'bg': u('\u0421\u0442\u0443\u0434\u0435\u043d\u043e \u0431\u0443\u0447\u0435'), 'en': 'Studeno buche'}, '3599545':{'bg': u('\u0413\u0430\u0431\u0440\u043e\u0432\u043d\u0438\u0446\u0430'), 'en': 'Gabrovnitsa'}, '3599546':{'bg': u('\u0421\u043b\u0430\u0432\u043e\u0442\u0438\u043d'), 'en': 'Slavotin'}, '35963568':{'bg': u('\u0411\u0443\u043a\u043e\u0432\u043b\u044a\u043a'), 'en': 'Bukovlak'}, '3599540':{'bg': u('\u0411\u0435\u043b\u043e\u0442\u0438\u043d\u0446\u0438'), 'en': 'Belotintsi'}, '3599541':{'bg': u('\u0414\u043e\u043a\u0442\u043e\u0440 \u0419\u043e\u0441\u0438\u0444\u043e\u0432\u043e'), 'en': 'Doktor Yosifovo'}, '3599542':{'bg': u('\u0421\u043c\u043e\u043b\u044f\u043d\u043e\u0432\u0446\u0438'), 'en': 'Smolyanovtsi'}, '370448':{'en': u('Plung\u0117')}, '370449':{'en': u('\u0160ilal\u0117')}, '434238':{'de': 'Eisenkappel-Vellach', 'en': 'Eisenkappel-Vellach'}, '434239':{'de': 'Sankt Kanzian am Klopeiner See', 'en': 'St. Kanzian am Klopeiner See'}, '370440':{'en': 'Skuodas'}, '370441':{'en': u('\u0160ilut\u0117')}, '434234':{'de': 'Ruden', 'en': 'Ruden'}, '370443':{'en': u('Ma\u017eeikiai')}, '370444':{'en': u('Tel\u0161iai')}, '370445':{'en': 'Kretinga'}, '370446':{'en': u('Taurag\u0117')}, '370447':{'en': 'Jurbarkas'}, '3324780':{'en': u('Jou\u00e9-l\u00e8s-Tours'), 'fr': u('Jou\u00e9-l\u00e8s-Tours')}, '3356175':{'en': 'Ramonville-Saint-Agne', 'fr': 'Ramonville-Saint-Agne'}, '3356172':{'en': 'Portet-sur-Garonne', 'fr': 'Portet-sur-Garonne'}, '3356173':{'en': 'Ramonville-Saint-Agne', 'fr': 'Ramonville-Saint-Agne'}, '3356170':{'en': 'Aucamville', 'fr': 'Aucamville'}, '3356171':{'en': 'Blagnac', 'fr': 'Blagnac'}, '3324788':{'en': 'Tours', 'fr': 'Tours'}, '3356178':{'en': 'Colomiers', 'fr': 'Colomiers'}, '3356179':{'en': u('Bagn\u00e8res-de-Luchon'), 'fr': u('Bagn\u00e8res-de-Luchon')}, '359373':{'bg': u('\u0425\u0430\u0440\u043c\u0430\u043d\u043b\u0438'), 'en': 'Harmanli'}, '359379':{'bg': u('\u0421\u0432\u0438\u043b\u0435\u043d\u0433\u0440\u0430\u0434'), 'en': 'Svilengrad'}, '3356351':{'en': 'Castres', 'fr': 'Castres'}, '3356357':{'en': 'Gaillac', 'fr': 'Gaillac'}, '3356354':{'en': 'Albi', 'fr': 'Albi'}, '3356358':{'en': 'Lavaur', 'fr': 'Lavaur'}, '3356359':{'en': 'Castres', 'fr': 'Castres'}, '3343280':{'en': u('Boll\u00e8ne'), 'fr': u('Boll\u00e8ne')}, '3343281':{'en': 'Orange', 'fr': 'Orange'}, '3902':{'en': 'Milan', 'it': 'Milano'}, '3343285':{'en': 'Carpentras', 'fr': 'Carpentras'}, '37432298':{'am': u('\u053c\u0565\u0580\u0574\u0578\u0576\u057f\u0578\u057e\u0578'), 'en': 'Lermontovo', 'ru': u('\u041b\u0435\u0440\u043c\u043e\u043d\u0442\u043e\u0432\u043e')}, '37432299':{'am': u('\u054e\u0561\u0570\u0561\u0563\u0576\u056b'), 'en': 'Vahagni', 'ru': u('\u0412\u0430\u0430\u0433\u043d\u0438')}, '37432296':{'am': u('\u0544\u0561\u0580\u0563\u0561\u0570\u0578\u057e\u056b\u057f'), 'en': 'Margahovit', 'ru': u('\u041c\u0430\u0440\u0433\u0430\u043e\u0432\u0438\u0442')}, '37432297':{'am': u('\u0541\u0578\u0580\u0561\u0563\u0565\u057f'), 'en': 'Dzoraget', 'ru': u('\u0414\u0437\u043e\u0440\u0430\u0433\u0435\u0442')}, '37432294':{'am': u('\u053c\u0565\u057c\u0576\u0561\u057a\u0561\u057f'), 'en': 'Lernapat', 'ru': u('\u041b\u0435\u0440\u043d\u0430\u043f\u0430\u0442')}, '37432295':{'am': u('\u0535\u0572\u0565\u0563\u0576\u0578\u0582\u057f'), 'en': 'Yeghegnut', 'ru': u('\u0415\u0445\u0435\u0433\u043d\u0443\u0442')}, '37432293':{'am': u('\u0553\u0561\u0574\u0562\u0561\u056f'), 'en': 'Pambak', 'ru': u('\u041f\u0430\u043c\u0431\u0430\u043a')}, '3346700':{'en': 'Agde', 'fr': 'Agde'}, '3324125':{'en': 'Angers', 'fr': 'Angers'}, '3346702':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3324127':{'en': 'Angers', 'fr': 'Angers'}, '3346704':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346706':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346707':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346709':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3332994':{'en': u('Neufch\u00e2teau'), 'fr': u('Neufch\u00e2teau')}, '35247':{'de': 'Lintgen', 'en': 'Lintgen', 'fr': 'Lintgen'}, '35245':{'de': 'Diedrich', 'en': 'Diedrich', 'fr': 'Diedrich'}, '35243':{'de': 'Findel/Kirchberg', 'en': 'Findel/Kirchberg', 'fr': 'Findel/Kirchberg'}, '35242':{'de': 'Plateau de Kirchberg', 'en': 'Plateau de Kirchberg', 'fr': 'Plateau de Kirchberg'}, '35240':{'de': 'Howald', 'en': 'Howald', 'fr': 'Howald'}, '39041':{'en': 'Venice', 'it': 'Venezia'}, '3332992':{'en': 'Commercy', 'fr': 'Commercy'}, '39045':{'en': 'Verona', 'it': 'Verona'}, '35249':{'de': 'Howald', 'en': 'Howald', 'fr': 'Howald'}, '35248':{'de': 'Contern/Foetz', 'en': 'Contern/Foetz', 'fr': 'Contern/Foetz'}, '3347031':{'en': 'Vichy', 'fr': 'Vichy'}, '3347030':{'en': 'Vichy', 'fr': 'Vichy'}, '3347032':{'en': 'Bellerive-sur-Allier', 'fr': 'Bellerive-sur-Allier'}, '3347035':{'en': 'Moulins', 'fr': 'Moulins'}, '3347034':{'en': 'Dompierre-sur-Besbre', 'fr': 'Dompierre-sur-Besbre'}, '3343067':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3332991':{'en': 'Commercy', 'fr': 'Commercy'}, '35965165':{'bg': u('\u041f\u0438\u0441\u0430\u0440\u043e\u0432\u043e, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Pisarovo, Pleven'}, '3338628':{'en': 'Cosne-Cours-sur-Loire', 'fr': 'Cosne-Cours-sur-Loire'}, '3338626':{'en': 'Cosne-Cours-sur-Loire', 'fr': 'Cosne-Cours-sur-Loire'}, '3338627':{'en': 'Clamecy', 'fr': 'Clamecy'}, '3338624':{'en': 'Clamecy', 'fr': 'Clamecy'}, '3338625':{'en': 'Decize', 'fr': 'Decize'}, '3338622':{'en': 'Lormes', 'fr': 'Lormes'}, '3338623':{'en': 'Nevers', 'fr': 'Nevers'}, '3338620':{'en': 'Corbigny', 'fr': 'Corbigny'}, '3338621':{'en': 'Nevers', 'fr': 'Nevers'}, '3338317':{'en': 'Nancy', 'fr': 'Nancy'}, '437283':{'de': 'Sarleinsbach', 'en': 'Sarleinsbach'}, '3338723':{'en': 'Sarrebourg', 'fr': 'Sarrebourg'}, '3338721':{'en': 'Metz', 'fr': 'Metz'}, '3338720':{'en': 'Metz', 'fr': 'Metz'}, '3338727':{'en': 'Sarreguemines', 'fr': 'Sarreguemines'}, '3659':{'en': 'Karcag', 'hu': 'Karcag'}, '3338724':{'en': 'Phalsbourg', 'fr': 'Phalsbourg'}, '3654':{'en': 'Berettyoujfalu', 'hu': u('Beretty\u00f3\u00fajfalu')}, '3338729':{'en': 'Saint-Avold', 'fr': 'Saint-Avold'}, '3338728':{'en': 'Sarreguemines', 'fr': 'Sarreguemines'}, '3652':{'en': 'Debrecen', 'hu': 'Debrecen'}, '3653':{'en': 'Cegled', 'hu': u('Cegl\u00e9d')}, '432278':{'de': 'Absdorf', 'en': 'Absdorf'}, '3334448':{'en': 'Beauvais', 'fr': 'Beauvais'}, '432279':{'de': 'Kirchberg am Wagram', 'en': 'Kirchberg am Wagram'}, '3334449':{'en': 'Chaumont-en-Vexin', 'fr': 'Chaumont-en-Vexin'}, '3324058':{'en': 'Nantes', 'fr': 'Nantes'}, '3598696':{'bg': u('\u0421\u0443\u0445\u043e\u0434\u043e\u043b, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Suhodol, Silistra'}, '3598695':{'bg': u('\u041d\u043e\u0436\u0430\u0440\u0435\u0432\u043e'), 'en': 'Nozharevo'}, '3598694':{'bg': u('\u0417\u0435\u0431\u0438\u043b'), 'en': 'Zebil'}, '437281':{'de': u('Aigen im M\u00fchlkreis'), 'en': u('Aigen im M\u00fchlkreis')}, '3347642':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3328552':{'en': 'Nantes', 'fr': 'Nantes'}, '3324188':{'en': 'Angers', 'fr': 'Angers'}, '3338319':{'en': 'Nancy', 'fr': 'Nancy'}, '441786':{'en': 'Stirling'}, '432276':{'de': 'Reidling', 'en': 'Reidling'}, '432277':{'de': 'Zwentendorf', 'en': 'Zwentendorf'}, '433588':{'de': 'Katsch an der Mur', 'en': 'Katsch an der Mur'}, '46253':{'en': u('Idre-S\u00e4rna'), 'sv': u('Idre-S\u00e4rna')}, '437758':{'de': 'Obernberg am Inn', 'en': 'Obernberg am Inn'}, '3329913':{'en': 'Melesse', 'fr': 'Melesse'}, '3332013':{'en': 'Lille', 'fr': 'Lille'}, '3332012':{'en': 'Lille', 'fr': 'Lille'}, '3332011':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '3332017':{'en': 'Lille', 'fr': 'Lille'}, '3332015':{'en': 'Lille', 'fr': 'Lille'}, '3332014':{'en': 'Lille', 'fr': 'Lille'}, '3332019':{'en': 'Villeneuve-d\'Ascq', 'fr': 'Villeneuve-d\'Ascq'}, '3332018':{'en': 'Lille', 'fr': 'Lille'}, '3354606':{'en': 'Royan', 'fr': 'Royan'}, '3354607':{'en': u('Surg\u00e8res'), 'fr': u('Surg\u00e8res')}, '3354605':{'en': 'Royan', 'fr': 'Royan'}, '3354602':{'en': 'Saujon', 'fr': 'Saujon'}, '3354600':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '437755':{'de': 'Mettmach', 'en': 'Mettmach'}, '432271':{'de': 'Ried am Riederberg', 'en': 'Ried am Riederberg'}, '432272':{'de': 'Tulln an der Donau', 'en': 'Tulln an der Donau'}, '432273':{'de': 'Tulbing', 'en': 'Tulbing'}, '432274':{'de': 'Sieghartskirchen', 'en': 'Sieghartskirchen'}, '432275':{'de': 'Atzenbrugg', 'en': 'Atzenbrugg'}, '3354608':{'en': 'Royan', 'fr': 'Royan'}, '3354609':{'en': u('Saint-Martin-de-R\u00e9'), 'fr': u('Saint-Martin-de-R\u00e9')}, '3329916':{'en': 'Dinard', 'fr': 'Dinard'}, '3329917':{'en': u('Foug\u00e8res'), 'fr': u('Foug\u00e8res')}, '3329914':{'en': 'Rennes', 'fr': 'Rennes'}, '433582':{'de': 'Scheifling', 'en': 'Scheifling'}, '35941178':{'bg': u('\u041e\u0440\u044f\u0445\u043e\u0432\u0438\u0446\u0430, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Oryahovitsa, St. Zagora'}, '3355806':{'en': 'Mont-de-Marsan', 'fr': 'Mont-de-Marsan'}, '3355805':{'en': 'Mont-de-Marsan', 'fr': 'Mont-de-Marsan'}, '35941174':{'bg': u('\u041f\u043e\u0434\u0441\u043b\u043e\u043d, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Podslon, St. Zagora'}, '35941175':{'bg': u('\u041a\u043e\u043b\u0435\u043d\u0430'), 'en': 'Kolena'}, '3355809':{'en': 'Mimizan', 'fr': 'Mimizan'}, '3355808':{'en': 'Pissos', 'fr': 'Pissos'}, '433585':{'de': 'Sankt Lambrecht', 'en': 'St. Lambrecht'}, '35941171':{'bg': u('\u0414\u044a\u043b\u0431\u043e\u043a\u0438'), 'en': 'Dalboki'}, '3329918':{'en': u('Saint-Brice-en-Cogl\u00e8s'), 'fr': u('Saint-Brice-en-Cogl\u00e8s')}, '3325065':{'en': 'Caen', 'fr': 'Caen'}, '3323549':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323548':{'en': 'Le Havre', 'fr': 'Le Havre'}, '35941172':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u0411\u043e\u0442\u0435\u0432\u043e'), 'en': 'Gorno Botevo'}, '3323543':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323542':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323541':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323540':{'en': 'Dieppe', 'fr': 'Dieppe'}, '3323547':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323546':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323545':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3323544':{'en': 'Le Havre', 'fr': 'Le Havre'}, '3349479':{'en': 'Ramatuelle', 'fr': 'Ramatuelle'}, '3349478':{'en': 'Saint-Maximin-la-Sainte-Baume', 'fr': 'Saint-Maximin-la-Sainte-Baume'}, '3349473':{'en': 'Vidauban', 'fr': 'Vidauban'}, '3349471':{'en': 'Bormes-les-Mimosas', 'fr': 'Bormes-les-Mimosas'}, '3349477':{'en': 'Barjols', 'fr': 'Barjols'}, '3349476':{'en': 'Fayence', 'fr': 'Fayence'}, '3349475':{'en': 'La Garde', 'fr': 'La Garde'}, '3349474':{'en': 'Sanary-sur-Mer', 'fr': 'Sanary-sur-Mer'}, '441913':{'en': 'Durham'}, '441912':{'en': 'Tyneside'}, '441911':{'en': 'Tyneside/Durham/Sunderland'}, '434231':{'de': 'Mittertrixen', 'en': 'Mittertrixen'}, '441917':{'en': 'Sunderland'}, '441916':{'en': 'Tyneside'}, '441915':{'en': 'Sunderland'}, '441914':{'en': 'Tyneside'}, '3322940':{'en': 'Briec', 'fr': 'Briec'}, '441919':{'en': 'Durham'}, '441918':{'en': 'Tyneside'}, '3355730':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355732':{'en': 'Saint-Ciers-sur-Gironde', 'fr': 'Saint-Ciers-sur-Gironde'}, '3355735':{'en': u('B\u00e8gles'), 'fr': u('B\u00e8gles')}, '3355734':{'en': 'Tresses', 'fr': 'Tresses'}, '3347769':{'en': 'Charlieu', 'fr': 'Charlieu'}, '34928':{'en': 'Las Palmas', 'es': 'Las Palmas'}, '335495':{'en': 'Poitiers', 'fr': 'Poitiers'}, '432988':{'de': u('Neup\u00f6lla'), 'en': u('Neup\u00f6lla')}, '432989':{'de': 'Brunn an der Wild', 'en': 'Brunn an der Wild'}, '432982':{'de': 'Horn', 'en': 'Horn'}, '432983':{'de': 'Sigmundsherberg', 'en': 'Sigmundsherberg'}, '432986':{'de': 'Irnfritz', 'en': 'Irnfritz'}, '432987':{'de': 'Sankt Leonhard am Hornerwald', 'en': 'St. Leonhard am Hornerwald'}, '432984':{'de': 'Eggenburg', 'en': 'Eggenburg'}, '432985':{'de': 'Gars am Kamp', 'en': 'Gars am Kamp'}, '3317348':{'en': 'Boulogne-Billancourt', 'fr': 'Boulogne-Billancourt'}, '4417689':{'en': 'Penrith'}, '359938':{'bg': u('\u041a\u0443\u043b\u0430'), 'en': 'Kula'}, '3318372':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3324339':{'en': 'Le Mans', 'fr': 'Le Mans'}, '437247':{'de': 'Kematen am Innbach', 'en': 'Kematen am Innbach'}, '437244':{'de': 'Sattledt', 'en': 'Sattledt'}, '437245':{'de': 'Lambach', 'en': 'Lambach'}, '437242':{'de': 'Wels', 'en': 'Wels'}, '437243':{'de': 'Marchtrenk', 'en': 'Marchtrenk'}, '437240':{'de': 'Sipbachzell', 'en': 'Sipbachzell'}, '437241':{'de': 'Steinerkirchen an der Traun', 'en': 'Steinerkirchen an der Traun'}, '3324330':{'en': 'Mayenne', 'fr': 'Mayenne'}, '3324332':{'en': 'Mayenne', 'fr': 'Mayenne'}, '437224':{'de': 'Sankt Florian', 'en': 'St. Florian'}, '4417687':{'en': 'Keswick'}, '437248':{'de': 'Grieskirchen', 'en': 'Grieskirchen'}, '437249':{'de': 'Bad Schallerbach', 'en': 'Bad Schallerbach'}, '4417686':{'en': 'Penrith'}, '381280':{'en': 'Gnjilane', 'sr': 'Gnjilane'}, '373215':{'en': 'Dubasari', 'ro': u('Dub\u0103sari'), 'ru': u('\u0414\u0443\u0431\u044d\u0441\u0430\u0440\u044c')}, '433633':{'de': 'Landl', 'en': 'Landl'}, '433632':{'de': 'Sankt Gallen', 'en': 'St. Gallen'}, '433631':{'de': 'Unterlaussa', 'en': 'Unterlaussa'}, '433637':{'de': 'Gams bei Hieflau', 'en': 'Gams bei Hieflau'}, '433636':{'de': 'Wildalpen', 'en': 'Wildalpen'}, '433635':{'de': 'Radmer', 'en': 'Radmer'}, '433634':{'de': 'Hieflau', 'en': 'Hieflau'}, '437225':{'de': 'Hargelsberg', 'en': 'Hargelsberg'}, '433638':{'de': 'Palfau', 'en': 'Palfau'}, '35981886':{'bg': u('\u0427\u0435\u0440\u0435\u0448\u043e\u0432\u043e, \u0420\u0443\u0441\u0435'), 'en': 'Chereshovo, Ruse'}, '374223':{'am': u('\u0540\u0561\u0576\u0584\u0561\u057e\u0561\u0576/\u0540\u0580\u0561\u0566\u0564\u0561\u0576/\u053e\u0561\u0572\u056f\u0561\u0571\u0578\u0580'), 'en': 'Hankavan/Hrazdan/Tsakhkadzor', 'ru': u('\u0410\u043d\u043a\u0430\u0432\u0430\u043d/\u0420\u0430\u0437\u0434\u0430\u043d/\u0426\u0430\u0445\u043a\u0430\u0434\u0437\u043e\u0440')}, '374224':{'am': u('\u0554\u0561\u0576\u0561\u0584\u0565\u057c\u0561\u057e\u0561\u0576/\u0546\u0578\u0580 \u0533\u0565\u0572\u056b/\u0546\u0578\u0580 \u0540\u0561\u0573\u0568\u0576/\u0535\u0572\u057e\u0561\u0580\u0564'), 'en': 'Kanakeravan/Nor Geghi/Nor Hajn/Yeghvard', 'ru': u('\u041a\u0430\u043d\u0430\u043a\u0435\u0440\u0430\u0432\u0430\u043d/\u041d\u043e\u0440 \u0413\u0435\u0445\u0438/\u041d\u043e\u0440 \u0410\u0447\u043d/\u0415\u0433\u0432\u0430\u0440\u0434')}, '374226':{'am': u('\u0549\u0561\u0580\u0565\u0576\u0581\u0561\u057e\u0561\u0576'), 'en': 'Charentsavan', 'ru': u('\u0427\u0430\u0440\u0435\u043d\u0446\u0430\u0432\u0430\u043d')}, '35993342':{'bg': u('\u041a\u0438\u0440\u0435\u0435\u0432\u043e'), 'en': 'Kireevo'}, '437226':{'de': 'Wilhering', 'en': 'Wilhering'}, '3356722':{'en': 'Toulouse', 'fr': 'Toulouse'}, '34927':{'en': u('C\u00e1ceres'), 'es': u('C\u00e1ceres')}, '441910':{'en': 'Tyneside/Durham/Sunderland'}, '437227':{'de': 'Neuhofen an der Krems', 'en': 'Neuhofen an der Krems'}, '437221':{'de': u('H\u00f6rsching'), 'en': u('H\u00f6rsching')}, '3596518':{'bg': u('\u0420\u0438\u0431\u0435\u043d'), 'en': 'Riben'}, '3596519':{'bg': u('\u0411\u0435\u0433\u043b\u0435\u0436'), 'en': 'Beglezh'}, '3596516':{'bg': u('\u0418\u0441\u043a\u044a\u0440, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Iskar, Pleven'}, '3596517':{'bg': u('\u041f\u043e\u0434\u0435\u043c'), 'en': 'Podem'}, '3596514':{'bg': u('\u0414\u043e\u043b\u043d\u0438 \u0414\u044a\u0431\u043d\u0438\u043a'), 'en': 'Dolni Dabnik'}, '3596515':{'bg': u('\u0421\u043b\u0430\u0432\u044f\u043d\u043e\u0432\u043e, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Slavyanovo, Pleven'}, '3596512':{'bg': u('\u0413\u043e\u0440\u043d\u0438 \u0414\u044a\u0431\u043d\u0438\u043a'), 'en': 'Gorni Dabnik'}, '3596513':{'bg': u('\u041f\u043e\u0440\u0434\u0438\u043c'), 'en': 'Pordim'}, '3596510':{'bg': u('\u0422\u043e\u0442\u043b\u0435\u0431\u0435\u043d'), 'en': 'Totleben'}, '3596511':{'bg': u('\u041f\u043e\u0431\u0435\u0434\u0430, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Pobeda, Pleven'}, '437223':{'de': 'Enns', 'en': 'Enns'}, '433867':{'de': 'Pernegg an der Mur', 'en': 'Pernegg an der Mur'}, '434852':{'de': 'Lienz', 'en': 'Lienz'}, '434853':{'de': 'Ainet', 'en': 'Ainet'}, '434855':{'de': 'Assling', 'en': 'Assling'}, '434858':{'de': 'Nikolsdorf', 'en': 'Nikolsdorf'}, '3347939':{'en': 'Albertville', 'fr': 'Albertville'}, '37426272':{'am': u('\u053c\u056b\u0573\u0584'), 'en': 'Lichk', 'ru': u('\u041b\u0438\u0447\u043a')}, '3347932':{'en': 'Albertville', 'fr': 'Albertville'}, '3347933':{'en': u('Chamb\u00e9ry'), 'fr': u('Chamb\u00e9ry')}, '3347934':{'en': 'Aix-les-Bains', 'fr': 'Aix-les-Bains'}, '3347935':{'en': 'Aix-les-Bains', 'fr': 'Aix-les-Bains'}, '3347937':{'en': 'Albertville', 'fr': 'Albertville'}, '3316995':{'en': 'Angerville', 'fr': 'Angerville'}, '3316996':{'en': 'Savigny-sur-Orge', 'fr': 'Savigny-sur-Orge'}, '3316990':{'en': 'Mennecy', 'fr': 'Mennecy'}, '3316991':{'en': u('\u00c9vry'), 'fr': u('\u00c9vry')}, '3316992':{'en': u('\u00c9tampes'), 'fr': u('\u00c9tampes')}, '3349222':{'en': u('Brian\u00e7on'), 'fr': u('Brian\u00e7on')}, '390428':{'it': 'Tarvisio'}, '390429':{'it': 'Este'}, '390424':{'en': 'Vicenza', 'it': 'Bassano del Grappa'}, '390425':{'en': 'Rovigo', 'it': 'Rovigo'}, '390426':{'en': 'Rovigo', 'it': 'Adria'}, '390427':{'it': 'Spilimbergo'}, '390932':{'it': 'Ragusa'}, '390421':{'en': 'Venice', 'it': u('San Don\u00e0 di Piave')}, '390422':{'en': 'Treviso', 'it': 'Treviso'}, '390423':{'en': 'Treviso', 'it': 'Montebelluna'}, '3343720':{'en': 'Givors', 'fr': 'Givors'}, '3343723':{'en': 'Lyon', 'fr': 'Lyon'}, '3343722':{'en': 'Craponne', 'fr': 'Craponne'}, '3343725':{'en': 'Saint-Priest', 'fr': 'Saint-Priest'}, '3343724':{'en': 'Lyon', 'fr': 'Lyon'}, '3338785':{'en': 'Forbach', 'fr': 'Forbach'}, '3343728':{'en': 'Lyon', 'fr': 'Lyon'}, '3597177':{'bg': u('\u0410\u043b\u0434\u043e\u043c\u0438\u0440\u043e\u0432\u0446\u0438'), 'en': 'Aldomirovtsi'}, '3597176':{'bg': u('\u0425\u0440\u0430\u0431\u044a\u0440\u0441\u043a\u043e'), 'en': 'Hrabarsko'}, '3597175':{'bg': u('\u0413\u0430\u0431\u0435\u0440'), 'en': 'Gaber'}, '3349227':{'en': 'Saint-Laurent-du-Var', 'fr': 'Saint-Laurent-du-Var'}, '3349224':{'en': 'Saint-Chaffrey', 'fr': 'Saint-Chaffrey'}, '3595123':{'bg': u('\u0420\u0430\u0432\u043d\u0430, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Ravna, Varna'}, '3355675':{'en': 'Gradignan', 'fr': 'Gradignan'}, '390376':{'en': 'Mantua', 'it': 'Mantova'}, '3345099':{'en': 'Divonne-les-Bains', 'fr': 'Divonne-les-Bains'}, '3345098':{'en': 'Cluses', 'fr': 'Cluses'}, '390377':{'it': 'Codogno'}, '3326272':{'en': 'Sainte-Marie', 'fr': 'Sainte-Marie'}, '3326270':{'en': 'Saint-Paul', 'fr': 'Saint-Paul'}, '3326271':{'en': 'Le Port', 'fr': 'Le Port'}, '3345091':{'en': 'Sallanches', 'fr': 'Sallanches'}, '3345090':{'en': u('Ar\u00e2ches-la-Frasse'), 'fr': u('Ar\u00e2ches-la-Frasse')}, '3345093':{'en': 'Saint-Gervais-les-Bains', 'fr': 'Saint-Gervais-les-Bains'}, '3345092':{'en': 'Annemasse', 'fr': 'Annemasse'}, '3345095':{'en': 'Annemasse', 'fr': 'Annemasse'}, '3345094':{'en': 'Douvaine', 'fr': 'Douvaine'}, '3345097':{'en': 'Bonneville', 'fr': 'Bonneville'}, '3345096':{'en': 'Cluses', 'fr': 'Cluses'}, '3317117':{'en': 'Boulogne-Billancourt', 'fr': 'Boulogne-Billancourt'}, '3317119':{'en': 'Paris', 'fr': 'Paris'}, '3317118':{'en': 'Paris', 'fr': 'Paris'}, '3595129':{'bg': u('\u0411\u043b\u044a\u0441\u043a\u043e\u0432\u043e'), 'en': 'Blaskovo'}, '3323223':{'en': u('\u00c9vreux'), 'fr': u('\u00c9vreux')}, '3323220':{'en': 'Pont-Audemer', 'fr': 'Pont-Audemer'}, '3323221':{'en': 'Vernon', 'fr': 'Vernon'}, '3323227':{'en': 'Gisors', 'fr': 'Gisors'}, '3323225':{'en': 'Louviers', 'fr': 'Louviers'}, '3323228':{'en': u('\u00c9vreux'), 'fr': u('\u00c9vreux')}, '3323229':{'en': 'Breteuil sur Iton', 'fr': 'Breteuil sur Iton'}, '437748':{'de': 'Eggelsberg', 'en': 'Eggelsberg'}, '35969032':{'bg': u('\u0411\u044a\u043b\u0433\u0430\u0440\u0441\u043a\u0438 \u0438\u0437\u0432\u043e\u0440'), 'en': 'Balgarski izvor'}, '3332220':{'en': 'Abbeville', 'fr': 'Abbeville'}, '437742':{'de': 'Mattighofen', 'en': 'Mattighofen'}, '3332222':{'en': 'Amiens', 'fr': 'Amiens'}, '3332224':{'en': 'Abbeville', 'fr': 'Abbeville'}, '3332225':{'en': 'Rue', 'fr': 'Rue'}, '3332226':{'en': 'Cayeux-sur-Mer', 'fr': 'Cayeux-sur-Mer'}, '3332227':{'en': 'Le Crotoy', 'fr': 'Le Crotoy'}, '3597043':{'bg': u('\u0413\u043e\u043b\u0435\u043c\u043e \u0441\u0435\u043b\u043e'), 'en': 'Golemo selo'}, '3597042':{'bg': u('\u041a\u043e\u0440\u043a\u0438\u043d\u0430'), 'en': 'Korkina'}, '3593920':{'bg': u('\u0417\u043b\u0430\u0442\u043e\u043f\u043e\u043b\u0435'), 'en': 'Zlatopole'}, '3347985':{'en': u('Chamb\u00e9ry'), 'fr': u('Chamb\u00e9ry')}, '3593922':{'bg': u('\u0411\u0440\u043e\u0434'), 'en': 'Brod'}, '3593691':{'bg': u('\u0427\u0435\u0440\u043d\u043e\u043e\u0447e\u043d\u0435'), 'en': 'Chernoochene'}, '3593696':{'bg': u('\u041f\u0447\u0435\u043b\u0430\u0440\u043e\u0432\u043e, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Pchelarovo, Kardzh.'}, '3593925':{'bg': u('\u041a\u0440\u0443\u043c'), 'en': 'Krum'}, '3593926':{'bg': u('\u0414\u043e\u0431\u0440\u0438\u0447, \u0425\u0430\u0441\u043a.'), 'en': 'Dobrich, Hask.'}, '3347768':{'en': 'Roanne', 'fr': 'Roanne'}, '3593928':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u0411\u0435\u043b\u0435\u0432\u043e'), 'en': 'Dolno Belevo'}, '3593929':{'bg': u('\u0413\u043e\u043b\u044f\u043c\u043e \u0410\u0441\u0435\u043d\u043e\u0432\u043e'), 'en': 'Golyamo Asenovo'}, '3593699':{'bg': u('\u0413\u0430\u0431\u0440\u043e\u0432\u043e, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Gabrovo, Kardzh.'}, '3347981':{'en': 'Belley', 'fr': 'Belley'}, '433833':{'de': 'Traboch', 'en': 'Traboch'}, '3332732':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '3332733':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '3332730':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '3332731':{'en': 'Denain', 'fr': 'Denain'}, '3593076':{'bg': u('\u0426\u0430\u0446\u0430\u0440\u043e\u0432\u0446\u0438'), 'en': 'Tsatsarovtsi'}, '3593077':{'bg': u('\u0421\u0440\u0435\u0434\u0435\u0446, \u0421\u043c\u043e\u043b.'), 'en': 'Sredets, Smol.'}, '3593074':{'bg': u('\u0415\u0440\u043c\u0430 \u0440\u0435\u043a\u0430'), 'en': 'Erma reka'}, '3593075':{'bg': u('\u0414\u043e\u043b\u0435\u043d, \u0421\u043c\u043e\u043b.'), 'en': 'Dolen, Smol.'}, '3593072':{'bg': u('\u041d\u0435\u0434\u0435\u043b\u0438\u043d\u043e'), 'en': 'Nedelino'}, '3593073':{'bg': u('\u0421\u0442\u0430\u0440\u0446\u0435\u0432\u043e'), 'en': 'Startsevo'}, '3332739':{'en': 'Jeumont', 'fr': 'Jeumont'}, '370422':{'en': u('Radvili\u0161kis')}, '370421':{'en': 'Pakruojis'}, '370426':{'en': u('Joni\u0161kis')}, '370427':{'en': u('Kelm\u0117')}, '370425':{'en': u('Akmen\u0117')}, '370428':{'en': 'Raseiniai'}, '3599129':{'bg': u('\u0421\u0438\u043d\u044c\u043e \u0431\u044a\u0440\u0434\u043e'), 'en': 'Sinyo bardo'}, '3599127':{'bg': u('\u041b\u044e\u0442\u0438\u0434\u043e\u043b'), 'en': 'Lyutidol'}, '434212':{'de': 'Sankt Veit an der Glan', 'en': 'St. Veit an der Glan'}, '434213':{'de': 'Launsdorf', 'en': 'Launsdorf'}, '434214':{'de': u('Br\u00fcckl'), 'en': u('Br\u00fcckl')}, '434215':{'de': 'Liebenfels', 'en': 'Liebenfels'}, '35971587':{'bg': u('\u0413\u043e\u043b\u0435\u043c\u0430 \u0420\u0430\u043a\u043e\u0432\u0438\u0446\u0430'), 'en': 'Golema Rakovitsa'}, '3356111':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356112':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356113':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356114':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356115':{'en': 'Colomiers', 'fr': 'Colomiers'}, '3356116':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356117':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3599121':{'bg': u('\u0426\u0430\u0440\u0435\u0432\u0435\u0446, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Tsarevets, Vratsa'}, '3353540':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3679':{'en': 'Baja', 'hu': 'Baja'}, '359318':{'bg': u('\u0421\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Saedinenie, Plovdiv'}, '3742830':{'am': u('\u054d\u056b\u057d\u056b\u0561\u0576'), 'en': 'Sisian', 'ru': u('\u0421\u0438\u0441\u0438\u0430\u043d')}, '441458':{'en': 'Glastonbury'}, '441456':{'en': 'Glenurquhart'}, '441457':{'en': 'Glossop'}, '441454':{'en': 'Chipping Sodbury'}, '441455':{'en': 'Hinckley'}, '441452':{'en': 'Gloucester'}, '441453':{'en': 'Dursley'}, '441450':{'en': 'Hawick'}, '39051':{'en': 'Bologna', 'it': 'Bologna'}, '437246':{'de': 'Gunskirchen', 'en': 'Gunskirchen'}, '441788':{'en': 'Rugby'}, '3599567':{'bg': u('\u0414\u043e\u043b\u043d\u0430 \u0412\u0435\u0440\u0435\u043d\u0438\u0446\u0430'), 'en': 'Dolna Verenitsa'}, '3599564':{'bg': u('\u0421\u0442\u0443\u0431\u0435\u043b'), 'en': 'Stubel'}, '3599560':{'bg': u('\u0411\u0435\u0437\u0434\u0435\u043d\u0438\u0446\u0430'), 'en': 'Bezdenitsa'}, '3599561':{'bg': u('\u0421\u0443\u043c\u0435\u0440'), 'en': 'Sumer'}, '3599568':{'bg': u('\u0411\u043b\u0430\u0433\u043e\u0432\u043e, \u041c\u043e\u043d\u0442.'), 'en': 'Blagovo, Mont.'}, '3599569':{'bg': u('\u041b\u0438\u043f\u0435\u043d'), 'en': 'Lipen'}, '3347581':{'en': 'Valence', 'fr': 'Valence'}, '3347580':{'en': u('Saint-P\u00e9ray'), 'fr': u('Saint-P\u00e9ray')}, '3347583':{'en': u('Bourg-l\u00e8s-Valence'), 'fr': u('Bourg-l\u00e8s-Valence')}, '3347582':{'en': 'Valence', 'fr': 'Valence'}, '3347584':{'en': u('Pont-de-l\'Is\u00e8re'), 'fr': u('Pont-de-l\'Is\u00e8re')}, '3347239':{'en': 'Saint-Genis-Laval', 'fr': 'Saint-Genis-Laval'}, '3347238':{'en': 'Tassin-la-Demi-Lune', 'fr': 'Tassin-la-Demi-Lune'}, '3347589':{'en': 'Aubenas', 'fr': 'Aubenas'}, '3347588':{'en': 'Vallon-Pont-d\'Arc', 'fr': 'Vallon-Pont-d\'Arc'}, '3347235':{'en': 'Lyon', 'fr': 'Lyon'}, '3347234':{'en': 'Lyon', 'fr': 'Lyon'}, '3347233':{'en': 'Lyon', 'fr': 'Lyon'}, '3347232':{'en': 'Lyon', 'fr': 'Lyon'}, '3347231':{'en': 'Brignais', 'fr': 'Brignais'}, '3332908':{'en': 'Vittel', 'fr': 'Vittel'}, '432825':{'de': u('G\u00f6pfritz an der Wild'), 'en': u('G\u00f6pfritz an der Wild')}, '434227':{'de': 'Ferlach', 'en': 'Ferlach'}, '432824':{'de': 'Allentsteig', 'en': 'Allentsteig'}, '3346728':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3346729':{'en': 'Mauguio', 'fr': 'Mauguio'}, '44281':{'en': 'Northern Ireland'}, '3346722':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346723':{'en': u('B\u00e9darieux'), 'fr': u('B\u00e9darieux')}, '3346720':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3324105':{'en': 'Angers', 'fr': 'Angers'}, '3346726':{'en': 'Le Cap d\'Agde', 'fr': 'Le Cap d\'Agde'}, '3346727':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346724':{'en': 'Montagnac', 'fr': 'Montagnac'}, '3346725':{'en': 'Paulhan', 'fr': 'Paulhan'}, '432829':{'de': 'Schweiggers', 'en': 'Schweiggers'}, '432828':{'de': 'Rappottenstein', 'en': 'Rappottenstein'}, '35931308':{'bg': u('\u0411\u043e\u0433\u0434\u0430\u043d, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Bogdan, Plovdiv'}, '35931309':{'bg': u('\u041a\u043b\u0438\u043c\u0435\u043d\u0442, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Kliment, Plovdiv'}, '3338648':{'en': 'Auxerre', 'fr': 'Auxerre'}, '3338649':{'en': 'Auxerre', 'fr': 'Auxerre'}, '3338640':{'en': u('Mon\u00e9teau'), 'fr': u('Mon\u00e9teau')}, '3338642':{'en': 'Chablis', 'fr': 'Chablis'}, '3338643':{'en': 'Saint-Florentin', 'fr': 'Saint-Florentin'}, '3338644':{'en': 'Toucy', 'fr': 'Toucy'}, '3338646':{'en': 'Auxerre', 'fr': 'Auxerre'}, '35937604':{'bg': u('\u0412\u044a\u0440\u0431\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Varbovo, Hask.'}, '3742499':{'am': u('\u0531\u0580\u0561\u0563\u0561\u056e\u0561\u057e\u0561\u0576'), 'en': 'Aragatsavan', 'ru': u('\u0410\u0440\u0430\u0433\u0430\u0446\u0430\u0432\u0430\u043d')}, '3336847':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3596167':{'bg': u('\u041a\u0435\u0441\u0430\u0440\u0435\u0432\u043e'), 'en': 'Kesarevo'}, '3596166':{'bg': u('\u0412\u0438\u043d\u043e\u0433\u0440\u0430\u0434'), 'en': 'Vinograd'}, '3596165':{'bg': u('\u0410\u0441\u0435\u043d\u043e\u0432\u043e, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Asenovo, V. Tarnovo'}, '3596164':{'bg': u('\u0411\u0440\u044f\u0433\u043e\u0432\u0438\u0446\u0430'), 'en': 'Bryagovitsa'}, '3596163':{'bg': u('\u041a\u0430\u043c\u0435\u043d, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Kamen, V. Tarnovo'}, '3596161':{'bg': u('\u0421\u0442\u0440\u0430\u0436\u0438\u0446\u0430, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Strazhitsa, V. Tarnovo'}, '3338705':{'en': u('Ch\u00e2teau-Salins'), 'fr': u('Ch\u00e2teau-Salins')}, '3338704':{'en': 'Freyming-Merlebach', 'fr': 'Freyming-Merlebach'}, '3338706':{'en': 'Bitche', 'fr': 'Bitche'}, '3676':{'en': 'Kecskemet', 'hu': u('Kecskem\u00e9t')}, '3677':{'en': 'Kiskunhalas', 'hu': 'Kiskunhalas'}, '3338703':{'en': 'Sarrebourg', 'fr': 'Sarrebourg'}, '3596168':{'bg': u('\u0421\u0443\u0448\u0438\u0446\u0430, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Sushitsa, V. Tarnovo'}, '3582':{'en': 'Turku/Pori', 'fi': 'Turku/Pori', 'se': u('\u00c5bo/Bj\u00f6rneborg')}, '3583':{'en': 'Tavastia', 'fi': u('H\u00e4me'), 'se': 'Tavastland'}, '3586':{'en': 'Vaasa', 'fi': 'Vaasa', 'se': 'Vasa'}, '3342602':{'en': 'Lyon', 'fr': 'Lyon'}, '3588':{'en': 'Oulu', 'fi': 'Oulu', 'se': u('Ule\u00e5borg')}, '3589':{'en': 'Helsinki', 'fi': 'Helsinki', 'se': 'Helsingfors'}, '3522780':{'de': 'Diekirch', 'en': 'Diekirch', 'fr': 'Diekirch'}, '3522781':{'de': u('Ettelbr\u00fcck/Reckange-sur-Mess'), 'en': 'Ettelbruck/Reckange-sur-Mess', 'fr': 'Ettelbruck/Reckange-sur-Mess'}, '3522783':{'de': 'Vianden', 'en': 'Vianden', 'fr': 'Vianden'}, '3522784':{'de': 'Han/Lesse', 'en': 'Han/Lesse', 'fr': 'Han/Lesse'}, '3522785':{'de': 'Bissen/Roost', 'en': 'Bissen/Roost', 'fr': 'Bissen/Roost'}, '3522787':{'de': 'Fels', 'en': 'Larochette', 'fr': 'Larochette'}, '3522788':{'de': 'Mertzig/Wahl', 'en': 'Mertzig/Wahl', 'fr': 'Mertzig/Wahl'}, '371634':{'en': 'Liepaja'}, '371635':{'en': 'Ventspils'}, '371636':{'en': 'Ventspils'}, '371637':{'en': 'Dobele'}, '371630':{'en': 'Jelgava'}, '371631':{'en': 'Tukums'}, '371632':{'en': 'Talsi'}, '371633':{'en': 'Kuldiga'}, '371638':{'en': 'Saldus'}, '371639':{'en': 'Bauska'}, '3674':{'en': 'Szekszard', 'hu': u('Szeksz\u00e1rd')}, '432212':{'de': 'Orth an der Donau', 'en': 'Orth an der Donau'}, '432213':{'de': 'Lassee', 'en': 'Lassee'}, '3332039':{'en': 'Comines', 'fr': 'Comines'}, '432214':{'de': 'Kopfstetten', 'en': 'Kopfstetten'}, '432215':{'de': 'Probstdorf', 'en': 'Probstdorf'}, '3332035':{'en': u('Armenti\u00e8res'), 'fr': u('Armenti\u00e8res')}, '3332034':{'en': 'Villeneuve-d\'Ascq', 'fr': 'Villeneuve-d\'Ascq'}, '3332036':{'en': 'Tourcoing', 'fr': 'Tourcoing'}, '3332031':{'en': 'Lille', 'fr': 'Lille'}, '3332030':{'en': 'Lille', 'fr': 'Lille'}, '3332033':{'en': 'Villeneuve-d\'Ascq', 'fr': 'Villeneuve-d\'Ascq'}, '3332032':{'en': 'Seclin', 'fr': 'Seclin'}, '4415078':{'en': 'Alford (Lincs)'}, '4415079':{'en': 'Alford (Lincs)'}, '3354667':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3354668':{'en': 'Puilboreau', 'fr': 'Puilboreau'}, '4415075':{'en': 'Spilsby (Horncastle)'}, '4415076':{'en': 'Louth'}, '4415077':{'en': 'Louth'}, '4415070':{'en': 'Louth/Alford (Lincs)/Spilsby (Horncastle)'}, '374222':{'am': u('\u0531\u0562\u0578\u057e\u0575\u0561\u0576/\u0531\u056f\u0578\u0582\u0576\u0584/\u0532\u0575\u0578\u0582\u0580\u0565\u0572\u0561\u057e\u0561\u0576/\u0546\u0578\u0580 \u0533\u0575\u0578\u0582\u0572/\u054e\u0565\u0580\u056b\u0576 \u054a\u057f\u0572\u0576\u056b'), 'en': 'Abovyan/Akunk/Byureghavan/Nor Gyugh/Verin Ptghni', 'ru': u('\u0410\u0431\u043e\u0432\u044f\u043d/\u0410\u043a\u0443\u043d\u043a/\u0411\u044e\u0440\u0435\u0433\u0430\u0432\u0430\u043d/\u041d\u043e\u0440 \u0413\u044e\u0445/\u0412\u0435\u0440\u0438\u043d \u041f\u0442\u0445\u043d\u0438')}, '4415072':{'en': 'Spilsby (Horncastle)'}, '3358160':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3329970':{'en': 'Sixt-sur-Aff', 'fr': 'Sixt-sur-Aff'}, '3329971':{'en': 'Redon', 'fr': 'Redon'}, '3323567':{'en': 'Grand-Couronne', 'fr': 'Grand-Couronne'}, '3329973':{'en': 'Combourg', 'fr': 'Combourg'}, '3329974':{'en': u('Vitr\u00e9'), 'fr': u('Vitr\u00e9')}, '3329975':{'en': u('Vitr\u00e9'), 'fr': u('Vitr\u00e9')}, '3323563':{'en': 'Rouen', 'fr': 'Rouen'}, '3329977':{'en': 'Chartres-de-Bretagne', 'fr': 'Chartres-de-Bretagne'}, '3329978':{'en': 'Rennes', 'fr': 'Rennes'}, '3329979':{'en': 'Rennes', 'fr': 'Rennes'}, '3355535':{'en': 'Limoges', 'fr': 'Limoges'}, '3355534':{'en': 'Limoges', 'fr': 'Limoges'}, '3323569':{'en': 'Le Grand Quevilly', 'fr': 'Le Grand Quevilly'}, '3323568':{'en': 'Petit-Couronne', 'fr': 'Petit-Couronne'}, '3355531':{'en': 'Limoges', 'fr': 'Limoges'}, '3355530':{'en': 'Limoges', 'fr': 'Limoges'}, '3349327':{'en': 'Nice', 'fr': 'Nice'}, '3349326':{'en': 'Nice', 'fr': 'Nice'}, '3349457':{'en': u('Hy\u00e8res'), 'fr': u('Hy\u00e8res')}, '3349324':{'en': 'Vence', 'fr': 'Vence'}, '3349323':{'en': 'Isola', 'fr': 'Isola'}, '3349450':{'en': 'Draguignan', 'fr': 'Draguignan'}, '3349453':{'en': u('Fr\u00e9jus'), 'fr': u('Fr\u00e9jus')}, '3349452':{'en': u('Fr\u00e9jus'), 'fr': u('Fr\u00e9jus')}, '3349459':{'en': 'Saint-Maximin-la-Sainte-Baume', 'fr': 'Saint-Maximin-la-Sainte-Baume'}, '3349458':{'en': 'Carqueiranne', 'fr': 'Carqueiranne'}, '3349329':{'en': 'Carros', 'fr': 'Carros'}, '3349328':{'en': 'Menton', 'fr': 'Menton'}, '3322962':{'en': 'Landerneau', 'fr': 'Landerneau'}, '3355347':{'en': 'Agen', 'fr': 'Agen'}, '3355340':{'en': 'Villeneuve-sur-Lot', 'fr': 'Villeneuve-sur-Lot'}, '4413879':{'en': 'Dumfries'}, '3355759':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355758':{'en': 'Saint-Savin', 'fr': 'Saint-Savin'}, '3355752':{'en': 'La Teste de Buch', 'fr': 'La Teste de Buch'}, '3355751':{'en': 'Libourne', 'fr': 'Libourne'}, '3355750':{'en': 'Libourne', 'fr': 'Libourne'}, '3355755':{'en': 'Libourne', 'fr': 'Libourne'}, '3355754':{'en': 'Cenon', 'fr': 'Cenon'}, '3332691':{'en': 'Reims', 'fr': 'Reims'}, '437485':{'de': 'Gaming', 'en': 'Gaming'}, '437486':{'de': 'Lunz am See', 'en': 'Lunz am See'}, '437487':{'de': 'Gresten', 'en': 'Gresten'}, '437480':{'de': 'Langau, Gaming', 'en': 'Langau, Gaming'}, '437482':{'de': 'Scheibbs', 'en': 'Scheibbs'}, '437483':{'de': 'Oberndorf an der Melk', 'en': 'Oberndorf an der Melk'}, '437488':{'de': 'Steinakirchen am Forst', 'en': 'Steinakirchen am Forst'}, '437489':{'de': 'Purgstall an der Erlauf', 'en': 'Purgstall an der Erlauf'}, '437673':{'de': 'Schwanenstadt', 'en': 'Schwanenstadt'}, '437672':{'de': u('V\u00f6cklabruck'), 'en': u('V\u00f6cklabruck')}, '3324353':{'en': 'Laval', 'fr': 'Laval'}, '3324352':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324350':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324356':{'en': 'Laval', 'fr': 'Laval'}, '3324354':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324359':{'en': 'Laval', 'fr': 'Laval'}, '3324358':{'en': 'Laval', 'fr': 'Laval'}, '437676':{'de': 'Ottnang am Hausruck', 'en': 'Ottnang am Hausruck'}, '437260':{'de': 'Waldhausen', 'en': 'Waldhausen'}, '437261':{'de': u('Sch\u00f6nau im M\u00fchlkreis'), 'en': u('Sch\u00f6nau im M\u00fchlkreis')}, '437262':{'de': 'Perg', 'en': 'Perg'}, '3332968':{'en': u('\u00c9pinal'), 'fr': u('\u00c9pinal')}, '437264':{'de': 'Windhaag bei Perg', 'en': 'Windhaag bei Perg'}, '437265':{'de': 'Pabneukirchen', 'en': 'Pabneukirchen'}, '437266':{'de': 'Bad Kreuzen', 'en': 'Bad Kreuzen'}, '437267':{'de': u('M\u00f6nchdorf'), 'en': u('M\u00f6nchdorf')}, '3332963':{'en': u('G\u00e9rardmer'), 'fr': u('G\u00e9rardmer')}, '3332962':{'en': 'Remiremont', 'fr': 'Remiremont'}, '3332960':{'en': u('G\u00e9rardmer'), 'fr': u('G\u00e9rardmer')}, '3332966':{'en': u('Plombi\u00e8res-les-Bains'), 'fr': u('Plombi\u00e8res-les-Bains')}, '3332965':{'en': 'Rambervillers', 'fr': 'Rambervillers'}, '3332964':{'en': u('\u00c9pinal'), 'fr': u('\u00c9pinal')}, '3356257':{'en': 'Balma', 'fr': 'Balma'}, '3356256':{'en': 'Tarbes', 'fr': 'Tarbes'}, '3356706':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356253':{'en': 'Tarbes', 'fr': 'Tarbes'}, '3356251':{'en': 'Tarbes', 'fr': 'Tarbes'}, '3338095':{'en': 'Is-sur-Tille', 'fr': 'Is-sur-Tille'}, '3338097':{'en': 'Semur-en-Auxois', 'fr': 'Semur-en-Auxois'}, '3338091':{'en': u('Ch\u00e2tillon-sur-Seine'), 'fr': u('Ch\u00e2tillon-sur-Seine')}, '3338090':{'en': 'Pouilly-en-Auxois', 'fr': 'Pouilly-en-Auxois'}, '3338092':{'en': 'Montbard', 'fr': 'Montbard'}, '442310':{'en': 'Portsmouth'}, '442311':{'en': 'Southampton'}, '390525':{'it': 'Fornovo di Taro'}, '390524':{'it': 'Fidenza'}, '3344247':{'en': 'Fos-sur-Mer', 'fr': 'Fos-sur-Mer'}, '3344246':{'en': 'Vitrolles', 'fr': 'Vitrolles'}, '3344245':{'en': 'Carry-le-Rouet', 'fr': 'Carry-le-Rouet'}, '3344244':{'en': 'Carry-le-Rouet', 'fr': 'Carry-le-Rouet'}, '3344243':{'en': 'Martigues', 'fr': 'Martigues'}, '3344242':{'en': 'Martigues', 'fr': 'Martigues'}, '3344241':{'en': 'Vitrolles', 'fr': 'Vitrolles'}, '3344240':{'en': 'Martigues', 'fr': 'Martigues'}, '46270':{'en': u('S\u00f6derhamn'), 'sv': u('S\u00f6derhamn')}, '3344249':{'en': 'Martigues', 'fr': 'Martigues'}, '3344248':{'en': u('Port-Saint-Louis-du-Rh\u00f4ne'), 'fr': u('Port-Saint-Louis-du-Rh\u00f4ne')}, '3355591':{'en': 'Beaulieu-sur-Dordogne', 'fr': 'Beaulieu-sur-Dordogne'}, '3595944':{'bg': u('\u0420\u0443\u0435\u043d, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Ruen, Burgas'}, '374242':{'am': u('\u0544\u0561\u0580\u0561\u056c\u056b\u056f/\u054d\u0561\u057c\u0576\u0561\u0572\u0562\u0575\u0578\u0582\u0580'), 'en': 'Maralik/Sarnaghbyur', 'ru': u('\u041c\u0430\u0440\u0430\u043b\u0438\u043a/\u0421\u0430\u0440\u043d\u0430\u0445\u0431\u044e\u0440')}, '374246':{'am': u('\u0531\u0574\u0561\u057d\u056b\u0561'), 'en': 'Amasia region', 'ru': u('\u0410\u043c\u0430\u0441\u0438\u044f')}, '374244':{'am': u('\u0531\u0580\u0569\u056b\u056f/\u054a\u0565\u0574\u0566\u0561\u0577\u0565\u0576'), 'en': 'Artik/Pemzashen', 'ru': u('\u0410\u0440\u0442\u0438\u043a/\u041f\u0435\u043c\u0437\u0430\u0448\u0435\u043d')}, '374245':{'am': u('\u0531\u0577\u0578\u0581\u0584'), 'en': 'Ashotsk region', 'ru': u('\u0410\u0448\u043e\u0446\u043a')}, '374249':{'am': u('\u0539\u0561\u056c\u056b\u0576'), 'en': 'Talin', 'ru': u('\u0422\u0430\u043b\u0438\u043d')}, '3596578':{'bg': u('\u0420\u0435\u0441\u0435\u043b\u0435\u0446'), 'en': 'Reselets'}, '3596579':{'bg': u('\u0420\u0443\u043f\u0446\u0438, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Ruptsi, Pleven'}, '3596570':{'bg': u('\u0414\u0435\u0432\u0435\u043d\u0446\u0438'), 'en': 'Deventsi'}, '3596571':{'bg': u('\u041b\u0435\u043f\u0438\u0446\u0430'), 'en': 'Lepitsa'}, '3596572':{'bg': u('\u0421\u0443\u0445\u0430\u0447\u0435'), 'en': 'Suhache'}, '3596573':{'bg': u('\u041a\u043e\u0439\u043d\u0430\u0440\u0435'), 'en': 'Koynare'}, '3596574':{'bg': u('\u0427\u043e\u043c\u0430\u043a\u043e\u0432\u0446\u0438'), 'en': 'Chomakovtsi'}, '3596575':{'bg': u('\u0422\u0435\u043b\u0438\u0448'), 'en': 'Telish'}, '3596576':{'bg': u('\u0420\u0430\u0434\u043e\u043c\u0438\u0440\u0446\u0438'), 'en': 'Radomirtsi'}, '3596577':{'bg': u('\u0411\u0440\u0435\u0441\u0442\u0435'), 'en': 'Breste'}, '441665':{'en': 'Alnwick'}, '441664':{'en': 'Melton Mowbray'}, '441667':{'en': 'Nairn'}, '441666':{'en': 'Malmesbury'}, '441661':{'en': 'Prudhoe'}, '441663':{'en': 'New Mills'}, '441669':{'en': 'Rothbury'}, '441668':{'en': 'Bamburgh'}, '355364':{'en': u('V\u00ebrtop/Terpan, Berat')}, '355365':{'en': u('Sinj\u00eb/Cukalat, Berat')}, '355366':{'en': u('Poshnj\u00eb/Kutalli, Berat')}, '355367':{'en': u('Perondi/Kozar\u00eb, Ku\u00e7ov\u00eb')}, '355360':{'en': u('Leshnje/Potom/\u00c7epan/Gjerb\u00ebs/Zhep\u00eb, Skrapar')}, '355361':{'en': 'Ura Vajgurore, Berat'}, '355362':{'en': 'Velabisht/Roshnik, Berat'}, '355363':{'en': 'Otllak/Lumas, Berat'}, '4414370':{'en': 'Haverfordwest/Clynderwen (Clunderwen)'}, '355368':{'en': u('Poli\u00e7an/Bogov\u00eb, Skrapar')}, '355369':{'en': u('Qend\u00ebr/Vendresh\u00eb, Skrapar')}, '3347910':{'en': 'Albertville', 'fr': 'Albertville'}, '434879':{'de': 'Sankt Veit in Defereggen', 'en': 'St. Veit in Defereggen'}, '434874':{'de': 'Virgen', 'en': 'Virgen'}, '434875':{'de': 'Matrei in Osttirol', 'en': 'Matrei in Osttirol'}, '434876':{'de': u('Kals am Gro\u00dfglockner'), 'en': 'Kals am Grossglockner'}, '434877':{'de': u('Pr\u00e4graten am Gro\u00dfvenediger'), 'en': u('Pr\u00e4graten am Grossvenediger')}, '434872':{'de': 'Huben', 'en': 'Huben'}, '434873':{'de': 'Sankt Jakob in Defereggen', 'en': 'St. Jakob in Defereggen'}, '3317463':{'en': 'Levallois-Perret', 'fr': 'Levallois-Perret'}, '3597155':{'bg': u('\u041b\u0435\u0441\u043d\u043e\u0432\u043e'), 'en': 'Lesnovo'}, '3597154':{'bg': u('\u0421\u0442\u043e\u043b\u043d\u0438\u043a'), 'en': 'Stolnik'}, '35961703':{'bg': u('\u0412\u044a\u0440\u0431\u0438\u0446\u0430, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Varbitsa, V. Tarnovo'}, '3597156':{'bg': u('\u0420\u0430\u0432\u043d\u043e \u043f\u043e\u043b\u0435'), 'en': 'Ravno pole'}, '35961705':{'bg': u('\u0413\u043e\u0440\u0441\u043a\u0438 \u0434\u043e\u043b\u0435\u043d \u0422\u0440\u044a\u043c\u0431\u0435\u0448'), 'en': 'Gorski dolen Trambesh'}, '35961704':{'bg': u('\u041f\u0440\u0430\u0432\u0434\u0430, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Pravda, V. Tarnovo'}, '35961706':{'bg': u('\u041f\u0438\u0441\u0430\u0440\u0435\u0432\u043e, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Pisarevo, V. Tarnovo'}, '35941149':{'bg': u('\u041b\u043e\u0432\u0435\u0446, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Lovets, St. Zagora'}, '3597159':{'bg': u('\u0410\u043f\u0440\u0438\u043b\u043e\u0432\u043e, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Aprilovo, Sofia'}, '3597158':{'bg': u('\u0414\u043e\u0433\u0430\u043d\u043e\u0432\u043e'), 'en': 'Doganovo'}, '441273':{'en': 'Brighton'}, '441270':{'en': 'Crewe'}, '3343748':{'en': 'Lyon', 'fr': 'Lyon'}, '441276':{'en': 'Camberley'}, '441277':{'en': 'Brentwood'}, '441274':{'en': 'Bradford'}, '441275':{'en': 'Clevedon'}, '3343743':{'en': 'Villeurbanne', 'fr': 'Villeurbanne'}, '3343742':{'en': 'Lyon', 'fr': 'Lyon'}, '441278':{'en': 'Bridgwater'}, '3343740':{'en': 'Caluire-et-Cuire', 'fr': 'Caluire-et-Cuire'}, '3343747':{'en': 'Villeurbanne', 'fr': 'Villeurbanne'}, '3343746':{'en': 'Lyon', 'fr': 'Lyon'}, '3343745':{'en': 'Vaulx-en-Velin', 'fr': 'Vaulx-en-Velin'}, '3343744':{'en': 'Meyzieu', 'fr': 'Meyzieu'}, '432263':{'de': u('Gro\u00dfru\u00dfbach'), 'en': 'Grossrussbach'}, '432262':{'de': 'Korneuburg', 'en': 'Korneuburg'}, '3346739':{'en': 'Servian', 'fr': 'Servian'}, '3346738':{'en': 'Saint-Chinian', 'fr': 'Saint-Chinian'}, '3751591':{'be': u('\u0410\u0441\u0442\u0440\u0430\u0432\u0435\u0446, \u0413\u0440\u043e\u0434\u0437\u0435\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Ostrovets, Grodno Region', 'ru': u('\u041e\u0441\u0442\u0440\u043e\u0432\u0435\u0446, \u0413\u0440\u043e\u0434\u043d\u0435\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751593':{'be': u('\u0410\u0448\u043c\u044f\u043d\u044b'), 'en': 'Oshmyany', 'ru': u('\u041e\u0448\u043c\u044f\u043d\u044b')}, '3751592':{'be': u('\u0421\u043c\u0430\u0440\u0433\u043e\u043d\u044c'), 'en': 'Smorgon', 'ru': u('\u0421\u043c\u043e\u0440\u0433\u043e\u043d\u044c')}, '3751595':{'be': u('\u0406\u045e\u0435, \u0413\u0440\u043e\u0434\u0437\u0435\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Ivye, Grodno Region', 'ru': u('\u0418\u0432\u044c\u0435, \u0413\u0440\u043e\u0434\u043d\u0435\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751594':{'be': u('\u0412\u043e\u0440\u0430\u043d\u0430\u0432\u0430, \u0413\u0440\u043e\u0434\u0437\u0435\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Voronovo, Grodno Region', 'ru': u('\u0412\u043e\u0440\u043e\u043d\u043e\u0432\u043e, \u0413\u0440\u043e\u0434\u043d\u0435\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751597':{'be': u('\u041d\u0430\u0432\u0430\u0433\u0440\u0443\u0434\u0430\u043a'), 'en': 'Novogrudok', 'ru': u('\u041d\u043e\u0432\u043e\u0433\u0440\u0443\u0434\u043e\u043a')}, '3751596':{'be': u('\u041a\u0430\u0440\u044d\u043b\u0456\u0447\u044b, \u0413\u0440\u043e\u0434\u0437\u0435\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Korelichi, Grodno Region', 'ru': u('\u041a\u043e\u0440\u0435\u043b\u0438\u0447\u0438, \u0413\u0440\u043e\u0434\u043d\u0435\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '35963563':{'bg': u('\u0411\u043e\u0440\u0438\u0441\u043b\u0430\u0432'), 'en': 'Borislav'}, '3324119':{'en': 'Angers', 'fr': 'Angers'}, '3323798':{'en': 'Cloyes-sur-le-Loir', 'fr': 'Cloyes-sur-le-Loir'}, '3323799':{'en': 'Voves', 'fr': 'Voves'}, '35963567':{'bg': u('\u0413\u0440\u0430\u0434\u0438\u043d\u0430, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Gradina, Pleven'}, '35963566':{'bg': u('\u0411\u0440\u044a\u0448\u043b\u044f\u043d\u0438\u0446\u0430'), 'en': 'Brashlyanitsa'}, '35963565':{'bg': u('\u041c\u0435\u0447\u043a\u0430, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Mechka, Pleven'}, '3346734':{'en': 'Montpellier', 'fr': 'Montpellier'}, '35963569':{'bg': u('\u041a\u0430\u043c\u0435\u043d\u0435\u0446, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Kamenets, Pleven'}, '3323791':{'en': 'Chartres', 'fr': 'Chartres'}, '3323797':{'en': 'Arrou', 'fr': 'Arrou'}, '441896':{'en': 'Galashiels'}, '441895':{'en': 'Uxbridge'}, '441892':{'en': 'Tunbridge Wells'}, '441899':{'en': 'Biggar'}, '3324028':{'en': u('Ch\u00e2teaubriant'), 'fr': u('Ch\u00e2teaubriant')}, '3345744':{'en': 'Chamonix-Mont-Blanc', 'fr': 'Chamonix-Mont-Blanc'}, '39059':{'en': 'Modena', 'it': 'Modena'}, '3593678':{'bg': u('\u0427\u0430\u043a\u0430\u043b\u0430\u0440\u043e\u0432\u043e'), 'en': 'Chakalarovo'}, '3593679':{'bg': u('\u041a\u0438\u0440\u043a\u043e\u0432\u043e'), 'en': 'Kirkovo'}, '3593674':{'bg': u('\u0421\u0430\u043c\u043e\u0434\u0438\u0432\u0430'), 'en': 'Samodiva'}, '3593675':{'bg': u('\u0424\u043e\u0442\u0438\u043d\u043e\u0432\u043e, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Fotinovo, Kardzh.'}, '3593676':{'bg': u('\u0411\u0435\u043d\u043a\u043e\u0432\u0441\u043a\u0438, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Benkovski, Kardzh.'}, '3593677':{'bg': u('\u0414\u0440\u0430\u043d\u0433\u043e\u0432\u043e, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Drangovo, Kardzh.'}, '3593671':{'bg': u('\u041f\u043e\u0434\u043a\u043e\u0432\u0430'), 'en': 'Podkova'}, '3593672':{'bg': u('\u0427\u043e\u0440\u0431\u0430\u0434\u0436\u0438\u0439\u0441\u043a\u043e'), 'en': 'Chorbadzhiysko'}, '3593673':{'bg': u('\u0422\u0438\u0445\u043e\u043c\u0438\u0440'), 'en': 'Tihomir'}, '3595948':{'bg': u('\u0421\u043d\u044f\u0433\u043e\u0432\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Snyagovo, Burgas'}, '3595949':{'bg': u('\u041f\u043b\u0430\u043d\u0438\u043d\u0438\u0446\u0430, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Planinitsa, Burgas'}, '3329899':{'en': 'Carhaix-Plouguer', 'fr': 'Carhaix-Plouguer'}, '3329898':{'en': 'Quimper', 'fr': 'Quimper'}, '3329893':{'en': 'Carhaix-Plouguer', 'fr': 'Carhaix-Plouguer'}, '3329892':{'en': 'Douarnenez', 'fr': 'Douarnenez'}, '3329891':{'en': u('Ploz\u00e9vet'), 'fr': u('Ploz\u00e9vet')}, '3329890':{'en': 'Quimper', 'fr': 'Quimper'}, '3329897':{'en': 'Concarneau', 'fr': 'Concarneau'}, '3329896':{'en': u('Quimperl\u00e9'), 'fr': u('Quimperl\u00e9')}, '3329895':{'en': 'Quimper', 'fr': 'Quimper'}, '4419467':{'en': 'Gosforth'}, '3593019':{'bg': u('\u041f\u0438\u0441\u0430\u043d\u0438\u0446\u0430'), 'en': 'Pisanitsa'}, '432535':{'de': 'Hohenau an der March', 'en': 'Hohenau an der March'}, '3332753':{'en': 'Maubeuge', 'fr': 'Maubeuge'}, '432533':{'de': 'Neusiedl an der Zaya', 'en': 'Neusiedl an der Zaya'}, '432532':{'de': 'Zistersdorf', 'en': 'Zistersdorf'}, '3332756':{'en': 'Avesnes-sur-Helpe', 'fr': 'Avesnes-sur-Helpe'}, '3595945':{'bg': u('\u0414\u043e\u0431\u0440\u043e\u043c\u0438\u0440'), 'en': 'Dobromir'}, '3332758':{'en': 'Maubeuge', 'fr': 'Maubeuge'}, '3332209':{'en': 'Moreuil', 'fr': 'Moreuil'}, '4419469':{'en': 'Whitehaven'}, '432538':{'de': u('Velm-G\u00f6tzendorf'), 'en': u('Velm-G\u00f6tzendorf')}, '434272':{'de': u('P\u00f6rtschach am W\u00f6rther See'), 'en': u('P\u00f6rtschach am W\u00f6rther See')}, '434273':{'de': 'Reifnitz', 'en': 'Reifnitz'}, '434271':{'de': 'Steuerberg', 'en': 'Steuerberg'}, '434276':{'de': u('Feldkirchen in K\u00e4rnten'), 'en': u('Feldkirchen in K\u00e4rnten')}, '434277':{'de': 'Glanegg', 'en': 'Glanegg'}, '434274':{'de': u('Velden am W\u00f6rther See'), 'en': u('Velden am W\u00f6rther See')}, '434275':{'de': 'Ebene Reichenau', 'en': 'Ebene Reichenau'}, '434278':{'de': 'Gnesau', 'en': 'Gnesau'}, '434279':{'de': 'Sirnitz', 'en': 'Sirnitz'}, '433856':{'de': 'Veitsch', 'en': 'Veitsch'}, '332482':{'en': 'Bourges', 'fr': 'Bourges'}, '40250':{'en': u('V\u00e2lcea'), 'ro': u('V\u00e2lcea')}, '40251':{'en': 'Dolj', 'ro': 'Dolj'}, '40252':{'en': u('Mehedin\u021bi'), 'ro': u('Mehedin\u021bi')}, '3356139':{'en': 'Saint-Orens-de-Gameville', 'fr': 'Saint-Orens-de-Gameville'}, '40254':{'en': 'Hunedoara', 'ro': 'Hunedoara'}, '40255':{'en': u('Cara\u0219-Severin'), 'ro': u('Cara\u0219-Severin')}, '40256':{'en': u('Timi\u0219'), 'ro': u('Timi\u0219')}, '40257':{'en': 'Arad', 'ro': 'Arad'}, '3356132':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356133':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356130':{'en': 'Colomiers', 'fr': 'Colomiers'}, '3356131':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356136':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356134':{'en': 'Toulouse', 'fr': 'Toulouse'}, '359339':{'bg': u('\u0421\u0442\u0430\u043c\u0431\u043e\u043b\u0438\u0439\u0441\u043a\u0438, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Stamboliyski, Plovdiv'}, '359331':{'bg': u('\u0410\u0441\u0435\u043d\u043e\u0432\u0433\u0440\u0430\u0434'), 'en': 'Asenovgrad'}, '359337':{'bg': u('\u0425\u0438\u0441\u0430\u0440\u044f'), 'en': 'Hisarya'}, '359336':{'bg': u('\u041f\u044a\u0440\u0432\u043e\u043c\u0430\u0439, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Parvomay, Plovdiv'}, '359335':{'bg': u('\u041a\u0430\u0440\u043b\u043e\u0432\u043e'), 'en': 'Karlovo'}, '441478':{'en': 'Isle of Skye - Portree'}, '441479':{'en': 'Grantown-on-Spey'}, '441470':{'en': 'Isle of Skye - Edinbane'}, '441471':{'en': 'Isle of Skye - Broadford'}, '441472':{'en': 'Grimsby'}, '441473':{'en': 'Ipswich'}, '441474':{'en': 'Gravesend'}, '441475':{'en': 'Greenock'}, '441476':{'en': 'Grantham'}, '441477':{'en': 'Holmes Chapel'}, '3356397':{'en': 'Mazamet', 'fr': 'Mazamet'}, '3356392':{'en': 'Montauban', 'fr': 'Montauban'}, '3356393':{'en': 'Caussade', 'fr': 'Caussade'}, '3356391':{'en': 'Montauban', 'fr': 'Montauban'}, '3356398':{'en': 'Mazamet', 'fr': 'Mazamet'}, '3347219':{'en': 'Lyon', 'fr': 'Lyon'}, '3347218':{'en': u('\u00c9cully'), 'fr': u('\u00c9cully')}, '3595146':{'bg': u('\u0413\u043e\u0440\u0435\u043d \u0447\u0438\u0444\u043b\u0438\u043a'), 'en': 'Goren chiflik'}, '3595147':{'bg': u('\u041f\u0447\u0435\u043b\u043d\u0438\u043a, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Pchelnik, Varna'}, '3595140':{'bg': u('\u0428\u043a\u043e\u0440\u043f\u0438\u043b\u043e\u0432\u0446\u0438'), 'en': 'Shkorpilovtsi'}, '3595141':{'bg': u('\u0421\u0442\u0430\u0440\u043e \u041e\u0440\u044f\u0445\u043e\u0432\u043e'), 'en': 'Staro Oryahovo'}, '3595142':{'bg': u('\u0414\u043e\u043b\u043d\u0438 \u0447\u0438\u0444\u043b\u0438\u043a'), 'en': 'Dolni chiflik'}, '3595143':{'bg': u('\u0411\u044f\u043b\u0430, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Byala, Varna'}, '3347210':{'en': 'Lyon', 'fr': 'Lyon'}, '3347213':{'en': 'Lyon', 'fr': 'Lyon'}, '3347212':{'en': 'Lyon', 'fr': 'Lyon'}, '3347215':{'en': 'Bron', 'fr': 'Bron'}, '3347214':{'en': 'Bron', 'fr': 'Bron'}, '3347217':{'en': 'Dardilly', 'fr': 'Dardilly'}, '3347216':{'en': u('Sainte-Foy-l\u00e8s-Lyon'), 'fr': u('Sainte-Foy-l\u00e8s-Lyon')}, '3598633':{'bg': u('\u0421\u0442\u0430\u0440\u043e \u0441\u0435\u043b\u043e, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Staro selo, Silistra'}, '3598632':{'bg': u('\u0417\u0430\u0444\u0438\u0440\u043e\u0432\u043e'), 'en': 'Zafirovo'}, '3598635':{'bg': u('\u0426\u0430\u0440 \u0421\u0430\u043c\u0443\u0438\u043b'), 'en': 'Tsar Samuil'}, '3598634':{'bg': u('\u041d\u043e\u0432\u0430 \u0427\u0435\u0440\u043d\u0430'), 'en': 'Nova Cherna'}, '3598637':{'bg': u('\u041c\u0430\u043b\u044a\u043a \u041f\u0440\u0435\u0441\u043b\u0430\u0432\u0435\u0446'), 'en': 'Malak Preslavets'}, '3598636':{'bg': u('\u0413\u043b\u0430\u0432\u0438\u043d\u0438\u0446\u0430, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Glavinitsa, Silistra'}, '3598639':{'bg': u('\u041a\u043e\u043b\u0430\u0440\u043e\u0432\u043e, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Kolarovo, Silistra'}, '3598638':{'bg': u('\u0411\u043e\u0433\u0434\u0430\u043d\u0446\u0438, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Bogdantsi, Silistra'}, '3324168':{'en': 'Angers', 'fr': 'Angers'}, '3338969':{'en': 'Saint-Louis', 'fr': 'Saint-Louis'}, '39089':{'en': 'Salerno', 'it': 'Salerno'}, '3324160':{'en': 'Angers', 'fr': 'Angers'}, '3324162':{'en': 'Cholet', 'fr': 'Cholet'}, '3324163':{'en': 'Beaupreau', 'fr': 'Beaupreau'}, '39081':{'en': 'Naples', 'it': 'Napoli'}, '3324165':{'en': 'Cholet', 'fr': 'Cholet'}, '3324166':{'en': 'Angers', 'fr': 'Angers'}, '3324167':{'en': 'Saumur', 'fr': 'Saumur'}, '35288':{'de': 'Mertzig/Wahl', 'en': 'Mertzig/Wahl', 'fr': 'Mertzig/Wahl'}, '35283':{'de': 'Vianden', 'en': 'Vianden', 'fr': 'Vianden'}, '35281':{'de': u('Ettelbr\u00fcck'), 'en': 'Ettelbruck', 'fr': 'Ettelbruck'}, '35280':{'de': 'Diekirch', 'en': 'Diekirch', 'fr': 'Diekirch'}, '35287':{'de': 'Fels', 'en': 'Larochette', 'fr': 'Larochette'}, '35285':{'de': 'Bissen/Roost', 'en': 'Bissen/Roost', 'fr': 'Bissen/Roost'}, '35284':{'de': 'Han/Lesse', 'en': 'Han/Lesse', 'fr': 'Han/Lesse'}, '35931324':{'bg': u('\u041c\u0440\u0430\u0447\u0435\u043d\u0438\u043a'), 'en': 'Mrachenik'}, '3338662':{'en': 'Joigny', 'fr': 'Joigny'}, '3338661':{'en': 'Nevers', 'fr': 'Nevers'}, '3338666':{'en': 'Villeneuve-la-Guyard', 'fr': 'Villeneuve-la-Guyard'}, '3338667':{'en': 'Pont-sur-Yonne', 'fr': 'Pont-sur-Yonne'}, '3338664':{'en': 'Sens', 'fr': 'Sens'}, '3338665':{'en': 'Sens', 'fr': 'Sens'}, '3338668':{'en': u('Pr\u00e9mery'), 'fr': u('Pr\u00e9mery')}, '3338967':{'en': 'Saint-Louis', 'fr': 'Saint-Louis'}, '3355685':{'en': u('B\u00e8gles'), 'fr': u('B\u00e8gles')}, '3355932':{'en': 'Pau', 'fr': 'Pau'}, '3329864':{'en': 'Quimper', 'fr': 'Quimper'}, '3596141':{'bg': u('\u041f\u043e\u043b\u0441\u043a\u0438 \u0422\u0440\u044a\u043c\u0431\u0435\u0448'), 'en': 'Polski Trambesh'}, '3596143':{'bg': u('\u041c\u0430\u0441\u043b\u0430\u0440\u0435\u0432\u043e'), 'en': 'Maslarevo'}, '3355930':{'en': 'Pau', 'fr': 'Pau'}, '3596145':{'bg': u('\u0421\u0442\u0440\u0430\u0445\u0438\u043b\u043e\u0432\u043e'), 'en': 'Strahilovo'}, '3596144':{'bg': u('\u0414\u043e\u043b\u043d\u0430 \u041b\u0438\u043f\u043d\u0438\u0446\u0430'), 'en': 'Dolna Lipnitsa'}, '3596147':{'bg': u('\u0418\u0432\u0430\u043d\u0447\u0430, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Ivancha, V. Tarnovo'}, '3596146':{'bg': u('\u041f\u043e\u043b\u0441\u043a\u0438 \u0421\u0435\u043d\u043e\u0432\u0435\u0446'), 'en': 'Polski Senovets'}, '3596149':{'bg': u('\u041a\u0443\u0446\u0438\u043d\u0430'), 'en': 'Kutsina'}, '3329862':{'en': 'Morlaix', 'fr': 'Morlaix'}, '3355936':{'en': 'Oloron-Sainte-Marie', 'fr': 'Oloron-Sainte-Marie'}, '3329860':{'en': 'Concarneau', 'fr': 'Concarneau'}, '3355682':{'en': 'Andernos-les-Bains', 'fr': 'Andernos-les-Bains'}, '4418902':{'en': 'Coldstream'}, '37425353':{'am': u('\u0547\u0576\u0578\u0572'), 'en': 'Shnogh', 'ru': u('\u0428\u043d\u043e\u0445')}, '37425352':{'am': u('\u0531\u056d\u0569\u0561\u056c\u0561'), 'en': 'Akhtala', 'ru': u('\u0410\u0445\u0442\u0430\u043b\u0430')}, '3338989':{'en': 'Saint-Louis', 'fr': 'Saint-Louis'}, '37425357':{'am': u('\u0539\u0578\u0582\u0574\u0561\u0576\u0575\u0561\u0576'), 'en': 'Tumanyan', 'ru': u('\u0422\u0443\u043c\u0430\u043d\u044f\u043d')}, '37425356':{'am': u('\u0543\u0578\u0573\u056f\u0561\u0576'), 'en': 'Chochkan', 'ru': u('\u0427\u043e\u0447\u043a\u0430\u043d')}, '3338980':{'en': 'Colmar', 'fr': 'Colmar'}, '390583':{'en': 'Lucca', 'it': 'Lucca'}, '3339057':{'en': u('S\u00e9lestat'), 'fr': u('S\u00e9lestat')}, '390587':{'it': 'Pontedera'}, '37428427':{'am': u('\u054e\u0565\u0580\u056b\u0577\u0565\u0576'), 'en': 'Verishen', 'ru': u('\u0412\u0435\u0440\u0438\u0448\u0435\u043d')}, '390585':{'en': 'Massa-Carrara', 'it': 'Massa'}, '390584':{'it': 'Viareggio'}, '390588':{'it': 'Volterra'}, '432238':{'de': 'Kaltenleutgeben', 'en': 'Kaltenleutgeben'}, '432239':{'de': 'Breitenfurt bei Wien', 'en': 'Breitenfurt bei Wien'}, '432234':{'de': 'Gramatneusiedl', 'en': 'Gramatneusiedl'}, '432235':{'de': 'Maria-Lanzendorf', 'en': 'Maria-Lanzendorf'}, '432236':{'de': u('M\u00f6dling'), 'en': u('M\u00f6dling')}, '432237':{'de': 'Gaaden', 'en': 'Gaaden'}, '432230':{'de': 'Schwadorf', 'en': 'Schwadorf'}, '432231':{'de': 'Purkersdorf', 'en': 'Purkersdorf'}, '432232':{'de': 'Fischamend', 'en': 'Fischamend'}, '432233':{'de': u('Pre\u00dfbaum'), 'en': 'Pressbaum'}, '3354648':{'en': 'Jonzac', 'fr': 'Jonzac'}, '3354642':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3354643':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3354641':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3354647':{'en': u('Saint-Pierre-d\'Ol\u00e9ron'), 'fr': u('Saint-Pierre-d\'Ol\u00e9ron')}, '3354644':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3354645':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3355518':{'en': 'Brive-la-Gaillarde', 'fr': 'Brive-la-Gaillarde'}, '3329959':{'en': 'Rennes', 'fr': 'Rennes'}, '3323589':{'en': 'Rouen', 'fr': 'Rouen'}, '3323588':{'en': 'Rouen', 'fr': 'Rouen'}, '3355511':{'en': 'Limoges', 'fr': 'Limoges'}, '3355510':{'en': 'Limoges', 'fr': 'Limoges'}, '3329950':{'en': 'Rennes', 'fr': 'Rennes'}, '3323584':{'en': 'Dieppe', 'fr': 'Dieppe'}, '3329956':{'en': 'Saint-Malo', 'fr': 'Saint-Malo'}, '3323582':{'en': 'Dieppe', 'fr': 'Dieppe'}, '3323581':{'en': 'Elbeuf', 'fr': 'Elbeuf'}, '3329955':{'en': 'Betton', 'fr': 'Betton'}, '3349301':{'en': 'Beaulieu-sur-Mer', 'fr': 'Beaulieu-sur-Mer'}, '3349300':{'en': 'Valbonne', 'fr': 'Valbonne'}, '3349303':{'en': u('Roquebilli\u00e8re'), 'fr': u('Roquebilli\u00e8re')}, '3349305':{'en': u('Puget-Th\u00e9niers'), 'fr': u('Puget-Th\u00e9niers')}, '3349304':{'en': 'Nice', 'fr': 'Nice'}, '3349307':{'en': 'Saint-Laurent-du-Var', 'fr': 'Saint-Laurent-du-Var'}, '3349306':{'en': 'Cannes', 'fr': 'Cannes'}, '3349309':{'en': 'Grasse', 'fr': 'Grasse'}, '3349308':{'en': 'Carros', 'fr': 'Carros'}, '390765':{'it': 'Poggio Mirteto'}, '390763':{'it': 'Orvieto'}, '390761':{'it': 'Viterbo'}, '3349723':{'en': 'Antibes Juan les Pins', 'fr': 'Antibes Juan les Pins'}, '3349721':{'en': 'Antibes Juan les Pins', 'fr': 'Antibes Juan les Pins'}, '3649':{'en': 'Mezokovesd', 'hu': u('Mez\u0151k\u00f6vesd')}, '3648':{'en': 'Ozd', 'hu': u('\u00d3zd')}, '3647':{'en': 'Szerencs', 'hu': 'Szerencs'}, '432948':{'de': 'Weitersfeld', 'en': 'Weitersfeld'}, '3646':{'en': 'Miskolc', 'hu': 'Miskolc'}, '432946':{'de': 'Pulkau', 'en': 'Pulkau'}, '432947':{'de': 'Theras', 'en': 'Theras'}, '432944':{'de': 'Haugsdorf', 'en': 'Haugsdorf'}, '432945':{'de': 'Zellerndorf', 'en': 'Zellerndorf'}, '432942':{'de': 'Retz', 'en': 'Retz'}, '432943':{'de': 'Obritz', 'en': 'Obritz'}, '3594738':{'bg': u('\u0425\u043b\u044f\u0431\u043e\u0432\u043e'), 'en': 'Hlyabovo'}, '3594739':{'bg': u('\u0420\u0430\u0434\u043e\u0432\u0435\u0446'), 'en': 'Radovets'}, '441394':{'en': 'Felixstowe'}, '3594734':{'bg': u('\u0421\u0440\u0435\u043c'), 'en': 'Srem'}, '3594736':{'bg': u('\u0421\u0432\u0435\u0442\u043b\u0438\u043d\u0430'), 'en': 'Svetlina'}, '3594737':{'bg': u('\u0421\u0438\u043d\u0430\u043f\u043e\u0432\u043e'), 'en': 'Sinapovo'}, '3594730':{'bg': u('\u041a\u043d\u044f\u0436\u0435\u0432\u043e'), 'en': 'Knyazhevo'}, '3594732':{'bg': u('\u0423\u0441\u0442\u0440\u0435\u043c'), 'en': 'Ustrem'}, '3594733':{'bg': u('\u041e\u0440\u043b\u043e\u0432 \u0434\u043e\u043b'), 'en': 'Orlov dol'}, '35981462':{'bg': u('\u0412\u043e\u043b\u043e\u0432\u043e'), 'en': 'Volovo'}, '35981463':{'bg': u('\u041c\u043e\u0433\u0438\u043b\u0438\u043d\u043e'), 'en': 'Mogilino'}, '35981461':{'bg': u('\u041a\u0430\u0440\u0430\u043d \u0412\u044a\u0440\u0431\u043e\u0432\u043a\u0430'), 'en': 'Karan Varbovka'}, '35981466':{'bg': u('\u041f\u043e\u043c\u0435\u043d'), 'en': 'Pomen'}, '35981464':{'bg': u('\u041e\u0441\u0442\u0440\u0438\u0446\u0430, \u0420\u0443\u0441\u0435'), 'en': 'Ostritsa, Ruse'}, '35981465':{'bg': u('\u0411\u0430\u0442\u0438\u043d'), 'en': 'Batin'}, '3332945':{'en': 'Bar-le-Duc', 'fr': 'Bar-le-Duc'}, '3332941':{'en': u('Raon-l\'\u00c9tape'), 'fr': u('Raon-l\'\u00c9tape')}, '3324378':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3332942':{'en': u('Saint-Di\u00e9-des-Vosges'), 'fr': u('Saint-Di\u00e9-des-Vosges')}, '3324375':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324374':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324377':{'en': 'Le Mans', 'fr': 'Le Mans'}, '441392':{'en': 'Exeter'}, '3324371':{'en': u('La Fert\u00e9 Bernard'), 'fr': u('La Fert\u00e9 Bernard')}, '3324802':{'en': 'Bourges', 'fr': 'Bourges'}, '3324372':{'en': 'Le Mans', 'fr': 'Le Mans'}, '441398':{'en': 'Dulverton'}, '3355776':{'en': 'Andernos-les-Bains', 'fr': 'Andernos-les-Bains'}, '3355771':{'en': 'Marcheprime', 'fr': 'Marcheprime'}, '3355773':{'en': 'Gujan-Mestras', 'fr': 'Gujan-Mestras'}, '3355772':{'en': 'Arcachon', 'fr': 'Arcachon'}, '3355778':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3356271':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356270':{'en': 'Montesquiou', 'fr': 'Montesquiou'}, '3356273':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3324011':{'en': 'La Baule Escoublac', 'fr': 'La Baule Escoublac'}, '3356275':{'en': 'Aucamville', 'fr': 'Aucamville'}, '3356274':{'en': 'Blagnac', 'fr': 'Blagnac'}, '4202':{'en': 'Prague'}, '3325174':{'en': 'Pornic', 'fr': 'Pornic'}, '3325175':{'en': 'La Baule Escoublac', 'fr': 'La Baule Escoublac'}, '3325176':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '3325177':{'en': 'Nantes', 'fr': 'Nantes'}, '3325170':{'en': u('Rez\u00e9'), 'fr': u('Rez\u00e9')}, '3325172':{'en': 'Nantes', 'fr': 'Nantes'}, '3325173':{'en': u('Gu\u00e9rande'), 'fr': u('Gu\u00e9rande')}, '3325178':{'en': 'Orvault', 'fr': 'Orvault'}, '3325179':{'en': 'Vertou', 'fr': 'Vertou'}, '3344261':{'en': 'Trets', 'fr': 'Trets'}, '3344260':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344263':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '35345':{'en': 'Naas/Kildare/Curragh'}, '3344265':{'en': 'Gardanne', 'fr': 'Gardanne'}, '35343':{'en': 'Longford/Granard'}, '3344267':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344266':{'en': 'Puyloubier', 'fr': 'Puyloubier'}, '3344269':{'en': u('Cabri\u00e8s'), 'fr': u('Cabri\u00e8s')}, '3344268':{'en': 'Fuveau', 'fr': 'Fuveau'}, '3599719':{'bg': u('\u0410\u0441\u043f\u0430\u0440\u0443\u0445\u043e\u0432\u043e, \u041c\u043e\u043d\u0442.'), 'en': 'Asparuhovo, Mont.'}, '35349':{'en': 'Cavan/Cootehill/Oldcastle/Belturbet'}, '351276':{'en': 'Chaves', 'pt': 'Chaves'}, '351277':{'en': 'Idanha-a-Nova', 'pt': 'Idanha-a-Nova'}, '3347688':{'en': 'Saint-Pierre-de-Chartreuse', 'fr': 'Saint-Pierre-de-Chartreuse'}, '3347689':{'en': 'Saint-Martin-d\'Uriage', 'fr': 'Saint-Martin-d\'Uriage'}, '351272':{'en': 'Castelo Branco', 'pt': 'Castelo Branco'}, '351273':{'en': u('Bragan\u00e7a'), 'pt': u('Bragan\u00e7a')}, '351271':{'en': 'Guarda', 'pt': 'Guarda'}, '3347681':{'en': u('La Mure d\'Is\u00e8re'), 'fr': u('La Mure d\'Is\u00e8re')}, '3347686':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347687':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347684':{'en': 'Grenoble', 'fr': 'Grenoble'}, '351279':{'en': 'Moncorvo', 'pt': 'Moncorvo'}, '374269':{'am': u('\u054e\u0561\u0580\u0564\u0565\u0576\u056b\u057d'), 'en': 'Vardenis', 'ru': u('\u0412\u0430\u0440\u0434\u0435\u043d\u0438\u0441')}, '374264':{'am': u('\u0533\u0561\u057e\u0561\u057c/\u054d\u0561\u0580\u0578\u0582\u056d\u0561\u0576'), 'en': 'Gavar/Sarukhan', 'ru': u('\u0413\u0430\u0432\u0430\u0440/\u0421\u0430\u0440\u0443\u0445\u0430\u043d')}, '374265':{'am': u('\u0543\u0561\u0574\u0562\u0561\u0580\u0561\u056f'), 'en': 'Tchambarak', 'ru': u('\u0427\u0430\u043c\u0431\u0430\u0440\u0430\u043a')}, '374266':{'am': u('\u0532\u0565\u0580\u0564\u0561\u057e\u0561\u0576/\u053f\u0578\u0572\u0562/\u0546\u0578\u0575\u0565\u0574\u0562\u0565\u0580\u0575\u0561\u0576'), 'en': 'Berdavan/Koghb/Noyemberyan', 'ru': u('\u0411\u0435\u0440\u0434\u0430\u0432\u0430\u043d/\u041a\u043e\u0445\u0431/\u041d\u043e\u0435\u043c\u0431\u0435\u0440\u044f\u043d')}, '374267':{'am': u('\u0531\u0575\u0563\u0565\u057a\u0561\u0580/\u0532\u0565\u0580\u0564'), 'en': 'Aygepar/Berd', 'ru': u('\u0410\u0439\u0433\u0435\u043f\u0430\u0440/\u0411\u0435\u0440\u0434')}, '374261':{'am': u('\u054d\u0587\u0561\u0576'), 'en': 'Sevan', 'ru': u('\u0421\u0435\u0432\u0430\u043d')}, '374262':{'am': u('\u0544\u0561\u0580\u057f\u0578\u0582\u0576\u056b'), 'en': 'Martuni', 'ru': u('\u041c\u0430\u0440\u0442\u0443\u043d\u0438')}, '374263':{'am': u('\u053b\u057b\u0587\u0561\u0576/\u0531\u0566\u0561\u057f\u0561\u0574\u0578\u0582\u057f/\u0533\u0565\u057f\u0561\u0570\u0578\u057e\u056b\u057f/\u0535\u0576\u0578\u0584\u0561\u057e\u0561\u0576'), 'en': 'Azatamut/Getahovit/Ijevan/Yenokavan', 'ru': u('\u0410\u0437\u0430\u0442\u0430\u043c\u0443\u0442/\u0413\u0435\u0442\u0430\u0445\u043e\u0432\u0438\u0442/\u0418\u0434\u0436\u0435\u0432\u0430\u043d/\u0415\u043d\u043e\u043a\u0430\u0432\u0430\u043d')}, '432627':{'de': 'Pitten', 'en': 'Pitten'}, '432626':{'de': 'Mattersburg', 'en': 'Mattersburg'}, '441647':{'en': 'Moretonhampstead'}, '441646':{'en': 'Milford Haven'}, '441644':{'en': 'New Galloway'}, '441643':{'en': 'Minehead'}, '441642':{'en': 'Middlesbrough'}, '441641':{'en': 'Strathy'}, '3596938':{'bg': u('\u041a\u0430\u043b\u0435\u043d\u0438\u043a, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Kalenik, Lovech'}, '355388':{'en': 'Levan, Fier'}, '355389':{'en': u('Dermenas/Topoj\u00eb, Fier')}, '355386':{'en': 'Kuman/Kurjan/Strum/Ruzhdie, Fier'}, '355387':{'en': 'Cakran/Frakull, Fier'}, '355384':{'en': u('Mbrostar Ura/LIibofsh\u00eb, Fier')}, '355385':{'en': u('Port\u00ebz/Zhar\u00ebz, Fier')}, '355382':{'en': 'Roskovec, Fier'}, '355383':{'en': u('Qend\u00ebr, Fier')}, '432625':{'de': 'Bad Sauerbrunn', 'en': 'Bad Sauerbrunn'}, '355381':{'en': 'Patos, Fier'}, '390935':{'it': 'Enna'}, '390933':{'en': 'Caltanissetta', 'it': 'Caltagirone'}, '3596939':{'bg': u('\u0414\u0440\u0430\u0433\u0430\u043d\u0430'), 'en': 'Dragana'}, '390931':{'it': 'Siracusa'}, '3336673':{'en': 'Lille', 'fr': 'Lille'}, '3336672':{'en': 'Lille', 'fr': 'Lille'}, '3597179':{'bg': u('\u0413\u043e\u043b\u0435\u043c\u043e \u041c\u0430\u043b\u043e\u0432\u043e'), 'en': 'Golemo Malovo'}, '35978':{'bg': u('\u041a\u044e\u0441\u0442\u0435\u043d\u0434\u0438\u043b'), 'en': 'Kyustendil'}, '3596552':{'bg': u('\u0414\u043e\u043b\u043d\u0430 \u041c\u0438\u0442\u0440\u043e\u043f\u043e\u043b\u0438\u044f'), 'en': 'Dolna Mitropolia'}, '3596553':{'bg': u('\u041e\u0440\u044f\u0445\u043e\u0432\u0438\u0446\u0430, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Oryahovitsa, Pleven'}, '3596550':{'bg': u('\u0421\u0442\u0430\u0432\u0435\u0440\u0446\u0438'), 'en': 'Stavertsi'}, '3596551':{'bg': u('\u0422\u0440\u044a\u0441\u0442\u0435\u043d\u0438\u043a, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Trastenik, Pleven'}, '3596556':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u041c\u0438\u0442\u0440\u043e\u043f\u043e\u043b\u0438\u044f'), 'en': 'Gorna Mitropolia'}, '3596557':{'bg': u('\u0411\u0440\u0435\u0433\u0430\u0440\u0435'), 'en': 'Bregare'}, '3596554':{'bg': u('\u041a\u0440\u0443\u0448\u043e\u0432\u0435\u043d\u0435'), 'en': 'Krushovene'}, '3596555':{'bg': u('\u0411\u0430\u0439\u043a\u0430\u043b'), 'en': 'Baykal'}, '3596558':{'bg': u('\u0421\u043b\u0430\u0432\u043e\u0432\u0438\u0446\u0430, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Slavovitsa, Pleven'}, '3596559':{'bg': u('\u0413\u043e\u0441\u0442\u0438\u043b\u044f'), 'en': 'Gostilya'}, '3343765':{'en': 'Lyon', 'fr': 'Lyon'}, '3343764':{'en': 'Lyon', 'fr': 'Lyon'}, '3343766':{'en': 'Lyon', 'fr': 'Lyon'}, '441258':{'en': 'Blandford'}, '441259':{'en': 'Alloa'}, '3597172':{'bg': u('\u0414\u0440\u0430\u0433\u043e\u043c\u0430\u043d'), 'en': 'Dragoman'}, '441254':{'en': 'Blackburn'}, '3347655':{'en': 'Saint-Laurent-du-Pont', 'fr': 'Saint-Laurent-du-Pont'}, '441256':{'en': 'Basingstoke'}, '441257':{'en': 'Coppull'}, '441250':{'en': 'Blairgowrie'}, '441252':{'en': 'Aldershot'}, '3347654':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347659':{'en': 'Saint-Martin-d\'Uriage', 'fr': 'Saint-Martin-d\'Uriage'}, '3323002':{'en': 'Rennes', 'fr': 'Rennes'}, '3597174':{'bg': u('\u041a\u0430\u043b\u043e\u0442\u0438\u043d\u0430'), 'en': 'Kalotina'}, '3354584':{'en': 'Confolens', 'fr': 'Confolens'}, '3326238':{'en': 'Les Avirons', 'fr': 'Les Avirons'}, '3326239':{'en': 'Saint-Louis', 'fr': 'Saint-Louis'}, '3354581':{'en': 'Jarnac', 'fr': 'Jarnac'}, '3354583':{'en': 'Segonzac', 'fr': 'Segonzac'}, '3354582':{'en': 'Cognac', 'fr': 'Cognac'}, '3326232':{'en': 'Saint-Paul', 'fr': 'Saint-Paul'}, '3326233':{'en': 'Saint-Paul', 'fr': 'Saint-Paul'}, '3326230':{'en': 'Saint-Denis', 'fr': 'Saint-Denis'}, '3326231':{'en': 'Saint-Pierre', 'fr': 'Saint-Pierre'}, '3354589':{'en': 'Chabanais', 'fr': 'Chabanais'}, '3326237':{'en': 'Saint-Joseph', 'fr': 'Saint-Joseph'}, '3326234':{'en': 'Saint-Leu', 'fr': 'Saint-Leu'}, '3326235':{'en': 'Saint-Pierre', 'fr': 'Saint-Pierre'}, '37447':{'am': u('\u053c\u0565\u057c\u0576\u0561\u0575\u056b\u0576-\u0542\u0561\u0580\u0561\u0562\u0561\u0572'), 'en': 'Nagorno-Karabakh', 'ru': u('\u041d\u0430\u0433\u043e\u0440\u043d\u044b\u0439 \u041a\u0430\u0440\u0430\u0431\u0430\u0445')}, '437754':{'de': 'Waldzell', 'en': 'Waldzell'}, '390972':{'it': 'Melfi'}, '390973':{'it': 'Lagonegro'}, '390971':{'it': 'Potenza'}, '390976':{'it': 'Muro Lucano'}, '390974':{'en': 'Salerno', 'it': 'Vallo della Lucania'}, '390975':{'en': 'Potenza', 'it': 'Sala Consilina'}, '3593657':{'bg': u('\u0416\u044a\u043b\u0442\u0443\u0448\u0430'), 'en': 'Zhaltusha'}, '3593652':{'bg': u('\u0411\u044f\u043b \u0438\u0437\u0432\u043e\u0440, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Byal izvor, Kardzh.'}, '3593653':{'bg': u('\u041c\u043b\u0435\u0447\u0438\u043d\u043e'), 'en': 'Mlechino'}, '3593651':{'bg': u('\u0410\u0440\u0434\u0438\u043d\u043e'), 'en': 'Ardino'}, '3593658':{'bg': u('\u041f\u0430\u0434\u0438\u043d\u0430, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Padina, Kardzh.'}, '3355982':{'en': 'Pau', 'fr': 'Pau'}, '3355983':{'en': 'Pau', 'fr': 'Pau'}, '3355980':{'en': 'Pau', 'fr': 'Pau'}, '3355981':{'en': 'Lescar', 'fr': 'Lescar'}, '437750':{'de': 'Andrichsfurt', 'en': 'Andrichsfurt'}, '3355984':{'en': 'Pau', 'fr': 'Pau'}, '3355985':{'en': 'Saint-Jean-de-Luz', 'fr': 'Saint-Jean-de-Luz'}, '3355988':{'en': 'Arette', 'fr': 'Arette'}, '3593032':{'bg': u('\u0421\u0440\u0435\u0434\u043d\u043e\u0433\u043e\u0440\u0446\u0438'), 'en': 'Srednogortsi'}, '355814':{'en': u('Tepelen\u00eb')}, '355815':{'en': u('Delvin\u00eb')}, '355812':{'en': u('Ersek\u00eb, Kolonj\u00eb')}, '355813':{'en': u('P\u00ebrmet')}, '3593034':{'bg': u('\u041b\u0435\u0432\u043e\u0447\u0435\u0432\u043e'), 'en': 'Levochevo'}, '355811':{'en': 'Bilisht, Devoll'}, '3593038':{'bg': u('\u0427\u043e\u043a\u043c\u0430\u043d\u043e\u0432\u043e'), 'en': 'Chokmanovo'}, '3324039':{'en': 'Saint-Brevin-les-Pins', 'fr': 'Saint-Brevin-les-Pins'}, '3324036':{'en': 'Vallet', 'fr': 'Vallet'}, '3332778':{'en': 'Cambrai', 'fr': 'Cambrai'}, '432552':{'de': 'Poysdorf', 'en': 'Poysdorf'}, '432555':{'de': 'Herrnbaumgarten', 'en': 'Herrnbaumgarten'}, '432554':{'de': u('St\u00fctzenhofen'), 'en': u('St\u00fctzenhofen')}, '432557':{'de': 'Bernhardsthal', 'en': 'Bernhardsthal'}, '3324037':{'en': 'Nantes', 'fr': 'Nantes'}, '3332772':{'en': 'Cambrai', 'fr': 'Cambrai'}, '3332773':{'en': 'Cambrai', 'fr': 'Cambrai'}, '3332770':{'en': 'Cambrai', 'fr': 'Cambrai'}, '3332771':{'en': 'Douai', 'fr': 'Douai'}, '3332776':{'en': 'Caudry', 'fr': 'Caudry'}, '3324034':{'en': 'Vertou', 'fr': 'Vertou'}, '3332774':{'en': 'Cambrai', 'fr': 'Cambrai'}, '3332775':{'en': 'Caudry', 'fr': 'Caudry'}, '3324035':{'en': 'Nantes', 'fr': 'Nantes'}, '434258':{'de': 'Gummern', 'en': 'Gummern'}, '434254':{'de': 'Faak am See', 'en': 'Faak am See'}, '3346656':{'en': u('Al\u00e8s'), 'fr': u('Al\u00e8s')}, '434256':{'de': u('N\u00f6tsch im Gailtal'), 'en': u('N\u00f6tsch im Gailtal')}, '434257':{'de': u('F\u00fcrnitz'), 'en': u('F\u00fcrnitz')}, '434252':{'de': 'Wernberg', 'en': 'Wernberg'}, '3338043':{'en': 'Dijon', 'fr': 'Dijon'}, '437752':{'de': 'Ried im Innkreis', 'en': 'Ried im Innkreis'}, '3324030':{'en': 'Nantes', 'fr': 'Nantes'}, '3338041':{'en': 'Dijon', 'fr': 'Dijon'}, '39015':{'en': 'Biella', 'it': 'Biella'}, '433383':{'de': 'Burgau', 'en': 'Burgau'}, '3334440':{'en': u('Compi\u00e8gne'), 'fr': u('Compi\u00e8gne')}, '3355517':{'en': 'Brive-la-Gaillarde', 'fr': 'Brive-la-Gaillarde'}, '3598431':{'bg': u('\u0418\u0441\u043f\u0435\u0440\u0438\u0445'), 'en': 'Isperih'}, '3599528':{'bg': u('\u0413\u0430\u0433\u0430\u043d\u0438\u0446\u0430'), 'en': 'Gaganitsa'}, '3594562':{'bg': u('\u041a\u0440\u0438\u0432\u0430 \u043a\u0440\u0443\u0448\u0430'), 'en': 'Kriva krusha'}, '3594564':{'bg': u('\u041d\u043e\u0432\u043e\u0441\u0435\u043b\u0435\u0446'), 'en': 'Novoselets'}, '3594567':{'bg': u('\u0411\u0430\u043d\u044f, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Banya, Sliven'}, '3594566':{'bg': u('\u041f\u0438\u0442\u043e\u0432\u043e'), 'en': 'Pitovo'}, '3599522':{'bg': u('\u041a\u043e\u0442\u0435\u043d\u043e\u0432\u0446\u0438'), 'en': 'Kotenovtsi'}, '3599523':{'bg': u('\u0411\u044a\u0440\u0437\u0438\u044f'), 'en': 'Barzia'}, '3599520':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u041e\u0437\u0438\u0440\u043e\u0432\u043e'), 'en': 'Gorno Ozirovo'}, '3599521':{'bg': u('\u0417\u0430\u043c\u0444\u0438\u0440\u043e\u0432\u043e'), 'en': 'Zamfirovo'}, '3599526':{'bg': u('\u0421\u043b\u0430\u0442\u0438\u043d\u0430, \u041c\u043e\u043d\u0442.'), 'en': 'Slatina, Mont.'}, '3599527':{'bg': u('\u0412\u044a\u0440\u0448\u0435\u0446'), 'en': 'Varshets'}, '3599524':{'bg': u('\u042f\u0433\u043e\u0434\u043e\u0432\u043e, \u041c\u043e\u043d\u0442.'), 'en': 'Yagodovo, Mont.'}, '3599525':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u041e\u0437\u0438\u0440\u043e\u0432\u043e'), 'en': 'Dolno Ozirovo'}, '3595168':{'bg': u('\u041f\u0435\u0442\u0440\u043e\u0432 \u0434\u043e\u043b, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Petrov dol, Varna'}, '3595169':{'bg': u('\u041c\u043e\u043c\u0447\u0438\u043b\u043e\u0432\u043e'), 'en': 'Momchilovo'}, '3595166':{'bg': u('\u0414\u043e\u0431\u0440\u043e\u043f\u043b\u043e\u0434\u043d\u043e'), 'en': 'Dobroplodno'}, '3595167':{'bg': u('\u0412\u0435\u043d\u0447\u0430\u043d'), 'en': 'Venchan'}, '3595164':{'bg': u('\u041d\u0435\u043e\u0444\u0438\u0442 \u0420\u0438\u043b\u0441\u043a\u0438'), 'en': 'Neofit Rilski'}, '3595165':{'bg': u('\u041d\u0435\u0432\u0448\u0430'), 'en': 'Nevsha'}, '3595162':{'bg': u('\u0411\u0435\u043b\u043e\u0433\u0440\u0430\u0434\u0435\u0446'), 'en': 'Belogradets'}, '3595163':{'bg': u('\u041c\u043b\u0430\u0434\u0430 \u0433\u0432\u0430\u0440\u0434\u0438\u044f'), 'en': 'Mlada gvardia'}, '3595161':{'bg': u('\u0412\u0435\u0442\u0440\u0438\u043d\u043e'), 'en': 'Vetrino'}, '3324143':{'en': 'Angers', 'fr': 'Angers'}, '3324140':{'en': 'Saumur', 'fr': 'Saumur'}, '3324146':{'en': 'Cholet', 'fr': 'Cholet'}, '3324147':{'en': 'Angers', 'fr': 'Angers'}, '3324144':{'en': 'Angers', 'fr': 'Angers'}, '3324148':{'en': 'Angers', 'fr': 'Angers'}, '3324149':{'en': 'Cholet', 'fr': 'Cholet'}, '39011':{'en': 'Turin', 'it': 'Torino'}, '354551':{'en': u('Reykjav\u00edk/Vesturb\u00e6r/Mi\u00f0b\u00e6rinn')}, '354552':{'en': u('Reykjav\u00edk/Vesturb\u00e6r/Mi\u00f0b\u00e6rinn')}, '432266':{'de': 'Stockerau', 'en': 'Stockerau'}, '432265':{'de': 'Hausleiten', 'en': 'Hausleiten'}, '3356514':{'en': 'Figeac', 'fr': 'Figeac'}, '432264':{'de': u('R\u00fcckersdorf, Harmannsdorf'), 'en': u('R\u00fcckersdorf, Harmannsdorf')}, '3338685':{'en': u('Ch\u00e2teau-Chinon(Ville)'), 'fr': u('Ch\u00e2teau-Chinon(Ville)')}, '3338687':{'en': 'Villeneuve-sur-Yonne', 'fr': 'Villeneuve-sur-Yonne'}, '3338680':{'en': 'Migennes', 'fr': 'Migennes'}, '3338681':{'en': 'Vermenton', 'fr': 'Vermenton'}, '3338682':{'en': 'Noyers sur Serein', 'fr': 'Noyers sur Serein'}, '3338683':{'en': 'Sens', 'fr': 'Sens'}, '43732':{'de': 'Linz', 'en': 'Linz'}, '3347273':{'en': 'Lyon', 'fr': 'Lyon'}, '3347272':{'en': 'Lyon', 'fr': 'Lyon'}, '3347271':{'en': 'Lyon', 'fr': 'Lyon'}, '3347270':{'en': 'Lyon', 'fr': 'Lyon'}, '3347277':{'en': 'Lyon', 'fr': 'Lyon'}, '3347276':{'en': 'Lyon', 'fr': 'Lyon'}, '3347275':{'en': 'Lyon', 'fr': 'Lyon'}, '3347274':{'en': 'Lyon', 'fr': 'Lyon'}, '3347279':{'en': 'Saint-Priest', 'fr': 'Saint-Priest'}, '3347278':{'en': 'Lyon', 'fr': 'Lyon'}, '432663':{'de': 'Schottwien', 'en': 'Schottwien'}, '3636':{'en': 'Eger', 'hu': 'Eger'}, '3637':{'en': 'Gyongyos', 'hu': u('Gy\u00f6ngy\u00f6s')}, '3634':{'en': 'Tatabanya', 'hu': u('Tatab\u00e1nya')}, '3635':{'en': 'Balassagyarmat', 'hu': 'Balassagyarmat'}, '3632':{'en': 'Salgotarjan', 'hu': u('Salg\u00f3tarj\u00e1n')}, '3633':{'en': 'Esztergom', 'hu': 'Esztergom'}, '3596129':{'bg': u('\u0413\u0430\u0431\u0440\u043e\u0432\u0446\u0438'), 'en': 'Gabrovtsi'}, '3596128':{'bg': u('\u0425\u043e\u0442\u043d\u0438\u0446\u0430'), 'en': 'Hotnitsa'}, '3596123':{'bg': u('\u0411\u0443\u043a\u043e\u0432\u0435\u0446, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Bukovets, V. Tarnovo'}, '3596122':{'bg': u('\u0411\u0435\u043b\u044f\u043a\u043e\u0432\u0435\u0446'), 'en': 'Belyakovets'}, '3596121':{'bg': u('\u041d\u0438\u043a\u044e\u043f'), 'en': 'Nikyup'}, '432662':{'de': 'Gloggnitz', 'en': 'Gloggnitz'}, '3596126':{'bg': u('\u0426\u0435\u0440\u043e\u0432\u0430 \u043a\u043e\u0440\u0438\u044f'), 'en': 'Tserova koria'}, '3596125':{'bg': u('\u041f\u0443\u0448\u0435\u0432\u043e'), 'en': 'Pushevo'}, '3596124':{'bg': u('\u041b\u0435\u0434\u0435\u043d\u0438\u043a'), 'en': 'Ledenik'}, '3355618':{'en': 'Merignac', 'fr': u('M\u00e9rignac')}, '3338389':{'en': u('Lun\u00e9ville'), 'fr': u('Lun\u00e9ville')}, '3347099':{'en': 'Lapalisse', 'fr': 'Lapalisse'}, '3347098':{'en': 'Vichy', 'fr': 'Vichy'}, '3347097':{'en': 'Vichy', 'fr': 'Vichy'}, '3347096':{'en': 'Vichy', 'fr': 'Vichy'}, '374312':{'am': u('\u0533\u0575\u0578\u0582\u0574\u0580\u056b/\u0531\u056d\u0578\u0582\u0580\u0575\u0561\u0576'), 'en': 'Gyumri/Akhuryan region', 'ru': u('\u0413\u044e\u043c\u0440\u0438/\u0410\u0445\u0443\u0440\u044f\u043d')}, '3347090':{'en': 'Gannat', 'fr': 'Gannat'}, '435523':{'de': u('G\u00f6tzis'), 'en': u('G\u00f6tzis')}, '3346322':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '441745':{'en': 'Rhyl'}, '433581':{'de': u('Oberw\u00f6lz'), 'en': u('Oberw\u00f6lz')}, '3347897':{'en': 'Rillieux-la-Pape', 'fr': 'Rillieux-la-Pape'}, '3347896':{'en': 'Chaponnay', 'fr': 'Chaponnay'}, '3347895':{'en': 'Lyon', 'fr': 'Lyon'}, '3347894':{'en': 'Villeurbanne', 'fr': 'Villeurbanne'}, '3347893':{'en': 'Lyon', 'fr': 'Lyon'}, '3347892':{'en': 'Lyon', 'fr': 'Lyon'}, '3347891':{'en': u('Neuville-sur-Sa\u00f4ne'), 'fr': u('Neuville-sur-Sa\u00f4ne')}, '3347890':{'en': 'Genas', 'fr': 'Genas'}, '3338064':{'en': 'Saulieu', 'fr': 'Saulieu'}, '37422675':{'am': u('\u0531\u056c\u0561\u057a\u0561\u0580\u057d/\u054e\u0561\u0580\u0564\u0561\u0576\u0561\u057e\u0561\u0576\u0584'), 'en': 'Alapars/Vardanavank', 'ru': u('\u0410\u043b\u0430\u043f\u0430\u0440\u0441/\u0412\u0430\u0440\u0434\u0430\u043d\u0430\u0432\u0430\u043d\u043a')}, '37422672':{'am': u('\u0531\u0580\u0566\u0561\u056f\u0561\u0576'), 'en': 'Arzakan', 'ru': u('\u0410\u0440\u0437\u0430\u043a\u0430\u043d')}, '435525':{'de': 'Nenzing', 'en': 'Nenzing'}, '35930257':{'bg': u('\u0412\u0438\u0448\u043d\u0435\u0432\u043e'), 'en': 'Vishnevo'}, '35930256':{'bg': u('\u0413\u044a\u043b\u044a\u0431\u043e\u0432\u043e, \u0421\u043c\u043e\u043b.'), 'en': 'Galabovo, Smol.'}, '39019':{'it': 'Savona'}, '432163':{'de': 'Petronell-Carnuntum', 'en': 'Petronell-Carnuntum'}, '434710':{'de': 'Oberdrauburg', 'en': 'Oberdrauburg'}, '390565':{'en': 'Livorno', 'it': 'Piombino'}, '390564':{'it': 'Grosseto'}, '390566':{'it': 'Follonica'}, '35991180':{'bg': u('\u041b\u0435\u0441\u0443\u0440\u0430'), 'en': 'Lesura'}, '3338066':{'en': 'Dijon', 'fr': 'Dijon'}, '35991182':{'bg': u('\u041e\u0441\u0435\u043d, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Osen, Vratsa'}, '437743':{'de': 'Maria Schmolln', 'en': 'Maria Schmolln'}, '35991183':{'bg': u('\u0424\u0443\u0440\u0435\u043d'), 'en': 'Furen'}, '433327':{'de': 'Sankt Michael im Burgenland', 'en': 'St. Michael im Burgenland'}, '437747':{'de': 'Kirchberg bei Mattighofen', 'en': 'Kirchberg bei Mattighofen'}, '437746':{'de': 'Friedburg', 'en': 'Friedburg'}, '3349499':{'en': 'Vidauban', 'fr': 'Vidauban'}, '3349498':{'en': 'Le Beausset', 'fr': 'Le Beausset'}, '3349369':{'en': 'Le Cannet', 'fr': 'Le Cannet'}, '3349368':{'en': 'Cannes', 'fr': 'Cannes'}, '437745':{'de': 'Lochen', 'en': 'Lochen'}, '3349491':{'en': 'Toulon', 'fr': 'Toulon'}, '3349362':{'en': 'Nice', 'fr': 'Nice'}, '3349493':{'en': 'Toulon', 'fr': 'Toulon'}, '3349492':{'en': 'Toulon', 'fr': 'Toulon'}, '3349495':{'en': u('Saint-Rapha\u00ebl'), 'fr': u('Saint-Rapha\u00ebl')}, '3349494':{'en': 'La Seyne sur Mer', 'fr': 'La Seyne sur Mer'}, '3349365':{'en': 'Biot', 'fr': 'Biot'}, '3349496':{'en': 'Sainte-Maxime', 'fr': 'Sainte-Maxime'}, '35931708':{'bg': u('\u041f\u0435\u0441\u043d\u043e\u043f\u043e\u0439, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Pesnopoy, Plovdiv'}, '35931709':{'bg': u('\u041c\u0438\u0445\u0438\u043b\u0446\u0438'), 'en': 'Mihiltsi'}, '35931700':{'bg': u('\u0411\u0435\u043b\u043e\u0432\u0438\u0446\u0430'), 'en': 'Belovitsa'}, '35931701':{'bg': u('\u041a\u0440\u044a\u0441\u0442\u0435\u0432\u0438\u0447'), 'en': 'Krastevich'}, '35931702':{'bg': u('\u0414\u043e\u043b\u043d\u0430 \u043c\u0430\u0445\u0430\u043b\u0430, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Dolna mahala, Plovdiv'}, '35931703':{'bg': u('\u0416\u0438\u0442\u043d\u0438\u0446\u0430, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Zhitnitsa, Plovdiv'}, '35931704':{'bg': u('\u0418\u0432\u0430\u043d \u0412\u0430\u0437\u043e\u0432\u043e'), 'en': 'Ivan Vazovo'}, '35931705':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u043c\u0430\u0445\u0430\u043b\u0430'), 'en': 'Gorna mahala'}, '35931706':{'bg': u('\u0421\u0443\u0445\u043e\u0437\u0435\u043c'), 'en': 'Suhozem'}, '35931707':{'bg': u('\u0427\u0435\u0440\u043d\u043e\u0437\u0435\u043c\u0435\u043d'), 'en': 'Chernozemen'}, '433584':{'de': 'Neumarkt in Steiermark', 'en': 'Neumarkt in Steiermark'}, '3355613':{'en': 'Merignac', 'fr': u('M\u00e9rignac')}, '3751655':{'be': u('\u0421\u0442\u043e\u043b\u0456\u043d, \u0411\u0440\u044d\u0441\u0446\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Stolin, Brest Region', 'ru': u('\u0421\u0442\u043e\u043b\u0438\u043d, \u0411\u0440\u0435\u0441\u0442\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751652':{'be': u('\u0406\u0432\u0430\u043d\u0430\u0432\u0430, \u0411\u0440\u044d\u0441\u0446\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Ivanovo, Brest Region', 'ru': u('\u0418\u0432\u0430\u043d\u043e\u0432\u043e, \u0411\u0440\u0435\u0441\u0442\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3347251':{'en': u('V\u00e9nissieux'), 'fr': u('V\u00e9nissieux')}, '3751651':{'be': u('\u041c\u0430\u043b\u0430\u0440\u044b\u0442\u0430, \u0411\u0440\u044d\u0441\u0446\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Malorita, Brest Region', 'ru': u('\u041c\u0430\u043b\u043e\u0440\u0438\u0442\u0430, \u0411\u0440\u0435\u0441\u0442\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3338061':{'en': 'Nuits-Saint-Georges', 'fr': 'Nuits-Saint-Georges'}, '3349032':{'en': 'Le Pontet', 'fr': 'Le Pontet'}, '3594716':{'bg': u('\u0412\u0435\u0441\u0435\u043b\u0438\u043d\u043e\u0432\u043e, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Veselinovo, Yambol'}, '3594717':{'bg': u('\u0427\u0430\u0440\u0433\u0430\u043d'), 'en': 'Chargan'}, '3594714':{'bg': u('\u0414\u0440\u0430\u0436\u0435\u0432\u043e'), 'en': 'Drazhevo'}, '3594715':{'bg': u('\u041a\u0430\u043b\u0447\u0435\u0432\u043e'), 'en': 'Kalchevo'}, '3594712':{'bg': u('\u041a\u0430\u0431\u0438\u043b\u0435'), 'en': 'Kabile'}, '3594713':{'bg': u('\u0421\u0442\u0430\u0440\u0430 \u0440\u0435\u043a\u0430, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Stara reka, Yambol'}, '3594710':{'bg': u('\u0411\u043e\u043b\u044f\u0440\u0441\u043a\u043e'), 'en': 'Bolyarsko'}, '3594711':{'bg': u('\u0411\u0435\u0437\u043c\u0435\u0440, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Bezmer, Yambol'}, '35937706':{'bg': u('\u0427\u0435\u0440\u043d\u043e\u0434\u044a\u0431'), 'en': 'Chernodab'}, '35937707':{'bg': u('\u0429\u0438\u0442'), 'en': 'Shtit'}, '35937704':{'bg': u('\u041c\u043b\u0430\u0434\u0438\u043d\u043e\u0432\u043e'), 'en': 'Mladinovo'}, '3347250':{'en': u('V\u00e9nissieux'), 'fr': u('V\u00e9nissieux')}, '35937702':{'bg': u('\u041c\u0443\u0441\u0442\u0440\u0430\u043a'), 'en': 'Mustrak'}, '35937703':{'bg': u('\u0414\u0438\u043c\u0438\u0442\u0440\u043e\u0432\u0447\u0435'), 'en': 'Dimitrovche'}, '3594718':{'bg': u('\u0420\u043e\u0437\u0430'), 'en': 'Roza'}, '35937701':{'bg': u('\u0421\u043b\u0430\u0434\u0443\u043d'), 'en': 'Sladun'}, '3338062':{'en': 'Nuits-Saint-Georges', 'fr': 'Nuits-Saint-Georges'}, '433586':{'de': u('M\u00fchlen'), 'en': u('M\u00fchlen')}, '4418907':{'en': 'Ayton'}, '3355572':{'en': 'Ussel', 'fr': 'Ussel'}, '4418905':{'en': 'Ayton'}, '3355570':{'en': 'Aixe-sur-Vienne', 'fr': 'Aixe-sur-Vienne'}, '3355577':{'en': 'Limoges', 'fr': 'Limoges'}, '3355576':{'en': 'Bessines-sur-Gartempe', 'fr': 'Bessines-sur-Gartempe'}, '3355575':{'en': 'Saint-Yrieix-la-Perche', 'fr': 'Saint-Yrieix-la-Perche'}, '3355574':{'en': 'Brive-la-Gaillarde', 'fr': 'Brive-la-Gaillarde'}, '3355579':{'en': 'Limoges', 'fr': 'Limoges'}, '4418909':{'en': 'Ayton'}, '4418908':{'en': 'Coldstream'}, '40355':{'en': u('Cara\u0219-Severin'), 'ro': u('Cara\u0219-Severin')}, '40354':{'en': 'Hunedoara', 'ro': 'Hunedoara'}, '3332433':{'en': u('Charleville-M\u00e9zi\u00e8res'), 'fr': u('Charleville-M\u00e9zi\u00e8res')}, '40356':{'en': u('Timi\u0219'), 'ro': u('Timi\u0219')}, '40351':{'en': 'Dolj', 'ro': 'Dolj'}, '40350':{'en': u('V\u00e2lcea'), 'ro': u('V\u00e2lcea')}, '3332437':{'en': u('Charleville-M\u00e9zi\u00e8res'), 'fr': u('Charleville-M\u00e9zi\u00e8res')}, '3332436':{'en': u('Charleville-M\u00e9zi\u00e8res'), 'fr': u('Charleville-M\u00e9zi\u00e8res')}, '3332439':{'en': 'Rethel', 'fr': 'Rethel'}, '3332438':{'en': 'Rethel', 'fr': 'Rethel'}, '40359':{'en': 'Bihor', 'ro': 'Bihor'}, '40358':{'en': 'Alba', 'ro': 'Alba'}, '432618':{'de': 'Markt Sankt Martin', 'en': 'Markt St. Martin'}, '432619':{'de': 'Lackendorf', 'en': 'Lackendorf'}, '35982':{'bg': u('\u0420\u0443\u0441\u0435'), 'en': 'Ruse'}, '35984':{'bg': u('\u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Razgrad'}, '35986':{'bg': u('\u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Silistra'}, '437432':{'de': 'Strengberg', 'en': 'Strengberg'}, '3355799':{'en': 'Villenave-d\'Ornon', 'fr': 'Villenave-d\'Ornon'}, '3355798':{'en': 'Langon', 'fr': 'Langon'}, '3355796':{'en': 'Gradignan', 'fr': 'Gradignan'}, '3355795':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355794':{'en': u('Saint-Andr\u00e9-de-Cubzac'), 'fr': u('Saint-Andr\u00e9-de-Cubzac')}, '3355793':{'en': 'Eysines', 'fr': 'Eysines'}, '3355792':{'en': 'Merignac', 'fr': u('M\u00e9rignac')}, '3356219':{'en': 'Ramonville-Saint-Agne', 'fr': 'Ramonville-Saint-Agne'}, '3356212':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356211':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356217':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356216':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356214':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356560':{'en': 'Millau', 'fr': 'Millau'}, '3325158':{'en': 'Saint-Jean-de-Monts', 'fr': 'Saint-Jean-de-Monts'}, '3593693':{'bg': u('\u041b\u044f\u0441\u043a\u043e\u0432\u043e, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Lyaskovo, Kardzh.'}, '3325156':{'en': u('Lu\u00e7on'), 'fr': u('Lu\u00e7on')}, '3325157':{'en': 'Pouzauges', 'fr': 'Pouzauges'}, '3325154':{'en': 'Saint-Hilaire-de-Riez', 'fr': 'Saint-Hilaire-de-Riez'}, '3325155':{'en': 'Saint-Gilles-Croix-de-Vie', 'fr': 'Saint-Gilles-Croix-de-Vie'}, '3325153':{'en': 'Saint-Martin-de-Fraigneau', 'fr': 'Saint-Martin-de-Fraigneau'}, '3325150':{'en': 'Fontenay-le-Comte', 'fr': 'Fontenay-le-Comte'}, '3593923':{'bg': u('\u0420\u0430\u0434\u0438\u0435\u0432\u043e'), 'en': 'Radievo'}, '3593924':{'bg': u('\u041a\u0440\u0435\u043f\u043e\u0441\u0442'), 'en': 'Krepost'}, '3705':{'en': 'Vilnius'}, '3344209':{'en': 'Marignane', 'fr': 'Marignane'}, '3344208':{'en': 'La Ciotat', 'fr': 'La Ciotat'}, '35368':{'en': 'Listowel'}, '35369':{'en': 'Newcastle West'}, '35364':{'en': 'Killarney/Rathmore'}, '35365':{'en': 'Ennis/Ennistymon/Kilrush'}, '35366':{'en': 'Tralee/Dingle/Killorglin/Cahersiveen'}, '35367':{'en': 'Nenagh'}, '3344207':{'en': 'Martigues', 'fr': 'Martigues'}, '3344206':{'en': 'Port-de-Bouc', 'fr': 'Port-de-Bouc'}, '3344205':{'en': 'Fos-sur-Mer', 'fr': 'Fos-sur-Mer'}, '3344204':{'en': 'Roquevaire', 'fr': 'Roquevaire'}, '46291':{'en': u('Hedesunda-\u00d6sterf\u00e4rnebo'), 'sv': u('Hedesunda-\u00d6sterf\u00e4rnebo')}, '370349':{'en': 'Jonava'}, '370347':{'en': u('K\u0117dainiai')}, '370346':{'en': u('Kai\u0161iadorys')}, '370345':{'en': u('\u0160akiai')}, '370343':{'en': u('Marijampol\u0117')}, '370342':{'en': u('Vilkavi\u0161kis')}, '370340':{'en': u('Ukmerg\u0117')}, '351251':{'en': u('Valen\u00e7a'), 'pt': u('Valen\u00e7a')}, '351252':{'en': u('V. N. de Famalic\u00e3o'), 'pt': u('V. N. de Famalic\u00e3o')}, '351253':{'en': 'Braga', 'pt': 'Braga'}, '351254':{'en': u('Peso da R\u00e9gua'), 'pt': u('Peso da R\u00e9gua')}, '351255':{'en': 'Penafiel', 'pt': 'Penafiel'}, '351256':{'en': u('S. Jo\u00e3o da Madeira'), 'pt': u('S. Jo\u00e3o da Madeira')}, '351258':{'en': 'Viana do Castelo', 'pt': 'Viana do Castelo'}, '351259':{'en': 'Vila Real', 'pt': 'Vila Real'}, '3347237':{'en': 'Bron', 'fr': 'Bron'}, '3599338':{'bg': u('\u0428\u0438\u0448\u0435\u043d\u0446\u0438'), 'en': 'Shishentsi'}, '3347236':{'en': 'Lyon', 'fr': 'Lyon'}, '3595590':{'bg': u('\u0416\u0438\u0442\u043e\u0441\u0432\u044f\u0442'), 'en': 'Zhitosvyat'}, '3595599':{'bg': u('\u0425\u0430\u0434\u0436\u0438\u0438\u0442\u0435'), 'en': 'Hadzhiite'}, '441629':{'en': 'Matlock'}, '441628':{'en': 'Maidenhead'}, '441621':{'en': 'Maldon'}, '441620':{'en': 'North Berwick'}, '441623':{'en': 'Mansfield'}, '441622':{'en': 'Maidstone'}, '441625':{'en': 'Macclesfield'}, '441624':{'en': 'Isle of Man'}, '3599332':{'bg': u('\u0420\u0430\u043a\u043e\u0432\u0438\u0446\u0430'), 'en': 'Rakovitsa'}, '3596710':{'bg': u('\u0414\u043e\u043d\u0438\u043d\u043e'), 'en': 'Donino'}, '3596711':{'bg': u('\u041a\u043e\u0437\u0438 \u0440\u043e\u0433'), 'en': 'Kozi rog'}, '3596712':{'bg': u('\u0413\u044a\u0431\u0435\u043d\u0435'), 'en': 'Gabene'}, '3596713':{'bg': u('\u0412\u0440\u0430\u043d\u0438\u043b\u043e\u0432\u0446\u0438'), 'en': 'Vranilovtsi'}, '3596714':{'bg': u('\u041f\u043e\u043f\u043e\u0432\u0446\u0438'), 'en': 'Popovtsi'}, '3596716':{'bg': u('\u0416\u044a\u043b\u0442\u0435\u0448'), 'en': 'Zhaltesh'}, '3596717':{'bg': u('\u041b\u0435\u0441\u0438\u0447\u0430\u0440\u043a\u0430'), 'en': 'Lesicharka'}, '3596718':{'bg': u('\u0414\u0440\u0430\u0433\u0430\u043d\u043e\u0432\u0446\u0438'), 'en': 'Draganovtsi'}, '442889':{'en': 'Fivemiletown'}, '3597448':{'bg': u('\u0411\u0430\u0447\u0435\u0432\u043e'), 'en': 'Bachevo'}, '3355674':{'en': 'Lormont', 'fr': 'Lormont'}, '3597446':{'bg': u('\u0415\u043b\u0435\u0448\u043d\u0438\u0446\u0430, \u0411\u043b\u0430\u0433.'), 'en': 'Eleshnitsa, Blag.'}, '3597445':{'bg': u('\u0411\u0430\u043d\u044f, \u0411\u043b\u0430\u0433.'), 'en': 'Banya, Blag.'}, '3597444':{'bg': u('\u0411\u0435\u043b\u0438\u0446\u0430, \u0411\u043b\u0430\u0433.'), 'en': 'Belitsa, Blag.'}, '3597442':{'bg': u('\u042f\u043a\u043e\u0440\u0443\u0434\u0430'), 'en': 'Yakoruda'}, '436478':{'de': 'Zederhaus', 'en': 'Zederhaus'}, '436479':{'de': 'Muhr', 'en': 'Muhr'}, '436476':{'de': 'Sankt Margarethen im Lungau', 'en': 'St. Margarethen im Lungau'}, '436477':{'de': 'Sankt Michael im Lungau', 'en': 'St. Michael im Lungau'}, '436474':{'de': 'Tamsweg', 'en': 'Tamsweg'}, '436475':{'de': 'Ramingstein', 'en': 'Ramingstein'}, '436472':{'de': 'Mauterndorf', 'en': 'Mauterndorf'}, '436473':{'de': 'Mariapfarr', 'en': 'Mariapfarr'}, '436470':{'de': 'Atzmannsdorf', 'en': 'Atzmannsdorf'}, '436471':{'de': 'Tweng', 'en': 'Tweng'}, '3338147':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3338146':{'en': 'Pontarlier', 'fr': 'Pontarlier'}, '3338141':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3338140':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3338148':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '390371':{'en': 'Lodi', 'it': 'Lodi'}, '390925':{'en': 'Agrigento', 'it': 'Sciacca'}, '3595115':{'bg': u('\u0413\u0435\u043d\u0435\u0440\u0430\u043b \u041a\u0430\u043d\u0442\u0430\u0440\u0434\u0436\u0438\u0435\u0432\u043e'), 'en': 'General Kantardzhievo'}, '3343785':{'en': 'Rillieux-la-Pape', 'fr': 'Rillieux-la-Pape'}, '3597192':{'bg': u('\u0413\u0438\u043d\u0446\u0438'), 'en': 'Gintsi'}, '390924':{'en': 'Trapani', 'it': 'Alcamo'}, '3595114':{'bg': u('\u0415\u0437\u0435\u0440\u043e\u0432\u043e, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Ezerovo, Varna'}, '35857':{'en': 'Kymi', 'fi': 'Kymi', 'se': 'Kymmene'}, '35854':{'en': 'Kymi', 'fi': 'Kymi', 'se': 'Kymmene'}, '35855':{'en': 'Kymi', 'fi': 'Kymi', 'se': 'Kymmene'}, '35984774':{'bg': u('\u0413\u043e\u043b\u044f\u043c \u0438\u0437\u0432\u043e\u0440, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Golyam izvor, Razgrad'}, '35984776':{'bg': u('\u0425\u044a\u0440\u0441\u043e\u0432\u043e, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Harsovo, Razgrad'}, '35984779':{'bg': u('\u0417\u0434\u0440\u0430\u0432\u0435\u0446, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Zdravets, Razgrad'}, '35852':{'en': 'Kymi', 'fi': 'Kymi', 'se': 'Kymmene'}, '35853':{'en': 'Kymi', 'fi': 'Kymi', 'se': 'Kymmene'}, '3329705':{'en': u('Qu\u00e9ven'), 'fr': u('Qu\u00e9ven')}, '46246':{'en': u('Sv\u00e4rdsj\u00f6-Enviken'), 'sv': u('Sv\u00e4rdsj\u00f6-Enviken')}, '46241':{'en': 'Gagnef-Floda', 'sv': 'Gagnef-Floda'}, '3329702':{'en': 'Guidel', 'fr': 'Guidel'}, '3354569':{'en': 'Champniers', 'fr': 'Champniers'}, '3354568':{'en': 'Gond-Pontouvre', 'fr': 'Gond-Pontouvre'}, '3354567':{'en': 'La Couronne', 'fr': 'La Couronne'}, '3354566':{'en': u('Roullet-Saint-Est\u00e8phe'), 'fr': u('Roullet-Saint-Est\u00e8phe')}, '35851':{'en': 'Kymi', 'fi': 'Kymi', 'se': 'Kymmene'}, '3354563':{'en': 'La Rochefoucauld', 'fr': 'La Rochefoucauld'}, '46248':{'en': u('R\u00e4ttvik'), 'sv': u('R\u00e4ttvik')}, '3354561':{'en': u('Angoul\u00eame'), 'fr': u('Angoul\u00eame')}, '3329708':{'en': 'Baud', 'fr': 'Baud'}, '3338534':{'en': u('M\u00e2con'), 'fr': u('M\u00e2con')}, '3338532':{'en': 'Tournus', 'fr': 'Tournus'}, '3338531':{'en': 'Replonges', 'fr': 'Replonges'}, '3342789':{'en': 'Lyon', 'fr': 'Lyon'}, '3338538':{'en': u('M\u00e2con'), 'fr': u('M\u00e2con')}, '3338539':{'en': u('M\u00e2con'), 'fr': u('M\u00e2con')}, '3323281':{'en': 'Rouen', 'fr': 'Rouen'}, '3323282':{'en': 'Maromme', 'fr': 'Maromme'}, '3323283':{'en': 'Rouen', 'fr': 'Rouen'}, '3323284':{'en': 'Notre-Dame-de-Gravenchon', 'fr': 'Notre-Dame-de-Gravenchon'}, '3323289':{'en': 'Gournay-en-Bray', 'fr': 'Gournay-en-Bray'}, '3349803':{'en': 'Toulon', 'fr': 'Toulon'}, '3349800':{'en': 'Toulon', 'fr': 'Toulon'}, '3349805':{'en': 'Saint-Maximin-la-Sainte-Baume', 'fr': 'Saint-Maximin-la-Sainte-Baume'}, '3359663':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3359662':{'en': u('Rivi\u00e8re-Pilote'), 'fr': u('Rivi\u00e8re-Pilote')}, '3359661':{'en': 'Schoelcher', 'fr': 'Schoelcher'}, '3359660':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3359667':{'en': 'Gros-Morne', 'fr': 'Gros-Morne'}, '4416975':{'en': 'Brampton'}, '3359665':{'en': 'Le Robert', 'fr': 'Le Robert'}, '3359664':{'en': 'Fort de France', 'fr': 'Fort de France'}, '4416978':{'en': 'Brampton'}, '4416979':{'en': 'Brampton'}, '3359669':{'en': 'Sainte Marie', 'fr': 'Sainte Marie'}, '3359668':{'en': u('Rivi\u00e8re-Sal\u00e9e'), 'fr': u('Rivi\u00e8re-Sal\u00e9e')}, '3593631':{'bg': u('\u041c\u043e\u043c\u0447\u0438\u043b\u0433\u0440\u0430\u0434'), 'en': 'Momchilgrad'}, '3593632':{'bg': u('\u0414\u0436\u0435\u0431\u0435\u043b'), 'en': 'Dzhebel'}, '3593633':{'bg': u('\u0420\u043e\u0433\u043e\u0437\u0447\u0435'), 'en': 'Rogozche'}, '3593634':{'bg': u('\u041f\u0440\u0438\u043f\u0435\u043a, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Pripek, Kardzh.'}, '436434':{'de': 'Bad Gastein', 'en': 'Bad Gastein'}, '3593636':{'bg': u('\u0420\u0430\u0432\u0435\u043d'), 'en': 'Raven'}, '3593637':{'bg': u('\u0413\u0440\u0443\u0435\u0432\u043e'), 'en': 'Gruevo'}, '3593638':{'bg': u('\u0417\u0432\u0435\u0437\u0434\u0435\u043b'), 'en': 'Zvezdel'}, '3593639':{'bg': u('\u041d\u0430\u043d\u043e\u0432\u0438\u0446\u0430, \u041a\u044a\u0440\u0434\u0436.'), 'en': 'Nanovitsa, Kardzh.'}, '3347774':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347775':{'en': 'Rive-de-Gier', 'fr': 'Rive-de-Gier'}, '3347996':{'en': u('Chamb\u00e9ry'), 'fr': u('Chamb\u00e9ry')}, '3593079':{'bg': u('\u041a\u043e\u0437\u0430\u0440\u043a\u0430'), 'en': 'Kozarka'}, '35941270':{'bg': u('\u041c\u0430\u043b\u043a\u0430 \u0412\u0435\u0440\u0435\u044f'), 'en': 'Malka Vereya'}, '35941277':{'bg': u('\u0417\u0430\u0433\u043e\u0440\u0435'), 'en': 'Zagore'}, '3355969':{'en': 'Orthez', 'fr': 'Orthez'}, '3329859':{'en': 'Rosporden', 'fr': 'Rosporden'}, '3329858':{'en': 'Penmarch', 'fr': 'Penmarch'}, '3355964':{'en': 'Tarnos', 'fr': 'Tarnos'}, '3355965':{'en': 'Saint-Palais', 'fr': 'Saint-Palais'}, '3355966':{'en': 'Navarrenx', 'fr': 'Navarrenx'}, '3355967':{'en': 'Orthez', 'fr': 'Orthez'}, '3355960':{'en': 'Mourenx', 'fr': 'Mourenx'}, '3355961':{'en': 'Nay', 'fr': 'Nay'}, '3355962':{'en': 'Lons', 'fr': 'Lons'}, '3355963':{'en': 'Anglet', 'fr': 'Anglet'}, '435446':{'de': 'Sankt Anton am Arlberg', 'en': 'St. Anton am Arlberg'}, '3355538':{'en': 'Limoges', 'fr': 'Limoges'}, '435444':{'de': 'Ischgl', 'en': 'Ischgl'}, '435445':{'de': 'Kappl', 'en': 'Kappl'}, '432573':{'de': 'Wilfersdorf', 'en': 'Wilfersdorf'}, '432572':{'de': 'Mistelbach', 'en': 'Mistelbach'}, '3593071':{'bg': u('\u0417\u043b\u0430\u0442\u043e\u0433\u0440\u0430\u0434'), 'en': 'Zlatograd'}, '432577':{'de': 'Asparn an der Zaya', 'en': 'Asparn an der Zaya'}, '432576':{'de': 'Ernstbrunn', 'en': 'Ernstbrunn'}, '432575':{'de': 'Ladendorf', 'en': 'Ladendorf'}, '432574':{'de': 'Gaweinstal', 'en': 'Gaweinstal'}, '3359087':{'en': u('Saint Barth\u00e9l\u00e9my'), 'fr': u('Saint Barth\u00e9l\u00e9my')}, '3359086':{'en': 'Capesterre Belle Eau', 'fr': 'Capesterre Belle Eau'}, '3359085':{'en': 'Sainte-Anne', 'fr': 'Sainte-Anne'}, '3359084':{'en': 'Le Gosier', 'fr': 'Le Gosier'}, '3359083':{'en': u('Pointe-\u00e0-Pitre'), 'fr': u('Pointe-\u00e0-Pitre')}, '3359082':{'en': u('Pointe-\u00e0-Pitre'), 'fr': u('Pointe-\u00e0-Pitre')}, '3359081':{'en': 'Basse Terre', 'fr': 'Basse Terre'}, '3359080':{'en': 'Saint-Claude', 'fr': 'Saint-Claude'}, '435441':{'de': 'See', 'en': 'See'}, '3359089':{'en': 'Les Abymes', 'fr': 'Les Abymes'}, '3359088':{'en': 'Sainte-Anne', 'fr': 'Sainte-Anne'}, '432536':{'de': u('Dr\u00f6sing'), 'en': u('Dr\u00f6sing')}, '435448':{'de': 'Pettneu am Arlberg', 'en': 'Pettneu am Arlberg'}, '3594369':{'bg': u('\u0410\u043b\u0435\u043a\u0441\u0430\u043d\u0434\u0440\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Aleksandrovo, St. Zagora'}, '3594368':{'bg': u('\u0422\u044a\u0440\u043d\u0438\u0447\u0435\u043d\u0438'), 'en': 'Tarnicheni'}, '3594367':{'bg': u('\u0422\u044a\u0436\u0430'), 'en': 'Tazha'}, '3594364':{'bg': u('\u041e\u0441\u0435\u0442\u0435\u043d\u043e\u0432\u043e'), 'en': 'Osetenovo'}, '3594363':{'bg': u('\u0413\u0430\u0431\u0430\u0440\u0435\u0432\u043e'), 'en': 'Gabarevo'}, '3594362':{'bg': u('\u041c\u0430\u043d\u043e\u043b\u043e\u0432\u043e'), 'en': 'Manolovo'}, '3594361':{'bg': u('\u041f\u0430\u0432\u0435\u043b \u0431\u0430\u043d\u044f'), 'en': 'Pavel banya'}, '3595368':{'bg': u('\u0422\u044a\u043a\u0430\u0447'), 'en': 'Takach'}, '441439':{'en': 'Helmsley'}, '3595365':{'bg': u('\u041b\u044f\u0442\u043d\u043e'), 'en': 'Lyatno'}, '3595366':{'bg': u('\u0411\u0440\u0430\u043d\u0438\u0447\u0435\u0432\u043e'), 'en': 'Branichevo'}, '3595367':{'bg': u('\u0422\u043e\u0434\u043e\u0440 \u0418\u043a\u043e\u043d\u043e\u043c\u043e\u0432\u043e'), 'en': 'Todor Ikonomovo'}, '3595361':{'bg': u('\u041a\u0430\u043e\u043b\u0438\u043d\u043e\u0432\u043e'), 'en': 'Kaolinovo'}, '3595362':{'bg': u('\u041a\u043b\u0438\u043c\u0435\u043d\u0442, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Kliment, Shumen'}, '3595363':{'bg': u('\u0413\u0443\u0441\u043b\u0430'), 'en': 'Gusla'}, '3752345':{'be': u('\u041a\u0430\u043b\u0456\u043d\u043a\u0430\u0432\u0456\u0447\u044b'), 'en': 'Kalinkovichi', 'ru': u('\u041a\u0430\u043b\u0438\u043d\u043a\u043e\u0432\u0438\u0447\u0438')}, '3338853':{'en': 'Drusenheim', 'fr': 'Drusenheim'}, '3752346':{'be': u('\u0425\u043e\u0439\u043d\u0456\u043a\u0456, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Khoiniki, Gomel Region', 'ru': u('\u0425\u043e\u0439\u043d\u0438\u043a\u0438, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752340':{'be': u('\u0420\u044d\u0447\u044b\u0446\u0430'), 'en': 'Rechitsa', 'ru': u('\u0420\u0435\u0447\u0438\u0446\u0430')}, '3752342':{'be': u('\u0421\u0432\u0435\u0442\u043b\u0430\u0433\u043e\u0440\u0441\u043a'), 'en': 'Svetlogorsk', 'ru': u('\u0421\u0432\u0435\u0442\u043b\u043e\u0433\u043e\u0440\u0441\u043a')}, '441435':{'en': 'Heathfield'}, '3334464':{'en': 'Creil', 'fr': 'Creil'}, '3598674':{'bg': u('\u041f\u0440\u043e\u0444\u0435\u0441\u043e\u0440 \u0418\u0448\u0438\u0440\u043a\u043e\u0432\u043e'), 'en': 'Profesor Ishirkovo'}, '3334466':{'en': 'Nogent-sur-Oise', 'fr': 'Nogent-sur-Oise'}, '3598676':{'bg': u('\u0412\u0435\u0442\u0440\u0435\u043d, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Vetren, Silistra'}, '3334460':{'en': 'Senlis', 'fr': 'Senlis'}, '3334462':{'en': 'Chantilly', 'fr': 'Chantilly'}, '3334463':{'en': 'Senlis', 'fr': 'Senlis'}, '3595100':{'bg': u('\u0421\u0438\u043d\u0434\u0435\u043b'), 'en': 'Sindel'}, '3595101':{'bg': u('\u0414\u044a\u0431\u0440\u0430\u0432\u0438\u043d\u043e'), 'en': 'Dabravino'}, '3595102':{'bg': u('\u041f\u0430\u0434\u0438\u043d\u0430, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Padina, Varna'}, '3598679':{'bg': u('\u041a\u0430\u0439\u043d\u0430\u0440\u0434\u0436\u0430'), 'en': 'Kaynardzha'}, '3595105':{'bg': u('\u041f\u0440\u0438\u0441\u0435\u043b\u0446\u0438, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Priseltsi, Varna'}, '3595106':{'bg': u('\u0410\u0432\u0440\u0435\u043d, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Avren, Varna'}, '3338338':{'en': 'Champigneulles', 'fr': 'Champigneulles'}, '3338339':{'en': 'Nancy', 'fr': 'Nancy'}, '3338335':{'en': 'Nancy', 'fr': 'Nancy'}, '3338336':{'en': 'Nancy', 'fr': 'Nancy'}, '3338337':{'en': 'Nancy', 'fr': 'Nancy'}, '3338330':{'en': 'Nancy', 'fr': 'Nancy'}, '3338332':{'en': 'Nancy', 'fr': 'Nancy'}, '3338333':{'en': 'Nancy', 'fr': 'Nancy'}, '3355694':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '432766':{'de': 'Kleinzell', 'en': 'Kleinzell'}, '353504':{'en': 'Thurles'}, '353505':{'en': 'Roscrea'}, '432767':{'de': 'Hohenberg', 'en': 'Hohenberg'}, '390721':{'it': 'Pesaro'}, '432764':{'de': 'Hainfeld', 'en': 'Hainfeld'}, '432765':{'de': 'Kaumberg', 'en': 'Kaumberg'}, '432812':{'de': u('Gro\u00df Gerungs'), 'en': 'Gross Gerungs'}, '3356538':{'en': u('Saint-C\u00e9r\u00e9'), 'fr': u('Saint-C\u00e9r\u00e9')}, '3356539':{'en': 'Bretenoux', 'fr': 'Bretenoux'}, '3356534':{'en': 'Figeac', 'fr': 'Figeac'}, '3356535':{'en': 'Cahors', 'fr': 'Cahors'}, '3356530':{'en': 'Cahors', 'fr': 'Cahors'}, '3347259':{'en': 'Tassin-la-Demi-Lune', 'fr': 'Tassin-la-Demi-Lune'}, '3347529':{'en': 'Le Cheylard', 'fr': 'Le Cheylard'}, '3347528':{'en': 'Buis-les-Baronnies', 'fr': 'Buis-les-Baronnies'}, '3347526':{'en': 'Nyons', 'fr': 'Nyons'}, '3347525':{'en': 'Crest', 'fr': 'Crest'}, '3347256':{'en': 'Lyon', 'fr': 'Lyon'}, '3347523':{'en': 'Saint-Vallier', 'fr': 'Saint-Vallier'}, '3347522':{'en': 'Die', 'fr': 'Die'}, '3347253':{'en': 'Lyon', 'fr': 'Lyon'}, '3347252':{'en': 'Dardilly', 'fr': 'Dardilly'}, '35393':{'en': 'Tuam'}, '4414239':{'en': 'Boroughbridge'}, '4414238':{'en': 'Harrogate'}, '4414235':{'en': 'Harrogate'}, '4414234':{'en': 'Boroughbridge'}, '4414237':{'en': 'Harrogate'}, '4414236':{'en': 'Harrogate'}, '4414231':{'en': 'Harrogate/Boroughbridge'}, '4414230':{'en': 'Harrogate/Boroughbridge'}, '4414233':{'en': 'Boroughbridge'}, '4414232':{'en': 'Harrogate'}, '435553':{'de': 'Raggal', 'en': 'Raggal'}, '441433':{'en': 'Hathersage'}, '3332714':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '44208':{'en': 'London'}, '332282':{'en': 'Nantes', 'fr': 'Nantes'}, '37426374':{'am': u('\u0531\u0575\u0563\u0565\u0570\u0578\u057e\u056b\u057f'), 'en': 'Aygehovit', 'ru': u('\u0410\u0439\u0433\u0435\u0445\u043e\u0432\u0438\u0442')}, '44207':{'en': 'London'}, '42049':{'en': u('Hradec Kr\u00e1lov\u00e9 Region')}, '42048':{'en': 'Liberec Region'}, '42041':{'en': u('\u00dast\u00ed nad Labem Region')}, '42047':{'en': u('\u00dast\u00ed nad Labem Region')}, '42046':{'en': 'Pardubice Region'}, '390547':{'it': 'Cesena'}, '390546':{'it': 'Faenza'}, '390545':{'en': 'Ravenna', 'it': 'Lugo'}, '390544':{'it': 'Ravenna'}, '390543':{'en': u('Forl\u00ec-Cesena'), 'it': u('Forl\u00ec')}, '390542':{'it': 'Imola'}, '390541':{'en': 'Rimini', 'it': 'Rimini'}, '390549':{'en': 'San Marino', 'it': 'Repubblica di San Marino'}, '3349169':{'en': 'Marseille', 'fr': 'Marseille'}, '3349168':{'en': 'Allauch', 'fr': 'Allauch'}, '3349161':{'en': 'Marseille', 'fr': 'Marseille'}, '3349160':{'en': 'Marseille', 'fr': 'Marseille'}, '3349163':{'en': 'Marseille', 'fr': 'Marseille'}, '3349162':{'en': 'Marseille', 'fr': 'Marseille'}, '3349165':{'en': 'Marseille', 'fr': 'Marseille'}, '3349164':{'en': 'Marseille', 'fr': 'Marseille'}, '3349167':{'en': 'Marseille', 'fr': 'Marseille'}, '3349166':{'en': 'Marseille', 'fr': 'Marseille'}, '3522499':{'de': 'Ulflingen', 'en': 'Troisvierges', 'fr': 'Troisvierges'}, '3522492':{'de': 'Kanton Clerf/Fischbach/Hosingen', 'en': 'Clervaux/Fischbach/Hosingen', 'fr': 'Clervaux/Fischbach/Hosingen'}, '3522495':{'de': 'Wiltz', 'en': 'Wiltz', 'fr': 'Wiltz'}, '3522497':{'de': 'Huldingen', 'en': 'Huldange', 'fr': 'Huldange'}, '3349345':{'en': 'Le Cannet', 'fr': 'Le Cannet'}, '3349344':{'en': 'Nice', 'fr': 'Nice'}, '3349347':{'en': 'Cannes', 'fr': 'Cannes'}, '3349346':{'en': 'Le Cannet', 'fr': 'Le Cannet'}, '3349341':{'en': 'Menton', 'fr': 'Menton'}, '3349340':{'en': 'Grasse', 'fr': 'Grasse'}, '3349343':{'en': 'Cannes', 'fr': 'Cannes'}, '3349349':{'en': 'Mandelieu-la-Napoule', 'fr': 'Mandelieu-la-Napoule'}, '3349348':{'en': 'Cannes', 'fr': 'Cannes'}, '3522634':{'de': 'Rammeldingen/Senningerberg', 'en': 'Rameldange/Senningerberg', 'fr': 'Rameldange/Senningerberg'}, '3522635':{'de': 'Sandweiler/Mutfort/Roodt-sur-Syre', 'en': 'Sandweiler/Moutfort/Roodt-sur-Syre', 'fr': 'Sandweiler/Moutfort/Roodt-sur-Syre'}, '3522636':{'de': 'Hesperingen/Kockelscheuer/Roeser', 'en': 'Hesperange/Kockelscheuer/Roeser', 'fr': 'Hesperange/Kockelscheuer/Roeser'}, '3522637':{'de': 'Leudelingen/Ehlingen/Monnerich', 'en': 'Leudelange/Ehlange/Mondercange', 'fr': 'Leudelange/Ehlange/Mondercange'}, '3522630':{'de': 'Kanton Capellen/Kehlen', 'en': 'Capellen/Kehlen', 'fr': 'Capellen/Kehlen'}, '3522631':{'de': 'Bartringen', 'en': 'Bertrange', 'fr': 'Bertrange'}, '3522632':{'de': 'Lintgen/Kanton Mersch/Steinfort', 'en': 'Lintgen/Mersch/Steinfort', 'fr': 'Lintgen/Mersch/Steinfort'}, '3522633':{'de': 'Walferdingen', 'en': 'Walferdange', 'fr': 'Walferdange'}, '3522639':{'de': 'Windhof/Steinfort', 'en': 'Windhof/Steinfort', 'fr': 'Windhof/Steinfort'}, '35984738':{'bg': u('\u041a\u0438\u0442\u0430\u043d\u0447\u0435\u0432\u043e'), 'en': 'Kitanchevo'}, '37037':{'en': 'Kaunas'}, '436138':{'de': 'Sankt Wolfgang im Salzkammergut', 'en': 'St. Wolfgang im Salzkammergut'}, '436137':{'de': 'Strobl', 'en': 'Strobl'}, '436136':{'de': 'Gosau', 'en': 'Gosau'}, '436135':{'de': 'Bad Goisern', 'en': 'Bad Goisern'}, '436134':{'de': 'Hallstatt', 'en': 'Hallstatt'}, '436133':{'de': 'Ebensee', 'en': 'Ebensee'}, '436132':{'de': 'Bad Ischl', 'en': 'Bad Ischl'}, '436131':{'de': 'Obertraun', 'en': 'Obertraun'}, '3355374':{'en': 'Bergerac', 'fr': 'Bergerac'}, '3338490':{'en': 'Belfort', 'fr': 'Belfort'}, '3338493':{'en': 'Luxeuil-les-Bains', 'fr': 'Luxeuil-les-Bains'}, '3338495':{'en': 'Saulx', 'fr': 'Saulx'}, '3338497':{'en': 'Vesoul', 'fr': 'Vesoul'}, '3338496':{'en': 'Vesoul', 'fr': 'Vesoul'}, '3338946':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3338945':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3338944':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3338943':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3338942':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3338941':{'en': 'Colmar', 'fr': 'Colmar'}, '3338940':{'en': 'Altkirch', 'fr': 'Altkirch'}, '3332180':{'en': 'Boulogne-sur-Mer', 'fr': 'Boulogne-sur-Mer'}, '35984736':{'bg': u('\u041f\u043e\u0434\u0430\u0439\u0432\u0430'), 'en': 'Podayva'}, '3332185':{'en': 'Calais', 'fr': 'Calais'}, '3332187':{'en': 'Boulogne-sur-Mer', 'fr': 'Boulogne-sur-Mer'}, '3332636':{'en': 'Reims', 'fr': 'Reims'}, '3332635':{'en': 'Reims', 'fr': 'Reims'}, '3332632':{'en': u('\u00c9pernay'), 'fr': u('\u00c9pernay')}, '3594770':{'bg': u('\u0413\u0435\u043d\u0435\u0440\u0430\u043b \u0418\u043d\u0437\u043e\u0432\u043e'), 'en': 'General Inzovo'}, '3594771':{'bg': u('\u041c\u0430\u043b\u043e\u043c\u0438\u0440, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Malomir, Yambol'}, '3594772':{'bg': u('\u0421\u0438\u043c\u0435\u043e\u043d\u043e\u0432\u043e, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Simeonovo, Yambol'}, '3594773':{'bg': u('\u041e\u043a\u043e\u043f'), 'en': 'Okop'}, '3594774':{'bg': u('\u041a\u0440\u0443\u043c\u043e\u0432\u043e, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Krumovo, Yambol'}, '3594775':{'bg': u('\u041a\u0430\u0440\u0430\u0432\u0435\u043b\u043e\u0432\u043e, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Karavelovo, Yambol'}, '3354792':{'en': 'Pau', 'fr': 'Pau'}, '3594777':{'bg': u('\u0422\u0435\u043d\u0435\u0432\u043e'), 'en': 'Tenevo'}, '3594778':{'bg': u('\u041f\u043e\u0431\u0435\u0434\u0430, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Pobeda, Yambol'}, '3594779':{'bg': u('\u0425\u0430\u043d\u043e\u0432\u043e'), 'en': 'Hanovo'}, '44201':{'en': 'London'}, '4418513':{'en': 'Stornoway'}, '432143':{'de': 'Kittsee', 'en': 'Kittsee'}, '3348695':{'en': 'Marseille', 'fr': 'Marseille'}, '3355558':{'en': 'Nexon', 'fr': 'Nexon'}, '3355556':{'en': u('Saint-L\u00e9onard-de-Noblat'), 'fr': u('Saint-L\u00e9onard-de-Noblat')}, '3355551':{'en': u('Gu\u00e9ret'), 'fr': u('Gu\u00e9ret')}, '3355550':{'en': 'Limoges', 'fr': 'Limoges'}, '3355553':{'en': 'Nantiat', 'fr': 'Nantiat'}, '3355552':{'en': u('Gu\u00e9ret'), 'fr': u('Gu\u00e9ret')}, '432630':{'de': 'Ternitz', 'en': 'Ternitz'}, '432631':{'de': u('P\u00f6ttsching'), 'en': u('P\u00f6ttsching')}, '3332459':{'en': u('Charleville-M\u00e9zi\u00e8res'), 'fr': u('Charleville-M\u00e9zi\u00e8res')}, '3332458':{'en': u('Charleville-M\u00e9zi\u00e8res'), 'fr': u('Charleville-M\u00e9zi\u00e8res')}, '432634':{'de': 'Gutenstein', 'en': 'Gutenstein'}, '432635':{'de': 'Neunkirchen', 'en': 'Neunkirchen'}, '432636':{'de': 'Puchberg am Schneeberg', 'en': 'Puchberg am Schneeberg'}, '432637':{'de': u('Gr\u00fcnbach am Schneeberg'), 'en': u('Gr\u00fcnbach am Schneeberg')}, '3332981':{'en': u('\u00c9pinal'), 'fr': u('\u00c9pinal')}, '432639':{'de': 'Bad Fischau', 'en': 'Bad Fischau'}, '3332983':{'en': 'Verdun', 'fr': 'Verdun'}, '3332982':{'en': u('\u00c9pinal'), 'fr': u('\u00c9pinal')}, '3332457':{'en': u('Charleville-M\u00e9zi\u00e8res'), 'fr': u('Charleville-M\u00e9zi\u00e8res')}, '3332984':{'en': 'Verdun', 'fr': 'Verdun'}, '3332455':{'en': u('Charleville-M\u00e9zi\u00e8res'), 'fr': u('Charleville-M\u00e9zi\u00e8res')}, '3332986':{'en': 'Verdun', 'fr': 'Verdun'}, '3348345':{'en': 'Nice', 'fr': 'Nice'}, '3349565':{'en': 'Calvi', 'fr': 'Calvi'}, '3354979':{'en': 'Niort', 'fr': 'Niort'}, '390141':{'en': 'Asti', 'it': 'Asti'}, '3593177':{'bg': u('\u041d\u043e\u0432\u043e \u0416\u0435\u043b\u0435\u0437\u0430\u0440\u0435'), 'en': 'Novo Zhelezare'}, '3593176':{'bg': u('\u0421\u0442\u0430\u0440\u043e\u0441\u0435\u043b'), 'en': 'Starosel'}, '3593175':{'bg': u('\u0414\u044a\u043b\u0433\u043e \u043f\u043e\u043b\u0435, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Dalgo pole, Plovdiv'}, '3593174':{'bg': u('\u0421\u0442\u0430\u0440\u043e \u0416\u0435\u043b\u0435\u0437\u0430\u0440\u0435'), 'en': 'Staro Zhelezare'}, '3593173':{'bg': u('\u041f\u0430\u043d\u0438\u0447\u0435\u0440\u0438'), 'en': 'Panicheri'}, '3349561':{'en': 'Corte', 'fr': 'Corte'}, '37428396':{'am': u('\u0531\u0576\u0563\u0565\u0572\u0561\u056f\u0578\u0569'), 'en': 'Angehakot', 'ru': u('\u0410\u043d\u0433\u0435\u0445\u0430\u043a\u043e\u0442')}, '3593178':{'bg': u('\u041a\u0440\u0430\u0441\u043d\u043e\u0432\u043e'), 'en': 'Krasnovo'}, '3345023':{'en': 'Annecy-le-Vieux', 'fr': 'Annecy-le-Vieux'}, '3325138':{'en': 'Mouilleron-le-Captif', 'fr': 'Mouilleron-le-Captif'}, '3325139':{'en': u('Noirmoutier-en-l\'\u00cele'), 'fr': u('Noirmoutier-en-l\'\u00cele')}, '3325130':{'en': 'La Tranche sur Mer', 'fr': 'La Tranche sur Mer'}, '3325132':{'en': 'Les Sables d\'Olonne', 'fr': 'Les Sables d\'Olonne'}, '3325133':{'en': 'Jard-sur-Mer', 'fr': 'Jard-sur-Mer'}, '3325135':{'en': 'Challans', 'fr': 'Challans'}, '3325136':{'en': 'La Roche sur Yon', 'fr': 'La Roche sur Yon'}, '3325137':{'en': 'La Roche sur Yon', 'fr': 'La Roche sur Yon'}, '351238':{'en': 'Seia', 'pt': 'Seia'}, '351239':{'en': 'Coimbra', 'pt': 'Coimbra'}, '441844':{'en': 'Thame'}, '351232':{'en': 'Viseu', 'pt': 'Viseu'}, '351233':{'en': 'Figueira da Foz', 'pt': 'Figueira da Foz'}, '351231':{'en': 'Mealhada', 'pt': 'Mealhada'}, '351236':{'en': 'Pombal', 'pt': 'Pombal'}, '351234':{'en': 'Aveiro', 'pt': 'Aveiro'}, '351235':{'en': 'Arganil', 'pt': 'Arganil'}, '3355690':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3356234':{'en': 'Tarbes', 'fr': 'Tarbes'}, '3356237':{'en': 'Tarbes', 'fr': 'Tarbes'}, '3356236':{'en': 'Tarbes', 'fr': 'Tarbes'}, '3356230':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356232':{'en': 'Juillan', 'fr': 'Juillan'}, '3356238':{'en': 'Tarbes', 'fr': 'Tarbes'}, '3355691':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '441603':{'en': 'Norwich'}, '441600':{'en': 'Monmouth'}, '441606':{'en': 'Northwich'}, '441604':{'en': 'Northampton'}, '441609':{'en': 'Northallerton'}, '441608':{'en': 'Chipping Norton'}, '3347586':{'en': 'Valence', 'fr': 'Valence'}, '3344224':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344227':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344226':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344221':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344220':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344223':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3344222':{'en': 'Bouc-Bel-air', 'fr': 'Bouc-Bel-air'}, '3596732':{'bg': u('\u0421\u0435\u043d\u043d\u0438\u043a'), 'en': 'Sennik'}, '3596733':{'bg': u('\u041a\u043e\u0440\u043c\u044f\u043d\u0441\u043a\u043e'), 'en': 'Kormyansko'}, '3344229':{'en': 'Trets', 'fr': 'Trets'}, '3344228':{'en': 'Ventabren', 'fr': 'Ventabren'}, '3596734':{'bg': u('\u041f\u0435\u0442\u043a\u043e \u0421\u043b\u0430\u0432\u0435\u0439\u043a\u043e\u0432'), 'en': 'Petko Slaveykov'}, '3347754':{'en': 'Chazelles-sur-Lyon', 'fr': 'Chazelles-sur-Lyon'}, '3347755':{'en': u('Andr\u00e9zieux-Bouth\u00e9on'), 'fr': u('Andr\u00e9zieux-Bouth\u00e9on')}, '3347756':{'en': 'Firminy', 'fr': 'Firminy'}, '3347757':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3336981':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3347751':{'en': 'Saint-Genest-Malifaux', 'fr': 'Saint-Genest-Malifaux'}, '3347752':{'en': 'Saint-Just-Saint-Rambert', 'fr': 'Saint-Just-Saint-Rambert'}, '3347753':{'en': 'Sorbiers', 'fr': 'Sorbiers'}, '3343260':{'en': u('Saint-R\u00e9my-de-Provence'), 'fr': u('Saint-R\u00e9my-de-Provence')}, '3347758':{'en': 'Montbrison', 'fr': 'Montbrison'}, '3347759':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3343411':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3343410':{'en': 'Perpignan', 'fr': 'Perpignan'}, '436458':{'de': u('H\u00fcttau'), 'en': u('H\u00fcttau')}, '3343262':{'en': u('Ch\u00e2teaurenard'), 'fr': u('Ch\u00e2teaurenard')}, '436452':{'de': 'Radstadt', 'en': 'Radstadt'}, '436453':{'de': 'Filzmoos', 'en': 'Filzmoos'}, '436454':{'de': 'Mandling', 'en': 'Mandling'}, '436455':{'de': 'Untertauern', 'en': 'Untertauern'}, '436456':{'de': 'Obertauern', 'en': 'Obertauern'}, '436457':{'de': 'Flachau', 'en': 'Flachau'}, '3338161':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3338162':{'en': 'Ornans', 'fr': 'Ornans'}, '3316918':{'en': 'Les Ulis', 'fr': 'Les Ulis'}, '3338164':{'en': u('Ma\u00eeche'), 'fr': u('Ma\u00eeche')}, '3338167':{'en': 'Morteau', 'fr': 'Morteau'}, '3596591':{'bg': u('\u0413\u043e\u0440\u043d\u0438\u043a'), 'en': 'Gornik'}, '3316914':{'en': 'Marolles-en-Hurepoix', 'fr': 'Marolles-en-Hurepoix'}, '3338168':{'en': 'Villers-le-Lac', 'fr': 'Villers-le-Lac'}, '3316910':{'en': 'Chilly-Mazarin', 'fr': 'Chilly-Mazarin'}, '3316911':{'en': 'Lisses', 'fr': 'Lisses'}, '3316912':{'en': u('Viry-Ch\u00e2tillon'), 'fr': u('Viry-Ch\u00e2tillon')}, '35984717':{'bg': u('\u041f\u043e\u0431\u0438\u0442 \u043a\u0430\u043c\u044a\u043a, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Pobit kamak, Razgrad'}, '35984713':{'bg': u('\u0411\u043b\u0430\u0433\u043e\u0435\u0432\u043e, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Blagoevo, Razgrad'}, '35984712':{'bg': u('\u041a\u043e\u0441\u0442\u0430\u043d\u0434\u0435\u043d\u0435\u0446'), 'en': 'Kostandenets'}, '35984711':{'bg': u('\u041c\u043e\u0440\u0442\u0430\u0433\u043e\u043d\u043e\u0432\u043e'), 'en': 'Mortagonovo'}, '35984710':{'bg': u('\u041e\u0441\u0435\u043d\u0435\u0446'), 'en': 'Osenets'}, '35984719':{'bg': u('\u0411\u0430\u043b\u043a\u0430\u043d\u0441\u043a\u0438'), 'en': 'Balkanski'}, '35984718':{'bg': u('\u0414\u0440\u044f\u043d\u043e\u0432\u0435\u0446, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Dryanovets, Razgrad'}, '3329721':{'en': 'Lorient', 'fr': 'Lorient'}, '3329723':{'en': 'Gourin', 'fr': 'Gourin'}, '3329722':{'en': 'Guer', 'fr': 'Guer'}, '3329725':{'en': 'Pontivy', 'fr': 'Pontivy'}, '3329724':{'en': 'Auray', 'fr': 'Auray'}, '3329727':{'en': 'Pontivy', 'fr': 'Pontivy'}, '3329726':{'en': 'Questembert', 'fr': 'Questembert'}, '3329729':{'en': 'Auray', 'fr': 'Auray'}, '3329728':{'en': u('S\u00e9glien'), 'fr': u('S\u00e9glien')}, '3338551':{'en': 'Tournus', 'fr': 'Tournus'}, '3338552':{'en': 'Autun', 'fr': 'Autun'}, '3338553':{'en': 'Digoin', 'fr': 'Digoin'}, '3338555':{'en': 'Le Creusot', 'fr': 'Le Creusot'}, '3338556':{'en': 'Le Creusot', 'fr': 'Le Creusot'}, '3338557':{'en': 'Montceau-les-Mines', 'fr': 'Montceau-les-Mines'}, '3338558':{'en': 'Montceau-les-Mines', 'fr': 'Montceau-les-Mines'}, '3338559':{'en': 'Cluny', 'fr': 'Cluny'}, '3335728':{'en': 'Metz', 'fr': 'Metz'}, '3332651':{'en': u('\u00c9pernay'), 'fr': u('\u00c9pernay')}, '3346721':{'en': 'Agde', 'fr': 'Agde'}, '3692':{'en': 'Zalaegerszeg', 'hu': 'Zalaegerszeg'}, '3359648':{'en': u('Rivi\u00e8re-Sal\u00e9e'), 'fr': u('Rivi\u00e8re-Sal\u00e9e')}, '3359642':{'en': 'Fort de France', 'fr': 'Fort de France'}, '3593348':{'bg': u('\u0414\u043e\u0431\u0440\u0430\u043b\u044a\u043a'), 'en': 'Dobralak'}, '3593349':{'bg': u('\u0411\u043e\u044f\u043d\u0446\u0438'), 'en': 'Boyantsi'}, '3593344':{'bg': u('\u041d\u043e\u0432\u0430\u043a\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Novakovo, Plovdiv'}, '3593345':{'bg': u('\u041b\u044f\u0441\u043a\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Lyaskovo, Plovdiv'}, '3593346':{'bg': u('\u041c\u0443\u043b\u0434\u0430\u0432\u0430'), 'en': 'Muldava'}, '3593347':{'bg': u('\u041b\u0435\u043d\u043e\u0432\u043e'), 'en': 'Lenovo'}, '3593340':{'bg': u('\u041d\u043e\u0432\u0438 \u0438\u0437\u0432\u043e\u0440'), 'en': 'Novi izvor'}, '3593341':{'bg': u('\u041a\u043e\u043d\u0443\u0448, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Konush, Plovdiv'}, '3593342':{'bg': u('\u041d\u0430\u0440\u0435\u0447\u0435\u043d\u0441\u043a\u0438 \u0431\u0430\u043d\u0438'), 'en': 'Narechenski bani'}, '3593343':{'bg': u('\u041a\u043e\u0437\u0430\u043d\u043e\u0432\u043e'), 'en': 'Kozanovo'}, '3355946':{'en': 'Bayonne', 'fr': 'Bayonne'}, '3355947':{'en': 'Ciboure', 'fr': 'Ciboure'}, '3355944':{'en': 'Saint-Pierre-d\'Irube', 'fr': 'Saint-Pierre-d\'Irube'}, '3355945':{'en': 'Labenne', 'fr': 'Labenne'}, '3355942':{'en': 'Anglet', 'fr': 'Anglet'}, '3355943':{'en': 'Biarritz', 'fr': 'Biarritz'}, '3355940':{'en': 'Pau', 'fr': 'Pau'}, '3355941':{'en': 'Biarritz', 'fr': 'Biarritz'}, '3355948':{'en': 'Hendaye', 'fr': 'Hendaye'}, '34972':{'en': 'Gerona', 'es': 'Gerona'}, '3329878':{'en': 'Pleyber-Christ', 'fr': 'Pleyber-Christ'}, '34971':{'en': 'Balearic Islands', 'es': 'Baleares'}, '34976':{'en': 'Zaragoza', 'es': 'Zaragoza'}, '34977':{'en': 'Tarragona', 'es': 'Tarragona'}, '34974':{'en': 'Huesca', 'es': 'Huesca'}, '34975':{'en': 'Soria', 'es': 'Soria'}, '3329871':{'en': u('Clohars-Carno\u00ebt'), 'fr': u('Clohars-Carno\u00ebt')}, '3329870':{'en': 'Audierne', 'fr': 'Audierne'}, '34978':{'en': 'Teruel', 'es': 'Teruel'}, '3329872':{'en': 'Guerlesquin', 'fr': 'Guerlesquin'}, '3329875':{'en': 'Douarnenez', 'fr': 'Douarnenez'}, '3329874':{'en': 'Douarnenez', 'fr': 'Douarnenez'}, '3695':{'en': 'Sarvar', 'hu': u('S\u00e1rv\u00e1r')}, '441386':{'en': 'Evesham'}, '441384':{'en': 'Dudley'}, '441382':{'en': 'Dundee'}, '441383':{'en': 'Dunfermline'}, '441380':{'en': 'Devizes'}, '441381':{'en': 'Fortrose'}, '441389':{'en': 'Dumbarton'}, '3696':{'en': 'Gyor', 'hu': u('Gy\u0151r')}, '3597717':{'bg': u('\u0414\u0438\u0432\u043e\u0442\u0438\u043d\u043e'), 'en': 'Divotino'}, '3329990':{'en': 'Nivillac', 'fr': 'Nivillac'}, '3352498':{'en': 'Pau', 'fr': 'Pau'}, '3594348':{'bg': u('\u0414\u0443\u043d\u0430\u0432\u0446\u0438, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Dunavtsi, St. Zagora'}, '3594341':{'bg': u('\u0427\u0435\u0440\u0433\u0430\u043d\u043e\u0432\u043e'), 'en': 'Cherganovo'}, '3594340':{'bg': u('\u041f\u0430\u043d\u0438\u0447\u0435\u0440\u0435\u0432\u043e'), 'en': 'Panicherevo'}, '3594343':{'bg': u('\u041a\u043e\u043d\u0430\u0440\u0435, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Konare, St. Zagora'}, '3594342':{'bg': u('\u041e\u0432\u043e\u0449\u043d\u0438\u043a'), 'en': 'Ovoshtnik'}, '3594345':{'bg': u('\u0420\u0430\u0434\u0443\u043d\u0446\u0438'), 'en': 'Raduntsi'}, '3594344':{'bg': u('\u0428\u0430\u043d\u043e\u0432\u043e'), 'en': 'Shanovo'}, '3594347':{'bg': u('\u0420\u043e\u0437\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Rozovo, St. Zagora'}, '3594346':{'bg': u('\u0413\u043e\u043b\u044f\u043c\u043e \u0414\u0440\u044f\u043d\u043e\u0432\u043e'), 'en': 'Golyamo Dryanovo'}, '3596560':{'bg': u('\u041a\u0440\u0435\u0442\u0430, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Kreta, Pleven'}, '3598477':{'bg': u('\u0421\u0430\u043c\u0443\u0438\u043b'), 'en': 'Samuil'}, '3598475':{'bg': u('\u041b\u043e\u0437\u043d\u0438\u0446\u0430, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Loznitsa, Razgrad'}, '3742359':{'am': u('\u0546\u0578\u0580\u0561\u0577\u0565\u0576'), 'en': 'Norashen', 'ru': u('\u041d\u043e\u0440\u0430\u0448\u0435\u043d')}, '3332844':{'en': 'Hazebrouck', 'fr': 'Hazebrouck'}, '3332841':{'en': 'Hazebrouck', 'fr': 'Hazebrouck'}, '3332849':{'en': 'Bailleul', 'fr': 'Bailleul'}, '3597714':{'bg': u('\u041c\u0435\u0449\u0438\u0446\u0430'), 'en': 'Meshtitsa'}, '3594525':{'bg': u('\u041e\u043c\u0430\u0440\u0447\u0435\u0432\u043e, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Omarchevo, Sliven'}, '3594524':{'bg': u('\u041a\u0430\u043c\u0435\u043d\u043e\u0432\u043e, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Kamenovo, Sliven'}, '3594527':{'bg': u('\u0417\u0430\u0433\u043e\u0440\u0446\u0438, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Zagortsi, Sliven'}, '3594526':{'bg': u('\u041c\u043b\u0435\u043a\u0430\u0440\u0435\u0432\u043e'), 'en': 'Mlekarevo'}, '3594520':{'bg': u('\u041a\u043e\u043d\u044c\u043e\u0432\u043e'), 'en': 'Konyovo'}, '3594523':{'bg': u('\u0421\u0442\u043e\u0438\u043b \u0432\u043e\u0439\u0432\u043e\u0434\u0430'), 'en': 'Stoil voyvoda'}, '3594522':{'bg': u('\u041a\u043e\u0440\u0442\u0435\u043d'), 'en': 'Korten'}, '3594529':{'bg': u('\u0421\u044a\u0434\u0438\u0435\u0432\u043e, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Sadievo, Sliven'}, '3594528':{'bg': u('\u041b\u044e\u0431\u0435\u043d\u043e\u0432\u0430 \u043c\u0430\u0445\u0430\u043b\u0430'), 'en': 'Lyubenova mahala'}, '3324186':{'en': 'Angers', 'fr': 'Angers'}, '3324187':{'en': 'Angers', 'fr': 'Angers'}, '3338315':{'en': 'Ludres', 'fr': 'Ludres'}, '3324183':{'en': 'Saumur', 'fr': 'Saumur'}, '3324180':{'en': 'Maze', 'fr': 'Maze'}, '3324181':{'en': 'Angers', 'fr': 'Angers'}, '3598697':{'bg': u('\u0421\u043e\u043a\u043e\u043b, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Sokol, Silistra'}, '3334447':{'en': 'Auneuil', 'fr': 'Auneuil'}, '3334444':{'en': 'Noyon', 'fr': 'Noyon'}, '3334445':{'en': 'Beauvais', 'fr': 'Beauvais'}, '3598693':{'bg': u('\u0417\u0432\u0435\u043d\u0438\u043c\u0438\u0440'), 'en': 'Zvenimir'}, '3598692':{'bg': u('\u0421\u0442\u0435\u0444\u0430\u043d \u041a\u0430\u0440\u0430\u0434\u0436\u0430, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Stefan Karadzha, Silistra'}, '3338318':{'en': 'Nancy', 'fr': 'Nancy'}, '3324189':{'en': u('Baug\u00e9'), 'fr': u('Baug\u00e9')}, '3595346':{'bg': u('\u041a\u0430\u043c\u0435\u043d\u044f\u043a, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Kamenyak, Shumen'}, '3595347':{'bg': u('\u0416\u0438\u0432\u043a\u043e\u0432\u043e, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Zhivkovo, Shumen'}, '3595344':{'bg': u('\u0412\u0435\u043b\u0438\u043d\u043e'), 'en': 'Velino'}, '3595345':{'bg': u('\u0420\u0430\u0437\u0432\u0438\u0433\u043e\u0440\u043e\u0432\u043e'), 'en': 'Razvigorovo'}, '3595342':{'bg': u('\u041a\u0430\u043f\u0438\u0442\u0430\u043d \u041f\u0435\u0442\u043a\u043e'), 'en': 'Kapitan Petko'}, '3595343':{'bg': u('\u0412\u0435\u043d\u0435\u0446, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Venets, Shumen'}, '3595340':{'bg': u('\u0412\u0438\u0441\u043e\u043a\u0430 \u043f\u043e\u043b\u044f\u043d\u0430, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Visoka polyana, Shumen'}, '3595341':{'bg': u('\u0425\u0438\u0442\u0440\u0438\u043d\u043e'), 'en': 'Hitrino'}, '359936':{'bg': u('\u0411\u0435\u043b\u043e\u0433\u0440\u0430\u0434\u0447\u0438\u043a'), 'en': 'Belogradchik'}, '3595348':{'bg': u('\u0422\u0440\u0435\u043c'), 'en': 'Trem'}, '3595349':{'bg': u('\u0421\u0442\u0443\u0434\u0435\u043d\u0438\u0446\u0430'), 'en': 'Studenitsa'}, '441677':{'en': 'Bedale'}, '3324738':{'en': 'Tours', 'fr': 'Tours'}, '4031':{'en': 'Bucharest and Ilfov County', 'ro': u('Bucure\u0219ti \u0219i jude\u021bul Ilfov')}, '3356559':{'en': 'Millau', 'fr': 'Millau'}, '441675':{'en': 'Coleshill'}, '3356550':{'en': 'Figeac', 'fr': 'Figeac'}, '3356551':{'en': 'Espalion', 'fr': 'Espalion'}, '3356553':{'en': 'Cahors', 'fr': 'Cahors'}, '433866':{'de': 'Breitenau am Hochlantsch', 'en': 'Breitenau am Hochlantsch'}, '3597912':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u0413\u0440\u0430\u0449\u0438\u0446\u0430'), 'en': 'Gorna Grashtitsa'}, '433864':{'de': u('Sankt Marein im M\u00fcrztal'), 'en': u('St. Marein im M\u00fcrztal')}, '433865':{'de': 'Kindberg', 'en': 'Kindberg'}, '433862':{'de': 'Bruck an der Mur', 'en': 'Bruck an der Mur'}, '433863':{'de': 'Turnau', 'en': 'Turnau'}, '433861':{'de': 'Aflenz', 'en': 'Aflenz'}, '35941113':{'bg': u('\u041f\u0440\u044f\u043f\u043e\u0440\u0435\u0446, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Pryaporets, St. Zagora'}, '433868':{'de': u('Trag\u00f6\u00df'), 'en': u('Trag\u00f6ss')}, '433869':{'de': 'Sankt Katharein an der Laming', 'en': 'St. Katharein an der Laming'}, '3595122':{'bg': u('\u0421\u043b\u0430\u0432\u0435\u0439\u043a\u043e\u0432\u043e, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Slaveykovo, Varna'}, '3347508':{'en': u('Tournon-sur-Rh\u00f4ne'), 'fr': u('Tournon-sur-Rh\u00f4ne')}, '3595120':{'bg': u('\u0411\u043e\u0437\u0432\u0435\u043b\u0438\u0439\u0441\u043a\u043e'), 'en': 'Bozveliysko'}, '3595121':{'bg': u('\u0422\u0443\u0442\u0440\u0430\u043a\u0430\u043d\u0446\u0438'), 'en': 'Tutrakantsi'}, '3595126':{'bg': u('\u0427\u0435\u0440\u043a\u043e\u0432\u043d\u0430, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Cherkovna, Varna'}, '3595127':{'bg': u('\u041c\u0430\u043d\u0430\u0441\u0442\u0438\u0440, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Manastir, Varna'}, '3595124':{'bg': u('\u041a\u043e\u043c\u0430\u0440\u0435\u0432\u043e, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Komarevo, Varna'}, '3595125':{'bg': u('\u0413\u0440\u0430\u0434\u0438\u043d\u0430\u0440\u043e\u0432\u043e'), 'en': 'Gradinarovo'}, '3347501':{'en': u('Mont\u00e9limar'), 'fr': u('Mont\u00e9limar')}, '3347500':{'en': u('Mont\u00e9limar'), 'fr': u('Mont\u00e9limar')}, '3595128':{'bg': u('\u0416\u0438\u0442\u043d\u0438\u0446\u0430, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Zhitnitsa, Varna'}, '3347502':{'en': u('Romans-sur-Is\u00e8re'), 'fr': u('Romans-sur-Is\u00e8re')}, '3347505':{'en': u('Romans-sur-Is\u00e8re'), 'fr': u('Romans-sur-Is\u00e8re')}, '3347504':{'en': 'Pierrelatte', 'fr': 'Pierrelatte'}, '3347507':{'en': u('Tournon-sur-Rh\u00f4ne'), 'fr': u('Tournon-sur-Rh\u00f4ne')}, '3355692':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355693':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355922':{'en': 'Biarritz', 'fr': 'Biarritz'}, '3355923':{'en': 'Biarritz', 'fr': 'Biarritz'}, '441678':{'en': 'Bala'}, '3599128':{'bg': u('\u0415\u043b\u0438\u0441\u0435\u0439\u043d\u0430'), 'en': 'Eliseyna'}, '3356182':{'en': 'Grenade', 'fr': 'Grenade'}, '3599126':{'bg': u('\u041a\u0430\u043c\u0435\u043d\u043e \u043f\u043e\u043b\u0435'), 'en': 'Kameno pole'}, '3329817':{'en': 'Crozon', 'fr': 'Crozon'}, '3599124':{'bg': u('\u0422\u0438\u043f\u0447\u0435\u043d\u0438\u0446\u0430'), 'en': 'Tipchenitsa'}, '3599125':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u0411\u0435\u0448\u043e\u0432\u0438\u0446\u0430'), 'en': 'Gorna Beshovitsa'}, '3599122':{'bg': u('\u0417\u0432\u0435\u0440\u0438\u043d\u043e'), 'en': 'Zverino'}, '3599123':{'bg': u('\u0420\u043e\u043c\u0430\u043d'), 'en': 'Roman'}, '3329816':{'en': 'Crozon', 'fr': 'Crozon'}, '3355926':{'en': 'Saint-Jean-de-Luz', 'fr': 'Saint-Jean-de-Luz'}, '3355927':{'en': 'Pau', 'fr': 'Pau'}, '3355698':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3339190':{'en': 'Boulogne-sur-Mer', 'fr': 'Boulogne-sur-Mer'}, '355874':{'en': u('Ho\u00e7isht/Miras, Devoll')}, '355875':{'en': u('K\u00eblcyr\u00eb, P\u00ebrmet')}, '359751':{'bg': u('\u0413\u043e\u0446\u0435 \u0414\u0435\u043b\u0447\u0435\u0432'), 'en': 'Gotse Delchev'}, '359750':{'bg': u('\u0411\u043e\u0440\u043e\u0432\u0435\u0446, \u0421\u043e\u0444\u0438\u044f'), 'en': 'Borovets, Sofia'}, '390884':{'en': 'Foggia', 'it': 'Manfredonia'}, '390885':{'it': 'Cerignola'}, '390883':{'en': 'Andria Barletta Trani', 'it': 'Andria'}, '3349103':{'en': 'Marseille', 'fr': 'Marseille'}, '3349102':{'en': 'Marseille', 'fr': 'Marseille'}, '3349101':{'en': 'Marseille', 'fr': 'Marseille'}, '390522':{'en': 'Reggio Emilia', 'it': 'Reggio nell\'Emilia'}, '3349107':{'en': 'Allauch', 'fr': 'Allauch'}, '3349106':{'en': 'Marseille', 'fr': 'Marseille'}, '3349105':{'en': 'Marseille', 'fr': 'Marseille'}, '3349104':{'en': 'Marseille', 'fr': 'Marseille'}, '3349109':{'en': 'Marseille', 'fr': 'Marseille'}, '3349108':{'en': 'Marseille', 'fr': 'Marseille'}, '3678':{'en': 'Kiskoros', 'hu': u('Kisk\u0151r\u00f6s')}, '3323877':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323874':{'en': u('Ingr\u00e9'), 'fr': u('Ingr\u00e9')}, '3323873':{'en': 'Saran', 'fr': 'Saran'}, '3338961':{'en': 'Illzach', 'fr': 'Illzach'}, '3338960':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3338965':{'en': 'Rixheim', 'fr': 'Rixheim'}, '3338964':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3323879':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3338966':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '4413873':{'en': 'Langholm'}, '3672':{'en': 'Pecs', 'hu': u('P\u00e9cs')}, '3742227':{'am': u('\u0533\u0561\u057c\u0576\u056b'), 'en': 'Garni', 'ru': u('\u0413\u0430\u0440\u043d\u0438')}, '3673':{'en': 'Szigetvar', 'hu': u('Szigetv\u00e1r')}, '3594752':{'bg': u('\u041f\u044a\u0440\u0432\u0435\u043d\u0435\u0446, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Parvenets, Yambol'}, '3594753':{'bg': u('\u0417\u043e\u0440\u043d\u0438\u0446\u0430, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Zornitsa, Yambol'}, '3742229':{'am': u('\u0536\u0578\u057e\u0584'), 'en': 'Zovk', 'ru': u('\u0417\u043e\u0432\u043a')}, '3594751':{'bg': u('\u0412\u043e\u0439\u043d\u0438\u043a\u0430'), 'en': 'Voynika'}, '3594756':{'bg': u('\u041f\u043e\u043b\u044f\u043d\u0430, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Polyana, Yambol'}, '3594757':{'bg': u('\u041d\u0435\u0434\u044f\u043b\u0441\u043a\u043e'), 'en': 'Nedyalsko'}, '3594754':{'bg': u('\u041a\u0430\u043c\u0435\u043d\u0435\u0446, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Kamenets, Yambol'}, '3594755':{'bg': u('\u0422\u0430\u043c\u0430\u0440\u0438\u043d\u043e'), 'en': 'Tamarino'}, '3346810':{'en': 'Carcassonne', 'fr': 'Carcassonne'}, '3346811':{'en': 'Carcassonne', 'fr': 'Carcassonne'}, '3596169':{'bg': u('\u0411\u043b\u0430\u0433\u043e\u0435\u0432\u043e, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Blagoevo, V. Tarnovo'}, '3675':{'en': 'Paks', 'hu': 'Paks'}, '3348418':{'en': 'Marseille', 'fr': 'Marseille'}, '3359432':{'en': 'Kourou', 'fr': 'Kourou'}, '3359430':{'en': 'Cayenne', 'fr': 'Cayenne'}, '3359431':{'en': 'Cayenne', 'fr': 'Cayenne'}, '3359437':{'en': 'Cayenne', 'fr': 'Cayenne'}, '3359434':{'en': 'Saint-Laurent-du-Maroni', 'fr': 'Saint-Laurent-du-Maroni'}, '3359435':{'en': 'Matoury', 'fr': 'Matoury'}, '3359438':{'en': 'Cayenne', 'fr': 'Cayenne'}, '3359439':{'en': 'Cayenne', 'fr': 'Cayenne'}, '3593151':{'bg': u('\u0420\u0430\u043a\u043e\u0432\u0441\u043a\u0438, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Rakovski, Plovdiv'}, '3593153':{'bg': u('\u0421\u0442\u0440\u044f\u043c\u0430'), 'en': 'Stryama'}, '3593155':{'bg': u('\u041c\u043e\u043c\u0438\u043d\u043e \u0441\u0435\u043b\u043e'), 'en': 'Momino selo'}, '3593154':{'bg': u('\u0427\u0430\u043b\u044a\u043a\u043e\u0432\u0438'), 'en': 'Chalakovi'}, '3593157':{'bg': u('\u0411\u043e\u043b\u044f\u0440\u0438\u043d\u043e'), 'en': 'Bolyarino'}, '3593156':{'bg': u('\u0428\u0438\u0448\u043c\u0430\u043d\u0446\u0438'), 'en': 'Shishmantsi'}, '3593159':{'bg': u('\u0411\u0435\u043b\u043e\u0437\u0435\u043c'), 'en': 'Belozem'}, '435442':{'de': 'Landeck', 'en': 'Landeck'}, '3595139':{'bg': u('\u041e\u0431\u043e\u0440\u0438\u0449\u0435, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Oborishte, Varna'}, '3325112':{'en': 'La Chapelle sur Erdre', 'fr': 'La Chapelle sur Erdre'}, '3325445':{'en': 'Blois', 'fr': 'Blois'}, '3325110':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '3325111':{'en': u('Rez\u00e9'), 'fr': u('Rez\u00e9')}, '3325116':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '3325441':{'en': 'Lye', 'fr': 'Lye'}, '3325442':{'en': 'Blois', 'fr': 'Blois'}, '3325443':{'en': 'Blois', 'fr': 'Blois'}, '433387':{'de': u('S\u00f6chau'), 'en': u('S\u00f6chau')}, '433386':{'de': u('Gro\u00dfsteinbach'), 'en': 'Grosssteinbach'}, '433385':{'de': 'Ilz', 'en': 'Ilz'}, '3325448':{'en': u('La Ch\u00e2tre'), 'fr': u('La Ch\u00e2tre')}, '433382':{'de': u('F\u00fcrstenfeld'), 'en': u('F\u00fcrstenfeld')}, '435443':{'de': u('Galt\u00fcr'), 'en': u('Galt\u00fcr')}, '3595138':{'bg': u('\u0414\u043e\u0431\u0440\u043e\u0442\u0438\u0447'), 'en': 'Dobrotich'}, '3324869':{'en': 'Bourges', 'fr': 'Bourges'}, '3324868':{'en': 'Bourges', 'fr': 'Bourges'}, '3324865':{'en': 'Bourges', 'fr': 'Bourges'}, '3324867':{'en': 'Bourges', 'fr': 'Bourges'}, '3324866':{'en': 'Bourges', 'fr': 'Bourges'}, '3324861':{'en': u('Ch\u00e2teaumeillant'), 'fr': u('Ch\u00e2teaumeillant')}, '375154':{'be': u('\u041b\u0456\u0434\u0430'), 'en': 'Lida', 'ru': u('\u041b\u0438\u0434\u0430')}, '432642':{'de': 'Aspangberg-Sankt Peter', 'en': 'Aspangberg-St. Peter'}, '375152':{'be': u('\u0413\u0440\u043e\u0434\u043d\u0430'), 'en': 'Grodno', 'ru': u('\u0413\u0440\u043e\u0434\u043d\u043e')}, '432644':{'de': 'Grimmenstein', 'en': 'Grimmenstein'}, '434718':{'de': 'Dellach', 'en': 'Dellach'}, '3596952':{'bg': u('\u041e\u0440\u0435\u0448\u0430\u043a, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Oreshak, Lovech'}, '434713':{'de': 'Techendorf', 'en': 'Techendorf'}, '434712':{'de': 'Greifenburg', 'en': 'Greifenburg'}, '434715':{'de': u('K\u00f6tschach-Mauthen'), 'en': u('K\u00f6tschach-Mauthen')}, '434714':{'de': 'Dellach im Drautal', 'en': 'Dellach im Drautal'}, '434717':{'de': 'Steinfeld', 'en': 'Steinfeld'}, '434716':{'de': 'Lesachtal', 'en': 'Lesachtal'}, '3347867':{'en': 'Saint-Fons', 'fr': 'Saint-Fons'}, '4413399':{'en': 'Ballater'}, '4413398':{'en': 'Aboyne'}, '4413397':{'en': 'Ballater'}, '4413396':{'en': 'Ballater'}, '4413395':{'en': 'Aboyne'}, '4413394':{'en': 'Ballater'}, '4413393':{'en': 'Aboyne'}, '4413392':{'en': 'Aboyne'}, '4413391':{'en': 'Aboyne/Ballater'}, '4413390':{'en': 'Aboyne/Ballater'}, '35856':{'en': 'Kymi', 'fi': 'Kymi', 'se': 'Kymmene'}, '35321':{'en': 'Cork/Kinsale/Coachford'}, '35322':{'en': 'Mallow'}, '35323':{'en': 'Bandon'}, '35324':{'en': 'Youghal'}, '35325':{'en': 'Fermoy'}, '35326':{'en': 'Macroom'}, '35327':{'en': 'Bantry'}, '35328':{'en': 'Skibbereen'}, '35329':{'en': 'Kanturk'}, '35858':{'en': 'Kymi', 'fi': 'Kymi', 'se': 'Kymmene'}, '361':{'en': 'Budapest', 'hu': 'Budapest'}, '436432':{'de': 'Bad Hofgastein', 'en': 'Bad Hofgastein'}, '436433':{'de': 'Dorfgastein', 'en': 'Dorfgastein'}, '434843':{'de': u('Au\u00dfervillgraten'), 'en': 'Ausservillgraten'}, '3347778':{'en': 'Roanne', 'fr': 'Roanne'}, '3347779':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '390921':{'en': 'Palermo', 'it': u('Cefal\u00f9')}, '3343433':{'en': u('B\u00e9ziers'), 'fr': u('B\u00e9ziers')}, '3343432':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3343435':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3347773':{'en': 'Saint-Paul-en-Jarez', 'fr': 'Saint-Paul-en-Jarez'}, '3347770':{'en': 'Roanne', 'fr': 'Roanne'}, '3347771':{'en': 'Roanne', 'fr': 'Roanne'}, '3316936':{'en': u('\u00c9vry'), 'fr': u('\u00c9vry')}, '435447':{'de': 'Flirsch', 'en': 'Flirsch'}, '3316934':{'en': 'Longjumeau', 'fr': 'Longjumeau'}, '3316935':{'en': u('Bi\u00e8vres'), 'fr': u('Bi\u00e8vres')}, '3316932':{'en': 'Massy', 'fr': 'Massy'}, '390923':{'it': 'Trapani'}, '3316930':{'en': 'Massy', 'fr': 'Massy'}, '3316931':{'en': 'Palaiseau', 'fr': 'Palaiseau'}, '390922':{'en': 'Agrigento', 'it': 'Agrigento'}, '3316938':{'en': 'Athis-Mons', 'fr': 'Athis-Mons'}, '3316939':{'en': 'Brunoy', 'fr': 'Brunoy'}, '441207':{'en': 'Consett'}, '441206':{'en': 'Colchester'}, '3595757':{'bg': u('\u0411\u0435\u0437\u043c\u0435\u0440, \u0414\u043e\u0431\u0440.'), 'en': 'Bezmer, Dobr.'}, '4419464':{'en': 'Whitehaven'}, '3595756':{'bg': u('\u0411\u043e\u0436\u0430\u043d'), 'en': 'Bozhan'}, '3595753':{'bg': u('\u041e\u0440\u043b\u044f\u043a'), 'en': 'Orlyak'}, '35984735':{'bg': u('\u0421\u0432\u0435\u0449\u0430\u0440\u0438'), 'en': 'Sveshtari'}, '35984734':{'bg': u('\u0422\u043e\u0434\u043e\u0440\u043e\u0432\u043e, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Todorovo, Razgrad'}, '35984737':{'bg': u('\u0420\u0430\u0439\u043d\u0438\u043d\u043e'), 'en': 'Raynino'}, '3595752':{'bg': u('\u041d\u043e\u0432\u0430 \u041a\u0430\u043c\u0435\u043d\u0430'), 'en': 'Nova Kamena'}, '35984730':{'bg': u('\u0413\u043e\u043b\u044f\u043c \u041f\u043e\u0440\u043e\u0432\u0435\u0446'), 'en': 'Golyam Porovets'}, '35984733':{'bg': u('\u041b\u0443\u0434\u043e\u0433\u043e\u0440\u0446\u0438'), 'en': 'Ludogortsi'}, '35984732':{'bg': u('\u0419\u043e\u043d\u043a\u043e\u0432\u043e'), 'en': 'Yonkovo'}, '3347646':{'en': 'Grenoble', 'fr': 'Grenoble'}, '441209':{'en': 'Redruth'}, '441208':{'en': 'Bodmin'}, '3347644':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3329749':{'en': 'Questembert', 'fr': 'Questembert'}, '3329748':{'en': 'Sarzeau', 'fr': 'Sarzeau'}, '3329743':{'en': 'Theix', 'fr': 'Theix'}, '3329742':{'en': 'Vannes', 'fr': 'Vannes'}, '3329741':{'en': 'Sarzeau', 'fr': 'Sarzeau'}, '3329740':{'en': 'Vannes', 'fr': 'Vannes'}, '3329747':{'en': 'Vannes', 'fr': 'Vannes'}, '3329746':{'en': 'Vannes', 'fr': 'Vannes'}, '435449':{'de': u('Flie\u00df'), 'en': 'Fliess'}, '3329744':{'en': 'Arradon', 'fr': 'Arradon'}, '3338578':{'en': 'Montchanin', 'fr': 'Montchanin'}, '3347640':{'en': u('\u00c9chirolles'), 'fr': u('\u00c9chirolles')}, '3338573':{'en': 'Le Creusot', 'fr': 'Le Creusot'}, '3347641':{'en': 'Meylan', 'fr': 'Meylan'}, '3338577':{'en': 'Le Creusot', 'fr': 'Le Creusot'}, '3338575':{'en': 'Louhans', 'fr': 'Louhans'}, '3593145':{'bg': u('\u041a\u0440\u0438\u0447\u0438\u043c'), 'en': 'Krichim'}, '3355925':{'en': 'Bayonne', 'fr': 'Bayonne'}, '46174':{'en': 'Alunda', 'sv': 'Alunda'}, '435575':{'de': 'Langen bei Bregenz', 'en': 'Langen bei Bregenz'}, '37425295':{'am': u('\u0531\u0580\u057f\u0561\u057e\u0561\u0576'), 'en': 'Artavan', 'ru': u('\u0410\u0440\u0442\u0430\u0432\u0430\u043d')}, '435578':{'de': u('H\u00f6chst'), 'en': u('H\u00f6chst')}, '3354525':{'en': u('Angoul\u00eame'), 'fr': u('Angoul\u00eame')}, '3354529':{'en': 'Ruffec', 'fr': 'Ruffec'}, '435579':{'de': 'Alberschwende', 'en': 'Alberschwende'}, '3322844':{'en': 'Nantes', 'fr': 'Nantes'}, '3355920':{'en': 'Hendaye', 'fr': 'Hendaye'}, '3355921':{'en': 'Monein', 'fr': 'Monein'}, '3329811':{'en': 'Douarnenez', 'fr': 'Douarnenez'}, '3329810':{'en': 'Quimper', 'fr': 'Quimper'}, '3355696':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355697':{'en': 'Merignac', 'fr': u('M\u00e9rignac')}, '3329815':{'en': 'Morlaix', 'fr': 'Morlaix'}, '3355695':{'en': 'Blanquefort', 'fr': 'Blanquefort'}, '3355928':{'en': u('Maul\u00e9on-Licharre'), 'fr': u('Maul\u00e9on-Licharre')}, '3355929':{'en': 'Hasparren', 'fr': 'Hasparren'}, '3329819':{'en': u('Saint-Pol-de-L\u00e9on'), 'fr': u('Saint-Pol-de-L\u00e9on')}, '3355699':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '34958':{'en': 'Granada', 'es': 'Granada'}, '34959':{'en': 'Huelva', 'es': 'Huelva'}, '355876':{'en': u('Qend\u00ebr/Frash\u00ebr/Petran/\u00c7arshov\u00eb, P\u00ebrmet')}, '355877':{'en': u('Dishnic\u00eb/Suk\u00eb/Ballaban, P\u00ebrmet')}, '390882':{'en': 'Foggia', 'it': 'San Severo'}, '355871':{'en': u('Leskovik/Barmash/Novosel\u00eb, Kolonj\u00eb')}, '355872':{'en': u('Qend\u00ebr Ersek\u00eb/Mollas/\u00c7lirim, Kolonj\u00eb')}, '355873':{'en': u('Qend\u00ebr Bilisht/Prog\u00ebr, Devoll')}, '34950':{'en': u('Almer\u00eda'), 'es': u('Almer\u00eda')}, '34951':{'en': u('M\u00e1laga'), 'es': u('M\u00e1laga')}, '34952':{'en': u('M\u00e1laga'), 'es': u('M\u00e1laga')}, '34953':{'en': u('Ja\u00e9n'), 'es': u('Ja\u00e9n')}, '34954':{'en': 'Seville', 'es': 'Sevilla'}, '34955':{'en': 'Seville', 'es': 'Sevilla'}, '34956':{'en': u('C\u00e1diz'), 'es': u('C\u00e1diz')}, '34957':{'en': u('C\u00f3rdoba'), 'es': u('C\u00f3rdoba')}, '3332288':{'en': u('Rosi\u00e8res-en-Santerre'), 'fr': u('Rosi\u00e8res-en-Santerre')}, '3332289':{'en': 'Amiens', 'fr': 'Amiens'}, '3332283':{'en': 'Chaulnes', 'fr': 'Chaulnes'}, '3332280':{'en': 'Amiens', 'fr': 'Amiens'}, '3332286':{'en': 'Roisel', 'fr': 'Roisel'}, '3332287':{'en': 'Roye', 'fr': 'Roye'}, '3332284':{'en': u('P\u00e9ronne'), 'fr': u('P\u00e9ronne')}, '35947192':{'bg': u('\u0417\u0430\u0432\u043e\u0439'), 'en': 'Zavoy'}, '35947193':{'bg': u('\u041c\u043e\u0433\u0438\u043b\u0430, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Mogila, Yambol'}, '3324042':{'en': 'Le Pouliguen', 'fr': 'Le Pouliguen'}, '3324041':{'en': 'Nantes', 'fr': 'Nantes'}, '3324040':{'en': 'Nantes', 'fr': 'Nantes'}, '3332868':{'en': 'Bergues', 'fr': 'Bergues'}, '3324047':{'en': 'Nantes', 'fr': 'Nantes'}, '3332869':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '3687':{'en': 'Tapolca', 'hu': 'Tapolca'}, '3594323':{'bg': u('\u0422\u0443\u043b\u043e\u0432\u043e'), 'en': 'Tulovo'}, '3594322':{'bg': u('\u042f\u0433\u043e\u0434\u0430'), 'en': 'Yagoda'}, '3594321':{'bg': u('\u041c\u044a\u0433\u043b\u0438\u0436'), 'en': 'Maglizh'}, '3594327':{'bg': u('\u0428\u0435\u0439\u043d\u043e\u0432\u043e'), 'en': 'Sheynovo'}, '3594326':{'bg': u('\u0415\u043d\u0438\u043d\u0430'), 'en': 'Enina'}, '3594325':{'bg': u('\u041a\u044a\u043d\u0447\u0435\u0432\u043e'), 'en': 'Kanchevo'}, '3594324':{'bg': u('\u0428\u0438\u043f\u043a\u0430'), 'en': 'Shipka'}, '3594329':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u0421\u0430\u0445\u0440\u0430\u043d\u0435'), 'en': 'Dolno Sahrane'}, '3322335':{'en': 'Rennes', 'fr': 'Rennes'}, '3322331':{'en': 'Bain-de-Bretagne', 'fr': 'Bain-de-Bretagne'}, '3322330':{'en': 'Rennes', 'fr': 'Rennes'}, '3332866':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '3332864':{'en': 'Coudekerque-Branche', 'fr': 'Coudekerque-Branche'}, '3332865':{'en': 'Wormhout', 'fr': 'Wormhout'}, '3332863':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '3332860':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '3332861':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '3334428':{'en': 'Creil', 'fr': 'Creil'}, '3334429':{'en': 'Saint-Martin-Longueau', 'fr': 'Saint-Martin-Longueau'}, '3338373':{'en': u('Lun\u00e9ville'), 'fr': u('Lun\u00e9ville')}, '3338374':{'en': u('Lun\u00e9ville'), 'fr': u('Lun\u00e9ville')}, '3338375':{'en': 'Baccarat', 'fr': 'Baccarat'}, '3338376':{'en': u('Lun\u00e9ville'), 'fr': u('Lun\u00e9ville')}, '3334420':{'en': u('Compi\u00e8gne'), 'fr': u('Compi\u00e8gne')}, '3334421':{'en': 'Lamorlaye', 'fr': 'Lamorlaye'}, '3334422':{'en': u('M\u00e9ru'), 'fr': u('M\u00e9ru')}, '3334423':{'en': u('Compi\u00e8gne'), 'fr': u('Compi\u00e8gne')}, '3334424':{'en': 'Creil', 'fr': 'Creil'}, '3334425':{'en': 'Creil', 'fr': 'Creil'}, '3334426':{'en': 'Neuilly-en-Thelle', 'fr': 'Neuilly-en-Thelle'}, '3334427':{'en': u('Pr\u00e9cy-sur-Oise'), 'fr': u('Pr\u00e9cy-sur-Oise')}, '436278':{'de': 'Ostermiething', 'en': 'Ostermiething'}, '390144':{'it': 'Acqui Terme'}, '437479':{'de': 'Ardagger', 'en': 'Ardagger'}, '359915':{'bg': u('\u0411\u044f\u043b\u0430 \u0421\u043b\u0430\u0442\u0438\u043d\u0430'), 'en': 'Byala Slatina'}, '359910':{'bg': u('\u041c\u0435\u0437\u0434\u0440\u0430'), 'en': 'Mezdra'}, '3595320':{'bg': u('\u041f\u0435\u0442 \u043c\u043e\u0433\u0438\u043b\u0438, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Pet mogili, Shumen'}, '3595321':{'bg': u('\u041f\u0440\u0430\u0432\u0435\u043d\u0446\u0438'), 'en': 'Praventsi'}, '3595323':{'bg': u('\u041f\u043b\u0438\u0441\u043a\u0430'), 'en': 'Pliska'}, '3595324':{'bg': u('\u0425\u044a\u0440\u0441\u043e\u0432\u043e, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Harsovo, Shumen'}, '3595325':{'bg': u('\u0412\u043e\u0439\u0432\u043e\u0434\u0430'), 'en': 'Voyvoda'}, '3595326':{'bg': u('\u0412\u044a\u0440\u0431\u044f\u043d\u0435'), 'en': 'Varbyane'}, '3595327':{'bg': u('\u041a\u0430\u0441\u043f\u0438\u0447\u0430\u043d, \u0428\u0443\u043c\u0435\u043d'), 'en': 'Kaspichan, Shumen'}, '3595328':{'bg': u('\u041d\u0438\u043a\u043e\u043b\u0430 \u041a\u043e\u0437\u043b\u0435\u0432\u043e'), 'en': 'Nikola Kozlevo'}, '3595329':{'bg': u('\u041c\u0438\u0440\u043e\u0432\u0446\u0438'), 'en': 'Mirovtsi'}, '437478':{'de': 'Oed-Oehling', 'en': 'Oed-Oehling'}, '355269':{'en': u('Kastrat/Shkrel/Kelmend, Mal\u00ebsi e Madhe')}, '3356573':{'en': 'Rodez', 'fr': 'Rodez'}, '3356577':{'en': 'Rodez', 'fr': 'Rodez'}, '3356575':{'en': 'Rodez', 'fr': 'Rodez'}, '355261':{'en': u('Vau-Dej\u00ebs')}, '355263':{'en': u('Pult/Shal\u00eb/Shosh/Temal/Shllak, Shkod\u00ebr')}, '355262':{'en': u('Rrethinat/Ana-Malit, Shkod\u00ebr')}, '355265':{'en': u('Vig-Mnel\u00eb/Hajmel, Shkod\u00ebr')}, '355264':{'en': u('Postrib\u00eb/Gur i Zi')}, '355267':{'en': u('Daj\u00e7/Velipoj\u00eb, Shkod\u00ebr')}, '355266':{'en': u('Bushat/B\u00ebrdic\u00eb, Shkod\u00ebr')}, '3599328':{'bg': u('\u0414\u043e\u043b\u043d\u0438 \u041b\u043e\u043c'), 'en': 'Dolni Lom'}, '3599329':{'bg': u('\u0420\u0430\u0431\u0438\u0448\u0430'), 'en': 'Rabisha'}, '3599324':{'bg': u('\u0420\u0443\u0436\u0438\u043d\u0446\u0438'), 'en': 'Ruzhintsi'}, '3599325':{'bg': u('\u0411\u0435\u043b\u043e \u043f\u043e\u043b\u0435, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Belo pole, Vidin'}, '3599326':{'bg': u('\u0413\u043e\u0440\u043d\u0438 \u041b\u043e\u043c'), 'en': 'Gorni Lom'}, '3599327':{'bg': u('\u0427\u0443\u043f\u0440\u0435\u043d\u0435'), 'en': 'Chuprene'}, '3599320':{'bg': u('\u0421\u0442\u0430\u043a\u0435\u0432\u0446\u0438'), 'en': 'Stakevtsi'}, '3599322':{'bg': u('\u041e\u0440\u0435\u0448\u0435\u0446, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Oreshets, Vidin'}, '3599323':{'bg': u('\u0414\u0440\u0435\u043d\u043e\u0432\u0435\u0446'), 'en': 'Drenovets'}, '3347563':{'en': u('Saulce-sur-Rh\u00f4ne'), 'fr': u('Saulce-sur-Rh\u00f4ne')}, '3347562':{'en': u('La Voulte sur Rh\u00f4ne'), 'fr': u('La Voulte sur Rh\u00f4ne')}, '3347561':{'en': u('Livron-sur-Dr\u00f4me'), 'fr': u('Livron-sur-Dr\u00f4me')}, '3347560':{'en': u('\u00c9toile-sur-Rh\u00f4ne'), 'fr': u('\u00c9toile-sur-Rh\u00f4ne')}, '3347567':{'en': 'Annonay', 'fr': 'Annonay'}, '433845':{'de': 'Mautern in Steiermark', 'en': 'Mautern in Steiermark'}, '433846':{'de': 'Kalwang', 'en': 'Kalwang'}, '3347564':{'en': 'Privas', 'fr': 'Privas'}, '433848':{'de': 'Eisenerz', 'en': 'Eisenerz'}, '433849':{'de': 'Vordernberg', 'en': 'Vordernberg'}, '3347569':{'en': 'Annonay', 'fr': 'Annonay'}, '3347568':{'en': 'Hauterives', 'fr': 'Hauterives'}, '433114':{'de': 'Markt Hartmannsdorf', 'en': 'Markt Hartmannsdorf'}, '3599148':{'bg': u('\u0411\u044a\u0440\u043a\u0430\u0447\u0435\u0432\u043e'), 'en': 'Barkachevo'}, '3599149':{'bg': u('\u0411\u0443\u043a\u043e\u0432\u0435\u0446, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Bukovets, Vratsa'}, '433115':{'de': 'Studenzen', 'en': 'Studenzen'}, '3599140':{'bg': u('\u0413\u0430\u0431\u0430\u0440\u0435'), 'en': 'Gabare'}, '3599141':{'bg': u('\u041c\u0430\u043b\u043e\u0440\u0430\u0434'), 'en': 'Malorad'}, '3599142':{'bg': u('\u041b\u0430\u0437\u0430\u0440\u043e\u0432\u043e'), 'en': 'Lazarovo'}, '3599143':{'bg': u('\u0415\u043d\u0438\u0446\u0430'), 'en': 'Enitsa'}, '3599144':{'bg': u('\u041d\u0438\u0432\u044f\u043d\u0438\u043d'), 'en': 'Nivyanin'}, '3599145':{'bg': u('\u0411\u0440\u0435\u043d\u0438\u0446\u0430, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Brenitsa, Vratsa'}, '3599146':{'bg': u('\u0421\u043e\u043a\u043e\u043b\u0430\u0440\u0435'), 'en': 'Sokolare'}, '3599147':{'bg': u('\u0411\u043e\u0440\u043e\u0432\u0430\u043d'), 'en': 'Borovan'}, '3353439':{'en': 'Colomiers', 'fr': 'Colomiers'}, '35963571':{'bg': u('\u0411\u0440\u0435\u0441\u0442\u043e\u0432\u0435\u0446'), 'en': 'Brestovets'}, '3353430':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3353431':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3353433':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3353436':{'en': 'Blagnac', 'fr': 'Blagnac'}, '435635':{'de': 'Elmen', 'en': 'Elmen'}, '435634':{'de': 'Elbigenalp', 'en': 'Elbigenalp'}, '432714':{'de': 'Rossatz', 'en': 'Rossatz'}, '35963575':{'bg': u('\u0411\u043e\u0445\u043e\u0442'), 'en': 'Bohot'}, '35963577':{'bg': u('\u041f\u0435\u043b\u0438\u0448\u0430\u0442'), 'en': 'Pelishat'}, '3347386':{'en': u('Ch\u00e2tel-Guyon'), 'fr': u('Ch\u00e2tel-Guyon')}, '3347385':{'en': u('Saint-\u00c9loy-les-Mines'), 'fr': u('Saint-\u00c9loy-les-Mines')}, '3347384':{'en': 'Cournon-d\'Auvergne', 'fr': 'Cournon-d\'Auvergne'}, '3347383':{'en': u('Pont-du-Ch\u00e2teau'), 'fr': u('Pont-du-Ch\u00e2teau')}, '3347382':{'en': 'Ambert', 'fr': 'Ambert'}, '3347381':{'en': 'La Bourboule', 'fr': 'La Bourboule'}, '3347380':{'en': 'Thiers', 'fr': 'Thiers'}, '435632':{'de': 'Stanzach', 'en': 'Stanzach'}, '3347389':{'en': 'Issoire', 'fr': 'Issoire'}, '441753':{'en': 'Slough'}, '4415071':{'en': 'Louth/Alford (Lincs)/Spilsby (Horncastle)'}, '4415073':{'en': 'Louth'}, '3323565':{'en': u('Saint-\u00c9tienne-du-Rouvray'), 'fr': u('Saint-\u00c9tienne-du-Rouvray')}, '3323564':{'en': 'Oissel', 'fr': 'Oissel'}, '35974321':{'bg': u('\u0425\u044a\u0440\u0441\u043e\u0432\u043e, \u0411\u043b\u0430\u0433.'), 'en': 'Harsovo, Blag.'}, '3329972':{'en': 'Redon', 'fr': 'Redon'}, '3323566':{'en': u('Saint-\u00c9tienne-du-Rouvray'), 'fr': u('Saint-\u00c9tienne-du-Rouvray')}, '3522458':{'de': 'Soleuvre/Differdingen', 'en': 'Soleuvre/Differdange', 'fr': 'Soleuvre/Differdange'}, '3522459':{'de': 'Soleuvre', 'en': 'Soleuvre', 'fr': 'Soleuvre'}, '3522454':{'de': 'Esch-sur-Alzette', 'en': 'Esch-sur-Alzette', 'fr': 'Esch-sur-Alzette'}, '3522455':{'de': 'Esch-sur-Alzette/Monnerich', 'en': 'Esch-sur-Alzette/Mondercange', 'fr': 'Esch-sur-Alzette/Mondercange'}, '3522456':{'de': u('R\u00fcmelingen'), 'en': 'Rumelange', 'fr': 'Rumelange'}, '3522457':{'de': 'Esch-sur-Alzette/Schifflingen', 'en': 'Esch-sur-Alzette/Schifflange', 'fr': 'Esch-sur-Alzette/Schifflange'}, '3522450':{'de': 'Bascharage/Petingen/Rodingen', 'en': 'Bascharage/Petange/Rodange', 'fr': 'Bascharage/Petange/Rodange'}, '3522451':{'de': u('D\u00fcdelingen/Bettemburg/Livingen'), 'en': 'Dudelange/Bettembourg/Livange', 'fr': 'Dudelange/Bettembourg/Livange'}, '3522452':{'de': u('D\u00fcdelingen'), 'en': 'Dudelange', 'fr': 'Dudelange'}, '3522453':{'de': 'Esch-sur-Alzette', 'en': 'Esch-sur-Alzette', 'fr': 'Esch-sur-Alzette'}, '3355539':{'en': 'Couzeix', 'fr': 'Couzeix'}, '3323562':{'en': 'Rouen', 'fr': 'Rouen'}, '3355537':{'en': 'Limoges', 'fr': 'Limoges'}, '441420':{'en': 'Alton'}, '3355533':{'en': 'Limoges', 'fr': 'Limoges'}, '437473':{'de': 'Blindenmarkt', 'en': 'Blindenmarkt'}, '3355532':{'en': 'Limoges', 'fr': 'Limoges'}, '3522678':{'de': 'Junglinster', 'en': 'Junglinster', 'fr': 'Junglinster'}, '3522679':{'de': 'Berdorf/Consdorf', 'en': 'Berdorf/Consdorf', 'fr': 'Berdorf/Consdorf'}, '3522671':{'de': 'Betzdorf', 'en': 'Betzdorf', 'fr': 'Betzdorf'}, '3522672':{'de': 'Echternach', 'en': 'Echternach', 'fr': 'Echternach'}, '3522673':{'de': 'Rosport', 'en': 'Rosport', 'fr': 'Rosport'}, '3522674':{'de': 'Wasserbillig', 'en': 'Wasserbillig', 'fr': 'Wasserbillig'}, '3522675':{'de': 'Distrikt Grevenmacher-sur-Moselle', 'en': 'Grevenmacher-sur-Moselle', 'fr': 'Grevenmacher-sur-Moselle'}, '3522676':{'de': 'Wormeldingen', 'en': 'Wormeldange', 'fr': 'Wormeldange'}, '3338906':{'en': 'Brunstatt', 'fr': 'Brunstatt'}, '3349454':{'en': 'Cogolin', 'fr': 'Cogolin'}, '437472':{'de': 'Amstetten', 'en': 'Amstetten'}, '3338908':{'en': 'Altkirch', 'fr': 'Altkirch'}, '3323851':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323853':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323852':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323855':{'en': 'Saint-Jean-de-Braye', 'fr': 'Saint-Jean-de-Braye'}, '3323854':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323856':{'en': u('Orl\u00e9ans'), 'fr': u('Orl\u00e9ans')}, '3323859':{'en': 'Jargeau', 'fr': 'Jargeau'}, '3323858':{'en': u('Ch\u00e2teauneuf-sur-Loire'), 'fr': u('Ch\u00e2teauneuf-sur-Loire')}, '3349322':{'en': 'Cagnes-sur-Mer', 'fr': 'Cagnes-sur-Mer'}, '3349321':{'en': 'Nice', 'fr': 'Nice'}, '3349320':{'en': 'Cagnes-sur-Mer', 'fr': 'Cagnes-sur-Mer'}, '44121':{'en': 'Birmingham'}, '3346839':{'en': u('Am\u00e9lie-les-Bains-Palalda'), 'fr': u('Am\u00e9lie-les-Bains-Palalda')}, '3346837':{'en': 'Saint-Cyprien', 'fr': 'Saint-Cyprien'}, '3346834':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3346835':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3346832':{'en': 'Narbonne', 'fr': 'Narbonne'}, '3346833':{'en': 'Coursan', 'fr': 'Coursan'}, '3346830':{'en': 'Font-Romeu-Odeillo-Via', 'fr': 'Font-Romeu-Odeillo-Via'}, '3346831':{'en': 'Limoux', 'fr': 'Limoux'}, '442827':{'en': 'Ballymoney'}, '442825':{'en': 'Ballymena'}, '442820':{'en': 'Ballycastle'}, '442821':{'en': 'Martinstown'}, '442828':{'en': 'Larne'}, '442829':{'en': 'Kilrea'}, '35930419':{'bg': u('\u042f\u0433\u043e\u0434\u0438\u043d\u0430'), 'en': 'Yagodina'}, '35930418':{'bg': u('\u0411\u0443\u0439\u043d\u043e\u0432\u043e, \u0421\u043c\u043e\u043b.'), 'en': 'Buynovo, Smol.'}, '35930410':{'bg': u('\u0411\u0440\u0435\u0437\u0435, \u0421\u043c\u043e\u043b.'), 'en': 'Breze, Smol.'}, '35930417':{'bg': u('\u0413\u0440\u043e\u0445\u043e\u0442\u043d\u043e'), 'en': 'Grohotno'}, '35930416':{'bg': u('\u0413\u044c\u043e\u0432\u0440\u0435\u043d'), 'en': 'Gyovren'}, '3332670':{'en': u('Ch\u00e2lons-en-Champagne'), 'fr': u('Ch\u00e2lons-en-Champagne')}, '3332677':{'en': 'Reims', 'fr': 'Reims'}, '3332674':{'en': u('Vitry-le-Fran\u00e7ois'), 'fr': u('Vitry-le-Fran\u00e7ois')}, '3593133':{'bg': u('\u041a\u0430\u043b\u043e\u0444\u0435\u0440'), 'en': 'Kalofer'}, '3593132':{'bg': u('\u0411\u0430\u043d\u044f, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Banya, Plovdiv'}, '3332679':{'en': 'Reims', 'fr': 'Reims'}, '3593130':{'bg': u('\u041a\u0430\u0440\u0430\u0432\u0435\u043b\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Karavelovo, Plovdiv'}, '3593137':{'bg': u('\u041a\u043b\u0438\u0441\u0443\u0440\u0430, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Klisura, Plovdiv'}, '3593136':{'bg': u('\u0420\u043e\u0437\u0438\u043d\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Rozino, Plovdiv'}, '3593135':{'bg': u('\u041a\u044a\u0440\u043d\u0430\u0440\u0435'), 'en': 'Karnare'}, '3593134':{'bg': u('\u0421\u043e\u043f\u043e\u0442, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Sopot, Plovdiv'}, '355268':{'en': u('Qend\u00ebr/Gruemir\u00eb, Mal\u00ebsi e Madhe')}, '35941357':{'bg': u('\u0417\u0435\u0442\u044c\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Zetyovo, St. Zagora'}, '3325467':{'en': u('Vend\u00f4me'), 'fr': u('Vend\u00f4me')}, '3325460':{'en': u('Ch\u00e2teauroux'), 'fr': u('Ch\u00e2teauroux')}, '3325461':{'en': u('Ch\u00e2teauroux'), 'fr': u('Ch\u00e2teauroux')}, '40337':{'en': 'Vrancea', 'ro': 'Vrancea'}, '40336':{'en': u('Gala\u021bi'), 'ro': u('Gala\u021bi')}, '40335':{'en': 'Vaslui', 'ro': 'Vaslui'}, '40334':{'en': u('Bac\u0103u'), 'ro': u('Bac\u0103u')}, '40333':{'en': u('Neam\u021b'), 'ro': u('Neam\u021b')}, '40332':{'en': u('Ia\u0219i'), 'ro': u('Ia\u0219i')}, '40331':{'en': u('Boto\u0219ani'), 'ro': u('Boto\u0219ani')}, '40330':{'en': 'Suceava', 'ro': 'Suceava'}, '437288':{'de': 'Ulrichsberg', 'en': 'Ulrichsberg'}, '437289':{'de': u('Rohrbach in Ober\u00f6sterreich'), 'en': u('Rohrbach in Ober\u00f6sterreich')}, '3356578':{'en': 'Rodez', 'fr': 'Rodez'}, '40339':{'en': u('Br\u0103ila'), 'ro': u('Br\u0103ila')}, '40338':{'en': u('Buz\u0103u'), 'ro': u('Buz\u0103u')}, '434733':{'de': 'Malta', 'en': 'Malta'}, '434732':{'de': u('Gm\u00fcnd in K\u00e4rnten'), 'en': u('Gm\u00fcnd in K\u00e4rnten')}, '359590':{'bg': u('\u0426\u0430\u0440\u0435\u0432\u043e'), 'en': 'Tsarevo'}, '434736':{'de': 'Innerkrems', 'en': 'Innerkrems'}, '434735':{'de': u('Kremsbr\u00fccke'), 'en': u('Kremsbr\u00fccke')}, '434734':{'de': 'Rennweg', 'en': 'Rennweg'}, '375177':{'be': u('\u0411\u0430\u0440\u044b\u0441\u0430\u045e'), 'en': 'Borisov', 'ru': u('\u0411\u043e\u0440\u0438\u0441\u043e\u0432')}, '375176':{'be': u('\u041c\u0430\u043b\u0430\u0434\u0437\u0435\u0447\u043d\u0430'), 'en': 'Molodechno', 'ru': u('\u041c\u043e\u043b\u043e\u0434\u0435\u0447\u043d\u043e')}, '375174':{'be': u('\u0421\u0430\u043b\u0456\u0433\u043e\u0440\u0441\u043a'), 'en': 'Soligorsk', 'ru': u('\u0421\u043e\u043b\u0438\u0433\u043e\u0440\u0441\u043a')}, '35122':{'en': 'Porto', 'pt': 'Porto'}, '35121':{'en': 'Lisbon', 'pt': 'Lisboa'}, '3593661':{'bg': u('\u0418\u0432\u0430\u0439\u043b\u043e\u0432\u0433\u0440\u0430\u0434'), 'en': 'Ivaylovgrad'}, '3347178':{'en': u('Riom-\u00e9s-Montagnes'), 'fr': u('Riom-\u00e9s-Montagnes')}, '3347174':{'en': 'Brioude', 'fr': 'Brioude'}, '3347175':{'en': 'Monistrol-sur-Loire', 'fr': 'Monistrol-sur-Loire'}, '3347177':{'en': 'Langeac', 'fr': 'Langeac'}, '435284':{'de': 'Gerlos', 'en': 'Gerlos'}, '435285':{'de': 'Mayrhofen', 'en': 'Mayrhofen'}, '3598156':{'bg': u('\u0427\u0435\u0440\u0432\u0435\u043d, \u0420\u0443\u0441\u0435'), 'en': 'Cherven, Ruse'}, '435287':{'de': 'Tux', 'en': 'Tux'}, '3598150':{'bg': u('\u0421\u0435\u043c\u0435\u0440\u0434\u0436\u0438\u0435\u0432\u043e'), 'en': 'Semerdzhievo'}, '3598151':{'bg': u('\u041f\u0440\u043e\u0441\u0435\u043d\u0430'), 'en': 'Prosena'}, '3598152':{'bg': u('\u041a\u0440\u0430\u0441\u0435\u043d, \u0420\u0443\u0441\u0435'), 'en': 'Krasen, Ruse'}, '435283':{'de': 'Kaltenbach', 'en': 'Kaltenbach'}, '3598158':{'bg': u('\u041c\u0435\u0447\u043a\u0430, \u0420\u0443\u0441\u0435'), 'en': 'Mechka, Ruse'}, '3598159':{'bg': u('\u041a\u043e\u0448\u043e\u0432'), 'en': 'Koshov'}, '3338291':{'en': 'Aumetz', 'fr': 'Aumetz'}, '3347719':{'en': 'Saint-Chamond', 'fr': 'Saint-Chamond'}, '436418':{'de': 'Kleinarl', 'en': 'Kleinarl'}, '3347710':{'en': 'Firminy', 'fr': 'Firminy'}, '436415':{'de': 'Schwarzach im Pongau', 'en': 'Schwarzach im Pongau'}, '436416':{'de': 'Lend', 'en': 'Lend'}, '436417':{'de': u('H\u00fcttschlag'), 'en': u('H\u00fcttschlag')}, '433842':{'de': 'Leoben', 'en': 'Leoben'}, '436412':{'de': 'Sankt Johann im Pongau', 'en': 'St. Johann im Pongau'}, '436413':{'de': 'Wagrain', 'en': 'Wagrain'}, '3338125':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3316951':{'en': u('Sainte-Genevi\u00e8ve-des-Bois'), 'fr': u('Sainte-Genevi\u00e8ve-des-Bois')}, '3316952':{'en': 'Montgeron', 'fr': 'Montgeron'}, '3316953':{'en': 'Massy', 'fr': 'Massy'}, '3338121':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3316956':{'en': 'Juvisy-sur-Orge', 'fr': 'Juvisy-sur-Orge'}, '3316957':{'en': 'Athis-Mons', 'fr': 'Athis-Mons'}, '433844':{'de': 'Kammern im Liesingtal', 'en': 'Kammern im Liesingtal'}, '437484':{'de': u('G\u00f6stling an der Ybbs'), 'en': u('G\u00f6stling an der Ybbs')}, '4171':{'de': 'St. Gallen', 'en': 'St. Gallen', 'fr': 'St. Gall', 'it': 'San Gallo'}, '433847':{'de': 'Trofaiach', 'en': 'Trofaiach'}, '35991668':{'bg': u('\u041c\u0430\u043d\u0430\u0441\u0442\u0438\u0440\u0438\u0449\u0435'), 'en': 'Manastirishte'}, '3597428':{'bg': u('\u0413\u0430\u0431\u0440\u0435\u043d\u0435'), 'en': 'Gabrene'}, '3597939':{'bg': u('\u0426\u044a\u0440\u0432\u0430\u0440\u0438\u0446\u0430'), 'en': 'Tsarvaritsa'}, '3597938':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u0423\u0439\u043d\u043e'), 'en': 'Dolno Uyno'}, '3597425':{'bg': u('\u041a\u0443\u043b\u0430\u0442\u0430'), 'en': 'Kulata'}, '3597424':{'bg': u('\u041a\u044a\u0440\u043d\u0430\u043b\u043e\u0432\u043e'), 'en': 'Karnalovo'}, '3597427':{'bg': u('\u041f\u044a\u0440\u0432\u043e\u043c\u0430\u0439, \u0411\u043b\u0430\u0433.'), 'en': 'Parvomay, Blag.'}, '3597426':{'bg': u('\u041c\u0430\u0440\u0438\u043a\u043e\u0441\u0442\u0438\u043d\u043e\u0432\u043e'), 'en': 'Marikostinovo'}, '3597933':{'bg': u('\u0413\u0440\u0430\u043c\u0430\u0436\u0434\u0430\u043d\u043e'), 'en': 'Gramazhdano'}, '3597932':{'bg': u('\u0428\u0438\u043f\u043e\u0447\u0430\u043d\u043e'), 'en': 'Shipochano'}, '3597423':{'bg': u('\u041a\u043e\u043b\u0430\u0440\u043e\u0432\u043e, \u0411\u043b\u0430\u0433.'), 'en': 'Kolarovo, Blag.'}, '3597422':{'bg': u('\u0422\u043e\u043f\u043e\u043b\u043d\u0438\u0446\u0430, \u0411\u043b\u0430\u0433.'), 'en': 'Topolnitsa, Blag.'}, '35967309':{'bg': u('\u0410\u0433\u0430\u0442\u043e\u0432\u043e'), 'en': 'Agatovo'}, '35967308':{'bg': u('\u041b\u043e\u0432\u043d\u0438\u0434\u043e\u043b'), 'en': 'Lovnidol'}, '35967307':{'bg': u('\u041c\u043b\u0435\u0447\u0435\u0432\u043e'), 'en': 'Mlechevo'}, '35967306':{'bg': u('\u0413\u0440\u0430\u0434\u0438\u0449\u0435, \u0413\u0430\u0431\u0440.'), 'en': 'Gradishte, Gabr.'}, '35967305':{'bg': u('\u0421\u0442\u043e\u043a\u0438\u0442\u0435'), 'en': 'Stokite'}, '35967304':{'bg': u('\u041a\u0440\u0430\u043c\u043e\u043b\u0438\u043d'), 'en': 'Kramolin'}, '35967303':{'bg': u('\u0411\u0430\u0442\u043e\u0448\u0435\u0432\u043e'), 'en': 'Batoshevo'}, '35967302':{'bg': u('\u041a\u0440\u044a\u0432\u0435\u043d\u0438\u043a'), 'en': 'Kravenik'}, '35967301':{'bg': u('\u0418\u0434\u0438\u043b\u0435\u0432\u043e'), 'en': 'Idilevo'}, '3323198':{'en': 'Deauville', 'fr': 'Deauville'}, '3323190':{'en': 'Falaise', 'fr': 'Falaise'}, '3323191':{'en': 'Cabourg', 'fr': 'Cabourg'}, '3323192':{'en': 'Bayeux', 'fr': 'Bayeux'}, '3323193':{'en': 'Caen', 'fr': 'Caen'}, '3323194':{'en': 'Caen', 'fr': 'Caen'}, '3323195':{'en': u('H\u00e9rouville-Saint-Clair'), 'fr': u('H\u00e9rouville-Saint-Clair')}, '3323196':{'en': 'Ouistreham', 'fr': 'Ouistreham'}, '3323197':{'en': 'Ouistreham', 'fr': 'Ouistreham'}, '3329765':{'en': 'Languidic', 'fr': 'Languidic'}, '3329764':{'en': 'Lorient', 'fr': 'Lorient'}, '46225':{'en': u('Hedemora-S\u00e4ter'), 'sv': u('Hedemora-S\u00e4ter')}, '3329766':{'en': 'Grand-Champ', 'fr': 'Grand-Champ'}, '35947356':{'bg': u('\u041c\u0440\u0430\u043c\u043e\u0440, \u042f\u043c\u0431\u043e\u043b'), 'en': 'Mramor, Yambol'}, '46222':{'en': 'Skinnskatteberg', 'sv': 'Skinnskatteberg'}, '3329763':{'en': 'Vannes', 'fr': 'Vannes'}, '3329762':{'en': 'Vannes', 'fr': 'Vannes'}, '3329769':{'en': 'Vannes', 'fr': 'Vannes'}, '3329768':{'en': 'Vannes', 'fr': 'Vannes'}, '3323336':{'en': 'Argentan', 'fr': 'Argentan'}, '3329839':{'en': 'Bannalec', 'fr': 'Bannalec'}, '3355679':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3323332':{'en': u('Alen\u00e7on'), 'fr': u('Alen\u00e7on')}, '3355902':{'en': 'Pau', 'fr': 'Pau'}, '3355903':{'en': 'Anglet', 'fr': 'Anglet'}, '3329837':{'en': 'Plabennec', 'fr': 'Plabennec'}, '3355901':{'en': 'Biarritz', 'fr': 'Biarritz'}, '3355670':{'en': u('Saint-M\u00e9dard-en-Jalles'), 'fr': u('Saint-M\u00e9dard-en-Jalles')}, '3329830':{'en': 'Landerneau', 'fr': 'Landerneau'}, '3329833':{'en': 'Brest', 'fr': 'Brest'}, '3329832':{'en': 'Saint-Renan', 'fr': 'Saint-Renan'}, '3349244':{'en': 'Savines-le-Lac', 'fr': 'Savines-le-Lac'}, '3349245':{'en': 'Guillestre', 'fr': 'Guillestre'}, '3349247':{'en': 'Nice', 'fr': 'Nice'}, '3349241':{'en': 'Menton', 'fr': 'Menton'}, '3349242':{'en': 'Grasse', 'fr': 'Grasse'}, '3349243':{'en': 'Embrun', 'fr': 'Embrun'}, '355894':{'en': u('Livadhja/Dhiv\u00ebr, Sarand\u00eb')}, '355895':{'en': u('Finiq/Mesopotam/Vergo, Delvin\u00eb')}, '355892':{'en': u('Aliko/Lukov\u00eb, Sarand\u00eb')}, '3349249':{'en': 'Gap', 'fr': 'Gap'}, '355891':{'en': u('Konispol/Xare/Markat, Sarand\u00eb')}, '4415243':{'en': 'Lancaster'}, '4415242':{'en': 'Hornby'}, '4415241':{'en': 'Lancaster'}, '37424973':{'am': u('\u053f\u0561\u0569\u0576\u0561\u0572\u0562\u0575\u0578\u0582\u0580'), 'en': 'Katnaghbyur', 'ru': u('\u041a\u0430\u0442\u043d\u0430\u0445\u0431\u044e\u0440')}, '4415247':{'en': 'Lancaster'}, '4415246':{'en': 'Lancaster'}, '4415245':{'en': 'Lancaster'}, '4415244':{'en': 'Lancaster'}, '4415249':{'en': 'Lancaster'}, '4415248':{'en': 'Lancaster'}, '3751797':{'be': u('\u041c\u044f\u0434\u0437\u0435\u043b'), 'en': 'Myadel', 'ru': u('\u041c\u044f\u0434\u0435\u043b\u044c')}, '3751796':{'be': u('\u041a\u0440\u0443\u043f\u043a\u0456, \u041c\u0456\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Krupki, Minsk Region', 'ru': u('\u041a\u0440\u0443\u043f\u043a\u0438, \u041c\u0438\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751795':{'be': u('\u0421\u043b\u0443\u0446\u043a'), 'en': 'Slutsk', 'ru': u('\u0421\u043b\u0443\u0446\u043a')}, '3751794':{'be': u('\u041b\u044e\u0431\u0430\u043d\u044c, \u041c\u0456\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Lyuban, Minsk Region', 'ru': u('\u041b\u044e\u0431\u0430\u043d\u044c, \u041c\u0438\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751793':{'be': u('\u041a\u043b\u0435\u0446\u043a, \u041c\u0456\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Kletsk, Minsk Region', 'ru': u('\u041a\u043b\u0435\u0446\u043a, \u041c\u0438\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751792':{'be': u('\u0421\u0442\u0430\u0440\u044b\u044f \u0414\u0430\u0440\u043e\u0433\u0456, \u041c\u0456\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Starye Dorogi, Minsk Region', 'ru': u('\u0421\u0442\u0430\u0440\u044b\u0435 \u0414\u043e\u0440\u043e\u0433\u0438, \u041c\u0438\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '441830':{'en': 'Kirkwhelpington'}, '441832':{'en': 'Clopton'}, '441833':{'en': 'Barnard Castle'}, '441834':{'en': 'Narberth'}, '441835':{'en': 'St Boswells'}, '441837':{'en': 'Okehampton'}, '3322310':{'en': u('P\u00e9nestin'), 'fr': u('P\u00e9nestin')}, '3322315':{'en': 'Cancale', 'fr': 'Cancale'}, '437618':{'de': u('Neukirchen, Altm\u00fcnster'), 'en': u('Neukirchen, Altm\u00fcnster')}, '3322316':{'en': 'Combourg', 'fr': 'Combourg'}, '437615':{'de': 'Scharnstein', 'en': 'Scharnstein'}, '3322318':{'en': 'Saint-Malo', 'fr': 'Saint-Malo'}, '437617':{'de': 'Traunkirchen', 'en': 'Traunkirchen'}, '437616':{'de': u('Gr\u00fcnau im Almtal'), 'en': u('Gr\u00fcnau im Almtal')}, '3332804':{'en': 'Lille', 'fr': 'Lille'}, '437613':{'de': 'Laakirchen', 'en': 'Laakirchen'}, '3332807':{'en': 'Lille', 'fr': 'Lille'}, '3324029':{'en': 'Nantes', 'fr': 'Nantes'}, '3593927':{'bg': u('\u0427\u0435\u0440\u043d\u043e\u0433\u043e\u0440\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Chernogorovo, Hask.'}, '437263':{'de': 'Bad Zell', 'en': 'Bad Zell'}, '3752354':{'be': u('\u0415\u043b\u044c\u0441\u043a, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Yelsk, Gomel Region', 'ru': u('\u0415\u043b\u044c\u0441\u043a, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '435337':{'de': 'Brixlegg', 'en': 'Brixlegg'}, '3752133':{'be': u('\u0427\u0430\u0448\u043d\u0456\u043a\u0456, \u0412\u0456\u0446\u0435\u0431\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Chashniki, Vitebsk Region', 'ru': u('\u0427\u0430\u0448\u043d\u0438\u043a\u0438, \u0412\u0438\u0442\u0435\u0431\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '437268':{'de': 'Grein', 'en': 'Grein'}, '437269':{'de': 'Baumgartenberg', 'en': 'Baumgartenberg'}, '3752136':{'be': u('\u0422\u0430\u043b\u0430\u0447\u044b\u043d'), 'en': 'Tolochin', 'ru': u('\u0422\u043e\u043b\u043e\u0447\u0438\u043d')}, '359971':{'bg': u('\u041b\u043e\u043c'), 'en': 'Lom'}, '359973':{'bg': u('\u041a\u043e\u0437\u043b\u043e\u0434\u0443\u0439'), 'en': 'Kozloduy'}, '434236':{'de': 'Eberndorf', 'en': 'Eberndorf'}, '432774':{'de': 'Innermanzing', 'en': 'Innermanzing'}, '3356598':{'en': 'Saint-Affrique', 'fr': 'Saint-Affrique'}, '3356597':{'en': 'Saint-Affrique', 'fr': 'Saint-Affrique'}, '432772':{'de': 'Neulengbach', 'en': 'Neulengbach'}, '3325320':{'en': 'Angers', 'fr': 'Angers'}, '3347549':{'en': 'Le Teil', 'fr': 'Le Teil'}, '3343849':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347545':{'en': 'Saint-Donat-sur-l\'Herbasse', 'fr': 'Saint-Donat-sur-l\'Herbasse'}, '3347544':{'en': 'Valence', 'fr': 'Valence'}, '3347541':{'en': 'Valence', 'fr': 'Valence'}, '3347540':{'en': 'Valence', 'fr': 'Valence'}, '3347543':{'en': 'Valence', 'fr': 'Valence'}, '3347542':{'en': 'Valence', 'fr': 'Valence'}, '3334402':{'en': 'Beauvais', 'fr': 'Beauvais'}, '3334403':{'en': 'Noailles', 'fr': 'Noailles'}, '3334406':{'en': 'Beauvais', 'fr': 'Beauvais'}, '3334407':{'en': 'Bresles', 'fr': 'Bresles'}, '3334405':{'en': 'Beauvais', 'fr': 'Beauvais'}, '3334409':{'en': 'Noyon', 'fr': 'Noyon'}, '3599162':{'bg': u('\u041c\u0438\u0445\u0430\u0439\u043b\u043e\u0432\u043e, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Mihaylovo, Vratsa'}, '3599163':{'bg': u('\u0425\u044a\u0440\u043b\u0435\u0446'), 'en': 'Harlets'}, '3599160':{'bg': u('\u0413\u043b\u043e\u0436\u0435\u043d\u0435, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Glozhene, Vratsa'}, '3599161':{'bg': u('\u041c\u0438\u0437\u0438\u044f'), 'en': 'Mizia'}, '3599166':{'bg': u('\u0425\u0430\u0439\u0440\u0435\u0434\u0438\u043d'), 'en': 'Hayredin'}, '3599167':{'bg': u('\u041b\u0438\u043f\u043d\u0438\u0446\u0430, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Lipnitsa, Vratsa'}, '3599164':{'bg': u('\u041a\u0440\u0443\u0448\u043e\u0432\u0438\u0446\u0430, \u0412\u0440\u0430\u0446\u0430'), 'en': 'Krushovitsa, Vratsa'}, '3599165':{'bg': u('\u0421\u043e\u0444\u0440\u043e\u043d\u0438\u0435\u0432\u043e'), 'en': 'Sofronievo'}, '3599168':{'bg': u('\u0411\u0443\u0442\u0430\u043d'), 'en': 'Butan'}, '3599169':{'bg': u('\u0420\u043e\u0433\u043e\u0437\u0435\u043d'), 'en': 'Rogozen'}, '3323730':{'en': 'Chartres', 'fr': 'Chartres'}, '3353414':{'en': 'Saint-Girons', 'fr': 'Saint-Girons'}, '35374':{'en': 'Letterkenny/Donegal/Dungloe/Buncrana'}, '441581':{'en': 'New Luce'}, '441582':{'en': 'Luton'}, '3323733':{'en': 'Chartres', 'fr': 'Chartres'}, '441584':{'en': 'Ludlow'}, '441586':{'en': 'Campbeltown'}, '441588':{'en': 'Bishops Castle'}, '40243':{'en': u('Ialomi\u021ba'), 'ro': u('Ialomi\u021ba')}, '34827':{'en': u('C\u00e1ceres'), 'es': u('C\u00e1ceres')}, '40242':{'en': u('C\u0103l\u0103ra\u0219i'), 'ro': u('C\u0103l\u0103ra\u0219i')}, '434233':{'de': 'Griffen', 'en': 'Griffen'}, '40240':{'en': 'Tulcea', 'ro': 'Tulcea'}, '433339':{'de': 'Friedberg', 'en': 'Friedberg'}, '3347818':{'en': 'Lyon', 'fr': 'Lyon'}, '3347817':{'en': 'Lyon', 'fr': 'Lyon'}, '3347816':{'en': 'Brindas', 'fr': 'Brindas'}, '3347814':{'en': 'Lyon', 'fr': 'Lyon'}, '434230':{'de': 'Globasnitz', 'en': 'Globasnitz'}, '3346638':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346639':{'en': 'Pont-Saint-Esprit', 'fr': 'Pont-Saint-Esprit'}, '3346634':{'en': 'La Grand Combe', 'fr': 'La Grand Combe'}, '359777':{'bg': u('\u0420\u0430\u0434\u043e\u043c\u0438\u0440'), 'en': 'Radomir'}, '3346636':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3346637':{'en': 'Remoulins', 'fr': 'Remoulins'}, '3346630':{'en': u('Al\u00e8s'), 'fr': u('Al\u00e8s')}, '3346631':{'en': u('Saint-Ch\u00e9ly-d\'Apcher'), 'fr': u('Saint-Ch\u00e9ly-d\'Apcher')}, '3346632':{'en': 'Marvejols', 'fr': 'Marvejols'}, '3346633':{'en': u('Bagnols-sur-C\u00e8ze'), 'fr': u('Bagnols-sur-C\u00e8ze')}, '3522476':{'de': 'Wormeldingen', 'en': 'Wormeldange', 'fr': 'Wormeldange'}, '3597745':{'bg': u('\u0415\u0433\u044a\u043b\u043d\u0438\u0446\u0430'), 'en': 'Egalnitsa'}, '3522474':{'de': 'Wasserbillig', 'en': 'Wasserbillig', 'fr': 'Wasserbillig'}, '3522475':{'de': 'Distrikt Grevenmacher-sur-Moselle', 'en': 'Grevenmacher-sur-Moselle', 'fr': 'Grevenmacher-sur-Moselle'}, '3522472':{'de': 'Echternach', 'en': 'Echternach', 'fr': 'Echternach'}, '3522473':{'de': 'Rosport', 'en': 'Rosport', 'fr': 'Rosport'}, '3597742':{'bg': u('\u041a\u0430\u043b\u0438\u0449\u0435'), 'en': 'Kalishte'}, '3522471':{'de': 'Betzdorf', 'en': 'Betzdorf', 'fr': 'Betzdorf'}, '3522478':{'de': 'Junglinster', 'en': 'Junglinster', 'fr': 'Junglinster'}, '3522479':{'de': 'Berdorf/Consdorf', 'en': 'Berdorf/Consdorf', 'fr': 'Berdorf/Consdorf'}, '4419468':{'en': 'Whitehaven'}, '37426796':{'am': u('\u0544\u0578\u057d\u0565\u057d\u0563\u0565\u0572'), 'en': 'Mosesgegh', 'ru': u('\u041c\u043e\u0441\u0435\u0441\u0433\u0435\u0445')}, '3355924':{'en': 'Biarritz', 'fr': 'Biarritz'}, '437285':{'de': u('Hofkirchen im M\u00fchlkreis'), 'en': u('Hofkirchen im M\u00fchlkreis')}, '3522652':{'de': u('D\u00fcdelingen'), 'en': 'Dudelange', 'fr': 'Dudelange'}, '3522653':{'de': 'Esch-sur-Alzette', 'en': 'Esch-sur-Alzette', 'fr': 'Esch-sur-Alzette'}, '3522650':{'de': 'Bascharage/Petingen/Rodingen', 'en': 'Bascharage/Petange/Rodange', 'fr': 'Bascharage/Petange/Rodange'}, '3522651':{'de': u('D\u00fcdelingen/Bettemburg/Livingen'), 'en': 'Dudelange/Bettembourg/Livange', 'fr': 'Dudelange/Bettembourg/Livange'}, '3522656':{'de': u('R\u00fcmelingen'), 'en': 'Rumelange', 'fr': 'Rumelange'}, '3522657':{'de': 'Esch-sur-Alzette/Schifflingen', 'en': 'Esch-sur-Alzette/Schifflange', 'fr': 'Esch-sur-Alzette/Schifflange'}, '3522654':{'de': 'Esch-sur-Alzette', 'en': 'Esch-sur-Alzette', 'fr': 'Esch-sur-Alzette'}, '3522655':{'de': 'Esch-sur-Alzette/Monnerich', 'en': 'Esch-sur-Alzette/Mondercange', 'fr': 'Esch-sur-Alzette/Mondercange'}, '3522658':{'de': 'Soleuvre/Differdingen', 'en': 'Soleuvre/Differdange', 'fr': 'Soleuvre/Differdange'}, '3522659':{'de': 'Soleuvre', 'en': 'Soleuvre', 'fr': 'Soleuvre'}, '3742363':{'am': u('\u0531\u0575\u0576\u0569\u0561\u057a'), 'en': 'Aintab', 'ru': u('\u0410\u0439\u043d\u0442\u0430\u043f')}, '441299':{'en': 'Bewdley'}, '3338929':{'en': 'Colmar', 'fr': 'Colmar'}, '3338437':{'en': 'Poligny', 'fr': 'Poligny'}, '3338924':{'en': 'Colmar', 'fr': 'Colmar'}, '3338927':{'en': 'Wintzenheim', 'fr': 'Wintzenheim'}, '3338433':{'en': 'Morez', 'fr': 'Morez'}, '3338920':{'en': 'Colmar', 'fr': 'Colmar'}, '3338923':{'en': 'Colmar', 'fr': 'Colmar'}, '3338922':{'en': 'Sainte-Croix-en-Plaine', 'fr': 'Sainte-Croix-en-Plaine'}, '3323838':{'en': 'Gien', 'fr': 'Gien'}, '3323833':{'en': 'Puiseaux', 'fr': 'Puiseaux'}, '3323831':{'en': 'Briare', 'fr': 'Briare'}, '3323830':{'en': 'Pithiviers', 'fr': 'Pithiviers'}, '3323837':{'en': 'Briare', 'fr': 'Briare'}, '3323836':{'en': 'Sully-sur-Loire', 'fr': 'Sully-sur-Loire'}, '3323835':{'en': u('Saint-Beno\u00eet-sur-Loire'), 'fr': u('Saint-Beno\u00eet-sur-Loire')}, '3323834':{'en': 'Malesherbes', 'fr': 'Malesherbes'}, '3358295':{'en': 'Toulouse', 'fr': 'Toulouse'}, '433333':{'de': 'Sebersdorf', 'en': 'Sebersdorf'}, '3348671':{'en': 'Carpentras', 'fr': 'Carpentras'}, '441962':{'en': 'Winchester'}, '3346858':{'en': 'Narbonne', 'fr': 'Narbonne'}, '3346859':{'en': 'Saint-Paul-de-Fenouillet', 'fr': 'Saint-Paul-de-Fenouillet'}, '3346850':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3346851':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3346852':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3346853':{'en': 'Thuir', 'fr': 'Thuir'}, '3346854':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3346855':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3346856':{'en': 'Perpignan', 'fr': 'Perpignan'}, '3346857':{'en': 'Millas', 'fr': 'Millas'}, '390781':{'it': 'Iglesias'}, '390783':{'en': 'Oristano', 'it': 'Oristano'}, '390782':{'it': 'Lanusei'}, '390785':{'it': 'Macomer'}, '390784':{'it': 'Nuoro'}, '390789':{'en': 'Sassari', 'it': 'Olbia'}, '3348905':{'en': 'Nice', 'fr': 'Nice'}, '3348900':{'en': 'Nice', 'fr': 'Nice'}, '3348902':{'en': 'Antibes', 'fr': 'Antibes'}, '3348903':{'en': 'Nice', 'fr': 'Nice'}, '3593115':{'bg': u('\u041a\u0443\u043a\u043b\u0435\u043d'), 'en': 'Kuklen'}, '3593114':{'bg': u('\u0411\u0440\u0435\u0441\u0442\u043d\u0438\u043a'), 'en': 'Brestnik'}, '3593117':{'bg': u('\u041a\u0430\u0442\u0443\u043d\u0438\u0446\u0430'), 'en': 'Katunitsa'}, '3593116':{'bg': u('\u041a\u0440\u0443\u043c\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Krumovo, Plovdiv'}, '34859':{'en': 'Huelva', 'es': 'Huelva'}, '3593110':{'bg': u('\u041f\u043e\u043f\u043e\u0432\u0438\u0446\u0430'), 'en': 'Popovitsa'}, '3593113':{'bg': u('\u0411\u0440\u0430\u043d\u0438\u043f\u043e\u043b\u0435'), 'en': 'Branipole'}, '3345010':{'en': 'Annecy', 'fr': 'Annecy'}, '34856':{'en': u('C\u00e1diz'), 'es': u('C\u00e1diz')}, '3593119':{'bg': u('\u0413\u044a\u043b\u044a\u0431\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Galabovo, Plovdiv'}, '3593118':{'bg': u('\u0421\u0430\u0434\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Sadovo, Plovdiv'}, '34853':{'en': u('Ja\u00e9n'), 'es': u('Ja\u00e9n')}, '3332129':{'en': 'Bully-les-Mines', 'fr': 'Bully-les-Mines'}, '3332128':{'en': 'Lens', 'fr': 'Lens'}, '3332655':{'en': u('\u00c9pernay'), 'fr': u('\u00c9pernay')}, '3332654':{'en': u('\u00c9pernay'), 'fr': u('\u00c9pernay')}, '3332656':{'en': u('\u00c9pernay'), 'fr': u('\u00c9pernay')}, '3332123':{'en': 'Arras', 'fr': 'Arras'}, '3332650':{'en': 'Reims', 'fr': 'Reims'}, '3332121':{'en': 'Arras', 'fr': 'Arras'}, '3332120':{'en': u('H\u00e9nin-Beaumont'), 'fr': u('H\u00e9nin-Beaumont')}, '3325408':{'en': u('Ch\u00e2teauroux'), 'fr': u('Ch\u00e2teauroux')}, '35951104':{'bg': u('\u0414\u043e\u043b\u0438\u0449\u0435, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Dolishte, Varna'}, '3325400':{'en': u('Valen\u00e7ay'), 'fr': u('Valen\u00e7ay')}, '3325401':{'en': 'Argenton-sur-Creuse', 'fr': 'Argenton-sur-Creuse'}, '3325402':{'en': u('Buzan\u00e7ais'), 'fr': u('Buzan\u00e7ais')}, '3325403':{'en': 'Issoudun', 'fr': 'Issoudun'}, '35951106':{'bg': u('\u041e\u0441\u0435\u043d\u043e\u0432\u043e, \u0412\u0430\u0440\u043d\u0430'), 'en': 'Osenovo, Varna'}, '3325406':{'en': 'Aigurande', 'fr': 'Aigurande'}, '3325407':{'en': u('Ch\u00e2teauroux'), 'fr': u('Ch\u00e2teauroux')}, '390125':{'en': 'Turin', 'it': 'Ivrea'}, '390124':{'it': 'Rivarolo Canavese'}, '3349505':{'en': 'Marseille', 'fr': 'Marseille'}, '390121':{'it': 'Pinerolo'}, '390123':{'it': 'Lanzo Torinese'}, '390122':{'en': 'Turin', 'it': 'Susa'}, '3349508':{'en': 'Marseille', 'fr': 'Marseille'}, '3358197':{'en': 'Toulouse', 'fr': 'Toulouse'}, '433127':{'de': 'Peggau', 'en': 'Peggau'}, '433126':{'de': 'Frohnleiten', 'en': 'Frohnleiten'}, '433125':{'de': u('\u00dcbelbach'), 'en': u('\u00dcbelbach')}, '433124':{'de': 'Gratkorn', 'en': 'Gratkorn'}, '433123':{'de': 'Sankt Oswald bei Plankenwarth', 'en': 'St. Oswald bei Plankenwarth'}, '37423779':{'am': u('\u0532\u0561\u0574\u0562\u0561\u056f\u0561\u0577\u0561\u057f'), 'en': 'Bambakashat', 'ru': u('\u0411\u0430\u043c\u0431\u0430\u043a\u0430\u0448\u0430\u0442')}, '3356293':{'en': 'Tarbes', 'fr': 'Tarbes'}, '3356292':{'en': 'Cauterets', 'fr': 'Cauterets'}, '3356291':{'en': u('Bagn\u00e8res-de-Bigorre'), 'fr': u('Bagn\u00e8res-de-Bigorre')}, '3356290':{'en': 'Ibos', 'fr': 'Ibos'}, '3356297':{'en': u('Argel\u00e8s-Gazost'), 'fr': u('Argel\u00e8s-Gazost')}, '3356295':{'en': u('Bagn\u00e8res-de-Bigorre'), 'fr': u('Bagn\u00e8res-de-Bigorre')}, '3356294':{'en': 'Lourdes', 'fr': 'Lourdes'}, '3356298':{'en': 'Lannemezan', 'fr': 'Lannemezan'}, '35959694':{'bg': u('\u0413\u0430\u0431\u0435\u0440\u043e\u0432\u043e'), 'en': 'Gaberovo'}, '3347489':{'en': 'Amplepuis', 'fr': 'Amplepuis'}, '35971228':{'bg': u('\u041c\u0430\u0440\u0438\u0446\u0430'), 'en': 'Maritsa'}, '3595519':{'bg': u('\u0417\u0438\u0434\u0430\u0440\u043e\u0432\u043e'), 'en': 'Zidarovo'}, '3595518':{'bg': u('\u0420\u0443\u0434\u043d\u0438\u043a, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Rudnik, Burgas'}, '3347480':{'en': 'Morestel', 'fr': 'Morestel'}, '3347481':{'en': 'Oyonnax', 'fr': 'Oyonnax'}, '3347482':{'en': 'Saint-Quentin-Fallavier', 'fr': 'Saint-Quentin-Fallavier'}, '35971220':{'bg': u('\u0413\u0443\u0446\u0430\u043b'), 'en': 'Gutsal'}, '3595513':{'bg': u('\u0413\u0430\u0431\u044a\u0440'), 'en': 'Gabar'}, '3347485':{'en': 'Vienne', 'fr': 'Vienne'}, '3347486':{'en': 'Roussillon', 'fr': 'Roussillon'}, '3347487':{'en': u('P\u00e9lussin'), 'fr': u('P\u00e9lussin')}, '3324757':{'en': 'Amboise', 'fr': 'Amboise'}, '3324755':{'en': 'Luynes', 'fr': 'Luynes'}, '3324754':{'en': 'Tours', 'fr': 'Tours'}, '3324753':{'en': u('Jou\u00e9-l\u00e8s-Tours'), 'fr': u('Jou\u00e9-l\u00e8s-Tours')}, '3324752':{'en': 'Vouvray', 'fr': 'Vouvray'}, '3324751':{'en': 'Tours', 'fr': 'Tours'}, '3324750':{'en': 'Montlouis-sur-Loire', 'fr': 'Montlouis-sur-Loire'}, '435266':{'de': u('\u00d6tztal-Bahnhof'), 'en': u('\u00d6tztal-Bahnhof')}, '3595153':{'bg': u('\u0421\u0443\u0432\u043e\u0440\u043e\u0432\u043e'), 'en': 'Suvorovo'}, '435264':{'de': 'Mieming', 'en': 'Mieming'}, '435265':{'de': 'Nassereith', 'en': 'Nassereith'}, '435262':{'de': 'Telfs', 'en': 'Telfs'}, '435263':{'de': 'Silz', 'en': 'Silz'}, '3324759':{'en': 'Loches', 'fr': 'Loches'}, '3344283':{'en': 'La Ciotat', 'fr': 'La Ciotat'}, '3344282':{'en': 'Aubagne', 'fr': 'Aubagne'}, '3344281':{'en': 'Martigues', 'fr': 'Martigues'}, '3344280':{'en': 'Martigues', 'fr': 'Martigues'}, '3344287':{'en': 'Rognac', 'fr': 'Rognac'}, '3344286':{'en': u('Port-Saint-Louis-du-Rh\u00f4ne'), 'fr': u('Port-Saint-Louis-du-Rh\u00f4ne')}, '3344285':{'en': u('Berre-l\'\u00c9tang'), 'fr': u('Berre-l\'\u00c9tang')}, '3344284':{'en': 'Aubagne', 'fr': 'Aubagne'}, '3344289':{'en': 'Vitrolles', 'fr': 'Vitrolles'}, '3344288':{'en': 'Marignane', 'fr': 'Marignane'}, '3347224':{'en': 'Givors', 'fr': 'Givors'}, '35818':{'en': u('\u00c5land Islands'), 'fi': 'Ahvenanmaa', 'se': u('\u00c5land')}, '35819':{'en': 'Nylandia', 'fi': 'Uusimaa', 'se': 'Nyland'}, '35813':{'en': 'North Karelia', 'fi': 'Pohjois-Karjala', 'se': 'Norra Karelen'}, '35816':{'en': 'Lapland', 'fi': 'Lappi', 'se': 'Lappland'}, '35817':{'en': 'Kuopio', 'fi': 'Kuopio', 'se': 'Kuopio'}, '35814':{'en': 'Central Finland', 'fi': 'Keski-Suomi', 'se': 'Mellersta Finland'}, '35815':{'en': 'Mikkeli', 'fi': 'Mikkeli', 'se': 'St Michel'}, '3347220':{'en': 'Lyon', 'fr': 'Lyon'}, '3347593':{'en': 'Aubenas', 'fr': 'Aubenas'}, '331820':{'en': 'Paris', 'fr': 'Paris'}, '3316978':{'en': u('\u00c9tampes'), 'fr': u('\u00c9tampes')}, '3316979':{'en': 'Chilly-Mazarin', 'fr': 'Chilly-Mazarin'}, '3347223':{'en': 'Saint-Priest', 'fr': 'Saint-Priest'}, '3316975':{'en': 'Massy', 'fr': 'Massy'}, '4152':{'de': 'Winterthur', 'en': 'Winterthur', 'fr': 'Winterthour', 'it': 'Winterthur'}, '4156':{'de': 'Baden', 'en': 'Baden', 'fr': 'Baden', 'it': 'Baden'}, '4155':{'de': 'Rapperswil', 'en': 'Rapperswil', 'fr': 'Rapperswil', 'it': 'Rapperswil'}, '3347156':{'en': 'Yssingeaux', 'fr': 'Yssingeaux'}, '3347150':{'en': 'Brioude', 'fr': 'Brioude'}, '3347159':{'en': 'Yssingeaux', 'fr': 'Yssingeaux'}, '390744':{'it': 'Terni'}, '38948':{'en': 'Prilep/Krusevo'}, '38943':{'en': 'Veles/Kavadarci/Negotino'}, '38942':{'en': 'Gostivar'}, '38947':{'en': 'Bitola/Demir Hisar/Resen'}, '38946':{'en': 'Ohrid/Struga/Debar'}, '38945':{'en': 'Kicevo/Makedonski Brod'}, '38944':{'en': 'Tetovo'}, '3347732':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347733':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347730':{'en': 'Sury-le-Comtal', 'fr': 'Sury-le-Comtal'}, '3347731':{'en': 'Saint-Chamond', 'fr': 'Saint-Chamond'}, '3347736':{'en': u('Andr\u00e9zieux-Bouth\u00e9on'), 'fr': u('Andr\u00e9zieux-Bouth\u00e9on')}, '3347737':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347734':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347735':{'en': 'Aurec-sur-Loire', 'fr': 'Aurec-sur-Loire'}, '3597911':{'bg': u('\u0413\u0440\u0430\u043d\u0438\u0446\u0430'), 'en': 'Granitsa'}, '3597910':{'bg': u('\u0411\u0435\u0440\u0441\u0438\u043d'), 'en': 'Bersin'}, '3347738':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347739':{'en': 'Bourg-Argental', 'fr': 'Bourg-Argental'}, '3597915':{'bg': u('\u041d\u0435\u0432\u0435\u0441\u0442\u0438\u043d\u043e, \u041a\u044e\u0441\u0442.'), 'en': 'Nevestino, Kyust.'}, '3597914':{'bg': u('\u0412\u0430\u043a\u0441\u0435\u0432\u043e'), 'en': 'Vaksevo'}, '3597917':{'bg': u('\u0422\u0430\u0432\u0430\u043b\u0438\u0447\u0435\u0432\u043e'), 'en': 'Tavalichevo'}, '3597916':{'bg': u('\u0411\u0430\u0433\u0440\u0435\u043d\u0446\u0438'), 'en': 'Bagrentsi'}, '390746':{'it': 'Rieti'}, '3596359':{'bg': u('\u0413\u043b\u0430\u0432\u0430'), 'en': 'Glava'}, '3596352':{'bg': u('\u0414\u043e\u043b\u043d\u0438 \u041b\u0443\u043a\u043e\u0432\u0438\u0442'), 'en': 'Dolni Lukovit'}, '3596356':{'bg': u('\u041a\u043e\u043c\u0430\u0440\u0435\u0432\u043e, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Komarevo, Pleven'}, '3596357':{'bg': u('\u042f\u0441\u0435\u043d, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Yasen, Pleven'}, '359631':{'bg': u('\u0421\u0432\u0438\u0449\u043e\u0432'), 'en': 'Svishtov'}, '39079':{'en': 'Sassari', 'it': 'Sassari'}, '3752339':{'be': u('\u0420\u0430\u0433\u0430\u0447\u043e\u045e'), 'en': 'Rogachev', 'ru': u('\u0420\u043e\u0433\u0430\u0447\u0435\u0432')}, '37425251':{'am': u('\u0554\u0578\u0582\u0579\u0561\u056f'), 'en': 'Kuchak', 'ru': u('\u041a\u0443\u0447\u0430\u043a')}, '3752334':{'be': u('\u0416\u043b\u043e\u0431\u0456\u043d'), 'en': 'Zhlobin', 'ru': u('\u0416\u043b\u043e\u0431\u0438\u043d')}, '3752336':{'be': u('\u0411\u0443\u0434\u0430-\u041a\u0430\u0448\u0430\u043b\u0451\u0432\u0430, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Budo-Koshelevo, Gomel Region', 'ru': u('\u0411\u0443\u0434\u0430-\u041a\u043e\u0448\u0435\u043b\u0435\u0432\u043e, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752337':{'be': u('\u041a\u0430\u0440\u043c\u0430, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Korma, Gomel Region', 'ru': u('\u041a\u043e\u0440\u043c\u0430, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752330':{'be': u('\u0412\u0435\u0442\u043a\u0430, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Vetka, Gomel Region', 'ru': u('\u0412\u0435\u0442\u043a\u0430, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752332':{'be': u('\u0427\u0430\u0447\u044d\u0440\u0441\u043a, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Chechersk, Gomel Region', 'ru': u('\u0427\u0435\u0447\u0435\u0440\u0441\u043a, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752333':{'be': u('\u0414\u043e\u0431\u0440\u0443\u0448, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Dobrush, Gomel Region', 'ru': u('\u0414\u043e\u0431\u0440\u0443\u0448, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3349082':{'en': 'Avignon', 'fr': 'Avignon'}, '3349083':{'en': 'Sorgues', 'fr': 'Sorgues'}, '3593328':{'bg': u('\u0414\u043e\u043b\u043d\u043e\u0441\u043b\u0430\u0432'), 'en': 'Dolnoslav'}, '3349081':{'en': 'Avignon', 'fr': 'Avignon'}, '3349086':{'en': 'Avignon', 'fr': 'Avignon'}, '3349087':{'en': 'Avignon', 'fr': 'Avignon'}, '3349084':{'en': 'Avignon', 'fr': 'Avignon'}, '3349085':{'en': 'Avignon', 'fr': 'Avignon'}, '3593322':{'bg': u('\u0417\u043b\u0430\u0442\u043e\u0432\u0440\u044a\u0445'), 'en': 'Zlatovrah'}, '3593323':{'bg': u('\u0411\u043e\u043b\u044f\u0440\u0446\u0438, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Bolyartsi, Plovdiv'}, '3349088':{'en': 'Avignon', 'fr': 'Avignon'}, '3349089':{'en': 'Avignon', 'fr': 'Avignon'}, '3593326':{'bg': u('\u041f\u0430\u0442\u0440\u0438\u0430\u0440\u0445 \u0415\u0432\u0442\u0438\u043c\u043e\u0432\u043e'), 'en': 'Patriarh Evtimovo'}, '3593327':{'bg': u('\u0411\u0430\u0447\u043a\u043e\u0432\u043e'), 'en': 'Bachkovo'}, '3593324':{'bg': u('\u0418\u0437\u0431\u0435\u0433\u043b\u0438\u0438'), 'en': 'Izbeglii'}, '3593325':{'bg': u('\u0427\u0435\u0440\u0432\u0435\u043d, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Cherven, Plovdiv'}, '390743':{'it': 'Spoleto'}, '3322808':{'en': 'Nantes', 'fr': 'Nantes'}, '441451':{'en': 'Stow-on-the-Wold'}, '3322803':{'en': 'Saint-Herblain', 'fr': 'Saint-Herblain'}, '3322802':{'en': 'Vigneux-de-Bretagne', 'fr': 'Vigneux-de-Bretagne'}, '3329789':{'en': 'Lanester', 'fr': 'Lanester'}, '3329788':{'en': 'Lorient', 'fr': 'Lorient'}, '3354071':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3329786':{'en': 'Ploemeur', 'fr': 'Ploemeur'}, '3329785':{'en': 'Hennebont', 'fr': 'Hennebont'}, '3329784':{'en': 'Lorient', 'fr': 'Lorient'}, '3329783':{'en': 'Lorient', 'fr': 'Lorient'}, '3329782':{'en': 'Ploemeur', 'fr': 'Ploemeur'}, '3329781':{'en': 'Lanester', 'fr': 'Lanester'}, '3329780':{'en': u('Qu\u00e9ven'), 'fr': u('Qu\u00e9ven')}, '390742':{'it': 'Foligno'}, '3329845':{'en': 'Brest', 'fr': 'Brest'}, '3323319':{'en': 'Coutances', 'fr': 'Coutances'}, '3355380':{'en': u('Montpon-M\u00e9nest\u00e9rol'), 'fr': u('Montpon-M\u00e9nest\u00e9rol')}, '3323317':{'en': 'Coutances', 'fr': 'Coutances'}, '3323312':{'en': 'Argentan', 'fr': 'Argentan'}, '3323310':{'en': 'Cherbourg-Octeville', 'fr': 'Cherbourg-Octeville'}, '3349268':{'en': 'Peyruis', 'fr': 'Peyruis'}, '3349267':{'en': 'Serres', 'fr': 'Serres'}, '3349264':{'en': u('Ch\u00e2teau-Arnoux-Saint-Auban'), 'fr': u('Ch\u00e2teau-Arnoux-Saint-Auban')}, '3349265':{'en': u('Laragne-Mont\u00e9glin'), 'fr': u('Laragne-Mont\u00e9glin')}, '3349260':{'en': 'Grasse', 'fr': 'Grasse'}, '3349261':{'en': 'Sisteron', 'fr': 'Sisteron'}, '441852':{'en': 'Kilmelford'}, '441856':{'en': 'Orkney'}, '441857':{'en': 'Sanday'}, '441854':{'en': 'Ullapool'}, '441855':{'en': 'Ballachulish'}, '441858':{'en': 'Market Harborough'}, '441859':{'en': 'Harris'}, '3593588':{'bg': u('\u041c\u0435\u043d\u0435\u043d\u043a\u044c\u043e\u0432\u043e'), 'en': 'Menenkyovo'}, '3593589':{'bg': u('\u0426\u0435\u0440\u043e\u0432\u043e, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Tserovo, Pazardzhik'}, '3593586':{'bg': u('\u0411\u043e\u0440\u0438\u043c\u0435\u0447\u043a\u043e\u0432\u043e'), 'en': 'Borimechkovo'}, '3593587':{'bg': u('\u0421\u0435\u0441\u0442\u0440\u0438\u043c\u043e'), 'en': 'Sestrimo'}, '3593584':{'bg': u('\u0412\u0435\u0442\u0440\u0435\u043d, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Vetren, Pazardzhik'}, '3593585':{'bg': u('\u0410\u043a\u0430\u043d\u0434\u0436\u0438\u0435\u0432\u043e'), 'en': 'Akandzhievo'}, '3593582':{'bg': u('\u041c\u043e\u043c\u0438\u043d\u0430 \u043a\u043b\u0438\u0441\u0443\u0440\u0430'), 'en': 'Momina klisura'}, '3593583':{'bg': u('\u0413\u0430\u0431\u0440\u043e\u0432\u0438\u0446\u0430'), 'en': 'Gabrovitsa'}, '3593581':{'bg': u('\u0411\u0435\u043b\u043e\u0432\u043e'), 'en': 'Belovo'}, '432865':{'de': 'Litschau', 'en': 'Litschau'}, '432864':{'de': 'Kautzen', 'en': 'Kautzen'}, '432863':{'de': 'Eggern', 'en': 'Eggern'}, '432862':{'de': 'Heidenreichstein', 'en': 'Heidenreichstein'}, '37243':{'en': 'Viljandi'}, '37245':{'en': 'Kuressaare'}, '37244':{'en': u('P\u00e4rnu')}, '37247':{'en': 'Haapsalu'}, '3317028':{'en': 'Boulogne-Billancourt', 'fr': 'Boulogne-Billancourt'}, '37248':{'en': 'Rapla'}, '3355656':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355657':{'en': 'Eysines', 'fr': 'Eysines'}, '3355654':{'en': 'La Teste de Buch', 'fr': 'La Teste de Buch'}, '3355655':{'en': 'Merignac', 'fr': u('M\u00e9rignac')}, '3355652':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355650':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355651':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '433358':{'de': 'Litzelsdorf', 'en': 'Litzelsdorf'}, '3355659':{'en': 'Pauillac', 'fr': 'Pauillac'}, '3332822':{'en': 'Bourbourg', 'fr': 'Bourbourg'}, '3332823':{'en': 'Gravelines', 'fr': 'Gravelines'}, '3332820':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '3332821':{'en': 'Grande-Synthe', 'fr': 'Grande-Synthe'}, '3332826':{'en': u('T\u00e9teghem'), 'fr': u('T\u00e9teghem')}, '3332352':{'en': 'Chauny', 'fr': 'Chauny'}, '3332353':{'en': 'Soissons', 'fr': 'Soissons'}, '3332828':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '3332829':{'en': 'Dunkirk', 'fr': 'Dunkerque'}, '3332358':{'en': 'Hirson', 'fr': 'Hirson'}, '3332359':{'en': 'Soissons', 'fr': 'Soissons'}, '3354927':{'en': 'Melle', 'fr': 'Melle'}, '3354926':{'en': u('Mauz\u00e9-sur-le-Mignon'), 'fr': u('Mauz\u00e9-sur-le-Mignon')}, '3359093':{'en': u('Pointe-\u00e0-Pitre'), 'fr': u('Pointe-\u00e0-Pitre')}, '3354924':{'en': 'Niort', 'fr': 'Niort'}, '3354923':{'en': u('Ch\u00e2tellerault'), 'fr': u('Ch\u00e2tellerault')}, '3594586':{'bg': u('\u041d\u0435\u0439\u043a\u043e\u0432\u043e, \u0421\u043b\u0438\u0432\u0435\u043d'), 'en': 'Neykovo, Sliven'}, '3354921':{'en': u('Ch\u00e2tellerault'), 'fr': u('Ch\u00e2tellerault')}, '3354920':{'en': u('Ch\u00e2tellerault'), 'fr': u('Ch\u00e2tellerault')}, '3594588':{'bg': u('\u0424\u0438\u043b\u0430\u0440\u0435\u0442\u043e\u0432\u043e'), 'en': 'Filaretovo'}, '3354928':{'en': 'Niort', 'fr': 'Niort'}, '3593743':{'bg': u('\u0421\u0438\u043b\u0435\u043d'), 'en': 'Silen'}, '3593695':{'bg': u('\u041a\u043e\u043c\u0443\u043d\u0438\u0433\u0430'), 'en': 'Komuniga'}, '432755':{'de': 'Mank', 'en': 'Mank'}, '435333':{'de': u('S\u00f6ll'), 'en': u('S\u00f6ll')}, '3593746':{'bg': u('\u0421\u0438\u0440\u0430\u043a\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Sirakovo, Hask.'}, '435334':{'de': 'Westendorf', 'en': 'Westendorf'}, '435335':{'de': 'Hopfgarten im Brixental', 'en': 'Hopfgarten im Brixental'}, '3324723':{'en': 'Amboise', 'fr': 'Amboise'}, '432754':{'de': 'Loosdorf', 'en': 'Loosdorf'}, '3324721':{'en': 'Tours', 'fr': 'Tours'}, '359953':{'bg': u('\u0411\u0435\u0440\u043a\u043e\u0432\u0438\u0446\u0430'), 'en': 'Berkovitsa'}, '3324725':{'en': u('Chambray-l\u00e8s-Tours'), 'fr': u('Chambray-l\u00e8s-Tours')}, '38138':{'en': 'Pristina', 'sr': u('Pri\u0161tina')}, '38139':{'en': 'Pec', 'sr': u('Pe\u0107')}, '38132':{'en': 'Cacak', 'sr': u('\u010ca\u010dak')}, '38133':{'en': 'Prijepolje', 'sr': 'Prijepolje'}, '38130':{'en': 'Bor', 'sr': 'Bor'}, '38131':{'en': 'Uzice', 'sr': u('U\u017eice')}, '38136':{'en': 'Kraljevo', 'sr': 'Kraljevo'}, '38137':{'en': 'Krusevac', 'sr': u('Kru\u0161evac')}, '38134':{'en': 'Kragujevac', 'sr': 'Kragujevac'}, '38135':{'en': 'Jagodina', 'sr': 'Jagodina'}, '432752':{'de': 'Melk', 'en': 'Melk'}, '3598699':{'bg': u('\u0422\u044a\u0440\u043d\u043e\u0432\u0446\u0438, \u0421\u0438\u043b\u0438\u0441\u0442\u0440\u0430'), 'en': 'Tarnovtsi, Silistra'}, '35995277':{'bg': u('\u0427\u0435\u0440\u043a\u0430\u0441\u043a\u0438'), 'en': 'Cherkaski'}, '3598698':{'bg': u('\u0428\u0443\u043c\u0435\u043d\u0446\u0438'), 'en': 'Shumentsi'}, '3325345':{'en': 'Nantes', 'fr': 'Nantes'}, '435673':{'de': 'Ehrwald', 'en': 'Ehrwald'}, '435672':{'de': 'Reutte', 'en': 'Reutte'}, '435675':{'de': 'Tannheim', 'en': 'Tannheim'}, '435674':{'de': 'Bichlbach', 'en': 'Bichlbach'}, '435677':{'de': 'Vils', 'en': 'Vils'}, '435676':{'de': 'Jungholz', 'en': 'Jungholz'}, '435678':{'de': u('Wei\u00dfenbach am Lech'), 'en': 'Weissenbach am Lech'}, '3599188':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u041f\u0435\u0449\u0435\u043d\u0435'), 'en': 'Gorno Peshtene'}, '3599189':{'bg': u('\u041f\u0430\u0432\u043e\u043b\u0447\u0435'), 'en': 'Pavolche'}, '3329801':{'en': 'Brest', 'fr': 'Brest'}, '3599184':{'bg': u('\u041e\u0445\u043e\u0434\u0435\u043d'), 'en': 'Ohoden'}, '3599185':{'bg': u('\u0411\u0435\u043b\u0438 \u0418\u0437\u0432\u043e\u0440'), 'en': 'Beli Izvor'}, '3599186':{'bg': u('\u0417\u0433\u043e\u0440\u0438\u0433\u0440\u0430\u0434'), 'en': 'Zgorigrad'}, '3599187':{'bg': u('\u041b\u044e\u0442\u0430\u0434\u0436\u0438\u043a'), 'en': 'Lyutadzhik'}, '3599180':{'bg': u('\u0413\u043e\u043b\u044f\u043c\u043e \u041f\u0435\u0449\u0435\u043d\u0435'), 'en': 'Golyamo Peshtene'}, '3599181':{'bg': u('\u041a\u0440\u0430\u0432\u043e\u0434\u0435\u0440'), 'en': 'Kravoder'}, '3599182':{'bg': u('\u0414\u0435\u0432\u0435\u043d\u0435'), 'en': 'Devene'}, '3599183':{'bg': u('\u041b\u0438\u043b\u044f\u0447\u0435'), 'en': 'Lilyache'}, '3329803':{'en': 'Brest', 'fr': 'Brest'}, '3329804':{'en': 'Lannilis', 'fr': 'Lannilis'}, '3329805':{'en': 'Brest', 'fr': 'Brest'}, '3323453':{'en': 'Tours', 'fr': 'Tours'}, '3329807':{'en': 'Guilers', 'fr': 'Guilers'}, '3596985':{'bg': u('\u0420\u0443\u043c\u044f\u043d\u0446\u0435\u0432\u043e'), 'en': 'Rumyantsevo'}, '3596984':{'bg': u('\u0411\u0435\u0436\u0430\u043d\u043e\u0432\u043e, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Bezhanovo, Lovech'}, '3596987':{'bg': u('\u041a\u0430\u0440\u043b\u0443\u043a\u043e\u0432\u043e'), 'en': 'Karlukovo'}, '3596986':{'bg': u('\u0414\u044a\u0431\u0435\u043d'), 'en': 'Daben'}, '3596981':{'bg': u('\u041f\u0435\u0442\u0440\u0435\u0432\u0435\u043d\u0435'), 'en': 'Petrevene'}, '3596980':{'bg': u('\u0411\u0435\u043b\u0435\u043d\u0446\u0438'), 'en': 'Belentsi'}, '3596983':{'bg': u('\u0414\u0435\u0440\u043c\u0430\u043d\u0446\u0438'), 'en': 'Dermantsi'}, '3355666':{'en': 'Gujan-Mestras', 'fr': 'Gujan-Mestras'}, '355514':{'en': 'Librazhd'}, '355513':{'en': 'Gramsh'}, '355512':{'en': 'Peqin'}, '355511':{'en': 'Kruje'}, '3355911':{'en': 'Pau', 'fr': 'Pau'}, '3347839':{'en': 'Lyon', 'fr': 'Lyon'}, '3347838':{'en': 'Lyon', 'fr': 'Lyon'}, '3595726':{'bg': u('\u0426\u0430\u0440\u0438\u0447\u0438\u043d\u043e'), 'en': 'Tsarichino'}, '3595727':{'bg': u('\u0421\u0435\u043d\u043e\u043a\u043e\u0441, \u0414\u043e\u0431\u0440.'), 'en': 'Senokos, Dobr.'}, '3349333':{'en': 'Antibes Juan les Pins', 'fr': 'Antibes Juan les Pins'}, '3595723':{'bg': u('\u0413\u0443\u0440\u043a\u043e\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'Gurkovo, Dobr.'}, '3347831':{'en': 'Meyzieu', 'fr': 'Meyzieu'}, '3347830':{'en': 'Lyon', 'fr': 'Lyon'}, '3347833':{'en': u('\u00c9cully'), 'fr': u('\u00c9cully')}, '3355912':{'en': 'Serres-Castet', 'fr': 'Serres-Castet'}, '3347835':{'en': 'Champagne-au-Mont-d\'Or', 'fr': 'Champagne-au-Mont-d\'Or'}, '3347834':{'en': 'Tassin-la-Demi-Lune', 'fr': 'Tassin-la-Demi-Lune'}, '3347837':{'en': 'Lyon', 'fr': 'Lyon'}, '3347836':{'en': 'Lyon', 'fr': 'Lyon'}, '355863':{'en': u('Drenov\u00eb/Mollaj, Kor\u00e7\u00eb')}, '355862':{'en': u('Qend\u00ebr, Kor\u00e7\u00eb')}, '355861':{'en': u('Maliq, Kor\u00e7\u00eb')}, '3349706':{'en': 'Cannes', 'fr': 'Cannes'}, '40248':{'en': u('Arge\u0219'), 'ro': u('Arge\u0219')}, '355867':{'en': u('Pojan/Liqenas, Kor\u00e7\u00eb')}, '3349700':{'en': 'Nice', 'fr': 'Nice'}, '355865':{'en': u('Gor\u00eb/Pirg/Moglic\u00eb, Kor\u00e7\u00eb')}, '355864':{'en': u('Voskop/Voskopoj\u00eb/Vithkuq/Lekas, Kor\u00e7\u00eb')}, '3596176':{'bg': u('\u041f\u043e\u043b\u0438\u043a\u0440\u0430\u0438\u0449\u0435'), 'en': 'Polikraishte'}, '432758':{'de': u('P\u00f6ggstall'), 'en': u('P\u00f6ggstall')}, '35961402':{'bg': u('\u0421\u0442\u0435\u0444\u0430\u043d \u0421\u0442\u0430\u043c\u0431\u043e\u043b\u043e\u0432\u043e'), 'en': 'Stefan Stambolovo'}, '35961403':{'bg': u('\u041e\u0440\u043b\u043e\u0432\u0435\u0446'), 'en': 'Orlovets'}, '35961406':{'bg': u('\u041a\u0430\u0440\u0430\u043d\u0446\u0438'), 'en': 'Karantsi'}, '35961405':{'bg': u('\u041f\u0435\u0442\u043a\u043e \u041a\u0430\u0440\u0430\u0432\u0435\u043b\u043e\u0432\u043e'), 'en': 'Petko Karavelovo'}, '3348612':{'en': 'Marseille', 'fr': 'Marseille'}, '3346872':{'en': 'Carcassonne', 'fr': 'Carcassonne'}, '3346873':{'en': 'Canet-en-Roussillon', 'fr': 'Canet-en-Roussillon'}, '3346871':{'en': 'Carcassonne', 'fr': 'Carcassonne'}, '3346876':{'en': 'Bram', 'fr': 'Bram'}, '3346877':{'en': 'Carcassonne', 'fr': 'Carcassonne'}, '3346875':{'en': 'Narbonne', 'fr': 'Narbonne'}, '3346878':{'en': u('Tr\u00e8bes'), 'fr': u('Tr\u00e8bes')}, '3596178':{'bg': u('\u0421\u0442\u0440\u0435\u043b\u0435\u0446, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Strelets, V. Tarnovo'}, '3596179':{'bg': u('\u041a\u0440\u0443\u0448\u0435\u0442\u043e'), 'en': 'Krusheto'}, '442868':{'en': 'Kesh'}, '442866':{'en': 'Enniskillen'}, '442867':{'en': 'Lisnaskea'}, '3348929':{'en': 'Toulon', 'fr': 'Toulon'}, '3348924':{'en': 'Nice', 'fr': 'Nice'}, '3348922':{'en': 'Nice', 'fr': 'Nice'}, '3323766':{'en': u('Ch\u00e2teaudun'), 'fr': u('Ch\u00e2teaudun')}, '3323765':{'en': 'Tremblay-les-Villages', 'fr': 'Tremblay-les-Villages'}, '3323764':{'en': u('\u00c9zy-sur-Eure'), 'fr': u('\u00c9zy-sur-Eure')}, '35930457':{'bg': u('\u041a\u044a\u0441\u0430\u043a'), 'en': 'Kasak'}, '35930456':{'bg': u('\u0427\u0430\u0432\u0434\u0430\u0440, \u0421\u043c\u043e\u043b.'), 'en': 'Chavdar, Smol.'}, '34879':{'en': 'Palencia', 'es': 'Palencia'}, '34878':{'en': 'Teruel', 'es': 'Teruel'}, '34872':{'en': 'Gerona', 'es': 'Gerona'}, '34876':{'en': 'Zaragoza', 'es': 'Zaragoza'}, '35930459':{'bg': u('\u0411\u0440\u044a\u0449\u0435\u043d'), 'en': 'Brashten'}, '35930458':{'bg': u('\u041b\u044e\u0431\u0447\u0430'), 'en': 'Lyubcha'}, '3332109':{'en': 'Berck sur Mer', 'fr': 'Berck sur Mer'}, '44161':{'en': 'Manchester'}, '3332101':{'en': u('B\u00e9thune'), 'fr': u('B\u00e9thune')}, '3332100':{'en': 'Calais', 'fr': 'Calais'}, '3332103':{'en': 'Saint-Pol-sur-Ternoise', 'fr': 'Saint-Pol-sur-Ternoise'}, '3332105':{'en': 'Le Touquet Paris Plage', 'fr': 'Le Touquet Paris Plage'}, '3332106':{'en': 'Montreuil', 'fr': 'Montreuil'}, '3325422':{'en': u('Ch\u00e2teauroux'), 'fr': u('Ch\u00e2teauroux')}, '3325421':{'en': 'Issoudun', 'fr': 'Issoudun'}, '3325426':{'en': 'Villedieu-sur-Indre', 'fr': 'Villedieu-sur-Indre'}, '3325427':{'en': u('Ch\u00e2teauroux'), 'fr': u('Ch\u00e2teauroux')}, '3325424':{'en': 'Argenton-sur-Creuse', 'fr': 'Argenton-sur-Creuse'}, '433325':{'de': 'Heiligenkreuz im Lafnitztal', 'en': 'Heiligenkreuz im Lafnitztal'}, '433324':{'de': 'Strem', 'en': 'Strem'}, '3325428':{'en': 'Le Blanc', 'fr': 'Le Blanc'}, '3325429':{'en': 'Niherne', 'fr': 'Niherne'}, '433323':{'de': 'Eberau', 'en': 'Eberau'}, '433322':{'de': u('G\u00fcssing'), 'en': u('G\u00fcssing')}, '441501':{'en': 'Harthill'}, '3349521':{'en': 'Ajaccio', 'fr': 'Ajaccio'}, '3349520':{'en': 'Ajaccio', 'fr': 'Ajaccio'}, '3349523':{'en': 'Ajaccio', 'fr': 'Ajaccio'}, '3349522':{'en': 'Ajaccio', 'fr': 'Ajaccio'}, '3349525':{'en': 'Grosseto-Prugna', 'fr': 'Grosseto-Prugna'}, '3349527':{'en': 'Piana', 'fr': 'Piana'}, '3349526':{'en': u('Carg\u00e8se'), 'fr': u('Carg\u00e8se')}, '3349528':{'en': 'Sagone', 'fr': 'Sagone'}, '433149':{'de': 'Geistthal', 'en': 'Geistthal'}, '3596923':{'bg': u('\u0413\u043e\u0440\u0430\u043d'), 'en': 'Goran'}, '3596922':{'bg': u('\u041b\u0435\u0448\u043d\u0438\u0446\u0430, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Leshnitsa, Lovech'}, '433141':{'de': 'Hirschegg', 'en': 'Hirschegg'}, '433140':{'de': u('Sankt Martin am W\u00f6llmi\u00dfberg'), 'en': u('St. Martin am W\u00f6llmissberg')}, '433143':{'de': 'Krottendorf', 'en': 'Krottendorf'}, '433142':{'de': 'Voitsberg', 'en': 'Voitsberg'}, '433145':{'de': 'Edelschrott', 'en': 'Edelschrott'}, '433144':{'de': u('K\u00f6flach'), 'en': u('K\u00f6flach')}, '433147':{'de': 'Salla', 'en': 'Salla'}, '433146':{'de': 'Modriach', 'en': 'Modriach'}, '3596920':{'bg': u('\u041b\u0435\u0441\u0438\u0434\u0440\u0435\u043d'), 'en': 'Lesidren'}, '3596927':{'bg': u('\u0423\u043c\u0430\u0440\u0435\u0432\u0446\u0438'), 'en': 'Umarevtsi'}, '3596926':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u041f\u0430\u0432\u043b\u0438\u043a\u0435\u043d\u0435'), 'en': 'Gorno Pavlikene'}, '3596925':{'bg': u('\u0412\u043b\u0430\u0434\u0438\u043d\u044f'), 'en': 'Vladinya'}, '3594118':{'bg': u('\u041f\u0430\u043c\u0443\u043a\u0447\u0438\u0438, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Pamukchii, St. Zagora'}, '3594115':{'bg': u('\u041a\u0438\u0440\u0438\u043b\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Kirilovo, St. Zagora'}, '3594116':{'bg': u('\u0420\u0430\u043a\u0438\u0442\u043d\u0438\u0446\u0430, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Rakitnitsa, St. Zagora'}, '37423572':{'am': u('\u0531\u0580\u0587\u0577\u0561\u057f'), 'en': 'Arevshat', 'ru': u('\u0410\u0440\u0435\u0432\u0448\u0430\u0442')}, '3323357':{'en': u('Saint-L\u00f4'), 'fr': u('Saint-L\u00f4')}, '3594112':{'bg': u('\u0411\u044a\u0434\u0435\u0449\u0435'), 'en': 'Badeshte'}, '3594113':{'bg': u('\u041f\u0440\u0435\u0441\u043b\u0430\u0432\u0435\u043d'), 'en': 'Preslaven'}, '3595539':{'bg': u('\u0427\u0435\u0440\u043d\u043e\u0433\u0440\u0430\u0434'), 'en': 'Chernograd'}, '3595538':{'bg': u('\u041a\u0430\u0440\u0430\u043d\u043e\u0432\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Karanovo, Burgas'}, '441689':{'en': 'Orpington'}, '3596928':{'bg': u('\u041a\u044a\u043a\u0440\u0438\u043d\u0430'), 'en': 'Kakrina'}, '441683':{'en': 'Moffat'}, '3595530':{'bg': u('\u041f\u0435\u0449\u0435\u0440\u0441\u043a\u043e'), 'en': 'Peshtersko'}, '3595533':{'bg': u('\u041f\u0438\u0440\u043d\u0435'), 'en': 'Pirne'}, '3595532':{'bg': u('\u0422\u043e\u043f\u043e\u043b\u0438\u0446\u0430'), 'en': 'Topolitsa'}, '3595535':{'bg': u('\u041b\u044f\u0441\u043a\u043e\u0432\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Lyaskovo, Burgas'}, '3595534':{'bg': u('\u041a\u0430\u0440\u0430\u0433\u0435\u043e\u0440\u0433\u0438\u0435\u0432\u043e'), 'en': 'Karageorgievo'}, '3595537':{'bg': u('\u0421\u044a\u0434\u0438\u0435\u0432\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Sadievo, Burgas'}, '3595536':{'bg': u('\u041c\u044a\u0433\u043b\u0435\u043d'), 'en': 'Maglen'}, '3324771':{'en': u('Chambray-l\u00e8s-Tours'), 'fr': u('Chambray-l\u00e8s-Tours')}, '3324770':{'en': 'Tours', 'fr': 'Tours'}, '3324773':{'en': u('Jou\u00e9-l\u00e8s-Tours'), 'fr': u('Jou\u00e9-l\u00e8s-Tours')}, '3324775':{'en': 'Tours', 'fr': 'Tours'}, '3324774':{'en': 'Saint-Avertin', 'fr': 'Saint-Avertin'}, '3338259':{'en': 'Thionville', 'fr': 'Thionville'}, '3324776':{'en': 'Tours', 'fr': 'Tours'}, '3338257':{'en': 'Florange', 'fr': 'Florange'}, '3338256':{'en': 'Yutz', 'fr': 'Yutz'}, '3338255':{'en': 'Cattenom', 'fr': 'Cattenom'}, '3338254':{'en': 'Thionville', 'fr': 'Thionville'}, '3338253':{'en': 'Thionville', 'fr': 'Thionville'}, '3338252':{'en': 'Audun-le-Tiche', 'fr': 'Audun-le-Tiche'}, '3338251':{'en': 'Thionville', 'fr': 'Thionville'}, '3598117':{'bg': u('\u041c\u0430\u0440\u0442\u0435\u043d'), 'en': 'Marten'}, '35952':{'bg': u('\u0412\u0430\u0440\u043d\u0430'), 'en': 'Varna'}, '3597152':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u041c\u0430\u043b\u0438\u043d\u0430'), 'en': 'Gorna Malina'}, '35954':{'bg': u('\u0428\u0443\u043c\u0435\u043d'), 'en': 'Shumen'}, '35984469':{'bg': u('\u0411\u043e\u0436\u0443\u0440\u043e\u0432\u043e, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Bozhurovo, Razgrad'}, '4413889':{'en': 'Bishop Auckland'}, '4413888':{'en': 'Bishop Auckland'}, '4413887':{'en': 'Bishop Auckland'}, '3594334':{'bg': u('\u0415\u043b\u0445\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430, \u043e\u0431\u0449. \u041d\u0438\u043a\u043e\u043b\u0430\u0435\u0432\u043e'), 'en': 'Elhovo, St. Zagora, mun. Nikolaevo'}, '35984463':{'bg': u('\u041f\u0440\u0435\u043b\u0435\u0437'), 'en': 'Prelez'}, '331800':{'en': 'Paris', 'fr': 'Paris'}, '35984465':{'bg': u('\u0421\u0430\u0432\u0438\u043d'), 'en': 'Savin'}, '35984464':{'bg': u('\u0412\u0435\u0441\u0435\u043b\u0435\u0446, \u0420\u0430\u0437\u0433\u0440\u0430\u0434'), 'en': 'Veselets, Razgrad'}, '331805':{'en': 'Paris', 'fr': 'Paris'}, '35984466':{'bg': u('\u0417\u0432\u044a\u043d\u0430\u0440\u0446\u0438'), 'en': 'Zvanartsi'}, '390881':{'en': 'Foggia', 'it': 'Foggia'}, '4131':{'de': 'Bern', 'en': 'Berne', 'fr': 'Berne', 'it': 'Berna'}, '4132':{'de': 'Biel/Neuenburg/Solothurn/Jura', 'en': u('Bienne/Neuch\u00e2tel/Soleure/Jura'), 'fr': u('Bienne/Neuch\u00e2tel/Soleure/Jura'), 'it': u('Bienne/Neuch\u00e2tel/Soletta/Giura')}, '4133':{'de': 'Thun', 'en': 'Thun', 'fr': 'Thoune', 'it': 'Thun'}, '4134':{'de': 'Burgdorf/Langnau i.E.', 'en': 'Burgdorf/Langnau i.E.', 'fr': 'Burgdorf/Langnau i.E.', 'it': 'Burgdorf/Langnau i.E.'}, '441271':{'en': 'Barnstaple'}, '3596039':{'bg': u('\u041e\u043f\u0430\u043a\u0430'), 'en': 'Opaka'}, '441323':{'en': 'Eastbourne'}, '441967':{'en': 'Strontian'}, '35524':{'en': u('Kuk\u00ebs')}, '3323358':{'en': 'Avranches', 'fr': 'Avranches'}, '35522':{'en': u('Shkod\u00ebr')}, '35221':{'de': 'Weicherdingen', 'fr': 'Weicherdange'}, '441279':{'en': 'Bishops Stortford'}, '4416861':{'en': 'Newtown/Llanidloes'}, '3593138':{'bg': u('\u0412\u0435\u0434\u0440\u0430\u0440\u0435'), 'en': 'Vedrare'}, '3336907':{'en': 'Mulhouse', 'fr': 'Mulhouse'}, '3596035':{'bg': u('\u041f\u0430\u043b\u0430\u043c\u0430\u0440\u0446\u0430'), 'en': 'Palamartsa'}, '3596034':{'bg': u('\u0421\u043b\u0430\u0432\u044f\u043d\u043e\u0432\u043e, \u0422\u044a\u0440\u0433.'), 'en': 'Slavyanovo, Targ.'}, '359610':{'bg': u('\u041f\u0430\u0432\u043b\u0438\u043a\u0435\u043d\u0438, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Pavlikeni, V. Tarnovo'}, '359615':{'bg': u('\u0417\u043b\u0430\u0442\u0430\u0440\u0438\u0446\u0430'), 'en': 'Zlataritsa'}, '359618':{'bg': u('\u0413\u043e\u0440\u043d\u0430 \u041e\u0440\u044f\u0445\u043e\u0432\u0438\u0446\u0430'), 'en': 'Gorna Oryahovitsa'}, '359619':{'bg': u('\u041b\u044f\u0441\u043a\u043e\u0432\u0435\u0446, \u0412. \u0422\u044a\u0440\u043d\u043e\u0432\u043e'), 'en': 'Lyaskovets, V. Tarnovo'}, '46159':{'en': 'Mariefred', 'sv': 'Mariefred'}, '46158':{'en': 'Gnesta', 'sv': 'Gnesta'}, '46155':{'en': u('Nyk\u00f6ping-Oxel\u00f6sund'), 'sv': u('Nyk\u00f6ping-Oxel\u00f6sund')}, '46157':{'en': u('Flen-Malmk\u00f6ping'), 'sv': u('Flen-Malmk\u00f6ping')}, '46156':{'en': u('Trosa-Vagnh\u00e4rad'), 'sv': u('Trosa-Vagnh\u00e4rad')}, '46151':{'en': u('Ving\u00e5ker'), 'sv': u('Ving\u00e5ker')}, '46150':{'en': 'Katrineholm', 'sv': 'Katrineholm'}, '46152':{'en': u('Str\u00e4ngn\u00e4s'), 'sv': u('Str\u00e4ngn\u00e4s')}, '3323154':{'en': u('H\u00e9rouville-Saint-Clair'), 'fr': u('H\u00e9rouville-Saint-Clair')}, '3323150':{'en': 'Caen', 'fr': 'Caen'}, '3323151':{'en': 'Bayeux', 'fr': 'Bayeux'}, '3323152':{'en': 'Caen', 'fr': 'Caen'}, '3323153':{'en': 'Caen', 'fr': 'Caen'}, '3349068':{'en': 'Cadenet', 'fr': 'Cadenet'}, '3349069':{'en': 'Mazan', 'fr': 'Mazan'}, '3349064':{'en': 'Sault', 'fr': 'Sault'}, '3349065':{'en': 'Sarrians', 'fr': 'Sarrians'}, '3349066':{'en': 'Monteux', 'fr': 'Monteux'}, '3349067':{'en': 'Carpentras', 'fr': 'Carpentras'}, '3349060':{'en': 'Carpentras', 'fr': 'Carpentras'}, '3349061':{'en': 'Pernes-les-Fontaines', 'fr': 'Pernes-les-Fontaines'}, '3349062':{'en': 'Caromb', 'fr': 'Caromb'}, '3349063':{'en': 'Carpentras', 'fr': 'Carpentras'}, '3323378':{'en': 'Cherbourg-Octeville', 'fr': 'Cherbourg-Octeville'}, '3323379':{'en': 'Avranches', 'fr': 'Avranches'}, '3324059':{'en': 'Nantes', 'fr': 'Nantes'}, '3323371':{'en': 'Carentan', 'fr': 'Carentan'}, '3323372':{'en': u('Saint-L\u00f4'), 'fr': u('Saint-L\u00f4')}, '3323376':{'en': 'Coutances', 'fr': 'Coutances'}, '3323377':{'en': u('Saint-L\u00f4'), 'fr': u('Saint-L\u00f4')}, '3349208':{'en': 'Carros', 'fr': 'Carros'}, '3349209':{'en': 'Nice', 'fr': 'Nice'}, '3522755':{'de': 'Esch-sur-Alzette/Monnerich', 'en': 'Esch-sur-Alzette/Mondercange', 'fr': 'Esch-sur-Alzette/Mondercange'}, '3522754':{'de': 'Esch-sur-Alzette', 'en': 'Esch-sur-Alzette', 'fr': 'Esch-sur-Alzette'}, '3522753':{'de': 'Esch-sur-Alzette', 'en': 'Esch-sur-Alzette', 'fr': 'Esch-sur-Alzette'}, '3522752':{'de': u('D\u00fcdelingen'), 'en': 'Dudelange', 'fr': 'Dudelange'}, '3522751':{'de': u('D\u00fcdelingen/Bettemburg/Livingen'), 'en': 'Dudelange/Bettembourg/Livange', 'fr': 'Dudelange/Bettembourg/Livange'}, '3522750':{'de': 'Bascharage/Petingen/Rodingen', 'en': 'Bascharage/Petange/Rodange', 'fr': 'Bascharage/Petange/Rodange'}, '3349200':{'en': 'Nice', 'fr': 'Nice'}, '3349202':{'en': 'Cagnes-sur-Mer', 'fr': 'Cagnes-sur-Mer'}, '3349204':{'en': 'Nice', 'fr': 'Nice'}, '3522759':{'de': 'Soleuvre', 'en': 'Soleuvre', 'fr': 'Soleuvre'}, '3349207':{'en': 'Nice', 'fr': 'Nice'}, '441878':{'en': 'Lochboisdale'}, '441879':{'en': 'Scarinish'}, '441308':{'en': 'Bridport'}, '441309':{'en': 'Forres'}, '441306':{'en': 'Dorking'}, '441307':{'en': 'Forfar'}, '441304':{'en': 'Dover'}, '35931620':{'bg': u('\u0414\u043e\u0431\u0440\u0438 \u0434\u043e\u043b, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Dobri dol, Plovdiv'}, '35931627':{'bg': u('\u041a\u0440\u0443\u0448\u0435\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Krushevo, Plovdiv'}, '441303':{'en': 'Folkestone'}, '335614':{'en': 'Toulouse', 'fr': 'Toulouse'}, '441301':{'en': 'Arrochar'}, '3338882':{'en': u('S\u00e9lestat'), 'fr': u('S\u00e9lestat')}, '3338883':{'en': 'Schiltigheim', 'fr': 'Schiltigheim'}, '3338881':{'en': 'Schiltigheim', 'fr': 'Schiltigheim'}, '3338887':{'en': 'Wasselonne', 'fr': 'Wasselonne'}, '3338884':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '381390':{'en': 'Dakovica', 'sr': 'Dakovica'}, '3338889':{'en': 'Ingwiller', 'fr': 'Ingwiller'}, '3324052':{'en': 'Nantes', 'fr': 'Nantes'}, '437355':{'de': 'Weyer', 'en': 'Weyer'}, '432847':{'de': u('Gro\u00df-Siegharts'), 'en': 'Gross-Siegharts'}, '432846':{'de': 'Raabs an der Thaya', 'en': 'Raabs an der Thaya'}, '3332590':{'en': 'Bourbonne-les-Bains', 'fr': 'Bourbonne-les-Bains'}, '432843':{'de': 'Dobersberg', 'en': 'Dobersberg'}, '432842':{'de': 'Waidhofen an der Thaya', 'en': 'Waidhofen an der Thaya'}, '3332594':{'en': 'Joinville', 'fr': 'Joinville'}, '3324054':{'en': 'Clisson', 'fr': 'Clisson'}, '432849':{'de': 'Schwarzenau', 'en': 'Schwarzenau'}, '432848':{'de': 'Pfaffenschlag bei Waidhofen', 'en': 'Pfaffenschlag bei Waidhofen'}, '3324057':{'en': u('H\u00e9ric'), 'fr': u('H\u00e9ric')}, '3317000':{'en': 'Chelles', 'fr': 'Chelles'}, '3355630':{'en': 'Cadaujac', 'fr': 'Cadaujac'}, '3355631':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355632':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355633':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355634':{'en': 'Merignac', 'fr': u('M\u00e9rignac')}, '3355635':{'en': 'Blanquefort', 'fr': 'Blanquefort'}, '3355636':{'en': 'Pessac', 'fr': 'Pessac'}, '3355637':{'en': 'Talence', 'fr': 'Talence'}, '3355638':{'en': u('Ambar\u00e8s-et-Lagrave'), 'fr': u('Ambar\u00e8s-et-Lagrave')}, '3355639':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3322355':{'en': u('Vitr\u00e9'), 'fr': u('Vitr\u00e9')}, '3322351':{'en': u('Foug\u00e8res'), 'fr': u('Foug\u00e8res')}, '3322350':{'en': 'Bruz', 'fr': 'Bruz'}, '3322352':{'en': 'Saint-Malo', 'fr': 'Saint-Malo'}, '3332376':{'en': 'Soissons', 'fr': 'Soissons'}, '3332375':{'en': 'Soissons', 'fr': 'Soissons'}, '3332373':{'en': 'Soissons', 'fr': 'Soissons'}, '4419753':{'en': 'Strathdon'}, '3354901':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354900':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354903':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354902':{'en': u('Ch\u00e2tellerault'), 'fr': u('Ch\u00e2tellerault')}, '3354906':{'en': 'Niort', 'fr': 'Niort'}, '3354909':{'en': 'Niort', 'fr': 'Niort'}, '3354908':{'en': 'Chauray', 'fr': 'Chauray'}, '4419752':{'en': 'Alford (Aberdeen)'}, '3359029':{'en': u('Saint Barth\u00e9l\u00e9my'), 'fr': u('Saint Barth\u00e9l\u00e9my')}, '3359028':{'en': 'Sainte Rose', 'fr': 'Sainte Rose'}, '3598675':{'bg': u('\u0410\u0439\u0434\u0435\u043c\u0438\u0440'), 'en': 'Aydemir'}, '3359021':{'en': u('Pointe-\u00e0-Pitre'), 'fr': u('Pointe-\u00e0-Pitre')}, '3359020':{'en': 'Les Abymes', 'fr': 'Les Abymes'}, '3359023':{'en': 'Le Moule', 'fr': 'Le Moule'}, '3359022':{'en': 'Petit-Canal', 'fr': 'Petit-Canal'}, '3359025':{'en': 'Baie Mahault', 'fr': 'Baie Mahault'}, '3359024':{'en': u('Morne-\u00c0-l\'Eau'), 'fr': u('Morne-\u00c0-l\'Eau')}, '3359027':{'en': u('Saint Barth\u00e9l\u00e9my'), 'fr': u('Saint Barth\u00e9l\u00e9my')}, '3359026':{'en': 'Baie Mahault', 'fr': 'Baie Mahault'}, '3595529':{'bg': u('\u041a\u0440\u0443\u0448\u043e\u0432\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Krushovo, Burgas'}, '35975214':{'bg': u('\u0413\u0430\u0439\u0442\u0430\u043d\u0438\u043d\u043e\u0432\u043e'), 'en': 'Gaytaninovo'}, '35975215':{'bg': u('\u0422\u0435\u0448\u043e\u0432\u043e'), 'en': 'Teshovo'}, '38110':{'en': 'Pirot', 'sr': 'Pirot'}, '38111':{'en': 'Belgrade', 'sr': 'Beograd'}, '38112':{'en': 'Pozarevac', 'sr': u('Po\u017earevac')}, '38113':{'en': 'Pancevo', 'sr': u('Pan\u010devo')}, '38114':{'en': 'Valjevo', 'sr': 'Valjevo'}, '38115':{'en': 'Sabac', 'sr': u('\u0160abac')}, '38116':{'en': 'Leskovac', 'sr': 'Leskovac'}, '38117':{'en': 'Vranje', 'sr': 'Vranje'}, '38118':{'en': 'Nis', 'sr': u('Ni\u0161')}, '38119':{'en': 'Zajecar', 'sr': u('Zaje\u010dar')}, '437280':{'de': u('Schwarzenberg am B\u00f6hmerwald'), 'en': u('Schwarzenberg am B\u00f6hmerwald')}, '3593704':{'bg': u('\u0411\u0440\u044f\u0433\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Bryagovo, Hask.'}, '3593705':{'bg': u('\u0412\u044a\u0433\u043b\u0430\u0440\u043e\u0432\u043e'), 'en': 'Vaglarovo'}, '3593706':{'bg': u('\u0422\u044a\u043d\u043a\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Tankovo, Hask.'}, '3593707':{'bg': u('\u041d\u0438\u043a\u043e\u043b\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Nikolovo, Hask.'}, '3593700':{'bg': u('\u0422\u0440\u0430\u043a\u0438\u0435\u0446'), 'en': 'Trakiets'}, '3593701':{'bg': u('\u0415\u043b\u0435\u043d\u0430, \u0425\u0430\u0441\u043a.'), 'en': 'Elena, Hask.'}, '3593702':{'bg': u('\u0426\u0430\u0440\u0435\u0432\u0430 \u043f\u043e\u043b\u044f\u043d\u0430'), 'en': 'Tsareva polyana'}, '3593703':{'bg': u('\u0416\u044a\u043b\u0442\u0438 \u0431\u0440\u044f\u0433'), 'en': 'Zhalti bryag'}, '437286':{'de': u('Lembach im M\u00fchlkreis'), 'en': u('Lembach im M\u00fchlkreis')}, '3593708':{'bg': u('\u041e\u0440\u043b\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Orlovo, Hask.'}, '3593709':{'bg': u('\u041a\u0430\u0440\u0430\u043c\u0430\u043d\u0446\u0438'), 'en': 'Karamantsi'}, '437287':{'de': u('Peilstein im M\u00fchlviertel'), 'en': u('Peilstein im M\u00fchlviertel')}, '3599348':{'bg': u('\u041d\u0435\u0433\u043e\u0432\u0430\u043d\u043e\u0432\u0446\u0438'), 'en': 'Negovanovtsi'}, '3599349':{'bg': u('\u0421\u043b\u0430\u043d\u043e\u0442\u0440\u044a\u043d'), 'en': 'Slanotran'}, '3593921':{'bg': u('\u041c\u0435\u0440\u0438\u0447\u043b\u0435\u0440\u0438'), 'en': 'Merichleri'}, '3599342':{'bg': u('\u0418\u043d\u043e\u0432\u043e'), 'en': 'Inovo'}, '3599343':{'bg': u('\u0413\u043e\u043c\u043e\u0442\u0430\u0440\u0446\u0438'), 'en': 'Gomotartsi'}, '3599340':{'bg': u('\u0421\u0435\u043f\u0442\u0435\u043c\u0432\u0440\u0438\u0439\u0446\u0438, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Septemvriytsi, Vidin'}, '3599341':{'bg': u('\u0414\u0438\u043c\u043e\u0432\u043e, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Dimovo, Vidin'}, '3599346':{'bg': u('\u0421\u0438\u043d\u0430\u0433\u043e\u0432\u0446\u0438'), 'en': 'Sinagovtsi'}, '3599347':{'bg': u('\u0411\u0435\u043b\u0430 \u0420\u0430\u0434\u0430'), 'en': 'Bela Rada'}, '3599344':{'bg': u('\u0412\u0440\u044a\u0432'), 'en': 'Vrav'}, '3599345':{'bg': u('\u0412\u0438\u043d\u0430\u0440\u043e\u0432\u043e, \u0412\u0438\u0434\u0438\u043d'), 'en': 'Vinarovo, Vidin'}, '3343802':{'en': u('Saint-Egr\u00e8ve'), 'fr': u('Saint-Egr\u00e8ve')}, '3339041':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3339040':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '355287':{'en': u('Klos/Su\u00e7/Lis, Mat')}, '355286':{'en': u('Ka\u00e7inar/Orosh/Fan, Mirdit\u00eb')}, '355285':{'en': u('Kthjell\u00eb/Selit\u00eb, Mirdit\u00eb')}, '355284':{'en': u('Rubik, Mirdit\u00eb')}, '355283':{'en': u('Kolsh/Zejmen/Sh\u00ebnkoll, Lezh\u00eb')}, '355282':{'en': u('Kallmet/Blinisht/Daj\u00e7/Ungrej, Lezh\u00eb')}, '355281':{'en': u('Sh\u00ebngjin/Balldre, Lezh\u00eb')}, '35963561':{'bg': u('\u0413\u0440\u0438\u0432\u0438\u0446\u0430'), 'en': 'Grivitsa'}, '355289':{'en': u('Ul\u00ebz/Rukaj/Derjan/Macukull, Mat')}, '355288':{'en': u('Baz/Komsi/Gurr\u00eb/Xib\u00ebr, Mat')}, '355579':{'en': u('Luz i Vog\u00ebl/Kryevidh/Helm\u00ebs, Kavaj\u00eb')}, '355578':{'en': u('Synej/Golem, Kavaj\u00eb')}, '35963560':{'bg': u('\u0420\u0430\u0434\u0438\u0448\u0435\u0432\u043e'), 'en': 'Radishevo'}, '3596969':{'bg': u('\u0411\u0435\u043a\u043b\u0435\u043c\u0435\u0442\u043e'), 'en': 'Beklemeto'}, '3596968':{'bg': u('\u0414\u043e\u0431\u0440\u043e\u0434\u0430\u043d'), 'en': 'Dobrodan'}, '355571':{'en': u('Shijak, Durr\u00ebs')}, '355570':{'en': u('Gos\u00eb/Lekaj/Sinaballaj, Kavaj\u00eb')}, '355573':{'en': u('Sukth, Durr\u00ebs')}, '355572':{'en': u('Man\u00ebz, Durr\u00ebs')}, '355575':{'en': u('Xhafzotaj/Maminas, Durr\u00ebs')}, '355574':{'en': u('Rashbull/Gjepalaj, Durr\u00ebs')}, '355577':{'en': u('Rrogozhin\u00eb, Kavaj\u00eb')}, '355576':{'en': u('Katund i Ri/Ishem, Durr\u00ebs')}, '3347853':{'en': 'Lyon', 'fr': 'Lyon'}, '3347852':{'en': 'Lyon', 'fr': 'Lyon'}, '3347851':{'en': 'Oullins', 'fr': 'Oullins'}, '3347850':{'en': 'Oullins', 'fr': 'Oullins'}, '3347857':{'en': 'Craponne', 'fr': 'Craponne'}, '3347856':{'en': 'Saint-Genis-Laval', 'fr': 'Saint-Genis-Laval'}, '3347855':{'en': 'Miribel', 'fr': 'Miribel'}, '3347854':{'en': 'Lyon', 'fr': 'Lyon'}, '3347859':{'en': u('Sainte-Foy-l\u00e8s-Lyon'), 'fr': u('Sainte-Foy-l\u00e8s-Lyon')}, '3347858':{'en': 'Lyon', 'fr': 'Lyon'}, '3347679':{'en': 'Les Deux Alpes', 'fr': 'Les Deux Alpes'}, '3347678':{'en': 'Vizille', 'fr': 'Vizille'}, '3346670':{'en': u('N\u00eemes'), 'fr': u('N\u00eemes')}, '3324015':{'en': u('Gu\u00e9rande'), 'fr': u('Gu\u00e9rande')}, '3346672':{'en': 'Lussan', 'fr': 'Lussan'}, '3324017':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '3338060':{'en': 'Dijon', 'fr': 'Dijon'}, '3346675':{'en': 'Marguerittes', 'fr': 'Marguerittes'}, '3324012':{'en': 'Nantes', 'fr': 'Nantes'}, '3324013':{'en': u('Rez\u00e9'), 'fr': u('Rez\u00e9')}, '3346678':{'en': u('Al\u00e8s'), 'fr': u('Al\u00e8s')}, '3346679':{'en': 'Laudun-l\'Ardoise', 'fr': 'Laudun-l\'Ardoise'}, '3324018':{'en': 'Nantes', 'fr': 'Nantes'}, '3324019':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '436227':{'de': 'Sankt Gilgen', 'en': 'St. Gilgen'}, '35941145':{'bg': u('\u0410\u0440\u043d\u0430\u0443\u0442\u0438\u0442\u043e'), 'en': 'Arnautito'}, '436225':{'de': 'Eugendorf', 'en': 'Eugendorf'}, '3522439':{'de': 'Windhof/Steinfort', 'en': 'Windhof/Steinfort', 'fr': 'Windhof/Steinfort'}, '436223':{'de': 'Anthering', 'en': 'Anthering'}, '436221':{'de': 'Koppl', 'en': 'Koppl'}, '35941144':{'bg': u('\u041a\u0430\u043b\u043e\u044f\u043d\u043e\u0432\u0435\u0446'), 'en': 'Kaloyanovets'}, '3522432':{'de': 'Lintgen/Kanton Mersch/Steinfort', 'en': 'Lintgen/Mersch/Steinfort', 'fr': 'Lintgen/Mersch/Steinfort'}, '3522433':{'de': 'Walferdingen', 'en': 'Walferdange', 'fr': 'Walferdange'}, '3522430':{'de': 'Kanton Capellen/Kehlen', 'en': 'Capellen/Kehlen', 'fr': 'Capellen/Kehlen'}, '3522431':{'de': 'Bartringen', 'en': 'Bertrange', 'fr': 'Bertrange'}, '3522436':{'de': 'Hesperingen/Kockelscheuer/Roeser', 'en': 'Hesperange/Kockelscheuer/Roeser', 'fr': 'Hesperange/Kockelscheuer/Roeser'}, '3522437':{'de': 'Leudelingen/Ehlingen/Monnerich', 'en': 'Leudelange/Ehlange/Mondercange', 'fr': 'Leudelange/Ehlange/Mondercange'}, '3522434':{'de': 'Rammeldingen/Senningerberg', 'en': 'Rameldange/Senningerberg', 'fr': 'Rameldange/Senningerberg'}, '3522435':{'de': 'Sandweiler/Mutfort/Roodt-sur-Syre', 'en': 'Sandweiler/Moutfort/Roodt-sur-Syre', 'fr': 'Sandweiler/Moutfort/Roodt-sur-Syre'}, '35941146':{'bg': u('\u0425\u0440\u0438\u0441\u0442\u0438\u044f\u043d\u043e\u0432\u043e'), 'en': 'Hristianovo'}, '3355528':{'en': 'Argentat', 'fr': 'Argentat'}, '3323577':{'en': 'Elbeuf', 'fr': 'Elbeuf'}, '334732':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '334731':{'en': 'Clermont-Ferrand', 'fr': 'Clermont-Ferrand'}, '35961393':{'bg': u('\u0413\u043e\u0440\u0441\u043a\u043e \u041a\u043e\u0441\u043e\u0432\u043e'), 'en': 'Gorsko Kosovo'}, '35961391':{'bg': u('\u0421\u043b\u043e\u043c\u0435\u0440'), 'en': 'Slomer'}, '3329947':{'en': u('Janz\u00e9'), 'fr': u('Janz\u00e9')}, '35961394':{'bg': u('\u0414\u044a\u0441\u043a\u043e\u0442'), 'en': 'Daskot'}, '35961395':{'bg': u('\u041f\u0430\u0441\u043a\u0430\u043b\u0435\u0432\u0435\u0446'), 'en': 'Paskalevets'}, '3329620':{'en': 'Paimpol', 'fr': 'Paimpol'}, '3329623':{'en': 'Perros-Guirec', 'fr': 'Perros-Guirec'}, '3355520':{'en': 'Tulle', 'fr': 'Tulle'}, '3329628':{'en': u('Loud\u00e9ac'), 'fr': u('Loud\u00e9ac')}, '3329629':{'en': 'Rostrenen', 'fr': 'Rostrenen'}, '3338473':{'en': 'Salins-les-Bains', 'fr': 'Salins-les-Bains'}, '3338472':{'en': 'Dole', 'fr': 'Dole'}, '3329943':{'en': 'Bain-de-Bretagne', 'fr': 'Bain-de-Bretagne'}, '3338475':{'en': 'Vesoul', 'fr': 'Vesoul'}, '3338474':{'en': 'Mollans', 'fr': 'Mollans'}, '3338479':{'en': 'Dole', 'fr': 'Dole'}, '3355523':{'en': 'Brive-la-Gaillarde', 'fr': 'Brive-la-Gaillarde'}, '3349442':{'en': 'Toulon', 'fr': 'Toulon'}, '3335462':{'en': 'Metz', 'fr': 'Metz'}, '3349443':{'en': 'Grimaud', 'fr': 'Grimaud'}, '3349440':{'en': u('Fr\u00e9jus'), 'fr': u('Fr\u00e9jus')}, '3349441':{'en': 'Toulon', 'fr': 'Toulon'}, '390774':{'en': 'Rome', 'it': 'Tivoli'}, '3349447':{'en': 'Draguignan', 'fr': 'Draguignan'}, '3349444':{'en': u('Fr\u00e9jus'), 'fr': u('Fr\u00e9jus')}, '3348633':{'en': 'La Ciotat', 'fr': 'La Ciotat'}, '3348631':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '3348634':{'en': 'Avignon', 'fr': 'Avignon'}, '3346894':{'en': 'Castelnaudary', 'fr': 'Castelnaudary'}, '3346895':{'en': u('Argel\u00e8s-sur-Mer'), 'fr': u('Argel\u00e8s-sur-Mer')}, '3346896':{'en': 'Prades', 'fr': 'Prades'}, '3346890':{'en': 'Narbonne', 'fr': 'Narbonne'}, '3346892':{'en': u('Saint-Est\u00e8ve'), 'fr': u('Saint-Est\u00e8ve')}, '3346893':{'en': 'Moussan', 'fr': 'Moussan'}, '442844':{'en': 'Downpatrick'}, '442840':{'en': 'Banbridge'}, '442841':{'en': 'Rostrevor'}, '442842':{'en': 'Kircubbin'}, '442843':{'en': 'Newcastle (Co. Down)'}, '3522697':{'de': 'Huldingen', 'en': 'Huldange', 'fr': 'Huldange'}, '3522695':{'de': 'Wiltz', 'en': 'Wiltz', 'fr': 'Wiltz'}, '3522692':{'de': 'Kanton Clerf/Fischbach/Hosingen', 'en': 'Clervaux/Fischbach/Hosingen', 'fr': 'Clervaux/Fischbach/Hosingen'}, '3522699':{'de': 'Ulflingen', 'en': 'Troisvierges', 'fr': 'Troisvierges'}, '3325629':{'en': 'Brest', 'fr': 'Brest'}, '3323741':{'en': 'Anet', 'fr': 'Anet'}, '34810':{'en': 'Madrid', 'es': 'Madrid'}, '3323742':{'en': 'Dreux', 'fr': 'Dreux'}, '3323745':{'en': u('Ch\u00e2teaudun'), 'fr': u('Ch\u00e2teaudun')}, '3323744':{'en': u('Ch\u00e2teaudun'), 'fr': u('Ch\u00e2teaudun')}, '3323747':{'en': 'Bonneval', 'fr': 'Bonneval'}, '3323746':{'en': 'Dreux', 'fr': 'Dreux'}, '35930475':{'bg': u('\u0421\u0442\u043e\u043c\u0430\u043d\u0435\u0432\u043e'), 'en': 'Stomanevo'}, '35930476':{'bg': u('\u0421\u0435\u043b\u0447\u0430'), 'en': 'Selcha'}, '35930472':{'bg': u('\u041c\u0438\u0445\u0430\u043b\u043a\u043e\u0432\u043e'), 'en': 'Mihalkovo'}, '3332163':{'en': u('B\u00e9thune'), 'fr': u('B\u00e9thune')}, '3332162':{'en': u('Bruay-la-Buissi\u00e8re'), 'fr': u('Bruay-la-Buissi\u00e8re')}, '3332160':{'en': 'Arras', 'fr': 'Arras'}, '3332167':{'en': 'Lens', 'fr': 'Lens'}, '3332169':{'en': 'Wingles', 'fr': 'Wingles'}, '3332168':{'en': u('B\u00e9thune'), 'fr': u('B\u00e9thune')}, '3354733':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '44141':{'en': 'Glasgow'}, '431':{'de': 'Wien', 'en': 'Vienna'}, '3325193':{'en': 'Challans', 'fr': 'Challans'}, '3325190':{'en': 'Bretignolles-sur-Mer', 'fr': 'Bretignolles-sur-Mer'}, '3325194':{'en': 'Chantonnay', 'fr': 'Chantonnay'}, '3325195':{'en': 'Les Sables d\'Olonne', 'fr': 'Les Sables d\'Olonne'}, '390161':{'en': 'Vercelli', 'it': 'Vercelli'}, '390163':{'it': 'Borgosesia'}, '390165':{'en': 'Aosta Valley', 'it': 'Aosta'}, '3349546':{'en': 'Corte', 'fr': 'Corte'}, '390166':{'en': 'Aosta Valley', 'it': 'Saint-Vincent'}, '351295':{'en': u('Angra do Hero\u00edsmo'), 'pt': u('Angra do Hero\u00edsmo')}, '351296':{'en': 'Ponta Delgada', 'pt': 'Ponta Delgada'}, '351291':{'en': 'Funchal', 'pt': 'Funchal'}, '351292':{'en': 'Horta', 'pt': 'Horta'}, '3332787':{'en': 'Douai', 'fr': 'Douai'}, '3332786':{'en': 'Somain', 'fr': 'Somain'}, '3332785':{'en': 'Caudry', 'fr': 'Caudry'}, '3332784':{'en': u('Le Cateau Cambr\u00e9sis'), 'fr': u('Le Cateau Cambr\u00e9sis')}, '3332783':{'en': 'Cambrai', 'fr': 'Cambrai'}, '3332782':{'en': 'Cambrai', 'fr': 'Cambrai'}, '3332781':{'en': 'Cambrai', 'fr': 'Cambrai'}, '3332788':{'en': 'Douai', 'fr': 'Douai'}, '3594136':{'bg': u('\u0427\u0435\u0440\u043d\u0430 \u0433\u043e\u0440\u0430, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Cherna gora, St. Zagora'}, '3594137':{'bg': u('\u0412\u0435\u0440\u0435\u043d'), 'en': 'Veren'}, '3594134':{'bg': u('\u0411\u0440\u0430\u0442\u044f \u0414\u0430\u0441\u043a\u0430\u043b\u043e\u0432\u0438'), 'en': 'Bratya Daskalovi'}, '3594132':{'bg': u('\u041e\u0440\u0438\u0437\u043e\u0432\u043e'), 'en': 'Orizovo'}, '3594130':{'bg': u('\u0421\u043f\u0430\u0441\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Spasovo, St. Zagora'}, '435286':{'de': 'Ginzling', 'en': 'Ginzling'}, '3594138':{'bg': u('\u0413\u0438\u0442\u0430'), 'en': 'Gita'}, '3594139':{'bg': u('\u0421\u0432\u043e\u0431\u043e\u0434\u0430, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Svoboda, St. Zagora'}, '4414301':{'en': 'North Cave/Market Weighton'}, '4414300':{'en': 'North Cave/Market Weighton'}, '435280':{'de': u('Hochf\u00fcgen'), 'en': u('Hochf\u00fcgen')}, '4414303':{'en': 'North Cave'}, '3598132':{'bg': u('\u042e\u0434\u0435\u043b\u043d\u0438\u043a'), 'en': 'Yudelnik'}, '3598133':{'bg': u('\u0420\u044f\u0445\u043e\u0432\u043e'), 'en': 'Ryahovo'}, '3598131':{'bg': u('\u0411\u043e\u0440\u0438\u0441\u043e\u0432\u043e, \u0420\u0443\u0441\u0435'), 'en': 'Borisovo, Ruse'}, '3598136':{'bg': u('\u0421\u0442\u0430\u043c\u0431\u043e\u043b\u043e\u0432\u043e, \u0420\u0443\u0441\u0435'), 'en': 'Stambolovo, Ruse'}, '3598137':{'bg': u('\u0413\u043e\u043b\u044f\u043c\u043e \u0412\u0440\u0430\u043d\u043e\u0432\u043e'), 'en': 'Golyamo Vranovo'}, '3598134':{'bg': u('\u041c\u0430\u043b\u043a\u043e \u0412\u0440\u0430\u043d\u043e\u0432\u043e'), 'en': 'Malko Vranovo'}, '3598135':{'bg': u('\u0411\u0430\u0431\u043e\u0432\u043e'), 'en': 'Babovo'}, '333854':{'en': u('Chalon-sur-Sa\u00f4ne'), 'fr': u('Chalon-sur-Sa\u00f4ne')}, '4414306':{'en': 'Market Weighton'}, '3688':{'en': 'Veszprem', 'hu': u('Veszpr\u00e9m')}, '435288':{'de': u('F\u00fcgen'), 'en': u('F\u00fcgen')}, '435289':{'de': u('H\u00e4usling'), 'en': u('H\u00e4usling')}, '370389':{'en': 'Utena'}, '370383':{'en': u('Mol\u0117tai')}, '370382':{'en': u('\u0160irvintos')}, '370381':{'en': u('Anyk\u0161\u010diai')}, '370380':{'en': u('\u0160al\u010dininkai')}, '370387':{'en': u('\u0160ven\u010dionys')}, '370386':{'en': 'Ignalina/Visaginas'}, '370385':{'en': 'Zarasai'}, '3338183':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3338182':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3338181':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3338180':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3338187':{'en': 'Saint-Vit', 'fr': 'Saint-Vit'}, '3338185':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3338184':{'en': 'Baume-les-Dames', 'fr': 'Baume-les-Dames'}, '3338188':{'en': u('Besan\u00e7on'), 'fr': u('Besan\u00e7on')}, '3596028':{'bg': u('\u0412\u0430\u0440\u0434\u0443\u043d'), 'en': 'Vardun'}, '433859':{'de': u('M\u00fcrzsteg'), 'en': u('M\u00fcrzsteg')}, '3596029':{'bg': u('\u041d\u0430\u0434\u0430\u0440\u0435\u0432\u043e'), 'en': 'Nadarevo'}, '3595553':{'bg': u('\u041e\u0440\u043b\u0438\u043d\u0446\u0438'), 'en': 'Orlintsi'}, '3595552':{'bg': u('\u0414\u044e\u043b\u0435\u0432\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Dyulevo, Burgas'}, '3595551':{'bg': u('\u0421\u0440\u0435\u0434\u0435\u0446, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Sredets, Burgas'}, '3595557':{'bg': u('\u0411\u0438\u0441\u0442\u0440\u0435\u0446, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Bistrets, Burgas'}, '3595556':{'bg': u('\u0413\u043e\u043b\u044f\u043c\u043e \u0411\u0443\u043a\u043e\u0432\u043e'), 'en': 'Golyamo Bukovo'}, '3595555':{'bg': u('\u0424\u0430\u043a\u0438\u044f'), 'en': 'Fakia'}, '3595554':{'bg': u('\u041c\u043e\u043c\u0438\u043d\u0430 \u0446\u044a\u0440\u043a\u0432\u0430'), 'en': 'Momina tsarkva'}, '3347445':{'en': 'Bourg-en-Bresse', 'fr': 'Bourg-en-Bresse'}, '3347446':{'en': u('Amb\u00e9rieu-en-Bugey'), 'fr': u('Amb\u00e9rieu-en-Bugey')}, '3347447':{'en': 'Bourg-en-Bresse', 'fr': 'Bourg-en-Bresse'}, '3347440':{'en': 'Lagnieu', 'fr': 'Lagnieu'}, '3347443':{'en': 'Bourgoin-Jallieu', 'fr': 'Bourgoin-Jallieu'}, '3346799':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346798':{'en': u('P\u00e9zenas'), 'fr': u('P\u00e9zenas')}, '3346793':{'en': 'Capestang', 'fr': 'Capestang'}, '3346792':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3346791':{'en': 'Lunel', 'fr': 'Lunel'}, '3346797':{'en': u('Saint-Pons-de-Thomi\u00e8res'), 'fr': u('Saint-Pons-de-Thomi\u00e8res')}, '3346796':{'en': u('Clermont-l\'H\u00e9rault'), 'fr': u('Clermont-l\'H\u00e9rault')}, '3346795':{'en': u('B\u00e9darieux'), 'fr': u('B\u00e9darieux')}, '3346794':{'en': 'Agde', 'fr': 'Agde'}, '331771':{'en': 'Paris', 'fr': 'Paris'}, '359678':{'bg': u('\u0422\u0435\u0442\u0435\u0432\u0435\u043d'), 'en': 'Teteven'}, '359670':{'bg': u('\u0422\u0440\u043e\u044f\u043d, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Troyan, Lovech'}, '359676':{'bg': u('\u0414\u0440\u044f\u043d\u043e\u0432\u043e, \u0413\u0430\u0431\u0440.'), 'en': 'Dryanovo, Gabr.'}, '359677':{'bg': u('\u0422\u0440\u044f\u0432\u043d\u0430'), 'en': 'Tryavna'}, '359675':{'bg': u('\u0421\u0435\u0432\u043b\u0438\u0435\u0432\u043e'), 'en': 'Sevlievo'}, '46171':{'en': u('Enk\u00f6ping'), 'sv': u('Enk\u00f6ping')}, '46176':{'en': u('Norrt\u00e4lje'), 'sv': u('Norrt\u00e4lje')}, '46175':{'en': 'Hallstavik-Rimbo', 'sv': 'Hallstavik-Rimbo'}, '441354':{'en': 'Chatteris'}, '3349047':{'en': 'Saint-Martin-de-Crau', 'fr': 'Saint-Martin-de-Crau'}, '3349044':{'en': 'Salon-de-Provence', 'fr': 'Salon-de-Provence'}, '3349045':{'en': 'Salon-de-Provence', 'fr': 'Salon-de-Provence'}, '3349042':{'en': 'Salon-de-Provence', 'fr': 'Salon-de-Provence'}, '3349043':{'en': 'Tarascon', 'fr': 'Tarascon'}, '3349040':{'en': u('Boll\u00e8ne'), 'fr': u('Boll\u00e8ne')}, '3349041':{'en': 'Visan', 'fr': 'Visan'}, '3351649':{'en': 'La Rochelle', 'fr': 'La Rochelle'}, '3349048':{'en': 'Entraigues-sur-la-Sorgue', 'fr': 'Entraigues-sur-la-Sorgue'}, '3349049':{'en': 'Arles', 'fr': 'Arles'}, '46281':{'en': 'Vansbro', 'sv': 'Vansbro'}, '46280':{'en': 'Malung', 'sv': 'Malung'}, '3354039':{'en': 'Bayonne', 'fr': 'Bayonne'}, '3332751':{'en': 'Valenciennes', 'fr': 'Valenciennes'}, '4419465':{'en': 'Whitehaven'}, '436414':{'de': u('Gro\u00dfarl'), 'en': 'Grossarl'}, '432534':{'de': 'Niedersulz', 'en': 'Niedersulz'}, '4419463':{'en': 'Whitehaven'}, '4419462':{'en': 'Whitehaven'}, '3349954':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3349223':{'en': u('L\'Argenti\u00e8re la Bess\u00e9e'), 'fr': u('L\'Argenti\u00e8re la Bess\u00e9e')}, '3349220':{'en': u('Brian\u00e7on'), 'fr': u('Brian\u00e7on')}, '3349221':{'en': u('Brian\u00e7on'), 'fr': u('Brian\u00e7on')}, '3349951':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3349952':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3349953':{'en': 'Montpellier', 'fr': 'Montpellier'}, '390374':{'it': 'Soresina'}, '390375':{'it': 'Casalmaggiore'}, '3349228':{'en': 'Mougins', 'fr': 'Mougins'}, '3349229':{'en': 'Nice', 'fr': 'Nice'}, '3349958':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3338787':{'en': 'Forbach', 'fr': 'Forbach'}, '390372':{'en': 'Cremona', 'it': 'Cremona'}, '390373':{'en': 'Cremona', 'it': 'Crema'}, '3522771':{'de': 'Betzdorf', 'en': 'Betzdorf', 'fr': 'Betzdorf'}, '3522773':{'de': 'Rosport', 'en': 'Rosport', 'fr': 'Rosport'}, '3522772':{'de': 'Echternach', 'en': 'Echternach', 'fr': 'Echternach'}, '3522775':{'de': 'Distrikt Grevenmacher-sur-Moselle', 'en': 'Grevenmacher-sur-Moselle', 'fr': 'Grevenmacher-sur-Moselle'}, '3522774':{'de': 'Wasserbillig', 'en': 'Wasserbillig', 'fr': 'Wasserbillig'}, '3522776':{'de': 'Wormeldingen', 'en': 'Wormeldange', 'fr': 'Wormeldange'}, '3522779':{'de': 'Berdorf/Consdorf', 'en': 'Berdorf/Consdorf', 'fr': 'Berdorf/Consdorf'}, '3522778':{'de': 'Junglinster', 'en': 'Junglinster', 'fr': 'Junglinster'}, '3597041':{'bg': u('\u0428\u0430\u0442\u0440\u043e\u0432\u043e'), 'en': 'Shatrovo'}, '3597047':{'bg': u('\u0423\u0441\u043e\u0439\u043a\u0430'), 'en': 'Usoyka'}, '3597046':{'bg': u('\u0411\u043e\u0431\u043e\u0448\u0435\u0432\u043e'), 'en': 'Boboshevo'}, '3597045':{'bg': u('\u0413\u043e\u043b\u0435\u043c \u0412\u044a\u0440\u0431\u043e\u0432\u043d\u0438\u043a'), 'en': 'Golem Varbovnik'}, '3338780':{'en': u('Maizi\u00e8res-l\u00e8s-Metz'), 'fr': u('Maizi\u00e8res-l\u00e8s-Metz')}, '441328':{'en': 'Fakenham'}, '441329':{'en': 'Fareham'}, '35931603':{'bg': u('\u0412\u0438\u043d\u0438\u0446\u0430'), 'en': 'Vinitsa'}, '35931602':{'bg': u('\u0422\u0430\u0442\u0430\u0440\u0435\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Tatarevo, Plovdiv'}, '35931605':{'bg': u('\u0411\u0443\u043a\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Bukovo, Plovdiv'}, '35931604':{'bg': u('\u0414\u0440\u0430\u0433\u043e\u0439\u043d\u043e\u0432\u043e'), 'en': 'Dragoynovo'}, '35931606':{'bg': u('\u0412\u043e\u0434\u0435\u043d, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Voden, Plovdiv'}, '441320':{'en': 'Fort Augustus'}, '441322':{'en': 'Dartford'}, '3338782':{'en': 'Creutzwald', 'fr': 'Creutzwald'}, '441324':{'en': 'Falkirk'}, '441325':{'en': 'Darlington'}, '441326':{'en': 'Falmouth'}, '441327':{'en': 'Daventry'}, '3323174':{'en': 'Caen', 'fr': 'Caen'}, '3323175':{'en': 'Caen', 'fr': 'Caen'}, '3323172':{'en': 'Colombelles', 'fr': 'Colombelles'}, '3323173':{'en': 'Caen', 'fr': 'Caen'}, '3323170':{'en': 'Caen', 'fr': 'Caen'}, '3323171':{'en': 'Carpiquet', 'fr': 'Carpiquet'}, '3338864':{'en': 'Fegersheim', 'fr': 'Fegersheim'}, '3338865':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338866':{'en': 'Illkirch-Graffenstaden', 'fr': 'Illkirch-Graffenstaden'}, '3338867':{'en': 'Illkirch-Graffenstaden', 'fr': 'Illkirch-Graffenstaden'}, '3338860':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338861':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3338862':{'en': 'Schiltigheim', 'fr': 'Schiltigheim'}, '3338863':{'en': 'Bischwiller', 'fr': 'Bischwiller'}, '432823':{'de': u('Gro\u00dfglobnitz'), 'en': 'Grossglobnitz'}, '432822':{'de': u('Zwettl-Nieder\u00f6sterreich'), 'en': 'Zwettl, Lower Austria'}, '3332578':{'en': 'Troyes', 'fr': 'Troyes'}, '3332579':{'en': 'Sainte-Savine', 'fr': 'Sainte-Savine'}, '432827':{'de': u('Sch\u00f6nbach'), 'en': u('Sch\u00f6nbach')}, '432826':{'de': 'Rastenfeld', 'en': 'Rastenfeld'}, '3332574':{'en': 'Troyes', 'fr': 'Troyes'}, '3332575':{'en': 'Troyes', 'fr': 'Troyes'}, '3332576':{'en': 'Troyes', 'fr': 'Troyes'}, '3332571':{'en': 'Troyes', 'fr': 'Troyes'}, '3332572':{'en': 'Troyes', 'fr': 'Troyes'}, '3332573':{'en': 'Troyes', 'fr': 'Troyes'}, '35937606':{'bg': u('\u0428\u0438\u0448\u043c\u0430\u043d\u043e\u0432\u043e'), 'en': 'Shishmanovo'}, '3354693':{'en': 'Saintes', 'fr': 'Saintes'}, '3354692':{'en': 'Saintes', 'fr': 'Saintes'}, '35937603':{'bg': u('\u0420\u043e\u0433\u043e\u0437\u0438\u043d\u043e\u0432\u043e'), 'en': 'Rogozinovo'}, '35937602':{'bg': u('\u0427\u0435\u0440\u043d\u0430 \u043c\u043e\u0433\u0438\u043b\u0430, \u0425\u0430\u0441\u043a.'), 'en': 'Cherna mogila, Hask.'}, '3354697':{'en': 'Saintes', 'fr': 'Saintes'}, '3354699':{'en': 'Rochefort', 'fr': 'Rochefort'}, '3354698':{'en': 'Saintes', 'fr': 'Saintes'}, '3554':{'en': 'Tirana'}, '3329952':{'en': 'Bruz', 'fr': 'Bruz'}, '3346931':{'en': 'Bourgoin-Jallieu', 'fr': 'Bourgoin-Jallieu'}, '3323353':{'en': 'Cherbourg-Octeville', 'fr': 'Cherbourg-Octeville'}, '3323350':{'en': 'Granville', 'fr': 'Granville'}, '3355348':{'en': 'Agen', 'fr': 'Agen'}, '3355349':{'en': 'Villeneuve-sur-Lot', 'fr': 'Villeneuve-sur-Lot'}, '3355612':{'en': 'Merignac', 'fr': u('M\u00e9rignac')}, '3355345':{'en': u('P\u00e9rigueux'), 'fr': u('P\u00e9rigueux')}, '3355346':{'en': u('P\u00e9rigueux'), 'fr': u('P\u00e9rigueux')}, '3355611':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355616':{'en': 'Eysines', 'fr': 'Eysines'}, '3355617':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3355615':{'en': 'Pessac', 'fr': 'Pessac'}, '3329953':{'en': 'Rennes', 'fr': 'Rennes'}, '37424300':{'am': u('\u0531\u056d\u0578\u0582\u0580\u0575\u0561\u0576/\u0531\u057c\u0561\u0583\u056b/\u053f\u0561\u0574\u0578/\u0544\u0578\u0582\u057d\u0561\u0575\u0565\u056c\u0575\u0561\u0576'), 'en': 'Akhuryan/Arapi/Kamo/Musayelyan', 'ru': u('\u0410\u0445\u0443\u0440\u044f\u043d/\u0410\u0440\u0430\u043f\u0438/\u041a\u0430\u043c\u043e/\u041c\u0443\u0441\u0430\u0435\u043b\u044f\u043d')}, '432177':{'de': 'Podersdorf am See', 'en': 'Podersdorf am See'}, '432176':{'de': 'Tadten', 'en': 'Tadten'}, '432175':{'de': 'Apetlon', 'en': 'Apetlon'}, '432174':{'de': 'Wallern im Burgenland', 'en': 'Wallern im Burgenland'}, '432173':{'de': 'Gols', 'en': 'Gols'}, '432172':{'de': 'Frauenkirchen', 'en': 'Frauenkirchen'}, '437675':{'de': 'Ampflwang im Hausruckwald', 'en': 'Ampflwang im Hausruckwald'}, '437674':{'de': 'Attnang-Puchheim', 'en': 'Attnang-Puchheim'}, '3354968':{'en': 'Thouars', 'fr': 'Thouars'}, '3354962':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354961':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354960':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354966':{'en': 'Thouars', 'fr': 'Thouars'}, '3354965':{'en': 'Bressuire', 'fr': 'Bressuire'}, '3354964':{'en': 'Parthenay', 'fr': 'Parthenay'}, '3359041':{'en': 'Baie Mahault', 'fr': 'Baie Mahault'}, '3359048':{'en': 'Les Abymes', 'fr': 'Les Abymes'}, '3323120':{'en': 'Saint-Pierre-sur-Dives', 'fr': 'Saint-Pierre-sur-Dives'}, '4621':{'en': u('V\u00e4ster\u00e5s'), 'sv': u('V\u00e4ster\u00e5s')}, '3329981':{'en': 'Saint-Malo', 'fr': 'Saint-Malo'}, '3329983':{'en': u('Cesson-S\u00e9vign\u00e9'), 'fr': u('Cesson-S\u00e9vign\u00e9')}, '3329982':{'en': 'Saint-Malo', 'fr': 'Saint-Malo'}, '3329985':{'en': u('Pac\u00e9'), 'fr': u('Pac\u00e9')}, '3329984':{'en': 'Rennes', 'fr': 'Rennes'}, '3329987':{'en': 'Rennes', 'fr': 'Rennes'}, '3329986':{'en': 'Rennes', 'fr': 'Rennes'}, '3329989':{'en': 'Cancale', 'fr': 'Cancale'}, '3329988':{'en': 'Pleurtuit', 'fr': 'Pleurtuit'}, '3595946':{'bg': u('\u0422\u0440\u044a\u043d\u0430\u043a'), 'en': 'Tranak'}, '3595947':{'bg': u('\u041f\u0440\u043e\u0441\u0435\u043d\u0438\u043a'), 'en': 'Prosenik'}, '3595941':{'bg': u('\u0421\u043a\u0430\u043b\u0430\u043a, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Skalak, Burgas'}, '3595942':{'bg': u('\u041b\u044e\u043b\u044f\u043a\u043e\u0432\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Lyulyakovo, Burgas'}, '3595943':{'bg': u('\u0412\u0440\u0435\u0441\u043e\u0432\u043e'), 'en': 'Vresovo'}, '3593728':{'bg': u('\u0421\u043b\u0430\u0432\u044f\u043d\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Slavyanovo, Hask.'}, '3593729':{'bg': u('\u041a\u0440\u0438\u0432\u043e \u043f\u043e\u043b\u0435'), 'en': 'Krivo pole'}, '3593726':{'bg': u('\u041a\u043b\u043e\u043a\u043e\u0442\u043d\u0438\u0446\u0430'), 'en': 'Klokotnitsa'}, '3593727':{'bg': u('\u041d\u043e\u0432\u0430 \u041d\u0430\u0434\u0435\u0436\u0434\u0430'), 'en': 'Nova Nadezhda'}, '3593724':{'bg': u('\u0421\u0443\u0441\u0430\u043c'), 'en': 'Susam'}, '3593725':{'bg': u('\u0421\u0442\u0430\u043c\u0431\u043e\u043b\u0438\u0439\u0441\u043a\u0438, \u0425\u0430\u0441\u043a.'), 'en': 'Stamboliyski, Hask.'}, '3593722':{'bg': u('\u041c\u0438\u043d\u0435\u0440\u0430\u043b\u043d\u0438 \u0431\u0430\u043d\u0438, \u0425\u0430\u0441\u043a.'), 'en': 'Mineralni bani, Hask.'}, '3593720':{'bg': u('\u041c\u0430\u0434\u0436\u0430\u0440\u043e\u0432\u043e'), 'en': 'Madzharovo'}, '3593721':{'bg': u('\u0421\u0442\u0430\u043c\u0431\u043e\u043b\u043e\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Stambolovo, Hask.'}, '3353348':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '3329954':{'en': 'Rennes', 'fr': 'Rennes'}, '37423699':{'am': u('\u0534\u0561\u0577\u057f\u0561\u057e\u0561\u0576'), 'en': 'Dashtavan', 'ru': u('\u0414\u0430\u0448\u0442\u0430\u0432\u0430\u043d')}, '374471':{'am': u('\u054d\u057f\u0565\u0583\u0561\u0576\u0561\u056f\u0565\u0580\u057f'), 'en': 'Stepanakert', 'ru': u('\u0421\u0442\u0435\u043f\u0430\u043d\u0430\u043a\u0435\u0440\u0442')}, '374475':{'am': u('\u0540\u0561\u0580\u0564\u0580\u0578\u0582\u0569'), 'en': 'Hadrut', 'ru': u('\u0413\u0430\u0434\u0440\u0443\u0442')}, '374474':{'am': u('\u0544\u0561\u0580\u057f\u0561\u056f\u0565\u0580\u057f'), 'en': 'Martakert', 'ru': u('\u041c\u0430\u0440\u0442\u0430\u043a\u0435\u0440\u0442')}, '374477':{'am': u('\u0547\u0578\u0582\u0577\u056b'), 'en': 'Shushi', 'ru': u('\u0428\u0443\u0448\u0438')}, '374476':{'am': u('\u0531\u057d\u056f\u0565\u0580\u0561\u0576'), 'en': 'Askeran', 'ru': u('\u0410\u0441\u043a\u0435\u0440\u0430\u043d')}, '374479':{'am': u('\u054d\u057f\u0565\u0583\u0561\u0576\u0561\u056f\u0565\u0580\u057f'), 'en': 'Stepanakert', 'ru': u('\u0421\u0442\u0435\u043f\u0430\u043d\u0430\u043a\u0435\u0440\u0442')}, '374478':{'am': u('\u0544\u0561\u0580\u057f\u0578\u0582\u0576\u056b'), 'en': 'Martuni', 'ru': u('\u041c\u0430\u0440\u0442\u0443\u043d\u0438')}, '441528':{'en': 'Laggan'}, '441529':{'en': 'Sleaford'}, '441526':{'en': 'Martin'}, '441527':{'en': 'Redditch'}, '441525':{'en': 'Leighton Buzzard'}, '441522':{'en': 'Lincoln'}, '441520':{'en': 'Lochcarron'}, '3324384':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324385':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324386':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324380':{'en': 'Allonnes', 'fr': 'Allonnes'}, '3324381':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324382':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324383':{'en': 'Le Mans', 'fr': 'Le Mans'}, '3324389':{'en': u('Connerr\u00e9'), 'fr': u('Connerr\u00e9')}, '3596948':{'bg': u('\u041a\u044a\u0440\u043f\u0430\u0447\u0435\u0432\u043e'), 'en': 'Karpachevo'}, '35976':{'bg': u('\u041f\u0435\u0440\u043d\u0438\u043a'), 'en': 'Pernik'}, '35973':{'bg': u('\u0411\u043b\u0430\u0433\u043e\u0435\u0432\u0433\u0440\u0430\u0434'), 'en': 'Blagoevgrad'}, '3596941':{'bg': u('\u041b\u0435\u0442\u043d\u0438\u0446\u0430'), 'en': 'Letnitsa'}, '3596943':{'bg': u('\u0413\u043e\u0440\u0441\u043a\u043e \u0421\u043b\u0438\u0432\u043e\u0432\u043e'), 'en': 'Gorsko Slivovo'}, '3596942':{'bg': u('\u0410\u043b\u0435\u043a\u0441\u0430\u043d\u0434\u0440\u043e\u0432\u043e, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Aleksandrovo, Lovech'}, '3596944':{'bg': u('\u041a\u0440\u0443\u0448\u0443\u043d\u0430'), 'en': 'Krushuna'}, '3596946':{'bg': u('\u0427\u0430\u0432\u0434\u0430\u0440\u0446\u0438'), 'en': 'Chavdartsi'}, '3347651':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347650':{'en': 'Voreppe', 'fr': 'Voreppe'}, '3347653':{'en': 'Fontaine', 'fr': 'Fontaine'}, '3347652':{'en': 'Saint-Ismier', 'fr': 'Saint-Ismier'}, '3347879':{'en': 'Vaulx-en-Velin', 'fr': 'Vaulx-en-Velin'}, '3347878':{'en': 'Lyon', 'fr': 'Lyon'}, '3347656':{'en': 'Grenoble', 'fr': 'Grenoble'}, '3347875':{'en': 'Lyon', 'fr': 'Lyon'}, '3347874':{'en': 'Lyon', 'fr': 'Lyon'}, '3347877':{'en': 'Lyon', 'fr': 'Lyon'}, '3347876':{'en': 'Lyon', 'fr': 'Lyon'}, '3347871':{'en': 'Lyon', 'fr': 'Lyon'}, '3347870':{'en': 'Saint-Fons', 'fr': 'Saint-Fons'}, '3347873':{'en': 'Givors', 'fr': 'Givors'}, '3347872':{'en': 'Lyon', 'fr': 'Lyon'}, '3595768':{'bg': u('\u041e\u0434\u0440\u0438\u043d\u0446\u0438, \u0414\u043e\u0431\u0440.'), 'en': 'Odrintsi, Dobr.'}, '3595769':{'bg': u('\u0425\u0438\u0442\u043e\u0432\u043e'), 'en': 'Hitovo'}, '40259':{'en': 'Bihor', 'ro': 'Bihor'}, '3595760':{'bg': u('\u0411\u043e\u0436\u0443\u0440\u043e\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'Bozhurovo, Dobr.'}, '3595761':{'bg': u('\u0411\u0430\u0442\u043e\u0432\u043e'), 'en': 'Batovo'}, '3595762':{'bg': u('\u0421\u0442\u0435\u0444\u0430\u043d \u041a\u0430\u0440\u0430\u0434\u0436\u0430, \u0414\u043e\u0431\u0440.'), 'en': 'Stefan Karadzha, Dobr.'}, '3595763':{'bg': u('\u041f\u043b\u0430\u0447\u0438\u0434\u043e\u043b'), 'en': 'Plachidol'}, '3595764':{'bg': u('\u0412\u043b\u0430\u0434\u0438\u043c\u0438\u0440\u043e\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'Vladimirovo, Dobr.'}, '3595765':{'bg': u('\u041b\u043e\u0432\u0447\u0430\u043d\u0446\u0438'), 'en': 'Lovchantsi'}, '3595766':{'bg': u('\u041c\u0435\u0442\u043e\u0434\u0438\u0435\u0432\u043e, \u0414\u043e\u0431\u0440.'), 'en': 'Metodievo, Dobr.'}, '3595767':{'bg': u('\u0416\u0438\u0442\u043d\u0438\u0446\u0430, \u0414\u043e\u0431\u0440.'), 'en': 'Zhitnitsa, Dobr.'}, '3329838':{'en': u('Ploudalm\u00e9zeau'), 'fr': u('Ploudalm\u00e9zeau')}, '3346659':{'en': 'Beaucaire', 'fr': 'Beaucaire'}, '3338048':{'en': 'Quetigny', 'fr': 'Quetigny'}, '3338049':{'en': 'Dijon', 'fr': 'Dijon'}, '3338046':{'en': 'Quetigny', 'fr': 'Quetigny'}, '3346653':{'en': 'Aigues-Mortes', 'fr': 'Aigues-Mortes'}, '3338044':{'en': 'Dijon', 'fr': 'Dijon'}, '3338045':{'en': 'Dijon', 'fr': 'Dijon'}, '3338042':{'en': 'Dijon', 'fr': 'Dijon'}, '3346657':{'en': 'Montfrin', 'fr': 'Montfrin'}, '3346654':{'en': u('Al\u00e8s'), 'fr': u('Al\u00e8s')}, '3346655':{'en': u('Al\u00e8s'), 'fr': u('Al\u00e8s')}, '436241':{'de': 'Sankt Koloman', 'en': 'St. Koloman'}, '436240':{'de': 'Krispl', 'en': 'Krispl'}, '436243':{'de': 'Abtenau', 'en': 'Abtenau'}, '436242':{'de': u('Ru\u00dfbach am Pa\u00df Gsch\u00fctt'), 'en': u('Russbach am Pass Gsch\u00fctt')}, '436245':{'de': 'Hallein', 'en': 'Hallein'}, '436244':{'de': 'Golling an der Salzach', 'en': 'Golling an der Salzach'}, '436247':{'de': u('Gro\u00dfgmain'), 'en': 'Grossgmain'}, '436246':{'de': u('Gr\u00f6dig'), 'en': u('Gr\u00f6dig')}, '3338089':{'en': 'Montbard', 'fr': 'Montbard'}, '390836':{'it': 'Maglie'}, '3597546':{'bg': u('\u0421\u043b\u0430\u0449\u0435\u043d'), 'en': 'Slashten'}, '3597547':{'bg': u('\u0412\u044a\u043b\u043a\u043e\u0441\u0435\u043b'), 'en': 'Valkosel'}, '3597544':{'bg': u('\u041e\u0441\u0438\u043d\u0430'), 'en': 'Osina'}, '3597545':{'bg': u('\u041a\u043e\u0447\u0430\u043d'), 'en': 'Kochan'}, '35991184':{'bg': u('\u0420\u0430\u043a\u0435\u0432\u043e'), 'en': 'Rakevo'}, '35991185':{'bg': u('\u041f\u0443\u0434\u0440\u0438\u044f'), 'en': 'Pudria'}, '35991186':{'bg': u('\u0411\u0430\u0443\u0440\u0435\u043d\u0435'), 'en': 'Baurene'}, '3597541':{'bg': u('\u0421\u0430\u0442\u043e\u0432\u0447\u0430'), 'en': 'Satovcha'}, '35991188':{'bg': u('\u0413\u0430\u043b\u0430\u0442\u0438\u043d'), 'en': 'Galatin'}, '35991189':{'bg': u('\u0422\u0440\u0438 \u043a\u043b\u0430\u0434\u0435\u043d\u0446\u0438'), 'en': 'Tri kladentsi'}, '432815':{'de': u('Gro\u00dfsch\u00f6nau'), 'en': u('Grosssch\u00f6nau')}, '3597548':{'bg': u('\u0413\u043e\u0434\u0435\u0448\u0435\u0432\u043e'), 'en': 'Godeshevo'}, '3597549':{'bg': u('\u0414\u043e\u043b\u0435\u043d, \u0411\u043b\u0430\u0433.'), 'en': 'Dolen, Blag.'}, '441289':{'en': 'Berwick-upon-Tweed'}, '441288':{'en': 'Bude'}, '3329601':{'en': 'Saint-Brieuc', 'fr': 'Saint-Brieuc'}, '3338458':{'en': 'Belfort', 'fr': 'Belfort'}, '3338454':{'en': 'Belfort', 'fr': 'Belfort'}, '3338457':{'en': 'Belfort', 'fr': 'Belfort'}, '3338456':{'en': 'Beaucourt', 'fr': 'Beaucourt'}, '3338452':{'en': 'Champagnole', 'fr': 'Champagnole'}, '441284':{'en': 'Bury St Edmunds'}, '3597723':{'bg': u('\u0414\u043e\u043b\u043d\u0438 \u0420\u0430\u043a\u043e\u0432\u0435\u0446'), 'en': 'Dolni Rakovets'}, '3597720':{'bg': u('\u041f\u0440\u0438\u0431\u043e\u0439'), 'en': 'Priboy'}, '3597726':{'bg': u('\u0414\u0440\u0435\u043d'), 'en': 'Dren'}, '3597727':{'bg': u('\u041a\u043e\u0432\u0430\u0447\u0435\u0432\u0446\u0438, \u041f\u0435\u0440\u043d\u0438\u043a'), 'en': 'Kovachevtsi, Pernik'}, '3597724':{'bg': u('\u0418\u0437\u0432\u043e\u0440, \u041f\u0435\u0440\u043d\u0438\u043a'), 'en': 'Izvor, Pernik'}, '3597725':{'bg': u('\u041a\u043b\u0435\u043d\u043e\u0432\u0438\u043a'), 'en': 'Klenovik'}, '3597728':{'bg': u('\u0414\u0440\u0443\u0433\u0430\u043d'), 'en': 'Drugan'}, '3597729':{'bg': u('\u0414\u043e\u043b\u043d\u0430 \u0414\u0438\u043a\u0430\u043d\u044f'), 'en': 'Dolna Dikanya'}, '3345681':{'en': 'Thonon-les-Bains', 'fr': 'Thonon-les-Bains'}, '437956':{'de': u('Unterwei\u00dfenbach'), 'en': 'Unterweissenbach'}, '3597937':{'bg': u('\u0420\u044a\u0436\u0434\u0430\u0432\u0438\u0446\u0430'), 'en': 'Razhdavitsa'}, '3323728':{'en': 'Chartres', 'fr': 'Chartres'}, '3597936':{'bg': u('\u0421\u043b\u043e\u043a\u043e\u0449\u0438\u0446\u0430'), 'en': 'Slokoshtitsa'}, '3323723':{'en': 'Courville-sur-Eure', 'fr': 'Courville-sur-Eure'}, '3323721':{'en': 'Chartres', 'fr': 'Chartres'}, '3323720':{'en': 'Chartres', 'fr': 'Chartres'}, '3323727':{'en': 'Maintenon', 'fr': 'Maintenon'}, '3597935':{'bg': u('\u0414\u043e\u043b\u043d\u043e \u0441\u0435\u043b\u043e'), 'en': 'Dolno selo'}, '3323724':{'en': 'Illiers-Combray', 'fr': 'Illiers-Combray'}, '3597934':{'bg': u('\u0411\u0443\u043d\u043e\u0432\u043e, \u041a\u044e\u0441\u0442.'), 'en': 'Bunovo, Kyust.'}, '3332149':{'en': u('H\u00e9nin-Beaumont'), 'fr': u('H\u00e9nin-Beaumont')}, '3332145':{'en': u('Li\u00e9vin'), 'fr': u('Li\u00e9vin')}, '3332144':{'en': u('Li\u00e9vin'), 'fr': u('Li\u00e9vin')}, '3332146':{'en': 'Calais', 'fr': 'Calais'}, '3332143':{'en': 'Lens', 'fr': 'Lens'}, '3332142':{'en': 'Lens', 'fr': 'Lens'}, '3597930':{'bg': u('\u0415\u0440\u0435\u043c\u0438\u044f'), 'en': 'Eremia'}, '3597048':{'bg': u('\u0411\u043b\u0430\u0436\u0438\u0435\u0432\u043e'), 'en': 'Blazhievo'}, '3598111':{'bg': u('\u0429\u0440\u044a\u043a\u043b\u0435\u0432\u043e'), 'en': 'Shtraklevo'}, '3345024':{'en': 'Meythet', 'fr': 'Meythet'}, '3345025':{'en': 'Bonneville', 'fr': 'Bonneville'}, '3345026':{'en': 'Thonon-les-Bains', 'fr': 'Thonon-les-Bains'}, '3345020':{'en': 'Divonne-les-Bains', 'fr': 'Divonne-les-Bains'}, '3345021':{'en': u('Meg\u00e8ve'), 'fr': u('Meg\u00e8ve')}, '3345022':{'en': 'Meythet', 'fr': 'Meythet'}, '3349562':{'en': 'Calenzana', 'fr': 'Calenzana'}, '3345028':{'en': 'Ferney-Voltaire', 'fr': 'Ferney-Voltaire'}, '3348966':{'en': 'Toulon', 'fr': 'Toulon'}, '3348968':{'en': 'Cannes', 'fr': 'Cannes'}, '3345001':{'en': 'Rumilly', 'fr': 'Rumilly'}, '35971798':{'bg': u('\u0412\u0430\u0441\u0438\u043b\u043e\u0432\u0446\u0438,\u0421\u043e\u0444.'), 'en': 'Vasilovtsi,Sof.'}, '437953':{'de': 'Liebenau', 'en': 'Liebenau'}, '3594152':{'bg': u('\u041e\u0431\u0440\u0443\u0447\u0438\u0449\u0435'), 'en': 'Obruchishte'}, '3594153':{'bg': u('\u041c\u044a\u0434\u0440\u0435\u0446, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Madrets, St. Zagora'}, '3594154':{'bg': u('\u041c\u0435\u0434\u043d\u0438\u043a\u0430\u0440\u043e\u0432\u043e'), 'en': 'Mednikarovo'}, '3594155':{'bg': u('\u0413\u043b\u0430\u0432\u0430\u043d, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Glavan, St. Zagora'}, '3594156':{'bg': u('\u0410\u043f\u0440\u0438\u043b\u043e\u0432\u043e, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Aprilovo, St. Zagora'}, '3594157':{'bg': u('\u0420\u0430\u0437\u0434\u0435\u043b\u043d\u0430, \u0421\u0442. \u0417\u0430\u0433\u043e\u0440\u0430'), 'en': 'Razdelna, St. Zagora'}, '3594158':{'bg': u('\u0418\u0441\u043a\u0440\u0438\u0446\u0430'), 'en': 'Iskritsa'}, '433363':{'de': 'Rechnitz', 'en': 'Rechnitz'}, '433362':{'de': u('Gro\u00dfpetersdorf'), 'en': 'Grosspetersdorf'}, '433365':{'de': u('Deutsch Sch\u00fctzen-Eisenberg'), 'en': u('Deutsch Sch\u00fctzen-Eisenberg')}, '433364':{'de': 'Hannersdorf', 'en': 'Hannersdorf'}, '433366':{'de': 'Kohfidisch', 'en': 'Kohfidisch'}, '35971471':{'bg': u('\u041e\u0447\u0443\u0448\u0430'), 'en': 'Ochusha'}, '441594':{'en': 'Lydney'}, '3595144':{'bg': u('\u041a\u0430\u043c\u0447\u0438\u044f'), 'en': 'Kamchia'}, '3324737':{'en': 'Tours', 'fr': 'Tours'}, '3324736':{'en': 'Tours', 'fr': 'Tours'}, '3324731':{'en': 'Tours', 'fr': 'Tours'}, '3324730':{'en': 'Amboise', 'fr': 'Amboise'}, '3324732':{'en': 'Saint-Pierre-des-Corps', 'fr': 'Saint-Pierre-des-Corps'}, '3324739':{'en': 'Tours', 'fr': 'Tours'}, '35357':{'en': 'Portlaoise/Abbeyleix/Tullamore/Birr'}, '3356189':{'en': 'Saint-Gaudens', 'fr': 'Saint-Gaudens'}, '35356':{'en': 'Kilkenny/Castlecomer/Freshford'}, '3344250':{'en': 'Rognes', 'fr': 'Rognes'}, '3356180':{'en': 'Toulouse', 'fr': 'Toulouse'}, '3356187':{'en': 'Carbonne', 'fr': 'Carbonne'}, '3356186':{'en': 'Tournefeuille', 'fr': 'Tournefeuille'}, '441787':{'en': 'Sudbury'}, '37423798':{'am': u('\u0547\u0565\u0576\u0561\u057e\u0561\u0576'), 'en': 'Shenavan', 'ru': u('\u0428\u0435\u043d\u0430\u0432\u0430\u043d')}, '35991401':{'bg': u('\u0412\u0440\u0430\u043d\u044f\u043a'), 'en': 'Vranyak'}, '35353':{'en': 'Wexford/Enniscorthy/Ferns/Gorey'}, '3344253':{'en': 'Rousset', 'fr': 'Rousset'}, '37423794':{'am': u('\u0544\u0561\u0580\u0563\u0561\u0580\u0561'), 'en': 'Margara', 'ru': u('\u041c\u0430\u0440\u0433\u0430\u0440\u0430')}, '37423796':{'am': u('\u054f\u0561\u0576\u0571\u0578\u0582\u057f'), 'en': 'Tandzut', 'ru': u('\u0422\u0430\u043d\u0434\u0437\u0443\u0442')}, '433185':{'de': 'Preding', 'en': 'Preding'}, '433184':{'de': 'Wolfsberg im Schwarzautal', 'en': 'Wolfsberg im Schwarzautal'}, '353404':{'en': 'Wicklow'}, '353402':{'en': 'Arklow'}, '433183':{'de': 'Sankt Georgen an der Stiefing', 'en': 'St. Georgen an der Stiefing'}, '433182':{'de': 'Wildon', 'en': 'Wildon'}, '441789':{'en': 'Stratford-upon-Avon'}, '3356323':{'en': 'Montauban', 'fr': 'Montauban'}, '3356321':{'en': 'Montauban', 'fr': 'Montauban'}, '3356320':{'en': 'Montauban', 'fr': 'Montauban'}, '3344258':{'en': 'Gardanne', 'fr': 'Gardanne'}, '3356329':{'en': 'Valence', 'fr': 'Valence'}, '3344259':{'en': 'Aix-en-Provence', 'fr': 'Aix-en-Provence'}, '35971306':{'bg': u('\u0420\u0430\u0448\u043a\u043e\u0432\u043e'), 'en': 'Rashkovo'}, '3332529':{'en': 'Bar-sur-Seine', 'fr': 'Bar-sur-Seine'}, '3347466':{'en': 'Belleville', 'fr': 'Belleville'}, '3347464':{'en': 'Thizy', 'fr': 'Thizy'}, '3347465':{'en': u('Villefranche-sur-Sa\u00f4ne'), 'fr': u('Villefranche-sur-Sa\u00f4ne')}, '3347462':{'en': u('Villefranche-sur-Sa\u00f4ne'), 'fr': u('Villefranche-sur-Sa\u00f4ne')}, '3347463':{'en': 'Tarare', 'fr': 'Tarare'}, '3347460':{'en': u('Villefranche-sur-Sa\u00f4ne'), 'fr': u('Villefranche-sur-Sa\u00f4ne')}, '3347461':{'en': 'Meximieux', 'fr': 'Meximieux'}, '3347468':{'en': u('Villefranche-sur-Sa\u00f4ne'), 'fr': u('Villefranche-sur-Sa\u00f4ne')}, '3595579':{'bg': u('\u0412\u0435\u0434\u0440\u043e\u0432\u043e'), 'en': 'Vedrovo'}, '3595578':{'bg': u('\u0422\u0435\u0440\u0437\u0438\u0439\u0441\u043a\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Terziysko, Burgas'}, '441590':{'en': 'Lymington'}, '3595575':{'bg': u('\u041f\u0440\u0438\u043b\u0435\u043f, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Prilep, Burgas'}, '3595574':{'bg': u('\u0421\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Saedinenie, Burgas'}, '3595577':{'bg': u('\u041f\u043e\u0434\u0432\u0438\u0441, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Podvis, Burgas'}, '3595576':{'bg': u('\u041b\u043e\u0437\u0430\u0440\u0435\u0432\u043e'), 'en': 'Lozarevo'}, '3595571':{'bg': u('\u0421\u0443\u043d\u0433\u0443\u0440\u043b\u0430\u0440\u0435'), 'en': 'Sungurlare'}, '3595570':{'bg': u('\u041c\u0430\u043d\u043e\u043b\u0438\u0447'), 'en': 'Manolich'}, '3595573':{'bg': u('\u0412\u0435\u0437\u0435\u043d\u043a\u043e\u0432\u043e'), 'en': 'Vezenkovo'}, '3595572':{'bg': u('\u0411\u0435\u0440\u043e\u043d\u043e\u0432\u043e'), 'en': 'Beronovo'}, '3596004':{'bg': u('\u041c\u0430\u043a\u043e\u0432\u043e'), 'en': 'Makovo'}, '3596006':{'bg': u('\u041f\u0440\u0435\u0441\u0438\u044f\u043d'), 'en': 'Presian'}, '3596007':{'bg': u('\u0420\u0430\u043b\u0438\u0446\u0430'), 'en': 'Ralitsa'}, '3596001':{'bg': u('\u0427\u0435\u0440\u043a\u043e\u0432\u043d\u0430, \u0422\u044a\u0440\u0433.'), 'en': 'Cherkovna, Targ.'}, '3596002':{'bg': u('\u0421\u044a\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435, \u0422\u044a\u0440\u0433.'), 'en': 'Saedinenie, Targ.'}, '3596003':{'bg': u('\u041f\u0440\u0435\u0441\u0435\u043b\u0435\u0446'), 'en': 'Preselets'}, '3347790':{'en': u('Roche-la-Moli\u00e8re'), 'fr': u('Roche-la-Moli\u00e8re')}, '3347791':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347792':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347793':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347795':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '3347796':{'en': 'Montbrison', 'fr': 'Montbrison'}, '3599726':{'bg': u('\u0417\u0430\u043c\u0444\u0438\u0440'), 'en': 'Zamfir'}, '3324169':{'en': u('Avrill\u00e9'), 'fr': u('Avrill\u00e9')}, '359650':{'bg': u('\u041b\u0435\u0432\u0441\u043a\u0438, \u041f\u043b\u0435\u0432\u0435\u043d'), 'en': 'Levski, Pleven'}, '359658':{'bg': u('\u0411\u0435\u043b\u0435\u043d\u0435'), 'en': 'Belene'}, '359659':{'bg': u('\u0427\u0435\u0440\u0432\u0435\u043d \u0431\u0440\u044f\u0433'), 'en': 'Cherven bryag'}, '441754':{'en': 'Skegness'}, '441757':{'en': 'Selby'}, '441756':{'en': 'Skipton'}, '441751':{'en': 'Pickering'}, '441750':{'en': 'Selkirk'}, '3597044':{'bg': u('\u0411\u0430\u0431\u0438\u043d\u043e'), 'en': 'Babino'}, '441752':{'en': 'Plymouth'}, '441759':{'en': 'Pocklington'}, '441758':{'en': 'Pwllheli'}, '39085':{'en': 'Pescara', 'it': 'Pescara'}, '3316480':{'en': 'Lognes', 'fr': 'Lognes'}, '3316486':{'en': 'Les Ulis', 'fr': 'Les Ulis'}, '3316487':{'en': 'Melun', 'fr': 'Melun'}, '3316488':{'en': 'Moissy-Cramayel', 'fr': 'Moissy-Cramayel'}, '3349020':{'en': 'L\'Isle sur la Sorgue', 'fr': 'L\'Isle sur la Sorgue'}, '3349021':{'en': 'L\'Isle sur la Sorgue', 'fr': 'L\'Isle sur la Sorgue'}, '3349022':{'en': u('Saint-Saturnin-l\u00e8s-Avignon'), 'fr': u('Saint-Saturnin-l\u00e8s-Avignon')}, '3349023':{'en': 'Caumont-sur-Durance', 'fr': 'Caumont-sur-Durance'}, '3349024':{'en': u('Ch\u00e2teaurenard'), 'fr': u('Ch\u00e2teaurenard')}, '3349025':{'en': u('Villeneuve-l\u00e8s-Avignon'), 'fr': u('Villeneuve-l\u00e8s-Avignon')}, '3349026':{'en': 'Pujaut', 'fr': 'Pujaut'}, '3349027':{'en': 'Avignon', 'fr': 'Avignon'}, '3349028':{'en': 'Vaison-la-Romaine', 'fr': 'Vaison-la-Romaine'}, '3349029':{'en': 'Piolenc', 'fr': 'Piolenc'}, '39080':{'en': 'Bari', 'it': 'Bari'}, '436588':{'de': 'Lofer', 'en': 'Lofer'}, '436589':{'de': 'Unken', 'en': 'Unken'}, '436582':{'de': 'Saalfelden am Steinernen Meer', 'en': 'Saalfelden am Steinernen Meer'}, '436583':{'de': 'Leogang', 'en': 'Leogang'}, '436584':{'de': 'Maria Alm am Steinernen Meer', 'en': 'Maria Alm am Steinernen Meer'}, '3342764':{'en': u('Saint-\u00c9tienne'), 'fr': u('Saint-\u00c9tienne')}, '374254':{'am': u('\u054f\u0561\u0577\u056b\u0580'), 'en': 'Tashir', 'ru': u('\u0422\u0430\u0448\u0438\u0440')}, '390828':{'it': 'Battipaglia'}, '3323586':{'en': 'Eu', 'fr': 'Eu'}, '3349977':{'en': 'Montpellier', 'fr': 'Montpellier'}, '3349974':{'en': 'Montpellier', 'fr': 'Montpellier'}, '390823':{'en': 'Caserta', 'it': 'Caserta'}, '390824':{'en': 'Benevento', 'it': 'Benevento'}, '390825':{'en': 'Avellino', 'it': 'Avellino'}, '390827':{'it': 'Sant\'Angelo dei Lombardi'}, '441342':{'en': 'East Grinstead'}, '441343':{'en': 'Elgin'}, '441340':{'en': 'Craigellachie (Aberlour)'}, '441341':{'en': 'Barmouth'}, '441346':{'en': 'Fraserburgh'}, '441347':{'en': 'Easingwold'}, '441344':{'en': 'Bracknell'}, '441348':{'en': 'Fishguard'}, '441349':{'en': 'Dingwall'}, '40249':{'en': 'Olt', 'ro': 'Olt'}, '3751719':{'be': u('\u041a\u0430\u043f\u044b\u043b\u044c, \u041c\u0456\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Kopyl, Minsk Region', 'ru': u('\u041a\u043e\u043f\u044b\u043b\u044c, \u041c\u0438\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751718':{'be': u('\u0423\u0437\u0434\u0430, \u041c\u0456\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Uzda, Minsk Region', 'ru': u('\u0423\u0437\u0434\u0430, \u041c\u0438\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751717':{'be': u('\u0421\u0442\u0430\u045e\u0431\u0446\u044b'), 'en': 'Stolbtsy', 'ru': u('\u0421\u0442\u043e\u043b\u0431\u0446\u044b')}, '3751716':{'be': u('\u0414\u0437\u044f\u0440\u0436\u044b\u043d\u0441\u043a'), 'en': 'Dzerzhinsk', 'ru': u('\u0414\u0437\u0435\u0440\u0436\u0438\u043d\u0441\u043a')}, '3751715':{'be': u('\u0411\u0435\u0440\u0430\u0437\u0456\u043d\u043e, \u041c\u0456\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Berezino, Minsk Region', 'ru': u('\u0411\u0435\u0440\u0435\u0437\u0438\u043d\u043e, \u041c\u0438\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3751714':{'be': u('\u0427\u044d\u0440\u0432\u0435\u043d\u044c'), 'en': 'Cherven', 'ru': u('\u0427\u0435\u0440\u0432\u0435\u043d\u044c')}, '3751713':{'be': u('\u041c\u0430\u0440\u2019\u0456\u043d\u0430 \u0413\u043e\u0440\u043a\u0430, \u041c\u0456\u043d\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Maryina Gorka, Minsk Region', 'ru': u('\u041c\u0430\u0440\u044c\u0438\u043d\u0430 \u0413\u043e\u0440\u043a\u0430, \u041c\u0438\u043d\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '333260':{'en': 'Reims', 'fr': 'Reims'}, '3323110':{'en': 'Bayeux', 'fr': 'Bayeux'}, '3323114':{'en': 'Deauville', 'fr': 'Deauville'}, '3323115':{'en': 'Caen', 'fr': 'Caen'}, '3752353':{'be': u('\u0416\u044b\u0442\u043a\u0430\u0432\u0456\u0447\u044b, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Zhitkovichi, Gomel Region', 'ru': u('\u0416\u0438\u0442\u043a\u043e\u0432\u0438\u0447\u0438, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752350':{'be': u('\u041f\u0435\u0442\u0440\u044b\u043a\u0430\u045e, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Petrikov, Gomel Region', 'ru': u('\u041f\u0435\u0442\u0440\u0438\u043a\u043e\u0432, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752356':{'be': u('\u041b\u0435\u043b\u044c\u0447\u044b\u0446\u044b, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Lelchitsy, Gomel Region', 'ru': u('\u041b\u0435\u043b\u044c\u0447\u0438\u0446\u044b, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3752357':{'be': u('\u0410\u043a\u0446\u044f\u0431\u0440\u0441\u043a\u0456, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Oktyabrskiy, Gomel Region', 'ru': u('\u041e\u043a\u0442\u044f\u0431\u0440\u044c\u0441\u043a\u0438\u0439, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '334961':{'en': 'Marseille', 'fr': 'Marseille'}, '3752355':{'be': u('\u041d\u0430\u0440\u043e\u045e\u043b\u044f, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Narovlya, Gomel Region', 'ru': u('\u041d\u0430\u0440\u043e\u0432\u043b\u044f, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3332088':{'en': 'Lille', 'fr': 'Lille'}, '3332089':{'en': u('Marcq-en-Bar\u0153ul'), 'fr': u('Marcq-en-Bar\u0153ul')}, '3332080':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332081':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332082':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332083':{'en': 'Roubaix', 'fr': 'Roubaix'}, '3332085':{'en': u('Ann\u0153ullin'), 'fr': u('Ann\u0153ullin')}, '432773':{'de': 'Eichgraben', 'en': 'Eichgraben'}, '3332087':{'en': 'Lesquin', 'fr': 'Lesquin'}, '3355366':{'en': 'Agen', 'fr': 'Agen'}, '3355364':{'en': 'Marmande', 'fr': 'Marmande'}, '3355365':{'en': u('N\u00e9rac'), 'fr': u('N\u00e9rac')}, '3355363':{'en': 'Bergerac', 'fr': 'Bergerac'}, '3355361':{'en': 'Bergerac', 'fr': 'Bergerac'}, '3355369':{'en': 'Agen', 'fr': 'Agen'}, '3354945':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354944':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354947':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354946':{'en': 'Poitiers', 'fr': 'Poitiers'}, '3354941':{'en': 'Poitiers', 'fr': 'Poitiers'}, '441963':{'en': 'Wincanton'}, '3354943':{'en': 'Vivonne', 'fr': 'Vivonne'}, '3354949':{'en': 'Chasseneuil-du-Poitou', 'fr': 'Chasseneuil-du-Poitou'}, '441968':{'en': 'Penicuik'}, '441969':{'en': 'Leyburn'}, '3359068':{'en': 'Les Abymes', 'fr': 'Les Abymes'}, '3359060':{'en': 'Baie Mahault', 'fr': 'Baie Mahault'}, '3332556':{'en': 'Saint-Dizier', 'fr': 'Saint-Dizier'}, '3593528':{'bg': u('\u0413\u043e\u0432\u0435\u0434\u0430\u0440\u0435'), 'en': 'Govedare'}, '3593529':{'bg': u('\u041c\u043e\u043a\u0440\u0438\u0449\u0435'), 'en': 'Mokrishte'}, '3593524':{'bg': u('\u0410\u043f\u0440\u0438\u043b\u0446\u0438, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Apriltsi, Pazardzhik'}, '3593526':{'bg': u('\u0414\u0438\u043d\u043a\u0430\u0442\u0430'), 'en': 'Dinkata'}, '3593527':{'bg': u('\u0410\u043b\u0435\u043a\u043e \u041a\u043e\u043d\u0441\u0442\u0430\u043d\u0442\u0438\u043d\u043e\u0432\u043e'), 'en': 'Aleko Konstantinovo'}, '3593520':{'bg': u('\u041c\u0438\u0440\u044f\u043d\u0446\u0438'), 'en': 'Miryantsi'}, '3593521':{'bg': u('\u0417\u0432\u044a\u043d\u0438\u0447\u0435\u0432\u043e'), 'en': 'Zvanichevo'}, '3593522':{'bg': u('\u0413\u0435\u043b\u0435\u043c\u0435\u043d\u043e\u0432\u043e'), 'en': 'Gelemenovo'}, '3593523':{'bg': u('\u0421\u0438\u043d\u0438\u0442\u0435\u0432\u043e'), 'en': 'Sinitevo'}, '37423498':{'am': u('\u054f\u0561\u0583\u0565\u0580\u0561\u056f\u0561\u0576'), 'en': 'Taperakan', 'ru': u('\u0422\u0430\u043f\u0435\u0440\u0430\u043a\u0430\u043d')}, '37423492':{'am': u('\u0544\u0561\u0580\u057f\u056b\u0580\u0578\u057d\u0575\u0561\u0576'), 'en': 'Martirosyan', 'ru': u('\u041c\u0430\u0440\u0442\u0438\u0440\u043e\u0441\u044f\u043d')}, '37423497':{'am': u('\u0553\u0578\u0584\u0580 \u054e\u0565\u0564\u056b'), 'en': 'Pokr Vedi', 'ru': u('\u041f\u043e\u043a\u0440 \u0412\u0435\u0434\u0438')}, '3595967':{'bg': u('\u0411\u0430\u0442\u0430'), 'en': 'Bata'}, '3595968':{'bg': u('\u041a\u0430\u0431\u043b\u0435\u0448\u043a\u043e\u0432\u043e, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Kableshkovo, Burgas'}, '3595969':{'bg': u('\u0413\u044a\u043b\u044a\u0431\u0435\u0446, \u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Galabets, Burgas'}, '46227':{'en': u('Kungs\u00f6r'), 'sv': u('Kungs\u00f6r')}, '3341339':{'en': 'Avignon', 'fr': 'Avignon'}, '35947353':{'bg': u('\u0411\u044a\u043b\u0433\u0430\u0440\u0441\u043a\u0430 \u043f\u043e\u043b\u044f\u043d\u0430'), 'en': 'Balgarska polyana'}, '3355890':{'en': 'Dax', 'fr': 'Dax'}, '3355891':{'en': u('Saint-Paul-l\u00e8s-Dax'), 'fr': u('Saint-Paul-l\u00e8s-Dax')}, '3355897':{'en': 'Mugron', 'fr': 'Mugron'}, '3593748':{'bg': u('\u041b\u044f\u0441\u043a\u043e\u0432\u0435\u0446, \u0425\u0430\u0441\u043a.'), 'en': 'Lyaskovets, Hask.'}, '3593749':{'bg': u('\u0413\u0430\u0440\u0432\u0430\u043d\u043e\u0432\u043e'), 'en': 'Garvanovo'}, '46224':{'en': 'Sala-Heby', 'sv': 'Sala-Heby'}, '3332336':{'en': 'Ham', 'fr': 'Ham'}, '3593740':{'bg': u('\u041f\u0447\u0435\u043b\u0430\u0440\u0438'), 'en': 'Pchelari'}, '3593741':{'bg': u('\u041c\u0430\u043d\u0434\u0440\u0430'), 'en': 'Mandra'}, '3332338':{'en': 'Chauny', 'fr': 'Chauny'}, '3332339':{'en': 'Chauny', 'fr': 'Chauny'}, '3593744':{'bg': u('\u0421\u044a\u0440\u043d\u0438\u0446\u0430, \u0425\u0430\u0441\u043a.'), 'en': 'Sarnitsa, Hask.'}, '3593745':{'bg': u('\u041c\u0430\u043b\u044a\u043a \u0438\u0437\u0432\u043e\u0440, \u0425\u0430\u0441\u043a.'), 'en': 'Malak izvor, Hask.'}, '3324944':{'en': 'Nantes', 'fr': 'Nantes'}, '3593747':{'bg': u('\u0422\u0430\u0442\u0430\u0440\u0435\u0432\u043e, \u0425\u0430\u0441\u043a.'), 'en': 'Tatarevo, Hask.'}, '35947354':{'bg': u('\u041a\u0430\u043c\u0435\u043d\u043d\u0430 \u0440\u0435\u043a\u0430'), 'en': 'Kamenna reka'}, '46220':{'en': 'Hallstahammar-Surahammar', 'sv': 'Hallstahammar-Surahammar'}, '3349560':{'en': u('L\'\u00cele-Rousse'), 'fr': u('L\'\u00cele-Rousse')}, '3334488':{'en': 'Nanteuil-le-Haudouin', 'fr': 'Nanteuil-le-Haudouin'}, '3334483':{'en': u('Margny-l\u00e8s-Compi\u00e8gne'), 'fr': u('Margny-l\u00e8s-Compi\u00e8gne')}, '3334486':{'en': u('Compi\u00e8gne'), 'fr': u('Compi\u00e8gne')}, '3334487':{'en': u('Cr\u00e9py-en-Valois'), 'fr': u('Cr\u00e9py-en-Valois')}, '35941339':{'bg': u('\u0414\u0438\u043c\u0438\u0442\u0440\u0438\u0435\u0432\u043e'), 'en': 'Dimitrievo'}, '3355908':{'en': 'Saint-Jean-de-Luz', 'fr': 'Saint-Jean-de-Luz'}, '441508':{'en': 'Brooke'}, '441509':{'en': 'Loughborough'}, '4415392':{'en': 'Kendal'}, '3355678':{'en': 'Cestas', 'fr': 'Cestas'}, '441502':{'en': 'Lowestoft'}, '441503':{'en': 'Looe'}, '441505':{'en': 'Johnstone'}, '441506':{'en': 'Bathgate'}, '3323331':{'en': u('Alen\u00e7on'), 'fr': u('Alen\u00e7on')}, '35960373':{'bg': u('\u041f\u043e\u0441\u0430\u0431\u0438\u043d\u0430'), 'en': 'Posabina'}, '35960372':{'bg': u('\u041a\u0440\u0435\u043f\u0447\u0430'), 'en': 'Krepcha'}, '3596921':{'bg': u('\u0410\u0431\u043b\u0430\u043d\u0438\u0446\u0430, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Ablanitsa, Lovech'}, '35960370':{'bg': u('\u0413\u043e\u043b\u044f\u043c\u043e \u0433\u0440\u0430\u0434\u0438\u0449\u0435'), 'en': 'Golyamo gradishte'}, '35960377':{'bg': u('\u0410\u043f\u0440\u0438\u043b\u043e\u0432\u043e, \u0422\u044a\u0440\u0433.'), 'en': 'Aprilovo, Targ.'}, '35960376':{'bg': u('\u041b\u044e\u0431\u043b\u0435\u043d'), 'en': 'Lyublen'}, '35960375':{'bg': u('\u0413\u044a\u0440\u0447\u0438\u043d\u043e\u0432\u043e'), 'en': 'Garchinovo'}, '35960374':{'bg': u('\u0413\u043e\u0440\u0441\u043a\u043e \u0410\u0431\u043b\u0430\u043d\u043e\u0432\u043e'), 'en': 'Gorsko Ablanovo'}, '3596929':{'bg': u('\u0420\u0430\u0434\u044e\u0432\u0435\u043d\u0435'), 'en': 'Radyuvene'}, '35960378':{'bg': u('\u0426\u0430\u0440 \u0410\u0441\u0435\u043d, \u0422\u044a\u0440\u0433.'), 'en': 'Tsar Asen, Targ.'}, '3329835':{'en': u('Quimperl\u00e9'), 'fr': u('Quimperl\u00e9')}, '35956':{'bg': u('\u0411\u0443\u0440\u0433\u0430\u0441'), 'en': 'Burgas'}, '3329834':{'en': 'Brest', 'fr': 'Brest'}, '35958':{'bg': u('\u0414\u043e\u0431\u0440\u0438\u0447'), 'en': 'Dobrich'}, '3355676':{'en': 'Langon', 'fr': 'Langon'}, '3595742':{'bg': u('\u0420\u0430\u043a\u043e\u0432\u0441\u043a\u0438, \u0414\u043e\u0431\u0440.'), 'en': 'Rakovski, Dobr.'}, '3595743':{'bg': u('\u0428\u0430\u0431\u043b\u0430'), 'en': 'Shabla'}, '3595740':{'bg': u('\u0413\u043e\u0440\u0438\u0447\u0430\u043d\u0435'), 'en': 'Gorichane'}, '3355677':{'en': u('Ambar\u00e8s-et-Lagrave'), 'fr': u('Ambar\u00e8s-et-Lagrave')}, '3595746':{'bg': u('\u0411\u0435\u043b\u0433\u0443\u043d'), 'en': 'Belgun'}, '3595747':{'bg': u('\u0412\u0430\u043a\u043b\u0438\u043d\u043e'), 'en': 'Vaklino'}, '3595745':{'bg': u('\u0412\u0440\u0430\u043d\u0438\u043d\u043e'), 'en': 'Vranino'}, '3347633':{'en': u('\u00c9chirolles'), 'fr': u('\u00c9chirolles')}, '3355906':{'en': u('Juran\u00e7on'), 'fr': u('Juran\u00e7on')}, '3595748':{'bg': u('\u0414\u0443\u0440\u0430\u043d\u043a\u0443\u043b\u0430\u043a'), 'en': 'Durankulak'}, '3595749':{'bg': u('\u041a\u0440\u0430\u043f\u0435\u0446, \u0414\u043e\u0431\u0440.'), 'en': 'Krapets, Dobr.'}, '3347637':{'en': 'Le Pont de Beauvoisin', 'fr': 'Le Pont de Beauvoisin'}, '3347636':{'en': 'Vinay', 'fr': 'Vinay'}, '3347635':{'en': 'Moirans', 'fr': 'Moirans'}, '3355905':{'en': 'Laruns', 'fr': 'Laruns'}, '3338028':{'en': 'Dijon', 'fr': 'Dijon'}, '3338029':{'en': 'Brazey-en-Plaine', 'fr': 'Brazey-en-Plaine'}, '3324050':{'en': 'Nantes', 'fr': 'Nantes'}, '3338022':{'en': 'Beaune', 'fr': 'Beaune'}, '3324053':{'en': 'Saint-Nazaire', 'fr': 'Saint-Nazaire'}, '3338024':{'en': 'Beaune', 'fr': 'Beaune'}, '3338025':{'en': 'Beaune', 'fr': 'Beaune'}, '3338027':{'en': 'Auxonne', 'fr': 'Auxonne'}, '3346652':{'en': u('Al\u00e8s'), 'fr': u('Al\u00e8s')}, '3742675':{'am': u('\u0531\u0580\u056e\u057e\u0561\u0562\u0565\u0580\u0564'), 'en': 'Artsvaberd', 'ru': u('\u0410\u0440\u0446\u0432\u0430\u0431\u0435\u0440\u0434')}, '355893':{'en': u('Ksamil, Sarand\u00eb')}, '3597520':{'bg': u('\u041a\u043e\u0440\u043d\u0438\u0446\u0430'), 'en': 'Kornitsa'}, '3597521':{'bg': u('\u041a\u043e\u043f\u0440\u0438\u0432\u043b\u0435\u043d'), 'en': 'Koprivlen'}, '3597522':{'bg': u('\u0414\u044a\u0431\u043d\u0438\u0446\u0430'), 'en': 'Dabnitsa'}, '3597523':{'bg': u('\u0413\u044a\u0440\u043c\u0435\u043d'), 'en': 'Garmen'}, '3597524':{'bg': u('\u0410\u0431\u043b\u0430\u043d\u0438\u0446\u0430, \u0411\u043b\u0430\u0433.'), 'en': 'Ablanitsa, Blag.'}, '3597525':{'bg': u('\u0411\u0430\u043d\u0438\u0447\u0430\u043d'), 'en': 'Banichan'}, '3597526':{'bg': u('\u0420\u0438\u0431\u043d\u043e\u0432\u043e'), 'en': 'Ribnovo'}, '3597527':{'bg': u('\u0413\u043e\u0440\u043d\u043e \u0414\u0440\u044f\u043d\u043e\u0432\u043e'), 'en': 'Gorno Dryanovo'}, '3597528':{'bg': u('\u0425\u0430\u0434\u0436\u0438\u0434\u0438\u043c\u043e\u0432\u043e'), 'en': 'Hadzhidimovo'}, '3597529':{'bg': u('\u0411\u0440\u0435\u0437\u043d\u0438\u0446\u0430'), 'en': 'Breznitsa'}, '373248':{'en': 'Criuleni', 'ro': 'Criuleni', 'ru': u('\u041a\u0440\u0438\u0443\u043b\u0435\u043d\u044c')}, '3329668':{'en': 'Saint-Brieuc', 'fr': 'Saint-Brieuc'}, '3329669':{'en': 'Binic', 'fr': 'Binic'}, '3593030':{'bg': u('\u0428\u0438\u0440\u043e\u043a\u0430 \u043b\u044a\u043a\u0430'), 'en': 'Shiroka laka'}, '3329660':{'en': 'Saint-Brieuc', 'fr': 'Saint-Brieuc'}, '3329661':{'en': 'Saint-Brieuc', 'fr': 'Saint-Brieuc'}, '3329662':{'en': 'Saint-Brieuc', 'fr': 'Saint-Brieuc'}, '3329663':{'en': u('Pl\u00e9neuf-Val-Andr\u00e9'), 'fr': u('Pl\u00e9neuf-Val-Andr\u00e9')}, '3329664':{'en': u('Pl\u00e9dran'), 'fr': u('Pl\u00e9dran')}, '3329665':{'en': 'Lanvollon', 'fr': 'Lanvollon'}, '3329666':{'en': u('Loud\u00e9ac'), 'fr': u('Loud\u00e9ac')}, '4415240':{'en': 'Lancaster'}, '3346651':{'en': 'Le Grau du Roi', 'fr': 'Le Grau du Roi'}, '4414309':{'en': 'Market Weighton'}, '4414308':{'en': 'Market Weighton'}, '43662':{'de': 'Salzburg', 'en': 'Salzburg'}, '35935393':{'bg': u('\u0421\u043c\u0438\u043b\u0435\u0446, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Smilets, Pazardzhik'}, '35935392':{'bg': u('\u0414\u044e\u043b\u0435\u0432\u043e, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Dyulevo, Pazardzhik'}, '35935391':{'bg': u('\u0411\u043b\u0430\u0442\u043d\u0438\u0446\u0430'), 'en': 'Blatnitsa'}, '4414302':{'en': 'North Cave'}, '4414305':{'en': 'North Cave'}, '4414304':{'en': 'North Cave'}, '4414307':{'en': 'Market Weighton'}, '35935394':{'bg': u('\u041e\u0431\u043e\u0440\u0438\u0449\u0435, \u041f\u0430\u0437\u0430\u0440\u0434\u0436\u0438\u043a'), 'en': 'Oborishte, Pazardzhik'}, '3596142':{'bg': u('\u041e\u0431\u0435\u0434\u0438\u043d\u0435\u043d\u0438\u0435'), 'en': 'Obedinenie'}, '37422453':{'am': u('\u054a\u057c\u0578\u0577\u0575\u0561\u0576'), 'en': 'Proshyan', 'ru': u('\u041f\u0440\u043e\u0448\u044f\u043d')}, '37422452':{'am': u('\u0536\u0578\u057e\u0578\u0582\u0576\u056b'), 'en': 'Zovuni', 'ru': u('\u0417\u043e\u0432\u0443\u043d\u0438')}, '37422454':{'am': u('\u0531\u0580\u0563\u0565\u056c'), 'en': 'Argel', 'ru': u('\u0410\u0440\u0433\u0435\u043b')}, '35967193':{'bg': u('\u041a\u043c\u0435\u0442\u043e\u0432\u0446\u0438'), 'en': 'Kmetovtsi'}, '35967194':{'bg': u('\u0413\u0440\u044a\u0431\u043b\u0435\u0432\u0446\u0438'), 'en': 'Grablevtsi'}, '3596148':{'bg': u('\u041f\u0430\u0432\u0435\u043b'), 'en': 'Pavel'}, '441838':{'en': 'Dalmally'}, '442880':{'en': 'Carrickmore'}, '442881':{'en': 'Newtownstewart'}, '442882':{'en': 'Omagh'}, '442837':{'en': 'Armagh'}, '442886':{'en': 'Cookstown'}, '442887':{'en': 'Dungannon'}, '442830':{'en': 'Newry'}, '3328537':{'en': 'Nantes', 'fr': 'Nantes'}, '3323255':{'en': 'Gisors', 'fr': 'Gisors'}, '3323254':{'en': 'Les Andelys', 'fr': 'Les Andelys'}, '3323253':{'en': 'Gaillon', 'fr': 'Gaillon'}, '3323251':{'en': 'Vernon', 'fr': 'Vernon'}, '3323250':{'en': 'Louviers', 'fr': 'Louviers'}, '3323259':{'en': 'Val-de-Reuil', 'fr': 'Val-de-Reuil'}, '3323258':{'en': 'Nonancourt', 'fr': 'Nonancourt'}, '3593198':{'bg': u('\u0427\u0435\u0445\u043b\u0430\u0440\u0435'), 'en': 'Chehlare'}, '37428375':{'am': u('\u0539\u0561\u057d\u056b\u056f'), 'en': 'Tasik', 'ru': u('\u0422\u0430\u0441\u0438\u043a')}, '3593195':{'bg': u('\u0420\u043e\u0437\u043e\u0432\u0435\u0446'), 'en': 'Rozovets'}, '3593194':{'bg': u('\u0417\u0435\u043b\u0435\u043d\u0438\u043a\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Zelenikovo, Plovdiv'}, '3593197':{'bg': u('\u0422\u044e\u0440\u043a\u043c\u0435\u043d'), 'en': 'Tyurkmen'}, '3593196':{'bg': u('\u0414\u0440\u0430\u043d\u0433\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Drangovo, Plovdiv'}, '3593191':{'bg': u('\u0411\u0440\u0435\u0437\u043e\u0432\u043e, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Brezovo, Plovdiv'}, '3593190':{'bg': u('\u0412\u044a\u0440\u0431\u0435\u043d, \u041f\u043b\u043e\u0432\u0434\u0438\u0432'), 'en': 'Varben, Plovdiv'}, '3593193':{'bg': u('\u0411\u043e\u0440\u0435\u0446'), 'en': 'Borets'}, '3593192':{'bg': u('\u0411\u0430\u0431\u0435\u043a'), 'en': 'Babek'}, '373242':{'en': 'Stefan Voda', 'ro': u('\u015etefan Vod\u0103'), 'ru': u('\u0428\u0442\u0435\u0444\u0430\u043d \u0412\u043e\u0434\u044d')}, '42133':{'en': 'Trnava'}, '42132':{'en': u('Tren\u010d\u00edn')}, '42131':{'en': u('Dunajsk\u00e1 Streda')}, '3354779':{'en': 'Bordeaux', 'fr': 'Bordeaux'}, '42137':{'en': 'Nitra'}, '42136':{'en': 'Levice'}, '42135':{'en': u('Nov\u00e9 Z\u00e1mky')}, '42134':{'en': 'Senica'}, '441287':{'en': 'Guisborough'}, '441286':{'en': 'Caernarfon'}, '441285':{'en': 'Cirencester'}, '42138':{'en': u('Topo\u013e\u010dany')}, '441283':{'en': 'Burton-on-Trent'}, '441282':{'en': 'Burnley'}, '441280':{'en': 'Buckingham'}, '3338826':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '3345008':{'en': 'Annecy', 'fr': 'Annecy'}, '3345009':{'en': 'Annecy-le-Vieux', 'fr': 'Annecy-le-Vieux'}, '3345007':{'en': 'Bonneville', 'fr': 'Bonneville'}, '3345005':{'en': 'Annecy', 'fr': 'Annecy'}, '3345002':{'en': u('Th\u00f4nes'), 'fr': u('Th\u00f4nes')}, '3345003':{'en': 'La Roche sur Foron', 'fr': 'La Roche sur Foron'}, '3338827':{'en': 'Strasbourg', 'fr': 'Strasbourg'}, '37322':{'en': 'Chisinau', 'ro': u('Chi\u015fin\u0103u'), 'ru': u('\u041a\u0438\u0448\u0438\u043d\u044d\u0443')}, '3348982':{'en': 'Cannes', 'fr': 'Cannes'}, '3596930':{'bg': u('\u0421\u043b\u0430\u0432\u0449\u0438\u0446\u0430'), 'en': 'Slavshtitsa'}, '3596931':{'bg': u('\u0423\u0433\u044a\u0440\u0447\u0438\u043d'), 'en': 'Ugarchin'}, '437954':{'de': 'Sankt Georgen am Walde', 'en': 'St. Georgen am Walde'}, '437955':{'de': u('K\u00f6nigswiesen'), 'en': u('K\u00f6nigswiesen')}, '437736':{'de': 'Pram', 'en': 'Pram'}, '437952':{'de': 'Weitersfelden', 'en': 'Weitersfelden'}, '437734':{'de': 'Hofkirchen an der Trattnach', 'en': 'Hofkirchen an der Trattnach'}, '437735':{'de': 'Gaspoltshofen', 'en': 'Gaspoltshofen'}, '437732':{'de': 'Haag am Hausruck', 'en': 'Haag am Hausruck'}, '437733':{'de': 'Neumarkt im Hausruckkreis', 'en': 'Neumarkt im Hausruckkreis'}, '3596935':{'bg': u('\u0421\u043e\u043f\u043e\u0442, \u041b\u043e\u0432\u0435\u0447'), 'en': 'Sopot, Lovech'}, '3349707':{'en': 'Nice', 'fr': 'Nice'}, '3317234':{'en': 'Paris', 'fr': 'Paris'}, '35971338':{'bg': u('\u041e\u0441\u0438\u043a\u043e\u0432\u0441\u043a\u0430 \u041b\u0430\u043a\u0430\u0432\u0438\u0446\u0430'), 'en': 'Osikovska Lakavitsa'}, '3325481':{'en': 'Mer', 'fr': 'Mer'}, '3325484':{'en': u('Buzan\u00e7ais'), 'fr': u('Buzan\u00e7ais')}, '3325485':{'en': 'Montoire-sur-le-Loir', 'fr': 'Montoire-sur-le-Loir'}, '3325487':{'en': 'Saint-Laurent-Nouan', 'fr': 'Saint-Laurent-Nouan'}, '3325488':{'en': 'Lamotte-Beuvron', 'fr': 'Lamotte-Beuvron'}, '3325489':{'en': u('Vend\u00f4me'), 'fr': u('Vend\u00f4me')}, '3752347':{'be': u('\u041b\u043e\u0435\u045e, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u0432\u043e\u0431\u043b\u0430\u0441\u0446\u044c'), 'en': 'Loyev, Gomel Region', 'ru': u('\u041b\u043e\u0435\u0432, \u0413\u043e\u043c\u0435\u043b\u044c\u0441\u043a\u0430\u044f \u043e\u0431\u043b\u0430\u0441\u0442\u044c')}, '3338239':{'en': 'Longuyon', 'fr': 'Longuyon'}, '3338234':{'en': 'Thionville', 'fr': 'Thionville'}, '3338233':{'en': 'Jarny', 'fr': 'Jarny'}, '359817':{'bg': u('\u0411\u044f\u043b\u0430, \u0420\u0443\u0441\u0435'), 'en': 'Byala, Ruse'}, '3356303':{'en': 'Montauban', 'fr': 'Montauban'}, '3356305':{'en': 'Moissac', 'fr': 'Moissac'}, '3356304':{'en': 'Moissac', 'fr': 'Moissac'}, '3349703':{'en': 'Nice', 'fr': 'Nice'}, '3347400':{'en': u('Tr\u00e9voux'), 'fr': u('Tr\u00e9voux')}, '3347402':{'en': u('Villefranche-sur-Sa\u00f4ne'), 'fr': u('Villefranche-sur-Sa\u00f4ne')}, '3347405':{'en': 'Tarare', 'fr': 'Tarare'}, '3347406':{'en': 'Belleville', 'fr': 'Belleville'}, '3347407':{'en': u('Villefranche-sur-Sa\u00f4ne'), 'fr': u('Villefranche-sur-Sa\u00f4ne')}, '3347408':{'en': u('Tr\u00e9voux'), 'fr': u('Tr\u00e9voux')}, '3347409':{'en': u('Villefranche-sur-Sa\u00f4ne'), 'fr': u('Villefranche-sur-Sa\u00f4ne')}, '434285':{'de': u('Tr\u00f6polach'), 'en': u('Tr\u00f6polach')}, '434284':{'de': 'Kirchbach', 'en': 'Kirchbach'}, '434283':{'de': 'Sankt Stefan im Gailtal', 'en': 'St. Stefan im Gailtal'}, '434282':{'de': 'Hermagor', 'en': 'Hermagor'}, '3341164':{'en': 'Perpignan', 'fr': 'Perpignan'}, }
bsd-3-clause
dannyperry571/theapprentice
script.module.beautifulsoup4/lib/bs4/builder/_lxml.py
446
8661
__all__ = [ 'LXMLTreeBuilderForXML', 'LXMLTreeBuilder', ] from io import BytesIO from StringIO import StringIO import collections from lxml import etree from bs4.element import Comment, Doctype, NamespacedAttribute from bs4.builder import ( FAST, HTML, HTMLTreeBuilder, PERMISSIVE, ParserRejectedMarkup, TreeBuilder, XML) from bs4.dammit import EncodingDetector LXML = 'lxml' class LXMLTreeBuilderForXML(TreeBuilder): DEFAULT_PARSER_CLASS = etree.XMLParser is_xml = True # Well, it's permissive by XML parser standards. features = [LXML, XML, FAST, PERMISSIVE] CHUNK_SIZE = 512 # This namespace mapping is specified in the XML Namespace # standard. DEFAULT_NSMAPS = {'http://www.w3.org/XML/1998/namespace' : "xml"} def default_parser(self, encoding): # This can either return a parser object or a class, which # will be instantiated with default arguments. if self._default_parser is not None: return self._default_parser return etree.XMLParser( target=self, strip_cdata=False, recover=True, encoding=encoding) def parser_for(self, encoding): # Use the default parser. parser = self.default_parser(encoding) if isinstance(parser, collections.Callable): # Instantiate the parser with default arguments parser = parser(target=self, strip_cdata=False, encoding=encoding) return parser def __init__(self, parser=None, empty_element_tags=None): # TODO: Issue a warning if parser is present but not a # callable, since that means there's no way to create new # parsers for different encodings. self._default_parser = parser if empty_element_tags is not None: self.empty_element_tags = set(empty_element_tags) self.soup = None self.nsmaps = [self.DEFAULT_NSMAPS] def _getNsTag(self, tag): # Split the namespace URL out of a fully-qualified lxml tag # name. Copied from lxml's src/lxml/sax.py. if tag[0] == '{': return tuple(tag[1:].split('}', 1)) else: return (None, tag) def prepare_markup(self, markup, user_specified_encoding=None, document_declared_encoding=None): """ :yield: A series of 4-tuples. (markup, encoding, declared encoding, has undergone character replacement) Each 4-tuple represents a strategy for parsing the document. """ if isinstance(markup, unicode): # We were given Unicode. Maybe lxml can parse Unicode on # this system? yield markup, None, document_declared_encoding, False if isinstance(markup, unicode): # No, apparently not. Convert the Unicode to UTF-8 and # tell lxml to parse it as UTF-8. yield (markup.encode("utf8"), "utf8", document_declared_encoding, False) # Instead of using UnicodeDammit to convert the bytestring to # Unicode using different encodings, use EncodingDetector to # iterate over the encodings, and tell lxml to try to parse # the document as each one in turn. is_html = not self.is_xml try_encodings = [user_specified_encoding, document_declared_encoding] detector = EncodingDetector(markup, try_encodings, is_html) for encoding in detector.encodings: yield (detector.markup, encoding, document_declared_encoding, False) def feed(self, markup): if isinstance(markup, bytes): markup = BytesIO(markup) elif isinstance(markup, unicode): markup = StringIO(markup) # Call feed() at least once, even if the markup is empty, # or the parser won't be initialized. data = markup.read(self.CHUNK_SIZE) try: self.parser = self.parser_for(self.soup.original_encoding) self.parser.feed(data) while len(data) != 0: # Now call feed() on the rest of the data, chunk by chunk. data = markup.read(self.CHUNK_SIZE) if len(data) != 0: self.parser.feed(data) self.parser.close() except (UnicodeDecodeError, LookupError, etree.ParserError), e: raise ParserRejectedMarkup(str(e)) def close(self): self.nsmaps = [self.DEFAULT_NSMAPS] def start(self, name, attrs, nsmap={}): # Make sure attrs is a mutable dict--lxml may send an immutable dictproxy. attrs = dict(attrs) nsprefix = None # Invert each namespace map as it comes in. if len(self.nsmaps) > 1: # There are no new namespaces for this tag, but # non-default namespaces are in play, so we need a # separate tag stack to know when they end. self.nsmaps.append(None) elif len(nsmap) > 0: # A new namespace mapping has come into play. inverted_nsmap = dict((value, key) for key, value in nsmap.items()) self.nsmaps.append(inverted_nsmap) # Also treat the namespace mapping as a set of attributes on the # tag, so we can recreate it later. attrs = attrs.copy() for prefix, namespace in nsmap.items(): attribute = NamespacedAttribute( "xmlns", prefix, "http://www.w3.org/2000/xmlns/") attrs[attribute] = namespace # Namespaces are in play. Find any attributes that came in # from lxml with namespaces attached to their names, and # turn then into NamespacedAttribute objects. new_attrs = {} for attr, value in attrs.items(): namespace, attr = self._getNsTag(attr) if namespace is None: new_attrs[attr] = value else: nsprefix = self._prefix_for_namespace(namespace) attr = NamespacedAttribute(nsprefix, attr, namespace) new_attrs[attr] = value attrs = new_attrs namespace, name = self._getNsTag(name) nsprefix = self._prefix_for_namespace(namespace) self.soup.handle_starttag(name, namespace, nsprefix, attrs) def _prefix_for_namespace(self, namespace): """Find the currently active prefix for the given namespace.""" if namespace is None: return None for inverted_nsmap in reversed(self.nsmaps): if inverted_nsmap is not None and namespace in inverted_nsmap: return inverted_nsmap[namespace] return None def end(self, name): self.soup.endData() completed_tag = self.soup.tagStack[-1] namespace, name = self._getNsTag(name) nsprefix = None if namespace is not None: for inverted_nsmap in reversed(self.nsmaps): if inverted_nsmap is not None and namespace in inverted_nsmap: nsprefix = inverted_nsmap[namespace] break self.soup.handle_endtag(name, nsprefix) if len(self.nsmaps) > 1: # This tag, or one of its parents, introduced a namespace # mapping, so pop it off the stack. self.nsmaps.pop() def pi(self, target, data): pass def data(self, content): self.soup.handle_data(content) def doctype(self, name, pubid, system): self.soup.endData() doctype = Doctype.for_name_and_ids(name, pubid, system) self.soup.object_was_parsed(doctype) def comment(self, content): "Handle comments as Comment objects." self.soup.endData() self.soup.handle_data(content) self.soup.endData(Comment) def test_fragment_to_document(self, fragment): """See `TreeBuilder`.""" return u'<?xml version="1.0" encoding="utf-8"?>\n%s' % fragment class LXMLTreeBuilder(HTMLTreeBuilder, LXMLTreeBuilderForXML): features = [LXML, HTML, FAST, PERMISSIVE] is_xml = False def default_parser(self, encoding): return etree.HTMLParser def feed(self, markup): encoding = self.soup.original_encoding try: self.parser = self.parser_for(encoding) self.parser.feed(markup) self.parser.close() except (UnicodeDecodeError, LookupError, etree.ParserError), e: raise ParserRejectedMarkup(str(e)) def test_fragment_to_document(self, fragment): """See `TreeBuilder`.""" return u'<html><body>%s</body></html>' % fragment
gpl-2.0
EUDAT-B2SHARE/invenio-old
modules/bibdocfile/lib/bibdocfilecli.py
6
60464
# -*- coding: utf-8 -*- ## ## This file is part of Invenio. ## Copyright (C) 2008, 2009, 2010, 2011, 2012 CERN. ## ## Invenio is free software; you can redistribute it and/or ## modify it under the terms of the GNU General Public License as ## published by the Free Software Foundation; either version 2 of the ## License, or (at your option) any later version. ## ## Invenio is distributed in the hope that it will be useful, but ## WITHOUT ANY WARRANTY; without even the implied warranty of ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU ## General Public License for more details. ## ## You should have received a copy of the GNU General Public License ## along with Invenio; if not, write to the Free Software Foundation, Inc., ## 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. """ BibDocAdmin CLI administration tool """ __revision__ = "$Id$" import sys import re import os import time import fnmatch import time from datetime import datetime from logging import getLogger, debug, DEBUG from optparse import OptionParser, OptionGroup, OptionValueError from tempfile import mkstemp from invenio.errorlib import register_exception from invenio.config import CFG_SITE_URL, CFG_BIBDOCFILE_FILEDIR, \ CFG_SITE_RECORD, CFG_TMPSHAREDDIR from invenio.bibdocfile import BibRecDocs, BibDoc, InvenioBibDocFileError, \ nice_size, check_valid_url, clean_url, get_docname_from_url, \ guess_format_from_url, KEEP_OLD_VALUE, decompose_bibdocfile_fullpath, \ bibdocfile_url_to_bibdoc, decompose_bibdocfile_url, CFG_BIBDOCFILE_AVAILABLE_FLAGS from invenio.intbitset import intbitset from invenio.search_engine import perform_request_search from invenio.textutils import wrap_text_in_a_box, wait_for_user from invenio.dbquery import run_sql from invenio.bibtask import task_low_level_submission from invenio.textutils import encode_for_xml from invenio.websubmit_file_converter import can_perform_ocr def _xml_mksubfield(key, subfield, fft): return fft.get(key, None) is not None and '\t\t<subfield code="%s">%s</subfield>\n' % (subfield, encode_for_xml(str(fft[key]))) or '' def _xml_mksubfields(key, subfield, fft): ret = "" for value in fft.get(key, []): ret += '\t\t<subfield code="%s">%s</subfield>\n' % (subfield, encode_for_xml(str(value))) return ret def _xml_fft_creator(fft): """Transform an fft dictionary (made by keys url, docname, format, new_docname, comment, description, restriction, doctype, into an xml string.""" debug('Input FFT structure: %s' % fft) out = '\t<datafield tag ="FFT" ind1=" " ind2=" ">\n' out += _xml_mksubfield('url', 'a', fft) out += _xml_mksubfield('docname', 'n', fft) out += _xml_mksubfield('format', 'f', fft) out += _xml_mksubfield('new_docname', 'm', fft) out += _xml_mksubfield('doctype', 't', fft) out += _xml_mksubfield('description', 'd', fft) out += _xml_mksubfield('comment', 'z', fft) out += _xml_mksubfield('restriction', 'r', fft) out += _xml_mksubfields('options', 'o', fft) out += _xml_mksubfield('version', 'v', fft) out += '\t</datafield>\n' debug('FFT created: %s' % out) return out def ffts_to_xml(ffts_dict): """Transform a dictionary: recid -> ffts where ffts is a list of fft dictionary into xml. """ debug('Input FFTs dictionary: %s' % ffts_dict) out = '' recids = ffts_dict.keys() recids.sort() for recid in recids: ffts = ffts_dict[recid] if ffts: out += '<record>\n' out += '\t<controlfield tag="001">%i</controlfield>\n' % recid for fft in ffts: out += _xml_fft_creator(fft) out += '</record>\n' debug('MARC to Upload: %s' % out) return out _shift_re = re.compile("([-\+]{0,1})([\d]+)([dhms])") def _parse_datetime(var): """Returns a date string according to the format string. It can handle normal date strings and shifts with respect to now.""" if not var: return None date = time.time() factors = {"d":24*3600, "h":3600, "m":60, "s":1} m = _shift_re.match(var) if m: sign = m.groups()[0] == "-" and -1 or 1 factor = factors[m.groups()[2]] value = float(m.groups()[1]) return datetime.fromtimestamp(date + sign * factor * value) else: return datetime(*(time.strptime(var, "%Y-%m-%d %H:%M:%S")[0:6])) # The code above is Python 2.4 compatible. The following is the 2.5 # version. # return datetime.strptime(var, "%Y-%m-%d %H:%M:%S") def _parse_date_range(var): """Returns the two dates contained as a low,high tuple""" limits = var.split(",") if len(limits)==1: low = _parse_datetime(limits[0]) return low, None if len(limits)==2: low = _parse_datetime(limits[0]) high = _parse_datetime(limits[1]) return low, high return None, None def cli_quick_match_all_recids(options): """Return an quickly an approximate but (by excess) list of good recids.""" url = getattr(options, 'url', None) if url: return intbitset([decompose_bibdocfile_url(url)[0]]) path = getattr(options, 'path', None) if path: docid = decompose_bibdocfile_fullpath(path)["doc_id"] bd = BibDoc(docid) ids = [] for rec_link in bd.bibrec_links: ids.append(rec_link["recid"]) return intbitset(ids) docids = getattr(options, 'docids', None) if docids: ids = [] for docid in docids: bd = BibDoc(docid) for rec_link in bd.bibrec_links: ids.append(rec_link["recid"]) return intbitset(ids) collection = getattr(options, 'collection', None) pattern = getattr(options, 'pattern', None) recids = getattr(options, 'recids', None) md_rec = getattr(options, 'md_rec', None) cd_rec = getattr(options, 'cd_rec', None) tmp_date_query = [] tmp_date_params = [] if recids is None: debug('Initially considering all the recids') recids = intbitset(run_sql('SELECT id FROM bibrec')) if not recids: print >> sys.stderr, 'WARNING: No record in the database' if md_rec[0] is not None: tmp_date_query.append('modification_date>=%s') tmp_date_params.append(md_rec[0]) if md_rec[1] is not None: tmp_date_query.append('modification_date<=%s') tmp_date_params.append(md_rec[1]) if cd_rec[0] is not None: tmp_date_query.append('creation_date>=%s') tmp_date_params.append(cd_rec[0]) if cd_rec[1] is not None: tmp_date_query.append('creation_date<=%s') tmp_date_params.append(cd_rec[1]) if tmp_date_query: tmp_date_query = ' AND '.join(tmp_date_query) tmp_date_params = tuple(tmp_date_params) query = 'SELECT id FROM bibrec WHERE %s' % tmp_date_query debug('Query: %s, param: %s' % (query, tmp_date_params)) recids &= intbitset(run_sql(query % tmp_date_query, tmp_date_params)) debug('After applying dates we obtain recids: %s' % recids) if not recids: print >> sys.stderr, 'WARNING: Time constraints for records are too strict' if collection or pattern: recids &= intbitset(perform_request_search(cc=collection or '', p=pattern or '')) debug('After applyings pattern and collection we obtain recids: %s' % recids) debug('Quick recids: %s' % recids) return recids def cli_quick_match_all_docids(options, recids=None): """Return an quickly an approximate but (by excess) list of good docids.""" url = getattr(options, 'url', None) if url: return intbitset([bibdocfile_url_to_bibdoc(url).get_id()]) path = getattr(options, 'path', None) if path: docid = decompose_bibdocfile_fullpath(path)["doc_id"] bd = BibDoc(docid) ids = [] for rec_link in bd.bibrec_links: ids.append(rec_link["recid"]) return intbitset(ids) deleted_docs = getattr(options, 'deleted_docs', None) action_undelete = getattr(options, 'action', None) == 'undelete' docids = getattr(options, 'docids', None) md_doc = getattr(options, 'md_doc', None) cd_doc = getattr(options, 'cd_doc', None) if docids is None: debug('Initially considering all the docids') if recids is None: recids = cli_quick_match_all_recids(options) docids = intbitset() for id_bibrec, id_bibdoc in run_sql('SELECT id_bibrec, id_bibdoc FROM bibrec_bibdoc'): if id_bibrec in recids: docids.add(id_bibdoc) else: debug('Initially considering this docids: %s' % docids) tmp_query = [] tmp_params = [] if deleted_docs is None and action_undelete: deleted_docs = 'only' if deleted_docs == 'no': tmp_query.append('status<>"DELETED"') elif deleted_docs == 'only': tmp_query.append('status="DELETED"') if md_doc[0] is not None: tmp_query.append('modification_date>=%s') tmp_params.append(md_doc[0]) if md_doc[1] is not None: tmp_query.append('modification_date<=%s') tmp_params.append(md_doc[1]) if cd_doc[0] is not None: tmp_query.append('creation_date>=%s') tmp_params.append(cd_doc[0]) if cd_doc[1] is not None: tmp_query.append('creation_date<=%s') tmp_params.append(cd_doc[1]) if tmp_query: tmp_query = ' AND '.join(tmp_query) tmp_params = tuple(tmp_params) query = 'SELECT id FROM bibdoc WHERE %s' % tmp_query debug('Query: %s, param: %s' % (query, tmp_params)) docids &= intbitset(run_sql(query, tmp_params)) debug('After applying dates we obtain docids: %s' % docids) return docids def cli_slow_match_single_recid(options, recid, docids=None): """Apply all the given queries in order to assert wethever a recid match or not. if with_docids is True, the recid is matched if it has at least one docid that is matched""" debug('cli_slow_match_single_recid checking: %s' % recid) deleted_docs = getattr(options, 'deleted_docs', None) deleted_recs = getattr(options, 'deleted_recs', None) empty_recs = getattr(options, 'empty_recs', None) docname = cli2docname(options) bibrecdocs = BibRecDocs(recid, deleted_too=(deleted_docs != 'no')) if bibrecdocs.deleted_p() and (deleted_recs == 'no'): return False elif not bibrecdocs.deleted_p() and (deleted_recs != 'only'): if docids: for bibdoc in bibrecdocs.list_bibdocs(): if bibdoc.get_id() in docids: break else: return False if docname: for other_docname in bibrecdocs.get_bibdoc_names(): if docname and fnmatch.fnmatchcase(other_docname, docname): break else: return False if bibrecdocs.empty_p() and (empty_recs != 'no'): return True elif not bibrecdocs.empty_p() and (empty_recs != 'only'): return True return False def cli_slow_match_single_docid(options, docid, recids=None): """Apply all the given queries in order to assert wethever a recid match or not.""" debug('cli_slow_match_single_docid checking: %s' % docid) empty_docs = getattr(options, 'empty_docs', None) docname = cli2docname(options) if recids is None: recids = cli_quick_match_all_recids(options) bibdoc = BibDoc.create_instance(docid) dn = None if bibdoc.bibrec_links: dn = bibdoc.bibrec_links[0]["docname"] if docname and not fnmatch.fnmatchcase(dn, docname): debug('docname %s does not match the pattern %s' % (repr(dn), repr(docname))) return False # elif bibdoc.get_recid() and bibdoc.get_recid() not in recids: # debug('recid %s is not in pattern %s' % (repr(bibdoc.get_recid()), repr(recids))) # return False elif empty_docs == 'no' and bibdoc.empty_p(): debug('bibdoc is empty') return False elif empty_docs == 'only' and not bibdoc.empty_p(): debug('bibdoc is not empty') return False else: return True def cli2recid(options, recids=None, docids=None): """Given the command line options return a recid.""" recids = list(cli_recids_iterator(options, recids=recids, docids=docids)) if len(recids) == 1: return recids[0] if recids: raise StandardError, "More than one recid has been matched: %s" % recids else: raise StandardError, "No recids matched" def cli2docid(options, recids=None, docids=None): """Given the command line options return a docid.""" docids = list(cli_docids_iterator(options, recids=recids, docids=docids)) if len(docids) == 1: return docids[0] if docids: raise StandardError, "More than one docid has been matched: %s" % docids else: raise StandardError, "No docids matched" def cli2flags(options): """ Transform a comma separated list of flags into a list of valid flags. """ flags = getattr(options, 'flags', None) if flags: flags = [flag.strip().upper() for flag in flags.split(',')] for flag in flags: if flag not in CFG_BIBDOCFILE_AVAILABLE_FLAGS: raise StandardError("%s is not among the valid flags: %s" % (flag, ', '.join(CFG_BIBDOCFILE_AVAILABLE_FLAGS))) return flags return [] def cli2description(options): """Return a good value for the description.""" description = getattr(options, 'set_description', None) if description is None: description = KEEP_OLD_VALUE return description def cli2restriction(options): """Return a good value for the restriction.""" restriction = getattr(options, 'set_restriction', None) if restriction is None: restriction = KEEP_OLD_VALUE return restriction def cli2comment(options): """Return a good value for the comment.""" comment = getattr(options, 'set_comment', None) if comment is None: comment = KEEP_OLD_VALUE return comment def cli2doctype(options): """Return a good value for the doctype.""" doctype = getattr(options, 'set_doctype', None) if not doctype: return 'Main' return doctype def cli2docname(options, url=None): """Given the command line options and optional precalculated docid returns the corresponding docname.""" docname = getattr(options, 'docname', None) if docname is not None: return docname if url is not None: return get_docname_from_url(url) else: return None def cli2format(options, url=None): """Given the command line options returns the corresponding format.""" docformat = getattr(options, 'format', None) if docformat is not None: return docformat elif url is not None: ## FIXME: to deploy once conversion-tools branch is merged #return guess_format_from_url(url) return guess_format_from_url(url) else: raise OptionValueError("Not enough information to retrieve a valid format") def cli_recids_iterator(options, recids=None, docids=None): """Slow iterator over all the matched recids. if with_docids is True, the recid must be attached to at least a matched docid""" debug('cli_recids_iterator') if recids is None: recids = cli_quick_match_all_recids(options) debug('working on recids: %s, docids: %s' % (recids, docids)) for recid in recids: if cli_slow_match_single_recid(options, recid, docids): yield recid raise StopIteration def cli_docids_iterator(options, recids=None, docids=None): """Slow iterator over all the matched docids.""" if recids is None: recids = cli_quick_match_all_recids(options) if docids is None: docids = cli_quick_match_all_docids(options, recids) for docid in docids: if cli_slow_match_single_docid(options, docid, recids): yield docid raise StopIteration def cli_get_stats(dummy): """Print per every collection some stats""" def print_table(title, table): if table: print "=" * 20, title, "=" * 20 for row in table: print "\t".join(str(elem) for elem in row) for collection, reclist in run_sql("SELECT name, reclist FROM collection ORDER BY name"): print "-" * 79 print "Statistic for: %s " % collection reclist = intbitset(reclist) if reclist: sqlreclist = "(" + ','.join(str(elem) for elem in reclist) + ')' print_table("Formats", run_sql("SELECT COUNT(format) as c, format FROM bibrec_bibdoc AS bb JOIN bibdocfsinfo AS fs ON bb.id_bibdoc=fs.id_bibdoc WHERE id_bibrec in %s AND last_version=true GROUP BY format ORDER BY c DESC" % sqlreclist)) # kwalitee: disable=sql print_table("Mimetypes", run_sql("SELECT COUNT(mime) as c, mime FROM bibrec_bibdoc AS bb JOIN bibdocfsinfo AS fs ON bb.id_bibdoc=fs.id_bibdoc WHERE id_bibrec in %s AND last_version=true GROUP BY mime ORDER BY c DESC" % sqlreclist)) # kwalitee: disable=sql print_table("Sizes", run_sql("SELECT SUM(filesize) AS c FROM bibrec_bibdoc AS bb JOIN bibdocfsinfo AS fs ON bb.id_bibdoc=fs.id_bibdoc WHERE id_bibrec in %s AND last_version=true" % sqlreclist)) # kwalitee: disable=sql class OptionParserSpecial(OptionParser): def format_help(self, *args, **kwargs): result = OptionParser.format_help(self, *args, **kwargs) if hasattr(self, 'trailing_text'): return "%s\n%s\n" % (result, self.trailing_text) else: return result def prepare_option_parser(): """Parse the command line options.""" def _ids_ranges_callback(option, opt, value, parser): """Callback for optparse to parse a set of ids ranges in the form nnn1-nnn2,mmm1-mmm2... returning the corresponding intbitset. """ try: debug('option: %s, opt: %s, value: %s, parser: %s' % (option, opt, value, parser)) debug('Parsing range: %s' % value) value = ranges2ids(value) setattr(parser.values, option.dest, value) except Exception, e: raise OptionValueError("It's impossible to parse the range '%s' for option %s: %s" % (value, opt, e)) def _date_range_callback(option, opt, value, parser): """Callback for optparse to parse a range of dates in the form [date1],[date2]. Both date1 and date2 could be optional. the date can be expressed absolutely ("%Y-%m-%d %H:%M:%S") or relatively (([-\+]{0,1})([\d]+)([dhms])) to the current time.""" try: value = _parse_date_range(value) setattr(parser.values, option.dest, value) except Exception, e: raise OptionValueError("It's impossible to parse the range '%s' for option %s: %s" % (value, opt, e)) parser = OptionParserSpecial(usage="usage: %prog [options]", #epilog="""With <query> you select the range of record/docnames/single files to work on. Note that some actions e.g. delete, append, revise etc. works at the docname level, while others like --set-comment, --set-description, at single file level and other can be applied in an iterative way to many records in a single run. Note that specifing docid(2) takes precedence over recid(2) which in turns takes precedence over pattern/collection search.""", version=__revision__) parser.trailing_text = """ Examples: $ bibdocfile --append foo.tar.gz --recid=1 $ bibdocfile --revise http://foo.com?search=123 --with-docname='sam' --format=pdf --recid=3 --set-docname='pippo' # revise for record 3 # the document sam, renaming it to pippo. $ bibdocfile --delete --with-docname="*sam" --all # delete all documents # starting ending # with "sam" $ bibdocfile --undelete -c "Test Collection" # undelete documents for # the collection $ bibdocfile --get-info --recids=1-4,6-8 # obtain informations $ bibdocfile -r 1 --with-docname=foo --set-docname=bar # Rename a document $ bibdocfile -r 1 --set-restriction "firerole: deny until '2011-01-01' allow any" # set an embargo to all the documents attached to record 1 # (note the ^M or \\n before 'allow any') # See also $r subfield in <%(site)s/help/admin/bibupload-admin-guide#3.6> # and Firerole in <%(site)s/help/admin/webaccess-admin-guide#6> $ bibdocfile --append x.pdf --recid=1 --with-flags='PDF/A,OCRED' # append # to record 1 the file x.pdf specifying the PDF/A and OCRED flags """ % {'site': CFG_SITE_URL} query_options = OptionGroup(parser, 'Query options') query_options.add_option('-r', '--recids', action="callback", callback=_ids_ranges_callback, type='string', dest='recids', help='matches records by recids, e.g.: --recids=1-3,5-7') query_options.add_option('-d', '--docids', action="callback", callback=_ids_ranges_callback, type='string', dest='docids', help='matches documents by docids, e.g.: --docids=1-3,5-7') query_options.add_option('-a', '--all', action='store_true', dest='all', help='Select all the records') query_options.add_option("--with-deleted-recs", choices=['yes', 'no', 'only'], type="choice", dest="deleted_recs", help="'Yes' to also match deleted records, 'no' to exclude them, 'only' to match only deleted ones", metavar="yes/no/only", default='no') query_options.add_option("--with-deleted-docs", choices=['yes', 'no', 'only'], type="choice", dest="deleted_docs", help="'Yes' to also match deleted documents, 'no' to exclude them, 'only' to match only deleted ones (e.g. for undeletion)", metavar="yes/no/only", default='no') query_options.add_option("--with-empty-recs", choices=['yes', 'no', 'only'], type="choice", dest="empty_recs", help="'Yes' to also match records without attached documents, 'no' to exclude them, 'only' to consider only such records (e.g. for statistics)", metavar="yes/no/only", default='no') query_options.add_option("--with-empty-docs", choices=['yes', 'no', 'only'], type="choice", dest="empty_docs", help="'Yes' to also match documents without attached files, 'no' to exclude them, 'only' to consider only such documents (e.g. for sanity checking)", metavar="yes/no/only", default='no') query_options.add_option("--with-record-modification-date", action="callback", callback=_date_range_callback, dest="md_rec", nargs=1, type="string", default=(None, None), help="matches records modified date1 and date2; dates can be expressed relatively, e.g.:\"-5m,2030-2-23 04:40\" # matches records modified since 5 minutes ago until the 2030...", metavar="date1,date2") query_options.add_option("--with-record-creation-date", action="callback", callback=_date_range_callback, dest="cd_rec", nargs=1, type="string", default=(None, None), help="matches records created between date1 and date2; dates can be expressed relatively", metavar="date1,date2") query_options.add_option("--with-document-modification-date", action="callback", callback=_date_range_callback, dest="md_doc", nargs=1, type="string", default=(None, None), help="matches documents modified between date1 and date2; dates can be expressed relatively", metavar="date1,date2") query_options.add_option("--with-document-creation-date", action="callback", callback=_date_range_callback, dest="cd_doc", nargs=1, type="string", default=(None, None), help="matches documents created between date1 and date2; dates can be expressed relatively", metavar="date1,date2") query_options.add_option("--url", dest="url", help='matches the document referred by the URL, e.g. "%s/%s/1/files/foobar.pdf?version=2"' % (CFG_SITE_URL, CFG_SITE_RECORD)) query_options.add_option("--path", dest="path", help='matches the document referred by the internal filesystem path, e.g. %s/g0/1/foobar.pdf\\;1' % CFG_BIBDOCFILE_FILEDIR) query_options.add_option("--with-docname", dest="docname", help='matches documents with the given docname (accept wildcards)') query_options.add_option("--with-doctype", dest="doctype", help='matches documents with the given doctype') query_options.add_option('-p', '--pattern', dest='pattern', help='matches records by pattern') query_options.add_option('-c', '--collection', dest='collection', help='matches records by collection') query_options.add_option('--force', dest='force', help='force an action even when it\'s not necessary e.g. textify on an already textified bibdoc.', action='store_true', default=False) parser.add_option_group(query_options) getting_information_options = OptionGroup(parser, 'Actions for getting information') getting_information_options.add_option('--get-info', dest='action', action='store_const', const='get-info', help='print all the informations about the matched record/documents') getting_information_options.add_option('--get-disk-usage', dest='action', action='store_const', const='get-disk-usage', help='print disk usage statistics of the matched documents') getting_information_options.add_option('--get-history', dest='action', action='store_const', const='get-history', help='print the matched documents history') getting_information_options.add_option('--get-stats', dest='action', action='store_const', const='get-stats', help='print some statistics of file properties grouped by collections') parser.add_option_group(getting_information_options) setting_information_options = OptionGroup(parser, 'Actions for setting information') setting_information_options.add_option('--set-doctype', dest='set_doctype', help='specify the new doctype', metavar='doctype') setting_information_options.add_option('--set-description', dest='set_description', help='specify a description', metavar='description') setting_information_options.add_option('--set-comment', dest='set_comment', help='specify a comment', metavar='comment') setting_information_options.add_option('--set-restriction', dest='set_restriction', help='specify a restriction tag', metavar='restriction') setting_information_options.add_option('--set-docname', dest='new_docname', help='specifies a new docname for renaming', metavar='docname') setting_information_options.add_option("--unset-comment", action="store_const", const='', dest="set_comment", help="remove any comment") setting_information_options.add_option("--unset-descriptions", action="store_const", const='', dest="set_description", help="remove any description") setting_information_options.add_option("--unset-restrictions", action="store_const", const='', dest="set_restriction", help="remove any restriction") setting_information_options.add_option("--hide", dest="action", action='store_const', const='hide', help="hides matched documents and revisions") setting_information_options.add_option("--unhide", dest="action", action='store_const', const='unhide', help="hides matched documents and revisions") parser.add_option_group(setting_information_options) revising_options = OptionGroup(parser, 'Action for revising content') revising_options.add_option("--append", dest='append_path', help='specify the URL/path of the file that will appended to the bibdoc (implies --with-empty-recs=yes)', metavar='PATH/URL') revising_options.add_option("--revise", dest='revise_path', help='specify the URL/path of the file that will revise the bibdoc', metavar='PATH/URL') revising_options.add_option("--revert", dest='action', action='store_const', const='revert', help='reverts a document to the specified version') revising_options.add_option("--delete", action='store_const', const='delete', dest='action', help='soft-delete the matched documents') revising_options.add_option("--hard-delete", action='store_const', const='hard-delete', dest='action', help='hard-delete the single matched document with a specific format and a specific revision (this operation is not revertible)') revising_options.add_option("--undelete", action='store_const', const='undelete', dest='action', help='undelete previosuly soft-deleted documents') revising_options.add_option("--purge", action='store_const', const='purge', dest='action', help='purge (i.e. hard-delete any format of any version prior to the latest version of) the matched documents') revising_options.add_option("--expunge", action='store_const', const='expunge', dest='action', help='expunge (i.e. hard-delete any version and formats of) the matched documents') revising_options.add_option("--with-version", dest="version", help="specifies the version(s) to be used with hide, unhide, e.g.: 1-2,3 or ALL. Specifies the version to be used with hard-delete and revert, e.g. 2") revising_options.add_option("--with-format", dest="format", help='to specify a format when appending/revising/deleting/reverting a document, e.g. "pdf"', metavar='FORMAT') revising_options.add_option("--with-hide-previous", dest='hide_previous', action='store_true', help='when revising, hides previous versions', default=False) revising_options.add_option("--with-flags", dest='flags', help='comma-separated optional list of flags used when appending/revising a document. Valid flags are: %s' % ', '.join(CFG_BIBDOCFILE_AVAILABLE_FLAGS), default=None) parser.add_option_group(revising_options) housekeeping_options = OptionGroup(parser, 'Actions for housekeeping') housekeeping_options.add_option("--check-md5", action='store_const', const='check-md5', dest='action', help='check md5 checksum validity of files') housekeeping_options.add_option("--check-format", action='store_const', const='check-format', dest='action', help='check if any format-related inconsistences exists') housekeeping_options.add_option("--check-duplicate-docnames", action='store_const', const='check-duplicate-docnames', dest='action', help='check for duplicate docnames associated with the same record') housekeeping_options.add_option("--update-md5", action='store_const', const='update-md5', dest='action', help='update md5 checksum of files') housekeeping_options.add_option("--fix-all", action='store_const', const='fix-all', dest='action', help='fix inconsistences in filesystem vs database vs MARC') housekeeping_options.add_option("--fix-marc", action='store_const', const='fix-marc', dest='action', help='synchronize MARC after filesystem/database') housekeeping_options.add_option("--fix-format", action='store_const', const='fix-format', dest='action', help='fix format related inconsistences') housekeeping_options.add_option("--fix-duplicate-docnames", action='store_const', const='fix-duplicate-docnames', dest='action', help='fix duplicate docnames associated with the same record') housekeeping_options.add_option("--fix-bibdocfsinfo-cache", action='store_const', const='fix-bibdocfsinfo-cache', dest='action', help='fix bibdocfsinfo cache related inconsistences') parser.add_option_group(housekeeping_options) experimental_options = OptionGroup(parser, 'Experimental options (do not expect to find them in the next release)') experimental_options.add_option('--textify', dest='action', action='store_const', const='textify', help='extract text from matched documents and store it for later indexing') experimental_options.add_option('--with-ocr', dest='perform_ocr', action='store_true', default=False, help='when used with --textify, wether to perform OCR') parser.add_option_group(experimental_options) parser.add_option('-D', '--debug', action='store_true', dest='debug', default=False) parser.add_option('-H', '--human-readable', dest='human_readable', action='store_true', default=False, help='print sizes in human readable format (e.g., 1KB 234MB 2GB)') parser.add_option('--yes-i-know', action='store_true', dest='yes-i-know', help='use with care!') return parser def print_info(docid, info): """Nicely print info about a docid.""" print '%i:%s' % (docid, info) def bibupload_ffts(ffts, append=False, do_debug=False, interactive=True): """Given an ffts dictionary it creates the xml and submit it.""" xml = ffts_to_xml(ffts) if xml: if interactive: print xml tmp_file_fd, tmp_file_name = mkstemp(suffix='.xml', prefix="bibdocfile_%s" % time.strftime("%Y-%m-%d_%H:%M:%S"), dir=CFG_TMPSHAREDDIR) os.write(tmp_file_fd, xml) os.close(tmp_file_fd) os.chmod(tmp_file_name, 0644) if append: if interactive: wait_for_user("This will be appended via BibUpload") if do_debug: task = task_low_level_submission('bibupload', 'bibdocfile', '-a', tmp_file_name, '-N', 'FFT', '-S2', '-v9') else: task = task_low_level_submission('bibupload', 'bibdocfile', '-a', tmp_file_name, '-N', 'FFT', '-S2') if interactive: print "BibUpload append submitted with id %s" % task else: if interactive: wait_for_user("This will be corrected via BibUpload") if do_debug: task = task_low_level_submission('bibupload', 'bibdocfile', '-c', tmp_file_name, '-N', 'FFT', '-S2', '-v9') else: task = task_low_level_submission('bibupload', 'bibdocfile', '-c', tmp_file_name, '-N', 'FFT', '-S2') if interactive: print "BibUpload correct submitted with id %s" % task elif interactive: print >> sys.stderr, "WARNING: no MARC to upload." return True def ranges2ids(parse_string): """Parse a string and return the intbitset of the corresponding ids.""" ids = intbitset() ranges = parse_string.split(",") for arange in ranges: tmp_ids = arange.split("-") if len(tmp_ids)==1: ids.add(int(tmp_ids[0])) else: if int(tmp_ids[0]) > int(tmp_ids[1]): # sanity check tmp = tmp_ids[0] tmp_ids[0] = tmp_ids[1] tmp_ids[1] = tmp ids += xrange(int(tmp_ids[0]), int(tmp_ids[1]) + 1) return ids def cli_append(options, append_path): """Create a bibupload FFT task submission for appending a format.""" recid = cli2recid(options) comment = cli2comment(options) description = cli2description(options) restriction = cli2restriction(options) doctype = cli2doctype(options) docname = cli2docname(options, url=append_path) flags = cli2flags(options) if not docname: raise OptionValueError, 'Not enough information to retrieve a valid docname' docformat = cli2format(options, append_path) url = clean_url(append_path) check_valid_url(url) bibrecdocs = BibRecDocs(recid) if bibrecdocs.has_docname_p(docname) and bibrecdocs.get_bibdoc(docname).format_already_exists_p(docformat): new_docname = bibrecdocs.propose_unique_docname(docname) wait_for_user("WARNING: a document with name %s and format %s already exists for recid %s. A new document with name %s will be created instead." % (repr(docname), repr(docformat), repr(recid), repr(new_docname))) docname = new_docname ffts = {recid: [{ 'docname' : docname, 'comment' : comment, 'description' : description, 'restriction' : restriction, 'doctype' : doctype, 'format' : docformat, 'url' : url, 'options': flags }]} return bibupload_ffts(ffts, append=True) def cli_revise(options, revise_path): """Create aq bibupload FFT task submission for appending a format.""" recid = cli2recid(options) comment = cli2comment(options) description = cli2description(options) restriction = cli2restriction(options) docname = cli2docname(options, url=revise_path) hide_previous = getattr(options, 'hide_previous', None) flags = cli2flags(options) if hide_previous and 'PERFORM_HIDE_PREVIOUS' not in flags: flags.append('PERFORM_HIDE_PREVIOUS') if not docname: raise OptionValueError, 'Not enough information to retrieve a valid docname' docformat = cli2format(options, revise_path) doctype = cli2doctype(options) url = clean_url(revise_path) new_docname = getattr(options, 'new_docname', None) check_valid_url(url) ffts = {recid : [{ 'docname' : docname, 'new_docname' : new_docname, 'comment' : comment, 'description' : description, 'restriction' : restriction, 'doctype' : doctype, 'format' : docformat, 'url' : url, 'options' : flags }]} return bibupload_ffts(ffts) def cli_set_batch(options): """Change in batch the doctype, description, comment and restriction.""" ffts = {} doctype = getattr(options, 'set_doctype', None) description = cli2description(options) comment = cli2comment(options) restriction = cli2restriction(options) with_format = getattr(options, 'format', None) for docid in cli_docids_iterator(options): bibdoc = BibDoc.create_instance(docid) recid = None docname = None if bibdoc.bibrec_links: # pick a sample recid from those to which a BibDoc is attached recid = bibdoc.bibrec_links[0]["recid"] docname = bibdoc.bibrec_links[0]["docname"] fft = [] if description is not None or comment is not None: for bibdocfile in bibdoc.list_latest_files(): docformat = bibdocfile.get_format() if not with_format or with_format == format: fft.append({ 'docname': docname, 'restriction': restriction, 'comment': comment, 'description': description, 'format': docformat, 'doctype': doctype }) else: fft.append({ 'docname': docname, 'restriction': restriction, 'doctype': doctype, }) ffts[recid] = fft return bibupload_ffts(ffts, append=False) def cli_textify(options): """Extract text to let indexing on fulltext be possible.""" force = getattr(options, 'force', None) perform_ocr = getattr(options, 'perform_ocr', None) if perform_ocr: if not can_perform_ocr(): print >> sys.stderr, "WARNING: OCR requested but OCR is not possible" perform_ocr = False if perform_ocr: additional = ' using OCR (this might take some time)' else: additional = '' for docid in cli_docids_iterator(options): bibdoc = BibDoc.create_instance(docid) print 'Extracting text for docid %s%s...' % (docid, additional), sys.stdout.flush() #pylint: disable=E1103 if force or (hasattr(bibdoc, "has_text") and not bibdoc.has_text(require_up_to_date=True)): try: #pylint: disable=E1103 bibdoc.extract_text(perform_ocr=perform_ocr) print "DONE" except InvenioBibDocFileError, e: print >> sys.stderr, "WARNING: %s" % e else: print "not needed" def cli_rename(options): """Rename a docname within a recid.""" new_docname = getattr(options, 'new_docname', None) docid = cli2docid(options) bibdoc = BibDoc.create_instance(docid) docname = None if bibdoc.bibrec_links: docname = bibdoc.bibrec_links[0]["docname"] recid = cli2recid(options) # now we read the recid from options ffts = {recid : [{'docname' : docname, 'new_docname' : new_docname}]} return bibupload_ffts(ffts, append=False) def cli_fix_bibdocfsinfo_cache(options): """Rebuild the bibdocfsinfo table according to what is available on filesystem""" to_be_fixed = intbitset() for docid in intbitset(run_sql("SELECT id FROM bibdoc")): print "Fixing bibdocfsinfo table for docid %s..." % docid, sys.stdout.flush() try: bibdoc = BibDoc(docid) except InvenioBibDocFileError, err: print err continue try: bibdoc._sync_to_db() except Exception, err: if bibdoc.bibrec_links: recid = bibdoc.bibrec_links[0]["recid"] if recid: to_be_fixed.add(recid) print "ERROR: %s, scheduling a fix for recid %s" % (err, recid) else: print "ERROR %s" % (err, ) print "DONE" if to_be_fixed: cli_fix_format(options, recids=to_be_fixed) print "You can now add CFG_BIBDOCFILE_ENABLE_BIBDOCFSINFO_CACHE=1 to your invenio-local.conf file." def cli_fix_all(options): """Fix all the records of a recid_set.""" ffts = {} for recid in cli_recids_iterator(options): ffts[recid] = [] for docname in BibRecDocs(recid).get_bibdoc_names(): ffts[recid].append({'docname' : docname, 'doctype' : 'FIX-ALL'}) return bibupload_ffts(ffts, append=False) def cli_fix_marc(options, explicit_recid_set=None, interactive=True): """Fix all the records of a recid_set.""" ffts = {} if explicit_recid_set is not None: for recid in explicit_recid_set: ffts[recid] = [{'doctype' : 'FIX-MARC'}] else: for recid in cli_recids_iterator(options): ffts[recid] = [{'doctype' : 'FIX-MARC'}] return bibupload_ffts(ffts, append=False, interactive=interactive) def cli_check_format(options): """Check if any format-related inconsistences exists.""" count = 0 tot = 0 duplicate = False for recid in cli_recids_iterator(options): tot += 1 bibrecdocs = BibRecDocs(recid) if not bibrecdocs.check_duplicate_docnames(): print >> sys.stderr, "recid %s has duplicate docnames!" broken = True duplicate = True else: broken = False for docname in bibrecdocs.get_bibdoc_names(): if not bibrecdocs.check_format(docname): print >> sys.stderr, "recid %s with docname %s need format fixing" % (recid, docname) broken = True if broken: count += 1 if count: result = "%d out of %d records need their formats to be fixed." % (count, tot) else: result = "All records appear to be correct with respect to formats." if duplicate: result += " Note however that at least one record appear to have duplicate docnames. You should better fix this situation by using --fix-duplicate-docnames." print wrap_text_in_a_box(result, style="conclusion") return not(duplicate or count) def cli_check_duplicate_docnames(options): """Check if some record is connected with bibdoc having the same docnames.""" count = 0 tot = 0 for recid in cli_recids_iterator(options): tot += 1 bibrecdocs = BibRecDocs(recid) if bibrecdocs.check_duplicate_docnames(): count += 1 print >> sys.stderr, "recid %s has duplicate docnames!" if count: print "%d out of %d records have duplicate docnames." % (count, tot) return False else: print "All records appear to be correct with respect to duplicate docnames." return True def cli_fix_format(options, recids=None): """Fix format-related inconsistences.""" fixed = intbitset() tot = 0 if not recids: recids = cli_recids_iterator(options) for recid in recids: tot += 1 bibrecdocs = BibRecDocs(recid) for docname in bibrecdocs.get_bibdoc_names(): if not bibrecdocs.check_format(docname): if bibrecdocs.fix_format(docname, skip_check=True): print >> sys.stderr, "%i has been fixed for docname %s" % (recid, docname) else: print >> sys.stderr, "%i has been fixed for docname %s. However note that a new bibdoc might have been created." % (recid, docname) fixed.add(recid) if fixed: print "Now we need to synchronize MARC to reflect current changes." cli_fix_marc(options, explicit_recid_set=fixed) print wrap_text_in_a_box("%i out of %i record needed to be fixed." % (tot, len(fixed)), style="conclusion") return not fixed def cli_fix_duplicate_docnames(options): """Fix duplicate docnames.""" fixed = intbitset() tot = 0 for recid in cli_recids_iterator(options): tot += 1 bibrecdocs = BibRecDocs(recid) if not bibrecdocs.check_duplicate_docnames(): bibrecdocs.fix_duplicate_docnames(skip_check=True) print >> sys.stderr, "%i has been fixed for duplicate docnames." % recid fixed.add(recid) if fixed: print "Now we need to synchronize MARC to reflect current changes." cli_fix_marc(options, explicit_recid_set=fixed) print wrap_text_in_a_box("%i out of %i record needed to be fixed." % (tot, len(fixed)), style="conclusion") return not fixed def cli_delete(options): """Delete the given docid_set.""" ffts = {} for docid in cli_docids_iterator(options): bibdoc = BibDoc.create_instance(docid) docname = None recid = None # retrieve the 1st recid if recid.bibrec_links: recid = bibdoc.bibrec_links[0]["recid"] docname = bibdoc.bibrec_links[0]["docname"] if recid not in ffts: ffts[recid] = [{'docname' : docname, 'doctype' : 'DELETE'}] else: ffts[recid].append({'docname' : docname, 'doctype' : 'DELETE'}) return bibupload_ffts(ffts) def cli_delete_file(options): """Delete the given file irreversibely.""" docid = cli2docid(options) recid = cli2recid(options, docids=intbitset([docid])) docformat = cli2format(options) bdr = BibRecDocs(recid) docname = bdr.get_docname(docid) version = getattr(options, 'version', None) try: version_int = int(version) if 0 >= version_int: raise ValueError except: raise OptionValueError, 'when hard-deleting, version should be valid positive integer, not %s' % version ffts = {recid : [{'docname' : docname, 'version' : version, 'format' : docformat, 'doctype' : 'DELETE-FILE'}]} return bibupload_ffts(ffts) def cli_revert(options): """Revert a bibdoc to a given version.""" docid = cli2docid(options) recid = cli2recid(options, docids=intbitset([docid])) bdr = BibRecDocs(recid) docname = bdr.get_docname(docid) version = getattr(options, 'version', None) try: version_int = int(version) if 0 >= version_int: raise ValueError except: raise OptionValueError, 'when reverting, version should be valid positive integer, not %s' % version ffts = {recid : [{'docname' : docname, 'version' : version, 'doctype' : 'REVERT'}]} return bibupload_ffts(ffts) def cli_undelete(options): """Delete the given docname""" docname = cli2docname(options) restriction = getattr(options, 'restriction', None) count = 0 if not docname: docname = 'DELETED-*-*' if not docname.startswith('DELETED-'): docname = 'DELETED-*-' + docname to_be_undeleted = intbitset() fix_marc = intbitset() setattr(options, 'deleted_docs', 'only') for docid in cli_docids_iterator(options): bibdoc = BibDoc.create_instance(docid) dnold = None if bibdoc.bibrec_links: dnold = bibdoc.bibrec_links[0]["docname"] if bibdoc.get_status() == 'DELETED' and fnmatch.fnmatch(dnold, docname): to_be_undeleted.add(docid) # get the 1st recid to which the document is attached recid = None if bibdoc.bibrec_links: recid = bibdoc.bibrec_links[0]["recid"] fix_marc.add(recid) count += 1 print '%s (docid %s from recid %s) will be undeleted to restriction: %s' % (dnold, docid, recid, restriction) wait_for_user("I'll proceed with the undeletion") for docid in to_be_undeleted: bibdoc = BibDoc.create_instance(docid) bibdoc.undelete(restriction) cli_fix_marc(options, explicit_recid_set=fix_marc) print wrap_text_in_a_box("%s bibdoc successfuly undeleted with status '%s'" % (count, restriction), style="conclusion") def cli_get_info(options): """Print all the info of the matched docids or recids.""" debug('Getting info!') human_readable = bool(getattr(options, 'human_readable', None)) debug('human_readable: %s' % human_readable) deleted_docs = getattr(options, 'deleted_docs', None) in ('yes', 'only') debug('deleted_docs: %s' % deleted_docs) if getattr(options, 'docids', None): for docid in cli_docids_iterator(options): sys.stdout.write(str(BibDoc.create_instance(docid, human_readable=human_readable))) else: for recid in cli_recids_iterator(options): sys.stdout.write(str(BibRecDocs(recid, deleted_too=deleted_docs, human_readable=human_readable))) def cli_purge(options): """Purge the matched docids.""" ffts = {} for docid in cli_docids_iterator(options): bibdoc = BibDoc.create_instance(docid) recid = None docname = None if bibdoc.bibrec_links: recid = bibdoc.bibrec_links[0]["recid"] docname = bibdoc.bibrec_links[0]["docname"] if recid: if recid not in ffts: ffts[recid] = [] ffts[recid].append({ 'docname' : docname, 'doctype' : 'PURGE', }) return bibupload_ffts(ffts) def cli_expunge(options): """Expunge the matched docids.""" ffts = {} for docid in cli_docids_iterator(options): bibdoc = BibDoc.create_instance(docid) recid = None docname = None if bibdoc.bibrec_links: #TODO: If we have a syntax for manipulating completely standalone objects, # this has to be modified recid = bibdoc.bibrec_links[0]["recid"] docname = bibdoc.bibrec_links[0]["docname"] if recid: if recid not in ffts: ffts[recid] = [] ffts[recid].append({ 'docname' : docname, 'doctype' : 'EXPUNGE', }) return bibupload_ffts(ffts) def cli_get_history(options): """Print the history of a docid_set.""" for docid in cli_docids_iterator(options): bibdoc = BibDoc.create_instance(docid) history = bibdoc.get_history() for row in history: print_info(docid, row) def cli_get_disk_usage(options): """Print the space usage of a docid_set.""" human_readable = getattr(options, 'human_readable', None) total_size = 0 total_latest_size = 0 for docid in cli_docids_iterator(options): bibdoc = BibDoc.create_instance(docid) size = bibdoc.get_total_size() total_size += size latest_size = bibdoc.get_total_size_latest_version() total_latest_size += latest_size if human_readable: print_info(docid, 'size=%s' % nice_size(size)) print_info(docid, 'latest version size=%s' % nice_size(latest_size)) else: print_info(docid, 'size=%s' % size) print_info( docid, 'latest version size=%s' % latest_size) if human_readable: print wrap_text_in_a_box('total size: %s\n\nlatest version total size: %s' % (nice_size(total_size), nice_size(total_latest_size)), style='conclusion') else: print wrap_text_in_a_box('total size: %s\n\nlatest version total size: %s' % (total_size, total_latest_size), style='conclusion') def cli_check_md5(options): """Check the md5 sums of a docid_set.""" failures = 0 for docid in cli_docids_iterator(options): bibdoc = BibDoc.create_instance(docid) if bibdoc.md5s.check(): print_info(docid, 'checksum OK') else: for afile in bibdoc.list_all_files(): if not afile.check(): failures += 1 print_info(docid, '%s failing checksum!' % afile.get_full_path()) if failures: print wrap_text_in_a_box('%i files failing' % failures , style='conclusion') else: print wrap_text_in_a_box('All files are correct', style='conclusion') def cli_update_md5(options): """Update the md5 sums of a docid_set.""" for docid in cli_docids_iterator(options): bibdoc = BibDoc.create_instance(docid) if bibdoc.md5s.check(): print_info(docid, 'checksum OK') else: for afile in bibdoc.list_all_files(): if not afile.check(): print_info(docid, '%s failing checksum!' % afile.get_full_path()) wait_for_user('Updating the md5s of this document can hide real problems.') bibdoc.md5s.update(only_new=False) bibdoc._sync_to_db() def cli_hide(options): """Hide the matched versions of documents.""" documents_to_be_hidden = {} to_be_fixed = intbitset() versions = getattr(options, 'versions', 'all') if versions != 'all': try: versions = ranges2ids(versions) except: raise OptionValueError, 'You should specify correct versions. Not %s' % versions else: versions = intbitset(trailing_bits=True) for docid in cli_docids_iterator(options): bibdoc = BibDoc.create_instance(docid) recid = None if bibdoc.bibrec_links: recid = bibdoc.bibrec_links[0]["recid"] if recid: for bibdocfile in bibdoc.list_all_files(): this_version = bibdocfile.get_version() this_format = bibdocfile.get_format() if this_version in versions: if docid not in documents_to_be_hidden: documents_to_be_hidden[docid] = [] documents_to_be_hidden[docid].append((this_version, this_format)) to_be_fixed.add(recid) print '%s (docid: %s, recid: %s) will be hidden' % (bibdocfile.get_full_name(), docid, recid) wait_for_user('Proceeding to hide the matched documents...') for docid, documents in documents_to_be_hidden.iteritems(): bibdoc = BibDoc.create_instance(docid) for version, docformat in documents: bibdoc.set_flag('HIDDEN', docformat, version) return cli_fix_marc(options, to_be_fixed) def cli_unhide(options): """Unhide the matched versions of documents.""" documents_to_be_unhidden = {} to_be_fixed = intbitset() versions = getattr(options, 'versions', 'all') if versions != 'all': try: versions = ranges2ids(versions) except: raise OptionValueError, 'You should specify correct versions. Not %s' % versions else: versions = intbitset(trailing_bits=True) for docid in cli_docids_iterator(options): bibdoc = BibDoc.create_instance(docid) recid = None if bibdoc.bibrec_links: recid = bibdoc.bibrec_links[0]["recid"] if recid: for bibdocfile in bibdoc.list_all_files(): this_version = bibdocfile.get_version() this_format = bibdocfile.get_format() if this_version in versions: if docid not in documents_to_be_unhidden: documents_to_be_unhidden[docid] = [] documents_to_be_unhidden[docid].append((this_version, this_format)) to_be_fixed.add(recid) print '%s (docid: %s, recid: %s) will be unhidden' % (bibdocfile.get_full_name(), docid, recid) wait_for_user('Proceeding to unhide the matched documents...') for docid, documents in documents_to_be_unhidden.iteritems(): bibdoc = BibDoc.create_instance(docid) for version, docformat in documents: bibdoc.unset_flag('HIDDEN', docformat, version) return cli_fix_marc(options, to_be_fixed) def main(): parser = prepare_option_parser() (options, args) = parser.parse_args() if getattr(options, 'debug', None): getLogger().setLevel(DEBUG) debug('test') debug('options: %s, args: %s' % (options, args)) try: if not getattr(options, 'action', None) and \ not getattr(options, 'append_path', None) and \ not getattr(options, 'revise_path', None): if getattr(options, 'set_doctype', None) is not None or \ getattr(options, 'set_comment', None) is not None or \ getattr(options, 'set_description', None) is not None or \ getattr(options, 'set_restriction', None) is not None: cli_set_batch(options) elif getattr(options, 'new_docname', None): cli_rename(options) else: print >> sys.stderr, "ERROR: no action specified" sys.exit(1) elif getattr(options, 'append_path', None): options.empty_recs = 'yes' options.empty_docs = 'yes' cli_append(options, getattr(options, 'append_path', None)) elif getattr(options, 'revise_path', None): cli_revise(options, getattr(options, 'revise_path', None)) elif options.action == 'textify': cli_textify(options) elif getattr(options, 'action', None) == 'get-history': cli_get_history(options) elif getattr(options, 'action', None) == 'get-info': cli_get_info(options) elif getattr(options, 'action', None) == 'get-disk-usage': cli_get_disk_usage(options) elif getattr(options, 'action', None) == 'check-md5': cli_check_md5(options) elif getattr(options, 'action', None) == 'update-md5': cli_update_md5(options) elif getattr(options, 'action', None) == 'fix-all': cli_fix_all(options) elif getattr(options, 'action', None) == 'fix-marc': cli_fix_marc(options) elif getattr(options, 'action', None) == 'delete': cli_delete(options) elif getattr(options, 'action', None) == 'hard-delete': cli_delete_file(options) elif getattr(options, 'action', None) == 'fix-duplicate-docnames': cli_fix_duplicate_docnames(options) elif getattr(options, 'action', None) == 'fix-format': cli_fix_format(options) elif getattr(options, 'action', None) == 'check-duplicate-docnames': cli_check_duplicate_docnames(options) elif getattr(options, 'action', None) == 'check-format': cli_check_format(options) elif getattr(options, 'action', None) == 'undelete': cli_undelete(options) elif getattr(options, 'action', None) == 'purge': cli_purge(options) elif getattr(options, 'action', None) == 'expunge': cli_expunge(options) elif getattr(options, 'action', None) == 'revert': cli_revert(options) elif getattr(options, 'action', None) == 'hide': cli_hide(options) elif getattr(options, 'action', None) == 'unhide': cli_unhide(options) elif getattr(options, 'action', None) == 'fix-bibdocfsinfo-cache': options.empty_docs = 'yes' cli_fix_bibdocfsinfo_cache(options) elif getattr(options, 'action', None) == 'get-stats': cli_get_stats(options) else: print >> sys.stderr, "ERROR: Action %s is not valid" % getattr(options, 'action', None) sys.exit(1) except Exception, e: register_exception() print >> sys.stderr, 'ERROR: %s' % e sys.exit(1) if __name__ == '__main__': main()
gpl-2.0
tomaszkolonko/ndnSIM-all
ndn-cxx/.waf-1.8.9-849024857bd41c3cf8e87dc01ecf79b0/waflib/extras/compat15.py
10
8876
#! /usr/bin/env python # encoding: utf-8 # WARNING! Do not edit! https://waf.io/book/index.html#_obtaining_the_waf_file import sys from waflib import ConfigSet,Logs,Options,Scripting,Task,Build,Configure,Node,Runner,TaskGen,Utils,Errors,Context sys.modules['Environment']=ConfigSet ConfigSet.Environment=ConfigSet.ConfigSet sys.modules['Logs']=Logs sys.modules['Options']=Options sys.modules['Scripting']=Scripting sys.modules['Task']=Task sys.modules['Build']=Build sys.modules['Configure']=Configure sys.modules['Node']=Node sys.modules['Runner']=Runner sys.modules['TaskGen']=TaskGen sys.modules['Utils']=Utils from waflib.Tools import c_preproc sys.modules['preproc']=c_preproc from waflib.Tools import c_config sys.modules['config_c']=c_config ConfigSet.ConfigSet.copy=ConfigSet.ConfigSet.derive ConfigSet.ConfigSet.set_variant=Utils.nada Build.BuildContext.add_subdirs=Build.BuildContext.recurse Build.BuildContext.new_task_gen=Build.BuildContext.__call__ Build.BuildContext.is_install=0 Node.Node.relpath_gen=Node.Node.path_from Utils.pproc=Utils.subprocess Utils.get_term_cols=Logs.get_term_cols def cmd_output(cmd,**kw): silent=False if'silent'in kw: silent=kw['silent'] del(kw['silent']) if'e'in kw: tmp=kw['e'] del(kw['e']) kw['env']=tmp kw['shell']=isinstance(cmd,str) kw['stdout']=Utils.subprocess.PIPE if silent: kw['stderr']=Utils.subprocess.PIPE try: p=Utils.subprocess.Popen(cmd,**kw) output=p.communicate()[0] except OSError ,e: raise ValueError(str(e)) if p.returncode: if not silent: msg="command execution failed: %s -> %r"%(cmd,str(output)) raise ValueError(msg) output='' return output Utils.cmd_output=cmd_output def name_to_obj(self,s,env=None): if Logs.verbose: Logs.warn('compat: change "name_to_obj(name, env)" by "get_tgen_by_name(name)"') return self.get_tgen_by_name(s) Build.BuildContext.name_to_obj=name_to_obj def env_of_name(self,name): try: return self.all_envs[name] except KeyError: Logs.error('no such environment: '+name) return None Build.BuildContext.env_of_name=env_of_name def set_env_name(self,name,env): self.all_envs[name]=env return env Configure.ConfigurationContext.set_env_name=set_env_name def retrieve(self,name,fromenv=None): try: env=self.all_envs[name] except KeyError: env=ConfigSet.ConfigSet() self.prepare_env(env) self.all_envs[name]=env else: if fromenv: Logs.warn("The environment %s may have been configured already"%name) return env Configure.ConfigurationContext.retrieve=retrieve Configure.ConfigurationContext.sub_config=Configure.ConfigurationContext.recurse Configure.ConfigurationContext.check_tool=Configure.ConfigurationContext.load Configure.conftest=Configure.conf Configure.ConfigurationError=Errors.ConfigurationError Utils.WafError=Errors.WafError Options.OptionsContext.sub_options=Options.OptionsContext.recurse Options.OptionsContext.tool_options=Context.Context.load Options.Handler=Options.OptionsContext Task.simple_task_type=Task.task_type_from_func=Task.task_factory Task.TaskBase.classes=Task.classes def setitem(self,key,value): if key.startswith('CCFLAGS'): key=key[1:] self.table[key]=value ConfigSet.ConfigSet.__setitem__=setitem @TaskGen.feature('d') @TaskGen.before('apply_incpaths') def old_importpaths(self): if getattr(self,'importpaths',[]): self.includes=self.importpaths from waflib import Context eld=Context.load_tool def load_tool(*k,**kw): ret=eld(*k,**kw) if'set_options'in ret.__dict__: if Logs.verbose: Logs.warn('compat: rename "set_options" to options') ret.options=ret.set_options if'detect'in ret.__dict__: if Logs.verbose: Logs.warn('compat: rename "detect" to "configure"') ret.configure=ret.detect return ret Context.load_tool=load_tool def get_curdir(self): return self.path.abspath() Context.Context.curdir=property(get_curdir,Utils.nada) rev=Context.load_module def load_module(path,encoding=None): ret=rev(path,encoding) if'set_options'in ret.__dict__: if Logs.verbose: Logs.warn('compat: rename "set_options" to "options" (%r)'%path) ret.options=ret.set_options if'srcdir'in ret.__dict__: if Logs.verbose: Logs.warn('compat: rename "srcdir" to "top" (%r)'%path) ret.top=ret.srcdir if'blddir'in ret.__dict__: if Logs.verbose: Logs.warn('compat: rename "blddir" to "out" (%r)'%path) ret.out=ret.blddir return ret Context.load_module=load_module old_post=TaskGen.task_gen.post def post(self): self.features=self.to_list(self.features) if'cc'in self.features: if Logs.verbose: Logs.warn('compat: the feature cc does not exist anymore (use "c")') self.features.remove('cc') self.features.append('c') if'cstaticlib'in self.features: if Logs.verbose: Logs.warn('compat: the feature cstaticlib does not exist anymore (use "cstlib" or "cxxstlib")') self.features.remove('cstaticlib') self.features.append(('cxx'in self.features)and'cxxstlib'or'cstlib') if getattr(self,'ccflags',None): if Logs.verbose: Logs.warn('compat: "ccflags" was renamed to "cflags"') self.cflags=self.ccflags return old_post(self) TaskGen.task_gen.post=post def waf_version(*k,**kw): Logs.warn('wrong version (waf_version was removed in waf 1.6)') Utils.waf_version=waf_version import os @TaskGen.feature('c','cxx','d') @TaskGen.before('apply_incpaths','propagate_uselib_vars') @TaskGen.after('apply_link','process_source') def apply_uselib_local(self): env=self.env from waflib.Tools.ccroot import stlink_task self.uselib=self.to_list(getattr(self,'uselib',[])) self.includes=self.to_list(getattr(self,'includes',[])) names=self.to_list(getattr(self,'uselib_local',[])) get=self.bld.get_tgen_by_name seen=set([]) seen_uselib=set([]) tmp=Utils.deque(names) if tmp: if Logs.verbose: Logs.warn('compat: "uselib_local" is deprecated, replace by "use"') while tmp: lib_name=tmp.popleft() if lib_name in seen: continue y=get(lib_name) y.post() seen.add(lib_name) if getattr(y,'uselib_local',None): for x in self.to_list(getattr(y,'uselib_local',[])): obj=get(x) obj.post() if getattr(obj,'link_task',None): if not isinstance(obj.link_task,stlink_task): tmp.append(x) if getattr(y,'link_task',None): link_name=y.target[y.target.rfind(os.sep)+1:] if isinstance(y.link_task,stlink_task): env.append_value('STLIB',[link_name]) else: env.append_value('LIB',[link_name]) self.link_task.set_run_after(y.link_task) self.link_task.dep_nodes+=y.link_task.outputs tmp_path=y.link_task.outputs[0].parent.bldpath() if not tmp_path in env['LIBPATH']: env.prepend_value('LIBPATH',[tmp_path]) for v in self.to_list(getattr(y,'uselib',[])): if v not in seen_uselib: seen_uselib.add(v) if not env['STLIB_'+v]: if not v in self.uselib: self.uselib.insert(0,v) if getattr(y,'export_includes',None): self.includes.extend(y.to_incnodes(y.export_includes)) @TaskGen.feature('cprogram','cxxprogram','cstlib','cxxstlib','cshlib','cxxshlib','dprogram','dstlib','dshlib') @TaskGen.after('apply_link') def apply_objdeps(self): names=getattr(self,'add_objects',[]) if not names: return names=self.to_list(names) get=self.bld.get_tgen_by_name seen=[] while names: x=names[0] if x in seen: names=names[1:] continue y=get(x) if getattr(y,'add_objects',None): added=0 lst=y.to_list(y.add_objects) lst.reverse() for u in lst: if u in seen:continue added=1 names=[u]+names if added:continue y.post() seen.append(x) for t in getattr(y,'compiled_tasks',[]): self.link_task.inputs.extend(t.outputs) @TaskGen.after('apply_link') def process_obj_files(self): if not hasattr(self,'obj_files'): return for x in self.obj_files: node=self.path.find_resource(x) self.link_task.inputs.append(node) @TaskGen.taskgen_method def add_obj_file(self,file): if not hasattr(self,'obj_files'):self.obj_files=[] if not'process_obj_files'in self.meths:self.meths.append('process_obj_files') self.obj_files.append(file) old_define=Configure.ConfigurationContext.__dict__['define'] @Configure.conf def define(self,key,val,quote=True): old_define(self,key,val,quote) if key.startswith('HAVE_'): self.env[key]=1 old_undefine=Configure.ConfigurationContext.__dict__['undefine'] @Configure.conf def undefine(self,key): old_undefine(self,key) if key.startswith('HAVE_'): self.env[key]=0 def set_incdirs(self,val): Logs.warn('compat: change "export_incdirs" by "export_includes"') self.export_includes=val TaskGen.task_gen.export_incdirs=property(None,set_incdirs) def install_dir(self,path): if not path: return[] destpath=Utils.subst_vars(path,self.env) if self.is_install>0: Logs.info('* creating %s'%destpath) Utils.check_dir(destpath) elif self.is_install<0: Logs.info('* removing %s'%destpath) try: os.remove(destpath) except OSError: pass Build.BuildContext.install_dir=install_dir
gpl-3.0
manipopopo/tensorflow
tensorflow/python/keras/utils/multi_gpu_utils.py
16
9015
# Copyright 2017 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # ============================================================================== """Utilities for multi-gpu training.""" from __future__ import absolute_import from __future__ import division from __future__ import print_function from tensorflow.python.framework import ops from tensorflow.python.keras import backend as K from tensorflow.python.keras.engine.training import Model from tensorflow.python.ops import array_ops from tensorflow.python.util.tf_export import tf_export def _get_available_devices(): return [x.name for x in K.get_session().list_devices()] def _normalize_device_name(name): name = '/' + name.lower().split('device:')[1] return name @tf_export('keras.utils.multi_gpu_model') def multi_gpu_model(model, gpus, cpu_merge=True, cpu_relocation=False): """Replicates a model on different GPUs. Specifically, this function implements single-machine multi-GPU data parallelism. It works in the following way: - Divide the model's input(s) into multiple sub-batches. - Apply a model copy on each sub-batch. Every model copy is executed on a dedicated GPU. - Concatenate the results (on CPU) into one big batch. E.g. if your `batch_size` is 64 and you use `gpus=2`, then we will divide the input into 2 sub-batches of 32 samples, process each sub-batch on one GPU, then return the full batch of 64 processed samples. This induces quasi-linear speedup on up to 8 GPUs. This function is only available with the TensorFlow backend for the time being. Arguments: model: A Keras model instance. To avoid OOM errors, this model could have been built on CPU, for instance (see usage example below). gpus: Integer >= 2, number of on GPUs on which to create model replicas. cpu_merge: A boolean value to identify whether to force merging model weights under the scope of the CPU or not. cpu_relocation: A boolean value to identify whether to create the model's weights under the scope of the CPU. If the model is not defined under any preceding device scope, you can still rescue it by activating this option. Returns: A Keras `Model` instance which can be used just like the initial `model` argument, but which distributes its workload on multiple GPUs. Example 1: Training models with weights merge on CPU ```python import tensorflow as tf from keras.applications import Xception from keras.utils import multi_gpu_model import numpy as np num_samples = 1000 height = 224 width = 224 num_classes = 1000 # Instantiate the base model (or "template" model). # We recommend doing this with under a CPU device scope, # so that the model's weights are hosted on CPU memory. # Otherwise they may end up hosted on a GPU, which would # complicate weight sharing. with tf.device('/cpu:0'): model = Xception(weights=None, input_shape=(height, width, 3), classes=num_classes) # Replicates the model on 8 GPUs. # This assumes that your machine has 8 available GPUs. parallel_model = multi_gpu_model(model, gpus=8) parallel_model.compile(loss='categorical_crossentropy', optimizer='rmsprop') # Generate dummy data. x = np.random.random((num_samples, height, width, 3)) y = np.random.random((num_samples, num_classes)) # This `fit` call will be distributed on 8 GPUs. # Since the batch size is 256, each GPU will process 32 samples. parallel_model.fit(x, y, epochs=20, batch_size=256) # Save model via the template model (which shares the same weights): model.save('my_model.h5') ``` Example 2: Training models with weights merge on CPU using cpu_relocation ```python .. # Not needed to change the device scope for model definition: model = Xception(weights=None, ..) try: model = multi_gpu_model(model, cpu_relocation=True) print("Training using multiple GPUs..") except: print("Training using single GPU or CPU..") model.compile(..) .. ``` Example 3: Training models with weights merge on GPU (recommended for NV-link) ```python .. # Not needed to change the device scope for model definition: model = Xception(weights=None, ..) try: model = multi_gpu_model(model, cpu_merge=False) print("Training using multiple GPUs..") except: print("Training using single GPU or CPU..") model.compile(..) .. ``` Raises: ValueError: if the `gpus` argument does not match available devices. """ # pylint: disable=g-import-not-at-top from tensorflow.python.keras.layers.core import Lambda from tensorflow.python.keras.layers.merge import concatenate if isinstance(gpus, (list, tuple)): if len(gpus) <= 1: raise ValueError('For multi-gpu usage to be effective, ' 'call `multi_gpu_model` with `len(gpus) >= 2`. ' 'Received: `gpus=%s`' % gpus) num_gpus = len(gpus) target_gpu_ids = gpus else: if gpus <= 1: raise ValueError('For multi-gpu usage to be effective, ' 'call `multi_gpu_model` with `gpus >= 2`. ' 'Received: `gpus=%s`' % gpus) num_gpus = gpus target_gpu_ids = range(num_gpus) target_devices = ['/cpu:0'] + ['/gpu:%d' % i for i in target_gpu_ids] available_devices = _get_available_devices() available_devices = [ _normalize_device_name(name) for name in available_devices ] for device in target_devices: if device not in available_devices: raise ValueError('To call `multi_gpu_model` with `gpus=%s`, ' 'we expect the following devices to be available: %s. ' 'However this machine only has: %s. ' 'Try reducing `gpus`.' % (gpus, target_devices, available_devices)) def get_slice(data, i, parts): """Slice an array into `parts` slices and return slice `i`. Arguments: data: array to slice. i: index of slice to return. parts: number of slices to make. Returns: Slice `i` of `data`. """ shape = array_ops.shape(data) batch_size = shape[:1] input_shape = shape[1:] step = batch_size // parts if i == parts - 1: size = batch_size - step * i else: size = step size = array_ops.concat([size, input_shape], axis=0) stride = array_ops.concat([step, input_shape * 0], axis=0) start = stride * i return array_ops.slice(data, start, size) # Relocate the model definition under CPU device scope if needed if cpu_relocation: from tensorflow.python.keras.models import clone_model # pylint: disable=g-import-not-at-top with ops.device('/cpu:0'): model = clone_model(model) all_outputs = [] for i in range(len(model.outputs)): all_outputs.append([]) # Place a copy of the model on each GPU, # each getting a slice of the inputs. for i, gpu_id in enumerate(target_gpu_ids): with ops.device('/gpu:%d' % gpu_id): with ops.name_scope('replica_%d' % gpu_id): inputs = [] # Retrieve a slice of the input. for x in model.inputs: input_shape = tuple(x.get_shape().as_list())[1:] slice_i = Lambda( get_slice, output_shape=input_shape, arguments={ 'i': i, 'parts': num_gpus })( x) inputs.append(slice_i) # Apply model on slice # (creating a model replica on the target device). outputs = model(inputs) if not isinstance(outputs, list): outputs = [outputs] # Save the outputs for merging back together later. for o in range(len(outputs)): all_outputs[o].append(outputs[o]) # Merge outputs under expected scope. with ops.device('/cpu:0' if cpu_merge else '/gpu:%d' % target_gpu_ids[0]): merged = [] for name, outputs in zip(model.output_names, all_outputs): merged.append(concatenate(outputs, axis=0, name=name)) return Model(model.inputs, merged)
apache-2.0
joariasl/odoo
addons/mail/mail_mail.py
183
18372
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2010-today OpenERP SA (<http://www.openerp.com>) # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as # published by the Free Software Foundation, either version 3 of the # License, or (at your option) any later version # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU Affero General Public License for more details # # You should have received a copy of the GNU Affero General Public License # along with this program. If not, see <http://www.gnu.org/licenses/> # ############################################################################## import base64 import logging from email.utils import formataddr from urlparse import urljoin from openerp import api, tools from openerp import SUPERUSER_ID from openerp.addons.base.ir.ir_mail_server import MailDeliveryException from openerp.osv import fields, osv from openerp.tools.safe_eval import safe_eval as eval from openerp.tools.translate import _ _logger = logging.getLogger(__name__) class mail_mail(osv.Model): """ Model holding RFC2822 email messages to send. This model also provides facilities to queue and send new email messages. """ _name = 'mail.mail' _description = 'Outgoing Mails' _inherits = {'mail.message': 'mail_message_id'} _order = 'id desc' _rec_name = 'subject' _columns = { 'mail_message_id': fields.many2one('mail.message', 'Message', required=True, ondelete='cascade', auto_join=True), 'state': fields.selection([ ('outgoing', 'Outgoing'), ('sent', 'Sent'), ('received', 'Received'), ('exception', 'Delivery Failed'), ('cancel', 'Cancelled'), ], 'Status', readonly=True, copy=False), 'auto_delete': fields.boolean('Auto Delete', help="Permanently delete this email after sending it, to save space"), 'references': fields.text('References', help='Message references, such as identifiers of previous messages', readonly=1), 'email_to': fields.text('To', help='Message recipients (emails)'), 'recipient_ids': fields.many2many('res.partner', string='To (Partners)'), 'email_cc': fields.char('Cc', help='Carbon copy message recipients'), 'body_html': fields.text('Rich-text Contents', help="Rich-text/HTML message"), 'headers': fields.text('Headers', copy=False), # Auto-detected based on create() - if 'mail_message_id' was passed then this mail is a notification # and during unlink() we will not cascade delete the parent and its attachments 'notification': fields.boolean('Is Notification', help='Mail has been created to notify people of an existing mail.message'), } _defaults = { 'state': 'outgoing', } def default_get(self, cr, uid, fields, context=None): # protection for `default_type` values leaking from menu action context (e.g. for invoices) # To remove when automatic context propagation is removed in web client if context and context.get('default_type') and context.get('default_type') not in self._all_columns['type'].column.selection: context = dict(context, default_type=None) return super(mail_mail, self).default_get(cr, uid, fields, context=context) def create(self, cr, uid, values, context=None): # notification field: if not set, set if mail comes from an existing mail.message if 'notification' not in values and values.get('mail_message_id'): values['notification'] = True return super(mail_mail, self).create(cr, uid, values, context=context) def unlink(self, cr, uid, ids, context=None): # cascade-delete the parent message for all mails that are not created for a notification ids_to_cascade = self.search(cr, uid, [('notification', '=', False), ('id', 'in', ids)]) parent_msg_ids = [m.mail_message_id.id for m in self.browse(cr, uid, ids_to_cascade, context=context)] res = super(mail_mail, self).unlink(cr, uid, ids, context=context) self.pool.get('mail.message').unlink(cr, uid, parent_msg_ids, context=context) return res def mark_outgoing(self, cr, uid, ids, context=None): return self.write(cr, uid, ids, {'state': 'outgoing'}, context=context) def cancel(self, cr, uid, ids, context=None): return self.write(cr, uid, ids, {'state': 'cancel'}, context=context) @api.cr_uid def process_email_queue(self, cr, uid, ids=None, context=None): """Send immediately queued messages, committing after each message is sent - this is not transactional and should not be called during another transaction! :param list ids: optional list of emails ids to send. If passed no search is performed, and these ids are used instead. :param dict context: if a 'filters' key is present in context, this value will be used as an additional filter to further restrict the outgoing messages to send (by default all 'outgoing' messages are sent). """ if context is None: context = {} if not ids: filters = [('state', '=', 'outgoing')] if 'filters' in context: filters.extend(context['filters']) ids = self.search(cr, uid, filters, context=context) res = None try: # Force auto-commit - this is meant to be called by # the scheduler, and we can't allow rolling back the status # of previously sent emails! res = self.send(cr, uid, ids, auto_commit=True, context=context) except Exception: _logger.exception("Failed processing mail queue") return res def _postprocess_sent_message(self, cr, uid, mail, context=None, mail_sent=True): """Perform any post-processing necessary after sending ``mail`` successfully, including deleting it completely along with its attachment if the ``auto_delete`` flag of the mail was set. Overridden by subclasses for extra post-processing behaviors. :param browse_record mail: the mail that was just sent :return: True """ if mail_sent and mail.auto_delete: # done with SUPERUSER_ID to avoid giving large unlink access rights self.unlink(cr, SUPERUSER_ID, [mail.id], context=context) return True #------------------------------------------------------ # mail_mail formatting, tools and send mechanism #------------------------------------------------------ def _get_partner_access_link(self, cr, uid, mail, partner=None, context=None): """Generate URLs for links in mails: partner has access (is user): link to action_mail_redirect action that will redirect to doc or Inbox """ if context is None: context = {} if partner and partner.user_ids: base_url = self.pool.get('ir.config_parameter').get_param(cr, SUPERUSER_ID, 'web.base.url') mail_model = mail.model or 'mail.thread' url = urljoin(base_url, self.pool[mail_model]._get_access_link(cr, uid, mail, partner, context=context)) return "<span class='oe_mail_footer_access'><small>%(access_msg)s <a style='color:inherit' href='%(portal_link)s'>%(portal_msg)s</a></small></span>" % { 'access_msg': _('about') if mail.record_name else _('access'), 'portal_link': url, 'portal_msg': '%s %s' % (context.get('model_name', ''), mail.record_name) if mail.record_name else _('your messages'), } else: return None def send_get_mail_subject(self, cr, uid, mail, force=False, partner=None, context=None): """If subject is void, set the subject as 'Re: <Resource>' or 'Re: <mail.parent_id.subject>' :param boolean force: force the subject replacement """ if (force or not mail.subject) and mail.record_name: return 'Re: %s' % (mail.record_name) elif (force or not mail.subject) and mail.parent_id and mail.parent_id.subject: return 'Re: %s' % (mail.parent_id.subject) return mail.subject def send_get_mail_body(self, cr, uid, mail, partner=None, context=None): """Return a specific ir_email body. The main purpose of this method is to be inherited to add custom content depending on some module.""" body = mail.body_html # generate access links for notifications or emails linked to a specific document with auto threading link = None if mail.notification or (mail.model and mail.res_id and not mail.no_auto_thread): link = self._get_partner_access_link(cr, uid, mail, partner, context=context) if link: body = tools.append_content_to_html(body, link, plaintext=False, container_tag='div') return body def send_get_mail_to(self, cr, uid, mail, partner=None, context=None): """Forge the email_to with the following heuristic: - if 'partner', recipient specific (Partner Name <email>) - else fallback on mail.email_to splitting """ if partner: email_to = [formataddr((partner.name, partner.email))] else: email_to = tools.email_split(mail.email_to) return email_to def send_get_email_dict(self, cr, uid, mail, partner=None, context=None): """Return a dictionary for specific email values, depending on a partner, or generic to the whole recipients given by mail.email_to. :param browse_record mail: mail.mail browse_record :param browse_record partner: specific recipient partner """ body = self.send_get_mail_body(cr, uid, mail, partner=partner, context=context) body_alternative = tools.html2plaintext(body) res = { 'body': body, 'body_alternative': body_alternative, 'subject': self.send_get_mail_subject(cr, uid, mail, partner=partner, context=context), 'email_to': self.send_get_mail_to(cr, uid, mail, partner=partner, context=context), } return res def send(self, cr, uid, ids, auto_commit=False, raise_exception=False, context=None): """ Sends the selected emails immediately, ignoring their current state (mails that have already been sent should not be passed unless they should actually be re-sent). Emails successfully delivered are marked as 'sent', and those that fail to be deliver are marked as 'exception', and the corresponding error mail is output in the server logs. :param bool auto_commit: whether to force a commit of the mail status after sending each mail (meant only for scheduler processing); should never be True during normal transactions (default: False) :param bool raise_exception: whether to raise an exception if the email sending process has failed :return: True """ context = dict(context or {}) ir_mail_server = self.pool.get('ir.mail_server') ir_attachment = self.pool['ir.attachment'] for mail in self.browse(cr, SUPERUSER_ID, ids, context=context): try: # TDE note: remove me when model_id field is present on mail.message - done here to avoid doing it multiple times in the sub method if mail.model: model_id = self.pool['ir.model'].search(cr, SUPERUSER_ID, [('model', '=', mail.model)], context=context)[0] model = self.pool['ir.model'].browse(cr, SUPERUSER_ID, model_id, context=context) else: model = None if model: context['model_name'] = model.name # load attachment binary data with a separate read(), as prefetching all # `datas` (binary field) could bloat the browse cache, triggerring # soft/hard mem limits with temporary data. attachment_ids = [a.id for a in mail.attachment_ids] attachments = [(a['datas_fname'], base64.b64decode(a['datas'])) for a in ir_attachment.read(cr, SUPERUSER_ID, attachment_ids, ['datas_fname', 'datas'])] # specific behavior to customize the send email for notified partners email_list = [] if mail.email_to: email_list.append(self.send_get_email_dict(cr, uid, mail, context=context)) for partner in mail.recipient_ids: email_list.append(self.send_get_email_dict(cr, uid, mail, partner=partner, context=context)) # headers headers = {} bounce_alias = self.pool['ir.config_parameter'].get_param(cr, uid, "mail.bounce.alias", context=context) catchall_domain = self.pool['ir.config_parameter'].get_param(cr, uid, "mail.catchall.domain", context=context) if bounce_alias and catchall_domain: if mail.model and mail.res_id: headers['Return-Path'] = '%s-%d-%s-%d@%s' % (bounce_alias, mail.id, mail.model, mail.res_id, catchall_domain) else: headers['Return-Path'] = '%s-%d@%s' % (bounce_alias, mail.id, catchall_domain) if mail.headers: try: headers.update(eval(mail.headers)) except Exception: pass # Writing on the mail object may fail (e.g. lock on user) which # would trigger a rollback *after* actually sending the email. # To avoid sending twice the same email, provoke the failure earlier mail.write({'state': 'exception'}) mail_sent = False # build an RFC2822 email.message.Message object and send it without queuing res = None for email in email_list: msg = ir_mail_server.build_email( email_from=mail.email_from, email_to=email.get('email_to'), subject=email.get('subject'), body=email.get('body'), body_alternative=email.get('body_alternative'), email_cc=tools.email_split(mail.email_cc), reply_to=mail.reply_to, attachments=attachments, message_id=mail.message_id, references=mail.references, object_id=mail.res_id and ('%s-%s' % (mail.res_id, mail.model)), subtype='html', subtype_alternative='plain', headers=headers) try: res = ir_mail_server.send_email(cr, uid, msg, mail_server_id=mail.mail_server_id.id, context=context) except AssertionError as error: if error.message == ir_mail_server.NO_VALID_RECIPIENT: # No valid recipient found for this particular # mail item -> ignore error to avoid blocking # delivery to next recipients, if any. If this is # the only recipient, the mail will show as failed. _logger.warning("Ignoring invalid recipients for mail.mail %s: %s", mail.message_id, email.get('email_to')) else: raise if res: mail.write({'state': 'sent', 'message_id': res}) mail_sent = True # /!\ can't use mail.state here, as mail.refresh() will cause an error # see revid:odo@openerp.com-20120622152536-42b2s28lvdv3odyr in 6.1 if mail_sent: _logger.info('Mail with ID %r and Message-Id %r successfully sent', mail.id, mail.message_id) self._postprocess_sent_message(cr, uid, mail, context=context, mail_sent=mail_sent) except MemoryError: # prevent catching transient MemoryErrors, bubble up to notify user or abort cron job # instead of marking the mail as failed _logger.exception('MemoryError while processing mail with ID %r and Msg-Id %r. '\ 'Consider raising the --limit-memory-hard startup option', mail.id, mail.message_id) raise except Exception as e: _logger.exception('failed sending mail.mail %s', mail.id) mail.write({'state': 'exception'}) self._postprocess_sent_message(cr, uid, mail, context=context, mail_sent=False) if raise_exception: if isinstance(e, AssertionError): # get the args of the original error, wrap into a value and throw a MailDeliveryException # that is an except_orm, with name and value as arguments value = '. '.join(e.args) raise MailDeliveryException(_("Mail Delivery Failed"), value) raise if auto_commit is True: cr.commit() return True
agpl-3.0
tkaitchuck/nupic
external/linux64/lib/python2.6/site-packages/numpy/polynomial/tests/test_laguerre.py
24
17474
"""Tests for hermendre module. """ from __future__ import division import numpy as np import numpy.polynomial.laguerre as lag import numpy.polynomial.polynomial as poly from numpy.testing import * L0 = np.array([1 ])/1 L1 = np.array([1 , -1 ])/1 L2 = np.array([2 , -4 , 1 ])/2 L3 = np.array([6 , -18 , 9 , -1 ])/6 L4 = np.array([24 , -96 , 72 , -16 , 1 ])/24 L5 = np.array([120 , -600 , 600 , -200 , 25 , -1 ])/120 L6 = np.array([720 , -4320 , 5400 , -2400 , 450 , -36 , 1 ])/720 Llist = [L0, L1, L2, L3, L4, L5, L6] def trim(x) : return lag.lagtrim(x, tol=1e-6) class TestConstants(TestCase) : def test_lagdomain(self) : assert_equal(lag.lagdomain, [0, 1]) def test_lagzero(self) : assert_equal(lag.lagzero, [0]) def test_lagone(self) : assert_equal(lag.lagone, [1]) def test_lagx(self) : assert_equal(lag.lagx, [1, -1]) class TestArithmetic(TestCase) : x = np.linspace(-3, 3, 100) y0 = poly.polyval(x, L0) y1 = poly.polyval(x, L1) y2 = poly.polyval(x, L2) y3 = poly.polyval(x, L3) y4 = poly.polyval(x, L4) y5 = poly.polyval(x, L5) y6 = poly.polyval(x, L6) y = [y0, y1, y2, y3, y4, y5, y6] def test_lagval(self) : def f(x) : return x*(x**2 - 1) #check empty input assert_equal(lag.lagval([], [1]).size, 0) #check normal input) for i in range(7) : msg = "At i=%d" % i ser = np.zeros tgt = self.y[i] res = lag.lagval(self.x, [0]*i + [1]) assert_almost_equal(res, tgt, err_msg=msg) #check that shape is preserved for i in range(3) : dims = [2]*i x = np.zeros(dims) assert_equal(lag.lagval(x, [1]).shape, dims) assert_equal(lag.lagval(x, [1,0]).shape, dims) assert_equal(lag.lagval(x, [1,0,0]).shape, dims) def test_lagadd(self) : for i in range(5) : for j in range(5) : msg = "At i=%d, j=%d" % (i,j) tgt = np.zeros(max(i,j) + 1) tgt[i] += 1 tgt[j] += 1 res = lag.lagadd([0]*i + [1], [0]*j + [1]) assert_equal(trim(res), trim(tgt), err_msg=msg) def test_lagsub(self) : for i in range(5) : for j in range(5) : msg = "At i=%d, j=%d" % (i,j) tgt = np.zeros(max(i,j) + 1) tgt[i] += 1 tgt[j] -= 1 res = lag.lagsub([0]*i + [1], [0]*j + [1]) assert_equal(trim(res), trim(tgt), err_msg=msg) def test_lagmulx(self): assert_equal(lag.lagmulx([0]), [0]) assert_equal(lag.lagmulx([1]), [1,-1]) for i in range(1, 5): ser = [0]*i + [1] tgt = [0]*(i - 1) + [-i, 2*i + 1, -(i + 1)] assert_almost_equal(lag.lagmulx(ser), tgt) def test_lagmul(self) : # check values of result for i in range(5) : pol1 = [0]*i + [1] val1 = lag.lagval(self.x, pol1) for j in range(5) : msg = "At i=%d, j=%d" % (i,j) pol2 = [0]*j + [1] val2 = lag.lagval(self.x, pol2) pol3 = lag.lagmul(pol1, pol2) val3 = lag.lagval(self.x, pol3) assert_(len(pol3) == i + j + 1, msg) assert_almost_equal(val3, val1*val2, err_msg=msg) def test_lagdiv(self) : for i in range(5) : for j in range(5) : msg = "At i=%d, j=%d" % (i,j) ci = [0]*i + [1] cj = [0]*j + [1] tgt = lag.lagadd(ci, cj) quo, rem = lag.lagdiv(tgt, ci) res = lag.lagadd(lag.lagmul(quo, ci), rem) assert_almost_equal(trim(res), trim(tgt), err_msg=msg) class TestCalculus(TestCase) : def test_lagint(self) : # check exceptions assert_raises(ValueError, lag.lagint, [0], .5) assert_raises(ValueError, lag.lagint, [0], -1) assert_raises(ValueError, lag.lagint, [0], 1, [0,0]) # test integration of zero polynomial for i in range(2, 5): k = [0]*(i - 2) + [1] res = lag.lagint([0], m=i, k=k) assert_almost_equal(res, [1, -1]) # check single integration with integration constant for i in range(5) : scl = i + 1 pol = [0]*i + [1] tgt = [i] + [0]*i + [1/scl] lagpol = lag.poly2lag(pol) lagint = lag.lagint(lagpol, m=1, k=[i]) res = lag.lag2poly(lagint) assert_almost_equal(trim(res), trim(tgt)) # check single integration with integration constant and lbnd for i in range(5) : scl = i + 1 pol = [0]*i + [1] lagpol = lag.poly2lag(pol) lagint = lag.lagint(lagpol, m=1, k=[i], lbnd=-1) assert_almost_equal(lag.lagval(-1, lagint), i) # check single integration with integration constant and scaling for i in range(5) : scl = i + 1 pol = [0]*i + [1] tgt = [i] + [0]*i + [2/scl] lagpol = lag.poly2lag(pol) lagint = lag.lagint(lagpol, m=1, k=[i], scl=2) res = lag.lag2poly(lagint) assert_almost_equal(trim(res), trim(tgt)) # check multiple integrations with default k for i in range(5) : for j in range(2,5) : pol = [0]*i + [1] tgt = pol[:] for k in range(j) : tgt = lag.lagint(tgt, m=1) res = lag.lagint(pol, m=j) assert_almost_equal(trim(res), trim(tgt)) # check multiple integrations with defined k for i in range(5) : for j in range(2,5) : pol = [0]*i + [1] tgt = pol[:] for k in range(j) : tgt = lag.lagint(tgt, m=1, k=[k]) res = lag.lagint(pol, m=j, k=range(j)) assert_almost_equal(trim(res), trim(tgt)) # check multiple integrations with lbnd for i in range(5) : for j in range(2,5) : pol = [0]*i + [1] tgt = pol[:] for k in range(j) : tgt = lag.lagint(tgt, m=1, k=[k], lbnd=-1) res = lag.lagint(pol, m=j, k=range(j), lbnd=-1) assert_almost_equal(trim(res), trim(tgt)) # check multiple integrations with scaling for i in range(5) : for j in range(2,5) : pol = [0]*i + [1] tgt = pol[:] for k in range(j) : tgt = lag.lagint(tgt, m=1, k=[k], scl=2) res = lag.lagint(pol, m=j, k=range(j), scl=2) assert_almost_equal(trim(res), trim(tgt)) def test_lagder(self) : # check exceptions assert_raises(ValueError, lag.lagder, [0], .5) assert_raises(ValueError, lag.lagder, [0], -1) # check that zeroth deriviative does nothing for i in range(5) : tgt = [1] + [0]*i res = lag.lagder(tgt, m=0) assert_equal(trim(res), trim(tgt)) # check that derivation is the inverse of integration for i in range(5) : for j in range(2,5) : tgt = [1] + [0]*i res = lag.lagder(lag.lagint(tgt, m=j), m=j) assert_almost_equal(trim(res), trim(tgt)) # check derivation with scaling for i in range(5) : for j in range(2,5) : tgt = [1] + [0]*i res = lag.lagder(lag.lagint(tgt, m=j, scl=2), m=j, scl=.5) assert_almost_equal(trim(res), trim(tgt)) class TestMisc(TestCase) : def test_lagfromroots(self) : res = lag.lagfromroots([]) assert_almost_equal(trim(res), [1]) for i in range(1,5) : roots = np.cos(np.linspace(-np.pi, 0, 2*i + 1)[1::2]) pol = lag.lagfromroots(roots) res = lag.lagval(roots, pol) tgt = 0 assert_(len(pol) == i + 1) assert_almost_equal(lag.lag2poly(pol)[-1], 1) assert_almost_equal(res, tgt) def test_lagroots(self) : assert_almost_equal(lag.lagroots([1]), []) assert_almost_equal(lag.lagroots([0, 1]), [1]) for i in range(2,5) : tgt = np.linspace(0, 3, i) res = lag.lagroots(lag.lagfromroots(tgt)) assert_almost_equal(trim(res), trim(tgt)) def test_lagvander(self) : # check for 1d x x = np.arange(3) v = lag.lagvander(x, 3) assert_(v.shape == (3,4)) for i in range(4) : coef = [0]*i + [1] assert_almost_equal(v[...,i], lag.lagval(x, coef)) # check for 2d x x = np.array([[1,2],[3,4],[5,6]]) v = lag.lagvander(x, 3) assert_(v.shape == (3,2,4)) for i in range(4) : coef = [0]*i + [1] assert_almost_equal(v[...,i], lag.lagval(x, coef)) def test_lagfit(self) : def f(x) : return x*(x - 1)*(x - 2) # Test exceptions assert_raises(ValueError, lag.lagfit, [1], [1], -1) assert_raises(TypeError, lag.lagfit, [[1]], [1], 0) assert_raises(TypeError, lag.lagfit, [], [1], 0) assert_raises(TypeError, lag.lagfit, [1], [[[1]]], 0) assert_raises(TypeError, lag.lagfit, [1, 2], [1], 0) assert_raises(TypeError, lag.lagfit, [1], [1, 2], 0) assert_raises(TypeError, lag.lagfit, [1], [1], 0, w=[[1]]) assert_raises(TypeError, lag.lagfit, [1], [1], 0, w=[1,1]) # Test fit x = np.linspace(0,2) y = f(x) # coef3 = lag.lagfit(x, y, 3) assert_equal(len(coef3), 4) assert_almost_equal(lag.lagval(x, coef3), y) # coef4 = lag.lagfit(x, y, 4) assert_equal(len(coef4), 5) assert_almost_equal(lag.lagval(x, coef4), y) # coef2d = lag.lagfit(x, np.array([y,y]).T, 3) assert_almost_equal(coef2d, np.array([coef3,coef3]).T) # test weighting w = np.zeros_like(x) yw = y.copy() w[1::2] = 1 y[0::2] = 0 wcoef3 = lag.lagfit(x, yw, 3, w=w) assert_almost_equal(wcoef3, coef3) # wcoef2d = lag.lagfit(x, np.array([yw,yw]).T, 3, w=w) assert_almost_equal(wcoef2d, np.array([coef3,coef3]).T) def test_lagtrim(self) : coef = [2, -1, 1, 0] # Test exceptions assert_raises(ValueError, lag.lagtrim, coef, -1) # Test results assert_equal(lag.lagtrim(coef), coef[:-1]) assert_equal(lag.lagtrim(coef, 1), coef[:-3]) assert_equal(lag.lagtrim(coef, 2), [0]) def test_lagline(self) : assert_equal(lag.lagline(3,4), [7, -4]) def test_lag2poly(self) : for i in range(7) : assert_almost_equal(lag.lag2poly([0]*i + [1]), Llist[i]) def test_poly2lag(self) : for i in range(7) : assert_almost_equal(lag.poly2lag(Llist[i]), [0]*i + [1]) def assert_poly_almost_equal(p1, p2): assert_almost_equal(p1.coef, p2.coef) assert_equal(p1.domain, p2.domain) class TestLaguerreClass(TestCase) : p1 = lag.Laguerre([1,2,3]) p2 = lag.Laguerre([1,2,3], [0,1]) p3 = lag.Laguerre([1,2]) p4 = lag.Laguerre([2,2,3]) p5 = lag.Laguerre([3,2,3]) def test_equal(self) : assert_(self.p1 == self.p1) assert_(self.p2 == self.p2) assert_(not self.p1 == self.p2) assert_(not self.p1 == self.p3) assert_(not self.p1 == [1,2,3]) def test_not_equal(self) : assert_(not self.p1 != self.p1) assert_(not self.p2 != self.p2) assert_(self.p1 != self.p2) assert_(self.p1 != self.p3) assert_(self.p1 != [1,2,3]) def test_add(self) : tgt = lag.Laguerre([2,4,6]) assert_(self.p1 + self.p1 == tgt) assert_(self.p1 + [1,2,3] == tgt) assert_([1,2,3] + self.p1 == tgt) def test_sub(self) : tgt = lag.Laguerre([1]) assert_(self.p4 - self.p1 == tgt) assert_(self.p4 - [1,2,3] == tgt) assert_([2,2,3] - self.p1 == tgt) def test_mul(self) : tgt = lag.Laguerre([ 14., -16., 56., -72., 54.]) assert_poly_almost_equal(self.p1 * self.p1, tgt) assert_poly_almost_equal(self.p1 * [1,2,3], tgt) assert_poly_almost_equal([1,2,3] * self.p1, tgt) def test_floordiv(self) : tgt = lag.Laguerre([1]) assert_(self.p4 // self.p1 == tgt) assert_(self.p4 // [1,2,3] == tgt) assert_([2,2,3] // self.p1 == tgt) def test_mod(self) : tgt = lag.Laguerre([1]) assert_((self.p4 % self.p1) == tgt) assert_((self.p4 % [1,2,3]) == tgt) assert_(([2,2,3] % self.p1) == tgt) def test_divmod(self) : tquo = lag.Laguerre([1]) trem = lag.Laguerre([2]) quo, rem = divmod(self.p5, self.p1) assert_(quo == tquo and rem == trem) quo, rem = divmod(self.p5, [1,2,3]) assert_(quo == tquo and rem == trem) quo, rem = divmod([3,2,3], self.p1) assert_(quo == tquo and rem == trem) def test_pow(self) : tgt = lag.Laguerre([1]) for i in range(5) : res = self.p1**i assert_(res == tgt) tgt = tgt*self.p1 def test_call(self) : # domain = [0, 1] x = np.linspace(0, 1) tgt = 3*(.5*x**2 - 2*x + 1) + 2*(-x + 1) + 1 assert_almost_equal(self.p1(x), tgt) # domain = [0, 1] x = np.linspace(.5, 1) xx = 2*x - 1 assert_almost_equal(self.p2(x), self.p1(xx)) def test_degree(self) : assert_equal(self.p1.degree(), 2) def test_cutdeg(self) : assert_raises(ValueError, self.p1.cutdeg, .5) assert_raises(ValueError, self.p1.cutdeg, -1) assert_equal(len(self.p1.cutdeg(3)), 3) assert_equal(len(self.p1.cutdeg(2)), 3) assert_equal(len(self.p1.cutdeg(1)), 2) assert_equal(len(self.p1.cutdeg(0)), 1) def test_convert(self) : x = np.linspace(-1,1) p = self.p1.convert(domain=[0,1]) assert_almost_equal(p(x), self.p1(x)) def test_mapparms(self) : parms = self.p2.mapparms() assert_almost_equal(parms, [-1, 2]) def test_trim(self) : coef = [1, 1e-6, 1e-12, 0] p = lag.Laguerre(coef) assert_equal(p.trim().coef, coef[:3]) assert_equal(p.trim(1e-10).coef, coef[:2]) assert_equal(p.trim(1e-5).coef, coef[:1]) def test_truncate(self) : assert_raises(ValueError, self.p1.truncate, .5) assert_raises(ValueError, self.p1.truncate, 0) assert_equal(len(self.p1.truncate(4)), 3) assert_equal(len(self.p1.truncate(3)), 3) assert_equal(len(self.p1.truncate(2)), 2) assert_equal(len(self.p1.truncate(1)), 1) def test_copy(self) : p = self.p1.copy() assert_(self.p1 == p) def test_integ(self) : p = self.p2.integ() assert_almost_equal(p.coef, lag.lagint([1,2,3], 1, 0, scl=.5)) p = self.p2.integ(lbnd=0) assert_almost_equal(p(0), 0) p = self.p2.integ(1, 1) assert_almost_equal(p.coef, lag.lagint([1,2,3], 1, 1, scl=.5)) p = self.p2.integ(2, [1, 2]) assert_almost_equal(p.coef, lag.lagint([1,2,3], 2, [1,2], scl=.5)) def test_deriv(self) : p = self.p2.integ(2, [1, 2]) assert_almost_equal(p.deriv(1).coef, self.p2.integ(1, [1]).coef) assert_almost_equal(p.deriv(2).coef, self.p2.coef) def test_roots(self) : p = lag.Laguerre(lag.poly2lag([0, -1, 0, 1]), [0, 1]) res = p.roots() tgt = [0, .5, 1] assert_almost_equal(res, tgt) def test_linspace(self): xdes = np.linspace(0, 1, 20) ydes = self.p2(xdes) xres, yres = self.p2.linspace(20) assert_almost_equal(xres, xdes) assert_almost_equal(yres, ydes) def test_fromroots(self) : roots = [0, .5, 1] p = lag.Laguerre.fromroots(roots, domain=[0, 1]) res = p.coef tgt = lag.poly2lag([0, -1, 0, 1]) assert_almost_equal(res, tgt) def test_fit(self) : def f(x) : return x*(x - 1)*(x - 2) x = np.linspace(0,3) y = f(x) # test default value of domain p = lag.Laguerre.fit(x, y, 3) assert_almost_equal(p.domain, [0,3]) # test that fit works in given domains p = lag.Laguerre.fit(x, y, 3, None) assert_almost_equal(p(x), y) assert_almost_equal(p.domain, [0,3]) p = lag.Laguerre.fit(x, y, 3, []) assert_almost_equal(p(x), y) assert_almost_equal(p.domain, [-1, 1]) # test that fit accepts weights. w = np.zeros_like(x) yw = y.copy() w[1::2] = 1 yw[0::2] = 0 p = lag.Laguerre.fit(x, yw, 3, w=w) assert_almost_equal(p(x), y) def test_identity(self) : x = np.linspace(0,3) p = lag.Laguerre.identity() assert_almost_equal(p(x), x) p = lag.Laguerre.identity([1,3]) assert_almost_equal(p(x), x) # if __name__ == "__main__": run_module_suite()
gpl-3.0
prop/titanium_mobile
support/iphone/builder.py
33
60056
#!/usr/bin/env python # -*- coding: utf-8 -*- # # Build and Launch iPhone Application in Simulator or install # the application on the device via iTunes # import os, sys, uuid, subprocess, shutil, signal, string, traceback, imp, filecmp, inspect import platform, time, re, run, glob, codecs, hashlib, datetime, plistlib from compiler import Compiler, softlink_for_simulator from projector import Projector from xml.dom.minidom import parseString from xml.etree.ElementTree import ElementTree from os.path import join, splitext, split, exists from tools import ensure_dev_path # the template_dir is the path where this file lives on disk template_dir = os.path.abspath(os.path.dirname(sys._getframe(0).f_code.co_filename)) # add the parent and the common directory so we can load libraries from those paths too sys.path.append(os.path.join(template_dir,'../')) sys.path.append(os.path.join(template_dir,'../common')) sys.path.append(os.path.join(template_dir, '../module')) script_ok = False from tiapp import * from css import csscompiler import localecompiler from module import ModuleDetector from tools import * ignoreFiles = ['.gitignore', '.cvsignore'] ignoreDirs = ['.git','.svn', 'CVS'] # need this so unicode works sys.stdout = codecs.getwriter('utf-8')(sys.stdout) def version_sort(a,b): x = float(a[0:3]) # ignore more than 2 places y = float(b[0:3]) # ignore more than 2 places if x > y: return -1 if x < y: return 1 return 0 # this will return the version of the iOS SDK that we have installed def check_iphone_sdk(s): found = [] output = run.run(["xcodebuild","-showsdks"],True,False) #print output if output: for line in output.split("\n"): if line[0:1] == '\t': line = line.strip() i = line.find('-sdk') if i < 0: continue type = line[0:i] cmd = line[i+5:] if cmd.find("iphoneos")==0: ver = cmd[8:] found.append(ver) # The sanity check doesn't have to be as thorough as prereq. if s in found: return s # Sanity check failed. Let's find something close. return sorted(found,version_sort)[0] def dequote(s): if s[0:1] == '"': return s[1:-1] return s # force kill the simulator if running def kill_simulator(): run.run(['/usr/bin/killall',"ios-sim"],True) run.run(['/usr/bin/killall',"iPhone Simulator"],True) def write_project_property(f,prop,val): existing_val = read_project_property(f,prop) if existing_val!=val: fx = open(f,'w') fx.write("%s=%s\n"%(prop,val)) fx.close() def read_project_property(f,prop): if os.path.exists(f): contents = open(f).read() for line in contents.splitlines(False): (k,v) = line.split("=") if k == prop: return v return None def read_project_appid(f): return read_project_property(f,'TI_APPID') def read_project_version(f): return read_project_property(f,'TI_VERSION') def infoplist_has_appid(f,appid): if os.path.exists(f): contents = codecs.open(f,encoding='utf-8').read() return contents.find(appid)>0 return False def copy_module_resources(source, target, copy_all=False, force=False): if not os.path.exists(os.path.expanduser(target)): os.makedirs(os.path.expanduser(target)) for root, dirs, files in os.walk(source, True, None, True): for name in ignoreDirs: if name in dirs: dirs.remove(name) # don't visit ignored directories for file in files: if copy_all==False and splitext(file)[-1] in ('.html', '.js', '.css', '.a', '.m', '.c', '.cpp', '.h', '.mm'): continue if file in ignoreFiles: continue from_ = os.path.join(root, file) to_ = os.path.expanduser(from_.replace(source, target, 1)) to_directory = os.path.expanduser(split(to_)[0]) if not exists(to_directory): os.makedirs(to_directory) # only copy if different filesize or doesn't exist if not os.path.exists(to_) or os.path.getsize(from_)!=os.path.getsize(to_) or force: if os.path.exists(to_): os.remove(to_) shutil.copyfile(from_, to_) # WARNING: This could be a time bomb waiting to happen, because it mangles # the app bundle name for NO REASON. Or... does it? def make_app_name(s): r = re.compile('[0-9a-zA-Z_]') buf = '' for i in s: if i=='-': buf+='_' continue if r.match(i)!=None: buf+=i # if name starts with number, we simply append a k to it if re.match('^[0-9]+',buf): buf = 'k%s' % buf return buf def getText(nodelist): rc = "" for node in nodelist: if node.nodeType == node.TEXT_NODE: rc+=node.data elif node.nodeType == node.ELEMENT_NODE: rc+=getText(node.childNodes) return rc def make_map(dict): props = {} curkey = None for i in dict.childNodes: if i.nodeType == 1: if i.nodeName == 'key': curkey = str(getText(i.childNodes)).strip() elif i.nodeName == 'dict': props[curkey] = make_map(i) curkey = None elif i.nodeName == 'array': s = i.getElementsByTagName('string') if len(s): txt = '' for t in s: txt+=getText(t.childNodes) props[curkey]=txt else: props[curkey]=None curkey = None else: if i.childNodes.length > 0: props[curkey] = getText(i.childNodes) else: props[curkey] = i.nodeName curkey = None return props def dump_resources_listing(rootdir,out): out.write("\nFile listing for %s\n\n" % rootdir) total = 0 for root, subFolders, files in os.walk(rootdir, True, None, True): for file in files: p = os.path.join(root,file) s = os.path.getsize(p) total+=s s = "[%.0f]" % s p = p[len(rootdir)+1:] if p.startswith('build/android') or p.startswith('build/mobileweb'): continue out.write(" %s %s\n" % (string.ljust(p,120),string.ljust(s,8))) out.write("-" * 130) out.write("\nTotal files: %.1f MB\n" % ((total/1024)/1024)) out.write("\n") def dump_infoplist(infoplist,out): plist = codecs.open(infoplist, encoding='utf-8').read() out.write("Contents of Info.plist\n\n") out.write(plist) out.write("\n") out.write("=" * 130) out.write("\n\n") def read_provisioning_profile(f,o): f = open(f,'rb').read() b = f.index('<?xml') e = f.index('</plist>') xml_content = f[b:e+8] o.write("Reading provisioning profile:\n\n%s\n" % xml_content) dom = parseString(xml_content) dict = dom.getElementsByTagName('dict')[0] props = make_map(dict) return props def get_aps_env(provisioning_profile): entitlements = provisioning_profile['Entitlements'] if entitlements.has_key('aps-environment'): return entitlements['aps-environment'] return None def get_task_allow(provisioning_profile): entitlements = provisioning_profile['Entitlements'] return entitlements['get-task-allow'] def get_app_prefix(provisioning_profile): appid_prefix = provisioning_profile['ApplicationIdentifierPrefix'] return appid_prefix def get_profile_uuid(provisioning_profile): return provisioning_profile['UUID'] def generate_customized_entitlements(provisioning_profile,appid,uuid,command,out): get_task_value = get_task_allow(provisioning_profile) aps_env = get_aps_env(provisioning_profile) buffer = """<?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> """ app_prefix = None if command=='distribute': app_prefix = get_app_prefix(provisioning_profile) out.write("Using app_prefix = %s\n\n" % (app_prefix)) buffer+=""" <key>application-identifier</key> <string>%s.%s</string> """ % (app_prefix,appid) buffer+="<key>get-task-allow</key>\n <%s/>" % get_task_value if aps_env!=None: buffer+="\n<key>aps-environment</key>\n <string>%s</string>" % aps_env if command=='distribute': buffer+=""" <key>keychain-access-groups</key> <array> <string>%s.%s</string> </array> """ % (app_prefix,appid) buffer+=""" </dict> </plist>""" return buffer def xcode_version(): output = run.run(['xcodebuild','-version'],True,False) if output: versionLine = output.split('\n')[0] return float(versionLine.split(' ')[1].rpartition('.')[0]) def distribute_xc4(name, icon, log): # Locations of bundle, app binary, dsym info log.write("Creating distribution for xcode4...\n"); timestamp = datetime.datetime.now() date = timestamp.date().isoformat() time = timestamp.time().strftime('%H-%M-%S') archive_name = os.path.join(date,'%s_%s' % (name, time)) archive_bundle = os.path.join(os.path.expanduser("~/Library/Developer/Xcode/Archives"),"%s.xcarchive" % archive_name) archive_app = os.path.join(archive_bundle,"Products","Applications","%s.app" % name) archive_dsym = os.path.join(archive_bundle,"dSYM") # create directories if not os.access(archive_bundle, os.F_OK): os.makedirs(archive_bundle) if not os.access(archive_app, os.F_OK): os.makedirs(archive_app) if not os.access(archive_dsym, os.F_OK): os.makedirs(archive_dsym) # copy app bundles into the approps. places os.system('ditto "%s.app" "%s"' % (name,archive_app)) os.system('ditto "%s.app.dSYM" "%s"' % (name,archive_dsym)) # plist processing time - this is the biggest difference from XC3. archive_info_plist = os.path.join(archive_bundle,'Info.plist') log.write("Writing archive plist to: %s\n\n" % archive_info_plist) # load existing plist values so that we can use them in generating the archive # plist os.system('/usr/bin/plutil -convert xml1 -o "%s" "%s"' % (os.path.join(archive_bundle,'Info.xml.plist'),os.path.join(archive_app,'Info.plist'))) project_info_plist = plistlib.readPlist(os.path.join(archive_bundle,'Info.xml.plist')) appbundle = "Applications/%s.app" % name # NOTE: We chop off the end '.' of 'CFBundleVersion' to provide the 'short' version version = project_info_plist['CFBundleVersion'] app_version_ = version.split('.') if(len(app_version_) > 3): version = app_version_[0]+'.'+app_version_[1]+'.'+app_version_[2] archive_info = { 'ApplicationProperties' : { 'ApplicationPath' : appbundle, 'CFBundleIdentifier' : project_info_plist['CFBundleIdentifier'], 'CFBundleShortVersionString' : version, 'IconPaths' : [os.path.join(appbundle,icon), os.path.join(appbundle,icon)] }, 'ArchiveVersion' : float(1), 'CreationDate' : datetime.datetime.utcnow(), 'Name' : name, 'SchemeName' : name } # write out the archive plist and clean up log.write("%s\n\n" % archive_info) plistlib.writePlist(archive_info,archive_info_plist) os.remove(os.path.join(archive_bundle,'Info.xml.plist')) # Workaround for dumb xcode4 bug that doesn't update the organizer unless # files are touched in a very specific manner temp = os.path.join(os.path.expanduser("~/Library/Developer/Xcode/Archives"),"temp") os.rename(archive_bundle,temp) os.rename(temp,archive_bundle) def is_indexing_enabled(tiapp, simulator_dir, **kwargs): # darwin versions: # - 9.x: Leopard (10.5) # - 10.x: Snow Leopard (10.6) # - 11.x: Lion (10.7) # for testing purposes platform_release = kwargs.get("platform_release", platform.release()) darwin_version = [int(n) for n in platform_release.split(".")] enable_mdfind = True if tiapp.has_app_property('ti.ios.enablemdfind'): enable_mdfind = tiapp.to_bool(tiapp.get_app_property('ti.ios.enablemdfind')) # mdfind is specifically disabled, so don't use it if not enable_mdfind: return False # pre-Leopard, mdfind / mdutil don't exist if darwin_version[0] < 10: return False # for testing purposes indexer_status = kwargs.get("indexer_status") if indexer_status == None: indexer_status = run.run(['mdutil', '-a', '-s'], True) # An error occurred running mdutil, play it safe if indexer_status == None: return False lines = indexer_status.splitlines() mount_point_status = {} for i in range(0, len(lines), 2): mount_point = lines[i].rstrip(':') if len(lines) > (i+1): status = lines[i+1].strip('\t.') # Only add mount points that the simulator_dir starts with if simulator_dir.startswith(mount_point): mount_point_status[mount_point] = status # mdutil must be disabled if we don't get the right amount of output else: return False if len(mount_point_status) > 0: # There may be multiple volumes that have a mount point that the # simulator_dir matches, so the one with the longest length # *should* be the most specific / correct mount point. mount_points = mount_point_status.keys() mount_points.sort(lambda a, b: cmp(len(b), len(a))) status = mount_point_status[mount_points[0]] if 'Indexing enabled' in status: return True return False HEADER = """/** * Appcelerator Titanium Mobile * This is generated code. Do not modify. Your changes *will* be lost. * Generated code is Copyright (c) 2009-2011 by Appcelerator, Inc. * All Rights Reserved. */ #import <Foundation/Foundation.h> """ DEFAULTS_IMPL_HEADER= """#import "TiUtils.h" #import "ApplicationDefaults.h" @implementation ApplicationDefaults +(NSDictionary*)launchUrl { return nil; } + (NSMutableDictionary*) copyDefaults { NSMutableDictionary * _property = [[NSMutableDictionary alloc] init];\n """ FOOTER =""" @end """ def copy_tiapp_properties(project_dir): tiapp = ElementTree() src_root = os.path.dirname(sys.argv[0]) assets_tiappxml = os.path.join(project_dir,'tiapp.xml') if not os.path.exists(assets_tiappxml): shutil.copy(os.path.join(project_dir, 'tiapp.xml'), assets_tiappxml) tiapp.parse(open(assets_tiappxml, 'r')) impf = open("ApplicationDefaults.m",'w+') appl_default = os.path.join(project_dir,'build','iphone','Classes','ApplicationDefaults.m') impf.write(HEADER) impf.write(DEFAULTS_IMPL_HEADER) for property_el in tiapp.findall("property"): name = property_el.get("name") type = property_el.get("type") value = property_el.text if name == None: continue if value == None: value = "" if type == "string": impf.write(""" [_property setObject:[TiUtils stringValue:@"%s"] forKey:@"%s"];\n"""%(value,name)) elif type == "bool": impf.write(""" [_property setObject:[NSNumber numberWithBool:[TiUtils boolValue:@"%s"]] forKey:@"%s"];\n"""%(value,name)) elif type == "int": impf.write(""" [_property setObject:[NSNumber numberWithInt:[TiUtils intValue:@"%s"]] forKey:@"%s"];\n"""%(value,name)) elif type == "double": impf.write(""" [_property setObject:[NSNumber numberWithDouble:[TiUtils doubleValue:@"%s"]] forKey:@"%s"];\n"""%(value,name)) elif type == None: impf.write(""" [_property setObject:[TiUtils stringValue:@"%s"] forKey:@"%s"];\n"""%(value,name)) else: print """[WARN] Cannot set property "%s" , type "%s" not supported""" % (name,type) if (len(tiapp.findall("property")) > 0) : impf.write("\n return _property;\n}") else: impf.write("\n [_property release];") impf.write("\n return nil;\n}") impf.write(FOOTER) impf.close() if open(appl_default,'r').read() == open('ApplicationDefaults.m','r').read(): os.remove('ApplicationDefaults.m') return False else: shutil.copyfile('ApplicationDefaults.m',appl_default) os.remove('ApplicationDefaults.m') return True def cleanup_app_logfiles(tiapp, log_id, iphone_version): print "[DEBUG] finding old log files" sys.stdout.flush() simulator_dir = os.path.expanduser('~/Library/Application\ Support/iPhone\ Simulator/%s' % iphone_version) # No need to clean if the directory doesn't exist if not os.path.exists(simulator_dir): return results = None # If the indexer is enabled, we can use spotlight for faster searching if is_indexing_enabled(tiapp, simulator_dir): print "[DEBUG] Searching for old log files with mdfind..." sys.stdout.flush() results = run.run(['mdfind', '-onlyin', simulator_dir, '-name', '%s.log' % log_id ], True) # Indexer is disabled, revert to manual crawling if results == None: print "[DEBUG] Searching for log files without mdfind..." sys.stdout.flush() def find_all_log_files(folder, fname): results = [] for root, dirs, files in os.walk(os.path.expanduser(folder)): for file in files: if fname==file: fullpath = os.path.join(root, file) results.append(fullpath) return results for f in find_all_log_files(simulator_dir, '%s.log' % log_id): print "[DEBUG] removing old log file: %s" % f sys.stdout.flush() os.remove(f) else: for i in results.splitlines(False): print "[DEBUG] removing old log file: %s" % i os.remove(i) def find_name_conflicts(project_dir, project_name): for dir in ['Resources', 'Resources/iphone']: for name in os.listdir(os.path.join(project_dir, dir)): if name.lower() == project_name.lower(): print "[ERROR] Project name %s conflicts with resource named %s: Cannot build. Please change one." % (project_name, os.path.join(project_dir, dir, name)) sys.exit(1) pass # # this script is invoked from our tooling but you can run from command line too if # you know the arguments # # the current pattern is <command> [arguments] # # where the arguments are dependent on the command being passed # def main(args): global script_ok argc = len(args) if argc < 2 or argc==2 and (args[1]=='--help' or args[1]=='-h'): print "%s <command> <version> <project_dir> <appid> <name> [options]" % os.path.basename(args[0]) print print "available commands: " print print " install install the app to itunes for testing on iphone" print " simulator build and run on the iphone simulator" print " adhoc build for adhoc distribution" print " distribute build final distribution bundle" print " xcode build from within xcode" print " run build and run app from project folder" sys.exit(1) print "[INFO] One moment, building ..." sys.stdout.flush() start_time = time.time() command = args[1].decode("utf-8") ensure_dev_path() target = 'Debug' deploytype = 'development' devicefamily = 'iphone' debug = False build_only = False simulator = False xcode_build = False force_xcode = False simtype = devicefamily # when you run from xcode, we'll pass xcode as the command and the # xcode script will simply pass some additional args as well as xcode # will add some additional useful stuff to the ENVIRONMENT and we pull # those values out here if command == 'xcode': xcode_build = True src_root = os.environ['SOURCE_ROOT'] project_dir = os.path.abspath(os.path.join(src_root,'../','../')) name = os.environ['PROJECT_NAME'] target = os.environ['CONFIGURATION'] appid = os.environ['TI_APPID'] arch = os.environ['CURRENT_ARCH'] sdk_name = os.environ['SDK_NAME'] iphone_version = sdk_name.replace('iphoneos','').replace('iphonesimulator','') # SUPPORTED_DEVICE_FAMILIES 1 or 2 or both # TARGETED_DEVICE_FAMILY 1 or 2 target_device = os.environ['TARGETED_DEVICE_FAMILY'] if target_device == '1': devicefamily = 'iphone' elif target_device == '2': devicefamily = 'ipad' elif target_device == '1,2': devicefamily = 'universal' if arch == 'i386': # simulator always indicates simulator deploytype = 'development' else: # if arch!=i386 indicates a build for device if target=='Debug': # non-simulator + debug build indicates test on device deploytype = 'test' else: # non-simulator + release build indicates package for distribution deploytype = 'production' #Ensure the localization files are copied in the application directory out_dir = os.path.join(os.environ['TARGET_BUILD_DIR'],os.environ['CONTENTS_FOLDER_PATH']) localecompiler.LocaleCompiler(name,project_dir,devicefamily,deploytype,out_dir).compile() compiler = Compiler(project_dir,appid,name,deploytype) compiler.compileProject(xcode_build,devicefamily,iphone_version) script_ok = True sys.exit(0) else: # the run command is when you run from titanium using the run command # and it will run the project in the current directory immediately in the simulator # from the command line if command == 'run': if argc < 3: print "Usage: %s run <project_dir> [ios_version]" % os.path.basename(args[0]) sys.exit(1) if argc == 3: iphone_version = check_iphone_sdk('4.0') else: iphone_version = dequote(args[3].decode("utf-8")) project_dir = os.path.expanduser(dequote(args[2].decode("utf-8"))) iphonesim = os.path.abspath(os.path.join(template_dir,'ios-sim')) iphone_dir = os.path.abspath(os.path.join(project_dir,'build','iphone')) tiapp_xml = os.path.join(project_dir,'tiapp.xml') ti = TiAppXML(tiapp_xml) appid = ti.properties['id'] name = ti.properties['name'] command = 'simulator' # switch it so that the rest of the stuff works else: iphone_version = dequote(args[2].decode("utf-8")) iphonesim = os.path.abspath(os.path.join(template_dir,'ios-sim')) project_dir = os.path.expanduser(dequote(args[3].decode("utf-8"))) appid = dequote(args[4].decode("utf-8")) name = dequote(args[5].decode("utf-8")) tiapp_xml = os.path.join(project_dir,'tiapp.xml') ti = TiAppXML(tiapp_xml) app_name = make_app_name(name) iphone_dir = os.path.abspath(os.path.join(project_dir,'build','iphone')) # We need to create the iphone dir if necessary, now that # the tiapp.xml allows build target selection if not os.path.isdir(iphone_dir): if os.path.exists(iphone_dir): os.remove(iphone_dir) os.makedirs(iphone_dir) project_xcconfig = os.path.join(iphone_dir,'project.xcconfig') target = 'Release' ostype = 'os' version_file = None log_id = None provisioning_profile = None debughost = None debugport = None debugairkey = None debughosts = None postbuild_modules = [] finalize_modules = [] def run_finalize(): try: if finalize_modules: for p in finalize_modules: print "[INFO] Running finalize %s..." % p[0] o.write("Running finalize %s" % p[0]) p[1].finalize() except Exception,e: print "[ERROR] Error in finalize: %s" % e o.write("Error in finalize: %s" % e) # starting in 1.4, you don't need to actually keep the build/iphone directory # if we don't find it, we'll just simply re-generate it if not os.path.exists(iphone_dir): from iphone import IPhone print "[INFO] Detected missing project but that's OK. re-creating it..." iphone_creator = IPhone(name,appid) iphone_creator.create(iphone_dir,True) sys.stdout.flush() # we use different arguments dependent on the command # pluck those out here if command == 'distribute': iphone_version = check_iphone_sdk(iphone_version) link_version = iphone_version dist_keychain = None appuuid = dequote(args[6].decode("utf-8")) dist_name = dequote(args[7].decode("utf-8")) output_dir = os.path.expanduser(dequote(args[8].decode("utf-8"))) if argc > 9: devicefamily = dequote(args[9].decode("utf-8")) if argc > 10: dist_keychain = dequote(args[10].decode("utf-8")) print "[INFO] Switching to production mode for distribution" deploytype = 'production' elif command in ['simulator', 'build']: link_version = check_iphone_sdk(iphone_version) deploytype = 'development' debug = True simulator = command == 'simulator' build_only = command == 'build' target = 'Debug' ostype = 'simulator' if argc > 6: devicefamily = dequote(args[6].decode("utf-8")) if argc > 7: simtype = dequote(args[7].decode("utf-8")) else: # 'universal' helpfully translates into iPhone here... just in case. simtype = devicefamily if argc > 8: # this is host:port from the debugger debughost = dequote(args[8].decode("utf-8")) if debughost=='': debughost = None debugport = None else: debughost,debugport = debughost.split(":") elif command in ['install', 'adhoc']: iphone_version = check_iphone_sdk(iphone_version) link_version = iphone_version dist_keychain = None appuuid = dequote(args[6].decode("utf-8")) dist_name = dequote(args[7].decode("utf-8")) if argc > 8: devicefamily = dequote(args[8].decode("utf-8")) if argc > 9: dist_keychain = dequote(args[9].decode("utf-8")) if dist_keychain=='': dist_keychain = None if argc > 10: # this is host:port:airkey:hosts from the debugger debughost = dequote(args[10].decode("utf-8")) if debughost=='': debughost = None debugport = None debugairkey = None debughosts = None else: debughost,debugport,debugairkey,debughosts = debughost.split(":",4) if command == 'install': target = 'Debug' deploytype = 'test' elif command == 'adhoc': target = 'Release' deploytype = 'production' # setup up the useful directories we need in the script build_out_dir = os.path.abspath(os.path.join(iphone_dir,'build')) build_dir = os.path.abspath(os.path.join(build_out_dir,'%s-iphone%s'%(target,ostype))) app_dir = os.path.abspath(os.path.join(build_dir,name+'.app')) binary = os.path.join(app_dir,name) sdk_version = os.path.basename(os.path.abspath(os.path.join(template_dir,'../'))) iphone_resources_dir = os.path.join(iphone_dir,'Resources') version_file = os.path.join(iphone_resources_dir,'.version') force_rebuild = read_project_version(project_xcconfig)!=sdk_version or not os.path.exists(version_file) infoplist = os.path.join(iphone_dir,'Info.plist') githash = None custom_fonts = [] # Before doing a single thing, we want to check for conflicts and bail out if necessary. find_name_conflicts(project_dir, app_name) # if we're not running in the simulator we want to clean out the build directory if command!='simulator' and os.path.exists(build_out_dir): shutil.rmtree(build_out_dir) if not os.path.exists(build_out_dir): os.makedirs(build_out_dir) # write out the build log, useful for debugging o = codecs.open(os.path.join(build_out_dir,'build.log'),'w',encoding='utf-8') def log(msg): print msg o.write(msg) try: buildtime = datetime.datetime.now() o.write("%s\n" % ("="*80)) o.write("Appcelerator Titanium Diagnostics Build Log\n") o.write("The contents of this file are useful to send to Appcelerator Support if\n") o.write("reporting an issue to help us understand your environment, build settings\n") o.write("and aid in debugging. Please attach this log to any issue that you report.\n") o.write("%s\n\n" % ("="*80)) o.write("Starting build at %s\n\n" % buildtime.strftime("%m/%d/%y %H:%M")) # write out the build versions info versions_txt = read_config(os.path.join(template_dir,'..','version.txt')) o.write("Build details:\n\n") for key in versions_txt: o.write(" %s=%s\n" % (key,versions_txt[key])) o.write("\n\n") if versions_txt.has_key('githash'): githash = versions_txt['githash'] o.write("Script arguments:\n") for arg in args: o.write(unicode(" %s\n" % arg, 'utf-8')) o.write("\n") o.write("Building from: %s\n" % template_dir) o.write("Platform: %s\n\n" % platform.version()) # print out path to debug xcode_path=run.run(["/usr/bin/xcode-select","-print-path"],True,False) if xcode_path: o.write("Xcode path is: %s\n" % xcode_path) else: o.write("Xcode path undetermined\n") # find the module directory relative to the root of the SDK titanium_dir = os.path.abspath(os.path.join(template_dir,'..','..','..','..')) tp_module_dir = os.path.abspath(os.path.join(titanium_dir,'modules','iphone')) force_destroy_build = command!='simulator' detector = ModuleDetector(project_dir) missing_modules, modules = detector.find_app_modules(ti, 'iphone', deploytype) module_lib_search_path, module_asset_dirs = locate_modules(modules, project_dir, app_dir, log) common_js_modules = [] if len(missing_modules) != 0: print '[ERROR] Could not find the following required iOS modules:' for module in missing_modules: print "[ERROR]\tid: %s\tversion: %s" % (module['id'], module['version']) sys.exit(1) # search for modules that the project is using # and make sure we add them to the compile for module in modules: if module.js: common_js_modules.append(module) continue module_id = module.manifest.moduleid.lower() module_version = module.manifest.version module_lib_name = ('lib%s.a' % module_id).lower() # check first in the local project local_module_lib = os.path.join(project_dir, 'modules', 'iphone', module_lib_name) local = False if os.path.exists(local_module_lib): module_lib_search_path.append([module_lib_name, local_module_lib]) local = True log("[INFO] Detected third-party module: %s" % (local_module_lib)) else: if module.lib is None: module_lib_path = module.get_resource(module_lib_name) log("[ERROR] Third-party module: %s/%s missing library at %s" % (module_id, module_version, module_lib_path)) sys.exit(1) module_lib_search_path.append([module_lib_name, os.path.abspath(module.lib).rsplit('/',1)[0]]) log("[INFO] Detected third-party module: %s/%s" % (module_id, module_version)) force_xcode = True if not local: # copy module resources img_dir = module.get_resource('assets', 'images') if os.path.exists(img_dir): dest_img_dir = os.path.join(app_dir, 'modules', module_id, 'images') if not os.path.exists(dest_img_dir): os.makedirs(dest_img_dir) module_asset_dirs.append([img_dir, dest_img_dir]) # copy in any module assets module_assets_dir = module.get_resource('assets') if os.path.exists(module_assets_dir): module_dir = os.path.join(app_dir, 'modules', module_id) module_asset_dirs.append([module_assets_dir, module_dir]) full_version = sdk_version if 'version' in versions_txt: full_version = versions_txt['version'] if 'timestamp' in versions_txt or 'githash' in versions_txt: full_version += ' (' if 'timestamp' in versions_txt: full_version += '%s' % versions_txt['timestamp'] if 'githash' in versions_txt: full_version += ' %s' % versions_txt['githash'] full_version += ')' print "[INFO] Titanium SDK version: %s" % full_version print "[INFO] iPhone Device family: %s" % devicefamily print "[INFO] iPhone SDK version: %s" % iphone_version if simulator or build_only: print "[INFO] iPhone simulated device: %s" % simtype # during simulator we need to copy in standard built-in module files # since we might not run the compiler on subsequent launches for module_name in ('ui'): img_dir = os.path.join(template_dir,'modules',module_name,'images') dest_img_dir = os.path.join(app_dir,'modules',module_name,'images') if not os.path.exists(dest_img_dir): os.makedirs(dest_img_dir) module_asset_dirs.append([img_dir,dest_img_dir]) # when in simulator since we point to the resources directory, we need # to explicitly copy over any files ird = os.path.join(project_dir,'Resources','iphone') if os.path.exists(ird): module_asset_dirs.append([ird,app_dir]) # We also need to copy over the contents of 'platform/iphone' platform_iphone = os.path.join(project_dir,'platform','iphone') if os.path.exists(platform_iphone): module_asset_dirs.append([platform_iphone,app_dir]) for ext in ('ttf','otf'): for f in glob.glob('%s/*.%s' % (os.path.join(project_dir,'Resources'),ext)): custom_fonts.append(f) if not (simulator or build_only): version = ti.properties['version'] # we want to make sure in debug mode the version always changes version = "%s.%d" % (version,time.time()) if (deploytype != 'production'): ti.properties['version']=version pp = os.path.expanduser("~/Library/MobileDevice/Provisioning Profiles/%s.mobileprovision" % appuuid) provisioning_profile = read_provisioning_profile(pp,o) create_info_plist(ti, template_dir, project_dir, infoplist) applogo = None clean_build = False # check to see if the appid is different (or not specified) - we need to re-generate if read_project_appid(project_xcconfig)!=appid or not infoplist_has_appid(infoplist,appid): clean_build = True force_xcode = True new_lib_hash = None lib_hash = None existing_git_hash = None # this code simply tries and detect if we're building a different # version of the project (or same version but built from different git hash) # and if so, make sure we force rebuild so to propagate any code changes in # source code (either upgrade or downgrade) if os.path.exists(app_dir): if os.path.exists(version_file): line = open(version_file).read().strip() lines = line.split(",") v = lines[0] log_id = lines[1] if len(lines) > 2: lib_hash = lines[2] existing_git_hash = lines[3] if lib_hash==None: force_rebuild = True else: if template_dir==v and force_rebuild==False: force_rebuild = False else: log_id = None else: force_rebuild = True else: force_rebuild = True o.write("\ngithash=%s, existing_git_hash=%s\n" %(githash,existing_git_hash)) if githash!=existing_git_hash: force_rebuild = True # we want to read the md5 of the libTiCore.a library since it must match # the current one we're building and if not, we need to force a rebuild since # that means we've copied in a different version of the library and we need # to rebuild clean to avoid linking errors source_lib=os.path.join(template_dir,'libTiCore.a') fd = open(source_lib,'rb') m = hashlib.md5() m.update(fd.read(1024)) # just read 1K, it's binary new_lib_hash = m.hexdigest() fd.close() if new_lib_hash!=lib_hash: force_rebuild=True o.write("forcing rebuild since libhash (%s) not matching (%s)\n" % (lib_hash,new_lib_hash)) lib_hash=new_lib_hash # when we force rebuild, we need to re-compile and re-copy source, libs etc if force_rebuild: o.write("Performing full rebuild\n") print "[INFO] Performing full rebuild. This will take a little bit. Hold tight..." sys.stdout.flush() # In order to avoid dual-mangling, we need to make sure that if we're re-projecting, # there is NOT an existing xcodeproj file. if not os.path.exists(os.path.join(iphone_dir, "%s.xcodeproj" % name)): project = Projector(name,sdk_version,template_dir,project_dir,appid, None) project.create(template_dir,iphone_dir) force_xcode = True if os.path.exists(app_dir): shutil.rmtree(app_dir) # we have to re-copy if we have a custom version create_info_plist(ti, template_dir, project_dir, infoplist) # since compiler will generate the module dependencies, we need to # attempt to compile to get it correct for the first time. compiler = Compiler(project_dir,appid,name,deploytype) compiler.compileProject(xcode_build,devicefamily,iphone_version,True) else: if simulator: softlink_for_simulator(project_dir,app_dir) contents="TI_VERSION=%s\n"% sdk_version contents+="TI_SDK_DIR=%s\n" % template_dir.replace(sdk_version,'$(TI_VERSION)') contents+="TI_APPID=%s\n" % appid contents+="OTHER_LDFLAGS[sdk=iphoneos*]=$(inherited) -weak_framework iAd\n" contents+="OTHER_LDFLAGS[sdk=iphonesimulator*]=$(inherited) -weak_framework iAd\n" contents+="#include \"module\"\n" xcconfig = open(project_xcconfig,'w+') xccontents = xcconfig.read() if contents!=xccontents: o.write("writing contents of %s:\n\n%s\n" % (project_xcconfig,contents)) o.write("old contents\n\n%s\n" % (xccontents)) xcconfig.write(contents) xcconfig.close() else: o.write("Skipping writing contents of xcconfig %s\n" % project_xcconfig) # write out any modules into the xcode project # this must be done after project create above or this will be overriden link_modules(module_lib_search_path, name, iphone_dir) cwd = os.getcwd() # check to see if the symlink exists and that it points to the # right version of the library libticore = os.path.join(template_dir,'libTiCore.a') make_link = True symlink = os.path.join(iphone_dir,'lib','libTiCore.a') if os.path.islink(symlink): path = os.path.realpath(symlink) if path.find(sdk_version) > 0: make_link = False if make_link: libdir = os.path.join(iphone_dir,'lib') if not os.path.exists(libdir): os.makedirs(libdir) os.chdir(libdir) # a broken link will not return true on os.path.exists # so we need to use brute force try: os.unlink("libTiCore.a") except: pass try: os.symlink(libticore,"libTiCore.a") except: pass os.chdir(cwd) # if the lib doesn't exist, force a rebuild since it's a new build if not os.path.exists(os.path.join(iphone_dir,'lib','libtiverify.a')): shutil.copy(os.path.join(template_dir,'libtiverify.a'),os.path.join(iphone_dir,'lib','libtiverify.a')) if not os.path.exists(os.path.join(iphone_dir,'lib','libti_ios_debugger.a')): shutil.copy(os.path.join(template_dir,'libti_ios_debugger.a'),os.path.join(iphone_dir,'lib','libti_ios_debugger.a')) if not os.path.exists(os.path.join(iphone_dir,'lib','libti_ios_profiler.a')): shutil.copy(os.path.join(template_dir,'libti_ios_profiler.a'),os.path.join(iphone_dir,'lib','libti_ios_profiler.a')) # compile JSS files cssc = csscompiler.CSSCompiler(os.path.join(project_dir,'Resources'),devicefamily,appid) app_stylesheet = os.path.join(iphone_dir,'Resources','stylesheet.plist') asf = codecs.open(app_stylesheet,'w','utf-8') asf.write(cssc.code) asf.close() # compile debugger file debug_plist = os.path.join(iphone_dir,'Resources','debugger.plist') # Force an xcodebuild if the debugger.plist has changed force_xcode = write_debugger_plist(debughost, debugport, debugairkey, debughosts, template_dir, debug_plist) if command not in ['simulator', 'build']: # compile plist into binary format so it's faster to load # we can be slow on simulator os.system("/usr/bin/plutil -convert binary1 \"%s\"" % app_stylesheet) o.write("Generated the following stylecode code:\n\n") o.write(cssc.code) o.write("\n") # generate the Info.plist file with the appropriate device family if devicefamily!=None: applogo = ti.generate_infoplist(infoplist,appid,devicefamily,project_dir,iphone_version) else: applogo = ti.generate_infoplist(infoplist,appid,'iphone',project_dir,iphone_version) # attempt to load any compiler plugins if len(ti.properties['plugins']) > 0: local_compiler_dir = os.path.abspath(os.path.join(project_dir,'plugins')) tp_compiler_dir = os.path.abspath(os.path.join(titanium_dir,'plugins')) if not os.path.exists(tp_compiler_dir) and not os.path.exists(local_compiler_dir): o.write("+ Missing plugins directory at %s\n" % tp_compiler_dir) print "[ERROR] Build Failed (Missing plugins directory). Please see output for more details" sys.stdout.flush() sys.exit(1) compiler_config = { 'platform':'ios', 'devicefamily':devicefamily, 'simtype':simtype, 'tiapp':ti, 'project_dir':project_dir, 'titanium_dir':titanium_dir, 'appid':appid, 'iphone_version':iphone_version, 'template_dir':template_dir, 'project_name':name, 'command':command, 'deploytype':deploytype, 'build_dir':build_dir, 'app_name':app_name, 'app_dir':app_dir, 'iphone_dir':iphone_dir } for plugin in ti.properties['plugins']: local_plugin_file = os.path.join(local_compiler_dir,plugin['name'],'plugin.py') plugin_file = os.path.join(tp_compiler_dir,plugin['name'],plugin['version'],'plugin.py') if not os.path.exists(local_plugin_file) and not os.path.exists(plugin_file): o.write("+ Missing plugin at %s (checked %s also)\n" % (plugin_file,local_plugin_file)) print "[ERROR] Build Failed (Missing plugin for %s). Please see output for more details" % plugin['name'] sys.stdout.flush() sys.exit(1) o.write("+ Detected plugin: %s/%s\n" % (plugin['name'],plugin['version'])) print "[INFO] Detected compiler plugin: %s/%s" % (plugin['name'],plugin['version']) code_path = plugin_file if os.path.exists(local_plugin_file): code_path = local_plugin_file o.write("+ Loading compiler plugin at %s\n" % code_path) compiler_config['plugin']=plugin fin = open(code_path, 'rb') m = hashlib.md5() m.update(open(code_path,'rb').read()) code_hash = m.hexdigest() p = imp.load_source(code_hash, code_path, fin) module_functions = dict(inspect.getmembers(p, inspect.isfunction)) if module_functions.has_key('postbuild'): print "[DEBUG] Plugin has postbuild" o.write("+ Plugin has postbuild") postbuild_modules.append((plugin['name'], p)) if module_functions.has_key('finalize'): print "[DEBUG] Plugin has finalize" o.write("+ Plugin has finalize") finalize_modules.append((plugin['name'], p)) p.compile(compiler_config) fin.close() try: os.chdir(iphone_dir) # target the requested value if provided; otherwise, target minimum (4.0) # or maximum iphone_version if 'min-ios-ver' in ti.ios: min_ver = ti.ios['min-ios-ver'] if min_ver < 4.0: if float(link_version) >= 6.0: new_min_ver = 4.3 else: new_min_ver = 4.0 print "[INFO] Minimum iOS version %s is lower than 4.0: Using %s as minimum" % (min_ver, new_min_ver) min_ver = new_min_ver elif min_ver > float(iphone_version): print "[INFO] Minimum iOS version %s is greater than %s (iphone_version): Using %s as minimum" % (min_ver, iphone_version, iphone_version) min_ver = float(iphone_version) elif float(link_version) >= 6.0 and min_ver < 4.3: print "[INFO] Minimum iOS version supported with %s (link_version) is 4.3. Ignoring %s and using 4.3 as minimum" %(link_version, min_ver) min_ver = 4.3 else: if float(link_version) >= 6.0: min_ver = 4.3 else: min_ver = 4.0 print "[INFO] Minimum iOS version: %s Linked iOS Version %s" % (min_ver, link_version) deploy_target = "IPHONEOS_DEPLOYMENT_TARGET=%s" % min_ver device_target = 'TARGETED_DEVICE_FAMILY=1' # this is non-sensical, but you can't pass empty string # No armv6 support above 4.3 or with 6.0+ SDK if min_ver >= 4.3 or float(link_version) >= 6.0: valid_archs = 'armv7 i386' else: valid_archs = 'armv6 armv7 i386' # clean means we need to nuke the build if clean_build or force_destroy_build: print "[INFO] Performing clean build" o.write("Performing clean build...\n") if os.path.exists(app_dir): shutil.rmtree(app_dir) if not os.path.exists(app_dir): os.makedirs(app_dir) # compile localization files # Using app_name here will cause the locale to be put in the WRONG bundle!! localecompiler.LocaleCompiler(name,project_dir,devicefamily,deploytype).compile() # copy any module resources if len(module_asset_dirs)>0: for e in module_asset_dirs: copy_module_resources(e[0],e[1],True) # copy CommonJS modules for module in common_js_modules: #module_id = module.manifest.moduleid.lower() #module_dir = os.path.join(app_dir, 'modules', module_id) #if os.path.exists(module_dir) is False: # os.makedirs(module_dir) shutil.copy(module.js, app_dir) # copy artworks, if appropriate if command in ['adhoc', 'install', 'distribute']: artworks = ['iTunesArtwork', 'iTunesArtwork@2x'] for artwork in artworks: if os.path.exists(os.path.join(project_dir, artwork)): shutil.copy(os.path.join(project_dir, artwork), app_dir) # copy any custom fonts in (only runs in simulator) # since we need to make them live in the bundle in simulator if len(custom_fonts)>0: for f in custom_fonts: font = os.path.basename(f) app_font_path = os.path.join(app_dir, font) print "[INFO] Detected custom font: %s" % font if os.path.exists(app_font_path): os.remove(app_font_path) try: shutil.copy(f,app_dir) except shutil.Error, e: print "[WARN] Not copying %s: %s" % (font, e) # dump out project file info if command not in ['simulator', 'build']: dump_resources_listing(project_dir,o) dump_infoplist(infoplist,o) install_logo(ti, applogo, project_dir, template_dir, app_dir) install_defaults(project_dir, template_dir, iphone_resources_dir) extra_args = None recompile = copy_tiapp_properties(project_dir) # if the anything changed in the application defaults then we have to force a xcode build. if recompile == True: force_xcode = recompile if devicefamily!=None: # Meet the minimum requirements for ipad when necessary if devicefamily == 'ipad' or devicefamily == 'universal': device_target="TARGETED_DEVICE_FAMILY=2" # NOTE: this is very important to run on device -- i dunno why # xcode warns that 3.2 needs only armv7, but if we don't pass in # armv6 we get crashes on device extra_args = ["VALID_ARCHS="+valid_archs] # Additionally, if we're universal, change the device family target if devicefamily == 'universal': device_target="TARGETED_DEVICE_FAMILY=1,2" kroll_coverage = "" if ti.has_app_property("ti.ios.enablecoverage"): enable_coverage = ti.to_bool(ti.get_app_property("ti.ios.enablecoverage")) if enable_coverage: kroll_coverage = "KROLL_COVERAGE=1" def execute_xcode(sdk,extras,print_output=True): config = name if devicefamily=='ipad': config = "%s-iPad" % config if devicefamily=='universal': config = "%s-universal" % config # these are the arguments for running a command line xcode build args = ["xcodebuild","-target",config,"-configuration",target,"-sdk",sdk] if extras!=None and len(extras)>0: args += extras args += [deploy_target,device_target] if extra_args!=None and len(extra_args)>0: args += extra_args o.write("Starting Xcode compile with the following arguments:\n\n") for arg in args: o.write(" %s\n" % arg) o.write("\napp_id = %s\n" % appid) o.write("\n\n") o.flush() if print_output: print "[DEBUG] compile checkpoint: %0.2f seconds" % (time.time()-start_time) print "[INFO] Executing XCode build..." print "[BEGIN_VERBOSE] Executing XCode Compiler <span>[toggle output]</span>" # h/t cbarber for this; occasionally the PCH header info gets out of sync # with the PCH file if you do the "wrong thing" and xcode isn't # smart enough to pick up these changes (since the PCH file hasn't 'changed'). run.run(['touch', '%s_Prefix.pch' % ti.properties['name']], debug=False) output = run.run(args,False,False,o) if print_output: print output print "[END_VERBOSE]" sys.stdout.flush() # Output already written by run.run #o.write(output) # check to make sure the user doesn't have a custom build location # configured in Xcode which currently causes issues with titanium idx = output.find("TARGET_BUILD_DIR ") if idx > 0: endidx = output.find("\n",idx) if endidx > 0: target_build_dir = dequote(output[idx+17:endidx].strip()) if not os.path.samefile(target_build_dir,build_dir): o.write("+ TARGET_BUILD_DIR = %s\n" % target_build_dir) print "[ERROR] Your TARGET_BUILD_DIR is incorrectly set. Most likely you have configured in Xcode a customized build location. Titanium does not currently support this configuration." print "[ERROR] Expected dir %s, was: %s" % (build_dir,target_build_dir) sys.stdout.flush() sys.exit(1) # look for build error if output.find("** BUILD FAILED **")!=-1 or output.find("ld returned 1")!=-1 or output.find("The following build commands failed:")!=-1: o.write("+ Detected build failure\n") print "[ERROR] Build Failed. Please see output for more details" sys.stdout.flush() sys.exit(1) o.write("+ Looking for application binary at %s\n" % binary) # make sure binary exists if not os.path.exists(binary): o.write("+ Missing application binary at %s\n" % binary) print "[ERROR] Build Failed (Missing app at %s). Please see output for more details" % binary sys.stdout.flush() sys.exit(1) # look for a code signing error error = re.findall(r'Code Sign error:(.*)',output) if len(error) > 0: o.write("+ Detected code sign error: %s\n" % error[0]) print "[ERROR] Code sign error: %s" % error[0].strip() sys.stdout.flush() sys.exit(1) def run_postbuild(): try: if postbuild_modules: for p in postbuild_modules: o.write("Running postbuild %s" % p[0]) print "[INFO] Running postbuild %s..." % p[0] p[1].postbuild() except Exception,e: o.write("Error in post-build: %s" % e) print "[ERROR] Error in post-build: %s" % e # build the final release distribution args = [] if command not in ['simulator', 'build']: # allow the project to have its own custom entitlements custom_entitlements = os.path.join(project_dir,"Entitlements.plist") entitlements_contents = None if os.path.exists(custom_entitlements): entitlements_contents = open(custom_entitlements).read() o.write("Found custom entitlements: %s\n" % custom_entitlements) else: # attempt to customize it by reading prov profile entitlements_contents = generate_customized_entitlements(provisioning_profile,appid,appuuid,command,o) o.write("Generated the following entitlements:\n\n%s\n\n" % entitlements_contents) f=open(os.path.join(iphone_resources_dir,'Entitlements.plist'),'w+') f.write(entitlements_contents) f.close() args+=["CODE_SIGN_ENTITLEMENTS=Resources/Entitlements.plist"] # only build if force rebuild (different version) or # the app hasn't yet been built initially if ti.properties['guid']!=log_id or force_xcode: log_id = ti.properties['guid'] f = open(version_file,'w+') f.write("%s,%s,%s,%s" % (template_dir,log_id,lib_hash,githash)) f.close() # both simulator and build require an xcodebuild if command in ['simulator', 'build']: debugstr = '' if debughost: debugstr = 'DEBUGGER_ENABLED=1' if force_rebuild or force_xcode or not os.path.exists(binary): execute_xcode("iphonesimulator%s" % link_version,["GCC_PREPROCESSOR_DEFINITIONS=__LOG__ID__=%s DEPLOYTYPE=development TI_DEVELOPMENT=1 DEBUG=1 TI_VERSION=%s %s %s" % (log_id,sdk_version,debugstr,kroll_coverage)],False) run_postbuild() o.write("Finishing build\n") if command == 'simulator': # first make sure it's not running kill_simulator() #Give the kill command time to finish time.sleep(2) # sometimes the simulator doesn't remove old log files # in which case we get our logging jacked - we need to remove # them before running the simulator cleanup_app_logfiles(ti, log_id, iphone_version) sim = None # this handler will simply catch when the simulator exits # so we can exit this script def handler(signum, frame): global script_ok print "[INFO] Simulator is exiting" if not log == None: try: os.system("kill -2 %s" % str(log.pid)) except: pass if not sim == None and signum!=3: try: os.system("kill -3 %s" % str(sim.pid)) except: pass kill_simulator() script_ok = True sys.exit(0) # make sure we're going to stop this script whenever # the simulator exits signal.signal(signal.SIGHUP, handler) signal.signal(signal.SIGINT, handler) signal.signal(signal.SIGQUIT, handler) signal.signal(signal.SIGABRT, handler) signal.signal(signal.SIGTERM, handler) print "[INFO] Launching application in Simulator" sys.stdout.flush() sys.stderr.flush() # set the DYLD_FRAMEWORK_PATH environment variable for the following Popen iphonesim command # this allows the XCode developer folder to be arbitrarily named xcodeselectpath = os.popen("/usr/bin/xcode-select -print-path").readline().rstrip('\n') iphoneprivateframeworkspath = xcodeselectpath + '/Platforms/iPhoneSimulator.platform/Developer/Library/PrivateFrameworks:' + xcodeselectpath + '/../OtherFrameworks' os.putenv('DYLD_FRAMEWORK_PATH', iphoneprivateframeworkspath) # launch the simulator # Awkward arg handling; we need to take 'retina' to be a device type, # even though it's really not (it's a combination of device type and configuration). # So we translate it into two args: if simtype == 'retina': # Manually overrule retina type if we're an ipad if devicefamily == 'ipad': simtype = 'ipad' else: simtype = 'iphone --retina' if devicefamily==None: sim = subprocess.Popen("\"%s\" launch \"%s\" --sdk %s" % (iphonesim,app_dir,iphone_version),shell=True,cwd=template_dir) else: sim = subprocess.Popen("\"%s\" launch \"%s\" --sdk %s --family %s" % (iphonesim,app_dir,iphone_version,simtype),shell=True,cwd=template_dir) os.unsetenv('DYLD_FRAMEWORK_PATH') # activate the simulator window ass = os.path.join(template_dir, 'iphone_sim_activate.scpt') command = 'osascript "%s" "%s/Platforms/iPhoneSimulator.platform/Developer/Applications/iPhone Simulator.app"' % (ass, xcodeselectpath) os.system(command) end_time = time.time()-start_time print "[INFO] Launched application in Simulator (%0.2f seconds)" % end_time sys.stdout.flush() sys.stderr.flush() # give the simulator a bit to get started and up and running before # starting the logger time.sleep(2) logger = os.path.realpath(os.path.join(template_dir,'logger.py')) # start the logger tail process. this will simply read the output # from the logs and stream them back to Titanium Developer on the console log = subprocess.Popen([ logger, str(log_id)+'.log', iphone_version ]) # wait (blocking this script) until the simulator exits try: os.waitpid(sim.pid,0) except SystemExit: # If the user terminates the app here, it's via a # soft kill of some kind (i.e. like what TiDev does) # and so we should suppress the usual error message. # Fixes #2086 pass print "[INFO] Application has exited from Simulator" # in this case, the user has exited the simulator itself # and not clicked Stop Emulator from within Developer so we kill # our tail log process but let simulator keep running if not log == None: try: os.system("kill -2 %s" % str(log.pid)) except: pass script_ok = True ########################################################################### # END OF SIMULATOR COMMAND ########################################################################### # # this command is run for installing an app on device or packaging for adhoc distribution # elif command in ['install', 'adhoc']: debugstr = '' if debughost: debugstr = 'DEBUGGER_ENABLED=1' args += [ "GCC_PREPROCESSOR_DEFINITIONS=DEPLOYTYPE=test TI_TEST=1 %s %s" % (debugstr, kroll_coverage), "PROVISIONING_PROFILE=%s" % appuuid ] if command == 'install': args += ["CODE_SIGN_IDENTITY=iPhone Developer: %s" % dist_name] elif command == 'adhoc': args += ["CODE_SIGN_IDENTITY=iPhone Distribution: %s" % dist_name] if dist_keychain is not None: args += ["OTHER_CODE_SIGN_FLAGS=--keychain %s" % dist_keychain] args += ["DEPLOYMENT_POSTPROCESSING=YES"] execute_xcode("iphoneos%s" % iphone_version,args,False) if command == 'install': print "[INFO] Installing application in iTunes ... one moment" sys.stdout.flush() dev_path = run.run(['xcode-select','-print-path'],True,False).rstrip() package_path = os.path.join(dev_path,'Platforms/iPhoneOS.platform/Developer/usr/bin/PackageApplication') if os.path.exists(package_path): o.write("+ Preparing to run %s\n"%package_path) output = run.run([package_path,app_dir],True) o.write("+ Finished running %s\n"%package_path) if output: o.write(output) # for install, launch itunes with the app ipa = os.path.join(os.path.dirname(app_dir),"%s.ipa" % name) o.write("+ IPA file should be at %s\n" % ipa); # it appears that sometimes this command above fails on certain installs # or is missing. let's just open if we have it otherwise, open the app # directory if not os.path.exists(ipa): # just open the app dir itself o.write("+ IPA didn't exist at %s\n" % ipa) o.write("+ Will try and open %s\n" % app_dir) ipa = app_dir if command == 'install': # to force iTunes to install our app, we simply open the IPA # file in itunes cmd = "open -b com.apple.itunes \"%s\"" % ipa o.write("+ Executing the command: %s\n" % cmd) os.system(cmd) o.write("+ After executing the command: %s\n" % cmd) # now run our applescript to tell itunes to sync to get # the application on the phone ass = os.path.join(template_dir,'itunes_sync.scpt') cmd = "osascript \"%s\"" % ass o.write("+ Executing the command: %s\n" % cmd) os.system(cmd) o.write("+ After executing the command: %s\n" % cmd) print "[INFO] iTunes sync initiated" o.write("Finishing build\n") sys.stdout.flush() script_ok = True run_postbuild() ########################################################################### # END OF INSTALL/ADHOC COMMAND ########################################################################### # # this command is run for packaging an app for distribution # elif command == 'distribute': deploytype = "production" args += [ "GCC_PREPROCESSOR_DEFINITIONS=DEPLOYTYPE=%s TI_PRODUCTION=1" % deploytype, "PROVISIONING_PROFILE=%s" % appuuid, "CODE_SIGN_IDENTITY=iPhone Distribution: %s" % dist_name, "DEPLOYMENT_POSTPROCESSING=YES" ] if dist_keychain is not None: args += ["OTHER_CODE_SIGN_FLAGS=--keychain %s" % dist_keychain] execute_xcode("iphoneos%s" % iphone_version,args,False) # switch to app_bundle for zip os.chdir(build_dir) distribute_xc4(name, applogo, o) # open xcode + organizer after packaging # Have to force the right xcode open... xc_path = run.run(['xcode-select','-print-path'],True,False).rstrip() xc_app_index = xc_path.find('/Xcode.app/') if (xc_app_index >= 0): xc_path = xc_path[0:xc_app_index+10] else: xc_path = os.path.join(xc_path,'Applications','Xcode.app') o.write("Launching xcode: %s\n" % xc_path) os.system('open -a %s' % xc_path) ass = os.path.join(template_dir,'xcode_organizer.scpt') cmd = "osascript \"%s\"" % ass os.system(cmd) o.write("Finishing build\n") script_ok = True run_postbuild() ########################################################################### # END OF DISTRIBUTE COMMAND ########################################################################### finally: os.chdir(cwd) except: print "[ERROR] Error: %s" % traceback.format_exc() if not script_ok: o.write("\nException detected in script:\n") traceback.print_exc(file=o) sys.exit(1) finally: if command not in ("xcode") and "run_finalize" in locals(): run_finalize() o.close() if __name__ == "__main__": main(sys.argv) sys.exit(0)
apache-2.0
fegonda/icon_demo
code/model/unet/g.py
1
44565
import os import sys import skimage.transform import skimage.exposure import time import glob import numpy as np import mahotas import random import matplotlib import matplotlib.pyplot as plt import scipy import scipy.ndimage import json from scipy.ndimage.filters import maximum_filter base_path = os.path.dirname(__file__) sys.path.insert(1,os.path.join(base_path, '../../common')) sys.path.insert(2,os.path.join(base_path, '../../database')) from utility import Utility from settings import Paths from project import Project from paths import Paths from db import DB # the idea is to grow the labels to cover the whole membrane # image and label should be [0,1] def adjust_imprecise_boundaries(image, label, number_iterations=5): label = label.copy() label_orig = label.copy() for i in xrange(number_iterations): # grow labels by one pixel label = maximum_filter(label, 2) # only keep pixels that are on dark membrane non_valid_label = np.logical_and(label==1, image>0.7) label[non_valid_label] = 0 # make sure original labels are preserved label = np.logical_or(label==1, label_orig==1) return label def deform_image(image): # assumes image is uint8 def apply_deformation(image, coordinates): # ndimage expects uint8 otherwise introduces artifacts. Don't ask me why, its stupid. deformed = scipy.ndimage.map_coordinates(image, coordinates, mode='reflect') deformed = np.reshape(deformed, image.shape) return deformed displacement_x = np.random.normal(size=image.shape, scale=10) displacement_y = np.random.normal(size=image.shape, scale=10) # smooth over image coords_x, coords_y = np.meshgrid(np.arange(0,image.shape[0]), np.arange(0,image.shape[1]), indexing='ij') displacement_x = coords_x.flatten() #+ scipy.ndimage.gaussian_filter(displacement_x, sigma=5).flatten() displacement_y = coords_y.flatten() #+ scipy.ndimage.gaussian_filter(displacement_y, sigma=5).flatten() coordinates = np.vstack([displacement_x, displacement_y]) return apply_deformation(np.uint8(image*255), coordinates) def deform_images(image1, image2, image3=None): # assumes image is uint8 def apply_deformation(image, coordinates): # ndimage expects uint8 otherwise introduces artifacts. Don't ask me why, its stupid. deformed = scipy.ndimage.map_coordinates(image, coordinates, mode='reflect') deformed = np.reshape(deformed, image.shape) return deformed displacement_x = np.random.normal(size=image1.shape, scale=10) displacement_y = np.random.normal(size=image1.shape, scale=10) # smooth over image coords_x, coords_y = np.meshgrid(np.arange(0,image1.shape[0]), np.arange(0,image1.shape[1]), indexing='ij') displacement_x = coords_x.flatten() #+ scipy.ndimage.gaussian_filter(displacement_x, sigma=5).flatten() displacement_y = coords_y.flatten() #+ scipy.ndimage.gaussian_filter(displacement_y, sigma=5).flatten() coordinates = np.vstack([displacement_x, displacement_y]) deformed1 = apply_deformation(np.uint8(image1*255), coordinates) deformed2 = apply_deformation(np.uint8(image2*255), coordinates) if not image3 is None: deformed3 = apply_deformation(image3, coordinates) return (deformed1, deformed2, deformed3) return (deformed1, deformed2) def deform_images_list(images): # assumes image is uint8 def apply_deformation(image, coordinates): # ndimage expects uint8 otherwise introduces artifacts. Don't ask me why, its stupid. deformed = scipy.ndimage.map_coordinates(image, coordinates, mode='reflect') deformed = np.reshape(deformed, image.shape) return deformed displacement_x = np.random.normal(size=images.shape[:2], scale=10) displacement_y = np.random.normal(size=images.shape[:2], scale=10) # smooth over image coords_x, coords_y = np.meshgrid(np.arange(0,images.shape[0]), np.arange(0,images.shape[1]), indexing='ij') displacement_x = coords_x.flatten() #+ scipy.ndimage.gaussian_filter(displacement_x, sigma=5).flatten() displacement_y = coords_y.flatten() #+ scipy.ndimage.gaussian_filter(displacement_y, sigma=5).flatten() coordinates = np.vstack([displacement_x, displacement_y]) deformed = images.copy() for i in xrange(images.shape[2]): deformed[:,:,i] = apply_deformation(np.uint8(images[:,:,i]), coordinates) return deformed def normalizeImage(img, saturation_level=0.05, doClahe=False): #was 0.005 if not doClahe: sortedValues = np.sort( img.ravel()) minVal = np.float32(sortedValues[np.int(len(sortedValues) * (saturation_level / 2))]) maxVal = np.float32(sortedValues[np.int(len(sortedValues) * (1 - saturation_level / 2))]) normImg = np.float32(img - minVal) * (255 / (maxVal-minVal)) normImg[normImg<0] = 0 normImg[normImg>255] = 255 output = (np.float32(normImg) / 255.0) return output else: output = skimage.exposure.equalize_adapthist(img) return output def generate_experiment_data_supervised(purpose='train', nsamples=1000, patchSize=29, balanceRate=0.5, rng=np.random): start_time = time.time() data_path = '/n/home00/fgonda/icon/data/reference' #if os.path.exists('/media/vkaynig/Data1/Cmor_paper_data/'): if os.path.exists( data_path ): pathPrefix = data_path #pathPrefix = '/media/vkaynig/Data1/Cmor_paper_data/' else: pathPrefix = '/n/pfister_lab/vkaynig/' #img_search_string_membraneImages = pathPrefix + 'labels/membranes_nonDilate/' + purpose + '/*.tif' #img_search_string_backgroundMaskImages = pathPrefix + 'labels/background_nonDilate/' + purpose + '/*.tif' img_search_string_membraneImages = pathPrefix + 'labels/membranes/' + purpose + '/*.tif' img_search_string_backgroundMaskImages = pathPrefix + 'labels/background/' + purpose + '/*.tif' img_search_string_grayImages = pathPrefix + 'images/' + purpose + '/*.tif' img_files_gray = sorted( glob.glob( img_search_string_grayImages ) ) img_files_label = sorted( glob.glob( img_search_string_membraneImages ) ) img_files_backgroundMask = sorted( glob.glob( img_search_string_backgroundMaskImages ) ) whole_set_patches = np.zeros((nsamples, patchSize*patchSize), dtype=np.float) whole_set_labels = np.zeros(nsamples, dtype=np.int32) #how many samples per image? nsamples_perImage = np.uint(np.ceil( (nsamples) / np.float(np.shape(img_files_gray)[0]) )) print 'using ' + np.str(nsamples_perImage) + ' samples per image.' counter = 0 img = mahotas.imread(img_files_gray[0]) grayImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) labelImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) maskImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) for img_index in xrange(np.shape(img_files_gray)[0]): img = mahotas.imread(img_files_gray[img_index]) img = normalizeImage(img) grayImages[:,:,img_index] = img label_img = mahotas.imread(img_files_label[img_index]) labelImages[:,:,img_index] = label_img mask_img = mahotas.imread(img_files_backgroundMask[img_index]) maskImages[:,:,img_index] = mask_img for img_index in xrange(np.shape(img_files_gray)[0]): img = grayImages[:,:,img_index] label_img = labelImages[:,:,img_index] mask_img = maskImages[:,:,img_index] #get rid of invalid image borders border_patch = np.int(np.ceil(patchSize/2.0)) border = np.int(np.ceil(np.sqrt(2*(border_patch**2)))) label_img[:border,:] = 0 #top label_img[-border:,:] = 0 #bottom label_img[:,:border] = 0 #left label_img[:,-border:] = 0 #right mask_img[:border,:] = 0 mask_img[-border:,:] = 0 mask_img[:,:border] = 0 mask_img[:,-border:] = 0 membrane_indices = np.nonzero(label_img) non_membrane_indices = np.nonzero(mask_img) positiveSample = True for i in xrange(nsamples_perImage): if counter >= nsamples: break if positiveSample: randmem = random.choice(xrange(len(membrane_indices[0]))) (row,col) = (membrane_indices[0][randmem], membrane_indices[1][randmem]) label = 1.0 positiveSample = False else: randmem = random.choice(xrange(len(non_membrane_indices[0]))) (row,col) = (non_membrane_indices[0][randmem], non_membrane_indices[1][randmem]) label = 0.0 positiveSample = True imgPatch = img[row-border+1:row+border, col-border+1:col+border] imgPatch = skimage.transform.rotate(imgPatch, random.choice(xrange(360))) imgPatch = imgPatch[border-border_patch:border+border_patch-1,border-border_patch:border+border_patch-1] if random.random() < 0.5: imgPatch = np.fliplr(imgPatch) imgPatch = np.rot90(imgPatch, random.randint(0,3)) whole_set_patches[counter,:] = imgPatch.flatten() whole_set_labels[counter] = label counter += 1 #normalize data whole_data = np.float32(whole_set_patches) whole_data = whole_data - 0.5 data = whole_data.copy() labels = whole_set_labels.copy() #remove the sorting in image order shuffleIndex = rng.permutation(np.shape(labels)[0]) for i in xrange(np.shape(labels)[0]): whole_data[i,:] = data[shuffleIndex[i],:] whole_set_labels[i] = labels[shuffleIndex[i]] data_set = (whole_data, whole_set_labels) end_time = time.time() total_time = (end_time - start_time) print 'Running time: ' + '%.2fm' % (total_time / 60.) rval = data_set return rval def generate_image_data(img, patchSize=29, rows=1): img = normalizeImage(img) # pad image borders border = np.int(np.ceil(patchSize/2.0)) img_padded = np.pad(img, border, mode='reflect') whole_set_patches = np.zeros((len(rows)*img.shape[1], patchSize**2)) counter = 0 for row in rows: for col in xrange(img.shape[1]): imgPatch = img_padded[row+1:row+2*border, col+1:col+2*border] whole_set_patches[counter,:] = imgPatch.flatten() counter += 1 #normalize data whole_set_patches = np.float32(whole_set_patches) whole_set_patches = whole_set_patches - 0.5 return whole_set_patches def stupid_map_wrapper(parameters): f = parameters[0] args = parameters[1:] return f(*args) def get_sample_sizes(annotations): samples_sizes = [] n_labels = len(annotations) for coordinates in annotations: n_label_samples_size = len(coordinates)/2 samples_sizes.append( n_label_samples_size ) return samples_sizes def gen_membrane_image(annotations, dim): m_image = np.zeros( (dim[0], dim[1]) ) label = 1 coordinates = annotations[ label ] n_coordinates = len(coordinates) i = 0 while i < n_coordinates: x = coordinates[i] y = coordinates[i+1] m_image[x][y] = 1.0 i = i+2 return m_image def generate_experiment_data_patch_prediction(purpose='train', nsamples=1000, patchSize=29, outPatchSize=1, project=None): nr_layers=3 def relabel(image): id_list = np.unique(image) for index, id in enumerate(id_list): image[image==id] = index return image start_time = time.time() if purpose == 'train': images = DB.getTrainingImages( project.id, new=False ) path = Paths.TrainGrayscale else: images = DB.getImages( project.id, purpose=1, new=False, annotated=True ) path = Paths.ValidGrayscale files_gray = [] data_labels = [] label_sample_sizes = np.array([ 0, 0]) #imgs = DB.getImages( project.id ) for image in images: d_path = '%s/%s.tif'%(path, image.id) l_path = '%s/%s.%s.json'%(Paths.Labels, image.id, project.id) if os.path.exists( d_path ) and os.path.exists( l_path ): # load the annotations with open( l_path ) as labels_f: annotations = json.load( labels_f ) # skip if not enough samples in the annotations sample_sizes = get_sample_sizes( annotations ) if np.sum( sample_sizes ) == 0: continue label_sample_sizes = label_sample_sizes + np.array(sample_sizes) files_gray.append( d_path ) data_labels.append( annotations ) if len( files_gray ) == 0 or len( data_labels ) == 0 or np.min( label_sample_sizes ) == 0: return None whole_set_patches = np.zeros((nsamples, patchSize**2), dtype=np.float) whole_set_labels = np.zeros((nsamples, outPatchSize**2), dtype=np.int32) #how many samples per image? nsamples_perImage = np.uint(np.ceil( (nsamples) / np.float(np.shape(files_gray)[0]) )) print 'using ' + np.str(nsamples_perImage) + ' samples per image.' counter = 0 border_patch = np.ceil(patchSize/2.0) pad = patchSize read_order = np.random.permutation(np.shape(files_gray)[0]) for index in read_order: file_image = files_gray[index] labels = data_labels[index] sample_sizes = get_sample_sizes( labels ) img = mahotas.imread(files_gray[index]) img = np.pad(img, ((pad, pad), (pad, pad)), 'symmetric') # normalizes [0,1] img = normalizeImage(img, doClahe=True) membrane_img = gen_membrane_image( labels, img.shape ) #img_cs = int(np.floor(nr_layers/2)) #if purpose=='train': # # adjust according to middle image # membrane_img = adjust_imprecise_boundaries(img[:,:,img_cs], membrane_img, 0) #get rid of invalid image borders #membrane_img[:,-patchSize:] = 0 #membrane_img[-patchSize:,:] = 0 valid_indices = np.nonzero(membrane_img) print valid_indices if len(valid_indices[0]) == 0 or len(valid_indices[1]) == 0: continue for i in xrange(nsamples_perImage): if counter >= nsamples: break randmem = random.choice(xrange(len(valid_indices[0]))) (row,col) = (valid_indices[0][randmem], valid_indices[1][randmem]) imgPatch = img[row:row+patchSize, col:col+patchSize] memPatch = membrane_img[row:row+patchSize, col:col+patchSize] if random.random() < 0.5: imgPatch = np.fliplr(imgPatch) memPatch = np.fliplr(memPatch) rotateInt = random.randint(0,3) imgPatch = np.rot90(imgPatch, rotateInt) memPatch = np.rot90(memPatch, rotateInt) #imgPatch = deform_image(imgPatch) imgPatch, memPatch = deform_images( imgPatch, memPatch ) imgPatch = imgPatch / np.double(np.max(imgPatch)) memPatch = memPatch / np.double(np.max(memPatch)) # crop labelPatch to potentially smaller output size offset_small_patch = int(np.ceil((patchSize - outPatchSize) / 2.0)) memPatch = memPatch[offset_small_patch:offset_small_patch+outPatchSize,offset_small_patch:offset_small_patch+outPatchSize] whole_set_patches[counter,:] = imgPatch.flatten() whole_set_labels[counter] = memPatch.flatten() counter = counter + 1 #normalize data whole_data = np.float32(whole_set_patches) whole_data = whole_data - 0.5 data = whole_data.copy() labels = whole_set_labels.copy() #remove the sorting in image order shuffleIndex = np.random.permutation(np.shape(labels)[0]) for i in xrange(np.shape(labels)[0]): whole_data[i,:] = data[shuffleIndex[i],:] whole_set_labels[i,:] = labels[shuffleIndex[i],:] data_set = (whole_data, whole_set_labels) print np.min(whole_data), np.max(whole_data) end_time = time.time() total_time = (end_time - start_time) print 'Running time: ', total_time / 60. print 'finished sampling data' return data_set def agenerate_experiment_data_patch_prediction(purpose='train', nsamples=1000, patchSize=29, outPatchSize=1, project=None): def relabel(image): id_list = np.unique(image) for index, id in enumerate(id_list): image[image==id] = index return image start_time = time.time() if purpose == 'train': images = DB.getTrainingImages( project.id, new=False ) path = Paths.TrainGrayscale else: images = DB.getImages( project.id, purpose=1, new=False, annotated=True ) path = Paths.ValidGrayscale files_gray = [] data_labels = [] label_sample_sizes = np.array([ 0, 0]) #imgs = DB.getImages( project.id ) for image in images: d_path = '%s/%s.tif'%(path, image.id) l_path = '%s/%s.%s.json'%(Paths.Labels, image.id, project.id) if os.path.exists( d_path ) and os.path.exists( l_path ): # load the annotations with open( l_path ) as labels_f: annotations = json.load( labels_f ) # skip if not enough samples in the annotations sample_sizes = get_sample_sizes( annotations ) if np.sum( sample_sizes ) == 0: continue label_sample_sizes = label_sample_sizes + np.array(sample_sizes) files_gray.append( d_path ) data_labels.append( annotations ) print len(files_gray) print len(data_labels) print label_sample_sizes if len( files_gray ) == 0 or len( data_labels ) == 0 or np.min( label_sample_sizes ) == 0: return None whole_set_patches = np.zeros((nsamples, patchSize**2), dtype=np.float) whole_set_labels = np.zeros((nsamples, outPatchSize**2), dtype=np.int32) #how many samples per image? nsamples_perImage = np.uint(np.ceil( (nsamples) / np.float(np.shape(files_gray)[0]) )) print 'using ' + np.str(nsamples_perImage) + ' samples per image.' counter = 0 border_patch = np.ceil(patchSize/2.0) pad = patchSize read_order = np.random.permutation(np.shape(files_gray)[0]) for index in read_order: file_image = files_gray[index] labels = data_labels[index] sample_sizes = get_sample_sizes( labels ) img = mahotas.imread(files_gray[index]) img = np.pad(img, ((pad, pad), (pad, pad)), 'symmetric') # normalizes [0,1] img = normalizeImage(img, doClahe=True) membrane_img = gen_membrane_image( labels, img.shape ) print membrane_img.shape print np.unique(membrane_img) for label, coordinates in enumerate( labels ): if counter >= nsamples: break ncoordinates = len(coordinates) if ncoordinates == 0: continue # randomly sample from the label indices = np.random.choice( ncoordinates, sample_sizes[label], replace=False) for i in indices: if i%2 == 1: i = i-1 if counter >= nsamples: break col = coordinates[i] row = coordinates[i+1] r1 = int(row+patchSize-border_patch) r2 = int(row+patchSize+border_patch) c1 = int(col+patchSize-border_patch) c2 = int(col+patchSize+border_patch) imgPatch = img[r1:r2,c1:c2] memPatch = membrane_img[r1:r2,c1:c2] if random.random() < 0.5: imgPatch = np.fliplr(imgPatch) memPatch = np.fliplr(memPatch) rotateInt = random.randint(0,3) imgPatch = np.rot90(imgPatch, rotateInt) memPatch = np.rot90(memPatch, rotateInt) #imgPatch = deform_image(imgPatch) imgPatch, memPatch = deform_images( imgPatch, memPatch ) imgPatch = imgPatch / np.double(np.max(imgPatch)) memPatch = memPatch / np.double(np.max(memPatch)) # crop labelPatch to potentially smaller output size offset_small_patch = int(np.ceil((patchSize - outPatchSize) / 2.0)) memPatch = memPatch[offset_small_patch:offset_small_patch+outPatchSize,offset_small_patch:offset_small_patch+outPatchSize] whole_set_patches[counter,:] = imgPatch.flatten() whole_set_labels[counter] = memPatch.flatten() counter = counter + 1 #normalize data whole_data = np.float32(whole_set_patches) whole_data = whole_data - 0.5 data = whole_data.copy() labels = whole_set_labels.copy() #remove the sorting in image order shuffleIndex = np.random.permutation(np.shape(labels)[0]) for i in xrange(np.shape(labels)[0]): whole_data[i,:] = data[shuffleIndex[i],:] whole_set_labels[i,:] = labels[shuffleIndex[i],:] data_set = (whole_data, whole_set_labels) print np.min(whole_data), np.max(whole_data) end_time = time.time() total_time = (end_time - start_time) print 'Running time: ', total_time / 60. print 'finished sampling data' return data_set def gen_validation_data(project, nsamples=1000, patchSize=29, outPatchSize=1): def relabel(image): id_list = np.unique(image) for index, id in enumerate(id_list): image[image==id] = index return image start_time = time.time() img_search_string_membraneImages = '%s/*.tif'%(Paths.ValidMembranes) img_search_string_labelImages = '%s/*.tif'%(Paths.ValidLabels) img_search_string_grayImages = '%s/*.tif'%(Paths.ValidGray) img_files_gray = sorted( glob.glob( img_search_string_grayImages ) ) img_files_membrane = sorted( glob.glob( img_search_string_membraneImages ) ) img_files_labels = sorted( glob.glob( img_search_string_labelImages ) ) whole_set_patches = np.zeros((nsamples, patchSize**2), dtype=np.float) whole_set_labels = np.zeros((nsamples, outPatchSize**2), dtype=np.int32) whole_set_membranes = np.zeros((nsamples, outPatchSize**2), dtype=np.int32) #how many samples per image? nsamples_perImage = np.uint(np.ceil( (nsamples) / np.float(np.shape(img_files_gray)[0]) )) print 'using ' + np.str(nsamples_perImage) + ' samples per image.' counter = 0 img = mahotas.imread(img_files_gray[0]) grayImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) labelImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) membraneImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) maskImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) # read the data # in random order read_order = np.random.permutation(np.shape(img_files_gray)[0]) for img_index in read_order: #print img_files_gray[img_index] img = mahotas.imread(img_files_gray[img_index]) # normalizes [0,1] img = normalizeImage(img, doClahe=True) grayImages[:,:,img_index] = img membrane_img = mahotas.imread(img_files_membrane[img_index])/255. membraneImages[:,:,img_index] = membrane_img maskImages[:,:,img_index] = 1.0 label_img = mahotas.imread(img_files_labels[img_index]) label_img = np.double(label_img) if label_img.ndim == 3: label_img = label_img[:,:,0] + 255*label_img[:,:,1] + 255**2 * label_img[:,:,2] labelImages[:,:,img_index] = label_img for img_index in xrange(np.shape(img_files_gray)[0]): #print img_files_gray[read_order[img_index]] img = grayImages[:,:,img_index] label_img = labelImages[:,:,img_index] membrane_img = membraneImages[:,:,img_index] mask_img = maskImages[:,:,img_index] #get rid of invalid image borders mask_img[:,-patchSize:] = 0 mask_img[-patchSize:,:] = 0 valid_indices = np.nonzero(mask_img) for i in xrange(nsamples_perImage): if counter >= nsamples: break randmem = random.choice(xrange(len(valid_indices[0]))) (row,col) = (valid_indices[0][randmem], valid_indices[1][randmem]) imgPatch = img[row:row+patchSize, col:col+patchSize] membranePatch = membrane_img[row:row+patchSize, col:col+patchSize] labelPatch = label_img[row:row+patchSize, col:col+patchSize] if random.random() < 0.5: imgPatch = np.fliplr(imgPatch) membranePatch = np.fliplr(membranePatch) labelPatch = np.fliplr(labelPatch) rotateInt = random.randint(0,3) imgPatch = np.rot90(imgPatch, rotateInt) membranePatch = np.rot90(membranePatch, rotateInt) labelPatch = np.rot90(labelPatch, rotateInt) labelPatch = relabel(labelPatch) imgPatch, membranePatch, labelPatch = deform_images(imgPatch, membranePatch, np.uint8(labelPatch)) imgPatch = imgPatch / np.double(np.max(imgPatch)) membranePatch = membranePatch / np.double(np.max(membranePatch)) # crop labelPatch to potentially smaller output size offset_small_patch = int(np.ceil((patchSize - outPatchSize) / 2.0)) membranePatch = membranePatch[offset_small_patch:offset_small_patch+outPatchSize, offset_small_patch:offset_small_patch+outPatchSize] labelPatch = labelPatch[offset_small_patch:offset_small_patch+outPatchSize, offset_small_patch:offset_small_patch+outPatchSize] whole_set_patches[counter,:] = imgPatch.flatten() whole_set_labels[counter] = labelPatch.flatten() whole_set_membranes[counter] = np.int32(membranePatch.flatten() > 0) counter += 1 #normalize data whole_data = np.float32(whole_set_patches) whole_data = whole_data - 0.5 data = whole_data.copy() labels = whole_set_labels.copy() membranes = whole_set_membranes.copy() #remove the sorting in image order shuffleIndex = np.random.permutation(np.shape(membranes)[0]) for i in xrange(np.shape(membranes)[0]): whole_data[i,:] = data[shuffleIndex[i],:] whole_set_labels[i,:] = labels[shuffleIndex[i],:] whole_set_membranes[i,:] = membranes[shuffleIndex[i],:] data_set = (whole_data, whole_set_membranes, whole_set_labels) end_time = time.time() total_time = (end_time - start_time) print 'Running time: ', total_time / 60. print 'finished sampling data' return data_set def gen_training_data(project, purpose='train', nsamples=1000, patchSize=29, outPatchSize=1): def relabel(image): id_list = np.unique(image) for index, id in enumerate(id_list): image[image==id] = index return image print 'gen_data' if project == None: return start_time = time.time() files_gray = [] files_membranes = [] if purpose == 'train': images = DB.getTrainingImages( project.id, new=False ) path = Paths.TrainGrayscale for image in images: d_path = '%s/%s.tif'%(path, image.id) m_path = '%s/%s.%s.json'%(Paths.Labels, image.id, project.id) if os.path.exists( d_path ) and os.path.exists( l_path ): ''' # load the annotations with open( l_path ) as labels_f: annotations = json.load( labels_f ) # skip if not enough samples in the annotations sample_sizes = get_sample_sizes( annotations ) if np.sum( sample_sizes ) == 0: continue label_sample_sizes = label_sample_sizes + np.array(sample_sizes) files_gray.append( d_path ) data_labels.append( annotations ) ''' files_gray.append( d_path ) files_membranes.append( m_path ) else: images = DB.getImages( project.id, purpose=1, new=False, annotated=True ) path = Paths.ValidLabels files_gray = [] data_labels = [] label_sample_sizes = np.array([ 0, 0]) if len( files_gray ) == 0 or len( data_labels ) == 0 or np.min( label_sample_sizes ) == 0: return None whole_set_patches = np.zeros((nsamples, patchSize**2), dtype=np.float) whole_set_labels = np.zeros((nsamples, outPatchSize**2), dtype=np.int32) whole_set_membranes = np.zeros((nsamples, outPatchSize**2), dtype=np.int32) return data # changed the patch sampling to use upper left corner instead of middle pixel # for patch labels it doesn't matter and it makes sampling even and odd patches easier def oldgenerate_experiment_data_patch_prediction(purpose='train', nsamples=1000, patchSize=29, outPatchSize=1): def relabel(image): id_list = np.unique(image) for index, id in enumerate(id_list): image[image==id] = index return image start_time = time.time() # pathPrefix = '/media/vkaynig/Data1/Cmor_paper_data/' # pathPrefix = '/media/vkaynig/Data1/Cmor_paper_data/Thalamus-LGN/Data/25-175_train/' #pathPrefix = '/media/vkaynig/Data1/Cmor_paper_data/Cerebellum-P7/Dense/' pathPrefix = '/n/home00/fgonda/icon/data/reference/' if not os.path.exists(pathPrefix): pathPrefix = '/n/pfister_lab/vkaynig/' #img_search_string_membraneImages = pathPrefix + 'labels/membranes_fullContour/' + purpose + '/*.tif' img_search_string_membraneImages = pathPrefix + 'labels/membranes/' + purpose + '/*.tif' img_search_string_labelImages = pathPrefix + 'labels/' + purpose + '/*.tif' img_search_string_grayImages = pathPrefix + 'images/' + purpose + '/*.tif' img_files_gray = sorted( glob.glob( img_search_string_grayImages ) ) img_files_membrane = sorted( glob.glob( img_search_string_membraneImages ) ) img_files_labels = sorted( glob.glob( img_search_string_labelImages ) ) print len(img_files_gray) print len(img_files_membrane) print len(img_files_labels) whole_set_patches = np.zeros((nsamples, patchSize**2), dtype=np.float) whole_set_labels = np.zeros((nsamples, outPatchSize**2), dtype=np.int32) whole_set_membranes = np.zeros((nsamples, outPatchSize**2), dtype=np.int32) #how many samples per image? nsamples_perImage = np.uint(np.ceil( (nsamples) / np.float(np.shape(img_files_gray)[0]) )) print 'using ' + np.str(nsamples_perImage) + ' samples per image.' counter = 0 img = mahotas.imread(img_files_gray[0]) grayImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) labelImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) membraneImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) maskImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) # read the data # in random order read_order = np.random.permutation(np.shape(img_files_gray)[0]) for img_index in read_order: #print img_files_gray[img_index] img = mahotas.imread(img_files_gray[img_index]) # normalizes [0,1] img = normalizeImage(img, doClahe=True) grayImages[:,:,img_index] = img membrane_img = mahotas.imread(img_files_membrane[img_index])/255. membraneImages[:,:,img_index] = membrane_img maskImages[:,:,img_index] = 1.0 if purpose == 'validate': label_img = mahotas.imread(img_files_labels[img_index]) label_img = np.double(label_img) if label_img.ndim == 3: label_img = label_img[:,:,0] + 255*label_img[:,:,1] + 255**2 * label_img[:,:,2] labelImages[:,:,img_index] = label_img for img_index in xrange(np.shape(img_files_gray)[0]): #print img_files_gray[read_order[img_index]] img = grayImages[:,:,img_index] label_img = labelImages[:,:,img_index] membrane_img = membraneImages[:,:,img_index] mask_img = maskImages[:,:,img_index] if purpose=='train': membrane_img = adjust_imprecise_boundaries(img, membrane_img, 0) #get rid of invalid image borders mask_img[:,-patchSize:] = 0 mask_img[-patchSize:,:] = 0 valid_indices = np.nonzero(mask_img) for i in xrange(nsamples_perImage): if counter >= nsamples: break randmem = random.choice(xrange(len(valid_indices[0]))) (row,col) = (valid_indices[0][randmem], valid_indices[1][randmem]) imgPatch = img[row:row+patchSize, col:col+patchSize] membranePatch = membrane_img[row:row+patchSize, col:col+patchSize] labelPatch = label_img[row:row+patchSize, col:col+patchSize] if random.random() < 0.5: imgPatch = np.fliplr(imgPatch) membranePatch = np.fliplr(membranePatch) if purpose == 'validate': labelPatch = np.fliplr(labelPatch) rotateInt = random.randint(0,3) imgPatch = np.rot90(imgPatch, rotateInt) membranePatch = np.rot90(membranePatch, rotateInt) if purpose=='validate': labelPatch = np.rot90(labelPatch, rotateInt) if purpose=='validate': labelPatch = relabel(labelPatch) imgPatch, membranePatch, labelPatch = deform_images(imgPatch, membranePatch, np.uint8(labelPatch)) else: imgPatch, membranePatch = deform_images(imgPatch, membranePatch) imgPatch = imgPatch / np.double(np.max(imgPatch)) membranePatch = membranePatch / np.double(np.max(membranePatch)) # crop labelPatch to potentially smaller output size offset_small_patch = int(np.ceil((patchSize - outPatchSize) / 2.0)) membranePatch = membranePatch[offset_small_patch:offset_small_patch+outPatchSize, offset_small_patch:offset_small_patch+outPatchSize] labelPatch = labelPatch[offset_small_patch:offset_small_patch+outPatchSize, offset_small_patch:offset_small_patch+outPatchSize] whole_set_patches[counter,:] = imgPatch.flatten() whole_set_labels[counter] = labelPatch.flatten() whole_set_membranes[counter] = np.int32(membranePatch.flatten() > 0) counter += 1 #normalize data whole_data = np.float32(whole_set_patches) whole_data = whole_data - 0.5 data = whole_data.copy() labels = whole_set_labels.copy() membranes = whole_set_membranes.copy() #remove the sorting in image order shuffleIndex = np.random.permutation(np.shape(membranes)[0]) for i in xrange(np.shape(membranes)[0]): whole_data[i,:] = data[shuffleIndex[i],:] whole_set_labels[i,:] = labels[shuffleIndex[i],:] whole_set_membranes[i,:] = membranes[shuffleIndex[i],:] if purpose == 'validate': data_set = (whole_data, whole_set_membranes, whole_set_labels) else: data_set = (whole_data, whole_set_membranes) end_time = time.time() total_time = (end_time - start_time) print 'Running time: ', total_time / 60. print 'finished sampling data' return data_set def generate_experiment_data_patch_prediction_layers(purpose='train', nsamples=1000, patchSize=29, outPatchSize=1, nr_layers=3): def relabel(image): id_list = np.unique(image) for index, id in enumerate(id_list): image[image==id] = index return image start_time = time.time() if os.path.exists('/media/vkaynig/Data1/Cmor_paper_data/'): pathPrefix = '/media/vkaynig/Data1/Cmor_paper_data/' else: pathPrefix = '/n/pfister_lab/vkaynig/' img_search_string_membraneImages = pathPrefix + 'labels/membranes_fullContour/' + purpose + '/*.tif' img_search_string_labelImages = pathPrefix + 'labels/' + purpose + '/*.tif' img_search_string_grayImages = pathPrefix + 'images/' + purpose + '/*.tif' img_files_gray = sorted( glob.glob( img_search_string_grayImages ) ) img_files_membrane = sorted( glob.glob( img_search_string_membraneImages ) ) img_files_labels = sorted( glob.glob( img_search_string_labelImages ) ) whole_set_patches = np.zeros((nsamples, nr_layers, patchSize**2), dtype=np.float) whole_set_labels = np.zeros((nsamples, outPatchSize**2), dtype=np.int32) whole_set_membranes = np.zeros((nsamples, outPatchSize**2), dtype=np.int32) #how many samples per image? nsamples_perImage = np.uint(np.ceil( (nsamples) / np.float(np.shape(img_files_gray)[0]) )) print 'using ' + np.str(nsamples_perImage) + ' samples per image.' counter = 0 img = mahotas.imread(img_files_gray[0]) grayImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) labelImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) membraneImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) maskImages = np.zeros((img.shape[0],img.shape[1], np.shape(img_files_gray)[0])) # read the data # in random order #read_order = np.random.permutation(np.shape(img_files_gray)[0]) for img_index in range(np.shape(img_files_gray)[0]): #print img_files_gray[img_index] img = mahotas.imread(img_files_gray[img_index]) # normalizes [0,1] img = normalizeImage(img) grayImages[:,:,img_index] = img membrane_img = mahotas.imread(img_files_membrane[img_index])/255. membraneImages[:,:,img_index] = membrane_img maskImages[:,:,img_index] = 1.0 if purpose == 'validate': label_img = mahotas.imread(img_files_labels[img_index]) label_img = np.double(label_img) labelImages[:,:,img_index] = label_img for img_index in xrange(np.shape(img_files_gray)[0]): img_cs = int(np.floor(nr_layers/2)) img_valid_range_indices = np.clip(range(img_index-img_cs,img_index+img_cs+1),0,np.shape(img_files_gray)[0]-1) img = grayImages[:,:,img_valid_range_indices] label_img = labelImages[:,:,img_index] membrane_img = membraneImages[:,:,img_index] mask_img = maskImages[:,:,img_index] if purpose=='train': # adjust according to middle image membrane_img = adjust_imprecise_boundaries(img[:,:,img_cs], membrane_img, 0) #get rid of invalid image borders mask_img[:,-patchSize:] = 0 mask_img[-patchSize:,:] = 0 valid_indices = np.nonzero(mask_img) for i in xrange(nsamples_perImage): if counter >= nsamples: break randmem = random.choice(xrange(len(valid_indices[0]))) (row,col) = (valid_indices[0][randmem], valid_indices[1][randmem]) imgPatch = img[row:row+patchSize, col:col+patchSize,:] membranePatch = membrane_img[row:row+patchSize, col:col+patchSize] labelPatch = label_img[row:row+patchSize, col:col+patchSize] if random.random() < 0.5: for flip_i in xrange(nr_layers): imgPatch[:,:,flip_i] = np.fliplr(imgPatch[:,:,flip_i]) membranePatch = np.fliplr(membranePatch) if purpose == 'validate': labelPatch = np.fliplr(labelPatch) rotateInt = random.randint(0,3) for rot_i in xrange(nr_layers): imgPatch[:,:,rot_i] = np.rot90(imgPatch[:,:,rot_i], rotateInt) membranePatch = np.rot90(membranePatch, rotateInt) if purpose=='validate': labelPatch = np.rot90(labelPatch, rotateInt) if purpose=='validate': labelPatch = relabel(labelPatch) deformed_images = deform_images_list(np.dstack([imgPatch*255, np.reshape(membranePatch*255,(patchSize,patchSize,1)), np.uint8(np.reshape(labelPatch,(patchSize,patchSize,1)))])) imgPatch, membranePatch, labelPatch = np.split(deformed_images,[imgPatch.shape[2],imgPatch.shape[2]+1], axis=2) else: deformed_images = deform_images_list(np.dstack([imgPatch*255, np.reshape(membranePatch,(patchSize,patchSize,1))*255])) imgPatch, membranePatch = np.split(deformed_images,[imgPatch.shape[2]], axis=2) imgPatch = imgPatch / np.double(np.max(imgPatch)) membranePatch = membranePatch / np.double(np.max(membranePatch)) # crop labelPatch to potentially smaller output size offset_small_patch = int(np.ceil((patchSize - outPatchSize) / 2.0)) membranePatch = membranePatch[offset_small_patch:offset_small_patch+outPatchSize, offset_small_patch:offset_small_patch+outPatchSize] labelPatch = labelPatch[offset_small_patch:offset_small_patch+outPatchSize, offset_small_patch:offset_small_patch+outPatchSize] #whole_set_patches = np.zeros((nsamples, nr_layers, patchSize**2), dtype=np.float) for patch_i in xrange(nr_layers): whole_set_patches[counter,patch_i,:] = imgPatch[:,:,patch_i].flatten() whole_set_labels[counter] = labelPatch.flatten() whole_set_membranes[counter] = np.int32(membranePatch.flatten() > 0) counter += 1 #normalize data whole_data = np.float32(whole_set_patches) whole_data = whole_data - 0.5 data = whole_data.copy() labels = whole_set_labels.copy() membranes = whole_set_membranes.copy() #remove the sorting in image order shuffleIndex = np.random.permutation(np.shape(membranes)[0]) for i in xrange(np.shape(membranes)[0]): whole_data[i,:,:] = data[shuffleIndex[i],:,:] whole_set_labels[i,:] = labels[shuffleIndex[i],:] whole_set_membranes[i,:] = membranes[shuffleIndex[i],:] if purpose == 'validate': data_set = (whole_data, whole_set_membranes, whole_set_labels) else: data_set = (whole_data, whole_set_membranes) end_time = time.time() total_time = (end_time - start_time) print 'Running time: ', total_time / 60. print 'finished sampling data' return data_set if __name__=="__main__": import uuid test = generate_experiment_data_patch_prediction(purpose='train', nsamples=30, patchSize=572, outPatchSize=388) dir_path = './training_patches/' for i in xrange(30): unique_filename = str(uuid.uuid4()) img = np.reshape(test[1][i],(388,388)) img_gray = np.reshape(test[0][i],(572,572)) mahotas.imsave(dir_path+unique_filename+'.tif', np.uint8(img*255)) mahotas.imsave(dir_path+unique_filename+'_gray.tif', np.uint8((img_gray+0.5)*255)) #data_val = generate_experiment_data_supervised(purpose='validate', nsamples=10000, patchSize=65, balanceRate=0.5) #data = generate_experiment_data_patch_prediction(purpose='validate', nsamples=2, patchSize=315, outPatchSize=215) # plt.imshow(np.reshape(data[0][0],(315,315))); plt.figure() # plt.imshow(np.reshape(data[1][0],(215,215))); plt.figure() # plt.imshow(np.reshape(data[2][0],(215,215))); plt.show() # image = mahotas.imread('ac3_input_0141.tif') # image = normalizeImage(image) # label = mahotas.imread('ac3_labels_0141.tif') / 255. # test = adjust_imprecise_boundaries(image, label, 10) # plt.imshow(label+image); plt.show() # plt.imshow(test+image); plt.show()
mit
lootr/netzob
netzob/test/src/test_netzob/test_Common/test_ExecutionContext.py
4
2556
# -*- coding: utf-8 -*- #+---------------------------------------------------------------------------+ #| 01001110 01100101 01110100 01111010 01101111 01100010 | #| | #| Netzob : Inferring communication protocols | #+---------------------------------------------------------------------------+ #| Copyright (C) 2011-2017 Georges Bossert and Frédéric Guihéry | #| This program is free software: you can redistribute it and/or modify | #| it under the terms of the GNU General Public License as published by | #| the Free Software Foundation, either version 3 of the License, or | #| (at your option) any later version. | #| | #| This program is distributed in the hope that it will be useful, | #| but WITHOUT ANY WARRANTY; without even the implied warranty of | #| MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | #| GNU General Public License for more details. | #| | #| You should have received a copy of the GNU General Public License | #| along with this program. If not, see <http://www.gnu.org/licenses/>. | #+---------------------------------------------------------------------------+ #| @url : http://www.netzob.org | #| @contact : contact@netzob.org | #| @sponsors : Amossys, http://www.amossys.fr | #| Supélec, http://www.rennes.supelec.fr/ren/rd/cidre/ | #+---------------------------------------------------------------------------+ #+---------------------------------------------------------------------------+ #| Standard library imports #+---------------------------------------------------------------------------+ import unittest from netzob.Common.ExecutionContext import ExecutionContext #+---------------------------------------------------------------------------+ #| Local Imports #+---------------------------------------------------------------------------+ class test_ExecutionContext(unittest.TestCase): def test_getCurrentProcesses(self): current = ExecutionContext.getCurrentProcesses() self.assertGreater(len(current), 5)
gpl-3.0
houzhenggang/hiwifi-openwrt-HC5661-HC5761
staging_dir/target-mipsel_r2_uClibc-0.9.33.2/root-ralink/usr/lib/python2.7/distutils/emxccompiler.py
250
11931
"""distutils.emxccompiler Provides the EMXCCompiler class, a subclass of UnixCCompiler that handles the EMX port of the GNU C compiler to OS/2. """ # issues: # # * OS/2 insists that DLLs can have names no longer than 8 characters # We put export_symbols in a def-file, as though the DLL can have # an arbitrary length name, but truncate the output filename. # # * only use OMF objects and use LINK386 as the linker (-Zomf) # # * always build for multithreading (-Zmt) as the accompanying OS/2 port # of Python is only distributed with threads enabled. # # tested configurations: # # * EMX gcc 2.81/EMX 0.9d fix03 __revision__ = "$Id$" import os,sys,copy from distutils.ccompiler import gen_preprocess_options, gen_lib_options from distutils.unixccompiler import UnixCCompiler from distutils.file_util import write_file from distutils.errors import DistutilsExecError, CompileError, UnknownFileError from distutils import log class EMXCCompiler (UnixCCompiler): compiler_type = 'emx' obj_extension = ".obj" static_lib_extension = ".lib" shared_lib_extension = ".dll" static_lib_format = "%s%s" shared_lib_format = "%s%s" res_extension = ".res" # compiled resource file exe_extension = ".exe" def __init__ (self, verbose=0, dry_run=0, force=0): UnixCCompiler.__init__ (self, verbose, dry_run, force) (status, details) = check_config_h() self.debug_print("Python's GCC status: %s (details: %s)" % (status, details)) if status is not CONFIG_H_OK: self.warn( "Python's pyconfig.h doesn't seem to support your compiler. " + ("Reason: %s." % details) + "Compiling may fail because of undefined preprocessor macros.") (self.gcc_version, self.ld_version) = \ get_versions() self.debug_print(self.compiler_type + ": gcc %s, ld %s\n" % (self.gcc_version, self.ld_version) ) # Hard-code GCC because that's what this is all about. # XXX optimization, warnings etc. should be customizable. self.set_executables(compiler='gcc -Zomf -Zmt -O3 -fomit-frame-pointer -mprobe -Wall', compiler_so='gcc -Zomf -Zmt -O3 -fomit-frame-pointer -mprobe -Wall', linker_exe='gcc -Zomf -Zmt -Zcrtdll', linker_so='gcc -Zomf -Zmt -Zcrtdll -Zdll') # want the gcc library statically linked (so that we don't have # to distribute a version dependent on the compiler we have) self.dll_libraries=["gcc"] # __init__ () def _compile(self, obj, src, ext, cc_args, extra_postargs, pp_opts): if ext == '.rc': # gcc requires '.rc' compiled to binary ('.res') files !!! try: self.spawn(["rc", "-r", src]) except DistutilsExecError, msg: raise CompileError, msg else: # for other files use the C-compiler try: self.spawn(self.compiler_so + cc_args + [src, '-o', obj] + extra_postargs) except DistutilsExecError, msg: raise CompileError, msg def link (self, target_desc, objects, output_filename, output_dir=None, libraries=None, library_dirs=None, runtime_library_dirs=None, export_symbols=None, debug=0, extra_preargs=None, extra_postargs=None, build_temp=None, target_lang=None): # use separate copies, so we can modify the lists extra_preargs = copy.copy(extra_preargs or []) libraries = copy.copy(libraries or []) objects = copy.copy(objects or []) # Additional libraries libraries.extend(self.dll_libraries) # handle export symbols by creating a def-file # with executables this only works with gcc/ld as linker if ((export_symbols is not None) and (target_desc != self.EXECUTABLE)): # (The linker doesn't do anything if output is up-to-date. # So it would probably better to check if we really need this, # but for this we had to insert some unchanged parts of # UnixCCompiler, and this is not what we want.) # we want to put some files in the same directory as the # object files are, build_temp doesn't help much # where are the object files temp_dir = os.path.dirname(objects[0]) # name of dll to give the helper files the same base name (dll_name, dll_extension) = os.path.splitext( os.path.basename(output_filename)) # generate the filenames for these files def_file = os.path.join(temp_dir, dll_name + ".def") # Generate .def file contents = [ "LIBRARY %s INITINSTANCE TERMINSTANCE" % \ os.path.splitext(os.path.basename(output_filename))[0], "DATA MULTIPLE NONSHARED", "EXPORTS"] for sym in export_symbols: contents.append(' "%s"' % sym) self.execute(write_file, (def_file, contents), "writing %s" % def_file) # next add options for def-file and to creating import libraries # for gcc/ld the def-file is specified as any other object files objects.append(def_file) #end: if ((export_symbols is not None) and # (target_desc != self.EXECUTABLE or self.linker_dll == "gcc")): # who wants symbols and a many times larger output file # should explicitly switch the debug mode on # otherwise we let dllwrap/ld strip the output file # (On my machine: 10KB < stripped_file < ??100KB # unstripped_file = stripped_file + XXX KB # ( XXX=254 for a typical python extension)) if not debug: extra_preargs.append("-s") UnixCCompiler.link(self, target_desc, objects, output_filename, output_dir, libraries, library_dirs, runtime_library_dirs, None, # export_symbols, we do this in our def-file debug, extra_preargs, extra_postargs, build_temp, target_lang) # link () # -- Miscellaneous methods ----------------------------------------- # override the object_filenames method from CCompiler to # support rc and res-files def object_filenames (self, source_filenames, strip_dir=0, output_dir=''): if output_dir is None: output_dir = '' obj_names = [] for src_name in source_filenames: # use normcase to make sure '.rc' is really '.rc' and not '.RC' (base, ext) = os.path.splitext (os.path.normcase(src_name)) if ext not in (self.src_extensions + ['.rc']): raise UnknownFileError, \ "unknown file type '%s' (from '%s')" % \ (ext, src_name) if strip_dir: base = os.path.basename (base) if ext == '.rc': # these need to be compiled to object files obj_names.append (os.path.join (output_dir, base + self.res_extension)) else: obj_names.append (os.path.join (output_dir, base + self.obj_extension)) return obj_names # object_filenames () # override the find_library_file method from UnixCCompiler # to deal with file naming/searching differences def find_library_file(self, dirs, lib, debug=0): shortlib = '%s.lib' % lib longlib = 'lib%s.lib' % lib # this form very rare # get EMX's default library directory search path try: emx_dirs = os.environ['LIBRARY_PATH'].split(';') except KeyError: emx_dirs = [] for dir in dirs + emx_dirs: shortlibp = os.path.join(dir, shortlib) longlibp = os.path.join(dir, longlib) if os.path.exists(shortlibp): return shortlibp elif os.path.exists(longlibp): return longlibp # Oops, didn't find it in *any* of 'dirs' return None # class EMXCCompiler # Because these compilers aren't configured in Python's pyconfig.h file by # default, we should at least warn the user if he is using a unmodified # version. CONFIG_H_OK = "ok" CONFIG_H_NOTOK = "not ok" CONFIG_H_UNCERTAIN = "uncertain" def check_config_h(): """Check if the current Python installation (specifically, pyconfig.h) appears amenable to building extensions with GCC. Returns a tuple (status, details), where 'status' is one of the following constants: CONFIG_H_OK all is well, go ahead and compile CONFIG_H_NOTOK doesn't look good CONFIG_H_UNCERTAIN not sure -- unable to read pyconfig.h 'details' is a human-readable string explaining the situation. Note there are two ways to conclude "OK": either 'sys.version' contains the string "GCC" (implying that this Python was built with GCC), or the installed "pyconfig.h" contains the string "__GNUC__". """ # XXX since this function also checks sys.version, it's not strictly a # "pyconfig.h" check -- should probably be renamed... from distutils import sysconfig import string # if sys.version contains GCC then python was compiled with # GCC, and the pyconfig.h file should be OK if string.find(sys.version,"GCC") >= 0: return (CONFIG_H_OK, "sys.version mentions 'GCC'") fn = sysconfig.get_config_h_filename() try: # It would probably better to read single lines to search. # But we do this only once, and it is fast enough f = open(fn) try: s = f.read() finally: f.close() except IOError, exc: # if we can't read this file, we cannot say it is wrong # the compiler will complain later about this file as missing return (CONFIG_H_UNCERTAIN, "couldn't read '%s': %s" % (fn, exc.strerror)) else: # "pyconfig.h" contains an "#ifdef __GNUC__" or something similar if string.find(s,"__GNUC__") >= 0: return (CONFIG_H_OK, "'%s' mentions '__GNUC__'" % fn) else: return (CONFIG_H_NOTOK, "'%s' does not mention '__GNUC__'" % fn) def get_versions(): """ Try to find out the versions of gcc and ld. If not possible it returns None for it. """ from distutils.version import StrictVersion from distutils.spawn import find_executable import re gcc_exe = find_executable('gcc') if gcc_exe: out = os.popen(gcc_exe + ' -dumpversion','r') try: out_string = out.read() finally: out.close() result = re.search('(\d+\.\d+\.\d+)',out_string) if result: gcc_version = StrictVersion(result.group(1)) else: gcc_version = None else: gcc_version = None # EMX ld has no way of reporting version number, and we use GCC # anyway - so we can link OMF DLLs ld_version = None return (gcc_version, ld_version)
gpl-2.0
dharmabumstead/ansible
test/units/modules/network/aruba/test_aruba_command.py
57
4349
# (c) 2016 Red Hat Inc. # # This file is part of Ansible # # Ansible is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # Ansible is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with Ansible. If not, see <http://www.gnu.org/licenses/>. # Make coding more python3-ish from __future__ import (absolute_import, division, print_function) __metaclass__ = type import json from ansible.compat.tests.mock import patch from ansible.modules.network.aruba import aruba_command from units.modules.utils import set_module_args from .aruba_module import TestArubaModule, load_fixture class TestArubaCommandModule(TestArubaModule): module = aruba_command def setUp(self): super(TestArubaCommandModule, self).setUp() self.mock_run_commands = patch('ansible.modules.network.aruba.aruba_command.run_commands') self.run_commands = self.mock_run_commands.start() def tearDown(self): super(TestArubaCommandModule, self).tearDown() self.mock_run_commands.stop() def load_fixtures(self, commands=None): def load_from_file(*args, **kwargs): module, commands = args output = list() for item in commands: try: obj = json.loads(item['command']) command = obj['command'] except ValueError: command = item['command'] filename = str(command).replace(' ', '_') output.append(load_fixture(filename)) return output self.run_commands.side_effect = load_from_file def test_aruba_command_simple(self): set_module_args(dict(commands=['show version'])) result = self.execute_module() self.assertEqual(len(result['stdout']), 1) self.assertTrue(result['stdout'][0].startswith('Aruba Operating System Software')) def test_aruba_command_multiple(self): set_module_args(dict(commands=['show version', 'show version'])) result = self.execute_module() self.assertEqual(len(result['stdout']), 2) self.assertTrue(result['stdout'][0].startswith('Aruba Operating System Software')) def test_aruba_command_wait_for(self): wait_for = 'result[0] contains "Aruba Operating System Software"' set_module_args(dict(commands=['show version'], wait_for=wait_for)) self.execute_module() def test_aruba_command_wait_for_fails(self): wait_for = 'result[0] contains "test string"' set_module_args(dict(commands=['show version'], wait_for=wait_for)) self.execute_module(failed=True) self.assertEqual(self.run_commands.call_count, 10) def test_aruba_command_retries(self): wait_for = 'result[0] contains "test string"' set_module_args(dict(commands=['show version'], wait_for=wait_for, retries=2)) self.execute_module(failed=True) self.assertEqual(self.run_commands.call_count, 2) def test_aruba_command_match_any(self): wait_for = ['result[0] contains "Aruba Operating System Software"', 'result[0] contains "test string"'] set_module_args(dict(commands=['show version'], wait_for=wait_for, match='any')) self.execute_module() def test_aruba_command_match_all(self): wait_for = ['result[0] contains "Aruba Operating System Software"', 'result[0] contains "Aruba Networks"'] set_module_args(dict(commands=['show version'], wait_for=wait_for, match='all')) self.execute_module() def test_aruba_command_match_all_failure(self): wait_for = ['result[0] contains "Aruba Operating System Software"', 'result[0] contains "test string"'] commands = ['show version', 'show version'] set_module_args(dict(commands=commands, wait_for=wait_for, match='all')) self.execute_module(failed=True)
gpl-3.0
pobizhe/shadowsocks
shadowsocks/crypto/util.py
1032
4287
#!/usr/bin/env python # # Copyright 2015 clowwindy # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations # under the License. from __future__ import absolute_import, division, print_function, \ with_statement import os import logging def find_library_nt(name): # modified from ctypes.util # ctypes.util.find_library just returns first result he found # but we want to try them all # because on Windows, users may have both 32bit and 64bit version installed results = [] for directory in os.environ['PATH'].split(os.pathsep): fname = os.path.join(directory, name) if os.path.isfile(fname): results.append(fname) if fname.lower().endswith(".dll"): continue fname = fname + ".dll" if os.path.isfile(fname): results.append(fname) return results def find_library(possible_lib_names, search_symbol, library_name): import ctypes.util from ctypes import CDLL paths = [] if type(possible_lib_names) not in (list, tuple): possible_lib_names = [possible_lib_names] lib_names = [] for lib_name in possible_lib_names: lib_names.append(lib_name) lib_names.append('lib' + lib_name) for name in lib_names: if os.name == "nt": paths.extend(find_library_nt(name)) else: path = ctypes.util.find_library(name) if path: paths.append(path) if not paths: # We may get here when find_library fails because, for example, # the user does not have sufficient privileges to access those # tools underlying find_library on linux. import glob for name in lib_names: patterns = [ '/usr/local/lib*/lib%s.*' % name, '/usr/lib*/lib%s.*' % name, 'lib%s.*' % name, '%s.dll' % name] for pat in patterns: files = glob.glob(pat) if files: paths.extend(files) for path in paths: try: lib = CDLL(path) if hasattr(lib, search_symbol): logging.info('loading %s from %s', library_name, path) return lib else: logging.warn('can\'t find symbol %s in %s', search_symbol, path) except Exception: pass return None def run_cipher(cipher, decipher): from os import urandom import random import time BLOCK_SIZE = 16384 rounds = 1 * 1024 plain = urandom(BLOCK_SIZE * rounds) results = [] pos = 0 print('test start') start = time.time() while pos < len(plain): l = random.randint(100, 32768) c = cipher.update(plain[pos:pos + l]) results.append(c) pos += l pos = 0 c = b''.join(results) results = [] while pos < len(plain): l = random.randint(100, 32768) results.append(decipher.update(c[pos:pos + l])) pos += l end = time.time() print('speed: %d bytes/s' % (BLOCK_SIZE * rounds / (end - start))) assert b''.join(results) == plain def test_find_library(): assert find_library('c', 'strcpy', 'libc') is not None assert find_library(['c'], 'strcpy', 'libc') is not None assert find_library(('c',), 'strcpy', 'libc') is not None assert find_library(('crypto', 'eay32'), 'EVP_CipherUpdate', 'libcrypto') is not None assert find_library('notexist', 'strcpy', 'libnotexist') is None assert find_library('c', 'symbol_not_exist', 'c') is None assert find_library(('notexist', 'c', 'crypto', 'eay32'), 'EVP_CipherUpdate', 'libc') is not None if __name__ == '__main__': test_find_library()
apache-2.0
ahu-odoo/odoo
addons/account_analytic_plans/__openerp__.py
45
3145
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Management Solution # Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as # published by the Free Software Foundation, either version 3 of the # License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU Affero General Public License for more details. # # You should have received a copy of the GNU Affero General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # ############################################################################## { 'name': 'Multiple Analytic Plans', 'version': '1.0', 'category': 'Accounting & Finance', 'description': """ This module allows to use several analytic plans according to the general journal. ================================================================================== Here multiple analytic lines are created when the invoice or the entries are confirmed. For example, you can define the following analytic structure: ------------------------------------------------------------- * **Projects** * Project 1 + SubProj 1.1 + SubProj 1.2 * Project 2 * **Salesman** * Eric * Fabien Here, we have two plans: Projects and Salesman. An invoice line must be able to write analytic entries in the 2 plans: SubProj 1.1 and Fabien. The amount can also be split. The following example is for an invoice that touches the two subprojects and assigned to one salesman: ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ **Plan1:** * SubProject 1.1 : 50% * SubProject 1.2 : 50% **Plan2:** Eric: 100% So when this line of invoice will be confirmed, it will generate 3 analytic lines,for one account entry. The analytic plan validates the minimum and maximum percentage at the time of creation of distribution models. """, 'author': 'OpenERP SA', 'website': 'http://www.openerp.com', 'images': ['images/analytic_plan.jpeg'], 'depends': ['account', 'account_analytic_default'], 'data': [ 'security/account_analytic_plan_security.xml', 'security/ir.model.access.csv', 'account_analytic_plans_view.xml', 'account_analytic_plans_report.xml', 'wizard/analytic_plan_create_model_view.xml', 'wizard/account_crossovered_analytic_view.xml', 'views/report_crossoveredanalyticplans.xml', 'views/account_analytic_plans.xml', ], 'demo': [], 'test': ['test/acount_analytic_plans_report.yml'], 'installable': True, 'auto_install': False, } # vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
agpl-3.0
alex/boto
tests/integration/iam/test_connection.py
100
1746
# Copyright (c) 2014 Amazon.com, Inc. or its affiliates. # All rights reserved. # # Permission is hereby granted, free of charge, to any person obtaining a # copy of this software and associated documentation files (the # "Software"), to deal in the Software without restriction, including # without limitation the rights to use, copy, modify, merge, publish, dis- # tribute, sublicense, and/or sell copies of the Software, and to permit # persons to whom the Software is furnished to do so, subject to the fol- # lowing conditions: # # The above copyright notice and this permission notice shall be included # in all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS # OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABIL- # ITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT # SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, # WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS # IN THE SOFTWARE. import boto import time from tests.compat import unittest class TestIAM(unittest.TestCase): iam = True def test_group_users(self): # A very basic test to create a group, a user, add the user # to the group and then delete everything iam = boto.connect_iam() name = 'boto-test-%d' % time.time() username = 'boto-test-user-%d' % time.time() iam.create_group(name) iam.create_user(username) iam.add_user_to_group(name, username) iam.remove_user_from_group(name, username) iam.delete_user(username) iam.delete_group(name)
mit
MounirMesselmeni/django
django/contrib/auth/__init__.py
69
7305
import inspect import re from django.apps import apps as django_apps from django.conf import settings from django.core.exceptions import ImproperlyConfigured, PermissionDenied from django.middleware.csrf import rotate_token from django.utils.crypto import constant_time_compare from django.utils.module_loading import import_string from django.utils.translation import LANGUAGE_SESSION_KEY from .signals import user_logged_in, user_logged_out, user_login_failed SESSION_KEY = '_auth_user_id' BACKEND_SESSION_KEY = '_auth_user_backend' HASH_SESSION_KEY = '_auth_user_hash' REDIRECT_FIELD_NAME = 'next' def load_backend(path): return import_string(path)() def _get_backends(return_tuples=False): backends = [] for backend_path in settings.AUTHENTICATION_BACKENDS: backend = load_backend(backend_path) backends.append((backend, backend_path) if return_tuples else backend) if not backends: raise ImproperlyConfigured( 'No authentication backends have been defined. Does ' 'AUTHENTICATION_BACKENDS contain anything?' ) return backends def get_backends(): return _get_backends(return_tuples=False) def _clean_credentials(credentials): """ Cleans a dictionary of credentials of potentially sensitive info before sending to less secure functions. Not comprehensive - intended for user_login_failed signal """ SENSITIVE_CREDENTIALS = re.compile('api|token|key|secret|password|signature', re.I) CLEANSED_SUBSTITUTE = '********************' for key in credentials: if SENSITIVE_CREDENTIALS.search(key): credentials[key] = CLEANSED_SUBSTITUTE return credentials def _get_user_session_key(request): # This value in the session is always serialized to a string, so we need # to convert it back to Python whenever we access it. return get_user_model()._meta.pk.to_python(request.session[SESSION_KEY]) def authenticate(**credentials): """ If the given credentials are valid, return a User object. """ for backend, backend_path in _get_backends(return_tuples=True): try: inspect.getcallargs(backend.authenticate, **credentials) except TypeError: # This backend doesn't accept these credentials as arguments. Try the next one. continue try: user = backend.authenticate(**credentials) except PermissionDenied: # This backend says to stop in our tracks - this user should not be allowed in at all. return None if user is None: continue # Annotate the user object with the path of the backend. user.backend = backend_path return user # The credentials supplied are invalid to all backends, fire signal user_login_failed.send(sender=__name__, credentials=_clean_credentials(credentials)) def login(request, user): """ Persist a user id and a backend in the request. This way a user doesn't have to reauthenticate on every request. Note that data set during the anonymous session is retained when the user logs in. """ session_auth_hash = '' if user is None: user = request.user if hasattr(user, 'get_session_auth_hash'): session_auth_hash = user.get_session_auth_hash() if SESSION_KEY in request.session: if _get_user_session_key(request) != user.pk or ( session_auth_hash and request.session.get(HASH_SESSION_KEY) != session_auth_hash): # To avoid reusing another user's session, create a new, empty # session if the existing session corresponds to a different # authenticated user. request.session.flush() else: request.session.cycle_key() request.session[SESSION_KEY] = user._meta.pk.value_to_string(user) request.session[BACKEND_SESSION_KEY] = user.backend request.session[HASH_SESSION_KEY] = session_auth_hash if hasattr(request, 'user'): request.user = user rotate_token(request) user_logged_in.send(sender=user.__class__, request=request, user=user) def logout(request): """ Removes the authenticated user's ID from the request and flushes their session data. """ # Dispatch the signal before the user is logged out so the receivers have a # chance to find out *who* logged out. user = getattr(request, 'user', None) if hasattr(user, 'is_authenticated') and not user.is_authenticated(): user = None user_logged_out.send(sender=user.__class__, request=request, user=user) # remember language choice saved to session language = request.session.get(LANGUAGE_SESSION_KEY) request.session.flush() if language is not None: request.session[LANGUAGE_SESSION_KEY] = language if hasattr(request, 'user'): from django.contrib.auth.models import AnonymousUser request.user = AnonymousUser() def get_user_model(): """ Returns the User model that is active in this project. """ try: return django_apps.get_model(settings.AUTH_USER_MODEL) except ValueError: raise ImproperlyConfigured("AUTH_USER_MODEL must be of the form 'app_label.model_name'") except LookupError: raise ImproperlyConfigured( "AUTH_USER_MODEL refers to model '%s' that has not been installed" % settings.AUTH_USER_MODEL ) def get_user(request): """ Returns the user model instance associated with the given request session. If no user is retrieved an instance of `AnonymousUser` is returned. """ from .models import AnonymousUser user = None try: user_id = _get_user_session_key(request) backend_path = request.session[BACKEND_SESSION_KEY] except KeyError: pass else: if backend_path in settings.AUTHENTICATION_BACKENDS: backend = load_backend(backend_path) user = backend.get_user(user_id) # Verify the session if hasattr(user, 'get_session_auth_hash'): session_hash = request.session.get(HASH_SESSION_KEY) session_hash_verified = session_hash and constant_time_compare( session_hash, user.get_session_auth_hash() ) if not session_hash_verified: request.session.flush() user = None return user or AnonymousUser() def get_permission_codename(action, opts): """ Returns the codename of the permission for the specified action. """ return '%s_%s' % (action, opts.model_name) def update_session_auth_hash(request, user): """ Updating a user's password logs out all sessions for the user. This function takes the current request and the updated user object from which the new session hash will be derived and updates the session hash appropriately to prevent a password change from logging out the session from which the password was changed. """ if hasattr(user, 'get_session_auth_hash') and request.user == user: request.session[HASH_SESSION_KEY] = user.get_session_auth_hash() default_app_config = 'django.contrib.auth.apps.AuthConfig'
bsd-3-clause
lz1988/django-web
build/lib/django/contrib/webdesign/lorem_ipsum.py
230
4908
""" Utility functions for generating "lorem ipsum" Latin text. """ from __future__ import unicode_literals import random COMMON_P = 'Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.' WORDS = ('exercitationem', 'perferendis', 'perspiciatis', 'laborum', 'eveniet', 'sunt', 'iure', 'nam', 'nobis', 'eum', 'cum', 'officiis', 'excepturi', 'odio', 'consectetur', 'quasi', 'aut', 'quisquam', 'vel', 'eligendi', 'itaque', 'non', 'odit', 'tempore', 'quaerat', 'dignissimos', 'facilis', 'neque', 'nihil', 'expedita', 'vitae', 'vero', 'ipsum', 'nisi', 'animi', 'cumque', 'pariatur', 'velit', 'modi', 'natus', 'iusto', 'eaque', 'sequi', 'illo', 'sed', 'ex', 'et', 'voluptatibus', 'tempora', 'veritatis', 'ratione', 'assumenda', 'incidunt', 'nostrum', 'placeat', 'aliquid', 'fuga', 'provident', 'praesentium', 'rem', 'necessitatibus', 'suscipit', 'adipisci', 'quidem', 'possimus', 'voluptas', 'debitis', 'sint', 'accusantium', 'unde', 'sapiente', 'voluptate', 'qui', 'aspernatur', 'laudantium', 'soluta', 'amet', 'quo', 'aliquam', 'saepe', 'culpa', 'libero', 'ipsa', 'dicta', 'reiciendis', 'nesciunt', 'doloribus', 'autem', 'impedit', 'minima', 'maiores', 'repudiandae', 'ipsam', 'obcaecati', 'ullam', 'enim', 'totam', 'delectus', 'ducimus', 'quis', 'voluptates', 'dolores', 'molestiae', 'harum', 'dolorem', 'quia', 'voluptatem', 'molestias', 'magni', 'distinctio', 'omnis', 'illum', 'dolorum', 'voluptatum', 'ea', 'quas', 'quam', 'corporis', 'quae', 'blanditiis', 'atque', 'deserunt', 'laboriosam', 'earum', 'consequuntur', 'hic', 'cupiditate', 'quibusdam', 'accusamus', 'ut', 'rerum', 'error', 'minus', 'eius', 'ab', 'ad', 'nemo', 'fugit', 'officia', 'at', 'in', 'id', 'quos', 'reprehenderit', 'numquam', 'iste', 'fugiat', 'sit', 'inventore', 'beatae', 'repellendus', 'magnam', 'recusandae', 'quod', 'explicabo', 'doloremque', 'aperiam', 'consequatur', 'asperiores', 'commodi', 'optio', 'dolor', 'labore', 'temporibus', 'repellat', 'veniam', 'architecto', 'est', 'esse', 'mollitia', 'nulla', 'a', 'similique', 'eos', 'alias', 'dolore', 'tenetur', 'deleniti', 'porro', 'facere', 'maxime', 'corrupti') COMMON_WORDS = ('lorem', 'ipsum', 'dolor', 'sit', 'amet', 'consectetur', 'adipisicing', 'elit', 'sed', 'do', 'eiusmod', 'tempor', 'incididunt', 'ut', 'labore', 'et', 'dolore', 'magna', 'aliqua') def sentence(): """ Returns a randomly generated sentence of lorem ipsum text. The first word is capitalized, and the sentence ends in either a period or question mark. Commas are added at random. """ # Determine the number of comma-separated sections and number of words in # each section for this sentence. sections = [' '.join(random.sample(WORDS, random.randint(3, 12))) for i in range(random.randint(1, 5))] s = ', '.join(sections) # Convert to sentence case and add end punctuation. return '%s%s%s' % (s[0].upper(), s[1:], random.choice('?.')) def paragraph(): """ Returns a randomly generated paragraph of lorem ipsum text. The paragraph consists of between 1 and 4 sentences, inclusive. """ return ' '.join([sentence() for i in range(random.randint(1, 4))]) def paragraphs(count, common=True): """ Returns a list of paragraphs as returned by paragraph(). If `common` is True, then the first paragraph will be the standard 'lorem ipsum' paragraph. Otherwise, the first paragraph will be random Latin text. Either way, subsequent paragraphs will be random Latin text. """ paras = [] for i in range(count): if common and i == 0: paras.append(COMMON_P) else: paras.append(paragraph()) return paras def words(count, common=True): """ Returns a string of `count` lorem ipsum words separated by a single space. If `common` is True, then the first 19 words will be the standard 'lorem ipsum' words. Otherwise, all words will be selected randomly. """ if common: word_list = list(COMMON_WORDS) else: word_list = [] c = len(word_list) if count > c: count -= c while count > 0: c = min(count, len(WORDS)) count -= c word_list += random.sample(WORDS, c) else: word_list = word_list[:count] return ' '.join(word_list)
apache-2.0
xyzz/vcmi-build
project/jni/python/src/Lib/encodings/cp861.py
593
34889
""" Python Character Mapping Codec generated from 'VENDORS/MICSFT/PC/CP861.TXT' with gencodec.py. """#" import codecs ### Codec APIs class Codec(codecs.Codec): def encode(self,input,errors='strict'): return codecs.charmap_encode(input,errors,encoding_map) def decode(self,input,errors='strict'): return codecs.charmap_decode(input,errors,decoding_table) class IncrementalEncoder(codecs.IncrementalEncoder): def encode(self, input, final=False): return codecs.charmap_encode(input,self.errors,encoding_map)[0] class IncrementalDecoder(codecs.IncrementalDecoder): def decode(self, input, final=False): return codecs.charmap_decode(input,self.errors,decoding_table)[0] class StreamWriter(Codec,codecs.StreamWriter): pass class StreamReader(Codec,codecs.StreamReader): pass ### encodings module API def getregentry(): return codecs.CodecInfo( name='cp861', encode=Codec().encode, decode=Codec().decode, incrementalencoder=IncrementalEncoder, incrementaldecoder=IncrementalDecoder, streamreader=StreamReader, streamwriter=StreamWriter, ) ### Decoding Map decoding_map = codecs.make_identity_dict(range(256)) decoding_map.update({ 0x0080: 0x00c7, # LATIN CAPITAL LETTER C WITH CEDILLA 0x0081: 0x00fc, # LATIN SMALL LETTER U WITH DIAERESIS 0x0082: 0x00e9, # LATIN SMALL LETTER E WITH ACUTE 0x0083: 0x00e2, # LATIN SMALL LETTER A WITH CIRCUMFLEX 0x0084: 0x00e4, # LATIN SMALL LETTER A WITH DIAERESIS 0x0085: 0x00e0, # LATIN SMALL LETTER A WITH GRAVE 0x0086: 0x00e5, # LATIN SMALL LETTER A WITH RING ABOVE 0x0087: 0x00e7, # LATIN SMALL LETTER C WITH CEDILLA 0x0088: 0x00ea, # LATIN SMALL LETTER E WITH CIRCUMFLEX 0x0089: 0x00eb, # LATIN SMALL LETTER E WITH DIAERESIS 0x008a: 0x00e8, # LATIN SMALL LETTER E WITH GRAVE 0x008b: 0x00d0, # LATIN CAPITAL LETTER ETH 0x008c: 0x00f0, # LATIN SMALL LETTER ETH 0x008d: 0x00de, # LATIN CAPITAL LETTER THORN 0x008e: 0x00c4, # LATIN CAPITAL LETTER A WITH DIAERESIS 0x008f: 0x00c5, # LATIN CAPITAL LETTER A WITH RING ABOVE 0x0090: 0x00c9, # LATIN CAPITAL LETTER E WITH ACUTE 0x0091: 0x00e6, # LATIN SMALL LIGATURE AE 0x0092: 0x00c6, # LATIN CAPITAL LIGATURE AE 0x0093: 0x00f4, # LATIN SMALL LETTER O WITH CIRCUMFLEX 0x0094: 0x00f6, # LATIN SMALL LETTER O WITH DIAERESIS 0x0095: 0x00fe, # LATIN SMALL LETTER THORN 0x0096: 0x00fb, # LATIN SMALL LETTER U WITH CIRCUMFLEX 0x0097: 0x00dd, # LATIN CAPITAL LETTER Y WITH ACUTE 0x0098: 0x00fd, # LATIN SMALL LETTER Y WITH ACUTE 0x0099: 0x00d6, # LATIN CAPITAL LETTER O WITH DIAERESIS 0x009a: 0x00dc, # LATIN CAPITAL LETTER U WITH DIAERESIS 0x009b: 0x00f8, # LATIN SMALL LETTER O WITH STROKE 0x009c: 0x00a3, # POUND SIGN 0x009d: 0x00d8, # LATIN CAPITAL LETTER O WITH STROKE 0x009e: 0x20a7, # PESETA SIGN 0x009f: 0x0192, # LATIN SMALL LETTER F WITH HOOK 0x00a0: 0x00e1, # LATIN SMALL LETTER A WITH ACUTE 0x00a1: 0x00ed, # LATIN SMALL LETTER I WITH ACUTE 0x00a2: 0x00f3, # LATIN SMALL LETTER O WITH ACUTE 0x00a3: 0x00fa, # LATIN SMALL LETTER U WITH ACUTE 0x00a4: 0x00c1, # LATIN CAPITAL LETTER A WITH ACUTE 0x00a5: 0x00cd, # LATIN CAPITAL LETTER I WITH ACUTE 0x00a6: 0x00d3, # LATIN CAPITAL LETTER O WITH ACUTE 0x00a7: 0x00da, # LATIN CAPITAL LETTER U WITH ACUTE 0x00a8: 0x00bf, # INVERTED QUESTION MARK 0x00a9: 0x2310, # REVERSED NOT SIGN 0x00aa: 0x00ac, # NOT SIGN 0x00ab: 0x00bd, # VULGAR FRACTION ONE HALF 0x00ac: 0x00bc, # VULGAR FRACTION ONE QUARTER 0x00ad: 0x00a1, # INVERTED EXCLAMATION MARK 0x00ae: 0x00ab, # LEFT-POINTING DOUBLE ANGLE QUOTATION MARK 0x00af: 0x00bb, # RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK 0x00b0: 0x2591, # LIGHT SHADE 0x00b1: 0x2592, # MEDIUM SHADE 0x00b2: 0x2593, # DARK SHADE 0x00b3: 0x2502, # BOX DRAWINGS LIGHT VERTICAL 0x00b4: 0x2524, # BOX DRAWINGS LIGHT VERTICAL AND LEFT 0x00b5: 0x2561, # BOX DRAWINGS VERTICAL SINGLE AND LEFT DOUBLE 0x00b6: 0x2562, # BOX DRAWINGS VERTICAL DOUBLE AND LEFT SINGLE 0x00b7: 0x2556, # BOX DRAWINGS DOWN DOUBLE AND LEFT SINGLE 0x00b8: 0x2555, # BOX DRAWINGS DOWN SINGLE AND LEFT DOUBLE 0x00b9: 0x2563, # BOX DRAWINGS DOUBLE VERTICAL AND LEFT 0x00ba: 0x2551, # BOX DRAWINGS DOUBLE VERTICAL 0x00bb: 0x2557, # BOX DRAWINGS DOUBLE DOWN AND LEFT 0x00bc: 0x255d, # BOX DRAWINGS DOUBLE UP AND LEFT 0x00bd: 0x255c, # BOX DRAWINGS UP DOUBLE AND LEFT SINGLE 0x00be: 0x255b, # BOX DRAWINGS UP SINGLE AND LEFT DOUBLE 0x00bf: 0x2510, # BOX DRAWINGS LIGHT DOWN AND LEFT 0x00c0: 0x2514, # BOX DRAWINGS LIGHT UP AND RIGHT 0x00c1: 0x2534, # BOX DRAWINGS LIGHT UP AND HORIZONTAL 0x00c2: 0x252c, # BOX DRAWINGS LIGHT DOWN AND HORIZONTAL 0x00c3: 0x251c, # BOX DRAWINGS LIGHT VERTICAL AND RIGHT 0x00c4: 0x2500, # BOX DRAWINGS LIGHT HORIZONTAL 0x00c5: 0x253c, # BOX DRAWINGS LIGHT VERTICAL AND HORIZONTAL 0x00c6: 0x255e, # BOX DRAWINGS VERTICAL SINGLE AND RIGHT DOUBLE 0x00c7: 0x255f, # BOX DRAWINGS VERTICAL DOUBLE AND RIGHT SINGLE 0x00c8: 0x255a, # BOX DRAWINGS DOUBLE UP AND RIGHT 0x00c9: 0x2554, # BOX DRAWINGS DOUBLE DOWN AND RIGHT 0x00ca: 0x2569, # BOX DRAWINGS DOUBLE UP AND HORIZONTAL 0x00cb: 0x2566, # BOX DRAWINGS DOUBLE DOWN AND HORIZONTAL 0x00cc: 0x2560, # BOX DRAWINGS DOUBLE VERTICAL AND RIGHT 0x00cd: 0x2550, # BOX DRAWINGS DOUBLE HORIZONTAL 0x00ce: 0x256c, # BOX DRAWINGS DOUBLE VERTICAL AND HORIZONTAL 0x00cf: 0x2567, # BOX DRAWINGS UP SINGLE AND HORIZONTAL DOUBLE 0x00d0: 0x2568, # BOX DRAWINGS UP DOUBLE AND HORIZONTAL SINGLE 0x00d1: 0x2564, # BOX DRAWINGS DOWN SINGLE AND HORIZONTAL DOUBLE 0x00d2: 0x2565, # BOX DRAWINGS DOWN DOUBLE AND HORIZONTAL SINGLE 0x00d3: 0x2559, # BOX DRAWINGS UP DOUBLE AND RIGHT SINGLE 0x00d4: 0x2558, # BOX DRAWINGS UP SINGLE AND RIGHT DOUBLE 0x00d5: 0x2552, # BOX DRAWINGS DOWN SINGLE AND RIGHT DOUBLE 0x00d6: 0x2553, # BOX DRAWINGS DOWN DOUBLE AND RIGHT SINGLE 0x00d7: 0x256b, # BOX DRAWINGS VERTICAL DOUBLE AND HORIZONTAL SINGLE 0x00d8: 0x256a, # BOX DRAWINGS VERTICAL SINGLE AND HORIZONTAL DOUBLE 0x00d9: 0x2518, # BOX DRAWINGS LIGHT UP AND LEFT 0x00da: 0x250c, # BOX DRAWINGS LIGHT DOWN AND RIGHT 0x00db: 0x2588, # FULL BLOCK 0x00dc: 0x2584, # LOWER HALF BLOCK 0x00dd: 0x258c, # LEFT HALF BLOCK 0x00de: 0x2590, # RIGHT HALF BLOCK 0x00df: 0x2580, # UPPER HALF BLOCK 0x00e0: 0x03b1, # GREEK SMALL LETTER ALPHA 0x00e1: 0x00df, # LATIN SMALL LETTER SHARP S 0x00e2: 0x0393, # GREEK CAPITAL LETTER GAMMA 0x00e3: 0x03c0, # GREEK SMALL LETTER PI 0x00e4: 0x03a3, # GREEK CAPITAL LETTER SIGMA 0x00e5: 0x03c3, # GREEK SMALL LETTER SIGMA 0x00e6: 0x00b5, # MICRO SIGN 0x00e7: 0x03c4, # GREEK SMALL LETTER TAU 0x00e8: 0x03a6, # GREEK CAPITAL LETTER PHI 0x00e9: 0x0398, # GREEK CAPITAL LETTER THETA 0x00ea: 0x03a9, # GREEK CAPITAL LETTER OMEGA 0x00eb: 0x03b4, # GREEK SMALL LETTER DELTA 0x00ec: 0x221e, # INFINITY 0x00ed: 0x03c6, # GREEK SMALL LETTER PHI 0x00ee: 0x03b5, # GREEK SMALL LETTER EPSILON 0x00ef: 0x2229, # INTERSECTION 0x00f0: 0x2261, # IDENTICAL TO 0x00f1: 0x00b1, # PLUS-MINUS SIGN 0x00f2: 0x2265, # GREATER-THAN OR EQUAL TO 0x00f3: 0x2264, # LESS-THAN OR EQUAL TO 0x00f4: 0x2320, # TOP HALF INTEGRAL 0x00f5: 0x2321, # BOTTOM HALF INTEGRAL 0x00f6: 0x00f7, # DIVISION SIGN 0x00f7: 0x2248, # ALMOST EQUAL TO 0x00f8: 0x00b0, # DEGREE SIGN 0x00f9: 0x2219, # BULLET OPERATOR 0x00fa: 0x00b7, # MIDDLE DOT 0x00fb: 0x221a, # SQUARE ROOT 0x00fc: 0x207f, # SUPERSCRIPT LATIN SMALL LETTER N 0x00fd: 0x00b2, # SUPERSCRIPT TWO 0x00fe: 0x25a0, # BLACK SQUARE 0x00ff: 0x00a0, # NO-BREAK SPACE }) ### Decoding Table decoding_table = ( u'\x00' # 0x0000 -> NULL u'\x01' # 0x0001 -> START OF HEADING u'\x02' # 0x0002 -> START OF TEXT u'\x03' # 0x0003 -> END OF TEXT u'\x04' # 0x0004 -> END OF TRANSMISSION u'\x05' # 0x0005 -> ENQUIRY u'\x06' # 0x0006 -> ACKNOWLEDGE u'\x07' # 0x0007 -> BELL u'\x08' # 0x0008 -> BACKSPACE u'\t' # 0x0009 -> HORIZONTAL TABULATION u'\n' # 0x000a -> LINE FEED u'\x0b' # 0x000b -> VERTICAL TABULATION u'\x0c' # 0x000c -> FORM FEED u'\r' # 0x000d -> CARRIAGE RETURN u'\x0e' # 0x000e -> SHIFT OUT u'\x0f' # 0x000f -> SHIFT IN u'\x10' # 0x0010 -> DATA LINK ESCAPE u'\x11' # 0x0011 -> DEVICE CONTROL ONE u'\x12' # 0x0012 -> DEVICE CONTROL TWO u'\x13' # 0x0013 -> DEVICE CONTROL THREE u'\x14' # 0x0014 -> DEVICE CONTROL FOUR u'\x15' # 0x0015 -> NEGATIVE ACKNOWLEDGE u'\x16' # 0x0016 -> SYNCHRONOUS IDLE u'\x17' # 0x0017 -> END OF TRANSMISSION BLOCK u'\x18' # 0x0018 -> CANCEL u'\x19' # 0x0019 -> END OF MEDIUM u'\x1a' # 0x001a -> SUBSTITUTE u'\x1b' # 0x001b -> ESCAPE u'\x1c' # 0x001c -> FILE SEPARATOR u'\x1d' # 0x001d -> GROUP SEPARATOR u'\x1e' # 0x001e -> RECORD SEPARATOR u'\x1f' # 0x001f -> UNIT SEPARATOR u' ' # 0x0020 -> SPACE u'!' # 0x0021 -> EXCLAMATION MARK u'"' # 0x0022 -> QUOTATION MARK u'#' # 0x0023 -> NUMBER SIGN u'$' # 0x0024 -> DOLLAR SIGN u'%' # 0x0025 -> PERCENT SIGN u'&' # 0x0026 -> AMPERSAND u"'" # 0x0027 -> APOSTROPHE u'(' # 0x0028 -> LEFT PARENTHESIS u')' # 0x0029 -> RIGHT PARENTHESIS u'*' # 0x002a -> ASTERISK u'+' # 0x002b -> PLUS SIGN u',' # 0x002c -> COMMA u'-' # 0x002d -> HYPHEN-MINUS u'.' # 0x002e -> FULL STOP u'/' # 0x002f -> SOLIDUS u'0' # 0x0030 -> DIGIT ZERO u'1' # 0x0031 -> DIGIT ONE u'2' # 0x0032 -> DIGIT TWO u'3' # 0x0033 -> DIGIT THREE u'4' # 0x0034 -> DIGIT FOUR u'5' # 0x0035 -> DIGIT FIVE u'6' # 0x0036 -> DIGIT SIX u'7' # 0x0037 -> DIGIT SEVEN u'8' # 0x0038 -> DIGIT EIGHT u'9' # 0x0039 -> DIGIT NINE u':' # 0x003a -> COLON u';' # 0x003b -> SEMICOLON u'<' # 0x003c -> LESS-THAN SIGN u'=' # 0x003d -> EQUALS SIGN u'>' # 0x003e -> GREATER-THAN SIGN u'?' # 0x003f -> QUESTION MARK u'@' # 0x0040 -> COMMERCIAL AT u'A' # 0x0041 -> LATIN CAPITAL LETTER A u'B' # 0x0042 -> LATIN CAPITAL LETTER B u'C' # 0x0043 -> LATIN CAPITAL LETTER C u'D' # 0x0044 -> LATIN CAPITAL LETTER D u'E' # 0x0045 -> LATIN CAPITAL LETTER E u'F' # 0x0046 -> LATIN CAPITAL LETTER F u'G' # 0x0047 -> LATIN CAPITAL LETTER G u'H' # 0x0048 -> LATIN CAPITAL LETTER H u'I' # 0x0049 -> LATIN CAPITAL LETTER I u'J' # 0x004a -> LATIN CAPITAL LETTER J u'K' # 0x004b -> LATIN CAPITAL LETTER K u'L' # 0x004c -> LATIN CAPITAL LETTER L u'M' # 0x004d -> LATIN CAPITAL LETTER M u'N' # 0x004e -> LATIN CAPITAL LETTER N u'O' # 0x004f -> LATIN CAPITAL LETTER O u'P' # 0x0050 -> LATIN CAPITAL LETTER P u'Q' # 0x0051 -> LATIN CAPITAL LETTER Q u'R' # 0x0052 -> LATIN CAPITAL LETTER R u'S' # 0x0053 -> LATIN CAPITAL LETTER S u'T' # 0x0054 -> LATIN CAPITAL LETTER T u'U' # 0x0055 -> LATIN CAPITAL LETTER U u'V' # 0x0056 -> LATIN CAPITAL LETTER V u'W' # 0x0057 -> LATIN CAPITAL LETTER W u'X' # 0x0058 -> LATIN CAPITAL LETTER X u'Y' # 0x0059 -> LATIN CAPITAL LETTER Y u'Z' # 0x005a -> LATIN CAPITAL LETTER Z u'[' # 0x005b -> LEFT SQUARE BRACKET u'\\' # 0x005c -> REVERSE SOLIDUS u']' # 0x005d -> RIGHT SQUARE BRACKET u'^' # 0x005e -> CIRCUMFLEX ACCENT u'_' # 0x005f -> LOW LINE u'`' # 0x0060 -> GRAVE ACCENT u'a' # 0x0061 -> LATIN SMALL LETTER A u'b' # 0x0062 -> LATIN SMALL LETTER B u'c' # 0x0063 -> LATIN SMALL LETTER C u'd' # 0x0064 -> LATIN SMALL LETTER D u'e' # 0x0065 -> LATIN SMALL LETTER E u'f' # 0x0066 -> LATIN SMALL LETTER F u'g' # 0x0067 -> LATIN SMALL LETTER G u'h' # 0x0068 -> LATIN SMALL LETTER H u'i' # 0x0069 -> LATIN SMALL LETTER I u'j' # 0x006a -> LATIN SMALL LETTER J u'k' # 0x006b -> LATIN SMALL LETTER K u'l' # 0x006c -> LATIN SMALL LETTER L u'm' # 0x006d -> LATIN SMALL LETTER M u'n' # 0x006e -> LATIN SMALL LETTER N u'o' # 0x006f -> LATIN SMALL LETTER O u'p' # 0x0070 -> LATIN SMALL LETTER P u'q' # 0x0071 -> LATIN SMALL LETTER Q u'r' # 0x0072 -> LATIN SMALL LETTER R u's' # 0x0073 -> LATIN SMALL LETTER S u't' # 0x0074 -> LATIN SMALL LETTER T u'u' # 0x0075 -> LATIN SMALL LETTER U u'v' # 0x0076 -> LATIN SMALL LETTER V u'w' # 0x0077 -> LATIN SMALL LETTER W u'x' # 0x0078 -> LATIN SMALL LETTER X u'y' # 0x0079 -> LATIN SMALL LETTER Y u'z' # 0x007a -> LATIN SMALL LETTER Z u'{' # 0x007b -> LEFT CURLY BRACKET u'|' # 0x007c -> VERTICAL LINE u'}' # 0x007d -> RIGHT CURLY BRACKET u'~' # 0x007e -> TILDE u'\x7f' # 0x007f -> DELETE u'\xc7' # 0x0080 -> LATIN CAPITAL LETTER C WITH CEDILLA u'\xfc' # 0x0081 -> LATIN SMALL LETTER U WITH DIAERESIS u'\xe9' # 0x0082 -> LATIN SMALL LETTER E WITH ACUTE u'\xe2' # 0x0083 -> LATIN SMALL LETTER A WITH CIRCUMFLEX u'\xe4' # 0x0084 -> LATIN SMALL LETTER A WITH DIAERESIS u'\xe0' # 0x0085 -> LATIN SMALL LETTER A WITH GRAVE u'\xe5' # 0x0086 -> LATIN SMALL LETTER A WITH RING ABOVE u'\xe7' # 0x0087 -> LATIN SMALL LETTER C WITH CEDILLA u'\xea' # 0x0088 -> LATIN SMALL LETTER E WITH CIRCUMFLEX u'\xeb' # 0x0089 -> LATIN SMALL LETTER E WITH DIAERESIS u'\xe8' # 0x008a -> LATIN SMALL LETTER E WITH GRAVE u'\xd0' # 0x008b -> LATIN CAPITAL LETTER ETH u'\xf0' # 0x008c -> LATIN SMALL LETTER ETH u'\xde' # 0x008d -> LATIN CAPITAL LETTER THORN u'\xc4' # 0x008e -> LATIN CAPITAL LETTER A WITH DIAERESIS u'\xc5' # 0x008f -> LATIN CAPITAL LETTER A WITH RING ABOVE u'\xc9' # 0x0090 -> LATIN CAPITAL LETTER E WITH ACUTE u'\xe6' # 0x0091 -> LATIN SMALL LIGATURE AE u'\xc6' # 0x0092 -> LATIN CAPITAL LIGATURE AE u'\xf4' # 0x0093 -> LATIN SMALL LETTER O WITH CIRCUMFLEX u'\xf6' # 0x0094 -> LATIN SMALL LETTER O WITH DIAERESIS u'\xfe' # 0x0095 -> LATIN SMALL LETTER THORN u'\xfb' # 0x0096 -> LATIN SMALL LETTER U WITH CIRCUMFLEX u'\xdd' # 0x0097 -> LATIN CAPITAL LETTER Y WITH ACUTE u'\xfd' # 0x0098 -> LATIN SMALL LETTER Y WITH ACUTE u'\xd6' # 0x0099 -> LATIN CAPITAL LETTER O WITH DIAERESIS u'\xdc' # 0x009a -> LATIN CAPITAL LETTER U WITH DIAERESIS u'\xf8' # 0x009b -> LATIN SMALL LETTER O WITH STROKE u'\xa3' # 0x009c -> POUND SIGN u'\xd8' # 0x009d -> LATIN CAPITAL LETTER O WITH STROKE u'\u20a7' # 0x009e -> PESETA SIGN u'\u0192' # 0x009f -> LATIN SMALL LETTER F WITH HOOK u'\xe1' # 0x00a0 -> LATIN SMALL LETTER A WITH ACUTE u'\xed' # 0x00a1 -> LATIN SMALL LETTER I WITH ACUTE u'\xf3' # 0x00a2 -> LATIN SMALL LETTER O WITH ACUTE u'\xfa' # 0x00a3 -> LATIN SMALL LETTER U WITH ACUTE u'\xc1' # 0x00a4 -> LATIN CAPITAL LETTER A WITH ACUTE u'\xcd' # 0x00a5 -> LATIN CAPITAL LETTER I WITH ACUTE u'\xd3' # 0x00a6 -> LATIN CAPITAL LETTER O WITH ACUTE u'\xda' # 0x00a7 -> LATIN CAPITAL LETTER U WITH ACUTE u'\xbf' # 0x00a8 -> INVERTED QUESTION MARK u'\u2310' # 0x00a9 -> REVERSED NOT SIGN u'\xac' # 0x00aa -> NOT SIGN u'\xbd' # 0x00ab -> VULGAR FRACTION ONE HALF u'\xbc' # 0x00ac -> VULGAR FRACTION ONE QUARTER u'\xa1' # 0x00ad -> INVERTED EXCLAMATION MARK u'\xab' # 0x00ae -> LEFT-POINTING DOUBLE ANGLE QUOTATION MARK u'\xbb' # 0x00af -> RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK u'\u2591' # 0x00b0 -> LIGHT SHADE u'\u2592' # 0x00b1 -> MEDIUM SHADE u'\u2593' # 0x00b2 -> DARK SHADE u'\u2502' # 0x00b3 -> BOX DRAWINGS LIGHT VERTICAL u'\u2524' # 0x00b4 -> BOX DRAWINGS LIGHT VERTICAL AND LEFT u'\u2561' # 0x00b5 -> BOX DRAWINGS VERTICAL SINGLE AND LEFT DOUBLE u'\u2562' # 0x00b6 -> BOX DRAWINGS VERTICAL DOUBLE AND LEFT SINGLE u'\u2556' # 0x00b7 -> BOX DRAWINGS DOWN DOUBLE AND LEFT SINGLE u'\u2555' # 0x00b8 -> BOX DRAWINGS DOWN SINGLE AND LEFT DOUBLE u'\u2563' # 0x00b9 -> BOX DRAWINGS DOUBLE VERTICAL AND LEFT u'\u2551' # 0x00ba -> BOX DRAWINGS DOUBLE VERTICAL u'\u2557' # 0x00bb -> BOX DRAWINGS DOUBLE DOWN AND LEFT u'\u255d' # 0x00bc -> BOX DRAWINGS DOUBLE UP AND LEFT u'\u255c' # 0x00bd -> BOX DRAWINGS UP DOUBLE AND LEFT SINGLE u'\u255b' # 0x00be -> BOX DRAWINGS UP SINGLE AND LEFT DOUBLE u'\u2510' # 0x00bf -> BOX DRAWINGS LIGHT DOWN AND LEFT u'\u2514' # 0x00c0 -> BOX DRAWINGS LIGHT UP AND RIGHT u'\u2534' # 0x00c1 -> BOX DRAWINGS LIGHT UP AND HORIZONTAL u'\u252c' # 0x00c2 -> BOX DRAWINGS LIGHT DOWN AND HORIZONTAL u'\u251c' # 0x00c3 -> BOX DRAWINGS LIGHT VERTICAL AND RIGHT u'\u2500' # 0x00c4 -> BOX DRAWINGS LIGHT HORIZONTAL u'\u253c' # 0x00c5 -> BOX DRAWINGS LIGHT VERTICAL AND HORIZONTAL u'\u255e' # 0x00c6 -> BOX DRAWINGS VERTICAL SINGLE AND RIGHT DOUBLE u'\u255f' # 0x00c7 -> BOX DRAWINGS VERTICAL DOUBLE AND RIGHT SINGLE u'\u255a' # 0x00c8 -> BOX DRAWINGS DOUBLE UP AND RIGHT u'\u2554' # 0x00c9 -> BOX DRAWINGS DOUBLE DOWN AND RIGHT u'\u2569' # 0x00ca -> BOX DRAWINGS DOUBLE UP AND HORIZONTAL u'\u2566' # 0x00cb -> BOX DRAWINGS DOUBLE DOWN AND HORIZONTAL u'\u2560' # 0x00cc -> BOX DRAWINGS DOUBLE VERTICAL AND RIGHT u'\u2550' # 0x00cd -> BOX DRAWINGS DOUBLE HORIZONTAL u'\u256c' # 0x00ce -> BOX DRAWINGS DOUBLE VERTICAL AND HORIZONTAL u'\u2567' # 0x00cf -> BOX DRAWINGS UP SINGLE AND HORIZONTAL DOUBLE u'\u2568' # 0x00d0 -> BOX DRAWINGS UP DOUBLE AND HORIZONTAL SINGLE u'\u2564' # 0x00d1 -> BOX DRAWINGS DOWN SINGLE AND HORIZONTAL DOUBLE u'\u2565' # 0x00d2 -> BOX DRAWINGS DOWN DOUBLE AND HORIZONTAL SINGLE u'\u2559' # 0x00d3 -> BOX DRAWINGS UP DOUBLE AND RIGHT SINGLE u'\u2558' # 0x00d4 -> BOX DRAWINGS UP SINGLE AND RIGHT DOUBLE u'\u2552' # 0x00d5 -> BOX DRAWINGS DOWN SINGLE AND RIGHT DOUBLE u'\u2553' # 0x00d6 -> BOX DRAWINGS DOWN DOUBLE AND RIGHT SINGLE u'\u256b' # 0x00d7 -> BOX DRAWINGS VERTICAL DOUBLE AND HORIZONTAL SINGLE u'\u256a' # 0x00d8 -> BOX DRAWINGS VERTICAL SINGLE AND HORIZONTAL DOUBLE u'\u2518' # 0x00d9 -> BOX DRAWINGS LIGHT UP AND LEFT u'\u250c' # 0x00da -> BOX DRAWINGS LIGHT DOWN AND RIGHT u'\u2588' # 0x00db -> FULL BLOCK u'\u2584' # 0x00dc -> LOWER HALF BLOCK u'\u258c' # 0x00dd -> LEFT HALF BLOCK u'\u2590' # 0x00de -> RIGHT HALF BLOCK u'\u2580' # 0x00df -> UPPER HALF BLOCK u'\u03b1' # 0x00e0 -> GREEK SMALL LETTER ALPHA u'\xdf' # 0x00e1 -> LATIN SMALL LETTER SHARP S u'\u0393' # 0x00e2 -> GREEK CAPITAL LETTER GAMMA u'\u03c0' # 0x00e3 -> GREEK SMALL LETTER PI u'\u03a3' # 0x00e4 -> GREEK CAPITAL LETTER SIGMA u'\u03c3' # 0x00e5 -> GREEK SMALL LETTER SIGMA u'\xb5' # 0x00e6 -> MICRO SIGN u'\u03c4' # 0x00e7 -> GREEK SMALL LETTER TAU u'\u03a6' # 0x00e8 -> GREEK CAPITAL LETTER PHI u'\u0398' # 0x00e9 -> GREEK CAPITAL LETTER THETA u'\u03a9' # 0x00ea -> GREEK CAPITAL LETTER OMEGA u'\u03b4' # 0x00eb -> GREEK SMALL LETTER DELTA u'\u221e' # 0x00ec -> INFINITY u'\u03c6' # 0x00ed -> GREEK SMALL LETTER PHI u'\u03b5' # 0x00ee -> GREEK SMALL LETTER EPSILON u'\u2229' # 0x00ef -> INTERSECTION u'\u2261' # 0x00f0 -> IDENTICAL TO u'\xb1' # 0x00f1 -> PLUS-MINUS SIGN u'\u2265' # 0x00f2 -> GREATER-THAN OR EQUAL TO u'\u2264' # 0x00f3 -> LESS-THAN OR EQUAL TO u'\u2320' # 0x00f4 -> TOP HALF INTEGRAL u'\u2321' # 0x00f5 -> BOTTOM HALF INTEGRAL u'\xf7' # 0x00f6 -> DIVISION SIGN u'\u2248' # 0x00f7 -> ALMOST EQUAL TO u'\xb0' # 0x00f8 -> DEGREE SIGN u'\u2219' # 0x00f9 -> BULLET OPERATOR u'\xb7' # 0x00fa -> MIDDLE DOT u'\u221a' # 0x00fb -> SQUARE ROOT u'\u207f' # 0x00fc -> SUPERSCRIPT LATIN SMALL LETTER N u'\xb2' # 0x00fd -> SUPERSCRIPT TWO u'\u25a0' # 0x00fe -> BLACK SQUARE u'\xa0' # 0x00ff -> NO-BREAK SPACE ) ### Encoding Map encoding_map = { 0x0000: 0x0000, # NULL 0x0001: 0x0001, # START OF HEADING 0x0002: 0x0002, # START OF TEXT 0x0003: 0x0003, # END OF TEXT 0x0004: 0x0004, # END OF TRANSMISSION 0x0005: 0x0005, # ENQUIRY 0x0006: 0x0006, # ACKNOWLEDGE 0x0007: 0x0007, # BELL 0x0008: 0x0008, # BACKSPACE 0x0009: 0x0009, # HORIZONTAL TABULATION 0x000a: 0x000a, # LINE FEED 0x000b: 0x000b, # VERTICAL TABULATION 0x000c: 0x000c, # FORM FEED 0x000d: 0x000d, # CARRIAGE RETURN 0x000e: 0x000e, # SHIFT OUT 0x000f: 0x000f, # SHIFT IN 0x0010: 0x0010, # DATA LINK ESCAPE 0x0011: 0x0011, # DEVICE CONTROL ONE 0x0012: 0x0012, # DEVICE CONTROL TWO 0x0013: 0x0013, # DEVICE CONTROL THREE 0x0014: 0x0014, # DEVICE CONTROL FOUR 0x0015: 0x0015, # NEGATIVE ACKNOWLEDGE 0x0016: 0x0016, # SYNCHRONOUS IDLE 0x0017: 0x0017, # END OF TRANSMISSION BLOCK 0x0018: 0x0018, # CANCEL 0x0019: 0x0019, # END OF MEDIUM 0x001a: 0x001a, # SUBSTITUTE 0x001b: 0x001b, # ESCAPE 0x001c: 0x001c, # FILE SEPARATOR 0x001d: 0x001d, # GROUP SEPARATOR 0x001e: 0x001e, # RECORD SEPARATOR 0x001f: 0x001f, # UNIT SEPARATOR 0x0020: 0x0020, # SPACE 0x0021: 0x0021, # EXCLAMATION MARK 0x0022: 0x0022, # QUOTATION MARK 0x0023: 0x0023, # NUMBER SIGN 0x0024: 0x0024, # DOLLAR SIGN 0x0025: 0x0025, # PERCENT SIGN 0x0026: 0x0026, # AMPERSAND 0x0027: 0x0027, # APOSTROPHE 0x0028: 0x0028, # LEFT PARENTHESIS 0x0029: 0x0029, # RIGHT PARENTHESIS 0x002a: 0x002a, # ASTERISK 0x002b: 0x002b, # PLUS SIGN 0x002c: 0x002c, # COMMA 0x002d: 0x002d, # HYPHEN-MINUS 0x002e: 0x002e, # FULL STOP 0x002f: 0x002f, # SOLIDUS 0x0030: 0x0030, # DIGIT ZERO 0x0031: 0x0031, # DIGIT ONE 0x0032: 0x0032, # DIGIT TWO 0x0033: 0x0033, # DIGIT THREE 0x0034: 0x0034, # DIGIT FOUR 0x0035: 0x0035, # DIGIT FIVE 0x0036: 0x0036, # DIGIT SIX 0x0037: 0x0037, # DIGIT SEVEN 0x0038: 0x0038, # DIGIT EIGHT 0x0039: 0x0039, # DIGIT NINE 0x003a: 0x003a, # COLON 0x003b: 0x003b, # SEMICOLON 0x003c: 0x003c, # LESS-THAN SIGN 0x003d: 0x003d, # EQUALS SIGN 0x003e: 0x003e, # GREATER-THAN SIGN 0x003f: 0x003f, # QUESTION MARK 0x0040: 0x0040, # COMMERCIAL AT 0x0041: 0x0041, # LATIN CAPITAL LETTER A 0x0042: 0x0042, # LATIN CAPITAL LETTER B 0x0043: 0x0043, # LATIN CAPITAL LETTER C 0x0044: 0x0044, # LATIN CAPITAL LETTER D 0x0045: 0x0045, # LATIN CAPITAL LETTER E 0x0046: 0x0046, # LATIN CAPITAL LETTER F 0x0047: 0x0047, # LATIN CAPITAL LETTER G 0x0048: 0x0048, # LATIN CAPITAL LETTER H 0x0049: 0x0049, # LATIN CAPITAL LETTER I 0x004a: 0x004a, # LATIN CAPITAL LETTER J 0x004b: 0x004b, # LATIN CAPITAL LETTER K 0x004c: 0x004c, # LATIN CAPITAL LETTER L 0x004d: 0x004d, # LATIN CAPITAL LETTER M 0x004e: 0x004e, # LATIN CAPITAL LETTER N 0x004f: 0x004f, # LATIN CAPITAL LETTER O 0x0050: 0x0050, # LATIN CAPITAL LETTER P 0x0051: 0x0051, # LATIN CAPITAL LETTER Q 0x0052: 0x0052, # LATIN CAPITAL LETTER R 0x0053: 0x0053, # LATIN CAPITAL LETTER S 0x0054: 0x0054, # LATIN CAPITAL LETTER T 0x0055: 0x0055, # LATIN CAPITAL LETTER U 0x0056: 0x0056, # LATIN CAPITAL LETTER V 0x0057: 0x0057, # LATIN CAPITAL LETTER W 0x0058: 0x0058, # LATIN CAPITAL LETTER X 0x0059: 0x0059, # LATIN CAPITAL LETTER Y 0x005a: 0x005a, # LATIN CAPITAL LETTER Z 0x005b: 0x005b, # LEFT SQUARE BRACKET 0x005c: 0x005c, # REVERSE SOLIDUS 0x005d: 0x005d, # RIGHT SQUARE BRACKET 0x005e: 0x005e, # CIRCUMFLEX ACCENT 0x005f: 0x005f, # LOW LINE 0x0060: 0x0060, # GRAVE ACCENT 0x0061: 0x0061, # LATIN SMALL LETTER A 0x0062: 0x0062, # LATIN SMALL LETTER B 0x0063: 0x0063, # LATIN SMALL LETTER C 0x0064: 0x0064, # LATIN SMALL LETTER D 0x0065: 0x0065, # LATIN SMALL LETTER E 0x0066: 0x0066, # LATIN SMALL LETTER F 0x0067: 0x0067, # LATIN SMALL LETTER G 0x0068: 0x0068, # LATIN SMALL LETTER H 0x0069: 0x0069, # LATIN SMALL LETTER I 0x006a: 0x006a, # LATIN SMALL LETTER J 0x006b: 0x006b, # LATIN SMALL LETTER K 0x006c: 0x006c, # LATIN SMALL LETTER L 0x006d: 0x006d, # LATIN SMALL LETTER M 0x006e: 0x006e, # LATIN SMALL LETTER N 0x006f: 0x006f, # LATIN SMALL LETTER O 0x0070: 0x0070, # LATIN SMALL LETTER P 0x0071: 0x0071, # LATIN SMALL LETTER Q 0x0072: 0x0072, # LATIN SMALL LETTER R 0x0073: 0x0073, # LATIN SMALL LETTER S 0x0074: 0x0074, # LATIN SMALL LETTER T 0x0075: 0x0075, # LATIN SMALL LETTER U 0x0076: 0x0076, # LATIN SMALL LETTER V 0x0077: 0x0077, # LATIN SMALL LETTER W 0x0078: 0x0078, # LATIN SMALL LETTER X 0x0079: 0x0079, # LATIN SMALL LETTER Y 0x007a: 0x007a, # LATIN SMALL LETTER Z 0x007b: 0x007b, # LEFT CURLY BRACKET 0x007c: 0x007c, # VERTICAL LINE 0x007d: 0x007d, # RIGHT CURLY BRACKET 0x007e: 0x007e, # TILDE 0x007f: 0x007f, # DELETE 0x00a0: 0x00ff, # NO-BREAK SPACE 0x00a1: 0x00ad, # INVERTED EXCLAMATION MARK 0x00a3: 0x009c, # POUND SIGN 0x00ab: 0x00ae, # LEFT-POINTING DOUBLE ANGLE QUOTATION MARK 0x00ac: 0x00aa, # NOT SIGN 0x00b0: 0x00f8, # DEGREE SIGN 0x00b1: 0x00f1, # PLUS-MINUS SIGN 0x00b2: 0x00fd, # SUPERSCRIPT TWO 0x00b5: 0x00e6, # MICRO SIGN 0x00b7: 0x00fa, # MIDDLE DOT 0x00bb: 0x00af, # RIGHT-POINTING DOUBLE ANGLE QUOTATION MARK 0x00bc: 0x00ac, # VULGAR FRACTION ONE QUARTER 0x00bd: 0x00ab, # VULGAR FRACTION ONE HALF 0x00bf: 0x00a8, # INVERTED QUESTION MARK 0x00c1: 0x00a4, # LATIN CAPITAL LETTER A WITH ACUTE 0x00c4: 0x008e, # LATIN CAPITAL LETTER A WITH DIAERESIS 0x00c5: 0x008f, # LATIN CAPITAL LETTER A WITH RING ABOVE 0x00c6: 0x0092, # LATIN CAPITAL LIGATURE AE 0x00c7: 0x0080, # LATIN CAPITAL LETTER C WITH CEDILLA 0x00c9: 0x0090, # LATIN CAPITAL LETTER E WITH ACUTE 0x00cd: 0x00a5, # LATIN CAPITAL LETTER I WITH ACUTE 0x00d0: 0x008b, # LATIN CAPITAL LETTER ETH 0x00d3: 0x00a6, # LATIN CAPITAL LETTER O WITH ACUTE 0x00d6: 0x0099, # LATIN CAPITAL LETTER O WITH DIAERESIS 0x00d8: 0x009d, # LATIN CAPITAL LETTER O WITH STROKE 0x00da: 0x00a7, # LATIN CAPITAL LETTER U WITH ACUTE 0x00dc: 0x009a, # LATIN CAPITAL LETTER U WITH DIAERESIS 0x00dd: 0x0097, # LATIN CAPITAL LETTER Y WITH ACUTE 0x00de: 0x008d, # LATIN CAPITAL LETTER THORN 0x00df: 0x00e1, # LATIN SMALL LETTER SHARP S 0x00e0: 0x0085, # LATIN SMALL LETTER A WITH GRAVE 0x00e1: 0x00a0, # LATIN SMALL LETTER A WITH ACUTE 0x00e2: 0x0083, # LATIN SMALL LETTER A WITH CIRCUMFLEX 0x00e4: 0x0084, # LATIN SMALL LETTER A WITH DIAERESIS 0x00e5: 0x0086, # LATIN SMALL LETTER A WITH RING ABOVE 0x00e6: 0x0091, # LATIN SMALL LIGATURE AE 0x00e7: 0x0087, # LATIN SMALL LETTER C WITH CEDILLA 0x00e8: 0x008a, # LATIN SMALL LETTER E WITH GRAVE 0x00e9: 0x0082, # LATIN SMALL LETTER E WITH ACUTE 0x00ea: 0x0088, # LATIN SMALL LETTER E WITH CIRCUMFLEX 0x00eb: 0x0089, # LATIN SMALL LETTER E WITH DIAERESIS 0x00ed: 0x00a1, # LATIN SMALL LETTER I WITH ACUTE 0x00f0: 0x008c, # LATIN SMALL LETTER ETH 0x00f3: 0x00a2, # LATIN SMALL LETTER O WITH ACUTE 0x00f4: 0x0093, # LATIN SMALL LETTER O WITH CIRCUMFLEX 0x00f6: 0x0094, # LATIN SMALL LETTER O WITH DIAERESIS 0x00f7: 0x00f6, # DIVISION SIGN 0x00f8: 0x009b, # LATIN SMALL LETTER O WITH STROKE 0x00fa: 0x00a3, # LATIN SMALL LETTER U WITH ACUTE 0x00fb: 0x0096, # LATIN SMALL LETTER U WITH CIRCUMFLEX 0x00fc: 0x0081, # LATIN SMALL LETTER U WITH DIAERESIS 0x00fd: 0x0098, # LATIN SMALL LETTER Y WITH ACUTE 0x00fe: 0x0095, # LATIN SMALL LETTER THORN 0x0192: 0x009f, # LATIN SMALL LETTER F WITH HOOK 0x0393: 0x00e2, # GREEK CAPITAL LETTER GAMMA 0x0398: 0x00e9, # GREEK CAPITAL LETTER THETA 0x03a3: 0x00e4, # GREEK CAPITAL LETTER SIGMA 0x03a6: 0x00e8, # GREEK CAPITAL LETTER PHI 0x03a9: 0x00ea, # GREEK CAPITAL LETTER OMEGA 0x03b1: 0x00e0, # GREEK SMALL LETTER ALPHA 0x03b4: 0x00eb, # GREEK SMALL LETTER DELTA 0x03b5: 0x00ee, # GREEK SMALL LETTER EPSILON 0x03c0: 0x00e3, # GREEK SMALL LETTER PI 0x03c3: 0x00e5, # GREEK SMALL LETTER SIGMA 0x03c4: 0x00e7, # GREEK SMALL LETTER TAU 0x03c6: 0x00ed, # GREEK SMALL LETTER PHI 0x207f: 0x00fc, # SUPERSCRIPT LATIN SMALL LETTER N 0x20a7: 0x009e, # PESETA SIGN 0x2219: 0x00f9, # BULLET OPERATOR 0x221a: 0x00fb, # SQUARE ROOT 0x221e: 0x00ec, # INFINITY 0x2229: 0x00ef, # INTERSECTION 0x2248: 0x00f7, # ALMOST EQUAL TO 0x2261: 0x00f0, # IDENTICAL TO 0x2264: 0x00f3, # LESS-THAN OR EQUAL TO 0x2265: 0x00f2, # GREATER-THAN OR EQUAL TO 0x2310: 0x00a9, # REVERSED NOT SIGN 0x2320: 0x00f4, # TOP HALF INTEGRAL 0x2321: 0x00f5, # BOTTOM HALF INTEGRAL 0x2500: 0x00c4, # BOX DRAWINGS LIGHT HORIZONTAL 0x2502: 0x00b3, # BOX DRAWINGS LIGHT VERTICAL 0x250c: 0x00da, # BOX DRAWINGS LIGHT DOWN AND RIGHT 0x2510: 0x00bf, # BOX DRAWINGS LIGHT DOWN AND LEFT 0x2514: 0x00c0, # BOX DRAWINGS LIGHT UP AND RIGHT 0x2518: 0x00d9, # BOX DRAWINGS LIGHT UP AND LEFT 0x251c: 0x00c3, # BOX DRAWINGS LIGHT VERTICAL AND RIGHT 0x2524: 0x00b4, # BOX DRAWINGS LIGHT VERTICAL AND LEFT 0x252c: 0x00c2, # BOX DRAWINGS LIGHT DOWN AND HORIZONTAL 0x2534: 0x00c1, # BOX DRAWINGS LIGHT UP AND HORIZONTAL 0x253c: 0x00c5, # BOX DRAWINGS LIGHT VERTICAL AND HORIZONTAL 0x2550: 0x00cd, # BOX DRAWINGS DOUBLE HORIZONTAL 0x2551: 0x00ba, # BOX DRAWINGS DOUBLE VERTICAL 0x2552: 0x00d5, # BOX DRAWINGS DOWN SINGLE AND RIGHT DOUBLE 0x2553: 0x00d6, # BOX DRAWINGS DOWN DOUBLE AND RIGHT SINGLE 0x2554: 0x00c9, # BOX DRAWINGS DOUBLE DOWN AND RIGHT 0x2555: 0x00b8, # BOX DRAWINGS DOWN SINGLE AND LEFT DOUBLE 0x2556: 0x00b7, # BOX DRAWINGS DOWN DOUBLE AND LEFT SINGLE 0x2557: 0x00bb, # BOX DRAWINGS DOUBLE DOWN AND LEFT 0x2558: 0x00d4, # BOX DRAWINGS UP SINGLE AND RIGHT DOUBLE 0x2559: 0x00d3, # BOX DRAWINGS UP DOUBLE AND RIGHT SINGLE 0x255a: 0x00c8, # BOX DRAWINGS DOUBLE UP AND RIGHT 0x255b: 0x00be, # BOX DRAWINGS UP SINGLE AND LEFT DOUBLE 0x255c: 0x00bd, # BOX DRAWINGS UP DOUBLE AND LEFT SINGLE 0x255d: 0x00bc, # BOX DRAWINGS DOUBLE UP AND LEFT 0x255e: 0x00c6, # BOX DRAWINGS VERTICAL SINGLE AND RIGHT DOUBLE 0x255f: 0x00c7, # BOX DRAWINGS VERTICAL DOUBLE AND RIGHT SINGLE 0x2560: 0x00cc, # BOX DRAWINGS DOUBLE VERTICAL AND RIGHT 0x2561: 0x00b5, # BOX DRAWINGS VERTICAL SINGLE AND LEFT DOUBLE 0x2562: 0x00b6, # BOX DRAWINGS VERTICAL DOUBLE AND LEFT SINGLE 0x2563: 0x00b9, # BOX DRAWINGS DOUBLE VERTICAL AND LEFT 0x2564: 0x00d1, # BOX DRAWINGS DOWN SINGLE AND HORIZONTAL DOUBLE 0x2565: 0x00d2, # BOX DRAWINGS DOWN DOUBLE AND HORIZONTAL SINGLE 0x2566: 0x00cb, # BOX DRAWINGS DOUBLE DOWN AND HORIZONTAL 0x2567: 0x00cf, # BOX DRAWINGS UP SINGLE AND HORIZONTAL DOUBLE 0x2568: 0x00d0, # BOX DRAWINGS UP DOUBLE AND HORIZONTAL SINGLE 0x2569: 0x00ca, # BOX DRAWINGS DOUBLE UP AND HORIZONTAL 0x256a: 0x00d8, # BOX DRAWINGS VERTICAL SINGLE AND HORIZONTAL DOUBLE 0x256b: 0x00d7, # BOX DRAWINGS VERTICAL DOUBLE AND HORIZONTAL SINGLE 0x256c: 0x00ce, # BOX DRAWINGS DOUBLE VERTICAL AND HORIZONTAL 0x2580: 0x00df, # UPPER HALF BLOCK 0x2584: 0x00dc, # LOWER HALF BLOCK 0x2588: 0x00db, # FULL BLOCK 0x258c: 0x00dd, # LEFT HALF BLOCK 0x2590: 0x00de, # RIGHT HALF BLOCK 0x2591: 0x00b0, # LIGHT SHADE 0x2592: 0x00b1, # MEDIUM SHADE 0x2593: 0x00b2, # DARK SHADE 0x25a0: 0x00fe, # BLACK SQUARE }
lgpl-2.1
jgrocha/QGIS
tests/src/python/test_qgsdatumtransforms.py
12
21240
# -*- coding: utf-8 -*- """QGIS Unit tests for QgsDatumTransforms. .. note:: This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. """ __author__ = 'Nyall Dawson' __date__ = '2019-05-25' __copyright__ = 'Copyright 2019, The QGIS Project' from qgis.core import ( QgsProjUtils, QgsCoordinateReferenceSystem, QgsDatumTransform ) from qgis.testing import (start_app, unittest, ) from utilities import unitTestDataPath start_app() TEST_DATA_DIR = unitTestDataPath() class TestPyQgsDatumTransform(unittest.TestCase): def testOperations(self): ops = QgsDatumTransform.operations(QgsCoordinateReferenceSystem(), QgsCoordinateReferenceSystem()) self.assertEqual(ops, []) ops = QgsDatumTransform.operations(QgsCoordinateReferenceSystem('EPSG:3111'), QgsCoordinateReferenceSystem()) self.assertEqual(ops, []) ops = QgsDatumTransform.operations(QgsCoordinateReferenceSystem(), QgsCoordinateReferenceSystem('EPSG:3111')) self.assertEqual(ops, []) ops = QgsDatumTransform.operations(QgsCoordinateReferenceSystem('EPSG:3111'), QgsCoordinateReferenceSystem('EPSG:3111')) self.assertEqual(len(ops), 1) self.assertTrue(ops[0].name) self.assertEqual(ops[0].proj, '+proj=noop') self.assertEqual(ops[0].accuracy, 0.0) self.assertTrue(ops[0].isAvailable) ops = QgsDatumTransform.operations(QgsCoordinateReferenceSystem('EPSG:3111'), QgsCoordinateReferenceSystem('EPSG:4283')) self.assertEqual(len(ops), 1) self.assertTrue(ops[0].name) self.assertEqual(ops[0].proj, '+proj=pipeline +step +inv +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80 +step +proj=unitconvert +xy_in=rad +xy_out=deg') self.assertEqual(ops[0].accuracy, -1.0) self.assertTrue(ops[0].isAvailable) ops = QgsDatumTransform.operations(QgsCoordinateReferenceSystem('EPSG:3111'), QgsCoordinateReferenceSystem('EPSG:28355')) self.assertEqual(len(ops), 1) self.assertTrue(ops[0].name) self.assertEqual(ops[0].proj, '+proj=pipeline +step +inv +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80 +step +proj=utm +zone=55 +south +ellps=GRS80') self.assertEqual(ops[0].accuracy, 0.0) self.assertTrue(ops[0].isAvailable) # uses a grid file ops = QgsDatumTransform.operations(QgsCoordinateReferenceSystem('EPSG:4283'), QgsCoordinateReferenceSystem('EPSG:7844')) self.assertGreaterEqual(len(ops), 5) op1_index = [i for i in range(len(ops)) if ops[i].proj == '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=push +v_3 +step +proj=cart +ellps=GRS80 +step +proj=helmert +x=0.06155 +y=-0.01087 +z=-0.04019 +rx=-0.0394924 +ry=-0.0327221 +rz=-0.0328979 +s=-0.009994 +convention=coordinate_frame +step +inv +proj=cart +ellps=GRS80 +step +proj=pop +v_3 +step +proj=unitconvert +xy_in=rad +xy_out=deg'][0] self.assertTrue(ops[op1_index].name) self.assertEqual(ops[op1_index].proj, '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=push +v_3 +step +proj=cart +ellps=GRS80 +step +proj=helmert +x=0.06155 +y=-0.01087 +z=-0.04019 +rx=-0.0394924 +ry=-0.0327221 +rz=-0.0328979 +s=-0.009994 +convention=coordinate_frame +step +inv +proj=cart +ellps=GRS80 +step +proj=pop +v_3 +step +proj=unitconvert +xy_in=rad +xy_out=deg') self.assertTrue(ops[op1_index].isAvailable) self.assertEqual(ops[op1_index].accuracy, 0.01) self.assertEqual(len(ops[op1_index].grids), 0) if QgsProjUtils.projVersionMajor() == 6: op2_index = [i for i in range(len(ops)) if ops[i].proj == '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=GDA94_GDA2020_conformal_and_distortion.gsb +step +proj=unitconvert +xy_in=rad +xy_out=deg'][0] else: op2_index = [i for i in range(len(ops)) if ops[ i].proj == '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=au_icsm_GDA94_GDA2020_conformal_and_distortion.tif +step +proj=unitconvert +xy_in=rad +xy_out=deg'][ 0] self.assertTrue(ops[op2_index].name) if QgsProjUtils.projVersionMajor() == 6: self.assertEqual(ops[op2_index].proj, '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=GDA94_GDA2020_conformal_and_distortion.gsb +step +proj=unitconvert +xy_in=rad +xy_out=deg') else: self.assertEqual(ops[op2_index].proj, '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=au_icsm_GDA94_GDA2020_conformal_and_distortion.tif +step +proj=unitconvert +xy_in=rad +xy_out=deg') self.assertEqual(ops[op2_index].accuracy, 0.05) self.assertEqual(len(ops[op2_index].grids), 1) if QgsProjUtils.projVersionMajor() == 6: self.assertEqual(ops[op2_index].grids[0].shortName, 'GDA94_GDA2020_conformal_and_distortion.gsb') else: self.assertEqual(ops[op2_index].grids[0].shortName, 'au_icsm_GDA94_GDA2020_conformal_and_distortion.tif') self.assertEqual(ops[op2_index].grids[0].fullName, '') if QgsProjUtils.projVersionMajor() == 6: self.assertTrue(ops[op2_index].grids[0].packageName) self.assertIn('http', ops[op2_index].grids[0].url) self.assertTrue(ops[op2_index].grids[0].directDownload) self.assertTrue(ops[op2_index].grids[0].openLicense) if QgsProjUtils.projVersionMajor() == 6: op3_index = [i for i in range(len(ops)) if ops[i].proj == '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=GDA94_GDA2020_conformal.gsb +step +proj=unitconvert +xy_in=rad +xy_out=deg'][0] else: op3_index = [i for i in range(len(ops)) if ops[ i].proj == '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=au_icsm_GDA94_GDA2020_conformal.tif +step +proj=unitconvert +xy_in=rad +xy_out=deg'][ 0] self.assertTrue(ops[op3_index].name) if QgsProjUtils.projVersionMajor() == 6: self.assertEqual(ops[op3_index].proj, '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=GDA94_GDA2020_conformal.gsb +step +proj=unitconvert +xy_in=rad +xy_out=deg') else: self.assertEqual(ops[op3_index].proj, '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=au_icsm_GDA94_GDA2020_conformal.tif +step +proj=unitconvert +xy_in=rad +xy_out=deg') self.assertEqual(ops[op3_index].accuracy, 0.05) self.assertEqual(len(ops[op3_index].grids), 1) if QgsProjUtils.projVersionMajor() == 6: self.assertEqual(ops[op3_index].grids[0].shortName, 'GDA94_GDA2020_conformal.gsb') else: self.assertEqual(ops[op3_index].grids[0].shortName, 'au_icsm_GDA94_GDA2020_conformal.tif') self.assertEqual(ops[op3_index].grids[0].fullName, '') if QgsProjUtils.projVersionMajor() == 6: self.assertTrue(ops[op3_index].grids[0].packageName) self.assertIn('http', ops[op3_index].grids[0].url) self.assertTrue(ops[op3_index].grids[0].directDownload) self.assertTrue(ops[op3_index].grids[0].openLicense) if QgsProjUtils.projVersionMajor() == 6: op4_index = [i for i in range(len(ops)) if ops[i].proj == '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=GDA94_GDA2020_conformal_cocos_island.gsb +step +proj=unitconvert +xy_in=rad +xy_out=deg'][0] else: op4_index = [i for i in range(len(ops)) if ops[ i].proj == '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=au_icsm_GDA94_GDA2020_conformal_cocos_island.tif +step +proj=unitconvert +xy_in=rad +xy_out=deg'][ 0] self.assertTrue(ops[op4_index].name) if QgsProjUtils.projVersionMajor() == 6: self.assertEqual(ops[op4_index].proj, '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=GDA94_GDA2020_conformal_cocos_island.gsb +step +proj=unitconvert +xy_in=rad +xy_out=deg') else: self.assertEqual(ops[op4_index].proj, '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=au_icsm_GDA94_GDA2020_conformal_cocos_island.tif +step +proj=unitconvert +xy_in=rad +xy_out=deg') self.assertEqual(ops[op4_index].accuracy, 0.05) self.assertEqual(len(ops[op4_index].grids), 1) if QgsProjUtils.projVersionMajor() == 6: self.assertEqual(ops[op4_index].grids[0].shortName, 'GDA94_GDA2020_conformal_cocos_island.gsb') else: self.assertEqual(ops[op4_index].grids[0].shortName, 'au_icsm_GDA94_GDA2020_conformal_cocos_island.tif') self.assertEqual(ops[op4_index].grids[0].fullName, '') if QgsProjUtils.projVersionMajor() == 6: self.assertTrue(ops[op4_index].grids[0].packageName) self.assertIn('http', ops[op4_index].grids[0].url) if QgsProjUtils.projVersionMajor() == 6: op5_index = [i for i in range(len(ops)) if ops[i].proj == '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=GDA94_GDA2020_conformal_christmas_island.gsb +step +proj=unitconvert +xy_in=rad +xy_out=deg'][0] else: op5_index = [i for i in range(len(ops)) if ops[ i].proj == '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=au_icsm_GDA94_GDA2020_conformal_christmas_island.tif +step +proj=unitconvert +xy_in=rad +xy_out=deg'][ 0] self.assertTrue(ops[op5_index].name) if QgsProjUtils.projVersionMajor() == 6: self.assertEqual(ops[op5_index].proj, '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=GDA94_GDA2020_conformal_christmas_island.gsb +step +proj=unitconvert +xy_in=rad +xy_out=deg') else: self.assertEqual(ops[op5_index].proj, '+proj=pipeline +step +proj=unitconvert +xy_in=deg +xy_out=rad +step +proj=hgridshift +grids=au_icsm_GDA94_GDA2020_conformal_christmas_island.tif +step +proj=unitconvert +xy_in=rad +xy_out=deg') self.assertEqual(ops[op5_index].accuracy, 0.05) self.assertEqual(len(ops[op5_index].grids), 1) if QgsProjUtils.projVersionMajor() == 6: self.assertEqual(ops[op5_index].grids[0].shortName, 'GDA94_GDA2020_conformal_christmas_island.gsb') else: self.assertEqual(ops[op5_index].grids[0].shortName, 'au_icsm_GDA94_GDA2020_conformal_christmas_island.tif') self.assertEqual(ops[op5_index].grids[0].fullName, '') if QgsProjUtils.projVersionMajor() == 6: self.assertTrue(ops[op5_index].grids[0].packageName) self.assertIn('http', ops[op5_index].grids[0].url) # uses a pivot datum (technically a proj test, but this will help me sleep at night ;) ops = QgsDatumTransform.operations(QgsCoordinateReferenceSystem('EPSG:3111'), QgsCoordinateReferenceSystem('EPSG:7899')) self.assertGreaterEqual(len(ops), 3) op1_index = [i for i in range(len(ops)) if ops[i].proj == '+proj=pipeline +step +inv +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80 +step +proj=push +v_3 +step +proj=cart +ellps=GRS80 +step +proj=helmert +x=0.06155 +y=-0.01087 +z=-0.04019 +rx=-0.0394924 +ry=-0.0327221 +rz=-0.0328979 +s=-0.009994 +convention=coordinate_frame +step +inv +proj=cart +ellps=GRS80 +step +proj=pop +v_3 +step +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80'][0] self.assertTrue(ops[op1_index].name) self.assertEqual(ops[op1_index].proj, '+proj=pipeline +step +inv +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80 +step +proj=push +v_3 +step +proj=cart +ellps=GRS80 +step +proj=helmert +x=0.06155 +y=-0.01087 +z=-0.04019 +rx=-0.0394924 +ry=-0.0327221 +rz=-0.0328979 +s=-0.009994 +convention=coordinate_frame +step +inv +proj=cart +ellps=GRS80 +step +proj=pop +v_3 +step +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80') self.assertTrue(ops[op1_index].isAvailable) self.assertEqual(ops[op1_index].accuracy, 0.01) self.assertEqual(len(ops[op1_index].grids), 0) if QgsProjUtils.projVersionMajor() == 6: op2_index = [i for i in range(len(ops)) if ops[i].proj == '+proj=pipeline +step +inv +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80 +step +proj=hgridshift +grids=GDA94_GDA2020_conformal_and_distortion.gsb +step +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80'][0] else: op2_index = [i for i in range(len(ops)) if ops[ i].proj == '+proj=pipeline +step +inv +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80 +step +proj=hgridshift +grids=au_icsm_GDA94_GDA2020_conformal_and_distortion.tif +step +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80'][ 0] self.assertTrue(ops[op2_index].name) if QgsProjUtils.projVersionMajor() == 6: self.assertEqual(ops[op2_index].proj, '+proj=pipeline +step +inv +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80 +step +proj=hgridshift +grids=GDA94_GDA2020_conformal_and_distortion.gsb +step +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80') else: self.assertEqual(ops[op2_index].proj, '+proj=pipeline +step +inv +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80 +step +proj=hgridshift +grids=au_icsm_GDA94_GDA2020_conformal_and_distortion.tif +step +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80') self.assertEqual(ops[op2_index].accuracy, 0.05) self.assertEqual(len(ops[op2_index].grids), 1) if QgsProjUtils.projVersionMajor() == 6: self.assertEqual(ops[op2_index].grids[0].shortName, 'GDA94_GDA2020_conformal_and_distortion.gsb') else: self.assertEqual(ops[op2_index].grids[0].shortName, 'au_icsm_GDA94_GDA2020_conformal_and_distortion.tif') self.assertEqual(ops[op2_index].grids[0].fullName, '') if QgsProjUtils.projVersionMajor() == 6: self.assertTrue(ops[op2_index].grids[0].packageName) self.assertIn('http', ops[op2_index].grids[0].url) self.assertTrue(ops[op2_index].grids[0].directDownload) self.assertTrue(ops[op2_index].grids[0].openLicense) if QgsProjUtils.projVersionMajor() == 6: op3_index = [i for i in range(len(ops)) if ops[i].proj == '+proj=pipeline +step +inv +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80 +step +proj=hgridshift +grids=GDA94_GDA2020_conformal.gsb +step +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80'][0] else: op3_index = [i for i in range(len(ops)) if ops[ i].proj == '+proj=pipeline +step +inv +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80 +step +proj=hgridshift +grids=au_icsm_GDA94_GDA2020_conformal.tif +step +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80'][ 0] self.assertTrue(ops[op3_index].name) if QgsProjUtils.projVersionMajor() == 6: self.assertEqual(ops[op3_index].proj, '+proj=pipeline +step +inv +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80 +step +proj=hgridshift +grids=GDA94_GDA2020_conformal.gsb +step +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80') else: self.assertEqual(ops[op3_index].proj, '+proj=pipeline +step +inv +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80 +step +proj=hgridshift +grids=au_icsm_GDA94_GDA2020_conformal.tif +step +proj=lcc +lat_0=-37 +lon_0=145 +lat_1=-36 +lat_2=-38 +x_0=2500000 +y_0=2500000 +ellps=GRS80') self.assertEqual(ops[op3_index].accuracy, 0.05) self.assertEqual(len(ops[op3_index].grids), 1) if QgsProjUtils.projVersionMajor() == 6: self.assertEqual(ops[op3_index].grids[0].shortName, 'GDA94_GDA2020_conformal.gsb') else: self.assertEqual(ops[op3_index].grids[0].shortName, 'au_icsm_GDA94_GDA2020_conformal.tif') self.assertEqual(ops[op3_index].grids[0].fullName, '') if QgsProjUtils.projVersionMajor() == 6: self.assertTrue(ops[op3_index].grids[0].packageName) self.assertIn('http', ops[op3_index].grids[0].url) self.assertTrue(ops[op3_index].grids[0].directDownload) self.assertTrue(ops[op3_index].grids[0].openLicense) @unittest.skipIf(QgsProjUtils.projVersionMajor() < 7, 'Not a proj >= 7 build') def testNoLasLos(self): """ Test that operations which rely on an NADCON5 grid shift file (which are unsupported by Proj... at time of writing !) are not returned """ ops = QgsDatumTransform.operations(QgsCoordinateReferenceSystem('EPSG:4138'), QgsCoordinateReferenceSystem('EPSG:4269')) self.assertEqual(len(ops), 2) self.assertTrue(ops[0].name) self.assertTrue(ops[0].proj) self.assertTrue(ops[1].name) self.assertTrue(ops[1].proj) @unittest.skipIf(QgsProjUtils.projVersionMajor() < 8, 'Not a proj >= 8 build') def testDatumEnsembles(self): """ Test datum ensemble details """ crs = QgsCoordinateReferenceSystem() self.assertFalse(crs.datumEnsemble().isValid()) self.assertEqual(str(crs.datumEnsemble()), '<QgsDatumEnsemble: invalid>') crs = QgsCoordinateReferenceSystem('EPSG:3111') self.assertFalse(crs.datumEnsemble().isValid()) crs = QgsCoordinateReferenceSystem('EPSG:3857') ensemble = crs.datumEnsemble() self.assertTrue(ensemble.isValid()) self.assertEqual(ensemble.name(), 'World Geodetic System 1984 ensemble') self.assertEqual(ensemble.authority(), 'EPSG') self.assertEqual(ensemble.code(), '6326') self.assertEqual(ensemble.scope(), 'Satellite navigation.') self.assertEqual(ensemble.accuracy(), 2.0) self.assertEqual(str(ensemble), '<QgsDatumEnsemble: World Geodetic System 1984 ensemble (EPSG:6326)>') self.assertEqual(ensemble.members()[0].name(), 'World Geodetic System 1984 (Transit)') self.assertEqual(ensemble.members()[0].authority(), 'EPSG') self.assertEqual(ensemble.members()[0].code(), '1166') self.assertEqual(ensemble.members()[0].scope(), 'Geodesy. Navigation and positioning using GPS satellite system.') self.assertEqual(str(ensemble.members()[0]), '<QgsDatumEnsembleMember: World Geodetic System 1984 (Transit) (EPSG:1166)>') self.assertEqual(ensemble.members()[1].name(), 'World Geodetic System 1984 (G730)') self.assertEqual(ensemble.members()[1].authority(), 'EPSG') self.assertEqual(ensemble.members()[1].code(), '1152') self.assertEqual(ensemble.members()[1].scope(), 'Geodesy. Navigation and positioning using GPS satellite system.') crs = QgsCoordinateReferenceSystem('EPSG:4936') ensemble = crs.datumEnsemble() self.assertTrue(ensemble.isValid()) self.assertEqual(ensemble.name(), 'European Terrestrial Reference System 1989 ensemble') self.assertEqual(ensemble.authority(), 'EPSG') self.assertEqual(ensemble.code(), '6258') self.assertEqual(ensemble.scope(), 'Spatial referencing.') self.assertEqual(ensemble.accuracy(), 0.1) self.assertTrue(ensemble.members()) if __name__ == '__main__': unittest.main()
gpl-2.0
jschleic/waymarked-trails-site
maps/riding.py
2
1843
# This file is part of the Waymarked Trails Map Project # Copyright (C) 2015 Sarah Hoffmann # # This is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License # as published by the Free Software Foundation; either version 2 # of the License, or any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. """ Configuration for the Horse riding map. """ from db.configs import * from os.path import join as os_join from config.defaults import MEDIA_ROOT MAPTYPE = 'routes' ROUTEDB = RouteDBConfig() ROUTEDB.schema = 'riding' ROUTEDB.relation_subset = """ tags ? 'route' and tags->'type' IN ('route', 'superroute') AND 'horse' = any(regexp_split_to_array(tags->'route', ';')) AND NOT (tags ? 'state' AND tags->'state' = 'proposed')""" ROUTES = RouteTableConfig() ROUTES.network_map = { 'nhn': 10, 'rhn': 20, 'lhn': 30, 'nwn': 10, 'rwn': 20, 'lwn': 30, 'nwn:kct' : 10, 'ncn': 10, 'rcn': 20, 'lcn': 30, } ROUTES.symbols = ( 'OSMCSymbol', 'TextSymbol', 'ColorBox') DEFSTYLE = RouteStyleTableConfig() GUIDEPOSTS = GuidePostConfig() GUIDEPOSTS.subtype = 'horse' GUIDEPOSTS.require_subtype = True NETWORKNODES = NetworkNodeConfig() NETWORKNODES.node_tag = 'rhn_ref' SYMBOLS = ShieldConfiguration() SYMBOLS.symbol_outdir = os_join(MEDIA_ROOT, 'symbols/riding')
gpl-3.0
shaunbrady/boto
boto/sdb/db/manager/xmlmanager.py
153
18612
# Copyright (c) 2006-2008 Mitch Garnaat http://garnaat.org/ # # Permission is hereby granted, free of charge, to any person obtaining a # copy of this software and associated documentation files (the # "Software"), to deal in the Software without restriction, including # without limitation the rights to use, copy, modify, merge, publish, dis- # tribute, sublicense, and/or sell copies of the Software, and to permit # persons to whom the Software is furnished to do so, subject to the fol- # lowing conditions: # # The above copyright notice and this permission notice shall be included # in all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS # OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABIL- # ITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT # SHALL THE AUTHOR BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, # WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS # IN THE SOFTWARE. import boto from boto.utils import find_class, Password from boto.sdb.db.key import Key from boto.sdb.db.model import Model from boto.compat import six, encodebytes from datetime import datetime from xml.dom.minidom import getDOMImplementation, parse, parseString, Node ISO8601 = '%Y-%m-%dT%H:%M:%SZ' class XMLConverter(object): """ Responsible for converting base Python types to format compatible with underlying database. For SimpleDB, that means everything needs to be converted to a string when stored in SimpleDB and from a string when retrieved. To convert a value, pass it to the encode or decode method. The encode method will take a Python native value and convert to DB format. The decode method will take a DB format value and convert it to Python native format. To find the appropriate method to call, the generic encode/decode methods will look for the type-specific method by searching for a method called "encode_<type name>" or "decode_<type name>". """ def __init__(self, manager): self.manager = manager self.type_map = { bool : (self.encode_bool, self.decode_bool), int : (self.encode_int, self.decode_int), Model : (self.encode_reference, self.decode_reference), Key : (self.encode_reference, self.decode_reference), Password : (self.encode_password, self.decode_password), datetime : (self.encode_datetime, self.decode_datetime)} if six.PY2: self.type_map[long] = (self.encode_long, self.decode_long) def get_text_value(self, parent_node): value = '' for node in parent_node.childNodes: if node.nodeType == node.TEXT_NODE: value += node.data return value def encode(self, item_type, value): if item_type in self.type_map: encode = self.type_map[item_type][0] return encode(value) return value def decode(self, item_type, value): if item_type in self.type_map: decode = self.type_map[item_type][1] return decode(value) else: value = self.get_text_value(value) return value def encode_prop(self, prop, value): if isinstance(value, list): if hasattr(prop, 'item_type'): new_value = [] for v in value: item_type = getattr(prop, "item_type") if Model in item_type.mro(): item_type = Model new_value.append(self.encode(item_type, v)) return new_value else: return value else: return self.encode(prop.data_type, value) def decode_prop(self, prop, value): if prop.data_type == list: if hasattr(prop, 'item_type'): item_type = getattr(prop, "item_type") if Model in item_type.mro(): item_type = Model values = [] for item_node in value.getElementsByTagName('item'): value = self.decode(item_type, item_node) values.append(value) return values else: return self.get_text_value(value) else: return self.decode(prop.data_type, value) def encode_int(self, value): value = int(value) return '%d' % value def decode_int(self, value): value = self.get_text_value(value) if value: value = int(value) else: value = None return value def encode_long(self, value): value = long(value) return '%d' % value def decode_long(self, value): value = self.get_text_value(value) return long(value) def encode_bool(self, value): if value == True: return 'true' else: return 'false' def decode_bool(self, value): value = self.get_text_value(value) if value.lower() == 'true': return True else: return False def encode_datetime(self, value): return value.strftime(ISO8601) def decode_datetime(self, value): value = self.get_text_value(value) try: return datetime.strptime(value, ISO8601) except: return None def encode_reference(self, value): if isinstance(value, six.string_types): return value if value is None: return '' else: val_node = self.manager.doc.createElement("object") val_node.setAttribute('id', value.id) val_node.setAttribute('class', '%s.%s' % (value.__class__.__module__, value.__class__.__name__)) return val_node def decode_reference(self, value): if not value: return None try: value = value.childNodes[0] class_name = value.getAttribute("class") id = value.getAttribute("id") cls = find_class(class_name) return cls.get_by_ids(id) except: return None def encode_password(self, value): if value and len(value) > 0: return str(value) else: return None def decode_password(self, value): value = self.get_text_value(value) return Password(value) class XMLManager(object): def __init__(self, cls, db_name, db_user, db_passwd, db_host, db_port, db_table, ddl_dir, enable_ssl): self.cls = cls if not db_name: db_name = cls.__name__.lower() self.db_name = db_name self.db_user = db_user self.db_passwd = db_passwd self.db_host = db_host self.db_port = db_port self.db_table = db_table self.ddl_dir = ddl_dir self.s3 = None self.converter = XMLConverter(self) self.impl = getDOMImplementation() self.doc = self.impl.createDocument(None, 'objects', None) self.connection = None self.enable_ssl = enable_ssl self.auth_header = None if self.db_user: base64string = encodebytes('%s:%s' % (self.db_user, self.db_passwd))[:-1] authheader = "Basic %s" % base64string self.auth_header = authheader def _connect(self): if self.db_host: if self.enable_ssl: from httplib import HTTPSConnection as Connection else: from httplib import HTTPConnection as Connection self.connection = Connection(self.db_host, self.db_port) def _make_request(self, method, url, post_data=None, body=None): """ Make a request on this connection """ if not self.connection: self._connect() try: self.connection.close() except: pass self.connection.connect() headers = {} if self.auth_header: headers["Authorization"] = self.auth_header self.connection.request(method, url, body, headers) resp = self.connection.getresponse() return resp def new_doc(self): return self.impl.createDocument(None, 'objects', None) def _object_lister(self, cls, doc): for obj_node in doc.getElementsByTagName('object'): if not cls: class_name = obj_node.getAttribute('class') cls = find_class(class_name) id = obj_node.getAttribute('id') obj = cls(id) for prop_node in obj_node.getElementsByTagName('property'): prop_name = prop_node.getAttribute('name') prop = obj.find_property(prop_name) if prop: if hasattr(prop, 'item_type'): value = self.get_list(prop_node, prop.item_type) else: value = self.decode_value(prop, prop_node) value = prop.make_value_from_datastore(value) setattr(obj, prop.name, value) yield obj def reset(self): self._connect() def get_doc(self): return self.doc def encode_value(self, prop, value): return self.converter.encode_prop(prop, value) def decode_value(self, prop, value): return self.converter.decode_prop(prop, value) def get_s3_connection(self): if not self.s3: self.s3 = boto.connect_s3(self.aws_access_key_id, self.aws_secret_access_key) return self.s3 def get_list(self, prop_node, item_type): values = [] try: items_node = prop_node.getElementsByTagName('items')[0] except: return [] for item_node in items_node.getElementsByTagName('item'): value = self.converter.decode(item_type, item_node) values.append(value) return values def get_object_from_doc(self, cls, id, doc): obj_node = doc.getElementsByTagName('object')[0] if not cls: class_name = obj_node.getAttribute('class') cls = find_class(class_name) if not id: id = obj_node.getAttribute('id') obj = cls(id) for prop_node in obj_node.getElementsByTagName('property'): prop_name = prop_node.getAttribute('name') prop = obj.find_property(prop_name) value = self.decode_value(prop, prop_node) value = prop.make_value_from_datastore(value) if value is not None: try: setattr(obj, prop.name, value) except: pass return obj def get_props_from_doc(self, cls, id, doc): """ Pull out the properties from this document Returns the class, the properties in a hash, and the id if provided as a tuple :return: (cls, props, id) """ obj_node = doc.getElementsByTagName('object')[0] if not cls: class_name = obj_node.getAttribute('class') cls = find_class(class_name) if not id: id = obj_node.getAttribute('id') props = {} for prop_node in obj_node.getElementsByTagName('property'): prop_name = prop_node.getAttribute('name') prop = cls.find_property(prop_name) value = self.decode_value(prop, prop_node) value = prop.make_value_from_datastore(value) if value is not None: props[prop.name] = value return (cls, props, id) def get_object(self, cls, id): if not self.connection: self._connect() if not self.connection: raise NotImplementedError("Can't query without a database connection") url = "/%s/%s" % (self.db_name, id) resp = self._make_request('GET', url) if resp.status == 200: doc = parse(resp) else: raise Exception("Error: %s" % resp.status) return self.get_object_from_doc(cls, id, doc) def query(self, cls, filters, limit=None, order_by=None): if not self.connection: self._connect() if not self.connection: raise NotImplementedError("Can't query without a database connection") from urllib import urlencode query = str(self._build_query(cls, filters, limit, order_by)) if query: url = "/%s?%s" % (self.db_name, urlencode({"query": query})) else: url = "/%s" % self.db_name resp = self._make_request('GET', url) if resp.status == 200: doc = parse(resp) else: raise Exception("Error: %s" % resp.status) return self._object_lister(cls, doc) def _build_query(self, cls, filters, limit, order_by): import types if len(filters) > 4: raise Exception('Too many filters, max is 4') parts = [] properties = cls.properties(hidden=False) for filter, value in filters: name, op = filter.strip().split() found = False for property in properties: if property.name == name: found = True if types.TypeType(value) == list: filter_parts = [] for val in value: val = self.encode_value(property, val) filter_parts.append("'%s' %s '%s'" % (name, op, val)) parts.append("[%s]" % " OR ".join(filter_parts)) else: value = self.encode_value(property, value) parts.append("['%s' %s '%s']" % (name, op, value)) if not found: raise Exception('%s is not a valid field' % name) if order_by: if order_by.startswith("-"): key = order_by[1:] type = "desc" else: key = order_by type = "asc" parts.append("['%s' starts-with ''] sort '%s' %s" % (key, key, type)) return ' intersection '.join(parts) def query_gql(self, query_string, *args, **kwds): raise NotImplementedError("GQL queries not supported in XML") def save_list(self, doc, items, prop_node): items_node = doc.createElement('items') prop_node.appendChild(items_node) for item in items: item_node = doc.createElement('item') items_node.appendChild(item_node) if isinstance(item, Node): item_node.appendChild(item) else: text_node = doc.createTextNode(item) item_node.appendChild(text_node) def save_object(self, obj, expected_value=None): """ Marshal the object and do a PUT """ doc = self.marshal_object(obj) if obj.id: url = "/%s/%s" % (self.db_name, obj.id) else: url = "/%s" % (self.db_name) resp = self._make_request("PUT", url, body=doc.toxml()) new_obj = self.get_object_from_doc(obj.__class__, None, parse(resp)) obj.id = new_obj.id for prop in obj.properties(): try: propname = prop.name except AttributeError: propname = None if propname: value = getattr(new_obj, prop.name) if value: setattr(obj, prop.name, value) return obj def marshal_object(self, obj, doc=None): if not doc: doc = self.new_doc() if not doc: doc = self.doc obj_node = doc.createElement('object') if obj.id: obj_node.setAttribute('id', obj.id) obj_node.setAttribute('class', '%s.%s' % (obj.__class__.__module__, obj.__class__.__name__)) root = doc.documentElement root.appendChild(obj_node) for property in obj.properties(hidden=False): prop_node = doc.createElement('property') prop_node.setAttribute('name', property.name) prop_node.setAttribute('type', property.type_name) value = property.get_value_for_datastore(obj) if value is not None: value = self.encode_value(property, value) if isinstance(value, list): self.save_list(doc, value, prop_node) elif isinstance(value, Node): prop_node.appendChild(value) else: text_node = doc.createTextNode(six.text_type(value).encode("ascii", "ignore")) prop_node.appendChild(text_node) obj_node.appendChild(prop_node) return doc def unmarshal_object(self, fp, cls=None, id=None): if isinstance(fp, six.string_types): doc = parseString(fp) else: doc = parse(fp) return self.get_object_from_doc(cls, id, doc) def unmarshal_props(self, fp, cls=None, id=None): """ Same as unmarshalling an object, except it returns from "get_props_from_doc" """ if isinstance(fp, six.string_types): doc = parseString(fp) else: doc = parse(fp) return self.get_props_from_doc(cls, id, doc) def delete_object(self, obj): url = "/%s/%s" % (self.db_name, obj.id) return self._make_request("DELETE", url) def set_key_value(self, obj, name, value): self.domain.put_attributes(obj.id, {name: value}, replace=True) def delete_key_value(self, obj, name): self.domain.delete_attributes(obj.id, name) def get_key_value(self, obj, name): a = self.domain.get_attributes(obj.id, name) if name in a: return a[name] else: return None def get_raw_item(self, obj): return self.domain.get_item(obj.id) def set_property(self, prop, obj, name, value): pass def get_property(self, prop, obj, name): pass def load_object(self, obj): if not obj._loaded: obj = obj.get_by_id(obj.id) obj._loaded = True return obj
mit
pyblish/pyblish-win
lib/Python27/Lib/test/test_rlcompleter.py
122
2848
from test import test_support as support import unittest import __builtin__ as builtins import rlcompleter class CompleteMe(object): """ Trivial class used in testing rlcompleter.Completer. """ spam = 1 class TestRlcompleter(unittest.TestCase): def setUp(self): self.stdcompleter = rlcompleter.Completer() self.completer = rlcompleter.Completer(dict(spam=int, egg=str, CompleteMe=CompleteMe)) # forces stdcompleter to bind builtins namespace self.stdcompleter.complete('', 0) def test_namespace(self): class A(dict): pass class B(list): pass self.assertTrue(self.stdcompleter.use_main_ns) self.assertFalse(self.completer.use_main_ns) self.assertFalse(rlcompleter.Completer(A()).use_main_ns) self.assertRaises(TypeError, rlcompleter.Completer, B((1,))) def test_global_matches(self): # test with builtins namespace self.assertEqual(sorted(self.stdcompleter.global_matches('di')), [x+'(' for x in dir(builtins) if x.startswith('di')]) self.assertEqual(sorted(self.stdcompleter.global_matches('st')), [x+'(' for x in dir(builtins) if x.startswith('st')]) self.assertEqual(self.stdcompleter.global_matches('akaksajadhak'), []) # test with a customized namespace self.assertEqual(self.completer.global_matches('CompleteM'), ['CompleteMe(']) self.assertEqual(self.completer.global_matches('eg'), ['egg(']) # XXX: see issue5256 self.assertEqual(self.completer.global_matches('CompleteM'), ['CompleteMe(']) def test_attr_matches(self): # test with builtins namespace self.assertEqual(self.stdcompleter.attr_matches('str.s'), ['str.{}('.format(x) for x in dir(str) if x.startswith('s')]) self.assertEqual(self.stdcompleter.attr_matches('tuple.foospamegg'), []) # test with a customized namespace self.assertEqual(self.completer.attr_matches('CompleteMe.sp'), ['CompleteMe.spam']) self.assertEqual(self.completer.attr_matches('Completeme.egg'), []) CompleteMe.me = CompleteMe self.assertEqual(self.completer.attr_matches('CompleteMe.me.me.sp'), ['CompleteMe.me.me.spam']) self.assertEqual(self.completer.attr_matches('egg.s'), ['egg.{}('.format(x) for x in dir(str) if x.startswith('s')]) def test_main(): support.run_unittest(TestRlcompleter) if __name__ == '__main__': test_main()
lgpl-3.0
DmitryADP/diff_qc750
external/webkit/Tools/QueueStatusServer/handlers/gc.py
146
2038
# Copyright (C) 2009 Google Inc. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # * Redistributions in binary form must reproduce the above # copyright notice, this list of conditions and the following disclaimer # in the documentation and/or other materials provided with the # distribution. # * Neither the name of Google Inc. nor the names of its # contributors may be used to endorse or promote products derived from # this software without specific prior written permission. # # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. from google.appengine.ext import webapp from model.queuestatus import QueueStatus class GC(webapp.RequestHandler): def get(self): statuses = QueueStatus.all().order("-date") seen_queues = set() for status in statuses: if status.active_patch_id or status.active_bug_id: continue if status.queue_name in seen_queues: status.delete() seen_queues.add(status.queue_name) self.response.out.write("Done!")
gpl-2.0
robertjpayne/rethinkdb
drivers/python/rethinkdb/twisted_net/net_twisted.py
8
13947
# Copyright 2015 RethinkDB, all rights reserved. import time import struct from twisted.python import log from twisted.internet import reactor, defer from twisted.internet.defer import inlineCallbacks, returnValue, Deferred from twisted.internet.defer import DeferredQueue, CancelledError from twisted.internet.protocol import ClientFactory, Protocol from twisted.internet.endpoints import clientFromString from twisted.internet.error import TimeoutError from . import ql2_pb2 as p from .net import Query, Response, Cursor, maybe_profile from .net import Connection as ConnectionBase from .errors import * __all__ = ['Connection'] pResponse = p.Response.ResponseType pQuery = p.Query.QueryType class DatabaseProtocol(Protocol): WAITING_FOR_HANDSHAKE = 0 READY = 1 def __init__(self, factory): self.factory = factory self.state = DatabaseProtocol.WAITING_FOR_HANDSHAKE self._handlers = { DatabaseProtocol.WAITING_FOR_HANDSHAKE: self._handleHandshake, DatabaseProtocol.READY: self._handleResponse } self.buf = bytes() self.buf_expected_length = 0 self.buf_token = None self.wait_for_handshake = Deferred() self._open = True def connectionMade(self): # Send immediately the handshake. self.factory.handshake.reset() self.transport.write(self.factory.handshake.next_message(None)) # Defer a timer which will callback when timed out and errback the # wait_for_handshake. Otherwise, it will be cancelled in # handleHandshake. self._timeout_defer = reactor.callLater(self.factory.timeout, self._handleHandshakeTimeout) def connectionLost(self, reason): self._open = False def _handleHandshakeTimeout(self): # If we are here, we failed to do the handshake before the timeout. # We close the connection and raise an ReqlTimeoutError in the # wait_for_handshake deferred. self._open = False self.transport.loseConnection() self.wait_for_handshake.errback(ReqlTimeoutError()) def _handleHandshake(self, data): try: self.buf += data end_index = self.buf.find(b'\0') if end_index != -1: response = self.buf[:end_index] self.buf = self.buf[end_index + 1:] request = self.factory.handshake.next_message(response) if request is None: # We're now ready to work with real data. self.state = DatabaseProtocol.READY # We cancel the scheduled timeout. self._timeout_defer.cancel() # We callback our wait_for_handshake. self.wait_for_handshake.callback(None) elif request != "": self.transport.write(request) except Exception as e: self.wait_for_handshake.errback(e) def _handleResponse(self, data): # If we have more than one response, we should handle all of them. self.buf += data while True: # 1. Read the header, until we read the length of the awaited payload. if self.buf_expected_length == 0: if len(self.buf) >= 12: token, length = struct.unpack('<qL', self.buf[:12]) self.buf_token = token self.buf_expected_length = length self.buf = self.buf[12:] else: # We quit the function, it is impossible to have read the # entire payload at this point. return # 2. Buffer the data, until the size of the data match the expected # length provided by the header. if len(self.buf) < self.buf_expected_length: return self.factory.response_handler(self.buf_token, self.buf[:self.buf_expected_length]) self.buf = self.buf[self.buf_expected_length:] self.buf_token = None self.buf_expected_length = 0 def dataReceived(self, data): try: if self._open: self._handlers[self.state](data) except Exception as e: raise ReqlDriverError('Driver failed to handle received data.' 'Error: {exc}. Dropping the connection.'.format(exc=str(e))) self.transport.loseConnection() class DatabaseProtoFactory(ClientFactory): protocol = DatabaseProtocol def __init__(self, timeout, response_handler, handshake): self.timeout = timeout self.handshake = handshake self.response_handler = response_handler def startedConnecting(self, connector): pass def buildProtocol(self, addr): p = DatabaseProtocol(self) return p def clientConnectionLost(self, connector, reason): pass def clientConnectionFailed(self, connector, reason): pass class CursorItems(DeferredQueue): def __init__(self): super(CursorItems, self).__init__() def cancel_getters(self, err): """ Cancel all waiters. """ for waiter in self.waiting[:]: if not waiter.called: waiter.errback(err) self.waiting.remove(waiter) def extend(self, data): for k in data: self.put(k) def __len__(self): return len(self.pending) def __getitem__(self, index): return self.pending[index] def __iter__(self): return iter(self.pending) class TwistedCursor(Cursor): def __init__(self, *args, **kwargs): kwargs.setdefault('items_type', CursorItems) super(TwistedCursor, self).__init__(*args, **kwargs) self.waiting = list() def _extend(self, res): Cursor._extend(self, res) if self.error is not None: self.items.cancel_getters(self.error) for d in self.waiting[:]: d.callback(None) self.waiting.remove(d) def _empty_error(self): return RqlCursorEmpty() @inlineCallbacks def fetch_next(self, wait=True): timeout = Cursor._wait_to_timeout(wait) deadline = None if timeout is None else time.time() + timeout def wait_canceller(d): d.errback(ReqlTimeoutError()) while len(self.items) == 0 and self.error is None: self._maybe_fetch_batch() wait = Deferred(canceller=wait_canceller) self.waiting.append(wait) if deadline is not None: timeout = max(0, deadline - time.time()) reactor.callLater(timeout, lambda: wait.cancel()) yield wait returnValue(not self._is_empty() or self._has_error()) def _has_error(self): return self.error and (not isinstance(self.error, RqlCursorEmpty)) def _is_empty(self): return isinstance(self.error, RqlCursorEmpty) and len(self.items) == 0 def _get_next(self, timeout): if len(self.items) == 0 and self.error is not None: return defer.fail(self.error) def raise_timeout(errback): if isinstance(errback.value, CancelledError): raise ReqlTimeoutError() else: raise errback.value item_defer = self.items.get() if timeout is not None: item_defer.addErrback(raise_timeout) timer = reactor.callLater(timeout, lambda: item_defer.cancel()) self._maybe_fetch_batch() return item_defer class ConnectionInstance(object): def __init__(self, parent, start_reactor=False): self._parent = parent self._closing = False self._connection = None self._user_queries = {} self._cursor_cache = {} if start_reactor: reactor.run() def client_port(self): if self.is_open(): return self._connection.transport.getHost().port def client_address(self): if self.is_open(): return self._connection.transport.getHost().host def _handleResponse(self, token, data): try: cursor = self._cursor_cache.get(token) if cursor is not None: cursor._extend(data) elif token in self._user_queries: query, deferred = self._user_queries[token] res = Response(token, data, self._parent._get_json_decoder(query)) if res.type == pResponse.SUCCESS_ATOM: deferred.callback(maybe_profile(res.data[0], res)) elif res.type in (pResponse.SUCCESS_SEQUENCE, pResponse.SUCCESS_PARTIAL): cursor = TwistedCursor(self, query, res) deferred.callback(maybe_profile(cursor, res)) elif res.type == pResponse.WAIT_COMPLETE: deferred.callback(None) elif res.type == pResponse.SERVER_INFO: deferred.callback(res.data[0]) else: deferred.errback(res.make_error(query)) del self._user_queries[token] elif not self._closing: raise ReqlDriverError("Unexpected response received.") except Exception as e: if not self._closing: self.close(exception=e) @inlineCallbacks def _connectTimeout(self, factory, timeout): try: # TODO: use ssl options # TODO: this doesn't work for literal IPv6 addresses like '::1' args = "tcp:%s:%d" % (self._parent.host, self._parent.port) if timeout is not None: args = args + (":timeout=%d" % timeout) endpoint = clientFromString(reactor, args) p = yield endpoint.connect(factory) returnValue(p) except TimeoutError: raise ReqlTimeoutError() @inlineCallbacks def connect(self, timeout): factory = DatabaseProtoFactory(timeout, self._handleResponse, self._parent.handshake) # We connect to the server, and send the handshake payload. pConnection = None try: pConnection = yield self._connectTimeout(factory, timeout) except Exception as e: raise ReqlDriverError('Could not connect to {p.host}:{p.port}. Error: {exc}' .format(p=self._parent, exc=str(e))) # Now, we need to wait for the handshake. try: yield pConnection.wait_for_handshake except ReqlAuthError as e: raise except ReqlTimeoutError as e: raise ReqlTimeoutError(self._parent.host, self._parent.port) except Exception as e: raise ReqlDriverError('Connection interrupted during handshake with {p.host}:{p.port}. Error: {exc}' .format(p=self._parent, exc=str(e))) self._connection = pConnection returnValue(self._parent) def is_open(self): return self._connection._open def close(self, noreply_wait=False, token=None, exception=None): d = defer.succeed(None) self._closing = True error_message = "Connection is closed" if exception is not None: error_message = "Connection is closed (reason: {exc})".format(exc=str(exception)) for cursor in list(self._cursor_cache.values()): cursor._error(error_message) for query, deferred in iter(self._user_queries.values()): if not deferred.called: deferred.errback(fail=ReqlDriverError(error_message)) self._user_queries = {} self._cursor_cache = {} if noreply_wait: noreply = Query(pQuery.NOREPLY_WAIT, token, None, None) d = self.run_query(noreply, False) def closeConnection(res): self._connection.transport.loseConnection() return res return d.addBoth(closeConnection) @inlineCallbacks def run_query(self, query, noreply): response_defer = Deferred() if not noreply: self._user_queries[query.token] = (query, response_defer) # Send the query self._connection.transport.write(query.serialize(self._parent._get_json_encoder(query))) if noreply: returnValue(None) else: res = yield response_defer returnValue(res) class Connection(ConnectionBase): def __init__(self, *args, **kwargs): super(Connection, self).__init__(ConnectionInstance, *args, **kwargs) @inlineCallbacks def reconnect(self, noreply_wait=True, timeout=None): yield self.close(noreply_wait) res = yield super(Connection, self).reconnect(noreply_wait, timeout) returnValue(res) @inlineCallbacks def close(self, *args, **kwargs): res = yield super(Connection, self).close(*args, **kwargs) or None returnValue(res) @inlineCallbacks def noreply_wait(self, *args, **kwargs): res = yield super(Connection, self).noreply_wait(*args, **kwargs) returnValue(res) @inlineCallbacks def server(self, *args, **kwargs): res = yield super(Connection, self).server(*args, **kwargs) returnValue(res) @inlineCallbacks def _start(self, *args, **kwargs): res = yield super(Connection, self)._start(*args, **kwargs) returnValue(res) @inlineCallbacks def _continue(self, *args, **kwargs): res = yield super(Connection, self)._continue(*args, **kwargs) returnValue(res) @inlineCallbacks def _stop(self, *args, **kwargs): res = yield super(Connection, self)._stop(*args, **kwargs) returnValue(res)
apache-2.0
kamalx/edx-platform
common/lib/xmodule/xmodule/open_ended_grading_classes/self_assessment_module.py
106
11916
import json import logging from lxml import etree from xmodule.capa_module import ComplexEncoder from xmodule.progress import Progress from xmodule.stringify import stringify_children import openendedchild from .combined_open_ended_rubric import CombinedOpenEndedRubric log = logging.getLogger("edx.courseware") class SelfAssessmentModule(openendedchild.OpenEndedChild): """ A Self Assessment module that allows students to write open-ended responses, submit, then see a rubric and rate themselves. Persists student supplied hints, answers, and assessment judgment (currently only correct/incorrect). Parses xml definition file--see below for exact format. Sample XML format: <selfassessment> <hintprompt> What hint about this problem would you give to someone? </hintprompt> <submitmessage> Save Succcesful. Thanks for participating! </submitmessage> </selfassessment> """ TEMPLATE_DIR = "combinedopenended/selfassessment" # states INITIAL = 'initial' ASSESSING = 'assessing' REQUEST_HINT = 'request_hint' DONE = 'done' def setup_response(self, system, location, definition, descriptor): """ Sets up the module @param system: Modulesystem @param location: location, to let the module know where it is. @param definition: XML definition of the module. @param descriptor: SelfAssessmentDescriptor @return: None """ self.child_prompt = stringify_children(self.child_prompt) self.child_rubric = stringify_children(self.child_rubric) def get_html(self, system): """ Gets context and renders HTML that represents the module @param system: Modulesystem @return: Rendered HTML """ # set context variables and render template previous_answer = self.get_display_answer() # Use the module name as a unique id to pass to the template. try: module_id = self.system.location.name except AttributeError: # In cases where we don't have a system or a location, use a fallback. module_id = "self_assessment" context = { 'prompt': self.child_prompt, 'previous_answer': previous_answer, 'ajax_url': system.ajax_url, 'initial_rubric': self.get_rubric_html(system), 'state': self.child_state, 'allow_reset': self._allow_reset(), 'child_type': 'selfassessment', 'accept_file_upload': self.accept_file_upload, 'module_id': module_id, } html = system.render_template('{0}/self_assessment_prompt.html'.format(self.TEMPLATE_DIR), context) return html def handle_ajax(self, dispatch, data, system): """ This is called by courseware.module_render, to handle an AJAX call. "data" is request.POST. Returns a json dictionary: { 'progress_changed' : True/False, 'progress': 'none'/'in_progress'/'done', <other request-specific values here > } """ handlers = { 'save_answer': self.save_answer, 'save_assessment': self.save_assessment, 'save_post_assessment': self.save_hint, 'store_answer': self.store_answer, } if dispatch not in handlers: # This is a dev_facing_error log.error("Cannot find {0} in handlers in handle_ajax function for open_ended_module.py".format(dispatch)) # This is a dev_facing_error return json.dumps({'error': 'Error handling action. Please try again.', 'success': False}) before = self.get_progress() d = handlers[dispatch](data, system) after = self.get_progress() d.update({ 'progress_changed': after != before, 'progress_status': Progress.to_js_status_str(after), }) return json.dumps(d, cls=ComplexEncoder) def get_rubric_html(self, system): """ Return the appropriate version of the rubric, based on the state. """ if self.child_state == self.INITIAL: return '' rubric_renderer = CombinedOpenEndedRubric(system.render_template, False) rubric_dict = rubric_renderer.render_rubric(self.child_rubric) success = rubric_dict['success'] rubric_html = rubric_dict['html'] # we'll render it context = { 'rubric': rubric_html, 'max_score': self._max_score, } if self.child_state == self.ASSESSING: context['read_only'] = False elif self.child_state in (self.POST_ASSESSMENT, self.DONE): context['read_only'] = True else: # This is a dev_facing_error raise ValueError("Self assessment module is in an illegal state '{0}'".format(self.child_state)) return system.render_template('{0}/self_assessment_rubric.html'.format(self.TEMPLATE_DIR), context) def get_hint_html(self, system): """ Return the appropriate version of the hint view, based on state. """ if self.child_state in (self.INITIAL, self.ASSESSING): return '' if self.child_state == self.DONE: # display the previous hint latest = self.latest_post_assessment(system) hint = latest if latest is not None else '' else: hint = '' context = {'hint': hint} if self.child_state == self.POST_ASSESSMENT: context['read_only'] = False elif self.child_state == self.DONE: context['read_only'] = True else: # This is a dev_facing_error raise ValueError("Self Assessment module is in an illegal state '{0}'".format(self.child_state)) return system.render_template('{0}/self_assessment_hint.html'.format(self.TEMPLATE_DIR), context) def save_answer(self, data, system): """ After the answer is submitted, show the rubric. Args: data: the request dictionary passed to the ajax request. Should contain a key 'student_answer' Returns: Dictionary with keys 'success' and either 'error' (if not success), or 'rubric_html' (if success). """ # Check to see if this problem is closed closed, msg = self.check_if_closed() if closed: return msg if self.child_state != self.INITIAL: return self.out_of_sync_error(data) error_message = "" # add new history element with answer and empty score and hint. success, error_message, data = self.append_file_link_to_student_answer(data) if success: data['student_answer'] = SelfAssessmentModule.sanitize_html(data['student_answer']) self.new_history_entry(data['student_answer']) self.change_state(self.ASSESSING) return { 'success': success, 'rubric_html': self.get_rubric_html(system), 'error': error_message, 'student_response': data['student_answer'].replace("\n", "<br/>"), } def save_assessment(self, data, _system): """ Save the assessment. If the student said they're right, don't ask for a hint, and go straight to the done state. Otherwise, do ask for a hint. Returns a dict { 'success': bool, 'state': state, 'hint_html': hint_html OR 'message_html': html and 'allow_reset', 'error': error-msg}, with 'error' only present if 'success' is False, and 'hint_html' or 'message_html' only if success is true :param data: A `webob.multidict.MultiDict` containing the keys asasssment: The sum of assessment scores score_list[]: A multivalue key containing all the individual scores """ closed, msg = self.check_if_closed() if closed: return msg if self.child_state != self.ASSESSING: return self.out_of_sync_error(data) try: score = int(data.get('assessment')) score_list = [int(x) for x in data.getall('score_list[]')] except (ValueError, TypeError): # This is a dev_facing_error log.error("Non-integer score value passed to save_assessment, or no score list present.") # This is a student_facing_error _ = self.system.service(self, "i18n").ugettext return { 'success': False, 'error': _("Error saving your score. Please notify course staff.") } # Record score as assessment and rubric scores as post assessment self.record_latest_score(score) self.record_latest_post_assessment(json.dumps(score_list)) d = {'success': True, } self.change_state(self.DONE) d['allow_reset'] = self._allow_reset() d['state'] = self.child_state return d def save_hint(self, data, _system): ''' Not used currently, as hints have been removed from the system. Save the hint. Returns a dict { 'success': bool, 'message_html': message_html, 'error': error-msg, 'allow_reset': bool}, with the error key only present if success is False and message_html only if True. ''' if self.child_state != self.POST_ASSESSMENT: # Note: because we only ask for hints on wrong answers, may not have # the same number of hints and answers. return self.out_of_sync_error(data) self.record_latest_post_assessment(data['hint']) self.change_state(self.DONE) return { 'success': True, 'message_html': '', 'allow_reset': self._allow_reset(), } def latest_post_assessment(self, system): latest_post_assessment = super(SelfAssessmentModule, self).latest_post_assessment(system) try: rubric_scores = json.loads(latest_post_assessment) except: rubric_scores = [] return [rubric_scores] class SelfAssessmentDescriptor(object): """ Module for adding self assessment questions to courses """ mako_template = "widgets/html-edit.html" module_class = SelfAssessmentModule filename_extension = "xml" has_score = True def __init__(self, system): self.system = system @classmethod def definition_from_xml(cls, xml_object, system): """ Pull out the rubric, prompt, and submitmessage into a dictionary. Returns: { 'submitmessage': 'some-html' 'hintprompt': 'some-html' } """ expected_children = [] for child in expected_children: if len(xml_object.xpath(child)) != 1: # This is a staff_facing_error raise ValueError( u"Self assessment definition must include exactly one '{0}' tag. Contact the learning sciences group for assistance.".format( child)) def parse(k): """Assumes that xml_object has child k""" return stringify_children(xml_object.xpath(k)[0]) return {} def definition_to_xml(self, resource_fs): '''Return an xml element representing this definition.''' elt = etree.Element('selfassessment') def add_child(k): child_str = u'<{tag}>{body}</{tag}>'.format(tag=k, body=getattr(self, k)) child_node = etree.fromstring(child_str) elt.append(child_node) for child in []: add_child(child) return elt
agpl-3.0
trishnaguha/ansible
packaging/release/tests/version_helper_test.py
125
2174
from __future__ import absolute_import, division, print_function __metaclass__ = type import pytest from packaging.version import InvalidVersion from versionhelper.version_helper import AnsibleVersionMunger @pytest.mark.parametrize('version,revision,codename,output_propname,expected', [ ('2.5.0.dev1', None, None, 'raw', '2.5.0.dev1'), ('2.5.0a0.post0', None, None, 'raw', '2.5.0a0.post0'), ('2.5.0', None, None, 'raw', '2.5.0'), ('2.5.0.dev1', None, None, 'major_version', '2.5'), ('2.5.0', None, None, 'major_version', '2.5'), ('2.5.0.dev1', None, None, 'base_version', '2.5.0'), ('2.5.0', None, None, 'base_version', '2.5.0'), ('2.5.0.dev1', None, None, 'deb_version', '2.5.0~dev1'), ('2.5.0b1', None, None, 'deb_version', '2.5.0~b1'), ('2.5.0b1.dev1', None, None, 'deb_version', '2.5.0~b1~dev1'), ('2.5.0b1.post0', None, None, 'deb_version', '2.5.0~b1~post0'), ('2.5.0', None, None, 'deb_version', '2.5.0'), ('2.5.0.dev1', None, None, 'deb_release', '1'), ('2.5.0b1', 2, None, 'deb_release', '2'), ('2.5.0.dev1', None, None, 'rpm_release', '0.1.dev1'), ('2.5.0a1', None, None, 'rpm_release', '0.101.a1'), ('2.5.0a1.post0', None, None, 'rpm_release', '0.101.a1.post0'), ('2.5.0b1', None, None, 'rpm_release', '0.201.b1'), ('2.5.0rc1', None, None, 'rpm_release', '0.1001.rc1'), ('2.5.0rc1', '0.99', None, 'rpm_release', '0.99.rc1'), ('2.5.0.rc.1', None, None, 'rpm_release', '0.1001.rc.1'), ('2.5.0.rc1.dev1', None, None, 'rpm_release', '0.1001.rc1.dev1'), ('2.5.0', None, None, 'rpm_release', '1'), ('2.5.0', 2, None, 'rpm_release', '2'), ('2.5.0', None, None, 'codename', 'UNKNOWN'), ('2.5.0', None, 'LedZeppelinSongHere', 'codename', 'LedZeppelinSongHere'), ('2.5.0x1', None, None, None, InvalidVersion) ]) def test_output_values(version, revision, codename, output_propname, expected): try: v = AnsibleVersionMunger(version, revision, codename) assert getattr(v, output_propname) == expected except Exception as ex: if isinstance(expected, type): assert isinstance(ex, expected) else: raise
gpl-3.0
ntuecon/server
pyenv/Lib/site-packages/twisted/names/test/test_util.py
13
3915
# Copyright (c) Twisted Matrix Laboratories. # See LICENSE for details. """ Utilities for Twisted.names tests. """ from __future__ import division, absolute_import from random import randrange from zope.interface import implementer from zope.interface.verify import verifyClass from twisted.internet.address import IPv4Address from twisted.internet.defer import succeed from twisted.internet.task import Clock from twisted.internet.interfaces import IReactorUDP, IUDPTransport @implementer(IUDPTransport) class MemoryDatagramTransport(object): """ This L{IUDPTransport} implementation enforces the usual connection rules and captures sent traffic in a list for later inspection. @ivar _host: The host address to which this transport is bound. @ivar _protocol: The protocol connected to this transport. @ivar _sentPackets: A C{list} of two-tuples of the datagrams passed to C{write} and the addresses to which they are destined. @ivar _connectedTo: L{None} if this transport is unconnected, otherwise an address to which all traffic is supposedly sent. @ivar _maxPacketSize: An C{int} giving the maximum length of a datagram which will be successfully handled by C{write}. """ def __init__(self, host, protocol, maxPacketSize): self._host = host self._protocol = protocol self._sentPackets = [] self._connectedTo = None self._maxPacketSize = maxPacketSize def getHost(self): """ Return the address which this transport is pretending to be bound to. """ return IPv4Address('UDP', *self._host) def connect(self, host, port): """ Connect this transport to the given address. """ if self._connectedTo is not None: raise ValueError("Already connected") self._connectedTo = (host, port) def write(self, datagram, addr=None): """ Send the given datagram. """ if addr is None: addr = self._connectedTo if addr is None: raise ValueError("Need an address") if len(datagram) > self._maxPacketSize: raise ValueError("Packet too big") self._sentPackets.append((datagram, addr)) def stopListening(self): """ Shut down this transport. """ self._protocol.stopProtocol() return succeed(None) def setBroadcastAllowed(self, enabled): """ Dummy implementation to satisfy L{IUDPTransport}. """ pass def getBroadcastAllowed(self): """ Dummy implementation to satisfy L{IUDPTransport}. """ pass verifyClass(IUDPTransport, MemoryDatagramTransport) @implementer(IReactorUDP) class MemoryReactor(Clock): """ An L{IReactorTime} and L{IReactorUDP} provider. Time is controlled deterministically via the base class, L{Clock}. UDP is handled in-memory by connecting protocols to instances of L{MemoryDatagramTransport}. @ivar udpPorts: A C{dict} mapping port numbers to instances of L{MemoryDatagramTransport}. """ def __init__(self): Clock.__init__(self) self.udpPorts = {} def listenUDP(self, port, protocol, interface='', maxPacketSize=8192): """ Pretend to bind a UDP port and connect the given protocol to it. """ if port == 0: while True: port = randrange(1, 2 ** 16) if port not in self.udpPorts: break if port in self.udpPorts: raise ValueError("Address in use") transport = MemoryDatagramTransport( (interface, port), protocol, maxPacketSize) self.udpPorts[port] = transport protocol.makeConnection(transport) return transport verifyClass(IReactorUDP, MemoryReactor)
bsd-3-clause
cevaris/pants
tests/python/pants_test/backend/jvm/tasks/test_jvm_platform_analysis_integration.py
21
4718
# coding=utf-8 # Copyright 2015 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). from __future__ import (absolute_import, division, generators, nested_scopes, print_function, unicode_literals, with_statement) import os from contextlib import contextmanager from textwrap import dedent from pants.util.contextutil import temporary_dir from pants_test.pants_run_integration_test import PantsRunIntegrationTest class JvmPlatformAnalysisIntegrationTest(PantsRunIntegrationTest): """Make sure jvm-platform-analysis runs properly, especially with respect to caching behavior.""" class JavaSandbox(object): """Testing sandbox for making temporary java_library targets.""" def __init__(self, test, workdir, javadir): self.javadir = javadir self.workdir = workdir self.test = test if not os.path.exists(self.workdir): os.makedirs(self.workdir) @property def build_file_path(self): return os.path.join(self.javadir, 'BUILD') def write_build_file(self, contents): with open(self.build_file_path, 'w') as f: f.write(contents) def spec(self, name): return '{}:{}'.format(self.javadir, name) def clean_all(self): return self.test.run_pants_with_workdir(['clean-all'], workdir=self.workdir) def jvm_platform_validate(self, *targets): return self.test.run_pants_with_workdir(['jvm-platform-validate', '--check=fatal'] + map(self.spec, targets), workdir=self.workdir) @contextmanager def setup_sandbox(self): with temporary_dir('.') as sourcedir: with self.temporary_workdir() as workdir: javadir = os.path.join(sourcedir, 'src', 'java') os.makedirs(javadir) yield self.JavaSandbox(self, workdir, javadir) @property def _good_one_two(self): return dedent(""" java_library(name='one', platform='1.7', ) java_library(name='two', platform='1.8', ) """) @property def _bad_one_two(self): return dedent(""" java_library(name='one', platform='1.7', dependencies=[':two'], ) java_library(name='two', platform='1.8', ) """) def test_good_targets_works_fresh(self): with self.setup_sandbox() as sandbox: sandbox.write_build_file(self._good_one_two) self.assert_success(sandbox.clean_all()) self.assert_success(sandbox.jvm_platform_validate('one', 'two')) def test_bad_targets_fails_fresh(self): with self.setup_sandbox() as sandbox: sandbox.write_build_file(self._bad_one_two) self.assert_success(sandbox.clean_all()) self.assert_failure(sandbox.jvm_platform_validate('one', 'two')) def test_good_then_bad(self): with self.setup_sandbox() as sandbox: sandbox.write_build_file(self._good_one_two) self.assert_success(sandbox.clean_all()) self.assert_success(sandbox.jvm_platform_validate('one', 'two')) sandbox.write_build_file(self._bad_one_two) self.assert_failure(sandbox.jvm_platform_validate('one', 'two')) def test_bad_then_good(self): with self.setup_sandbox() as sandbox: sandbox.write_build_file(self._bad_one_two) self.assert_success(sandbox.clean_all()) self.assert_failure(sandbox.jvm_platform_validate('one', 'two')) sandbox.write_build_file(self._good_one_two) self.assert_success(sandbox.jvm_platform_validate('one', 'two')) def test_good_caching(self): # Make sure targets are cached after a good run. with self.setup_sandbox() as sandbox: sandbox.write_build_file(self._good_one_two) self.assert_success(sandbox.clean_all()) first_run = sandbox.jvm_platform_validate('one', 'two') self.assert_success(first_run) self.assertIn('Invalidated 2 targets', first_run.stdout_data) second_run = sandbox.jvm_platform_validate('one', 'two') self.assert_success(second_run) self.assertNotIn('Invalidated 2 targets', second_run.stdout_data) def test_bad_caching(self): # Make sure targets aren't cached after a bad run. with self.setup_sandbox() as sandbox: sandbox.write_build_file(self._bad_one_two) self.assert_success(sandbox.clean_all()) first_run = sandbox.jvm_platform_validate('one', 'two') self.assert_failure(first_run) self.assertIn('Invalidated 2 targets', first_run.stdout_data) second_run = sandbox.jvm_platform_validate('one', 'two') self.assert_failure(second_run) self.assertIn('Invalidated 2 targets', second_run.stdout_data)
apache-2.0
southpawtech/TACTIC-DEV
src/pyasm/prod/service/base_xmlrpc.py
6
19251
########################################################### # # Copyright (c) 2005, Southpaw Technology # All Rights Reserved # # PROPRIETARY INFORMATION. This software is proprietary to # Southpaw Technology, and is not to be reproduced, transmitted, # or disclosed in any way without written permission. # # # __all__ = ["ServiceException", "BaseXMLRPC", "CreateSetAssetsCmd"] import shutil, os from pyasm.common import System, TacticException from pyasm.security import * from pyasm.search import * from pyasm.command import Command from pyasm.checkin import FileGroupCheckin from pyasm.prod.checkin import * from pyasm.prod.biz import * from pyasm.prod.load import * from pyasm.prod.queue import Queue from pyasm.web.app_server import XmlrpcServer from pyasm.web import WebContainer from pyasm.biz import Project, Snapshot class ServiceException(Exception): pass class BaseXMLRPC(XmlrpcServer): METHODS = ['get_loader_xml', \ 'get_shot_loader_xml', \ 'update_session', \ 'create_assets', \ 'get_update_xml', \ 'create_set', \ 'checkin_set', \ 'checkin_shot_set', \ 'get_instances_by_shot_xml', \ 'checkin_flash_shot', \ 'set_project' \ ] def init(my, ticket): XmlRpcInit(ticket) # initialize the web environment object and register it adapter = my.get_adapter() WebContainer.set_web(adapter) my.set_templates() def set_project(my, project_code): my.project_code = project_code return True set_project.exposed = True def set_templates(my): pass def exposedMethods(my): return my.METHODS def get_loader_xml(my, ticket, project_code, snapshot_code, context="", options=""): '''uses the loader to generate an execute xml that can be used to load the assets''' try: my.init(ticket) Project.set_project(project_code) snapshot = Snapshot.get_by_code(snapshot_code) # get the loader implementation loader_context = ProdLoaderContext() loader_context.set_context(context) # pass on any message options for the loader if options != "": loader_context.set_options(options) loader = loader_context.get_loader(snapshot) loader.execute() execute_xml = loader.get_execute_xml() xml = execute_xml.get_xml() finally: DbContainer.close_all() return xml get_loader_xml.exposed = True def get_update_xml(my, ticket, project_code, snapshot_code, asset_code, instance, context='', options=''): '''an update xml to update node info''' try: my.init(ticket) Project.set_project(project_code) snapshot = Snapshot.get_by_code(snapshot_code) # get the loader implementation loader_context = ProdLoaderContext() loader_context.set_context(context) if options != "": loader_context.set_options(options) loader = loader_context.get_updater(snapshot, asset_code, instance) loader.execute() execute_xml = loader.get_execute_xml() xml = execute_xml.get_xml() finally: DbContainer.close_all() return xml get_update_xml.exposed = True def get_shot_loader_xml(my, ticket, project_code, snapshot_code, shot_code, instance_name, context="", options=""): '''uses the loader to generate an execute xml that can be used to load the assets''' try: my.init(ticket) Project.set_project(project_code) snapshot = Snapshot.get_by_code(snapshot_code) # get the shot shot = Shot.get_by_code(shot_code) if not shot: raise ServiceException("No shot [%s] exists" % shot_code) # get the loader implementation loader_context = ProdLoaderContext() loader_context.set_shot(shot) loader_context.set_context(context) # pass on any message options for the loader if options != "": loader_context.set_options(options) loader = loader_context.get_loader(snapshot) # just set the shot if we are loading the shot if shot_code == instance_name: loader.set_instance(shot) else: instance = ShotInstance.get_by_shot(shot, instance_name) if not instance: raise TacticException('Asset Instance [%s] not found in shot [%s]'%(instance_name, shot.get_code())) loader.set_instance(instance) # setting all instances in anim to be loaded with the unique flag loader.set_unique() loader.execute() execute_xml = loader.get_execute_xml() xml = execute_xml.get_xml() finally: DbContainer.close_all() return xml get_shot_loader_xml.exposed = True def update_session(my, ticket, project_code, user, pid, data): try: my.init(ticket) Project.set_project(project_code) # get the session sobject sobject = None search = Search("prod/session_contents", project_code=project_code) search.add_filter("login", user) search.add_filter("pid", pid) sobject = search.get_sobject() # if none exists, then create one if sobject == None: search_type = SearchType.build_search_type('prod/session_contents', project_code) sobject = SearchType.create(search_type) sobject.set_value("login", user) sobject.set_value("pid", pid) sobject.set_value("data", data) impl = search.get_database_impl() sobject.set_value("timestamp", impl.get_timestamp_now(), quoted=False) sobject.commit() finally: DbContainer.close_all() return True update_session.exposed = True def create_assets(my, ticket, project_code, set_code, names): try: my.init(ticket) Project.set_project(project_code) cmd = CreateSetAssetsCmd() cmd.set_set_code(set_code) cmd.set_names(names) Command.execute_cmd(cmd) asset_codes = cmd.get_asset_codes() finally: DbContainer.close_all() return asset_codes create_assets.exposed = True def create_set(my, ticket, project_code, set_name, cat_name, selected): '''an xml to create a new set node''' xml = '' asset_code = '' try: my.init(ticket) Project.set_project(project_code) cmd = MayaSetCreateCmd() cmd.set_set_name(set_name) cmd.set_cat_name(cat_name) Command.execute_cmd(cmd) asset_code = cmd.get_asset_code() if asset_code: cmd = CreateSetNodeCmd() cmd.set_asset_code(asset_code) cmd.set_instance(set_name) cmd.set_contents(selected) cmd.execute() execute_xml = cmd.get_execute_xml() xml = execute_xml.get_xml() finally: DbContainer.close_all() return [xml, asset_code] create_set.exposed = True def checkin_set(my, ticket, project_code, asset_code, context): snapshot_code = '' try: my.init(ticket) Project.set_project(project_code) new_set = Asset.get_by_code(asset_code) checkin = MayaGroupCheckin(new_set) checkin.set_context(context) checkin.set_description("Initial Publish") Command.execute_cmd(checkin) snapshot_code = checkin.snapshot.get_code() finally: DbContainer.close_all() return snapshot_code checkin_set.exposed = True def checkin_shot_set(my, ticket, project_code, shot_code, process, context, \ checkin_as, currency, unknown_ref, desc): snapshot_code = '' try: my.init(ticket) Project.set_project(project_code) shot = Shot.get_by_code(shot_code) checkin = ShotCheckin(shot) checkin.set_description(desc) checkin.set_process(process) checkin.set_context(context) is_current = True if currency == 'False': is_current = False is_revision = False if checkin_as == 'Revision': is_revision = True checkin.set_current(is_current) checkin.set_revision(is_revision) checkin.set_option("unknown_ref", unknown_ref) Command.execute_cmd(checkin) snapshot_code = checkin.snapshot.get_code() finally: DbContainer.close_all() return snapshot_code checkin_shot_set.exposed = True """ def get_snapshot_file(my, search_key, context): '''gets the last checked in snapshot for this sobject and context and retrieves the files already checked in''' get_snapshot_file.exposed = True """ def get_instances_by_shot_xml(my, ticket, project_code, shot_code, with_template=True, with_audio=True): ''' retrieve flash asset instances in a shot''' try: my.init(ticket) Project.set_project(project_code) shot = Shot.get_by_code(shot_code) if not shot: raise ServiceException("No shot [%s] exists" % shot_code) # get the instances and then get the latest assets instances = ShotInstance.get_all_by_shot(shot) asset_codes = SObject.get_values(instances, "asset_code", unique=True) search = Search(Asset) search.add_filters("code", asset_codes) assets = search.get_sobjects() uber_xml = [] uber_xml.append("<execute>") if with_template: loader_context = ProdLoaderContext() # hard-coded in TemplateLoaderCmd for now #loader_context.set_option('instantiation', 'open') tmpl_loader = loader_context.get_template_loader(shot) tmpl_loader.execute() execute_xml = tmpl_loader.get_execute_xml() xml = execute_xml.get_xml() xml = Xml(string=xml) nodes = xml.get_nodes("execute/*") for node in nodes: uber_xml.append( " %s" % xml.to_string(node, pretty=False) ) if with_audio: shot_audio = ShotAudio.get_by_shot_code(shot_code) # assuming shot_audio uses 'publish' context if shot_audio: context = "publish" inst_mode = "import_media" my._append_xml( shot_audio, context, inst_mode, uber_xml ) for asset in assets: context = "publish" inst_mode = "import" my._append_xml( asset, context, inst_mode, uber_xml ) loader_context = ProdLoaderContext() loader_context.set_context(context) loader_context.set_option('code', shot_code) # add publish instructions publisher = loader_context.get_publisher('flash') publisher.execute() xml = publisher.get_execute_xml().get_xml() xml = Xml(string=xml) nodes = xml.get_nodes("execute/*") for node in nodes: uber_xml.append( " %s" % xml.to_string(node, pretty=False) ) uber_xml.append("</execute>") uber_xml = "\n".join(uber_xml) finally: DbContainer.close_all() return uber_xml get_instances_by_shot_xml.exposed = True def _append_xml(my, asset, context, inst_mode, uber_xml ): '''append xml to the uber_xml''' snapshot = Snapshot.get_latest_by_sobject(asset, context) loader_context = ProdLoaderContext() loader_context.set_context(context) loader_context.set_option('instantiation', inst_mode) loader = loader_context.get_loader(snapshot) loader.execute() execute_xml = loader.get_execute_xml() xml = execute_xml.get_xml() xml = Xml(string=xml) nodes = xml.get_nodes("execute/*") for node in nodes: uber_xml.append( " %s" % xml.to_string(node, pretty=False)) def checkin_textures(my, ticket, project_code, asset_code, paths, file_ranges, node_names, attrs, use_handoff_dir=False, md5s=[]): '''creates a number of textures under a single asset''' new_paths = [] try: my.init(ticket) Project.set_project(project_code) parent = Asset.get_by_code(asset_code) #parent = Search.get_by_search_key(search_key) context = 'publish' checkin = TextureCheckin(parent, context, paths, file_ranges, node_names, attrs, use_handoff_dir=use_handoff_dir, md5s=md5s) Command.execute_cmd(checkin) new_paths = checkin.get_texture_paths() #md5_list = checkin.get_texture_md5() file_code_list = checkin.get_file_codes() #loader_context = ProdLoaderContext() #updater = loader_context.get_updater(snapshot, asset_code, instance) #execute_xml = updater.get_execute_xml() #xml = execute_xml.to_string() finally: DbContainer.close_all() return new_paths, file_code_list checkin_textures.exposed = True def checkin_flash_shot(my, ticket, project_code,shot_code, context, comment): snapshot_code = '' try: my.init(ticket) Project.set_project(project_code) from pyasm.flash import FlashShotSObjectPublishCmd shot = Shot.get_by_code(shot_code) checkin = FlashShotSObjectPublishCmd(shot, context, comment) Command.execute_cmd(checkin) snapshot_code = checkin.snapshot.get_code() finally: DbContainer.close_all() return snapshot_code checkin_flash_shot.exposed = True def get_queue(my, ticket): execute_xml = "<execute/>" try: my.init(ticket) from pyasm.prod.queue import Queue job = Queue.get_next_job() if job: job.execute() # need to get the execute xml command = job.get_command() execute_xml = command.get_execute_xml() finally: DbContainer.close_all() return execute_xml get_queue.exposed = True def get_upload_dir(my, ticket): '''simple function that returns a temporary path that files can be copied to''' tmp_dir = Environment.get_tmp_dir() upload_dir = "%s/upload/%s" % (tmp_dir, ticket) # TODO: upload_dir is not System().makedirs(upload_dir) return upload_dir get_upload_dir.exposed = True def checkin_frames(my, ticket, project_code, queue_id): try: my.init(ticket) Project.set_project(project_code) cmd = CheckinFramesXMLRPC() cmd.set_args(ticket, queue_id) Command.execute_cmd(cmd) finally: DbContainer.close_all() return True checkin_frames.exposed = True class CreateSetAssetsCmd(Command): '''This command checkins everything included in a set as a new asset''' def __init__(my): my.asset_codes = [] def set_set_code(my, set_code): my.set_code = set_code def set_names(my, names): my.names = names my.description = "Created assets '%s'" % names def get_asset_codes(my): return my.asset_codes def execute(my): set = Asset.get_by_code(my.set_code) asset_library = set.get_value("name") # create the assets and check each in for name in my.names: description = name asset = Asset.create_with_autocode(name, asset_library, name) asset_code = asset.get_code() my.asset_codes.append(asset_code) # move the file created to a new name with the proper asset_code tmp_dir = Environment.get_tmp_dir() dir = "%s/upload" % tmp_dir shutil.move("%s/%s.ma" % (dir,name), "%s/%s.ma" % (dir,asset_code) ) checkin = MayaAssetCheckin(asset_code) checkin.set_description("Initial checkin") checkin.set_context("proxy") checkin.execute() class CheckinFramesXMLRPC(Command): def get_title(my): return "Checkin Frames" def set_args(my, ticket, queue_id): my.ticket = ticket # get the necessary data queue = Queue.get_by_id(queue_id) #data = queue.get_xml_value("data") data = queue.get_xml_value("serialized") search_key = data.get_value("data/search_key") my.sobject = Search.get_by_search_key(search_key) if not my.sobject: raise Exception("SObject with search_key: %s does not exist" % search_key) snapshot_code = data.get_value("data/snapshot_code") my.snapshot = Snapshot.get_by_code(snapshot_code) my.file_range = data.get_value("data/file_range") my.session = "<session/>" my.pattern = data.get_value("data/pattern") def execute(my): assert my.snapshot # assumes the files are already copied to the upload directory by # some other means (copying, for example) tmp_dir = Environment.get_tmp_dir() upload_dir = "%s/upload/%s" % (tmp_dir, my.ticket) file_name = my.pattern file_paths = ["%s/%s" % (upload_dir, file_name)] file_types = ["main"] # need to get session information if not my.session: my.session = "<session/>" # just add the next version version = -1 render = Render.create(my.sobject, my.snapshot, my.session, my.file_range, version) file_range = FrameRange.get(my.file_range) checkin = FileGroupCheckin(render, file_paths, file_types, file_range) checkin.add_input_snapshot(my.snapshot) checkin.execute() my.description = "Checked in frames %s" % file_range.get_key()
epl-1.0
gferguson-gd/sensu-community-plugins
plugins/aws/check_vpc_vpn.py
56
1480
#!/usr/bin/python # #RED import argparse import boto.ec2 from boto.vpc import VPCConnection import sys def main(): try: conn = boto.vpc.VPCConnection(aws_access_key_id=args.aws_access_key_id, aws_secret_access_key=args.aws_secret_access_key, region=boto.ec2.get_region(args.region)) except: print "UNKNOWN: Unable to connect to reqion %s" % args.region sys.exit(3) errors = [] for vpn_connection in conn.get_all_vpn_connections(): for tunnel in vpn_connection.tunnels: if tunnel.status != 'UP': errors.append("[gateway: %s connection: %s tunnel: %s status: %s]" % (vpn_connection.vpn_gateway_id, vpn_connection.id, tunnel.outside_ip_address, tunnel.status)) if len(errors) > 1: print 'CRITICAL: ' + ' '.join(errors) sys.exit(2) elif len(errors) > 0: print 'WARN: ' + ' '.join(errors) sys.exit(1) else: print 'OK' sys.exit(0) if __name__ == "__main__": parser = argparse.ArgumentParser(description='Check status of all existing AWS VPC VPN Tunnels') parser.add_argument('-a', '--aws-access-key-id', required=True, dest='aws_access_key_id', help='AWS Access Key') parser.add_argument('-s', '--aws-secret-access-key', required=True, dest='aws_secret_access_key', help='AWS Secret Access Key') parser.add_argument('-r', '--region', required=True, dest='region', help='AWS Region') args = parser.parse_args() main()
mit
wgcv/SWW-Crashphone
lib/python2.7/site-packages/pip/_vendor/html5lib/treebuilders/_base.py
915
13711
from __future__ import absolute_import, division, unicode_literals from pip._vendor.six import text_type from ..constants import scopingElements, tableInsertModeElements, namespaces # The scope markers are inserted when entering object elements, # marquees, table cells, and table captions, and are used to prevent formatting # from "leaking" into tables, object elements, and marquees. Marker = None listElementsMap = { None: (frozenset(scopingElements), False), "button": (frozenset(scopingElements | set([(namespaces["html"], "button")])), False), "list": (frozenset(scopingElements | set([(namespaces["html"], "ol"), (namespaces["html"], "ul")])), False), "table": (frozenset([(namespaces["html"], "html"), (namespaces["html"], "table")]), False), "select": (frozenset([(namespaces["html"], "optgroup"), (namespaces["html"], "option")]), True) } class Node(object): def __init__(self, name): """Node representing an item in the tree. name - The tag name associated with the node parent - The parent of the current node (or None for the document node) value - The value of the current node (applies to text nodes and comments attributes - a dict holding name, value pairs for attributes of the node childNodes - a list of child nodes of the current node. This must include all elements but not necessarily other node types _flags - A list of miscellaneous flags that can be set on the node """ self.name = name self.parent = None self.value = None self.attributes = {} self.childNodes = [] self._flags = [] def __str__(self): attributesStr = " ".join(["%s=\"%s\"" % (name, value) for name, value in self.attributes.items()]) if attributesStr: return "<%s %s>" % (self.name, attributesStr) else: return "<%s>" % (self.name) def __repr__(self): return "<%s>" % (self.name) def appendChild(self, node): """Insert node as a child of the current node """ raise NotImplementedError def insertText(self, data, insertBefore=None): """Insert data as text in the current node, positioned before the start of node insertBefore or to the end of the node's text. """ raise NotImplementedError def insertBefore(self, node, refNode): """Insert node as a child of the current node, before refNode in the list of child nodes. Raises ValueError if refNode is not a child of the current node""" raise NotImplementedError def removeChild(self, node): """Remove node from the children of the current node """ raise NotImplementedError def reparentChildren(self, newParent): """Move all the children of the current node to newParent. This is needed so that trees that don't store text as nodes move the text in the correct way """ # XXX - should this method be made more general? for child in self.childNodes: newParent.appendChild(child) self.childNodes = [] def cloneNode(self): """Return a shallow copy of the current node i.e. a node with the same name and attributes but with no parent or child nodes """ raise NotImplementedError def hasContent(self): """Return true if the node has children or text, false otherwise """ raise NotImplementedError class ActiveFormattingElements(list): def append(self, node): equalCount = 0 if node != Marker: for element in self[::-1]: if element == Marker: break if self.nodesEqual(element, node): equalCount += 1 if equalCount == 3: self.remove(element) break list.append(self, node) def nodesEqual(self, node1, node2): if not node1.nameTuple == node2.nameTuple: return False if not node1.attributes == node2.attributes: return False return True class TreeBuilder(object): """Base treebuilder implementation documentClass - the class to use for the bottommost node of a document elementClass - the class to use for HTML Elements commentClass - the class to use for comments doctypeClass - the class to use for doctypes """ # Document class documentClass = None # The class to use for creating a node elementClass = None # The class to use for creating comments commentClass = None # The class to use for creating doctypes doctypeClass = None # Fragment class fragmentClass = None def __init__(self, namespaceHTMLElements): if namespaceHTMLElements: self.defaultNamespace = "http://www.w3.org/1999/xhtml" else: self.defaultNamespace = None self.reset() def reset(self): self.openElements = [] self.activeFormattingElements = ActiveFormattingElements() # XXX - rename these to headElement, formElement self.headPointer = None self.formPointer = None self.insertFromTable = False self.document = self.documentClass() def elementInScope(self, target, variant=None): # If we pass a node in we match that. if we pass a string # match any node with that name exactNode = hasattr(target, "nameTuple") listElements, invert = listElementsMap[variant] for node in reversed(self.openElements): if (node.name == target and not exactNode or node == target and exactNode): return True elif (invert ^ (node.nameTuple in listElements)): return False assert False # We should never reach this point def reconstructActiveFormattingElements(self): # Within this algorithm the order of steps described in the # specification is not quite the same as the order of steps in the # code. It should still do the same though. # Step 1: stop the algorithm when there's nothing to do. if not self.activeFormattingElements: return # Step 2 and step 3: we start with the last element. So i is -1. i = len(self.activeFormattingElements) - 1 entry = self.activeFormattingElements[i] if entry == Marker or entry in self.openElements: return # Step 6 while entry != Marker and entry not in self.openElements: if i == 0: # This will be reset to 0 below i = -1 break i -= 1 # Step 5: let entry be one earlier in the list. entry = self.activeFormattingElements[i] while True: # Step 7 i += 1 # Step 8 entry = self.activeFormattingElements[i] clone = entry.cloneNode() # Mainly to get a new copy of the attributes # Step 9 element = self.insertElement({"type": "StartTag", "name": clone.name, "namespace": clone.namespace, "data": clone.attributes}) # Step 10 self.activeFormattingElements[i] = element # Step 11 if element == self.activeFormattingElements[-1]: break def clearActiveFormattingElements(self): entry = self.activeFormattingElements.pop() while self.activeFormattingElements and entry != Marker: entry = self.activeFormattingElements.pop() def elementInActiveFormattingElements(self, name): """Check if an element exists between the end of the active formatting elements and the last marker. If it does, return it, else return false""" for item in self.activeFormattingElements[::-1]: # Check for Marker first because if it's a Marker it doesn't have a # name attribute. if item == Marker: break elif item.name == name: return item return False def insertRoot(self, token): element = self.createElement(token) self.openElements.append(element) self.document.appendChild(element) def insertDoctype(self, token): name = token["name"] publicId = token["publicId"] systemId = token["systemId"] doctype = self.doctypeClass(name, publicId, systemId) self.document.appendChild(doctype) def insertComment(self, token, parent=None): if parent is None: parent = self.openElements[-1] parent.appendChild(self.commentClass(token["data"])) def createElement(self, token): """Create an element but don't insert it anywhere""" name = token["name"] namespace = token.get("namespace", self.defaultNamespace) element = self.elementClass(name, namespace) element.attributes = token["data"] return element def _getInsertFromTable(self): return self._insertFromTable def _setInsertFromTable(self, value): """Switch the function used to insert an element from the normal one to the misnested table one and back again""" self._insertFromTable = value if value: self.insertElement = self.insertElementTable else: self.insertElement = self.insertElementNormal insertFromTable = property(_getInsertFromTable, _setInsertFromTable) def insertElementNormal(self, token): name = token["name"] assert isinstance(name, text_type), "Element %s not unicode" % name namespace = token.get("namespace", self.defaultNamespace) element = self.elementClass(name, namespace) element.attributes = token["data"] self.openElements[-1].appendChild(element) self.openElements.append(element) return element def insertElementTable(self, token): """Create an element and insert it into the tree""" element = self.createElement(token) if self.openElements[-1].name not in tableInsertModeElements: return self.insertElementNormal(token) else: # We should be in the InTable mode. This means we want to do # special magic element rearranging parent, insertBefore = self.getTableMisnestedNodePosition() if insertBefore is None: parent.appendChild(element) else: parent.insertBefore(element, insertBefore) self.openElements.append(element) return element def insertText(self, data, parent=None): """Insert text data.""" if parent is None: parent = self.openElements[-1] if (not self.insertFromTable or (self.insertFromTable and self.openElements[-1].name not in tableInsertModeElements)): parent.insertText(data) else: # We should be in the InTable mode. This means we want to do # special magic element rearranging parent, insertBefore = self.getTableMisnestedNodePosition() parent.insertText(data, insertBefore) def getTableMisnestedNodePosition(self): """Get the foster parent element, and sibling to insert before (or None) when inserting a misnested table node""" # The foster parent element is the one which comes before the most # recently opened table element # XXX - this is really inelegant lastTable = None fosterParent = None insertBefore = None for elm in self.openElements[::-1]: if elm.name == "table": lastTable = elm break if lastTable: # XXX - we should really check that this parent is actually a # node here if lastTable.parent: fosterParent = lastTable.parent insertBefore = lastTable else: fosterParent = self.openElements[ self.openElements.index(lastTable) - 1] else: fosterParent = self.openElements[0] return fosterParent, insertBefore def generateImpliedEndTags(self, exclude=None): name = self.openElements[-1].name # XXX td, th and tr are not actually needed if (name in frozenset(("dd", "dt", "li", "option", "optgroup", "p", "rp", "rt")) and name != exclude): self.openElements.pop() # XXX This is not entirely what the specification says. We should # investigate it more closely. self.generateImpliedEndTags(exclude) def getDocument(self): "Return the final tree" return self.document def getFragment(self): "Return the final fragment" # assert self.innerHTML fragment = self.fragmentClass() self.openElements[0].reparentChildren(fragment) return fragment def testSerializer(self, node): """Serialize the subtree of node in the format required by unit tests node - the node from which to start serializing""" raise NotImplementedError
apache-2.0
Datera/cinder
cinder/backup/driver.py
1
18112
# Copyright (C) 2013 Deutsche Telekom AG # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations # under the License. """Base class for all backup drivers.""" import abc from oslo_config import cfg from oslo_log import log as logging from oslo_serialization import jsonutils import six from cinder.db import base from cinder import exception from cinder.i18n import _ service_opts = [ cfg.IntOpt('backup_metadata_version', default=2, help='Backup metadata version to be used when backing up ' 'volume metadata. If this number is bumped, make sure the ' 'service doing the restore supports the new version.'), cfg.IntOpt('backup_object_number_per_notification', default=10, help='The number of chunks or objects, for which one ' 'Ceilometer notification will be sent'), cfg.IntOpt('backup_timer_interval', default=120, help='Interval, in seconds, between two progress notifications ' 'reporting the backup status'), ] CONF = cfg.CONF CONF.register_opts(service_opts) LOG = logging.getLogger(__name__) class BackupMetadataAPI(base.Base): TYPE_TAG_VOL_BASE_META = 'volume-base-metadata' TYPE_TAG_VOL_META = 'volume-metadata' TYPE_TAG_VOL_GLANCE_META = 'volume-glance-metadata' def __init__(self, context, db=None): super(BackupMetadataAPI, self).__init__(db) self.context = context self._key_mgr = None @staticmethod def _is_serializable(value): """Returns True if value is serializable.""" try: jsonutils.dumps(value) except TypeError: LOG.info("Value with type=%s is not serializable", type(value)) return False return True def _save_vol_base_meta(self, container, volume_id): """Save base volume metadata to container. This will fetch all fields from the db Volume object for volume_id and save them in the provided container dictionary. """ type_tag = self.TYPE_TAG_VOL_BASE_META LOG.debug("Getting metadata type '%s'", type_tag) meta = self.db.volume_get(self.context, volume_id) if meta: container[type_tag] = {} for key, value in meta: # Exclude fields that are "not JSON serializable" if not self._is_serializable(value): LOG.info("Unable to serialize field '%s' - excluding " "from backup", key) continue # NOTE(abishop): The backup manager is now responsible for # ensuring a copy of the volume's encryption key ID is # retained in case the volume is deleted. Yes, this means # the backup's volume base metadata now stores the volume's # original encryption key ID, which affects how things are # handled when backups are restored. The backup manager # handles this, too. container[type_tag][key] = value LOG.debug("Completed fetching metadata type '%s'", type_tag) else: LOG.debug("No metadata type '%s' available", type_tag) def _save_vol_meta(self, container, volume_id): """Save volume metadata to container. This will fetch all fields from the db VolumeMetadata object for volume_id and save them in the provided container dictionary. """ type_tag = self.TYPE_TAG_VOL_META LOG.debug("Getting metadata type '%s'", type_tag) meta = self.db.volume_metadata_get(self.context, volume_id) if meta: container[type_tag] = {} for entry in meta: # Exclude fields that are "not JSON serializable" if not self._is_serializable(meta[entry]): LOG.info("Unable to serialize field '%s' - excluding " "from backup", entry) continue container[type_tag][entry] = meta[entry] LOG.debug("Completed fetching metadata type '%s'", type_tag) else: LOG.debug("No metadata type '%s' available", type_tag) def _save_vol_glance_meta(self, container, volume_id): """Save volume Glance metadata to container. This will fetch all fields from the db VolumeGlanceMetadata object for volume_id and save them in the provided container dictionary. """ type_tag = self.TYPE_TAG_VOL_GLANCE_META LOG.debug("Getting metadata type '%s'", type_tag) try: meta = self.db.volume_glance_metadata_get(self.context, volume_id) if meta: container[type_tag] = {} for entry in meta: # Exclude fields that are "not JSON serializable" if not self._is_serializable(entry.value): LOG.info("Unable to serialize field '%s' - " "excluding from backup", entry) continue container[type_tag][entry.key] = entry.value LOG.debug("Completed fetching metadata type '%s'", type_tag) except exception.GlanceMetadataNotFound: LOG.debug("No metadata type '%s' available", type_tag) @staticmethod def _filter(metadata, fields, excludes=None): """Returns set of metadata restricted to required fields. If fields is empty list, the full set is returned. :param metadata: master set of metadata :param fields: list of fields we want to extract :param excludes: fields to be excluded :returns: filtered metadata """ if not fields: return metadata if not excludes: excludes = [] subset = {} for field in fields: if field in metadata and field not in excludes: subset[field] = metadata[field] else: LOG.debug("Excluding field '%s'", field) return subset def _restore_vol_base_meta(self, metadata, volume_id, fields): """Restore values to Volume object for provided fields.""" LOG.debug("Restoring volume base metadata") excludes = [] # Ignore unencrypted backups. key = 'encryption_key_id' if key in fields and key in metadata and metadata[key] is not None: self._restore_vol_encryption_meta(volume_id, metadata['volume_type_id']) # NOTE(dosaboy): if the target volume looks like it was auto-created # as part of this restore operation and we have a name to restore # then apply the name to the target volume. However, if that target # volume already existed and it has a name or we do not have a name to # restore, then ignore this key. This is intended to be a less drastic # solution than commit 7ee80f7. key = 'display_name' if key in fields and key in metadata: target_vol = self.db.volume_get(self.context, volume_id) name = target_vol.get(key, '') if (not metadata.get(key) or name and not name.startswith('restore_backup_')): excludes.append(key) excludes.append('display_description') metadata = self._filter(metadata, fields, excludes=excludes) self.db.volume_update(self.context, volume_id, metadata) def _restore_vol_encryption_meta(self, volume_id, src_volume_type_id): """Restores the volume_type_id for encryption if needed. Only allow restoration of an encrypted backup if the destination volume has the same volume type as the source volume. Otherwise encryption will not work. If volume types are already the same, no action is needed. """ dest_vol = self.db.volume_get(self.context, volume_id) if dest_vol['volume_type_id'] != src_volume_type_id: LOG.debug("Volume type id's do not match.") # If the volume types do not match, and the destination volume # does not have a volume type, force the destination volume # to have the encrypted volume type, provided it still exists. if dest_vol['volume_type_id'] is None: try: self.db.volume_type_get( self.context, src_volume_type_id) except exception.VolumeTypeNotFound: LOG.debug("Volume type of source volume has been " "deleted. Encrypted backup restore has " "failed.") msg = _("The source volume type '%s' is not " "available.") % (src_volume_type_id) raise exception.EncryptedBackupOperationFailed(msg) # Update dest volume with src volume's volume_type_id. LOG.debug("The volume type of the destination volume " "will become the volume type of the source " "volume.") self.db.volume_update(self.context, volume_id, {'volume_type_id': src_volume_type_id}) else: # Volume type id's do not match, and destination volume # has a volume type. Throw exception. LOG.warning("Destination volume type is different from " "source volume type for an encrypted volume. " "Encrypted backup restore has failed.") msg = (_("The source volume type '%(src)s' is different " "than the destination volume type '%(dest)s'.") % {'src': src_volume_type_id, 'dest': dest_vol['volume_type_id']}) raise exception.EncryptedBackupOperationFailed(msg) def _restore_vol_meta(self, metadata, volume_id, fields): """Restore values to VolumeMetadata object for provided fields.""" LOG.debug("Restoring volume metadata") metadata = self._filter(metadata, fields) self.db.volume_metadata_update(self.context, volume_id, metadata, True) def _restore_vol_glance_meta(self, metadata, volume_id, fields): """Restore values to VolumeGlanceMetadata object for provided fields. First delete any existing metadata then save new values. """ LOG.debug("Restoring volume glance metadata") metadata = self._filter(metadata, fields) self.db.volume_glance_metadata_delete_by_volume(self.context, volume_id) for key, value in metadata.items(): self.db.volume_glance_metadata_create(self.context, volume_id, key, value) # Now mark the volume as bootable self.db.volume_update(self.context, volume_id, {'bootable': True}) def _v1_restore_factory(self): """All metadata is backed up but we selectively restore. Returns a dictionary of the form: {<type tag>: (<restore function>, <fields list>)} Empty field list indicates that all backed up fields should be restored. """ return {self.TYPE_TAG_VOL_BASE_META: (self._restore_vol_base_meta, ['display_name', 'display_description']), self.TYPE_TAG_VOL_META: (self._restore_vol_meta, []), self.TYPE_TAG_VOL_GLANCE_META: (self._restore_vol_glance_meta, [])} def _v2_restore_factory(self): """All metadata is backed up but we selectively restore. Returns a dictionary of the form: {<type tag>: (<restore function>, <fields list>)} Empty field list indicates that all backed up fields should be restored. """ return {self.TYPE_TAG_VOL_BASE_META: (self._restore_vol_base_meta, ['display_name', 'display_description', 'encryption_key_id']), self.TYPE_TAG_VOL_META: (self._restore_vol_meta, []), self.TYPE_TAG_VOL_GLANCE_META: (self._restore_vol_glance_meta, [])} def get(self, volume_id): """Get volume metadata. Returns a json-encoded dict containing all metadata and the restore version i.e. the version used to decide what actually gets restored from this container when doing a backup restore. """ container = {'version': CONF.backup_metadata_version} self._save_vol_base_meta(container, volume_id) self._save_vol_meta(container, volume_id) self._save_vol_glance_meta(container, volume_id) if container: return jsonutils.dumps(container) else: return None def put(self, volume_id, json_metadata): """Restore volume metadata to a volume. The json container should contain a version that is supported here. """ meta_container = jsonutils.loads(json_metadata) version = meta_container['version'] if version == 1: factory = self._v1_restore_factory() elif version == 2: factory = self._v2_restore_factory() else: msg = (_("Unsupported backup metadata version (%s)") % (version)) raise exception.BackupMetadataUnsupportedVersion(msg) for type in factory: func = factory[type][0] fields = factory[type][1] if type in meta_container: func(meta_container[type], volume_id, fields) else: LOG.debug("No metadata of type '%s' to restore", type) @six.add_metaclass(abc.ABCMeta) class BackupDriver(base.Base): def __init__(self, context, db=None): super(BackupDriver, self).__init__(db) self.context = context self.backup_meta_api = BackupMetadataAPI(context, db) # This flag indicates if backup driver supports force # deletion. So it should be set to True if the driver that inherits # from BackupDriver supports the force deletion function. self.support_force_delete = False def get_metadata(self, volume_id): return self.backup_meta_api.get(volume_id) def put_metadata(self, volume_id, json_metadata): self.backup_meta_api.put(volume_id, json_metadata) @abc.abstractmethod def backup(self, backup, volume_file, backup_metadata=False): """Start a backup of a specified volume. Some I/O operations may block greenthreads, so in order to prevent starvation parameter volume_file will be a proxy that will execute all methods in native threads, so the method implementation doesn't need to worry about that.. """ return @abc.abstractmethod def restore(self, backup, volume_id, volume_file): """Restore a saved backup. Some I/O operations may block greenthreads, so in order to prevent starvation parameter volume_file will be a proxy that will execute all methods in native threads, so the method implementation doesn't need to worry about that.. """ return @abc.abstractmethod def delete_backup(self, backup): """Delete a saved backup.""" return def export_record(self, backup): """Export driver specific backup record information. If backup backend needs additional driver specific information to import backup record back into the system it must overwrite this method and return it here as a dictionary so it can be serialized into a string. Default backup driver implementation has no extra information. :param backup: backup object to export :returns: driver_info - dictionary with extra information """ return {} def import_record(self, backup, driver_info): """Import driver specific backup record information. If backup backend needs additional driver specific information to import backup record back into the system it must overwrite this method since it will be called with the extra information that was provided by export_record when exporting the backup. Default backup driver implementation does nothing since it didn't export any specific data in export_record. :param backup: backup object to export :param driver_info: dictionary with driver specific backup record information :returns: nothing """ return def check_for_setup_error(self): """Method for checking if backup backend is successfully installed.""" return @six.add_metaclass(abc.ABCMeta) class BackupDriverWithVerify(BackupDriver): @abc.abstractmethod def verify(self, backup): """Verify that the backup exists on the backend. Verify that the backup is OK, possibly following an import record operation. :param backup: backup id of the backup to verify :raises InvalidBackup, NotImplementedError: """ return
apache-2.0
lumig242/Hue-Integration-with-CDAP
desktop/core/ext-py/pycrypto-2.6.1/lib/Crypto/SelfTest/Random/OSRNG/test_winrandom.py
131
1777
# -*- coding: utf-8 -*- # # SelfTest/Util/test_winrandom.py: Self-test for the winrandom module # # Written in 2008 by Dwayne C. Litzenberger <dlitz@dlitz.net> # # =================================================================== # The contents of this file are dedicated to the public domain. To # the extent that dedication to the public domain is not available, # everyone is granted a worldwide, perpetual, royalty-free, # non-exclusive license to exercise all rights associated with the # contents of this file for any purpose whatsoever. # No rights are reserved. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, # EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND # NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS # BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN # ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN # CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE # SOFTWARE. # =================================================================== """Self-test suite for Crypto.Random.OSRNG.winrandom""" __revision__ = "$Id$" import unittest class SimpleTest(unittest.TestCase): def runTest(self): """Crypto.Random.OSRNG.winrandom""" # Import the winrandom module and try to use it from Crypto.Random.OSRNG import winrandom randobj = winrandom.new() x = randobj.get_bytes(16) y = randobj.get_bytes(16) self.assertNotEqual(x, y) def get_tests(config={}): return [SimpleTest()] if __name__ == '__main__': suite = lambda: unittest.TestSuite(get_tests()) unittest.main(defaultTest='suite') # vim:set ts=4 sw=4 sts=4 expandtab:
apache-2.0
mandeepdhami/nova
nova/scheduler/filters/num_instances_filter.py
56
2596
# Copyright (c) 2012 OpenStack Foundation # All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); you may # not use this file except in compliance with the License. You may obtain # a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, WITHOUT # WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the # License for the specific language governing permissions and limitations # under the License. from oslo_config import cfg from oslo_log import log as logging from nova.i18n import _LW from nova.scheduler import filters from nova.scheduler.filters import utils LOG = logging.getLogger(__name__) max_instances_per_host_opt = cfg.IntOpt("max_instances_per_host", default=50, help="Ignore hosts that have too many instances") CONF = cfg.CONF CONF.register_opt(max_instances_per_host_opt) class NumInstancesFilter(filters.BaseHostFilter): """Filter out hosts with too many instances.""" def _get_max_instances_per_host(self, host_state, filter_properties): return CONF.max_instances_per_host def host_passes(self, host_state, filter_properties): num_instances = host_state.num_instances max_instances = self._get_max_instances_per_host( host_state, filter_properties) passes = num_instances < max_instances if not passes: LOG.debug("%(host_state)s fails num_instances check: Max " "instances per host is set to %(max_instances)s", {'host_state': host_state, 'max_instances': max_instances}) return passes class AggregateNumInstancesFilter(NumInstancesFilter): """AggregateNumInstancesFilter with per-aggregate the max num instances. Fall back to global max_num_instances_per_host if no per-aggregate setting found. """ def _get_max_instances_per_host(self, host_state, filter_properties): aggregate_vals = utils.aggregate_values_from_key( host_state, 'max_instances_per_host') try: value = utils.validate_num_values( aggregate_vals, CONF.max_instances_per_host, cast_to=int) except ValueError as e: LOG.warning(_LW("Could not decode max_instances_per_host: '%s'"), e) value = CONF.max_instances_per_host return value
apache-2.0
mohamed--abdel-maksoud/chromium.src
third_party/typ/typ/tests/json_results_test.py
74
4342
# Copyright 2014 Dirk Pranke. All rights reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. import unittest from typ import json_results class TestMakeUploadRequest(unittest.TestCase): maxDiff = 4096 def test_basic_upload(self): results = json_results.ResultSet() full_results = json_results.make_full_results([], 0, [], results) url, content_type, data = json_results.make_upload_request( 'localhost', 'fake_builder_name', 'fake_master', 'fake_test_type', full_results) self.assertEqual( content_type, 'multipart/form-data; ' 'boundary=-J-S-O-N-R-E-S-U-L-T-S---B-O-U-N-D-A-R-Y-') self.assertEqual(url, 'http://localhost/testfile/upload') self.assertMultiLineEqual( data, ('---J-S-O-N-R-E-S-U-L-T-S---B-O-U-N-D-A-R-Y-\r\n' 'Content-Disposition: form-data; name="builder"\r\n' '\r\n' 'fake_builder_name\r\n' '---J-S-O-N-R-E-S-U-L-T-S---B-O-U-N-D-A-R-Y-\r\n' 'Content-Disposition: form-data; name="master"\r\n' '\r\n' 'fake_master\r\n' '---J-S-O-N-R-E-S-U-L-T-S---B-O-U-N-D-A-R-Y-\r\n' 'Content-Disposition: form-data; name="testtype"\r\n' '\r\n' 'fake_test_type\r\n' '---J-S-O-N-R-E-S-U-L-T-S---B-O-U-N-D-A-R-Y-\r\n' 'Content-Disposition: form-data; name="file"; ' 'filename="full_results.json"\r\n' 'Content-Type: application/json\r\n' '\r\n' '{"version": 3, "interrupted": false, "path_delimiter": ".", ' '"seconds_since_epoch": 0, ' '"num_failures_by_type": {"FAIL": 0, "PASS": 0, "SKIP": 0}, ' '"tests": {}}\r\n' '---J-S-O-N-R-E-S-U-L-T-S---B-O-U-N-D-A-R-Y---\r\n')) class TestMakeFullResults(unittest.TestCase): maxDiff = 2048 def test_basic(self): test_names = ['foo_test.FooTest.test_fail', 'foo_test.FooTest.test_pass', 'foo_test.FooTest.test_skip'] result_set = json_results.ResultSet() result_set.add( json_results.Result('foo_test.FooTest.test_fail', json_results.ResultType.Failure, 0, 0, 0, unexpected=True)) result_set.add(json_results.Result('foo_test.FooTest.test_pass', json_results.ResultType.Pass, 0, 0, 0)) result_set.add(json_results.Result('foo_test.FooTest.test_skip', json_results.ResultType.Skip, 0, 0, 0, unexpected=False)) full_results = json_results.make_full_results( ['foo=bar'], 0, test_names, result_set) expected_full_results = { 'foo': 'bar', 'interrupted': False, 'num_failures_by_type': { 'FAIL': 1, 'PASS': 1, 'SKIP': 1}, 'path_delimiter': '.', 'seconds_since_epoch': 0, 'tests': { 'foo_test': { 'FooTest': { 'test_fail': { 'expected': 'PASS', 'actual': 'FAIL', 'is_unexpected': True}, 'test_pass': { 'expected': 'PASS', 'actual': 'PASS'}, 'test_skip': { 'expected': 'SKIP', 'actual': 'SKIP'}}}}, 'version': 3} self.assertEqual(full_results, expected_full_results)
bsd-3-clause
llllllllll/cytoolz
cytoolz/tests/test_functoolz.py
2
12054
import platform from cytoolz.functoolz import (thread_first, thread_last, memoize, curry, compose, pipe, complement, do, juxt) from cytoolz.functoolz import _num_required_args from operator import add, mul, itemgetter from cytoolz.utils import raises from functools import partial from cytoolz.compatibility import reduce, PY3 def iseven(x): return x % 2 == 0 def isodd(x): return x % 2 == 1 def inc(x): return x + 1 def double(x): return 2 * x def test_thread_first(): assert thread_first(2) == 2 assert thread_first(2, inc) == 3 assert thread_first(2, inc, inc) == 4 assert thread_first(2, double, inc) == 5 assert thread_first(2, (add, 5), double) == 14 def test_thread_last(): assert list(thread_last([1, 2, 3], (map, inc), (filter, iseven))) == [2, 4] assert list(thread_last([1, 2, 3], (map, inc), (filter, isodd))) == [3] assert thread_last(2, (add, 5), double) == 14 def test_memoize(): fn_calls = [0] # Storage for side effects def f(x, y): """ A docstring """ fn_calls[0] += 1 return x + y mf = memoize(f) assert mf(2, 3) == mf(2, 3) assert fn_calls == [1] # function was only called once assert mf.__doc__ == f.__doc__ assert raises(TypeError, lambda: mf(1, {})) def test_memoize_kwargs(): fn_calls = [0] # Storage for side effects def f(x, y=0): return x + y mf = memoize(f) assert mf(1) == f(1) assert mf(1, 2) == f(1, 2) assert mf(1, y=2) == f(1, y=2) assert mf(1, y=3) == f(1, y=3) def test_memoize_curried(): @curry def f(x, y=0): return x + y f2 = f(y=1) fm2 = memoize(f2) assert fm2(3) == f2(3) assert fm2(3) == f2(3) def test_memoize_partial(): def f(x, y=0): return x + y f2 = partial(f, y=1) fm2 = memoize(f2) assert fm2(3) == f2(3) assert fm2(3) == f2(3) def test_memoize_key_signature(): # Single argument should not be tupled as a key. No keywords. mf = memoize(lambda x: False, cache={1: True}) assert mf(1) is True assert mf(2) is False # Single argument must be tupled if signature has varargs. No keywords. mf = memoize(lambda x, *args: False, cache={(1,): True, (1, 2): 2}) assert mf(1) is True assert mf(2) is False assert mf(1, 1) is False assert mf(1, 2) == 2 assert mf((1, 2)) is False # More than one argument is always tupled. No keywords. mf = memoize(lambda x, y: False, cache={(1, 2): True}) assert mf(1, 2) is True assert mf(1, 3) is False assert raises(TypeError, lambda: mf((1, 2))) # Nullary function (no inputs) uses empty tuple as the key mf = memoize(lambda: False, cache={(): True}) assert mf() is True # Single argument must be tupled if there are keyword arguments, because # keyword arguments may be passed as unnamed args. mf = memoize(lambda x, y=0: False, cache={((1,), frozenset((('y', 2),))): 2, ((1, 2), None): 3}) assert mf(1, y=2) == 2 assert mf(1, 2) == 3 assert mf(2, y=2) is False assert mf(2, 2) is False assert mf(1) is False assert mf((1, 2)) is False # Keyword-only signatures must still have an "args" tuple. mf = memoize(lambda x=0: False, cache={(None, frozenset((('x', 1),))): 1, ((1,), None): 2}) assert mf() is False assert mf(x=1) == 1 assert mf(1) == 2 def test_memoize_curry_cache(): @memoize(cache={1: True}) def f(x): return False assert f(1) is True assert f(2) is False def test_memoize_key(): @memoize(key=lambda args, kwargs: args[0]) def f(x, y, *args, **kwargs): return x + y assert f(1, 2) == 3 assert f(1, 3) == 3 def test_curry_simple(): cmul = curry(mul) double = cmul(2) assert callable(double) assert double(10) == 20 assert repr(cmul) == repr(mul) cmap = curry(map) assert list(cmap(inc)([1, 2, 3])) == [2, 3, 4] assert raises(TypeError, lambda: curry()) assert raises(TypeError, lambda: curry({1: 2})) def test_curry_kwargs(): def f(a, b, c=10): return (a + b) * c f = curry(f) assert f(1, 2, 3) == 9 assert f(1)(2, 3) == 9 assert f(1, 2) == 30 assert f(1, c=3)(2) == 9 assert f(c=3)(1, 2) == 9 def g(a=1, b=10, c=0): return a + b + c cg = curry(g, b=2) assert cg() == 3 assert cg(b=3) == 4 assert cg(a=0) == 2 assert cg(a=0, b=1) == 1 assert cg(0) == 2 # pass "a" as arg, not kwarg assert raises(TypeError, lambda: cg(1, 2)) # pass "b" as arg AND kwarg def h(x, func=int): return func(x) if platform.python_implementation() != 'PyPy'\ or platform.python_version_tuple()[0] != '3': # Bug on PyPy3<2.5 # __init__ must not pick func as positional arg assert curry(h)(0.0) == 0 assert curry(h)(func=str)(0.0) == '0.0' assert curry(h, func=str)(0.0) == '0.0' def test_curry_passes_errors(): @curry def f(a, b): if not isinstance(a, int): raise TypeError() return a + b assert f(1, 2) == 3 assert raises(TypeError, lambda: f('1', 2)) assert raises(TypeError, lambda: f('1')(2)) assert raises(TypeError, lambda: f(1, 2, 3)) def test_curry_docstring(): def f(x, y): """ A docstring """ return x g = curry(f) assert g.__doc__ == f.__doc__ assert str(g) == str(f) assert f(1, 2) == g(1, 2) def test_curry_is_like_partial(): def foo(a, b, c=1): return a + b + c p, c = partial(foo, 1, c=2), curry(foo)(1, c=2) assert p.keywords == c.keywords assert p.args == c.args assert p(3) == c(3) p, c = partial(foo, 1), curry(foo)(1) assert p.keywords == c.keywords assert p.args == c.args assert p(3) == c(3) assert p(3, c=2) == c(3, c=2) p, c = partial(foo, c=1), curry(foo)(c=1) assert p.keywords == c.keywords assert p.args == c.args assert p(1, 2) == c(1, 2) def test_curry_is_idempotent(): def foo(a, b, c=1): return a + b + c f = curry(foo, 1, c=2) g = curry(f) assert isinstance(f, curry) assert isinstance(g, curry) assert not isinstance(g.func, curry) assert not hasattr(g.func, 'func') assert f.func == g.func assert f.args == g.args assert f.keywords == g.keywords def test_curry_attributes_readonly(): def foo(a, b, c=1): return a + b + c f = curry(foo, 1, c=2) assert raises(AttributeError, lambda: setattr(f, 'args', (2,))) assert raises(AttributeError, lambda: setattr(f, 'keywords', {'c': 3})) assert raises(AttributeError, lambda: setattr(f, 'func', f)) def test_curry_attributes_writable(): def foo(a, b, c=1): return a + b + c f = curry(foo, 1, c=2) f.__name__ = 'newname' f.__doc__ = 'newdoc' assert f.__name__ == 'newname' assert f.__doc__ == 'newdoc' if hasattr(f, 'func_name'): assert f.__name__ == f.func_name def test_curry_comparable(): def foo(a, b, c=1): return a + b + c f1 = curry(foo, 1, c=2) f2 = curry(foo, 1, c=2) g1 = curry(foo, 1, c=3) h1 = curry(foo, c=2) h2 = h1(c=2) h3 = h1() assert f1 == f2 assert not (f1 != f2) assert f1 != g1 assert not (f1 == g1) assert f1 != h1 assert h1 == h2 assert h1 == h3 # test function comparison works def bar(a, b, c=1): return a + b + c b1 = curry(bar, 1, c=2) assert b1 != f1 assert set([f1, f2, g1, h1, h2, h3, b1, b1()]) == set([f1, g1, h1, b1]) # test unhashable input unhash1 = curry(foo, []) assert raises(TypeError, lambda: hash(unhash1)) unhash2 = curry(foo, c=[]) assert raises(TypeError, lambda: hash(unhash2)) def test_curry_doesnot_transmogrify(): # Early versions of `curry` transmogrified to `partial` objects if # only one positional argument remained even if keyword arguments # were present. Now, `curry` should always remain `curry`. def f(x, y=0): return x + y cf = curry(f) assert cf(y=1)(y=2)(y=3)(1) == f(1, 3) def test_curry_on_classmethods(): class A(object): BASE = 10 def __init__(self, base): self.BASE = base @curry def addmethod(self, x, y): return self.BASE + x + y @classmethod @curry def addclass(cls, x, y): return cls.BASE + x + y @staticmethod @curry def addstatic(x, y): return x + y a = A(100) assert a.addmethod(3, 4) == 107 assert a.addmethod(3)(4) == 107 assert A.addmethod(a, 3, 4) == 107 assert A.addmethod(a)(3)(4) == 107 assert a.addclass(3, 4) == 17 assert a.addclass(3)(4) == 17 assert A.addclass(3, 4) == 17 assert A.addclass(3)(4) == 17 assert a.addstatic(3, 4) == 7 assert a.addstatic(3)(4) == 7 assert A.addstatic(3, 4) == 7 assert A.addstatic(3)(4) == 7 # we want this to be of type curry assert isinstance(a.addmethod, curry) assert isinstance(A.addmethod, curry) def test_memoize_on_classmethods(): class A(object): BASE = 10 HASH = 10 def __init__(self, base): self.BASE = base @memoize def addmethod(self, x, y): return self.BASE + x + y @classmethod @memoize def addclass(cls, x, y): return cls.BASE + x + y @staticmethod @memoize def addstatic(x, y): return x + y def __hash__(self): return self.HASH a = A(100) assert a.addmethod(3, 4) == 107 assert A.addmethod(a, 3, 4) == 107 a.BASE = 200 assert a.addmethod(3, 4) == 107 a.HASH = 200 assert a.addmethod(3, 4) == 207 assert a.addclass(3, 4) == 17 assert A.addclass(3, 4) == 17 A.BASE = 20 assert A.addclass(3, 4) == 17 A.HASH = 20 # hashing of class is handled by metaclass assert A.addclass(3, 4) == 17 # hence, != 27 assert a.addstatic(3, 4) == 7 assert A.addstatic(3, 4) == 7 def test__num_required_args(): assert _num_required_args(map) != 0 assert _num_required_args(lambda x: x) == 1 assert _num_required_args(lambda x, y: x) == 2 def foo(x, y, z=2): pass assert _num_required_args(foo) == 2 def test_compose(): assert compose()(0) == 0 assert compose(inc)(0) == 1 assert compose(double, inc)(0) == 2 assert compose(str, iseven, inc, double)(3) == "False" assert compose(str, add)(1, 2) == '3' def f(a, b, c=10): return (a + b) * c assert compose(str, inc, f)(1, 2, c=3) == '10' def test_pipe(): assert pipe(1, inc) == 2 assert pipe(1, inc, inc) == 3 assert pipe(1, double, inc, iseven) is False def test_complement(): # No args: assert complement(lambda: False)() assert not complement(lambda: True)() # Single arity: assert complement(iseven)(1) assert not complement(iseven)(2) assert complement(complement(iseven))(2) assert not complement(complement(isodd))(2) # Multiple arities: both_even = lambda a, b: iseven(a) and iseven(b) assert complement(both_even)(1, 2) assert not complement(both_even)(2, 2) # Generic truthiness: assert complement(lambda: "")() assert complement(lambda: 0)() assert complement(lambda: None)() assert complement(lambda: [])() assert not complement(lambda: "x")() assert not complement(lambda: 1)() assert not complement(lambda: [1])() def test_do(): inc = lambda x: x + 1 assert do(inc, 1) == 1 log = [] assert do(log.append, 1) == 1 assert log == [1] def test_juxt_generator_input(): data = list(range(10)) juxtfunc = juxt(itemgetter(2*i) for i in range(5)) assert juxtfunc(data) == (0, 2, 4, 6, 8) assert juxtfunc(data) == (0, 2, 4, 6, 8)
bsd-3-clause
danieljaouen/ansible
test/runner/lib/cloud/openshift.py
46
7381
"""OpenShift plugin for integration tests.""" from __future__ import absolute_import, print_function import json import os import re import time from lib.cloud import ( CloudProvider, CloudEnvironment, ) from lib.util import ( find_executable, ApplicationError, display, SubprocessError, ) from lib.http import ( HttpClient, ) from lib.docker_util import ( docker_exec, docker_run, docker_rm, docker_inspect, docker_pull, docker_network_inspect, get_docker_container_id, ) class OpenShiftCloudProvider(CloudProvider): """OpenShift cloud provider plugin. Sets up cloud resources before delegation.""" DOCKER_CONTAINER_NAME = 'openshift-origin' def __init__(self, args): """ :type args: TestConfig """ super(OpenShiftCloudProvider, self).__init__(args, config_extension='.kubeconfig') # The image must be pinned to a specific version to guarantee CI passes with the version used. self.image = 'openshift/origin:v3.7.1' self.container_name = '' def filter(self, targets, exclude): """Filter out the cloud tests when the necessary config and resources are not available. :type targets: tuple[TestTarget] :type exclude: list[str] """ if os.path.isfile(self.config_static_path): return docker = find_executable('docker', required=False) if docker: return skip = 'cloud/%s/' % self.platform skipped = [target.name for target in targets if skip in target.aliases] if skipped: exclude.append(skip) display.warning('Excluding tests marked "%s" which require the "docker" command or config (see "%s"): %s' % (skip.rstrip('/'), self.config_template_path, ', '.join(skipped))) def setup(self): """Setup the cloud resource before delegation and register a cleanup callback.""" super(OpenShiftCloudProvider, self).setup() if self._use_static_config(): self._setup_static() else: self._setup_dynamic() def get_remote_ssh_options(self): """Get any additional options needed when delegating tests to a remote instance via SSH. :rtype: list[str] """ if self.managed: return ['-R', '8443:localhost:8443'] return [] def get_docker_run_options(self): """Get any additional options needed when delegating tests to a docker container. :rtype: list[str] """ if self.managed: return ['--link', self.DOCKER_CONTAINER_NAME] return [] def cleanup(self): """Clean up the cloud resource and any temporary configuration files after tests complete.""" if self.container_name: docker_rm(self.args, self.container_name) super(OpenShiftCloudProvider, self).cleanup() def _setup_static(self): """Configure OpenShift tests for use with static configuration.""" with open(self.config_static_path, 'r') as config_fd: config = config_fd.read() match = re.search(r'^ *server: (?P<server>.*)$', config, flags=re.MULTILINE) if match: endpoint = match.group('server') self._wait_for_service(endpoint) else: display.warning('Could not find OpenShift endpoint in kubeconfig. Skipping check for OpenShift service availability.') def _setup_dynamic(self): """Create a OpenShift container using docker.""" self.container_name = self.DOCKER_CONTAINER_NAME results = docker_inspect(self.args, self.container_name) if results and not results[0]['State']['Running']: docker_rm(self.args, self.container_name) results = [] if results: display.info('Using the existing OpenShift docker container.', verbosity=1) else: display.info('Starting a new OpenShift docker container.', verbosity=1) docker_pull(self.args, self.image) cmd = ['start', 'master', '--listen', 'https://0.0.0.0:8443'] docker_run(self.args, self.image, ['-d', '-p', '8443:8443', '--name', self.container_name], cmd) container_id = get_docker_container_id() if container_id: display.info('Running in docker container: %s' % container_id, verbosity=1) host = self._get_container_address() display.info('Found OpenShift container address: %s' % host, verbosity=1) else: host = 'localhost' port = 8443 endpoint = 'https://%s:%s/' % (host, port) self._wait_for_service(endpoint) if self.args.explain: config = '# Unknown' else: if self.args.docker: host = self.DOCKER_CONTAINER_NAME server = 'https://%s:%s' % (host, port) config = self._get_config(server) self._write_config(config) def _get_container_address(self): networks = docker_network_inspect(self.args, 'bridge') try: bridge = [network for network in networks if network['Name'] == 'bridge'][0] containers = bridge['Containers'] container = [containers[container] for container in containers if containers[container]['Name'] == self.DOCKER_CONTAINER_NAME][0] return re.sub(r'/[0-9]+$', '', container['IPv4Address']) except Exception: display.error('Failed to process the following docker network inspect output:\n%s' % json.dumps(networks, indent=4, sort_keys=True)) raise def _wait_for_service(self, endpoint): """Wait for the OpenShift service endpoint to accept connections. :type endpoint: str """ if self.args.explain: return client = HttpClient(self.args, always=True, insecure=True) endpoint = endpoint for dummy in range(1, 30): display.info('Waiting for OpenShift service: %s' % endpoint, verbosity=1) try: client.get(endpoint) return except SubprocessError: pass time.sleep(10) raise ApplicationError('Timeout waiting for OpenShift service.') def _get_config(self, server): """Get OpenShift config from container. :type server: str :rtype: dict[str, str] """ cmd = ['cat', '/var/lib/origin/openshift.local.config/master/admin.kubeconfig'] stdout, dummy = docker_exec(self.args, self.container_name, cmd, capture=True) config = stdout config = re.sub(r'^( *)certificate-authority-data: .*$', r'\1insecure-skip-tls-verify: true', config, flags=re.MULTILINE) config = re.sub(r'^( *)server: .*$', r'\1server: %s' % server, config, flags=re.MULTILINE) return config class OpenShiftCloudEnvironment(CloudEnvironment): """OpenShift cloud environment plugin. Updates integration test environment after delegation.""" def configure_environment(self, env, cmd): """ :type env: dict[str, str] :type cmd: list[str] """ changes = dict( K8S_AUTH_KUBECONFIG=self.config_path, ) env.update(changes)
gpl-3.0
rory/SystemAutopsy
system_autopsy/default_components.py
1
1244
from utils import * class Basics(Component): @bash_command def disk_usage(self): return "df" @bash_command def open_files(self): return 'lsof' @bash_command def memory_usage(self): return "free" class Apache(Component): @bash_command def running_procs(self): return "ps -p $(pgrep -u www-data) 2>/dev/null" @iterate_on(pids_matching('-u www-data')) @takes_own_filename def strace_wsgi(self, pid, filename): return "timeout 10s strace -o {filename} -f -p {pid}".format(filename=filename, pid=pid) class Network(Component): @bash_command def open_connections_lsof(self): return "lsof -i" @bash_command def netstat_connections(self): return 'netstat -nt' @bash_command def ifconfig(self): return 'ifconfig -a' @bash_command def ip_link_show(self): return 'ip link show' class MySQL(Component): @bash_command def running(self): return "ps -fp $(pgrep -u mysql)" @iterate_on(pids_matching('-u mysql')) @takes_own_filename def strace_mysqld(self, pid, filename): return "timeout 10s strace -o {filename} -f -p {pid}".format(filename=filename, pid=pid)
gpl-3.0
AlmostBetterNetwork/podmaster-host
analytics/management/commands/analytics_adjustment.py
3
2353
import json from django.core.management.base import BaseCommand from accounts.models import UserSettings from accounts.payment_plans import PLAN_DEMO from pinecast.email import send_notification_email from podcasts.models import Podcast MESSAGE_INCREASE = ''' We recently performed an audit of our analytics database. In the process, {count} listens that were previously flagged as originating from a bot or as non-genuine listens were un-flagged. This will cause your listen counts to increase for {title}. This adjustment was performed as we refine our filters. We perform adjustments like this periodically as a way to provide the most accurate analytics possible. Periodic audits allow Pinecast analytics to remain IAB-compliant. If you have questions or concerns, please contact Pinecast support. '''.strip() MESSAGE_DECREASE = ''' We recently performed an audit of our analytics database. In the process, {count} listens were flagged as originating from a bot or were marked as junk. This will cause your listen counts to decrease for {title}. We perform adjustments like this periodically as a way to provide the most accurate analytics possible. Periodic audits allow Pinecast analytics to remain IAB-compliant. If you have questions or concerns, please contact Pinecast support. '''.strip() class Command(BaseCommand): help = 'Alerts podcast owners about analytics adjustments' def add_arguments(self, parser): parser.add_argument('--data', action='store', dest='data', help='The audit output') def handle(self, **options): parsed = json.loads(options['data']) for pod_id, count in parsed.items(): if -10 < count < 10: continue try: pod = Podcast.objects.get(id=pod_id) except Podcast.DoesNotExist: continue us = UserSettings.get_from_user(pod.owner) if us.plan == PLAN_DEMO: continue send_notification_email( user=pod.owner, subject='Pinecast analytics adjustment', description=( MESSAGE_DECREASE if count > 0 else MESSAGE_INCREASE ).format(count=count, title=pod.name), ) self.stdout.write('Sent email to {} for {}'.format(pod.owner.email, count))
apache-2.0
Iolaum/MongoDB_CW
myScripts/Question5+7.py
1
1175
from __future__ import division from pymongo import MongoClient """ Question 5: What is the mean length of a message? Question 7: What is the average number of hashtags (#) used within a message? """ # import pymongo client = MongoClient('localhost', 27017) if client is None: print "Couldn't connect!" else: print ("Connected.") dbc = client.mongo1.microblogging # ... cursor = dbc.find()#.limit(150000) textLength = 0 hashtags = 0 notAString = 0 dummyVar = 0 badLength = 0 badhashtags = 0 for i in cursor: # print len(i["text"]), i["text"].count('#') if isinstance(i["text"], basestring): # str textLength += len(i["text"]) hashtags += i["text"].count('#') else: # print i notAString += 1 dummyVar = str(i["text"]) badLength += len(dummyVar) badhashtags += dummyVar.count('#') print textLength print hashtags print notAString print badLength print badhashtags tl = textLength + badLength docs = 1459434 tavg = tl/docs havg = hashtags /docs print tavg print havg client.close() print "Disconnected." """ Results (basestring): 1041765534 454656 45 162 0 1459434 """
gpl-2.0
ojengwa/odoo
addons/sale_stock/res_config.py
331
5235
# -*- coding: utf-8 -*- ############################################################################## # # OpenERP, Open Source Business Applications # Copyright (C) 2004-2012 OpenERP S.A. (<http://openerp.com>). # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as # published by the Free Software Foundation, either version 3 of the # License, or (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU Affero General Public License for more details. # # You should have received a copy of the GNU Affero General Public License # along with this program. If not, see <http://www.gnu.org/licenses/>. # ############################################################################## import openerp from openerp import SUPERUSER_ID from openerp.osv import fields, osv from openerp.tools.translate import _ class sale_configuration(osv.osv_memory): _inherit = 'sale.config.settings' _columns = { 'group_invoice_deli_orders': fields.boolean('Generate invoices after and based on delivery orders', implied_group='sale_stock.group_invoice_deli_orders', help="To allow your salesman to make invoices for Delivery Orders using the menu 'Deliveries to Invoice'."), 'task_work': fields.boolean("Prepare invoices based on task's activities", help='Lets you transfer the entries under tasks defined for Project Management to ' 'the Timesheet line entries for particular date and particular user with the effect of creating, editing and deleting either ways ' 'and to automatically creates project tasks from procurement lines.\n' '-This installs the modules project_timesheet and sale_service.'), 'default_order_policy': fields.selection( [('manual', 'Invoice based on sales orders'), ('picking', 'Invoice based on deliveries')], 'The default invoicing method is', default_model='sale.order', help="You can generate invoices based on sales orders or based on shippings."), 'module_delivery': fields.boolean('Allow adding shipping costs', help='Allows you to add delivery methods in sales orders and delivery orders.\n' 'You can define your own carrier and delivery grids for prices.\n' '-This installs the module delivery.'), 'default_picking_policy' : fields.boolean("Deliver all at once when all products are available.", help = "Sales order by default will be configured to deliver all products at once instead of delivering each product when it is available. This may have an impact on the shipping price."), 'group_mrp_properties': fields.boolean('Product properties on order lines', implied_group='sale.group_mrp_properties', help="Allows you to tag sales order lines with properties."), 'module_project_timesheet': fields.boolean("Project Timesheet"), 'module_sale_service': fields.boolean("Sale Service"), 'group_route_so_lines': fields.boolean('Choose MTO, drop shipping,... on sales order lines', implied_group='sale_stock.group_route_so_lines', help="Allows you to choose a delivery route on sales order lines"), } _defaults = { 'default_order_policy': 'manual', } def default_get(self, cr, uid, fields, context=None): res = super(sale_configuration, self).default_get(cr, uid, fields, context) # task_work, time_unit depend on other fields res['task_work'] = res.get('module_sale_service') and res.get('module_project_timesheet') return res def get_default_sale_config(self, cr, uid, ids, context=None): ir_values = self.pool.get('ir.values') default_picking_policy = ir_values.get_default(cr, uid, 'sale.order', 'picking_policy') return { 'default_picking_policy': default_picking_policy == 'one', } def set_sale_defaults(self, cr, uid, ids, context=None): if uid != SUPERUSER_ID and not self.pool['res.users'].has_group(cr, uid, 'base.group_erp_manager'): raise openerp.exceptions.AccessError(_("Only administrators can change the settings")) ir_values = self.pool.get('ir.values') wizard = self.browse(cr, uid, ids)[0] default_picking_policy = 'one' if wizard.default_picking_policy else 'direct' ir_values.set_default(cr, SUPERUSER_ID, 'sale.order', 'picking_policy', default_picking_policy) res = super(sale_configuration, self).set_sale_defaults(cr, uid, ids, context) return res def onchange_invoice_methods(self, cr, uid, ids, group_invoice_so_lines, group_invoice_deli_orders, context=None): if not group_invoice_deli_orders: return {'value': {'default_order_policy': 'manual'}} if not group_invoice_so_lines: return {'value': {'default_order_policy': 'picking'}} return {}
agpl-3.0
peguin40/zulip
analytics/management/commands/analyze_mit.py
12
3811
from __future__ import absolute_import from __future__ import print_function from typing import Any from optparse import make_option from django.core.management.base import BaseCommand, CommandParser from zerver.models import Recipient, Message from zerver.lib.timestamp import timestamp_to_datetime import datetime import time import logging def compute_stats(log_level): # type: (int) -> None logger = logging.getLogger() logger.setLevel(log_level) one_week_ago = timestamp_to_datetime(time.time()) - datetime.timedelta(weeks=1) mit_query = Message.objects.filter(sender__realm__domain="mit.edu", recipient__type=Recipient.STREAM, pub_date__gt=one_week_ago) for bot_sender_start in ["imap.", "rcmd.", "sys."]: mit_query = mit_query.exclude(sender__email__startswith=(bot_sender_start)) # Filtering for "/" covers tabbott/extra@ and all the daemon/foo bots. mit_query = mit_query.exclude(sender__email__contains=("/")) mit_query = mit_query.exclude(sender__email__contains=("aim.com")) mit_query = mit_query.exclude( sender__email__in=["rss@mit.edu", "bash@mit.edu", "apache@mit.edu", "bitcoin@mit.edu", "lp@mit.edu", "clocks@mit.edu", "root@mit.edu", "nagios@mit.edu", "www-data|local-realm@mit.edu"]) user_counts = {} # type: Dict[str, Dict[str, int]] for m in mit_query.select_related("sending_client", "sender"): email = m.sender.email user_counts.setdefault(email, {}) user_counts[email].setdefault(m.sending_client.name, 0) user_counts[email][m.sending_client.name] += 1 total_counts = {} # type: Dict[str, int] total_user_counts = {} # type: Dict[str, int] for email, counts in user_counts.items(): total_user_counts.setdefault(email, 0) for client_name, count in counts.items(): total_counts.setdefault(client_name, 0) total_counts[client_name] += count total_user_counts[email] += count logging.debug("%40s | %10s | %s" % ("User", "Messages", "Percentage Zulip")) top_percents = {} # type: Dict[int, float] for size in [10, 25, 50, 100, 200, len(total_user_counts.keys())]: top_percents[size] = 0.0 for i, email in enumerate(sorted(total_user_counts.keys(), key=lambda x: -total_user_counts[x])): percent_zulip = round(100 - (user_counts[email].get("zephyr_mirror", 0)) * 100. / total_user_counts[email], 1) for size in top_percents.keys(): top_percents.setdefault(size, 0) if i < size: top_percents[size] += (percent_zulip * 1.0 / size) logging.debug("%40s | %10s | %s%%" % (email, total_user_counts[email], percent_zulip)) logging.info("") for size in sorted(top_percents.keys()): logging.info("Top %6s | %s%%" % (size, round(top_percents[size], 1))) grand_total = sum(total_counts.values()) print(grand_total) logging.info("%15s | %s" % ("Client", "Percentage")) for client in total_counts.keys(): logging.info("%15s | %s%%" % (client, round(100. * total_counts[client] / grand_total, 1))) class Command(BaseCommand): help = "Compute statistics on MIT Zephyr usage." def add_arguments(self, parser): # type: (CommandParser) -> None parser.add_argument('--verbose', default=False, action='store_true') def handle(self, *args, **options): # type: (*Any, **Any) -> None level = logging.INFO if options["verbose"]: level = logging.DEBUG compute_stats(level)
apache-2.0
foxdog-studios/pyddp
ddp/messages/__init__.py
1
1052
# -*- coding: utf-8 -*- # Copyright 2014 Foxdog Studios # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. from __future__ import absolute_import from __future__ import division from __future__ import print_function from .message import * from .message_parser import * from .message_serializer import * from .ping_message import * from .ping_message_parser import * from .ping_message_serializer import * from .pong_message import * from .pong_message_parser import * from .pong_message_serializer import* from .client import * from .server import *
apache-2.0
chfoo/warcat
warcat/tool_test.py
1
2743
from warcat.tool import ListTool, VerifyTool, SplitTool, ExtractTool, ConcatTool import glob import os.path import tempfile import unittest class TestTool(unittest.TestCase): test_dir = os.path.join('example') def test_list(self): tool = ListTool([os.path.join(self.test_dir, 'at.warc')]) tool.process() def test_verify(self): tool = VerifyTool([os.path.join(self.test_dir, 'at.warc')], preserve_block=False) tool.process() self.assertEqual(1, tool.problems) def test_split(self): with tempfile.TemporaryDirectory() as temp_dir: tool = SplitTool([os.path.join(self.test_dir, 'at.warc')], out_dir=temp_dir) tool.process() self.assertEqual(8, len(os.listdir(temp_dir))) def test_extract(self): with tempfile.TemporaryDirectory() as temp_dir: tool = ExtractTool([os.path.join(self.test_dir, 'at.warc')], out_dir=temp_dir, preserve_block=False) tool.process() self.assertEqual(1, len( glob.glob(os.path.join(temp_dir, '*', '*index*')))) def test_extract_long_url(self): with tempfile.TemporaryDirectory() as temp_dir: tool = ExtractTool([os.path.join(self.test_dir, 'long_url.warc')], out_dir=temp_dir, preserve_block=False) tool.process() self.assertEqual(1, len( glob.glob(os.path.join(temp_dir, '*', '*index*')))) files = list(glob.glob(os.path.join(temp_dir, '*', '*index*'))) filename = files[0].rsplit('/', 1)[-1] self.assertLess(len(filename), 180) def test_extract_bad_http_chunked_content(self): with tempfile.TemporaryDirectory() as temp_dir: tool = ExtractTool([os.path.join(self.test_dir, 'bad_http_chunked_content.warc')], out_dir=temp_dir, preserve_block=False) tool.process() self.assertEqual(1, len( glob.glob(os.path.join(temp_dir, '*', '*index*')))) def test_extract_not_utf8_http_header(self): with tempfile.TemporaryDirectory() as temp_dir: tool = ExtractTool([os.path.join(self.test_dir, 'not_utf8_http_header.warc')], out_dir=temp_dir, preserve_block=False) tool.process() def test_concat(self): with tempfile.NamedTemporaryFile() as f: tool = ConcatTool([os.path.join(self.test_dir, 'at.warc')], out_file=f) tool.process() f.seek(0) tool = VerifyTool([f.name], preserve_block=False) tool.process() self.assertEqual(1, tool.problems)
gpl-3.0
jnovinger/django
django/contrib/gis/shortcuts.py
388
1209
import zipfile from io import BytesIO from django.conf import settings from django.http import HttpResponse from django.template import loader # NumPy supported? try: import numpy except ImportError: numpy = False def compress_kml(kml): "Returns compressed KMZ from the given KML string." kmz = BytesIO() zf = zipfile.ZipFile(kmz, 'a', zipfile.ZIP_DEFLATED) zf.writestr('doc.kml', kml.encode(settings.DEFAULT_CHARSET)) zf.close() kmz.seek(0) return kmz.read() def render_to_kml(*args, **kwargs): "Renders the response as KML (using the correct MIME type)." return HttpResponse(loader.render_to_string(*args, **kwargs), content_type='application/vnd.google-earth.kml+xml') def render_to_kmz(*args, **kwargs): """ Compresses the KML content and returns as KMZ (using the correct MIME type). """ return HttpResponse(compress_kml(loader.render_to_string(*args, **kwargs)), content_type='application/vnd.google-earth.kmz') def render_to_text(*args, **kwargs): "Renders the response using the MIME type for plain text." return HttpResponse(loader.render_to_string(*args, **kwargs), content_type='text/plain')
bsd-3-clause
DIRACGrid/DIRAC
src/DIRAC/Resources/Storage/test/FIXME_Test_StoragePlugIn.py
2
34041
#! /usr/bin/env python # FIXME: if it requires a dirac.cfg it is not a unit test and should be moved to tests directory from __future__ import print_function from __future__ import absolute_import from __future__ import division import unittest import time import os import shutil import sys import six from DIRAC.Core.Base.Script import parseCommandLine, getPositionalArgs parseCommandLine() from DIRAC.Resources.Storage.StorageFactory import StorageFactory from DIRAC.Core.Utilities.File import getSize positionalArgs = getPositionalArgs() __RCSID__ = "$Id$" if len(positionalArgs) < 2: print('Usage: TestStoragePlugIn.py StorageElement plugin') sys.exit() else: storageElementToTest = positionalArgs[0] plugin = positionalArgs[1] class StoragePlugInTestCase(unittest.TestCase): """ Base class for the StoragePlugin test cases """ def setUp(self): factory = StorageFactory('lhcb') res = factory.getStorages(storageElementToTest, [plugin]) self.assertTrue(res['OK']) storageDetails = res['Value'] self.storage = storageDetails['StorageObjects'][0] self.storage.changeDirectory('lhcb/test/unit-test/TestStoragePlugIn') destDir = self.storage.getCurrentURL('')['Value'] res = self.storage.createDirectory(destDir) self.assertTrue(res['OK']) self.assertTrue(destDir in res['Value']['Successful']) self.assertTrue(res['Value']['Successful'][destDir]) self.numberOfFiles = 1 def tearDown(self): remoteDir = self.storage.getCurrentURL('')['Value'] _ = self.storage.removeDirectory(remoteDir, True) class DirectoryTestCase(StoragePlugInTestCase): def test_putRemoveDirectory(self): print('\n\n#########################################################' '################\n\n\t\t\tPut Directory test\n') # First clean the remote directory incase something was left there remoteDir = self.storage.getCurrentURL('')['Value'] _ = self.storage.removeDirectory(remoteDir, True) # Create a local directory to upload localDir = '/tmp/unit-test' srcFile = '/etc/group' sizeOfLocalFile = getSize(srcFile) if not os.path.exists(localDir): os.mkdir(localDir) for i in range(self.numberOfFiles): shutil.copy(srcFile, '%s/testFile.%s' % (localDir, time.time())) time.sleep(1) # Check that we can successfully upload the directory to the storage element dirDict = {remoteDir: localDir} putDirRes = self.storage.putDirectory(dirDict) # Now remove the remove directory removeDirRes = self.storage.removeDirectory(remoteDir, True) # Clean up the locally created directory shutil.rmtree(localDir) # Perform the checks for the put dir operation self.assertTrue(putDirRes['OK']) self.assertTrue(remoteDir in putDirRes['Value']['Successful']) if putDirRes['Value']['Successful'][remoteDir]['Files']: self.assertEqual(putDirRes['Value']['Successful'][remoteDir]['Files'], self.numberOfFiles) self.assertEqual(putDirRes['Value']['Successful'][remoteDir]['Size'], self.numberOfFiles * sizeOfLocalFile) self.assertTrue(isinstance(putDirRes['Value']['Successful'][remoteDir]['Files'], int)) self.assertTrue(type(putDirRes['Value']['Successful'][remoteDir]['Size']) in six.integer_types) # Perform the checks for the remove dir operation self.assertTrue(removeDirRes['OK']) self.assertTrue(remoteDir in removeDirRes['Value']['Successful']) if removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved']: self.assertEqual(removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved'], self.numberOfFiles) self.assertEqual(removeDirRes['Value']['Successful'][remoteDir] ['SizeRemoved'], self.numberOfFiles * sizeOfLocalFile) self.assertTrue(isinstance(removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved'], int)) self.assertTrue(type(removeDirRes['Value']['Successful'][remoteDir]['SizeRemoved']) in six.integer_types) def test_isDirectory(self): print('\n\n#########################################################' '################\n\n\t\t\tIs Directory test\n') # Test that we can determine what is a directory destDir = self.storage.getCurrentURL('')['Value'] isDirRes = self.storage.isDirectory(destDir) # Test that we can determine that a directory is not a directory dummyDir = self.storage.getCurrentURL('NonExistantFile')['Value'] nonExistantDirRes = self.storage.isDirectory(dummyDir) # Check the is directory operation self.assertTrue(isDirRes['OK']) self.assertTrue(destDir in isDirRes['Value']['Successful']) self.assertTrue(isDirRes['Value']['Successful'][destDir]) # Check the non existant directory operation self.assertTrue(nonExistantDirRes['OK']) self.assertTrue(dummyDir in nonExistantDirRes['Value']['Failed']) expectedError = 'Path does not exist' self.assertTrue(expectedError in nonExistantDirRes['Value']['Failed'][dummyDir]) def test_putGetDirectoryMetadata(self): print('\n\n#########################################################' '################\n\n\t\t\tGet Directory Metadata test\n') # First clean the remote directory incase something was left there remoteDir = self.storage.getCurrentURL('')['Value'] _ = self.storage.removeDirectory(remoteDir, True) # Create a local directory to upload localDir = '/tmp/unit-test' srcFile = '/etc/group' sizeOfLocalFile = getSize(srcFile) if not os.path.exists(localDir): os.mkdir(localDir) for i in range(self.numberOfFiles): shutil.copy(srcFile, '%s/testFile.%s' % (localDir, time.time())) time.sleep(1) # Check that we can successfully upload the directory to the storage element dirDict = {remoteDir: localDir} putDirRes = self.storage.putDirectory(dirDict) # Get the directory metadata getMetadataRes = self.storage.getDirectoryMetadata(remoteDir) # Now remove the remove directory removeDirRes = self.storage.removeDirectory(remoteDir, True) # Clean up the locally created directory shutil.rmtree(localDir) # Perform the checks for the put dir operation self.assertTrue(putDirRes['OK']) self.assertTrue(remoteDir in putDirRes['Value']['Successful']) if putDirRes['Value']['Successful'][remoteDir]['Files']: self.assertEqual(putDirRes['Value']['Successful'][remoteDir]['Files'], self.numberOfFiles) self.assertEqual(putDirRes['Value']['Successful'][remoteDir]['Size'], self.numberOfFiles * sizeOfLocalFile) self.assertTrue(isinstance(putDirRes['Value']['Successful'][remoteDir]['Files'], int)) self.assertTrue(type(putDirRes['Value']['Successful'][remoteDir]['Size']) in six.integer_types) # Perform the checks for the get metadata operation self.assertTrue(getMetadataRes['OK']) self.assertTrue(remoteDir in getMetadataRes['Value']['Successful']) resDict = getMetadataRes['Value']['Successful'][remoteDir] self.assertTrue('Mode' in resDict) self.assertTrue(isinstance(resDict['Mode'], int)) # Perform the checks for the remove directory operation if removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved']: self.assertEqual(removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved'], self.numberOfFiles) self.assertEqual(removeDirRes['Value']['Successful'][remoteDir] ['SizeRemoved'], self.numberOfFiles * sizeOfLocalFile) self.assertTrue(isinstance(removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved'], int)) self.assertTrue(type(removeDirRes['Value']['Successful'][remoteDir]['SizeRemoved']) in six.integer_types) def test_putGetDirectorySize(self): print('\n\n#########################################################' '################\n\n\t\t\tGet Directory Size test\n') # First clean the remote directory incase something was left there remoteDir = self.storage.getCurrentURL('')['Value'] _ = self.storage.removeDirectory(remoteDir, True) # Create a local directory to upload localDir = '/tmp/unit-test' srcFile = '/etc/group' sizeOfLocalFile = getSize(srcFile) if not os.path.exists(localDir): os.mkdir(localDir) for i in range(self.numberOfFiles): shutil.copy(srcFile, '%s/testFile.%s' % (localDir, time.time())) time.sleep(1) # Check that we can successfully upload the directory to the storage element dirDict = {remoteDir: localDir} putDirRes = self.storage.putDirectory(dirDict) # Now get the directory size getDirSizeRes = self.storage.getDirectorySize(remoteDir) # Now remove the remove directory removeDirRes = self.storage.removeDirectory(remoteDir, True) # Clean up the locally created directory shutil.rmtree(localDir) # Perform the checks for the put dir operation self.assertTrue(putDirRes['OK']) self.assertTrue(remoteDir in putDirRes['Value']['Successful']) if putDirRes['Value']['Successful'][remoteDir]['Files']: self.assertEqual(putDirRes['Value']['Successful'][remoteDir]['Files'], self.numberOfFiles) self.assertEqual(putDirRes['Value']['Successful'][remoteDir]['Size'], self.numberOfFiles * sizeOfLocalFile) self.assertTrue(isinstance(putDirRes['Value']['Successful'][remoteDir]['Files'], int)) self.assertTrue(type(putDirRes['Value']['Successful'][remoteDir]['Size']) in six.integer_types) # Now perform the checks for the get directory size operation self.assertTrue(getDirSizeRes['OK']) self.assertTrue(remoteDir in getDirSizeRes['Value']['Successful']) resDict = getDirSizeRes['Value']['Successful'][remoteDir] self.assertTrue(type(resDict['Size']) in six.integer_types) self.assertTrue(isinstance(resDict['Files'], int)) # Perform the checks for the remove directory operation self.assertTrue(removeDirRes['OK']) self.assertTrue(remoteDir in removeDirRes['Value']['Successful']) if removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved']: self.assertEqual(removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved'], self.numberOfFiles) self.assertEqual(removeDirRes['Value']['Successful'][remoteDir] ['SizeRemoved'], self.numberOfFiles * sizeOfLocalFile) self.assertTrue(isinstance(removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved'], int)) self.assertTrue(type(removeDirRes['Value']['Successful'][remoteDir]['SizeRemoved']) in six.integer_types) def test_putListDirectory(self): print('\n\n#########################################################' '################\n\n\t\t\tList Directory test\n') # First clean the remote directory incase something was left there remoteDir = self.storage.getCurrentURL('')['Value'] _ = self.storage.removeDirectory(remoteDir, True) # Create a local directory to upload localDir = '/tmp/unit-test' srcFile = '/etc/group' sizeOfLocalFile = getSize(srcFile) if not os.path.exists(localDir): os.mkdir(localDir) for i in range(self.numberOfFiles): shutil.copy(srcFile, '%s/testFile.%s' % (localDir, time.time())) time.sleep(1) # Check that we can successfully upload the directory to the storage element dirDict = {remoteDir: localDir} putDirRes = self.storage.putDirectory(dirDict) # List the remote directory listDirRes = self.storage.listDirectory(remoteDir) # Now remove the remove directory removeDirRes = self.storage.removeDirectory(remoteDir, True) # Clean up the locally created directory shutil.rmtree(localDir) # Perform the checks for the put dir operation self.assertTrue(putDirRes['OK']) self.assertTrue(remoteDir in putDirRes['Value']['Successful']) if putDirRes['Value']['Successful'][remoteDir]['Files']: self.assertEqual(putDirRes['Value']['Successful'][remoteDir]['Files'], self.numberOfFiles) self.assertEqual(putDirRes['Value']['Successful'][remoteDir]['Size'], self.numberOfFiles * sizeOfLocalFile) self.assertTrue(isinstance(putDirRes['Value']['Successful'][remoteDir]['Files'], int)) self.assertTrue(type(putDirRes['Value']['Successful'][remoteDir]['Size']) in six.integer_types) # Perform the checks for the list dir operation self.assertTrue(listDirRes['OK']) self.assertTrue(remoteDir in listDirRes['Value']['Successful']) resDict = listDirRes['Value']['Successful'][remoteDir] self.assertTrue('SubDirs' in resDict) self.assertTrue('Files' in resDict) self.assertEqual(len(resDict['Files']), self.numberOfFiles) # Perform the checks for the remove directory operation self.assertTrue(removeDirRes['OK']) self.assertTrue(remoteDir in removeDirRes['Value']['Successful']) if removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved']: self.assertEqual(removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved'], self.numberOfFiles) self.assertEqual(removeDirRes['Value']['Successful'][remoteDir] ['SizeRemoved'], self.numberOfFiles * sizeOfLocalFile) self.assertTrue(isinstance(removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved'], int)) self.assertTrue(type(removeDirRes['Value']['Successful'][remoteDir]['SizeRemoved']) in six.integer_types) def test_putGetDirectory(self): print('\n\n#########################################################' '################\n\n\t\t\tGet Directory test\n') # First clean the remote directory incase something was left there remoteDir = self.storage.getCurrentURL('')['Value'] _ = self.storage.removeDirectory(remoteDir, True) # Create a local directory to upload localDir = '/tmp/unit-test' srcFile = '/etc/group' sizeOfLocalFile = getSize(srcFile) if not os.path.exists(localDir): os.mkdir(localDir) for i in range(self.numberOfFiles): shutil.copy(srcFile, '%s/testFile.%s' % (localDir, time.time())) time.sleep(1) # Check that we can successfully upload the directory to the storage element dirDict = {remoteDir: localDir} putDirRes = self.storage.putDirectory(dirDict) # Clean up the locally created directory shutil.rmtree(localDir) # Check that we can get directories from the storage element getDirRes = self.storage.getDirectory(remoteDir, localPath=localDir) # Now remove the remove directory removeDirRes = self.storage.removeDirectory(remoteDir, True) # Clean up the locally created directory shutil.rmtree(localDir) # Perform the checks for the put dir operation self.assertTrue(putDirRes['OK']) self.assertTrue(remoteDir in putDirRes['Value']['Successful']) if putDirRes['Value']['Successful'][remoteDir]['Files']: self.assertEqual(putDirRes['Value']['Successful'][remoteDir]['Files'], self.numberOfFiles) self.assertEqual(putDirRes['Value']['Successful'][remoteDir]['Size'], self.numberOfFiles * sizeOfLocalFile) self.assertTrue(isinstance(putDirRes['Value']['Successful'][remoteDir]['Files'], int)) self.assertTrue(type(putDirRes['Value']['Successful'][remoteDir]['Size']) in six.integer_types) # Perform the checks for the get dir operation self.assertTrue(getDirRes['OK']) self.assertTrue(remoteDir in getDirRes['Value']['Successful']) resDict = getDirRes['Value']['Successful'][remoteDir] if resDict['Files']: self.assertEqual(resDict['Files'], self.numberOfFiles) self.assertEqual(resDict['Size'], self.numberOfFiles * sizeOfLocalFile) self.assertTrue(isinstance(resDict['Files'], int)) self.assertTrue(type(resDict['Size']) in six.integer_types) # Perform the checks for the remove directory operation self.assertTrue(removeDirRes['OK']) self.assertTrue(remoteDir in removeDirRes['Value']['Successful']) if removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved']: self.assertEqual(removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved'], self.numberOfFiles) self.assertEqual(removeDirRes['Value']['Successful'][remoteDir] ['SizeRemoved'], self.numberOfFiles * sizeOfLocalFile) self.assertTrue(isinstance(removeDirRes['Value']['Successful'][remoteDir]['FilesRemoved'], int)) self.assertTrue(type(removeDirRes['Value']['Successful'][remoteDir]['SizeRemoved']) in six.integer_types) class FileTestCase(StoragePlugInTestCase): def test_putRemoveFile(self): print('\n\n#########################################################' '################\n\n\t\t\tPut and Remove test\n') # Make sure that we can actually upload a file properly srcFile = '/etc/group' srcFileSize = getSize(srcFile) testFileName = 'testFile.%s' % time.time() destFile = self.storage.getCurrentURL(testFileName)['Value'] fileDict = {destFile: srcFile} putFileRes = self.storage.putFile(fileDict) # Make sure we are able to remove the file removeFileRes = self.storage.removeFile(destFile) # Check the successful put file operation self.assertTrue(putFileRes['OK']) self.assertTrue(destFile in putFileRes['Value']['Successful']) self.assertEqual(putFileRes['Value']['Successful'][destFile], srcFileSize) # Check the remove file operation self.assertTrue(removeFileRes['OK']) self.assertTrue(destFile in removeFileRes['Value']['Successful']) self.assertTrue(removeFileRes['Value']['Successful'][destFile]) def test_putGetFile(self): print('\n\n#########################################################' '################\n\n\t\t\tPut and Get test\n') # First upload a file to the storage srcFile = '/etc/group' srcFileSize = getSize(srcFile) testFileName = 'testFile.%s' % time.time() remoteFile = self.storage.getCurrentURL(testFileName)['Value'] fileDict = {remoteFile: srcFile} putFileRes = self.storage.putFile(fileDict) # Then make sure we can get a local copy of the file getFileRes = self.storage.getFile(remoteFile) # Cleanup the remote mess removeFileRes = self.storage.removeFile(remoteFile) # Cleanup the mess locally os.remove(testFileName) # Check the put operation self.assertTrue(putFileRes['OK']) self.assertTrue(remoteFile in putFileRes['Value']['Successful']) self.assertEqual(putFileRes['Value']['Successful'][remoteFile], srcFileSize) # Check the get operation self.assertTrue(getFileRes['OK']) self.assertTrue(remoteFile in getFileRes['Value']['Successful']) self.assertEqual(getFileRes['Value']['Successful'][remoteFile], srcFileSize) # Check the remove operation self.assertTrue(removeFileRes['OK']) self.assertTrue(remoteFile in removeFileRes['Value']['Successful']) self.assertTrue(removeFileRes['Value']['Successful'][remoteFile]) def test_putExistsFile(self): print('\n\n#########################################################' '################\n\n\t\t\tExists test\n') # First upload a file to the storage srcFile = '/etc/group' srcFileSize = getSize(srcFile) testFileName = 'testFile.%s' % time.time() remoteFile = self.storage.getCurrentURL(testFileName)['Value'] fileDict = {remoteFile: srcFile} putFileRes = self.storage.putFile(fileDict) # Then get the file's existance existsFileRes = self.storage.exists(remoteFile) # Now remove the file removeFileRes = self.storage.removeFile(remoteFile) # Check again that the file exists failedExistRes = self.storage.exists(remoteFile) # Check the put file operation self.assertTrue(putFileRes['OK']) self.assertTrue(remoteFile in putFileRes['Value']['Successful']) self.assertEqual(putFileRes['Value']['Successful'][remoteFile], srcFileSize) # Check the exists operation self.assertTrue(existsFileRes['OK']) self.assertTrue(remoteFile in existsFileRes['Value']['Successful']) self.assertTrue(existsFileRes['Value']['Successful'][remoteFile]) # Check the removal operation self.assertTrue(removeFileRes['OK']) self.assertTrue(remoteFile in removeFileRes['Value']['Successful']) # Check the failed exists operation self.assertTrue(failedExistRes['OK']) self.assertTrue(remoteFile in failedExistRes['Value']['Successful']) self.assertFalse(failedExistRes['Value']['Successful'][remoteFile]) def test_putIsFile(self): print('\n\n#########################################################' '################\n\n\t\t\tIs file test\n') # First upload a file to the storage srcFile = '/etc/group' srcFileSize = getSize(srcFile) testFileName = 'testFile.%s' % time.time() remoteFile = self.storage.getCurrentURL(testFileName)['Value'] fileDict = {remoteFile: srcFile} putFileRes = self.storage.putFile(fileDict) # Check we are able to determine that it is a file isFileRes = self.storage.isFile(remoteFile) # Clean up the remote mess removeFileRes = self.storage.removeFile(remoteFile) # Check that everything isn't a file remoteDir = os.path.dirname(remoteFile) failedIsFileRes = self.storage.isFile(remoteDir) # Check the put file operation self.assertTrue(putFileRes['OK']) self.assertTrue(remoteFile in putFileRes['Value']['Successful']) self.assertTrue(putFileRes['Value']['Successful'][remoteFile]) self.assertEqual(putFileRes['Value']['Successful'][remoteFile], srcFileSize) # Check the is file operation self.assertTrue(isFileRes['OK']) self.assertTrue(remoteFile in isFileRes['Value']['Successful']) self.assertTrue(isFileRes['Value']['Successful'][remoteFile]) # check the remove file operation self.assertTrue(removeFileRes['OK']) self.assertTrue(remoteFile in removeFileRes['Value']['Successful']) # Check that the directory is not a file self.assertTrue(failedIsFileRes['OK']) self.assertTrue(remoteDir in failedIsFileRes['Value']['Successful']) self.assertFalse(failedIsFileRes['Value']['Successful'][remoteDir]) def test_putGetFileMetaData(self): print('\n\n#########################################################' '################\n\n\t\t\tGet file metadata test\n') # First upload a file to the storage srcFile = '/etc/group' srcFileSize = getSize(srcFile) testFileName = 'testFile.%s' % time.time() remoteFile = self.storage.getCurrentURL(testFileName)['Value'] fileDict = {remoteFile: srcFile} putFileRes = self.storage.putFile(fileDict) # Check that we can get the file metadata getMetadataRes = self.storage.getFileMetadata(remoteFile) # Clean up the remote mess removeFileRes = self.storage.removeFile(remoteFile) # See what happens with non existant files failedMetadataRes = self.storage.getFileMetadata(remoteFile) # Check directories are handled properly remoteDir = os.path.dirname(remoteFile) directoryMetadataRes = self.storage.getFileMetadata(remoteDir) # Check the put file operation self.assertTrue(putFileRes['OK']) self.assertTrue(remoteFile in putFileRes['Value']['Successful']) self.assertTrue(putFileRes['Value']['Successful'][remoteFile]) self.assertEqual(putFileRes['Value']['Successful'][remoteFile], srcFileSize) # Check the get metadata operation self.assertTrue(getMetadataRes['OK']) self.assertTrue(remoteFile in getMetadataRes['Value']['Successful']) fileMetaData = getMetadataRes['Value']['Successful'][remoteFile] self.assertTrue(fileMetaData['Cached']) self.assertFalse(fileMetaData['Migrated']) self.assertEqual(fileMetaData['Size'], srcFileSize) # check the remove file operation self.assertTrue(removeFileRes['OK']) self.assertTrue(remoteFile in removeFileRes['Value']['Successful']) # Check the get metadata for non existant file self.assertTrue(failedMetadataRes['OK']) self.assertTrue(remoteFile in failedMetadataRes['Value']['Failed']) expectedError = "File does not exist" self.assertTrue(expectedError in failedMetadataRes['Value']['Failed'][remoteFile]) # Check that metadata operation with a directory self.assertTrue(directoryMetadataRes['OK']) self.assertTrue(remoteDir in directoryMetadataRes['Value']['Failed']) expectedError = "Supplied path is not a file" self.assertTrue(expectedError in directoryMetadataRes['Value']['Failed'][remoteDir]) def test_putGetFileSize(self): print('\n\n#########################################################' '################\n\n\t\t\tGet file size test\n') # First upload a file to the storage srcFile = '/etc/group' srcFileSize = getSize(srcFile) testFileName = 'testFile.%s' % time.time() remoteFile = self.storage.getCurrentURL(testFileName)['Value'] fileDict = {remoteFile: srcFile} putFileRes = self.storage.putFile(fileDict) # Check that we can get the file size getSizeRes = self.storage.getFileSize(remoteFile) # Clean up the remote mess removeFileRes = self.storage.removeFile(remoteFile) # Check non existant files failedSizeRes = self.storage.getFileMetadata(remoteFile) # Check directories are handled properly remoteDir = os.path.dirname(remoteFile) directorySizeRes = self.storage.getFileSize(remoteDir) # Check the put file operation self.assertTrue(putFileRes['OK']) self.assertTrue(remoteFile in putFileRes['Value']['Successful']) self.assertTrue(putFileRes['Value']['Successful'][remoteFile]) self.assertEqual(putFileRes['Value']['Successful'][remoteFile], srcFileSize) # Check that we got the file size correctly self.assertTrue(getSizeRes['OK']) self.assertTrue(remoteFile in getSizeRes['Value']['Successful']) self.assertEqual(getSizeRes['Value']['Successful'][remoteFile], srcFileSize) # check the remove file operation self.assertTrue(removeFileRes['OK']) self.assertTrue(remoteFile in removeFileRes['Value']['Successful']) # Check the get size with non existant file works properly self.assertTrue(failedSizeRes['OK']) self.assertTrue(remoteFile in failedSizeRes['Value']['Failed']) expectedError = "File does not exist" self.assertTrue(expectedError in failedSizeRes['Value']['Failed'][remoteFile]) # Check that the passing a directory is handled correctly self.assertTrue(directorySizeRes['OK']) self.assertTrue(remoteDir in directorySizeRes['Value']['Failed']) expectedError = "Supplied path is not a file" self.assertTrue(expectedError in directorySizeRes['Value']['Failed'][remoteDir]) def test_putPrestageFile(self): print('\n\n#########################################################' '################\n\n\t\t\tFile prestage test\n') # First upload a file to the storage srcFile = '/etc/group' srcFileSize = getSize(srcFile) testFileName = 'testFile.%s' % time.time() remoteFile = self.storage.getCurrentURL(testFileName)['Value'] fileDict = {remoteFile: srcFile} putFileRes = self.storage.putFile(fileDict) # Check that we can issue a stage request prestageRes = self.storage.prestageFile(remoteFile) # Clean up the remote mess removeFileRes = self.storage.removeFile(remoteFile) # Check what happens with deleted files deletedPrestageRes = self.storage.prestageFile(remoteFile) # Check the put file operation self.assertTrue(putFileRes['OK']) self.assertTrue(remoteFile in putFileRes['Value']['Successful']) self.assertTrue(putFileRes['Value']['Successful'][remoteFile]) self.assertEqual(putFileRes['Value']['Successful'][remoteFile], srcFileSize) # Check the prestage file operation self.assertTrue(prestageRes['OK']) self.assertTrue(remoteFile in prestageRes['Value']['Successful']) self.assertTrue(prestageRes['Value']['Successful'][remoteFile]) # Check the remove file operation self.assertTrue(removeFileRes['OK']) self.assertTrue(remoteFile in removeFileRes['Value']['Successful']) # Check that pre-staging non-existant file fails self.assertTrue(deletedPrestageRes['OK']) self.assertTrue(remoteFile in deletedPrestageRes['Value']['Failed']) expectedError = "No such file or directory" self.assertTrue(expectedError in deletedPrestageRes['Value']['Failed'][remoteFile]) def test_putFilegetTransportURL(self): print('\n\n#########################################################' '################\n\n\t\t\tGet tURL test\n') # First upload a file to the storage srcFile = '/etc/group' srcFileSize = getSize(srcFile) testFileName = 'testFile.%s' % time.time() remoteFile = self.storage.getCurrentURL(testFileName)['Value'] fileDict = {remoteFile: srcFile} putFileRes = self.storage.putFile(fileDict) # Check that we can get a turl getTurlRes = self.storage.getTransportURL(remoteFile) # Clean up the remote mess removeFileRes = self.storage.removeFile(remoteFile) # Try and get a turl for a non existant file failedGetTurlRes = self.storage.getTransportURL(remoteFile) # Check the put file operation self.assertTrue(putFileRes['OK']) self.assertTrue(remoteFile in putFileRes['Value']['Successful']) self.assertTrue(putFileRes['Value']['Successful'][remoteFile]) self.assertEqual(putFileRes['Value']['Successful'][remoteFile], srcFileSize) # check the get turl operation self.assertTrue(getTurlRes['OK']) self.assertTrue(remoteFile in getTurlRes['Value']['Successful']) # check the remove file operation self.assertTrue(removeFileRes['OK']) self.assertTrue(remoteFile in removeFileRes['Value']['Successful']) # Check the get turl with non existant file operation self.assertTrue(failedGetTurlRes['OK']) self.assertTrue(remoteFile in failedGetTurlRes['Value']['Failed']) expectedError = "File does not exist" self.assertTrue(expectedError in failedGetTurlRes['Value']['Failed'][remoteFile]) def test_putPinRelease(self): print('\n\n#########################################################' '################\n\n\t\t\tPin and Release test\n') # First upload a file to the storage srcFile = '/etc/group' srcFileSize = getSize(srcFile) testFileName = 'testFile.%s' % time.time() remoteFile = self.storage.getCurrentURL(testFileName)['Value'] fileDict = {remoteFile: srcFile} putFileRes = self.storage.putFile(fileDict) # Check that we can pin the file pinFileRes = self.storage.pinFile(remoteFile) srmID = '' if pinFileRes['OK']: if remoteFile in pinFileRes['Value']['Successful']: srmID = pinFileRes['Value']['Successful'][remoteFile] # Check that we can release the file releaseFileRes = self.storage.releaseFile({remoteFile: srmID}) # Clean up the mess removeFileRes = self.storage.removeFile(remoteFile) # Check the put file operation self.assertTrue(putFileRes['OK']) self.assertTrue(remoteFile in putFileRes['Value']['Successful']) self.assertTrue(putFileRes['Value']['Successful'][remoteFile]) self.assertEqual(putFileRes['Value']['Successful'][remoteFile], srcFileSize) # Check the pin file operation self.assertTrue(pinFileRes['OK']) self.assertTrue(remoteFile in pinFileRes['Value']['Successful']) self.assertTrue(type(pinFileRes['Value']['Successful'][remoteFile]) in six.string_types) # Check the release file operation self.assertTrue(releaseFileRes['OK']) self.assertTrue(remoteFile in releaseFileRes['Value']['Successful']) # check the remove file operation self.assertTrue(removeFileRes['OK']) self.assertTrue(remoteFile in removeFileRes['Value']['Successful']) def test_putPrestageStatus(self): print('\n\n#########################################################' '################\n\n\t\t\tPrestage status test\n') # First upload a file to the storage srcFile = '/etc/group' srcFileSize = getSize(srcFile) testFileName = 'testFile.%s' % time.time() remoteFile = self.storage.getCurrentURL(testFileName)['Value'] fileDict = {remoteFile: srcFile} putFileRes = self.storage.putFile(fileDict) # Check that we can issue a stage request prestageRes = self.storage.prestageFile(remoteFile) srmID = '' if prestageRes['OK']: if remoteFile in prestageRes['Value']['Successful']: srmID = prestageRes['Value']['Successful'][remoteFile] # Take a quick break to allow the SRM to realise the file is available sleepTime = 10 print('Sleeping for %s seconds' % sleepTime) time.sleep(sleepTime) # Check that we can monitor the stage request prestageStatusRes = self.storage.prestageFileStatus({remoteFile: srmID}) # Clean up the remote mess removeFileRes = self.storage.removeFile(remoteFile) # Check the put file operation self.assertTrue(putFileRes['OK']) self.assertTrue(remoteFile in putFileRes['Value']['Successful']) self.assertTrue(putFileRes['Value']['Successful'][remoteFile]) self.assertEqual(putFileRes['Value']['Successful'][remoteFile], srcFileSize) # Check the prestage file operation self.assertTrue(prestageRes['OK']) self.assertTrue(remoteFile in prestageRes['Value']['Successful']) self.assertTrue(prestageRes['Value']['Successful'][remoteFile]) self.assertTrue(type(prestageRes['Value']['Successful'][remoteFile]) in six.string_types) # Check the prestage status operation self.assertTrue(prestageStatusRes['OK']) self.assertTrue(remoteFile in prestageStatusRes['Value']['Successful']) self.assertTrue(prestageStatusRes['Value']['Successful'][remoteFile]) # Check the remove file operation self.assertTrue(removeFileRes['OK']) self.assertTrue(remoteFile in removeFileRes['Value']['Successful']) if __name__ == '__main__': suite = unittest.defaultTestLoader.loadTestsFromTestCase(FileTestCase) suite.addTest(unittest.defaultTestLoader.loadTestsFromTestCase(DirectoryTestCase)) testResult = unittest.TextTestRunner(verbosity=2).run(suite)
gpl-3.0
GbalsaC/bitnamiP
cms/djangoapps/contentstore/migrations/0001_initial.py
110
5287
# -*- coding: utf-8 -*- import datetime from south.db import db from south.v2 import SchemaMigration from django.db import models class Migration(SchemaMigration): def forwards(self, orm): # Adding model 'VideoUploadConfig' db.create_table('contentstore_videouploadconfig', ( ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)), ('change_date', self.gf('django.db.models.fields.DateTimeField')(auto_now_add=True, blank=True)), ('changed_by', self.gf('django.db.models.fields.related.ForeignKey')(to=orm['auth.User'], null=True, on_delete=models.PROTECT)), ('enabled', self.gf('django.db.models.fields.BooleanField')(default=False)), ('profile_whitelist', self.gf('django.db.models.fields.TextField')(blank=True)), ('status_whitelist', self.gf('django.db.models.fields.TextField')(blank=True)), )) db.send_create_signal('contentstore', ['VideoUploadConfig']) if not db.dry_run: orm.VideoUploadConfig.objects.create( profile_whitelist="desktop_mp4,desktop_webm,mobile_low,youtube", status_whitelist="Uploading,In Progress,Complete,Failed,Invalid Token,Unknown" ) def backwards(self, orm): # Deleting model 'VideoUploadConfig' db.delete_table('contentstore_videouploadconfig') models = { 'auth.group': { 'Meta': {'object_name': 'Group'}, 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '80'}), 'permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'}) }, 'auth.permission': { 'Meta': {'ordering': "('content_type__app_label', 'content_type__model', 'codename')", 'unique_together': "(('content_type', 'codename'),)", 'object_name': 'Permission'}, 'codename': ('django.db.models.fields.CharField', [], {'max_length': '100'}), 'content_type': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['contenttypes.ContentType']"}), 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), 'name': ('django.db.models.fields.CharField', [], {'max_length': '50'}) }, 'auth.user': { 'Meta': {'object_name': 'User'}, 'date_joined': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}), 'email': ('django.db.models.fields.EmailField', [], {'max_length': '75', 'blank': 'True'}), 'first_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}), 'groups': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Group']", 'symmetrical': 'False', 'blank': 'True'}), 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), 'is_active': ('django.db.models.fields.BooleanField', [], {'default': 'True'}), 'is_staff': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), 'is_superuser': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), 'last_login': ('django.db.models.fields.DateTimeField', [], {'default': 'datetime.datetime.now'}), 'last_name': ('django.db.models.fields.CharField', [], {'max_length': '30', 'blank': 'True'}), 'password': ('django.db.models.fields.CharField', [], {'max_length': '128'}), 'user_permissions': ('django.db.models.fields.related.ManyToManyField', [], {'to': "orm['auth.Permission']", 'symmetrical': 'False', 'blank': 'True'}), 'username': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '30'}) }, 'contentstore.videouploadconfig': { 'Meta': {'object_name': 'VideoUploadConfig'}, 'change_date': ('django.db.models.fields.DateTimeField', [], {'auto_now_add': 'True', 'blank': 'True'}), 'changed_by': ('django.db.models.fields.related.ForeignKey', [], {'to': "orm['auth.User']", 'null': 'True', 'on_delete': 'models.PROTECT'}), 'enabled': ('django.db.models.fields.BooleanField', [], {'default': 'False'}), 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), 'profile_whitelist': ('django.db.models.fields.TextField', [], {'blank': 'True'}), 'status_whitelist': ('django.db.models.fields.TextField', [], {'blank': 'True'}) }, 'contenttypes.contenttype': { 'Meta': {'ordering': "('name',)", 'unique_together': "(('app_label', 'model'),)", 'object_name': 'ContentType', 'db_table': "'django_content_type'"}, 'app_label': ('django.db.models.fields.CharField', [], {'max_length': '100'}), 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}), 'model': ('django.db.models.fields.CharField', [], {'max_length': '100'}), 'name': ('django.db.models.fields.CharField', [], {'max_length': '100'}) } } complete_apps = ['contentstore']
agpl-3.0
Anonymous-X6/django
django/core/servers/basehttp.py
274
7319
""" HTTP server that implements the Python WSGI protocol (PEP 333, rev 1.21). Based on wsgiref.simple_server which is part of the standard library since 2.5. This is a simple server for use in testing or debugging Django apps. It hasn't been reviewed for security issues. DON'T USE IT FOR PRODUCTION USE! """ from __future__ import unicode_literals import socket import sys from wsgiref import simple_server from django.core.exceptions import ImproperlyConfigured from django.core.handlers.wsgi import ISO_8859_1, UTF_8 from django.core.management.color import color_style from django.core.wsgi import get_wsgi_application from django.utils import six from django.utils.encoding import uri_to_iri from django.utils.module_loading import import_string from django.utils.six.moves import socketserver __all__ = ('WSGIServer', 'WSGIRequestHandler') def get_internal_wsgi_application(): """ Loads and returns the WSGI application as configured by the user in ``settings.WSGI_APPLICATION``. With the default ``startproject`` layout, this will be the ``application`` object in ``projectname/wsgi.py``. This function, and the ``WSGI_APPLICATION`` setting itself, are only useful for Django's internal server (runserver); external WSGI servers should just be configured to point to the correct application object directly. If settings.WSGI_APPLICATION is not set (is ``None``), we just return whatever ``django.core.wsgi.get_wsgi_application`` returns. """ from django.conf import settings app_path = getattr(settings, 'WSGI_APPLICATION') if app_path is None: return get_wsgi_application() try: return import_string(app_path) except ImportError as e: msg = ( "WSGI application '%(app_path)s' could not be loaded; " "Error importing module: '%(exception)s'" % ({ 'app_path': app_path, 'exception': e, }) ) six.reraise(ImproperlyConfigured, ImproperlyConfigured(msg), sys.exc_info()[2]) def is_broken_pipe_error(): exc_type, exc_value = sys.exc_info()[:2] return issubclass(exc_type, socket.error) and exc_value.args[0] == 32 class WSGIServer(simple_server.WSGIServer, object): """BaseHTTPServer that implements the Python WSGI protocol""" request_queue_size = 10 def __init__(self, *args, **kwargs): if kwargs.pop('ipv6', False): self.address_family = socket.AF_INET6 super(WSGIServer, self).__init__(*args, **kwargs) def server_bind(self): """Override server_bind to store the server name.""" super(WSGIServer, self).server_bind() self.setup_environ() def handle_error(self, request, client_address): if is_broken_pipe_error(): sys.stderr.write("- Broken pipe from %s\n" % (client_address,)) else: super(WSGIServer, self).handle_error(request, client_address) # Inheriting from object required on Python 2. class ServerHandler(simple_server.ServerHandler, object): def handle_error(self): # Ignore broken pipe errors, otherwise pass on if not is_broken_pipe_error(): super(ServerHandler, self).handle_error() class WSGIRequestHandler(simple_server.WSGIRequestHandler, object): def __init__(self, *args, **kwargs): self.style = color_style() super(WSGIRequestHandler, self).__init__(*args, **kwargs) def address_string(self): # Short-circuit parent method to not call socket.getfqdn return self.client_address[0] def log_message(self, format, *args): msg = "[%s] " % self.log_date_time_string() try: msg += "%s\n" % (format % args) except UnicodeDecodeError: # e.g. accessing the server via SSL on Python 2 msg += "\n" # Utilize terminal colors, if available if args[1][0] == '2': # Put 2XX first, since it should be the common case msg = self.style.HTTP_SUCCESS(msg) elif args[1][0] == '1': msg = self.style.HTTP_INFO(msg) elif args[1] == '304': msg = self.style.HTTP_NOT_MODIFIED(msg) elif args[1][0] == '3': msg = self.style.HTTP_REDIRECT(msg) elif args[1] == '404': msg = self.style.HTTP_NOT_FOUND(msg) elif args[1][0] == '4': # 0x16 = Handshake, 0x03 = SSL 3.0 or TLS 1.x if args[0].startswith(str('\x16\x03')): msg = ("You're accessing the development server over HTTPS, " "but it only supports HTTP.\n") msg = self.style.HTTP_BAD_REQUEST(msg) else: # Any 5XX, or any other response msg = self.style.HTTP_SERVER_ERROR(msg) sys.stderr.write(msg) def get_environ(self): # Strip all headers with underscores in the name before constructing # the WSGI environ. This prevents header-spoofing based on ambiguity # between underscores and dashes both normalized to underscores in WSGI # env vars. Nginx and Apache 2.4+ both do this as well. for k, v in self.headers.items(): if '_' in k: del self.headers[k] env = super(WSGIRequestHandler, self).get_environ() path = self.path if '?' in path: path = path.partition('?')[0] path = uri_to_iri(path).encode(UTF_8) # Under Python 3, non-ASCII values in the WSGI environ are arbitrarily # decoded with ISO-8859-1. We replicate this behavior here. # Refs comment in `get_bytes_from_wsgi()`. env['PATH_INFO'] = path.decode(ISO_8859_1) if six.PY3 else path return env def handle(self): """Copy of WSGIRequestHandler, but with different ServerHandler""" self.raw_requestline = self.rfile.readline(65537) if len(self.raw_requestline) > 65536: self.requestline = '' self.request_version = '' self.command = '' self.send_error(414) return if not self.parse_request(): # An error code has been sent, just exit return handler = ServerHandler( self.rfile, self.wfile, self.get_stderr(), self.get_environ() ) handler.request_handler = self # backpointer for logging handler.run(self.server.get_app()) def run(addr, port, wsgi_handler, ipv6=False, threading=False): server_address = (addr, port) if threading: httpd_cls = type(str('WSGIServer'), (socketserver.ThreadingMixIn, WSGIServer), {}) else: httpd_cls = WSGIServer httpd = httpd_cls(server_address, WSGIRequestHandler, ipv6=ipv6) if threading: # ThreadingMixIn.daemon_threads indicates how threads will behave on an # abrupt shutdown; like quitting the server by the user or restarting # by the auto-reloader. True means the server will not wait for thread # termination before it quits. This will make auto-reloader faster # and will prevent the need to kill the server manually if a thread # isn't terminating correctly. httpd.daemon_threads = True httpd.set_app(wsgi_handler) httpd.serve_forever()
bsd-3-clause
amitsela/incubator-beam
sdks/python/apache_beam/tests/test_utils.py
8
2331
# # Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not use this file except in compliance with # the License. You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # """Utility methods for testing""" import hashlib import imp from mock import Mock, patch from apache_beam.utils import retry DEFAULT_HASHING_ALG = 'sha1' def compute_hash(content, hashing_alg=DEFAULT_HASHING_ALG): """Compute a hash value from a list of string.""" content.sort() m = hashlib.new(hashing_alg) for elem in content: m.update(str(elem)) return m.hexdigest() def patch_retry(testcase, module): """A function to patch retry module to use mock clock and logger. Clock and logger that defined in retry decorator will be replaced in test in order to skip sleep phase when retry happens. Args: testcase: An instance of unittest.TestCase that calls this function to patch retry module. module: The module that uses retry and need to be replaced with mock clock and logger in test. """ real_retry_with_exponential_backoff = retry.with_exponential_backoff def patched_retry_with_exponential_backoff(num_retries, retry_filter): """A patch for retry decorator to use a mock dummy clock and logger.""" return real_retry_with_exponential_backoff( num_retries=num_retries, retry_filter=retry_filter, logger=Mock(), clock=Mock()) patch.object(retry, 'with_exponential_backoff', side_effect=patched_retry_with_exponential_backoff).start() # Reload module after patching. imp.reload(module) def remove_patches(): patch.stopall() # Reload module again after removing patch. imp.reload(module) testcase.addCleanup(remove_patches)
apache-2.0
CivicKnowledge/rowgenerators
rowgenerators/rowpipe/test/test_basic.py
1
8010
from __future__ import print_function import unittest import warnings warnings.resetwarnings() warnings.simplefilter("ignore") class TestBasic(unittest.TestCase): def setUp(self): import warnings super().setUp() warnings.simplefilter('ignore') def test_table(self): from rowgenerators.rowpipe import Table t = Table('foobar') t.add_column('i1',datatype='int') t.add_column('i2', valuetype='int') t.add_column('i3', valuetype='measure/int') t.add_column('f1',datatype='float') t.add_column('f2', valuetype='float') t.add_column('f3', valuetype='measure/float') self.assertEqual(6, len(list(t))) for c in t: print(c) def test_expand_transform_1(self): from rowgenerators.rowpipe import Table from rowgenerators.rowpipe import RowProcessor from contexttimer import Timer from itertools import zip_longest def doubleit(v): return int(v) * 2 env = { 'doubleit': doubleit } t = Table('extable') t.add_column('id', datatype='int') t.add_column('b', datatype='int') t.add_column('v1', datatype='int', transform='^row.a') t.add_column('v2', datatype='int', transform='row.v1;doubleit') t.add_column('v3', datatype='int', transform='^row.a;doubleit') for c in t: print('---',c) for i, tr in enumerate(c.expanded_transform): print(' ',i, len(list(tr)), list(tr)) headers = ['stage'] + list(c.name for c in t) table = [[i] + [ tr.str(i) for tr in stage ] for i, stage in enumerate(t.stage_transforms)] from tabulate import tabulate print (tabulate(table, headers, tablefmt="rst")) class Source(object): headers = 'a b'.split() def __iter__(self): for i in range(N): yield i, 2*i rp = RowProcessor(Source(), t, env=env, code_path='/tmp/rowgenerators/test_transform.py') def test_expand_transform_2(self): from rowgenerators.rowpipe import Table from rowgenerators.rowpipe import RowProcessor from contexttimer import Timer from itertools import zip_longest def doubleit(v): return int(v) * 2 env = { 'doubleit': doubleit } t = Table('extable') t.add_column('id', datatype='int') t.add_column('v4', datatype='float', transform='^row.a;doubleit;doubleit') t.add_column('v5', datatype='int', transform='^row.a;doubleit|doubleit') t.add_column('v6', datatype='str', transform="^str('v6-string')") for c in t: print('---',c) for i, tr in enumerate(c.expanded_transform): print(' ',i, len(list(tr)), list(tr)) headers = ['stage'] + list(c.name for c in t) table = [[i] + [ tr.str(i) for tr in stage ] for i, stage in enumerate(t.stage_transforms)] from tabulate import tabulate print (tabulate(table, headers, tablefmt="rst")) class Source(object): headers = 'a b'.split() def __iter__(self): for i in range(N): yield i, 2*i rp = RowProcessor(Source(), t, env=env, code_path='/tmp/rowgenerators/test_transform.py') # NOTE. This speed test is about 12x to 23x faster running in PyPy than CPython! def test_basic_transform(self): from rowgenerators.rowpipe import Table from rowgenerators.rowpipe import RowProcessor from contexttimer import Timer def doubleit(v): return int(v) * 2 env = { 'doubleit': doubleit } t = Table('foobar') t.add_column('id', datatype='int') t.add_column('a', datatype='int') t.add_column('v1', datatype='int', transform='^row.a') t.add_column('v2', datatype='int', transform='row.v1;doubleit') t.add_column('v3', datatype='int', transform='^row.a;doubleit') t.add_column('v4', datatype='float', transform='^row.a;doubleit;doubleit') t.add_column('v5', datatype='int', transform='^row.a;doubleit|doubleit') t.add_column('v6', datatype='float') N = 20000 class Source(object): headers = 'a b'.split() def __iter__(self): for i in range(N): yield i, 2*i rp = RowProcessor(Source(), t, env=env, code_path='/tmp/rowgenerators/test_transform.py') print("Code: ", rp.code_path) headers = rp.headers for row in rp: d = dict(zip(headers, row)) self.assertEqual(d['a'], d['v1'], d) self.assertEqual(2 * d['a'], d['v2'], d) self.assertEqual(2 * d['a'], d['v3'], d) self.assertEqual(4 * d['a'], d['v4'], d) self.assertEqual(4 * d['a'], d['v5'], d) count = 0 row_sum = 0 with Timer() as t: for row in rp: count += 1 row_sum += round(sum(row[:6])) self.assertEqual(2199890000, row_sum) print('Rate=', float(N) / t.elapsed) def test_init_transform(self): from rowgenerators.rowpipe import Table def expand_transform(code, datatype='int', valuetype=None): t = Table('foobar') c = t.add_column('c', datatype=datatype, valuetype=valuetype, transform=code) return c.expanded_transform print(expand_transform('^GeoidCensusTract|v.as_acs()')) print(expand_transform('v.as_acs()')) def test_many_transform(self): from rowgenerators.rowpipe import Table from rowgenerators.rowpipe import RowProcessor from contexttimer import Timer def doubleit(v): return int(v) * 2 def printstuff(v, manager, accumulator): print(type(accumulator), accumulator) return v def accumulate(v, accumulator): from collections import deque if not 'deque' in accumulator: accumulator['deque'] = deque([0], 3) accumulator['deque'].append(v) return sum(accumulator['deque']) def addtwo(x): return x+2 env = { 'doubleit': doubleit, 'printstuff': printstuff, 'accumulate': accumulate, 'addtwo': addtwo } transforms = [ ('',45), ('^row.a', 45), ('^row.a;doubleit', 90), ('^row.a;doubleit;doubleit', 180), ('^row.a;doubleit|doubleit', 180), ('^row.a;row.c*2|doubleit', 180), ('^row.a;row.c/3|doubleit', 24), ('doubleit', 90), ('doubleit;doubleit', 180), ('doubleit|doubleit', 180), ('row.c*2|doubleit', 180), ('row.c/3|doubleit', 24), ('accumulate', 109), ('manager.factor_a*row.c', 450), ('addtwo(row.c)', 65), ] N = 10 class Source(object): headers = 'a'.split() def __iter__(self): for i in range(N): yield (i,) class Manager(object): factor_a = 10 for i, (tr, final_sum) in enumerate(transforms): t = Table('foobar') t.add_column('c', datatype='int', transform=tr) rp = RowProcessor(Source(), t, env=env, manager=Manager(), code_path='/tmp/rowgenerators/test_many_transform_{}.py'.format(i)) row_sum = 0 with Timer() as t: for row in rp: row_sum += sum(row) self.assertEqual(final_sum, row_sum) if __name__ == '__main__': unittest.main()
mit
OpenLinkedSocialData/twitter1
SnapDetremura_tw/scripts/rdfTwitter2.py
4
1441
# read both pickle data that starts with the defined string # write packs of < 50MB pickle data # write triples in packs of < 50MB import social as S, percolation as P, os, re import importlib, datetime importlib.reload(S.tw) importlib.reload(P.utils) ddir="../data/tw/" #a=P.utils.pRead2(ddir+ "{}.pickle".format(sid)) #b=P.utils.pRead2(ddir+"{}_.pickle".format(sid)) #aa=a+b #bb=[i for j in aa for i in j] ##cc=zip(*[iter(bb)]*3) #cc=[bb[i:i+10000] for i in range(0,len(bb),10000)] #i=0 #for chunck in cc: # P.utils.pDump(ddir2+"{}{:04d}".format(sid,i)) # i+=1 scriptpath=os.path.realpath(__file__) fpath="./publishing/tw/" stags=[ "python", "QuartaSemRacismoClubeSDV_tw", "arenaNETmundial", "SnapDetremura_tw", "art_tw", "game_tw", "god_tw", "music_tw", "obama_tw", "science_tw", "porn_tw", "ChennaiFloods_tw", "SyriaVote_tw", "MAMA2015_tw", ] stags=["QuartaSemRacismoClubeSDV_tw", "arenaNETmundial", "SnapDetremura_tw", "art_tw"] umbrella_dir="twitter1/" #fnames=[sid+".pickle","arenaNETmundial.pickle"] fnames=[i+".pickle" for i in stags] #descriptions=["tweets with the #QuertaSemRacismoClubeSDV hashtag","tweets with the #arenaNETmundial hashtag"] descriptions=["tweets with the #{} hashtag".format(i) for i in stags] for fname,desc in zip(fnames,descriptions): b=S.tw.publishSearch("../data/tw/{}".format(fname),fpath, None,scriptpath,datetime.date(2015, 12, 3), desc,umbrella_dir=umbrella_dir)
cc0-1.0
chillpop/Vokoder
Paging Data Source Example/Pods/xUnique/xUnique.py
22
26477
#!/usr/bin/env python # -*- coding: utf-8 -*- """ This software is licensed under the Apache 2 license, quoted below. Copyright 2014 Xiao Wang <wangxiao8611@gmail.com, http://fclef.wordpress.com/about> Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. """ from __future__ import unicode_literals from __future__ import print_function from subprocess import (check_output as sp_co, CalledProcessError) from os import path, unlink, rename from hashlib import md5 as hl_md5 from json import (loads as json_loads, dump as json_dump) from fileinput import (input as fi_input, close as fi_close) from re import compile as re_compile from sys import (argv as sys_argv, getfilesystemencoding as sys_get_fs_encoding) from collections import deque from filecmp import cmp as filecmp_cmp from optparse import OptionParser md5_hex = lambda a_str: hl_md5(a_str.encode('utf-8')).hexdigest().upper() print_ng = lambda *args, **kwargs: print(*[unicode(i).encode(sys_get_fs_encoding()) for i in args], **kwargs) output_u8line = lambda *args: print(*[unicode(i).encode('utf-8') for i in args], end='') def warning_print(*args, **kwargs): new_args = list(args) new_args[0] = '\x1B[33m{}'.format(new_args[0]) new_args[-1] = '{}\x1B[0m'.format(new_args[-1]) print_ng(*new_args, **kwargs) def success_print(*args, **kwargs): new_args = list(args) new_args[0] = '\x1B[32m{}'.format(new_args[0]) new_args[-1] = '{}\x1B[0m'.format(new_args[-1]) print_ng(*new_args, **kwargs) class XUnique(object): def __init__(self, target_path, verbose=False): # check project path abs_target_path = path.abspath(target_path) if not path.exists(abs_target_path): raise XUniqueExit('Path "{}" not found!'.format(abs_target_path)) elif abs_target_path.endswith('xcodeproj'): self.xcodeproj_path = abs_target_path self.xcode_pbxproj_path = path.join(abs_target_path, 'project.pbxproj') elif abs_target_path.endswith('project.pbxproj'): self.xcode_pbxproj_path = abs_target_path self.xcodeproj_path = path.dirname(self.xcode_pbxproj_path) else: raise XUniqueExit("Path must be dir '.xcodeproj' or file 'project.pbxproj'") self.verbose = verbose self.vprint = print if self.verbose else lambda *a, **k: None self.proj_root = self.get_proj_root() self.proj_json = self.pbxproj_to_json() self.nodes = self.proj_json['objects'] self.root_hex = self.proj_json['rootObject'] self.root_node = self.nodes[self.root_hex] self.main_group_hex = self.root_node['mainGroup'] self.__result = {} # initialize root content self.__result.update( { self.root_hex: {'path': self.proj_root, 'new_key': md5_hex(self.proj_root), 'type': self.root_node['isa'] } }) self._is_modified = False @property def is_modified(self): return self._is_modified def pbxproj_to_json(self): pbproj_to_json_cmd = ['plutil', '-convert', 'json', '-o', '-', self.xcode_pbxproj_path] try: json_unicode_str = sp_co(pbproj_to_json_cmd).decode(sys_get_fs_encoding()) return json_loads(json_unicode_str) except CalledProcessError as cpe: raise XUniqueExit("""{} Please check: 1. You have installed Xcode Command Line Tools and command 'plutil' could be found in $PATH; 2. The project file is not broken, such like merge conflicts, incomplete content due to xUnique failure. """.format( cpe.output)) def __set_to_result(self, parent_hex, current_hex, current_path_key): current_node = self.nodes[current_hex] isa_type = current_node['isa'] if isinstance(current_path_key, (list, tuple)): current_path = '/'.join([str(current_node[i]) for i in current_path_key]) elif isinstance(current_path_key, (basestring, unicode)): if current_path_key in current_node.keys(): current_path = current_node[current_path_key] else: current_path = current_path_key else: raise KeyError('current_path_key must be list/tuple/string') cur_abs_path = '{}/{}'.format(self.__result[parent_hex]['path'], current_path) new_key = md5_hex(cur_abs_path) self.__result.update({ current_hex: {'path': '{}[{}]'.format(isa_type, cur_abs_path), 'new_key': new_key, 'type': isa_type } }) return new_key def get_proj_root(self): """PBXProject name,the root node""" pbxproject_ptn = re_compile('(?<=PBXProject ").*(?=")') with open(self.xcode_pbxproj_path) as pbxproj_file: for line in pbxproj_file: # project.pbxproj is an utf-8 encoded file line = line.decode('utf-8') result = pbxproject_ptn.search(line) if result: # Backward compatibility using suffix return '{}.xcodeproj'.format(result.group()) raise XUniqueExit("File 'project.pbxproj' is broken. Cannot find PBXProject name.") def unique_project(self): """iterate all nodes in pbxproj file: PBXProject XCConfigurationList PBXNativeTarget PBXTargetDependency PBXContainerItemProxy XCBuildConfiguration PBX*BuildPhase PBXBuildFile PBXReferenceProxy PBXFileReference PBXGroup PBXVariantGroup """ self.__unique_project(self.root_hex) if self.verbose: debug_result_file_path = path.join(self.xcodeproj_path, 'debug_result.json') with open(debug_result_file_path, 'w') as debug_result_file: json_dump(self.__result, debug_result_file) warning_print("Debug result json file has been written to '", debug_result_file_path, sep='') self.substitute_old_keys() def substitute_old_keys(self): self.vprint('replace UUIDs and remove unused UUIDs') key_ptn = re_compile('(?<=\s)([0-9A-Z]{24}|[0-9A-F]{32})(?=[\s;])') removed_lines = [] for line in fi_input(self.xcode_pbxproj_path, backup='.ubak', inplace=1): # project.pbxproj is an utf-8 encoded file line = line.decode('utf-8') key_list = key_ptn.findall(line) if not key_list: output_u8line(line) else: new_line = line # remove line with non-existing element if self.__result.get('to_be_removed') and any( i for i in key_list if i in self.__result['to_be_removed']): removed_lines.append(new_line) continue # remove incorrect entry that somehow does not exist in project node tree elif not all(self.__result.get(uuid) for uuid in key_list): removed_lines.append(new_line) continue else: for key in key_list: new_key = self.__result[key]['new_key'] new_line = new_line.replace(key, new_key) output_u8line(new_line) fi_close() tmp_path = self.xcode_pbxproj_path + '.ubak' if filecmp_cmp(self.xcode_pbxproj_path, tmp_path, shallow=False): unlink(self.xcode_pbxproj_path) rename(tmp_path, self.xcode_pbxproj_path) warning_print('Ignore uniquify, no changes made to "', self.xcode_pbxproj_path, sep='') else: unlink(tmp_path) self._is_modified = True success_print('Uniquify done') if self.__result.get('uniquify_warning'): warning_print(*self.__result['uniquify_warning']) if removed_lines: warning_print('Following lines were deleted because of invalid format or no longer being used:') print_ng(*removed_lines, end='') def sort_pbxproj(self, sort_pbx_by_file_name=False): self.vprint('sort project.xpbproj file') lines = [] removed_lines = [] files_start_ptn = re_compile('^(\s*)files = \(\s*$') files_key_ptn = re_compile('((?<=[A-Z0-9]{24} \/\* )|(?<=[A-F0-9]{32} \/\* )).+?(?= in )') fc_end_ptn = '\);' files_flag = False children_start_ptn = re_compile('^(\s*)children = \(\s*$') children_pbx_key_ptn = re_compile('((?<=[A-Z0-9]{24} \/\* )|(?<=[A-F0-9]{32} \/\* )).+?(?= \*\/)') child_flag = False pbx_start_ptn = re_compile('^.*Begin (PBXBuildFile|PBXFileReference) section.*$') pbx_key_ptn = re_compile('^\s+(([A-Z0-9]{24})|([A-F0-9]{32}))(?= \/\*)') pbx_end_ptn = ('^.*End ', ' section.*$') pbx_flag = False last_two = deque([]) def file_dir_cmp(x, y): if '.' in x: if '.' in y: return cmp(x, y) else: return 1 else: if '.' in y: return -1 else: return cmp(x, y) for line in fi_input(self.xcode_pbxproj_path, backup='.sbak', inplace=1): # project.pbxproj is an utf-8 encoded file line = line.decode('utf-8') last_two.append(line) if len(last_two) > 2: last_two.popleft() # files search and sort files_match = files_start_ptn.search(line) if files_match: output_u8line(line) files_flag = True if isinstance(fc_end_ptn, unicode): fc_end_ptn = re_compile(files_match.group(1) + fc_end_ptn) if files_flag: if fc_end_ptn.search(line): if lines: lines.sort(key=lambda file_str: files_key_ptn.search(file_str).group()) output_u8line(''.join(lines)) lines = [] files_flag = False fc_end_ptn = '\);' elif files_key_ptn.search(line): if line in lines: removed_lines.append(line) else: lines.append(line) # children search and sort children_match = children_start_ptn.search(line) if children_match: output_u8line(line) child_flag = True if isinstance(fc_end_ptn, unicode): fc_end_ptn = re_compile(children_match.group(1) + fc_end_ptn) if child_flag: if fc_end_ptn.search(line): if lines: if self.main_group_hex not in last_two[0]: lines.sort(key=lambda file_str: children_pbx_key_ptn.search(file_str).group(), cmp=file_dir_cmp) output_u8line(''.join(lines)) lines = [] child_flag = False fc_end_ptn = '\);' elif children_pbx_key_ptn.search(line): if line in lines: removed_lines.append(line) else: lines.append(line) # PBX search and sort pbx_match = pbx_start_ptn.search(line) if pbx_match: output_u8line(line) pbx_flag = True if isinstance(pbx_end_ptn, tuple): pbx_end_ptn = re_compile(pbx_match.group(1).join(pbx_end_ptn)) if pbx_flag: if pbx_end_ptn.search(line): if lines: if sort_pbx_by_file_name: lines.sort(key=lambda file_str: children_pbx_key_ptn.search(file_str).group()) else: lines.sort(key=lambda file_str: pbx_key_ptn.search(file_str).group(1)) output_u8line(''.join(lines)) lines = [] pbx_flag = False pbx_end_ptn = ('^.*End ', ' section.*') elif children_pbx_key_ptn.search(line): if line in lines: removed_lines.append(line) else: lines.append(line) # normal output if not (files_flag or child_flag or pbx_flag): output_u8line(line) fi_close() tmp_path = self.xcode_pbxproj_path + '.sbak' if filecmp_cmp(self.xcode_pbxproj_path, tmp_path, shallow=False): unlink(self.xcode_pbxproj_path) rename(tmp_path, self.xcode_pbxproj_path) warning_print('Ignore sort, no changes made to "', self.xcode_pbxproj_path, sep='') else: unlink(tmp_path) self._is_modified = True success_print('Sort done') if removed_lines: warning_print('Following lines were deleted because of duplication:') print_ng(*removed_lines, end='') def __unique_project(self, project_hex): """PBXProject. It is root itself, no parents to it""" self.vprint('uniquify PBXProject') self.vprint('uniquify PBX*Group and PBX*Reference*') self.__unique_group_or_ref(project_hex, self.main_group_hex) self.vprint('uniquify XCConfigurationList') bcl_hex = self.root_node['buildConfigurationList'] self.__unique_build_configuration_list(project_hex, bcl_hex) subprojects_list = self.root_node.get('projectReferences') if subprojects_list: self.vprint('uniquify Subprojects') for subproject_dict in subprojects_list: product_group_hex = subproject_dict['ProductGroup'] project_ref_parent_hex = subproject_dict['ProjectRef'] self.__unique_group_or_ref(project_ref_parent_hex, product_group_hex) targets_list = self.root_node['targets'] # workaround for PBXTargetDependency referring target that have not been iterated for target_hex in targets_list: cur_path_key = ('productName', 'name') self.__set_to_result(project_hex, target_hex, cur_path_key) for target_hex in targets_list: self.__unique_target(target_hex) def __unique_build_configuration_list(self, parent_hex, build_configuration_list_hex): """XCConfigurationList""" cur_path_key = 'defaultConfigurationName' self.__set_to_result(parent_hex, build_configuration_list_hex, cur_path_key) build_configuration_list_node = self.nodes[build_configuration_list_hex] self.vprint('uniquify XCConfiguration') for build_configuration_hex in build_configuration_list_node['buildConfigurations']: self.__unique_build_configuration(build_configuration_list_hex, build_configuration_hex) def __unique_build_configuration(self, parent_hex, build_configuration_hex): """XCBuildConfiguration""" cur_path_key = 'name' self.__set_to_result(parent_hex, build_configuration_hex, cur_path_key) def __unique_target(self, target_hex): """PBXNativeTarget PBXAggregateTarget""" self.vprint('uniquify PBX*Target') current_node = self.nodes[target_hex] bcl_hex = current_node['buildConfigurationList'] self.__unique_build_configuration_list(target_hex, bcl_hex) dependencies_list = current_node.get('dependencies') if dependencies_list: self.vprint('uniquify PBXTargetDependency') for dependency_hex in dependencies_list: self.__unique_target_dependency(target_hex, dependency_hex) build_phases_list = current_node['buildPhases'] for build_phase_hex in build_phases_list: self.__unique_build_phase(target_hex, build_phase_hex) build_rules_list = current_node.get('buildRules') if build_rules_list: for build_rule_hex in build_rules_list: self.__unique_build_rules(target_hex, build_rule_hex) def __unique_target_dependency(self, parent_hex, target_dependency_hex): """PBXTargetDependency""" target_hex = self.nodes[target_dependency_hex].get('target') if target_hex: self.__set_to_result(parent_hex, target_dependency_hex, self.__result[target_hex]['path']) else: self.__set_to_result(parent_hex, target_dependency_hex, 'name') self.__unique_container_item_proxy(target_dependency_hex, self.nodes[target_dependency_hex]['targetProxy']) def __unique_container_item_proxy(self, parent_hex, container_item_proxy_hex): """PBXContainerItemProxy""" self.vprint('uniquify PBXContainerItemProxy') new_container_item_proxy_hex = self.__set_to_result(parent_hex, container_item_proxy_hex, ('isa', 'remoteInfo')) cur_path = self.__result[container_item_proxy_hex]['path'] current_node = self.nodes[container_item_proxy_hex] # re-calculate remoteGlobalIDString to a new length 32 MD5 digest remote_global_id_hex = current_node.get('remoteGlobalIDString') if not remote_global_id_hex: self.__result.setdefault('uniquify_warning', []).append( "PBXTargetDependency '{}' and its child PBXContainerItemProxy '{}' are not needed anymore, please remove their sections manually".format( self.__result[parent_hex]['new_key'], new_container_item_proxy_hex)) elif remote_global_id_hex not in self.__result.keys(): portal_hex = current_node['containerPortal'] portal_result_hex = self.__result.get(portal_hex) if not portal_result_hex: self.__result.setdefault('uniquify_warning', []).append( "PBXTargetDependency '{}' and its child PBXContainerItemProxy '{}' are not needed anymore, please remove their sections manually".format( self.__result[parent_hex]['new_key'], new_container_item_proxy_hex)) else: portal_path = portal_result_hex['path'] new_rg_id_path = '{}+{}'.format(cur_path, portal_path) self.__result.update({ remote_global_id_hex: {'path': new_rg_id_path, 'new_key': md5_hex(new_rg_id_path), 'type': '{}#{}'.format(self.nodes[container_item_proxy_hex]['isa'], 'remoteGlobalIDString') } }) def __unique_build_phase(self, parent_hex, build_phase_hex): """PBXSourcesBuildPhase PBXFrameworksBuildPhase PBXResourcesBuildPhase PBXCopyFilesBuildPhase PBXHeadersBuildPhase PBXShellScriptBuildPhase """ self.vprint('uniquify all kinds of PBX*BuildPhase') current_node = self.nodes[build_phase_hex] # no useful key in some build phase types, use its isa value bp_type = current_node['isa'] if bp_type == 'PBXShellScriptBuildPhase': cur_path_key = 'shellScript' elif bp_type == 'PBXCopyFilesBuildPhase': cur_path_key = ['name', 'dstSubfolderSpec', 'dstPath'] if not current_node.get('name'): del cur_path_key[0] else: cur_path_key = bp_type self.__set_to_result(parent_hex, build_phase_hex, cur_path_key) self.vprint('uniquify PBXBuildFile') for build_file_hex in current_node['files']: self.__unique_build_file(build_phase_hex, build_file_hex) def __unique_group_or_ref(self, parent_hex, group_ref_hex): """PBXFileReference PBXGroup PBXVariantGroup PBXReferenceProxy""" if self.nodes.get(group_ref_hex): current_hex = group_ref_hex if self.nodes[current_hex].get('name'): cur_path_key = 'name' elif self.nodes[current_hex].get('path'): cur_path_key = 'path' else: # root PBXGroup has neither path nor name, give a new name 'PBXRootGroup' cur_path_key = 'PBXRootGroup' self.__set_to_result(parent_hex, current_hex, cur_path_key) if self.nodes[current_hex].get('children'): for child_hex in self.nodes[current_hex]['children']: self.__unique_group_or_ref(current_hex, child_hex) if self.nodes[current_hex]['isa'] == 'PBXReferenceProxy': self.__unique_container_item_proxy(parent_hex, self.nodes[current_hex]['remoteRef']) else: self.vprint("Group/FileReference/ReferenceProxy '", group_ref_hex, "' not found, it will be removed.") self.__result.setdefault('to_be_removed', []).append(group_ref_hex) def __unique_build_file(self, parent_hex, build_file_hex): """PBXBuildFile""" current_node = self.nodes.get(build_file_hex) if not current_node: self.__result.setdefault('to_be_removed', []).append(build_file_hex) else: file_ref_hex = current_node.get('fileRef') if not file_ref_hex: self.vprint("PBXFileReference '", file_ref_hex, "' not found, it will be removed.") self.__result.setdefault('to_be_removed', []).append(build_file_hex) else: if self.__result.get(file_ref_hex): cur_path_key = self.__result[file_ref_hex]['path'] self.__set_to_result(parent_hex, build_file_hex, cur_path_key) else: self.vprint("PBXFileReference '", file_ref_hex, "' not found in PBXBuildFile '", build_file_hex, "'. To be removed.", sep='') self.__result.setdefault('to_be_removed', []).extend((build_file_hex, file_ref_hex)) def __unique_build_rules(self, parent_hex, build_rule_hex): """PBXBuildRule""" current_node = self.nodes.get(build_rule_hex) if not current_node: self.vprint("PBXBuildRule '", current_node, "' not found, it will be removed.") self.__result.setdefault('to_be_removed', []).append(build_rule_hex) else: file_type = current_node['fileType'] cur_path_key = 'fileType' if file_type == 'pattern.proxy': cur_path_key = ('fileType', 'filePatterns') self.__set_to_result(parent_hex, build_rule_hex, cur_path_key) class XUniqueExit(SystemExit): def __init__(self, value): value = "\x1B[31m{}\x1B[0m".format(value) super(XUniqueExit, self).__init__(value) def main(): usage = "usage: %prog [-v][-u][-s][-c][-p] path/to/Project.xcodeproj" description = "Doc: https://github.com/truebit/xUnique" parser = OptionParser(usage=usage, description=description) parser.add_option("-v", "--verbose", action="store_true", dest="verbose", default=False, help="output verbose messages. default is False.") parser.add_option("-u", "--unique", action="store_true", dest="unique_bool", default=False, help="uniquify the project file. default is False.") parser.add_option("-s", "--sort", action="store_true", dest="sort_bool", default=False, help="sort the project file. default is False. When neither '-u' nor '-s' option exists, xUnique will invisibly add both '-u' and '-s' in arguments") parser.add_option("-c", "--combine-commit", action="store_true", dest="combine_commit", default=False, help="When project file was modified, xUnique quit with non-zero status. Without this option, the status code would be zero if so. This option is usually used in Git hook to submit xUnique result combined with your original new commit.") parser.add_option("-p", "--sort-pbx-by-filename", action="store_true", dest="sort_pbx_fn_bool", default=False, help="sort PBXFileReference and PBXBuildFile sections in project file, ordered by file name. Without this option, ordered by MD5 digest, the same as Xcode does.") (options, args) = parser.parse_args(sys_argv[1:]) if len(args) < 1: parser.print_help() raise XUniqueExit( "xUnique requires at least one positional argument: relative/absolute path to xcodeproj.") xcode_proj_path = args[0].decode(sys_get_fs_encoding()) xunique = XUnique(xcode_proj_path, options.verbose) if not (options.unique_bool or options.sort_bool): print_ng("Uniquify and Sort") xunique.unique_project() xunique.sort_pbxproj(options.sort_pbx_fn_bool) success_print("Uniquify and Sort done") else: if options.unique_bool: print_ng('Uniquify...') xunique.unique_project() if options.sort_bool: print_ng('Sort...') xunique.sort_pbxproj(options.sort_pbx_fn_bool) if options.combine_commit: if xunique.is_modified: raise XUniqueExit("File 'project.pbxproj' was modified, please add it and then commit.") else: if xunique.is_modified: warning_print( "File 'project.pbxproj' was modified, please add it and commit again to submit xUnique result.\nNOTICE: If you want to submit xUnique result combined with original commit, use option '-c' in command.") if __name__ == '__main__': main()
mit
wwj718/murp-edx
common/djangoapps/terrain/browser.py
2
9872
""" Browser set up for acceptance tests. """ # pylint: disable=E1101 # pylint: disable=W0613 from lettuce import before, after, world from splinter.browser import Browser from logging import getLogger from django.core.management import call_command from django.conf import settings from selenium.common.exceptions import WebDriverException from selenium.webdriver.common.desired_capabilities import DesiredCapabilities import requests from base64 import encodestring from json import dumps from pymongo import MongoClient import xmodule.modulestore.django from xmodule.contentstore.django import _CONTENTSTORE from xmodule.modulestore import ModuleStoreEnum # There is an import issue when using django-staticfiles with lettuce # Lettuce assumes that we are using django.contrib.staticfiles, # but the rest of the app assumes we are using django-staticfiles # (in particular, django-pipeline and our mako implementation) # To resolve this, we check whether staticfiles is installed, # then redirect imports for django.contrib.staticfiles # to use staticfiles. try: import staticfiles import staticfiles.handlers except ImportError: pass else: import sys sys.modules['django.contrib.staticfiles'] = staticfiles sys.modules['django.contrib.staticfiles.handlers'] = staticfiles.handlers LOGGER = getLogger(__name__) LOGGER.info("Loading the lettuce acceptance testing terrain file...") MAX_VALID_BROWSER_ATTEMPTS = 20 GLOBAL_SCRIPT_TIMEOUT = 60 def get_saucelabs_username_and_key(): """ Returns the Sauce Labs username and access ID as set by environment variables """ return {"username": settings.SAUCE.get('USERNAME'), "access-key": settings.SAUCE.get('ACCESS_ID')} def set_saucelabs_job_status(jobid, passed=True): """ Sets the job status on sauce labs """ config = get_saucelabs_username_and_key() url = 'http://saucelabs.com/rest/v1/{}/jobs/{}'.format(config['username'], world.jobid) body_content = dumps({"passed": passed}) base64string = encodestring('{}:{}'.format(config['username'], config['access-key']))[:-1] headers = {"Authorization": "Basic {}".format(base64string)} result = requests.put(url, data=body_content, headers=headers) return result.status_code == 200 def make_saucelabs_desired_capabilities(): """ Returns a DesiredCapabilities object corresponding to the environment sauce parameters """ desired_capabilities = settings.SAUCE.get('BROWSER', DesiredCapabilities.CHROME) desired_capabilities['platform'] = settings.SAUCE.get('PLATFORM') desired_capabilities['version'] = settings.SAUCE.get('VERSION') desired_capabilities['device-type'] = settings.SAUCE.get('DEVICE') desired_capabilities['name'] = settings.SAUCE.get('SESSION') desired_capabilities['build'] = settings.SAUCE.get('BUILD') desired_capabilities['video-upload-on-pass'] = False desired_capabilities['sauce-advisor'] = False desired_capabilities['capture-html'] = True desired_capabilities['record-screenshots'] = True desired_capabilities['selenium-version'] = "2.34.0" desired_capabilities['max-duration'] = 3600 desired_capabilities['public'] = 'public restricted' return desired_capabilities @before.harvest def initial_setup(server): """ Launch the browser once before executing the tests. """ world.absorb(settings.LETTUCE_SELENIUM_CLIENT, 'LETTUCE_SELENIUM_CLIENT') if world.LETTUCE_SELENIUM_CLIENT == 'local': browser_driver = getattr(settings, 'LETTUCE_BROWSER', 'chrome') # There is an issue with ChromeDriver2 r195627 on Ubuntu # in which we sometimes get an invalid browser session. # This is a work-around to ensure that we get a valid session. success = False num_attempts = 0 while (not success) and num_attempts < MAX_VALID_BROWSER_ATTEMPTS: # Load the browser and try to visit the main page # If the browser couldn't be reached or # the browser session is invalid, this will # raise a WebDriverException try: world.browser = Browser(browser_driver) world.browser.driver.set_script_timeout(GLOBAL_SCRIPT_TIMEOUT) world.visit('/') except WebDriverException: if hasattr(world, 'browser'): world.browser.quit() num_attempts += 1 else: success = True # If we were unable to get a valid session within the limit of attempts, # then we cannot run the tests. if not success: raise IOError("Could not acquire valid {driver} browser session.".format(driver=browser_driver)) world.absorb(0, 'IMPLICIT_WAIT') world.browser.driver.set_window_size(1280, 1024) elif world.LETTUCE_SELENIUM_CLIENT == 'saucelabs': config = get_saucelabs_username_and_key() world.browser = Browser( 'remote', url="http://{}:{}@ondemand.saucelabs.com:80/wd/hub".format(config['username'], config['access-key']), **make_saucelabs_desired_capabilities() ) world.absorb(30, 'IMPLICIT_WAIT') world.browser.set_script_timeout(GLOBAL_SCRIPT_TIMEOUT) elif world.LETTUCE_SELENIUM_CLIENT == 'grid': world.browser = Browser( 'remote', url=settings.SELENIUM_GRID.get('URL'), browser=settings.SELENIUM_GRID.get('BROWSER'), ) world.absorb(30, 'IMPLICIT_WAIT') world.browser.driver.set_script_timeout(GLOBAL_SCRIPT_TIMEOUT) else: raise Exception("Unknown selenium client '{}'".format(world.LETTUCE_SELENIUM_CLIENT)) world.browser.driver.implicitly_wait(world.IMPLICIT_WAIT) world.absorb(world.browser.driver.session_id, 'jobid') @before.each_scenario def reset_data(scenario): """ Clean out the django test database defined in the envs/acceptance.py file: edx-platform/db/test_edx.db """ LOGGER.debug("Flushing the test database...") call_command('flush', interactive=False, verbosity=0) world.absorb({}, 'scenario_dict') @before.each_scenario def configure_screenshots(scenario): """ Before each scenario, turn off automatic screenshots. Args: str, scenario. Name of current scenario. """ world.auto_capture_screenshots = False @after.each_scenario def clear_data(scenario): world.spew('scenario_dict') @after.each_scenario def reset_databases(scenario): ''' After each scenario, all databases are cleared/dropped. Contentstore data are stored in unique databases whereas modulestore data is in unique collection names. This data is created implicitly during the scenarios. If no data is created during the test, these lines equivilently do nothing. ''' mongo = MongoClient() mongo.drop_database(settings.CONTENTSTORE['DOC_STORE_CONFIG']['db']) _CONTENTSTORE.clear() modulestore = xmodule.modulestore.django.modulestore()._get_modulestore_by_type(ModuleStoreEnum.Type.mongo) modulestore.collection.drop() xmodule.modulestore.django.clear_existing_modulestores() @world.absorb def capture_screenshot(image_name): """ Capture a screenshot outputting it to a defined directory. This function expects only the name of the file. It will generate the full path of the output screenshot. If the name contains spaces, they ill be converted to underscores. """ output_dir = '{}/log/auto_screenshots'.format(settings.TEST_ROOT) image_name = '{}/{}.png'.format(output_dir, image_name.replace(' ', '_')) try: world.browser.driver.save_screenshot(image_name) except WebDriverException: LOGGER.error("Could not capture a screenshot '{}'".format(image_name)) @after.each_scenario def screenshot_on_error(scenario): """ Save a screenshot to help with debugging. """ if scenario.failed: try: output_dir = '{}/log'.format(settings.TEST_ROOT) image_name = '{}/{}.png'.format(output_dir, scenario.name.replace(' ', '_')) world.browser.driver.save_screenshot(image_name) except WebDriverException: LOGGER.error('Could not capture a screenshot') def capture_screenshot_for_step(step, when): """ Useful method for debugging acceptance tests that are run in Vagrant. This method runs automatically before and after each step of an acceptance test scenario. The variable: world.auto_capture_screenshots either enables or disabled the taking of screenshots. To change the variable there is a convenient step defined: I (enable|disable) auto screenshots If you just want to capture a single screenshot at a desired point in code, you should use the method: world.capture_screenshot("image_name") """ if world.auto_capture_screenshots: scenario_num = step.scenario.feature.scenarios.index(step.scenario) + 1 step_num = step.scenario.steps.index(step) + 1 step_func_name = step.defined_at.function.func_name image_name = "{prefix:03d}__{num:03d}__{name}__{postfix}".format( prefix=scenario_num, num=step_num, name=step_func_name, postfix=when ) world.capture_screenshot(image_name) @before.each_step def before_each_step(step): capture_screenshot_for_step(step, '1_before') @after.each_step def after_each_step(step): capture_screenshot_for_step(step, '2_after') @after.harvest def teardown_browser(total): """ Quit the browser after executing the tests. """ if world.LETTUCE_SELENIUM_CLIENT == 'saucelabs': set_saucelabs_job_status(world.jobid, total.scenarios_ran == total.scenarios_passed) world.browser.quit()
agpl-3.0
samvidmistry/PyMaterial
demo/ripple_test_demo.py
2
1187
__author__ = "Samvid Mistry" import sys from PySide.QtGui import * from PySide.QtCore import * from MUtilities import MColors from MBase.MAnimationThread import MAnimationThread from MComponents.MTestComponent import MTestComponent class MainWindow(QWidget): def __init__(self): QWidget.__init__(self) self.setWindowTitle("Reveal test") self.setGeometry(100, 100, 500, 500) p = self.palette() p.setColor(self.backgroundRole(), MColors.BACKGROUND_DARK) self.setPalette(p) def addComponents(self): layout = QGridLayout() self.test1 = MTestComponent() # self.test1.animate().fade(100).scale(50).start() cancel = QPushButton("Start Animation") cancel.clicked.connect(self.start_animation) layout.addWidget(self.test1) layout.addWidget(cancel) self.setLayout(layout) def start_animation(self): self.test1.animate().duration(1000).reveal("show").start() thread = MAnimationThread() if __name__ == '__main__': app = QApplication(sys.argv) win = MainWindow() win.show() win.addComponents() thread.start() app.exec_() sys.exit()
mit
mvitr/titanium_mobile
support/common/markdown/html4.py
133
9672
# markdown/html4.py # # Add html4 serialization to older versions of Elementree # Taken from ElementTree 1.3 preview with slight modifications # # Copyright (c) 1999-2007 by Fredrik Lundh. All rights reserved. # # fredrik@pythonware.com # http://www.pythonware.com # # -------------------------------------------------------------------- # The ElementTree toolkit is # # Copyright (c) 1999-2007 by Fredrik Lundh # # By obtaining, using, and/or copying this software and/or its # associated documentation, you agree that you have read, understood, # and will comply with the following terms and conditions: # # Permission to use, copy, modify, and distribute this software and # its associated documentation for any purpose and without fee is # hereby granted, provided that the above copyright notice appears in # all copies, and that both that copyright notice and this permission # notice appear in supporting documentation, and that the name of # Secret Labs AB or the author not be used in advertising or publicity # pertaining to distribution of the software without specific, written # prior permission. # # SECRET LABS AB AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD # TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANT- # ABILITY AND FITNESS. IN NO EVENT SHALL SECRET LABS AB OR THE AUTHOR # BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY # DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, # WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS # ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE # OF THIS SOFTWARE. # -------------------------------------------------------------------- import markdown ElementTree = markdown.etree.ElementTree QName = markdown.etree.QName Comment = markdown.etree.Comment PI = markdown.etree.PI ProcessingInstruction = markdown.etree.ProcessingInstruction HTML_EMPTY = ("area", "base", "basefont", "br", "col", "frame", "hr", "img", "input", "isindex", "link", "meta" "param") try: HTML_EMPTY = set(HTML_EMPTY) except NameError: pass _namespace_map = { # "well-known" namespace prefixes "http://www.w3.org/XML/1998/namespace": "xml", "http://www.w3.org/1999/xhtml": "html", "http://www.w3.org/1999/02/22-rdf-syntax-ns#": "rdf", "http://schemas.xmlsoap.org/wsdl/": "wsdl", # xml schema "http://www.w3.org/2001/XMLSchema": "xs", "http://www.w3.org/2001/XMLSchema-instance": "xsi", # dublic core "http://purl.org/dc/elements/1.1/": "dc", } def _raise_serialization_error(text): raise TypeError( "cannot serialize %r (type %s)" % (text, type(text).__name__) ) def _encode(text, encoding): try: return text.encode(encoding, "xmlcharrefreplace") except (TypeError, AttributeError): _raise_serialization_error(text) def _escape_cdata(text, encoding): # escape character data try: # it's worth avoiding do-nothing calls for strings that are # shorter than 500 character, or so. assume that's, by far, # the most common case in most applications. if "&" in text: text = text.replace("&", "&amp;") if "<" in text: text = text.replace("<", "&lt;") if ">" in text: text = text.replace(">", "&gt;") return text.encode(encoding, "xmlcharrefreplace") except (TypeError, AttributeError): _raise_serialization_error(text) def _escape_attrib(text, encoding): # escape attribute value try: if "&" in text: text = text.replace("&", "&amp;") if "<" in text: text = text.replace("<", "&lt;") if ">" in text: text = text.replace(">", "&gt;") if "\"" in text: text = text.replace("\"", "&quot;") if "\n" in text: text = text.replace("\n", "&#10;") return text.encode(encoding, "xmlcharrefreplace") except (TypeError, AttributeError): _raise_serialization_error(text) def _escape_attrib_html(text, encoding): # escape attribute value try: if "&" in text: text = text.replace("&", "&amp;") if ">" in text: text = text.replace(">", "&gt;") if "\"" in text: text = text.replace("\"", "&quot;") return text.encode(encoding, "xmlcharrefreplace") except (TypeError, AttributeError): _raise_serialization_error(text) def _serialize_html(write, elem, encoding, qnames, namespaces): tag = elem.tag text = elem.text if tag is Comment: write("<!--%s-->" % _escape_cdata(text, encoding)) elif tag is ProcessingInstruction: write("<?%s?>" % _escape_cdata(text, encoding)) else: tag = qnames[tag] if tag is None: if text: write(_escape_cdata(text, encoding)) for e in elem: _serialize_html(write, e, encoding, qnames, None) else: write("<" + tag) items = elem.items() if items or namespaces: items.sort() # lexical order for k, v in items: if isinstance(k, QName): k = k.text if isinstance(v, QName): v = qnames[v.text] else: v = _escape_attrib_html(v, encoding) # FIXME: handle boolean attributes write(" %s=\"%s\"" % (qnames[k], v)) if namespaces: items = namespaces.items() items.sort(key=lambda x: x[1]) # sort on prefix for v, k in items: if k: k = ":" + k write(" xmlns%s=\"%s\"" % ( k.encode(encoding), _escape_attrib(v, encoding) )) write(">") tag = tag.lower() if text: if tag == "script" or tag == "style": write(_encode(text, encoding)) else: write(_escape_cdata(text, encoding)) for e in elem: _serialize_html(write, e, encoding, qnames, None) if tag not in HTML_EMPTY: write("</" + tag + ">") if elem.tail: write(_escape_cdata(elem.tail, encoding)) def write_html(root, f, # keyword arguments encoding="us-ascii", default_namespace=None): assert root is not None if not hasattr(f, "write"): f = open(f, "wb") write = f.write if not encoding: encoding = "us-ascii" qnames, namespaces = _namespaces( root, encoding, default_namespace ) _serialize_html( write, root, encoding, qnames, namespaces ) # -------------------------------------------------------------------- # serialization support def _namespaces(elem, encoding, default_namespace=None): # identify namespaces used in this tree # maps qnames to *encoded* prefix:local names qnames = {None: None} # maps uri:s to prefixes namespaces = {} if default_namespace: namespaces[default_namespace] = "" def encode(text): return text.encode(encoding) def add_qname(qname): # calculate serialized qname representation try: if qname[:1] == "{": uri, tag = qname[1:].split("}", 1) prefix = namespaces.get(uri) if prefix is None: prefix = _namespace_map.get(uri) if prefix is None: prefix = "ns%d" % len(namespaces) if prefix != "xml": namespaces[uri] = prefix if prefix: qnames[qname] = encode("%s:%s" % (prefix, tag)) else: qnames[qname] = encode(tag) # default element else: if default_namespace: # FIXME: can this be handled in XML 1.0? raise ValueError( "cannot use non-qualified names with " "default_namespace option" ) qnames[qname] = encode(qname) except TypeError: _raise_serialization_error(qname) # populate qname and namespaces table try: iterate = elem.iter except AttributeError: iterate = elem.getiterator # cET compatibility for elem in iterate(): tag = elem.tag if isinstance(tag, QName) and tag.text not in qnames: add_qname(tag.text) elif isinstance(tag, basestring): if tag not in qnames: add_qname(tag) elif tag is not None and tag is not Comment and tag is not PI: _raise_serialization_error(tag) for key, value in elem.items(): if isinstance(key, QName): key = key.text if key not in qnames: add_qname(key) if isinstance(value, QName) and value.text not in qnames: add_qname(value.text) text = elem.text if isinstance(text, QName) and text.text not in qnames: add_qname(text.text) return qnames, namespaces def to_html_string(element, encoding=None): class dummy: pass data = [] file = dummy() file.write = data.append write_html(ElementTree(element).getroot(),file,encoding) return "".join(data)
apache-2.0
slyphon/pants
src/python/pants/option/option_value_container.py
4
6789
# coding=utf-8 # Copyright 2014 Pants project contributors (see CONTRIBUTORS.md). # Licensed under the Apache License, Version 2.0 (see LICENSE). from __future__ import (absolute_import, division, generators, nested_scopes, print_function, unicode_literals, with_statement) from pants.option.ranked_value import RankedValue class OptionValueContainer(object): """A container for option values. Implements the following functionality: 1) Attribute forwarding. An attribute can be registered as forwarding to another attribute, and attempts to read the source attribute's value will be read from the target attribute. This is necessary so we can qualify registered options by the scope that registered them, to allow re-registration in inner scopes. This is best explained by example: Say that in global scope we register an option with two names: [-f, --foo], which writes its value to the attribute foo. Then in the compile scope we re-register --foo but leave -f alone. The re-registered --foo will also write to attribute foo. So now -f, which in the compile scope is unrelated to --foo, can still stomp on its value. With attribute forwarding we can have the global scope option write to _DEFAULT_foo__, and the re-registered option to _COMPILE_foo__, and then have the 'f' and 'foo' attributes forward, appropriately. Note that only reads are forwarded. The target of the forward must be written to directly. If the source attribute is set directly, this overrides any forwarding. 2) Value ranking. Attribute values can be ranked, so that a given attribute's value can only be changed if the new value has at least as high a rank as the old value. This allows an option value in an outer scope to override that option's value in an inner scope, when the outer scope's value comes from a higher ranked source (e.g., the outer value comes from an env var and the inner one from config). See ranked_value.py for more details. Note that this container is suitable for passing as the namespace argument to argparse's parse_args() method. """ def __init__(self): self._forwardings = {} # src attribute name -> target attribute name. def add_forwardings(self, forwardings): """Add attribute forwardings. Will overwrite existing forwardings with the same source attributes. :param forwardings: A map of source attribute name -> attribute to read source's value from. """ self._forwardings.update(forwardings) def get_rank(self, key): """Returns the rank of the value at the specified key. Returns one of the constants in RankedValue. """ if key not in self._forwardings: raise AttributeError('No such forwarded attribute: {}'.format(key)) val = getattr(self, self._forwardings[key]) if isinstance(val, RankedValue): return val.rank else: # Values without rank are assumed to be flag values set by argparse. return RankedValue.FLAG def is_flagged(self, key): """Returns `True` if the value for the specified key was supplied via a flag. A convenience equivalent to `get_rank(key) == RankedValue.FLAG`. This check can be useful to determine whether or not a user explicitly set an option for this run. Although a user might also set an option explicitly via an environment variable, ie via: `ENV_VAR=value ./pants ...`, this is an ambiguous case since the environment variable could also be permanently set in the user's environment. :param string key: The name of the option to check. :returns: `True` if the option was explicitly flagged by the user from the command line. :rtype: bool """ return self.get_rank(key) == RankedValue.FLAG def is_default(self, key): """Returns `True` if the value for the specified key was not supplied by the user. I.e. the option was NOT specified config files, on the cli, or in environment variables. :param string key: The name of the option to check. :returns: `True` if the user did not set the value for this option. :rtype: bool """ return self.get_rank(key) in (RankedValue.NONE, RankedValue.HARDCODED) def update(self, attrs): """Set attr values on this object from the data in the attrs dict.""" for k, v in attrs.items(): setattr(self, k, v) def get(self, key, default=None): # Support dict-like dynamic access. See also __getitem__ below. if hasattr(self, key): return getattr(self, key) else: return default def __setattr__(self, key, value): if key == '_forwardings': return super(OptionValueContainer, self).__setattr__(key, value) if hasattr(self, key): existing_value = getattr(self, key) if isinstance(existing_value, RankedValue): existing_rank = existing_value.rank else: # Values without rank are assumed to be flag values set by argparse. existing_rank = RankedValue.FLAG else: existing_rank = RankedValue.NONE if isinstance(value, RankedValue): new_rank = value.rank else: # Values without rank are assumed to be flag values set by argparse. new_rank = RankedValue.FLAG if new_rank >= existing_rank: # We set values from outer scopes before values from inner scopes, so # in case of equal rank we overwrite. That way that the inner scope value wins. super(OptionValueContainer, self).__setattr__(key, value) def __getitem__(self, key): # Support natural dynamic access, options[key_var] is more idiomatic than # getattr(option, key_var). return getattr(self, key) def __getattr__(self, key): # Note: Called only if regular attribute lookup fails, so accesses # to non-forwarded attributes will be handled the normal way. if key == '_forwardings': # In case we get called in copy/deepcopy, which don't invoke the ctor. raise AttributeError if key not in self._forwardings: raise AttributeError('No such forwarded attribute: {}'.format(key)) val = getattr(self, self._forwardings[key]) if isinstance(val, RankedValue): return val.value else: return val def __iter__(self): """Returns an iterator over all option names, in lexicographical order. In the rare (for us) case of an option with multiple names, we pick the lexicographically smallest one, for consistency. """ inverse_forwardings = {} # internal attribute -> external attribute. for k, v in self._forwardings.items(): if v not in inverse_forwardings or inverse_forwardings[v] > k: inverse_forwardings[v] = k for name in sorted(inverse_forwardings.values()): yield name
apache-2.0
alfred82santa/aio-service-client
tests/tests_utils.py
1
8530
from textwrap import dedent from typing import Optional, Union from unittest.case import TestCase from service_client.utils import IncompleteFormatter, random_token, build_parameter_object class TestIncompleteFormatter(TestCase): def setUp(self): self.formatter = IncompleteFormatter() def test_all_items_kwargs(self): self.assertEqual(self.formatter.format("Test {var1} with {var2} kwarg", var1="first", var2=2), "Test first with 2 kwarg") self.assertEqual(self.formatter.get_substituted_fields(), ['var1', 'var2']) self.assertEqual(self.formatter.get_not_substituted_fields(), []) def test_one_items_kwargs(self): self.assertEqual(self.formatter.format("Test {var1} with {var2} kwarg", var1="first"), "Test first with {var2} kwarg") self.assertEqual(self.formatter.get_substituted_fields(), ['var1']) self.assertEqual(self.formatter.get_not_substituted_fields(), ['var2']) def test_no_items_kwargs(self): self.assertEqual(self.formatter.format("Test {var1} with {var2} kwarg"), "Test {var1} with {var2} kwarg") self.assertEqual(self.formatter.get_substituted_fields(), []) self.assertEqual(self.formatter.get_not_substituted_fields(), ['var1', 'var2']) def test_all_items_indexed_args(self): self.assertEqual(self.formatter.format("Test {0} with {1} indexed args", "first", 2), "Test first with 2 indexed args") self.assertEqual(self.formatter.get_substituted_fields(), ['0', '1']) self.assertEqual(self.formatter.get_not_substituted_fields(), []) def test_one_items_indexed_args(self): self.assertEqual(self.formatter.format("Test {0} with {1} indexed args", 'first'), "Test first with {1} indexed args") self.assertEqual(self.formatter.get_substituted_fields(), ['0']) self.assertEqual(self.formatter.get_not_substituted_fields(), ['1']) def test_no_items_indexed_args(self): self.assertEqual(self.formatter.format("Test {0} with {1} indexed args"), "Test {0} with {1} indexed args") self.assertEqual(self.formatter.get_substituted_fields(), []) self.assertEqual(self.formatter.get_not_substituted_fields(), ['0', '1']) def test_all_items_not_indexed_args(self): self.assertEqual(self.formatter.format("Test {} with {} indexed args", "first", 2), "Test first with 2 indexed args") self.assertEqual(self.formatter.get_substituted_fields(), ['0', '1']) self.assertEqual(self.formatter.get_not_substituted_fields(), []) def test_one_items_not_indexed_args(self): self.assertEqual(self.formatter.format("Test {} with {} indexed args", 'first'), "Test first with {1} indexed args") self.assertEqual(self.formatter.get_substituted_fields(), ['0']) self.assertEqual(self.formatter.get_not_substituted_fields(), ['1']) def test_no_items_not_indexed_args(self): self.assertEqual(self.formatter.format("Test {} with {} indexed args"), "Test {0} with {1} indexed args") self.assertEqual(self.formatter.get_substituted_fields(), []) self.assertEqual(self.formatter.get_not_substituted_fields(), ['0', '1']) class RandomTokenTest(TestCase): def test_random_token(self): self.assertNotEqual(random_token(), random_token()) self.assertNotEqual(random_token(), random_token()) self.assertNotEqual(random_token(), random_token()) def test_default_length(self): self.assertEqual(len(random_token()), 10) def test_custom_length(self): self.assertEqual(len(random_token(20)), 20) class FakeModel: def __init__(self, data=None): try: self.fieldname_1 = data['fieldname_1'] except (KeyError, TypeError): self.fieldname_1 = None class BuildParameterObjectTests(TestCase): class Fake: @build_parameter_object def method_union(self, request: Union[FakeModel, None]): return request @build_parameter_object(arg_name='request_1', arg_index=1, arg_class=FakeModel) def method_no_anno_extra_params(self, param_1, request_1, param_2): """ :param param_1: :param request_1: :param param_2: :return: """ return param_1, request_1, param_2 @build_parameter_object def method_optional(self, request: Optional[FakeModel]): return request @build_parameter_object def method_class(self, request: FakeModel): return request def setUp(self): self.object = self.Fake() def test_using_union_positional(self): request = FakeModel() self.assertEqual(self.object.method_union(request), request) def test_using_union_keyword(self): request = FakeModel() self.assertEqual(self.object.method_union(request=request), request) def test_using_union_build(self): result = self.object.method_union(fieldname_1=1) self.assertIsInstance(result, FakeModel) self.assertEqual(result.fieldname_1, 1) def test_using_union_build_empty(self): result = self.object.method_union() self.assertIsInstance(result, FakeModel) self.assertIsNone(result.fieldname_1) def test_using_optional_positional(self): request = FakeModel() self.assertEqual(self.object.method_optional(request), request) def test_using_optional_keyword(self): request = FakeModel() self.assertEqual(self.object.method_optional(request=request), request) def test_using_optional_build(self): result = self.object.method_optional(fieldname_1=1) self.assertIsInstance(result, FakeModel) self.assertEqual(result.fieldname_1, 1) def test_using_optional_build_empty(self): result = self.object.method_optional() self.assertIsInstance(result, FakeModel) self.assertIsNone(result.fieldname_1) def test_using_class_positional(self): request = FakeModel() self.assertEqual(self.object.method_class(request), request) def test_using_class_keyword(self): request = FakeModel() self.assertEqual(self.object.method_class(request=request), request) def test_using_class_build(self): result = self.object.method_class(fieldname_1=1) self.assertIsInstance(result, FakeModel) self.assertEqual(result.fieldname_1, 1) def test_using_class_build_empty(self): result = self.object.method_class() self.assertIsInstance(result, FakeModel) self.assertIsNone(result.fieldname_1) def test_using_no_anno_extra_params_positional(self): request = FakeModel() self.assertEqual(self.object.method_no_anno_extra_params(1, request, 2), (1, request, 2)) def test_using_no_anno_extra_params_keyword(self): request = FakeModel() self.assertEqual(self.object.method_no_anno_extra_params(param_1=1, request_1=request, param_2=2), (1, request, 2)) def test_using_no_anno_extra_params_build(self): result = self.object.method_no_anno_extra_params(1, fieldname_1=1, param_2=2) self.assertEqual(result[0], 1) self.assertEqual(result[2], 2) self.assertIsInstance(result[1], FakeModel) self.assertEqual(result[1].fieldname_1, 1) def test_using_no_anno_extra_params_build_empty(self): result = self.object.method_no_anno_extra_params(1, param_2=2) self.assertEqual(result[0], 1) self.assertEqual(result[2], 2) self.assertIsInstance(result[1], FakeModel) self.assertIsNone(result[1].fieldname_1) def test_doc(self): self.assertEqual(self.object.method_no_anno_extra_params.__doc__, dedent(""" :param param_1: :param request_1: :param param_2: :return: It is possible to use keyword parameters to build an object :class:`~tests.tests_utils.FakeModel` for parameter ``request_1``."""), self.object.method_no_anno_extra_params.__doc__)
lgpl-3.0
importsfromgooglecode/pychess
lib/pychess/widgets/SetupBoard.py
21
2655
from gi.repository import Gtk, Gtk.Gdk from gi.repository import GObject from math import floor from BoardView import BoardView from pychess.Utils.const import * from pychess.Utils.Cord import Cord ALL = 0 class SetupBoard (Gtk.EventBox): __gsignals__ = { 'cord_clicked' : (SIGNAL_RUN_FIRST, TYPE_NONE, (TYPE_PYOBJECT,)), } def __init__(self): GObject.GObject.__init__(self) self.view = BoardView() self.add(self.view) self.view.showEnpassant = True self.connect("button_press_event", self.button_press) self.connect("button_release_event", self.button_release) self.add_events(Gdk.EventMask.LEAVE_NOTIFY_MASK|Gdk.EventMask.POINTER_MOTION_MASK) self.connect("motion_notify_event", self.motion_notify) self.connect("leave_notify_event", self.leave_notify) self.brush = None # Selection and stuff # def setBrush (self, brush): self.brush = brush def getBrush (self): return self.brush def transPoint (self, x, y): if not self.view.square: return None xc, yc, square, s = self.view.square y -= yc; x -= xc y /= float(s) x /= float(s) if self.view.fromWhite: y = 8 - y else: x = 8 - x return x, y def point2Cord (self, x, y): if not self.view.square: return None point = self.transPoint(x, y) x = floor(point[0]) if self.view.fromWhite: y = floor(point[1]) else: y = floor(point[1]) if not (0 <= x <= 7 and 0 <= y <= 7): return None return Cord(x, y) def button_press (self, widget, event): self.grab_focus() cord = self.point2Cord (event.x, event.y) if self.legalCords == ALL or cord in self.legalCords: self.view.active = cord else: self.view.active = None def button_release (self, widget, event): cord = self.point2Cord (event.x, event.y) if cord == self.view.active: self.emit('cord_clicked', cord) self.view.active = None def motion_notify (self, widget, event): cord = self.point2Cord (event.x, event.y) if cord == None: return if self.legalCords == ALL or cord in self.legalCords: self.view.hover = cord else: self.view.hover = None def leave_notify (self, widget, event): a = self.get_allocation() if not (0 <= event.x < a.width and 0 <= event.y < a.height): self.view.hover = None
gpl-3.0
anryko/ansible
lib/ansible/modules/packaging/os/pulp_repo.py
11
27318
#!/usr/bin/python # -*- coding: utf-8 -*- # (c) 2016, Joe Adams <@sysadmind> # # GNU General Public License v3.0+ (see COPYING or https://www.gnu.org/licenses/gpl-3.0.txt) from __future__ import absolute_import, division, print_function __metaclass__ = type ANSIBLE_METADATA = {'metadata_version': '1.1', 'status': ['preview'], 'supported_by': 'community'} DOCUMENTATION = ''' --- module: pulp_repo author: "Joe Adams (@sysadmind)" short_description: Add or remove Pulp repos from a remote host. description: - Add or remove Pulp repos from a remote host. version_added: "2.3" options: add_export_distributor: description: - Whether or not to add the export distributor to new C(rpm) repositories. type: bool default: 'no' feed: description: - Upstream feed URL to receive updates from. force_basic_auth: description: - httplib2, the library used by the M(uri) module only sends authentication information when a webservice responds to an initial request with a 401 status. Since some basic auth services do not properly send a 401, logins will fail. This option forces the sending of the Basic authentication header upon initial request. type: bool default: 'no' generate_sqlite: description: - Boolean flag to indicate whether sqlite files should be generated during a repository publish. required: false type: bool default: 'no' version_added: "2.8" feed_ca_cert: description: - CA certificate string used to validate the feed source SSL certificate. This can be the file content or the path to the file. The ca_cert alias will be removed in Ansible 2.14. type: str aliases: [ importer_ssl_ca_cert, ca_cert ] feed_client_cert: version_added: "2.9.2" description: - Certificate used as the client certificate when synchronizing the repository. This is used to communicate authentication information to the feed source. The value to this option must be the full path to the certificate. The specified file may be the certificate itself or a single file containing both the certificate and private key. This can be the file content or the path to the file. - If not specified the default value will come from client_cert. Which will change in Ansible 2.14. type: str aliases: [ importer_ssl_client_cert ] feed_client_key: version_added: "2.9.2" description: - Private key to the certificate specified in I(importer_ssl_client_cert), assuming it is not included in the certificate file itself. This can be the file content or the path to the file. - If not specified the default value will come from client_key. Which will change in Ansible 2.14. type: str aliases: [ importer_ssl_client_key ] name: description: - Name of the repo to add or remove. This correlates to repo-id in Pulp. required: true proxy_host: description: - Proxy url setting for the pulp repository importer. This is in the format scheme://host. required: false default: null proxy_port: description: - Proxy port setting for the pulp repository importer. required: false default: null proxy_username: description: - Proxy username for the pulp repository importer. required: false default: null version_added: "2.8" proxy_password: description: - Proxy password for the pulp repository importer. required: false default: null version_added: "2.8" publish_distributor: description: - Distributor to use when state is C(publish). The default is to publish all distributors. pulp_host: description: - URL of the pulp server to connect to. default: http://127.0.0.1 relative_url: description: - Relative URL for the local repository. required: true repo_type: description: - Repo plugin type to use (i.e. C(rpm), C(docker)). default: rpm repoview: description: - Whether to generate repoview files for a published repository. Setting this to "yes" automatically activates `generate_sqlite`. required: false type: bool default: 'no' version_added: "2.8" serve_http: description: - Make the repo available over HTTP. type: bool default: 'no' serve_https: description: - Make the repo available over HTTPS. type: bool default: 'yes' state: description: - The repo state. A state of C(sync) will queue a sync of the repo. This is asynchronous but not delayed like a scheduled sync. A state of C(publish) will use the repository's distributor to publish the content. default: present choices: [ "present", "absent", "sync", "publish" ] url_password: description: - The password for use in HTTP basic authentication to the pulp API. If the I(url_username) parameter is not specified, the I(url_password) parameter will not be used. url_username: description: - The username for use in HTTP basic authentication to the pulp API. validate_certs: description: - If C(no), SSL certificates will not be validated. This should only be used on personally controlled sites using self-signed certificates. type: bool default: 'yes' wait_for_completion: description: - Wait for asynchronous tasks to complete before returning. type: bool default: 'no' notes: - This module can currently only create distributors and importers on rpm repositories. Contributions to support other repo types are welcome. extends_documentation_fragment: - url ''' EXAMPLES = ''' - name: Create a new repo with name 'my_repo' pulp_repo: name: my_repo relative_url: my/repo state: present - name: Create a repo with a feed and a relative URL pulp_repo: name: my_centos_updates repo_type: rpm feed: http://mirror.centos.org/centos/6/updates/x86_64/ relative_url: centos/6/updates url_username: admin url_password: admin force_basic_auth: yes state: present - name: Remove a repo from the pulp server pulp_repo: name: my_old_repo repo_type: rpm state: absent ''' RETURN = ''' repo: description: Name of the repo that the action was performed on. returned: success type: str sample: my_repo ''' import json import os from time import sleep # import module snippets from ansible.module_utils.basic import AnsibleModule from ansible.module_utils.urls import fetch_url from ansible.module_utils.urls import url_argument_spec class pulp_server(object): """ Class to interact with a Pulp server """ def __init__(self, module, pulp_host, repo_type, wait_for_completion=False): self.module = module self.host = pulp_host self.repo_type = repo_type self.repo_cache = dict() self.wait_for_completion = wait_for_completion def check_repo_exists(self, repo_id): try: self.get_repo_config_by_id(repo_id) except IndexError: return False else: return True def compare_repo_distributor_config(self, repo_id, **kwargs): repo_config = self.get_repo_config_by_id(repo_id) for distributor in repo_config['distributors']: for key, value in kwargs.items(): if key not in distributor['config'].keys(): return False if not distributor['config'][key] == value: return False return True def compare_repo_importer_config(self, repo_id, **kwargs): repo_config = self.get_repo_config_by_id(repo_id) for importer in repo_config['importers']: for key, value in kwargs.items(): if value is not None: if key not in importer['config'].keys(): return False if not importer['config'][key] == value: return False return True def create_repo( self, repo_id, relative_url, feed=None, generate_sqlite=False, serve_http=False, serve_https=True, proxy_host=None, proxy_port=None, proxy_username=None, proxy_password=None, repoview=False, ssl_ca_cert=None, ssl_client_cert=None, ssl_client_key=None, add_export_distributor=False ): url = "%s/pulp/api/v2/repositories/" % self.host data = dict() data['id'] = repo_id data['distributors'] = [] if self.repo_type == 'rpm': yum_distributor = dict() yum_distributor['distributor_id'] = "yum_distributor" yum_distributor['distributor_type_id'] = "yum_distributor" yum_distributor['auto_publish'] = True yum_distributor['distributor_config'] = dict() yum_distributor['distributor_config']['http'] = serve_http yum_distributor['distributor_config']['https'] = serve_https yum_distributor['distributor_config']['relative_url'] = relative_url yum_distributor['distributor_config']['repoview'] = repoview yum_distributor['distributor_config']['generate_sqlite'] = generate_sqlite or repoview data['distributors'].append(yum_distributor) if add_export_distributor: export_distributor = dict() export_distributor['distributor_id'] = "export_distributor" export_distributor['distributor_type_id'] = "export_distributor" export_distributor['auto_publish'] = False export_distributor['distributor_config'] = dict() export_distributor['distributor_config']['http'] = serve_http export_distributor['distributor_config']['https'] = serve_https export_distributor['distributor_config']['relative_url'] = relative_url export_distributor['distributor_config']['repoview'] = repoview export_distributor['distributor_config']['generate_sqlite'] = generate_sqlite or repoview data['distributors'].append(export_distributor) data['importer_type_id'] = "yum_importer" data['importer_config'] = dict() if feed: data['importer_config']['feed'] = feed if proxy_host: data['importer_config']['proxy_host'] = proxy_host if proxy_port: data['importer_config']['proxy_port'] = proxy_port if proxy_username: data['importer_config']['proxy_username'] = proxy_username if proxy_password: data['importer_config']['proxy_password'] = proxy_password if ssl_ca_cert: data['importer_config']['ssl_ca_cert'] = ssl_ca_cert if ssl_client_cert: data['importer_config']['ssl_client_cert'] = ssl_client_cert if ssl_client_key: data['importer_config']['ssl_client_key'] = ssl_client_key data['notes'] = { "_repo-type": "rpm-repo" } response, info = fetch_url( self.module, url, data=json.dumps(data), method='POST') if info['status'] != 201: self.module.fail_json( msg="Failed to create repo.", status_code=info['status'], response=info['msg'], url=url) else: return True def delete_repo(self, repo_id): url = "%s/pulp/api/v2/repositories/%s/" % (self.host, repo_id) response, info = fetch_url(self.module, url, data='', method='DELETE') if info['status'] != 202: self.module.fail_json( msg="Failed to delete repo.", status_code=info['status'], response=info['msg'], url=url) if self.wait_for_completion: self.verify_tasks_completed(json.load(response)) return True def get_repo_config_by_id(self, repo_id): if repo_id not in self.repo_cache.keys(): repo_array = [x for x in self.repo_list if x['id'] == repo_id] self.repo_cache[repo_id] = repo_array[0] return self.repo_cache[repo_id] def publish_repo(self, repo_id, publish_distributor): url = "%s/pulp/api/v2/repositories/%s/actions/publish/" % (self.host, repo_id) # If there's no distributor specified, we will publish them all if publish_distributor is None: repo_config = self.get_repo_config_by_id(repo_id) for distributor in repo_config['distributors']: data = dict() data['id'] = distributor['id'] response, info = fetch_url( self.module, url, data=json.dumps(data), method='POST') if info['status'] != 202: self.module.fail_json( msg="Failed to publish the repo.", status_code=info['status'], response=info['msg'], url=url, distributor=distributor['id']) else: data = dict() data['id'] = publish_distributor response, info = fetch_url( self.module, url, data=json.dumps(data), method='POST') if info['status'] != 202: self.module.fail_json( msg="Failed to publish the repo", status_code=info['status'], response=info['msg'], url=url, distributor=publish_distributor) if self.wait_for_completion: self.verify_tasks_completed(json.load(response)) return True def sync_repo(self, repo_id): url = "%s/pulp/api/v2/repositories/%s/actions/sync/" % (self.host, repo_id) response, info = fetch_url(self.module, url, data='', method='POST') if info['status'] != 202: self.module.fail_json( msg="Failed to schedule a sync of the repo.", status_code=info['status'], response=info['msg'], url=url) if self.wait_for_completion: self.verify_tasks_completed(json.load(response)) return True def update_repo_distributor_config(self, repo_id, **kwargs): url = "%s/pulp/api/v2/repositories/%s/distributors/" % (self.host, repo_id) repo_config = self.get_repo_config_by_id(repo_id) for distributor in repo_config['distributors']: distributor_url = "%s%s/" % (url, distributor['id']) data = dict() data['distributor_config'] = dict() for key, value in kwargs.items(): data['distributor_config'][key] = value response, info = fetch_url( self.module, distributor_url, data=json.dumps(data), method='PUT') if info['status'] != 202: self.module.fail_json( msg="Failed to set the relative url for the repository.", status_code=info['status'], response=info['msg'], url=url) def update_repo_importer_config(self, repo_id, **kwargs): url = "%s/pulp/api/v2/repositories/%s/importers/" % (self.host, repo_id) data = dict() importer_config = dict() for key, value in kwargs.items(): if value is not None: importer_config[key] = value data['importer_config'] = importer_config if self.repo_type == 'rpm': data['importer_type_id'] = "yum_importer" response, info = fetch_url( self.module, url, data=json.dumps(data), method='POST') if info['status'] != 202: self.module.fail_json( msg="Failed to set the repo importer configuration", status_code=info['status'], response=info['msg'], importer_config=importer_config, url=url) def set_repo_list(self): url = "%s/pulp/api/v2/repositories/?details=true" % self.host response, info = fetch_url(self.module, url, method='GET') if info['status'] != 200: self.module.fail_json( msg="Request failed", status_code=info['status'], response=info['msg'], url=url) self.repo_list = json.load(response) def verify_tasks_completed(self, response_dict): for task in response_dict['spawned_tasks']: task_url = "%s%s" % (self.host, task['_href']) while True: response, info = fetch_url( self.module, task_url, data='', method='GET') if info['status'] != 200: self.module.fail_json( msg="Failed to check async task status.", status_code=info['status'], response=info['msg'], url=task_url) task_dict = json.load(response) if task_dict['state'] == 'finished': return True if task_dict['state'] == 'error': self.module.fail_json(msg="Asynchronous task failed to complete.", error=task_dict['error']) sleep(2) def main(): argument_spec = url_argument_spec() argument_spec.update( add_export_distributor=dict(default=False, type='bool'), feed=dict(), generate_sqlite=dict(default=False, type='bool'), feed_ca_cert=dict(aliases=['importer_ssl_ca_cert', 'ca_cert'], deprecated_aliases=[dict(name='ca_cert', version='2.14')]), feed_client_cert=dict(aliases=['importer_ssl_client_cert']), feed_client_key=dict(aliases=['importer_ssl_client_key']), name=dict(required=True, aliases=['repo']), proxy_host=dict(), proxy_port=dict(), proxy_username=dict(), proxy_password=dict(no_log=True), publish_distributor=dict(), pulp_host=dict(default="https://127.0.0.1"), relative_url=dict(), repo_type=dict(default="rpm"), repoview=dict(default=False, type='bool'), serve_http=dict(default=False, type='bool'), serve_https=dict(default=True, type='bool'), state=dict( default="present", choices=['absent', 'present', 'sync', 'publish']), wait_for_completion=dict(default=False, type="bool")) module = AnsibleModule( argument_spec=argument_spec, supports_check_mode=True) add_export_distributor = module.params['add_export_distributor'] feed = module.params['feed'] generate_sqlite = module.params['generate_sqlite'] importer_ssl_ca_cert = module.params['feed_ca_cert'] importer_ssl_client_cert = module.params['feed_client_cert'] if importer_ssl_client_cert is None and module.params['client_cert'] is not None: importer_ssl_client_cert = module.params['client_cert'] module.deprecate("To specify client certificates to be used with the repo to sync, and not for communication with the " "Pulp instance, use the new options `feed_client_cert` and `feed_client_key` (available since " "Ansible 2.9.2). Until Ansible 2.14, the default value for `feed_client_cert` will be taken from " "`client_cert` if only the latter is specified", version="2.14") importer_ssl_client_key = module.params['feed_client_key'] if importer_ssl_client_key is None and module.params['client_key'] is not None: importer_ssl_client_key = module.params['client_key'] module.deprecate("In Ansible 2.9.2 `feed_client_key` option was added. Until 2.14 the default value will come from client_key option", version="2.14") proxy_host = module.params['proxy_host'] proxy_port = module.params['proxy_port'] proxy_username = module.params['proxy_username'] proxy_password = module.params['proxy_password'] publish_distributor = module.params['publish_distributor'] pulp_host = module.params['pulp_host'] relative_url = module.params['relative_url'] repo = module.params['name'] repo_type = module.params['repo_type'] repoview = module.params['repoview'] serve_http = module.params['serve_http'] serve_https = module.params['serve_https'] state = module.params['state'] wait_for_completion = module.params['wait_for_completion'] if (state == 'present') and (not relative_url): module.fail_json(msg="When state is present, relative_url is required.") # Ensure that the importer_ssl_* is the content and not a file path if importer_ssl_ca_cert is not None: importer_ssl_ca_cert_file_path = os.path.abspath(importer_ssl_ca_cert) if os.path.isfile(importer_ssl_ca_cert_file_path): importer_ssl_ca_cert_file_object = open(importer_ssl_ca_cert_file_path, 'r') try: importer_ssl_ca_cert = importer_ssl_ca_cert_file_object.read() finally: importer_ssl_ca_cert_file_object.close() if importer_ssl_client_cert is not None: importer_ssl_client_cert_file_path = os.path.abspath(importer_ssl_client_cert) if os.path.isfile(importer_ssl_client_cert_file_path): importer_ssl_client_cert_file_object = open(importer_ssl_client_cert_file_path, 'r') try: importer_ssl_client_cert = importer_ssl_client_cert_file_object.read() finally: importer_ssl_client_cert_file_object.close() if importer_ssl_client_key is not None: importer_ssl_client_key_file_path = os.path.abspath(importer_ssl_client_key) if os.path.isfile(importer_ssl_client_key_file_path): importer_ssl_client_key_file_object = open(importer_ssl_client_key_file_path, 'r') try: importer_ssl_client_key = importer_ssl_client_key_file_object.read() finally: importer_ssl_client_key_file_object.close() server = pulp_server(module, pulp_host, repo_type, wait_for_completion=wait_for_completion) server.set_repo_list() repo_exists = server.check_repo_exists(repo) changed = False if state == 'absent' and repo_exists: if not module.check_mode: server.delete_repo(repo) changed = True if state == 'sync': if not repo_exists: module.fail_json(msg="Repository was not found. The repository can not be synced.") if not module.check_mode: server.sync_repo(repo) changed = True if state == 'publish': if not repo_exists: module.fail_json(msg="Repository was not found. The repository can not be published.") if not module.check_mode: server.publish_repo(repo, publish_distributor) changed = True if state == 'present': if not repo_exists: if not module.check_mode: server.create_repo( repo_id=repo, relative_url=relative_url, feed=feed, generate_sqlite=generate_sqlite, serve_http=serve_http, serve_https=serve_https, proxy_host=proxy_host, proxy_port=proxy_port, proxy_username=proxy_username, proxy_password=proxy_password, repoview=repoview, ssl_ca_cert=importer_ssl_ca_cert, ssl_client_cert=importer_ssl_client_cert, ssl_client_key=importer_ssl_client_key, add_export_distributor=add_export_distributor) changed = True else: # Check to make sure all the settings are correct # The importer config gets overwritten on set and not updated, so # we set the whole config at the same time. if not server.compare_repo_importer_config( repo, feed=feed, proxy_host=proxy_host, proxy_port=proxy_port, proxy_username=proxy_username, proxy_password=proxy_password, ssl_ca_cert=importer_ssl_ca_cert, ssl_client_cert=importer_ssl_client_cert, ssl_client_key=importer_ssl_client_key ): if not module.check_mode: server.update_repo_importer_config( repo, feed=feed, proxy_host=proxy_host, proxy_port=proxy_port, proxy_username=proxy_username, proxy_password=proxy_password, ssl_ca_cert=importer_ssl_ca_cert, ssl_client_cert=importer_ssl_client_cert, ssl_client_key=importer_ssl_client_key) changed = True if relative_url is not None: if not server.compare_repo_distributor_config( repo, relative_url=relative_url ): if not module.check_mode: server.update_repo_distributor_config( repo, relative_url=relative_url) changed = True if not server.compare_repo_distributor_config(repo, generate_sqlite=generate_sqlite): if not module.check_mode: server.update_repo_distributor_config(repo, generate_sqlite=generate_sqlite) changed = True if not server.compare_repo_distributor_config(repo, repoview=repoview): if not module.check_mode: server.update_repo_distributor_config(repo, repoview=repoview) changed = True if not server.compare_repo_distributor_config(repo, http=serve_http): if not module.check_mode: server.update_repo_distributor_config(repo, http=serve_http) changed = True if not server.compare_repo_distributor_config(repo, https=serve_https): if not module.check_mode: server.update_repo_distributor_config(repo, https=serve_https) changed = True module.exit_json(changed=changed, repo=repo) if __name__ == '__main__': main()
gpl-3.0
ProfessionalIT/maxigenios-website
sdk/google_appengine/google/appengine/api/images/images_stub.py
2
25284
#!/usr/bin/env python # # Copyright 2007 Google Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # """Stub version of the images API.""" import datetime import logging import re import StringIO import time try: import json as simplejson except ImportError: import simplejson try: import PIL from PIL import _imaging from PIL import Image except ImportError: import _imaging # Try importing the 'Image' module directly. If that fails, try # importing it from the 'PIL' package (this is necessary to also # cover "pillow" package installations). try: import Image except ImportError: from PIL import Image from google.appengine.api import apiproxy_stub from google.appengine.api import apiproxy_stub_map from google.appengine.api import datastore from google.appengine.api import datastore_errors from google.appengine.api import datastore_types from google.appengine.api import images from google.appengine.api.blobstore import blobstore_stub from google.appengine.api.images import images_blob_stub from google.appengine.api.images import images_service_pb from google.appengine.runtime import apiproxy_errors BLOB_SERVING_URL_KIND = images_blob_stub.BLOB_SERVING_URL_KIND BMP = 'BMP' GIF = 'GIF' GS_INFO_KIND = '__GsFileInfo__' ICO = 'ICO' JPEG = 'JPEG' MAX_REQUEST_SIZE = 32 << 20 # 32MB PNG = 'PNG' RGB = 'RGB' RGBA = 'RGBA' TIFF = 'TIFF' WEBP = 'WEBP' FORMAT_LIST = [BMP, GIF, ICO, JPEG, PNG, TIFF, WEBP] EXIF_TIME_REGEX = re.compile(r'^([0-9]{4}):([0-9]{1,2}):([0-9]{1,2})' ' ([0-9]{1,2}):([0-9]{1,2})(?::([0-9]{1,2}))?') # Orientation tag id in EXIF. _EXIF_ORIENTATION_TAG = 274 # DateTimeOriginal tag in EXIF. _EXIF_DATETIMEORIGINAL_TAG = 36867 # Subset of EXIF tags. The stub is only able to extract these fields. _EXIF_TAGS = { 256: 'ImageWidth', 257: 'ImageLength', 271: 'Make', 272: 'Model', _EXIF_ORIENTATION_TAG: 'Orientation', 305: 'Software', 306: 'DateTime', 34855: 'ISOSpeedRatings', _EXIF_DATETIMEORIGINAL_TAG: 'DateTimeOriginal', 36868: 'DateTimeDigitized', 37383: 'MeteringMode', 37385: 'Flash', 41987: 'WhiteBalance'} def _ArgbToRgbaTuple(argb): """Convert from a single ARGB value to a tuple containing RGBA. Args: argb: Signed 32 bit integer containing an ARGB value. Returns: RGBA tuple. """ unsigned_argb = argb % 0x100000000 return ((unsigned_argb >> 16) & 0xFF, (unsigned_argb >> 8) & 0xFF, unsigned_argb & 0xFF, (unsigned_argb >> 24) & 0xFF) def _BackendPremultiplication(color): """Apply premultiplication and unpremultiplication to match production. Args: color: color tuple as returned by _ArgbToRgbaTuple. Returns: RGBA tuple. """ alpha = color[3] rgb = color[0:3] multiplied = [(x * (alpha + 1)) >> 8 for x in rgb] if alpha: alpha_inverse = 0xffffff / alpha unmultiplied = [(x * alpha_inverse) >> 16 for x in multiplied] else: unmultiplied = [0] * 3 return tuple(unmultiplied + [alpha]) class ImagesServiceStub(apiproxy_stub.APIProxyStub): """Stub version of images API to be used with the dev_appserver.""" def __init__(self, service_name='images', host_prefix=''): """Preloads PIL to load all modules in the unhardened environment. Args: service_name: Service name expected for all calls. host_prefix: the URL prefix (protocol://host:port) to preprend to image urls on a call to GetUrlBase. """ super(ImagesServiceStub, self).__init__( service_name, max_request_size=MAX_REQUEST_SIZE) self._blob_stub = images_blob_stub.ImagesBlobStub(host_prefix) Image.init() def _Dynamic_Composite(self, request, response): """Implementation of ImagesService::Composite. Based off documentation of the PIL library at http://www.pythonware.com/library/pil/handbook/index.htm Args: request: ImagesCompositeRequest - Contains image request info. response: ImagesCompositeResponse - Contains transformed image. Raises: ApplicationError: Bad data was provided, likely data about the dimensions. """ if (not request.canvas().width() or not request.canvas().height() or not request.image_size() or not request.options_size()): raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_TRANSFORM_DATA) if (request.canvas().width() > 4000 or request.canvas().height() > 4000 or request.options_size() > images.MAX_COMPOSITES_PER_REQUEST): raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_TRANSFORM_DATA) width = request.canvas().width() height = request.canvas().height() color = _ArgbToRgbaTuple(request.canvas().color()) color = _BackendPremultiplication(color) canvas = Image.new(RGBA, (width, height), color) sources = [] for image in request.image_list(): sources.append(self._OpenImageData(image)) for options in request.options_list(): if (options.anchor() < images.TOP_LEFT or options.anchor() > images.BOTTOM_RIGHT): raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_TRANSFORM_DATA) if options.source_index() >= len(sources) or options.source_index() < 0: raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_TRANSFORM_DATA) if options.opacity() < 0 or options.opacity() > 1: raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_TRANSFORM_DATA) source = sources[options.source_index()] x_anchor = (options.anchor() % 3) * 0.5 y_anchor = (options.anchor() / 3) * 0.5 x_offset = int(options.x_offset() + x_anchor * (width - source.size[0])) y_offset = int(options.y_offset() + y_anchor * (height - source.size[1])) if source.mode == RGBA: canvas.paste(source, (x_offset, y_offset), source) else: alpha = options.opacity() * 255 mask = Image.new('L', source.size, alpha) canvas.paste(source, (x_offset, y_offset), mask) response_value = self._EncodeImage(canvas, request.canvas().output()) response.mutable_image().set_content(response_value) def _Dynamic_Histogram(self, request, response): """Trivial implementation of an API. Based off documentation of the PIL library at http://www.pythonware.com/library/pil/handbook/index.htm Args: request: ImagesHistogramRequest - Contains the image. response: ImagesHistogramResponse - Contains histogram of the image. Raises: ApplicationError: Image was of an unsupported format. """ image = self._OpenImageData(request.image()) img_format = image.format if img_format not in FORMAT_LIST: raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.NOT_IMAGE) image = image.convert(RGBA) red = [0] * 256 green = [0] * 256 blue = [0] * 256 for pixel in image.getdata(): red[int((pixel[0] * pixel[3]) / 255)] += 1 green[int((pixel[1] * pixel[3]) / 255)] += 1 blue[int((pixel[2] * pixel[3]) / 255)] += 1 histogram = response.mutable_histogram() for value in red: histogram.add_red(value) for value in green: histogram.add_green(value) for value in blue: histogram.add_blue(value) def _Dynamic_Transform(self, request, response): """Trivial implementation of ImagesService::Transform. Based off documentation of the PIL library at http://www.pythonware.com/library/pil/handbook/index.htm Args: request: ImagesTransformRequest, contains image request info. response: ImagesTransformResponse, contains transformed image. """ original_image = self._OpenImageData(request.image()) input_settings = request.input() correct_orientation = ( input_settings.has_correct_exif_orientation() and input_settings.correct_exif_orientation() == images_service_pb.InputSettings.CORRECT_ORIENTATION) source_metadata = self._ExtractMetadata( original_image, input_settings.parse_metadata()) if input_settings.parse_metadata(): logging.info( 'Once the application is deployed, a more powerful metadata ' 'extraction will be performed which might return many more fields.') new_image = self._ProcessTransforms( original_image, request.transform_list(), correct_orientation) substitution_rgb = None if input_settings.has_transparent_substitution_rgb(): substitution_rgb = input_settings.transparent_substitution_rgb() response_value = self._EncodeImage( new_image, request.output(), substitution_rgb) response.mutable_image().set_content(response_value) response.set_source_metadata(source_metadata) def _Dynamic_GetUrlBase(self, request, response): self._blob_stub.GetUrlBase(request, response) def _Dynamic_DeleteUrlBase(self, request, response): self._blob_stub.DeleteUrlBase(request, response) def _EncodeImage(self, image, output_encoding, substitution_rgb=None): """Encode the given image and return it in string form. Args: image: PIL Image object, image to encode. output_encoding: ImagesTransformRequest.OutputSettings object. substitution_rgb: The color to use for transparent pixels if the output format does not support transparency. Returns: str - Encoded image information in given encoding format. Default is PNG. """ image_string = StringIO.StringIO() image_encoding = PNG if output_encoding.mime_type() == images_service_pb.OutputSettings.WEBP: image_encoding = WEBP if output_encoding.mime_type() == images_service_pb.OutputSettings.JPEG: image_encoding = JPEG if substitution_rgb: blue = substitution_rgb & 0xFF green = (substitution_rgb >> 8) & 0xFF red = (substitution_rgb >> 16) & 0xFF background = Image.new(RGB, image.size, (red, green, blue)) background.paste(image, mask=image.convert(RGBA).split()[3]) image = background else: image = image.convert(RGB) image.save(image_string, image_encoding) return image_string.getvalue() def _OpenImageData(self, image_data): """Open image data from ImageData protocol buffer. Args: image_data: ImageData protocol buffer containing image data or blob reference. Returns: Image containing the image data passed in or reference by blob-key. Raises: ApplicationError: Both content and blob-key are provided. NOTE: 'content' must always be set because it is a required field, however, it must be the empty string when a blob-key is provided. """ if image_data.content() and image_data.has_blob_key(): raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.INVALID_BLOB_KEY) if image_data.has_blob_key(): image = self._OpenBlob(image_data.blob_key()) else: image = self._OpenImage(image_data.content()) img_format = image.format if img_format not in FORMAT_LIST: raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.NOT_IMAGE) return image def _OpenImage(self, image): """Opens an image provided as a string. Args: image: Image data to be opened. Raises: ApplicationError: Image could not be opened or was an unsupported format. Returns: Image containing the image data passed in. """ if not image: raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.NOT_IMAGE) image = StringIO.StringIO(image) try: return Image.open(image) except IOError: raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_IMAGE_DATA) def _OpenBlob(self, blob_key): """Create an Image from the blob data read from blob_key.""" try: _ = datastore.Get( blobstore_stub.BlobstoreServiceStub.ToDatastoreBlobKey(blob_key)) except datastore_errors.Error: logging.exception('Blob with key %r does not exist', blob_key) raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.UNSPECIFIED_ERROR) blobstore_storage = apiproxy_stub_map.apiproxy.GetStub('blobstore') try: blob_file = blobstore_storage.storage.OpenBlob(blob_key) except IOError: logging.exception('Could not get file for blob_key %r', blob_key) raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_IMAGE_DATA) try: return Image.open(blob_file) except IOError: logging.exception('Could not open image %r for blob_key %r', blob_file, blob_key) raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_IMAGE_DATA) def _ValidateCropArg(self, arg): """Check an argument for the Crop transform. Args: arg: float - Argument to Crop transform to check. Raises: ApplicationError: There was a problem with the provided argument. """ if not isinstance(arg, float): raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_TRANSFORM_DATA) if 0 > arg or arg > 1.0: raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_TRANSFORM_DATA) def _CalculateNewDimensions(self, current_width, current_height, req_width, req_height, crop_to_fit, allow_stretch): """Get new resize dimensions keeping the current aspect ratio. This uses the more restricting of the two requested values to determine the new ratio. See also crop_to_fit. Args: current_width: int, current width of the image. current_height: int, current height of the image. req_width: int, requested new width of the image, 0 if unspecified. req_height: int, requested new height of the image, 0 if unspecified. crop_to_fit: bool, True if the less restricting dimension should be used. allow_stretch: bool, True is aspect ratio should be ignored. Raises: apiproxy_errors.ApplicationError: if crop_to_fit is True either req_width or req_height is 0. Returns: tuple (width, height) ints of the new dimensions. """ width_ratio = float(req_width) / current_width height_ratio = float(req_height) / current_height height = req_height width = req_width if allow_stretch or crop_to_fit: if not req_width or not req_height: raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_TRANSFORM_DATA) if not allow_stretch: if width_ratio > height_ratio: height = int(width_ratio * current_height) else: width = int(height_ratio * current_width) else: if not req_width or (width_ratio > height_ratio and req_height): width = int(height_ratio * current_width) else: height = int(width_ratio * current_height) return width, height def _Resize(self, image, transform): """Use PIL to resize the given image with the given transform. Args: image: PIL.Image.Image object to resize. transform: images_service_pb.Transform to use when resizing. Returns: PIL.Image.Image with transforms performed on it. Raises: ApplicationError: The resize data given was bad. """ width = 0 height = 0 if transform.has_width(): width = transform.width() if width < 0 or 4000 < width: raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_TRANSFORM_DATA) if transform.has_height(): height = transform.height() if height < 0 or 4000 < height: raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_TRANSFORM_DATA) crop_to_fit = transform.crop_to_fit() allow_stretch = transform.allow_stretch() current_width, current_height = image.size new_width, new_height = self._CalculateNewDimensions( current_width, current_height, width, height, crop_to_fit, allow_stretch) new_image = image.resize((new_width, new_height), Image.ANTIALIAS) if crop_to_fit and (new_width > width or new_height > height): left = int((new_width - width) * transform.crop_offset_x()) top = int((new_height - height) * transform.crop_offset_y()) right = left + width bottom = top + height new_image = new_image.crop((left, top, right, bottom)) return new_image def _Rotate(self, image, transform): """Use PIL to rotate the given image with the given transform. Args: image: PIL.Image.Image object to rotate. transform: images_service_pb.Transform to use when rotating. Returns: PIL.Image.Image with transforms performed on it. Raises: ApplicationError: Given data for the rotate was bad. """ degrees = transform.rotate() if degrees < 0 or degrees % 90 != 0: raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_TRANSFORM_DATA) degrees %= 360 degrees = 360 - degrees return image.rotate(degrees) def _Crop(self, image, transform): """Use PIL to crop the given image with the given transform. Args: image: PIL.Image.Image object to crop. transform: images_service_pb.Transform to use when cropping. Returns: PIL.Image.Image with transforms performed on it. Raises: BadRequestError if the crop data given is bad. """ left_x = 0.0 top_y = 0.0 right_x = 1.0 bottom_y = 1.0 if transform.has_crop_left_x(): left_x = transform.crop_left_x() self._ValidateCropArg(left_x) if transform.has_crop_top_y(): top_y = transform.crop_top_y() self._ValidateCropArg(top_y) if transform.has_crop_right_x(): right_x = transform.crop_right_x() self._ValidateCropArg(right_x) if transform.has_crop_bottom_y(): bottom_y = transform.crop_bottom_y() self._ValidateCropArg(bottom_y) width, height = image.size box = (int(round(left_x * width)), int(round(top_y * height)), int(round(right_x * width)), int(round(bottom_y * height))) return image.crop(box) @staticmethod def _GetExifFromImage(image): if hasattr(image, '_getexif'): try: from PIL import TiffImagePlugin return image._getexif() except ImportError: # We have not managed to get this to work in the SDK with Python # 2.5, so just catch the ImportError and pretend there is no # EXIF information of interest. logging.info('Sorry, TiffImagePlugin does not work in this environment') return None @staticmethod def _ExtractMetadata(image, parse_metadata): """Extract EXIF metadata from the image. Note that this is a much simplified version of metadata extraction. After deployment applications have access to a more powerful parser that can parse hundreds of fields from images. Args: image: PIL Image object. parse_metadata: bool, True if metadata parsing has been requested. If False the result will contain image dimensions. Returns: str - JSON encoded values with various metadata fields. """ def ExifTimeToUnixtime(exif_time): """Convert time in EXIF to unix time. Args: exif_time: str - Time from the EXIF block formated by EXIF standard. Seconds are optional. (Example: '2011:02:20 10:23:12') Returns: Integer, the time in unix fromat: seconds since the epoch. """ match = EXIF_TIME_REGEX.match(exif_time) if not match: return None try: date = datetime.datetime(*map(int, filter(None, match.groups()))) except ValueError: logging.info('Invalid date in EXIF: %s', exif_time) return None return int(time.mktime(date.timetuple())) metadata_dict = ( parse_metadata and ImagesServiceStub._GetExifFromImage(image) or {}) metadata_dict[256], metadata_dict[257] = image.size if _EXIF_DATETIMEORIGINAL_TAG in metadata_dict: date_ms = ExifTimeToUnixtime(metadata_dict[_EXIF_DATETIMEORIGINAL_TAG]) if date_ms: metadata_dict[_EXIF_DATETIMEORIGINAL_TAG] = date_ms else: del metadata_dict[_EXIF_DATETIMEORIGINAL_TAG] metadata = dict( [(_EXIF_TAGS[k], v) for k, v in metadata_dict.iteritems() if k in _EXIF_TAGS]) return simplejson.dumps(metadata) def _CorrectOrientation(self, image, orientation): """Use PIL to correct the image orientation based on its EXIF. See JEITA CP-3451 at http://www.exif.org/specifications.html, Exif 2.2, page 18. Args: image: source PIL.Image.Image object. orientation: integer in range (1,8) inclusive, corresponding the image orientation from EXIF. Returns: PIL.Image.Image with transforms performed on it. If no correction was done, it returns the input image. """ if orientation == 2: image = image.transpose(Image.FLIP_LEFT_RIGHT) elif orientation == 3: image = image.rotate(180) elif orientation == 4: image = image.transpose(Image.FLIP_TOP_BOTTOM) elif orientation == 5: image = image.transpose(Image.FLIP_TOP_BOTTOM) image = image.rotate(270) elif orientation == 6: image = image.rotate(270) elif orientation == 7: image = image.transpose(Image.FLIP_LEFT_RIGHT) image = image.rotate(270) elif orientation == 8: image = image.rotate(90) return image def _ProcessTransforms(self, image, transforms, correct_orientation): """Execute PIL operations based on transform values. Args: image: PIL.Image.Image instance, image to manipulate. transforms: list of ImagesTransformRequest.Transform objects. correct_orientation: True to indicate that image orientation should be corrected based on its EXIF. Returns: PIL.Image.Image with transforms performed on it. Raises: ApplicationError: More than one of the same type of transform was present. """ new_image = image if len(transforms) > images.MAX_TRANSFORMS_PER_REQUEST: raise apiproxy_errors.ApplicationError( images_service_pb.ImagesServiceError.BAD_TRANSFORM_DATA) orientation = 1 if correct_orientation: exif = self._GetExifFromImage(image) if not exif or _EXIF_ORIENTATION_TAG not in exif: correct_orientation = False else: orientation = exif[_EXIF_ORIENTATION_TAG] width, height = new_image.size if height > width: orientation = 1 for transform in transforms: if (correct_orientation and not (transform.has_crop_left_x() or transform.has_crop_top_y() or transform.has_crop_right_x() or transform.has_crop_bottom_y()) and not transform.has_horizontal_flip() and not transform.has_vertical_flip()): new_image = self._CorrectOrientation(new_image, orientation) correct_orientation = False if transform.has_width() or transform.has_height(): new_image = self._Resize(new_image, transform) elif transform.has_rotate(): new_image = self._Rotate(new_image, transform) elif transform.has_horizontal_flip(): new_image = new_image.transpose(Image.FLIP_LEFT_RIGHT) elif transform.has_vertical_flip(): new_image = new_image.transpose(Image.FLIP_TOP_BOTTOM) elif (transform.has_crop_left_x() or transform.has_crop_top_y() or transform.has_crop_right_x() or transform.has_crop_bottom_y()): new_image = self._Crop(new_image, transform) elif transform.has_autolevels(): logging.info('I\'m Feeling Lucky autolevels will be visible once this ' 'application is deployed.') else: logging.warn('Found no transformations found to perform.') if correct_orientation: new_image = self._CorrectOrientation(new_image, orientation) correct_orientation = False return new_image
mit
detiber/lib_openshift
lib_openshift/models/v1_deployment_cause_image_trigger.py
2
3631
# coding: utf-8 """ OpenAPI spec version: Generated by: https://github.com/swagger-api/swagger-codegen.git Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. """ from pprint import pformat from six import iteritems import re class V1DeploymentCauseImageTrigger(object): """ NOTE: This class is auto generated by the swagger code generator program. Do not edit the class manually. """ operations = [ ] # The key is attribute name # and the value is attribute type. swagger_types = { '_from': 'V1ObjectReference' } # The key is attribute name # and the value is json key in definition. attribute_map = { '_from': 'from' } def __init__(self, _from=None): """ V1DeploymentCauseImageTrigger - a model defined in Swagger """ self.__from = _from @property def _from(self): """ Gets the _from of this V1DeploymentCauseImageTrigger. From is a reference to the changed object which triggered a deployment. The field may have the kinds DockerImage, ImageStreamTag, or ImageStreamImage. :return: The _from of this V1DeploymentCauseImageTrigger. :rtype: V1ObjectReference """ return self.__from @_from.setter def _from(self, _from): """ Sets the _from of this V1DeploymentCauseImageTrigger. From is a reference to the changed object which triggered a deployment. The field may have the kinds DockerImage, ImageStreamTag, or ImageStreamImage. :param _from: The _from of this V1DeploymentCauseImageTrigger. :type: V1ObjectReference """ self.__from = _from def to_dict(self): """ Returns the model properties as a dict """ result = {} for attr, _ in iteritems(V1DeploymentCauseImageTrigger.swagger_types): value = getattr(self, attr) if isinstance(value, list): result[attr] = list(map( lambda x: x.to_dict() if hasattr(x, "to_dict") else x, value )) elif hasattr(value, "to_dict"): result[attr] = value.to_dict() elif isinstance(value, dict): result[attr] = dict(map( lambda item: (item[0], item[1].to_dict()) if hasattr(item[1], "to_dict") else item, value.items() )) else: result[attr] = value return result def to_str(self): """ Returns the string representation of the model """ return pformat(self.to_dict()) def __repr__(self): """ For `print` and `pprint` """ return self.to_str() def __eq__(self, other): """ Returns true if both objects are equal """ return self.__dict__ == other.__dict__ def __ne__(self, other): """ Returns true if both objects are not equal """ return not self == other
apache-2.0
ywcui1990/nupic.research
projects/l2_pooling/noise_tolerance_l2.py
9
19188
# Numenta Platform for Intelligent Computing (NuPIC) # Copyright (C) 2016 - 2017, Numenta, Inc. Unless you have an agreement # with Numenta, Inc., for a separate license for this software code, the # following terms and conditions apply: # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero Public License version 3 as # published by the Free Software Foundation. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. # See the GNU Affero Public License for more details. # # You should have received a copy of the GNU Affero Public License # along with this program. If not, see http://www.gnu.org/licenses. # # http://numenta.org/licenses/ # ---------------------------------------------------------------------- """ Test the noise tolerance of Layer 2 in isolation. Perform an experiment to see if L2 eventually recognizes an object. Test with various noise levels and with various column counts and synapse sample sizes. """ from collections import defaultdict import json import math import random import os import time import matplotlib.pyplot as plt import numpy as np from htmresearch.algorithms.column_pooler import ColumnPooler from htmresearch.frameworks.layers.sensor_placement import greedySensorPositions L4_CELL_COUNT = 8*1024 def createRandomObjectDescriptions(numObjects, numLocationsPerObject, featurePool=("A", "B", "C")): """ Returns {"Object 1": [(0, "C"), (1, "B"), (2, "C"), ...], "Object 2": [(0, "C"), (1, "A"), (2, "B"), ...]} """ return dict(("Object %d" % i, zip(xrange(numLocationsPerObject), [random.choice(featurePool) for _ in xrange(numLocationsPerObject)])) for i in xrange(1, numObjects + 1)) def noisy(pattern, noiseLevel, totalNumCells): """ Generate a noisy copy of a pattern. Given number of active bits w = len(pattern), deactivate noiseLevel*w cells, and activate noiseLevel*w other cells. @param pattern (set) A set of active indices @param noiseLevel (float) The percentage of the bits to shuffle @param totalNumCells (int) The number of cells in the SDR, active and inactive @return (numpy array) A noisy list of active indices """ n = int(noiseLevel * len(pattern)) noised = set(pattern) noised.difference_update(random.sample(noised, n)) for _ in xrange(n): while True: v = random.randint(0, totalNumCells - 1) if v not in pattern and v not in noised: noised.add(v) break return np.array(sorted(noised), dtype="uint32") def doExperiment(numColumns, l2Overrides, objectDescriptions, noiseMu, noiseSigma, numInitialTraversals, noiseEverywhere): """ Touch every point on an object 'numInitialTraversals' times, then evaluate whether it has inferred the object by touching every point once more and checking the number of correctly active and incorrectly active cells. @param numColumns (int) The number of sensors to use @param l2Overrides (dict) Parameters for the ColumnPooler @param objectDescriptions (dict) A mapping of object names to their feature-locations. See 'createRandomObjectDescriptions'. @param noiseMu (float) The average amount of noise in a feedforward input. The noise level for each column's input is determined once per touch. It is a gaussian distribution with mean 'noiseMu' and sigma 'noiseSigma'. @param noiseSigma (float) The sigma for the gaussian distribution of noise levels. If the noiseSigma is 0, then the noise level will always be 'noiseMu'. @param numInitialTraversals (int) The number of times to traverse the object before testing whether the object has been inferred. @param noiseEverywhere (bool) If true, add noise to every column's input, and record accuracy of every column. If false, add noise to one column's input, and only record accuracy of that column. """ # For each column, keep a mapping from feature-location names to their SDRs layer4sdr = lambda : np.array(sorted(random.sample(xrange(L4_CELL_COUNT), 40)), dtype="uint32") featureLocationSDRs = [defaultdict(layer4sdr) for _ in xrange(numColumns)] params = {"inputWidth": L4_CELL_COUNT, "lateralInputWidths": [4096]*(numColumns-1), "seed": random.randint(0, 1024)} params.update(l2Overrides) l2Columns = [ColumnPooler(**params) for _ in xrange(numColumns)] # Learn the objects objectL2Representations = {} for objectName, featureLocations in objectDescriptions.iteritems(): for featureLocationName in featureLocations: # Touch it enough times for the distal synapses to reach the # connected permanence, and then once more. for _ in xrange(4): allLateralInputs = [l2.getActiveCells() for l2 in l2Columns] for columnNumber, l2 in enumerate(l2Columns): feedforwardInput = featureLocationSDRs[columnNumber][featureLocationName] lateralInputs = [lateralInput for i, lateralInput in enumerate(allLateralInputs) if i != columnNumber] l2.compute(feedforwardInput, lateralInputs, learn=True) objectL2Representations[objectName] = [set(l2.getActiveCells()) for l2 in l2Columns] for l2 in l2Columns: l2.reset() results = [] # Try to infer the objects for objectName, featureLocations in objectDescriptions.iteritems(): for l2 in l2Columns: l2.reset() sensorPositionsIterator = greedySensorPositions(numColumns, len(featureLocations)) # Touch each location at least numInitialTouches times, and then touch it # once more, testing it. For each traversal, touch each point on the object # ~once. Not once per sensor -- just once. So we translate the "number of # traversals" into a "number of touches" according to the number of sensors. numTouchesPerTraversal = len(featureLocations) / float(numColumns) numInitialTouches = int(math.ceil(numInitialTraversals * numTouchesPerTraversal)) if noiseEverywhere: numTestTouches = int(math.ceil(1 * numTouchesPerTraversal)) else: numTestTouches = len(featureLocations) for touch in xrange(numInitialTouches + numTestTouches): sensorPositions = next(sensorPositionsIterator) # Give the system a few timesteps to settle, allowing lateral connections # to cause cells to be inhibited. for _ in xrange(3): allLateralInputs = [l2.getActiveCells() for l2 in l2Columns] for columnNumber, l2 in enumerate(l2Columns): position = sensorPositions[columnNumber] featureLocationName = featureLocations[position] feedforwardInput = featureLocationSDRs[columnNumber][featureLocationName] if noiseEverywhere or columnNumber == 0: noiseLevel = random.gauss(noiseMu, noiseSigma) noiseLevel = max(0.0, min(1.0, noiseLevel)) feedforwardInput = noisy(feedforwardInput, noiseLevel, L4_CELL_COUNT) lateralInputs = [lateralInput for i, lateralInput in enumerate(allLateralInputs) if i != columnNumber] l2.compute(feedforwardInput, lateralInputs, learn=False) if touch >= numInitialTouches: if noiseEverywhere: for columnNumber, l2 in enumerate(l2Columns): activeCells = set(l2.getActiveCells()) correctCells = objectL2Representations[objectName][columnNumber] results.append((len(activeCells & correctCells), len(activeCells - correctCells))) else: activeCells = set(l2Columns[0].getActiveCells()) correctCells = objectL2Representations[objectName][0] results.append((len(activeCells & correctCells), len(activeCells - correctCells))) return results def plotSuccessRate_varyNumColumns(noiseSigma, noiseEverywhere): """ Run and plot the experiment, varying the number of cortical columns. """ # # Run the experiment # noiseLevels = [x * 0.01 for x in xrange(0, 101, 5)] l2Overrides = {"sampleSizeDistal": 20} columnCounts = [1, 2, 3, 4] results = defaultdict(list) for trial in xrange(1): print "trial", trial objectDescriptions = createRandomObjectDescriptions(10, 10) for numColumns in columnCounts: print "numColumns", numColumns for noiseLevel in noiseLevels: r = doExperiment(numColumns, l2Overrides, objectDescriptions, noiseLevel, noiseSigma, numInitialTraversals=6, noiseEverywhere=noiseEverywhere) results[(numColumns, noiseLevel)].extend(r) # # Plot it # numCorrectActiveThreshold = 30 numIncorrectActiveThreshold = 10 plt.figure() colors = dict(zip(columnCounts, ('r', 'k', 'g', 'b'))) markers = dict(zip(columnCounts, ('o', '*', 'D', 'x'))) for numColumns in columnCounts: y = [] for noiseLevel in noiseLevels: trials = results[(numColumns, noiseLevel)] numPassed = len([True for numCorrect, numIncorrect in trials if numCorrect >= numCorrectActiveThreshold and numIncorrect <= numIncorrectActiveThreshold]) y.append(numPassed / float(len(trials))) plt.plot(noiseLevels, y, color=colors[numColumns], marker=markers[numColumns]) lgnd = plt.legend(["%d columns" % numColumns for numColumns in columnCounts], bbox_to_anchor=(1.05, 1), loc=2, borderaxespad=0.0) plt.xlabel("Mean feedforward noise level") plt.xticks([0.01 * n for n in xrange(0, 101, 10)]) plt.ylabel("Success rate") plt.yticks([0.0, 0.2, 0.4, 0.6, 0.8, 1.0]) plt.title("Inference with normally distributed noise (stdev=%.2f)" % noiseSigma) plotPath = os.path.join("plots", "successRate_varyColumnCount_sigma%.2f_%s.pdf" % (noiseSigma, time.strftime("%Y%m%d-%H%M%S"))) plt.savefig(plotPath, bbox_extra_artists=(lgnd,), bbox_inches="tight") print "Saved file %s" % plotPath def plotSuccessRate_varyDistalSampleSize(noiseSigma, noiseEverywhere): """ Run and plot the experiment, varying the distal sample size. """ # # Run the experiment # noiseLevels = [x * 0.01 for x in xrange(0, 101, 5)] noiseSigma = 0.1 sampleSizes = [13, 20, 30, 40] numColumns = 3 results = defaultdict(list) for trial in xrange(1): print "trial", trial objectDescriptions = createRandomObjectDescriptions(10, 10) for sampleSizeDistal in sampleSizes: print "sampleSizeDistal", sampleSizeDistal l2Overrides = {"sampleSizeDistal": sampleSizeDistal} for noiseLevel in noiseLevels: r = doExperiment(numColumns, l2Overrides, objectDescriptions, noiseLevel, noiseSigma, numInitialTraversals=6, noiseEverywhere=noiseEverywhere) results[(sampleSizeDistal, noiseLevel)].extend(r) # # Plot it # numCorrectActiveThreshold = 30 numIncorrectActiveThreshold = 10 plt.figure() colorList = dict(zip(sampleSizes, ('r', 'k', 'g', 'b'))) markerList = dict(zip(sampleSizes, ('o', '*', 'D', 'x'))) for sampleSizeDistal in sampleSizes: y = [] for noiseLevel in noiseLevels: trials = results[(sampleSizeDistal, noiseLevel)] numPassed = len([True for numCorrect, numIncorrect in trials if numCorrect >= numCorrectActiveThreshold and numIncorrect <= numIncorrectActiveThreshold]) y.append(numPassed / float(len(trials))) plt.plot(noiseLevels, y, color=colorList[sampleSizeDistal], marker=markerList[sampleSizeDistal]) lgnd = plt.legend(["Distal sample size %d" % sampleSizeDistal for sampleSizeDistal in sampleSizes], bbox_to_anchor=(1.05, 1), loc=2, borderaxespad=0.0) plt.xlabel("Mean feedforward noise level") plt.xticks([0.01 * n for n in xrange(0, 101, 10)]) plt.ylabel("Success rate") plt.yticks([0.0, 0.2, 0.4, 0.6, 0.8, 1.0]) plt.title("Inference with normally distributed noise (stdev=0.1)") plotPath = os.path.join("plots", "successRate_varyDistalSampleSize_sigma%.2f_%s.pdf" % (noiseSigma, time.strftime("%Y%m%d-%H%M%S"))) plt.savefig(plotPath, bbox_extra_artists=(lgnd,), bbox_inches="tight") print "Saved file %s" % plotPath def plotSuccessRate_varyProximalSampleSize(noiseSigma, noiseEverywhere): """ Run and plot the experiment, varying the proximal sample size. """ # # Run the experiment # noiseLevels = [x * 0.01 for x in xrange(0, 101, 5)] noiseSigma = 0.1 sampleSizes = [13, 20, 30, 40] numColumns = 3 results = defaultdict(list) for trial in xrange(1): print "trial", trial objectDescriptions = createRandomObjectDescriptions(10, 10) for sampleSizeProximal in sampleSizes: print "sampleSizeProximal", sampleSizeProximal l2Overrides = {"sampleSizeProximal": sampleSizeProximal} for noiseLevel in noiseLevels: r = doExperiment(numColumns, l2Overrides, objectDescriptions, noiseLevel, noiseSigma, numInitialTraversals=6, noiseEverywhere=noiseEverywhere) results[(sampleSizeProximal, noiseLevel)].extend(r) # # Plot it # numCorrectActiveThreshold = 30 numIncorrectActiveThreshold = 10 plt.figure() colorList = dict(zip(sampleSizes, ('r', 'k', 'g', 'b'))) markerList = dict(zip(sampleSizes, ('o', '*', 'D', 'x'))) for sampleSizeProximal in sampleSizes: y = [] for noiseLevel in noiseLevels: trials = results[(sampleSizeProximal, noiseLevel)] numPassed = len([True for numCorrect, numIncorrect in trials if numCorrect >= numCorrectActiveThreshold and numIncorrect <= numIncorrectActiveThreshold]) y.append(numPassed / float(len(trials))) plt.plot(noiseLevels, y, color=colorList[sampleSizeProximal], marker=markerList[sampleSizeProximal]) lgnd = plt.legend(["Proximal sample size %d" % sampleSizeProximal for sampleSizeProximal in sampleSizes], bbox_to_anchor=(1.05, 1), loc=2, borderaxespad=0.0) plt.xlabel("Mean feedforward noise level") plt.xticks([0.01 * n for n in xrange(0, 101, 10)]) plt.ylabel("Success rate") plt.yticks([0.0, 0.2, 0.4, 0.6, 0.8, 1.0]) plt.title("Inference with normally distributed noise (stdev=0.1)") plotPath = os.path.join("plots", "successRate_varyProximalSampleSize_sigma%.2f_%s.pdf" % (noiseSigma, time.strftime("%Y%m%d-%H%M%S"))) plt.savefig(plotPath, bbox_extra_artists=(lgnd,), bbox_inches="tight") print "Saved file %s" % plotPath def logCellActivity_varyNumColumns(noiseSigma, noiseEverywhere): """ Run the experiment, varying the column counts, and save each [# correctly active cells, # incorrectly active cells] pair to a JSON file that can be visualized. """ noiseLevels = [0.30, 0.40, 0.45, 0.50, 0.55, 0.60, 0.65, 0.70, 0.75, 0.80, 0.85, 0.90] l2Overrides = {"sampleSizeDistal": 20} columnCounts = [1, 2, 3, 4, 5] results = defaultdict(list) for trial in xrange(1): print "trial", trial objectDescriptions = createRandomObjectDescriptions(10, 10) for numColumns in columnCounts: print "numColumns", numColumns for noiseLevel in noiseLevels: r = doExperiment(numColumns, l2Overrides, objectDescriptions, noiseLevel, noiseSigma, numInitialTraversals=6, noiseEverywhere=noiseEverywhere) results[(numColumns, noiseLevel)].extend(r) d = [] for (numColumns, noiseLevel), cellCounts in results.iteritems(): d.append({"numColumns": numColumns, "noiseLevel": noiseLevel, "results": cellCounts}) filename = os.path.join("plots", "varyColumns_sigma%.2f_%s.json" % (noiseSigma, time.strftime("%Y%m%d-%H%M%S"))) with open(filename, "w") as fout: json.dump(d, fout) print "Wrote to", filename print "Visualize this file at: http://numenta.github.io/htmresearch/visualizations/grid-of-scatterplots/L2-columns-with-noise.html" if __name__ == "__main__": # Plot the accuracy of inference when noise is added, varying the number of # cortical columns. We find that when noise is applied at a constant equal # rate for each column, the accuracy only improves slightly with more cortical # columns. plotSuccessRate_varyNumColumns(noiseSigma=0.0, noiseEverywhere=True) # Change noise to a Gaussian random variable that is independently applied to # different columns. We find that the accuracy now improves with more cortical # columns. This means that noisy sensors benefit from having lateral input # from non-noisy sensors. The sensors that happen to have high noise levels # take advantage of the sensors that happen to have low noise levels, so the # array as a whole can partially guard itself from noise. plotSuccessRate_varyNumColumns(noiseSigma=0.1, noiseEverywhere=True) plotSuccessRate_varyNumColumns(noiseSigma=0.2, noiseEverywhere=True) # Plot the accuracy of inference when noise is added, varying the ratio of the # proximal threshold to the proximal synapse sample size. We find that this # ratio does more than any other parameter to determine at what noise level # the accuracy drop-off occurs. plotSuccessRate_varyProximalSampleSize(noiseSigma=0.1, noiseEverywhere=True) # Plot the accuracy of inference when noise is added, varying the ratio of the # distal segment activation threshold to the distal synapse sample size. We # find that increasing this ratio provides additional noise tolerance on top # of the noise tolerance provided by proximal connections. plotSuccessRate_varyDistalSampleSize(noiseSigma=0.1, noiseEverywhere=True) # Observe the impact of columns without noisy input on columns with noisy # input. Add constant noise to one column's input, and don't add noise for the # other columns. Observe what happens as more non-noisy columns are added. We # find that the lateral input from other columns can help correctly active # cells inhibit cells that shouldn't be active, but it doesn't help increase # the number of correctly active cells. So the accuracy of inference is # improved, but the confidence of the inference isn't. logCellActivity_varyNumColumns(noiseSigma=0.0, noiseEverywhere=False)
agpl-3.0
a-doumoulakis/tensorflow
tensorflow/contrib/rnn/python/kernel_tests/core_rnn_cell_test.py
9
36478
# Copyright 2015 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. # ============================================================================== """Tests for RNN cells.""" from __future__ import absolute_import from __future__ import division from __future__ import print_function import functools import numpy as np # TODO(ebrevdo): Remove once _linear is fully deprecated. # pylint: disable=protected-access from tensorflow.contrib import rnn as contrib_rnn from tensorflow.core.protobuf import config_pb2 from tensorflow.python.framework import constant_op from tensorflow.python.framework import dtypes from tensorflow.python.framework import ops from tensorflow.python.framework import random_seed from tensorflow.python.ops import array_ops from tensorflow.python.ops import init_ops from tensorflow.python.ops import math_ops from tensorflow.python.ops import random_ops from tensorflow.python.ops import rnn from tensorflow.python.ops import rnn_cell_impl from tensorflow.python.ops import variable_scope from tensorflow.python.ops import variables as variables_lib from tensorflow.python.platform import test from tensorflow.python.framework import test_util # pylint: enable=protected-access linear = rnn_cell_impl._linear class RNNCellTest(test.TestCase): def testLinear(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(1.0)): x = array_ops.zeros([1, 2]) l = linear([x], 2, False) sess.run([variables_lib.global_variables_initializer()]) res = sess.run([l], {x.name: np.array([[1., 2.]])}) self.assertAllClose(res[0], [[3.0, 3.0]]) # Checks prevent you from accidentally creating a shared function. with self.assertRaises(ValueError): l1 = linear([x], 2, False) # But you can create a new one in a new scope and share the variables. with variable_scope.variable_scope("l1") as new_scope: l1 = linear([x], 2, False) with variable_scope.variable_scope(new_scope, reuse=True): linear([l1], 2, False) self.assertEqual(len(variables_lib.trainable_variables()), 2) def testBasicRNNCell(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 2]) m = array_ops.zeros([1, 2]) cell = rnn_cell_impl.BasicRNNCell(2) g, _ = cell(x, m) self.assertEqual([ "root/basic_rnn_cell/%s:0" % rnn_cell_impl._WEIGHTS_VARIABLE_NAME, "root/basic_rnn_cell/%s:0" % rnn_cell_impl._BIAS_VARIABLE_NAME ], [v.name for v in cell.trainable_variables]) self.assertFalse(cell.non_trainable_variables) sess.run([variables_lib.global_variables_initializer()]) res = sess.run( [g], {x.name: np.array([[1., 1.]]), m.name: np.array([[0.1, 0.1]])}) self.assertEqual(res[0].shape, (1, 2)) def testBasicRNNCellNotTrainable(self): with self.test_session() as sess: def not_trainable_getter(getter, *args, **kwargs): kwargs["trainable"] = False return getter(*args, **kwargs) with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5), custom_getter=not_trainable_getter): x = array_ops.zeros([1, 2]) m = array_ops.zeros([1, 2]) cell = rnn_cell_impl.BasicRNNCell(2) g, _ = cell(x, m) self.assertFalse(cell.trainable_variables) self.assertEqual([ "root/basic_rnn_cell/%s:0" % rnn_cell_impl._WEIGHTS_VARIABLE_NAME, "root/basic_rnn_cell/%s:0" % rnn_cell_impl._BIAS_VARIABLE_NAME ], [v.name for v in cell.non_trainable_variables]) sess.run([variables_lib.global_variables_initializer()]) res = sess.run( [g], {x.name: np.array([[1., 1.]]), m.name: np.array([[0.1, 0.1]])}) self.assertEqual(res[0].shape, (1, 2)) def testGRUCell(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 2]) m = array_ops.zeros([1, 2]) g, _ = rnn_cell_impl.GRUCell(2)(x, m) sess.run([variables_lib.global_variables_initializer()]) res = sess.run( [g], {x.name: np.array([[1., 1.]]), m.name: np.array([[0.1, 0.1]])}) # Smoke test self.assertAllClose(res[0], [[0.175991, 0.175991]]) with variable_scope.variable_scope( "other", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros( [1, 3]) # Test GRUCell with input_size != num_units. m = array_ops.zeros([1, 2]) g, _ = rnn_cell_impl.GRUCell(2)(x, m) sess.run([variables_lib.global_variables_initializer()]) res = sess.run( [g], {x.name: np.array([[1., 1., 1.]]), m.name: np.array([[0.1, 0.1]])}) # Smoke test self.assertAllClose(res[0], [[0.156736, 0.156736]]) def testBasicLSTMCell(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 2]) m = array_ops.zeros([1, 8]) cell = rnn_cell_impl.MultiRNNCell( [ rnn_cell_impl.BasicLSTMCell(2, state_is_tuple=False) for _ in range(2) ], state_is_tuple=False) g, out_m = cell(x, m) expected_variable_names = [ "root/multi_rnn_cell/cell_0/basic_lstm_cell/%s:0" % rnn_cell_impl._WEIGHTS_VARIABLE_NAME, "root/multi_rnn_cell/cell_0/basic_lstm_cell/%s:0" % rnn_cell_impl._BIAS_VARIABLE_NAME, "root/multi_rnn_cell/cell_1/basic_lstm_cell/%s:0" % rnn_cell_impl._WEIGHTS_VARIABLE_NAME, "root/multi_rnn_cell/cell_1/basic_lstm_cell/%s:0" % rnn_cell_impl._BIAS_VARIABLE_NAME ] self.assertEqual( expected_variable_names, [v.name for v in cell.trainable_variables]) self.assertFalse(cell.non_trainable_variables) sess.run([variables_lib.global_variables_initializer()]) res = sess.run( [g, out_m], {x.name: np.array([[1., 1.]]), m.name: 0.1 * np.ones([1, 8])}) self.assertEqual(len(res), 2) variables = variables_lib.global_variables() self.assertEqual(expected_variable_names, [v.name for v in variables]) # The numbers in results were not calculated, this is just a smoke test. self.assertAllClose(res[0], [[0.24024698, 0.24024698]]) expected_mem = np.array([[ 0.68967271, 0.68967271, 0.44848421, 0.44848421, 0.39897051, 0.39897051, 0.24024698, 0.24024698 ]]) self.assertAllClose(res[1], expected_mem) with variable_scope.variable_scope( "other", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros( [1, 3]) # Test BasicLSTMCell with input_size != num_units. m = array_ops.zeros([1, 4]) g, out_m = rnn_cell_impl.BasicLSTMCell(2, state_is_tuple=False)(x, m) sess.run([variables_lib.global_variables_initializer()]) res = sess.run( [g, out_m], {x.name: np.array([[1., 1., 1.]]), m.name: 0.1 * np.ones([1, 4])}) self.assertEqual(len(res), 2) def testBasicLSTMCellDimension0Error(self): """Tests that dimension 0 in both(x and m) shape must be equal.""" with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): num_units = 2 state_size = num_units * 2 batch_size = 3 input_size = 4 x = array_ops.zeros([batch_size, input_size]) m = array_ops.zeros([batch_size - 1, state_size]) with self.assertRaises(ValueError): g, out_m = rnn_cell_impl.BasicLSTMCell( num_units, state_is_tuple=False)(x, m) sess.run([variables_lib.global_variables_initializer()]) sess.run([g, out_m], {x.name: 1 * np.ones([batch_size, input_size]), m.name: 0.1 * np.ones([batch_size - 1, state_size])}) def testBasicLSTMCellStateSizeError(self): """Tests that state_size must be num_units * 2.""" with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): num_units = 2 state_size = num_units * 3 # state_size must be num_units * 2 batch_size = 3 input_size = 4 x = array_ops.zeros([batch_size, input_size]) m = array_ops.zeros([batch_size, state_size]) with self.assertRaises(ValueError): g, out_m = rnn_cell_impl.BasicLSTMCell( num_units, state_is_tuple=False)(x, m) sess.run([variables_lib.global_variables_initializer()]) sess.run([g, out_m], {x.name: 1 * np.ones([batch_size, input_size]), m.name: 0.1 * np.ones([batch_size, state_size])}) def testBasicLSTMCellStateTupleType(self): with self.test_session(): with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 2]) m0 = (array_ops.zeros([1, 2]),) * 2 m1 = (array_ops.zeros([1, 2]),) * 2 cell = rnn_cell_impl.MultiRNNCell( [rnn_cell_impl.BasicLSTMCell(2) for _ in range(2)], state_is_tuple=True) self.assertTrue(isinstance(cell.state_size, tuple)) self.assertTrue( isinstance(cell.state_size[0], rnn_cell_impl.LSTMStateTuple)) self.assertTrue( isinstance(cell.state_size[1], rnn_cell_impl.LSTMStateTuple)) # Pass in regular tuples _, (out_m0, out_m1) = cell(x, (m0, m1)) self.assertTrue(isinstance(out_m0, rnn_cell_impl.LSTMStateTuple)) self.assertTrue(isinstance(out_m1, rnn_cell_impl.LSTMStateTuple)) # Pass in LSTMStateTuples variable_scope.get_variable_scope().reuse_variables() zero_state = cell.zero_state(1, dtypes.float32) self.assertTrue(isinstance(zero_state, tuple)) self.assertTrue(isinstance(zero_state[0], rnn_cell_impl.LSTMStateTuple)) self.assertTrue(isinstance(zero_state[1], rnn_cell_impl.LSTMStateTuple)) _, (out_m0, out_m1) = cell(x, zero_state) self.assertTrue(isinstance(out_m0, rnn_cell_impl.LSTMStateTuple)) self.assertTrue(isinstance(out_m1, rnn_cell_impl.LSTMStateTuple)) def testBasicLSTMCellWithStateTuple(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 2]) m0 = array_ops.zeros([1, 4]) m1 = array_ops.zeros([1, 4]) cell = rnn_cell_impl.MultiRNNCell( [ rnn_cell_impl.BasicLSTMCell(2, state_is_tuple=False) for _ in range(2) ], state_is_tuple=True) g, (out_m0, out_m1) = cell(x, (m0, m1)) sess.run([variables_lib.global_variables_initializer()]) res = sess.run([g, out_m0, out_m1], { x.name: np.array([[1., 1.]]), m0.name: 0.1 * np.ones([1, 4]), m1.name: 0.1 * np.ones([1, 4]) }) self.assertEqual(len(res), 3) # The numbers in results were not calculated, this is just a smoke test. # Note, however, these values should match the original # version having state_is_tuple=False. self.assertAllClose(res[0], [[0.24024698, 0.24024698]]) expected_mem0 = np.array( [[0.68967271, 0.68967271, 0.44848421, 0.44848421]]) expected_mem1 = np.array( [[0.39897051, 0.39897051, 0.24024698, 0.24024698]]) self.assertAllClose(res[1], expected_mem0) self.assertAllClose(res[2], expected_mem1) def testLSTMCell(self): with self.test_session() as sess: num_units = 8 num_proj = 6 state_size = num_units + num_proj batch_size = 3 input_size = 2 with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([batch_size, input_size]) m = array_ops.zeros([batch_size, state_size]) cell = rnn_cell_impl.LSTMCell( num_units=num_units, num_proj=num_proj, forget_bias=1.0, state_is_tuple=False) output, state = cell(x, m) sess.run([variables_lib.global_variables_initializer()]) res = sess.run([output, state], { x.name: np.array([[1., 1.], [2., 2.], [3., 3.]]), m.name: 0.1 * np.ones((batch_size, state_size)) }) self.assertEqual(len(res), 2) # The numbers in results were not calculated, this is mostly just a # smoke test. self.assertEqual(res[0].shape, (batch_size, num_proj)) self.assertEqual(res[1].shape, (batch_size, state_size)) # Different inputs so different outputs and states for i in range(1, batch_size): self.assertTrue( float(np.linalg.norm((res[0][0, :] - res[0][i, :]))) > 1e-6) self.assertTrue( float(np.linalg.norm((res[1][0, :] - res[1][i, :]))) > 1e-6) def testLSTMCellVariables(self): with self.test_session(): num_units = 8 num_proj = 6 state_size = num_units + num_proj batch_size = 3 input_size = 2 with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([batch_size, input_size]) m = array_ops.zeros([batch_size, state_size]) cell = rnn_cell_impl.LSTMCell( num_units=num_units, num_proj=num_proj, forget_bias=1.0, state_is_tuple=False) cell(x, m) # Execute to create variables variables = variables_lib.global_variables() self.assertEquals(variables[0].op.name, "root/lstm_cell/kernel") self.assertEquals(variables[1].op.name, "root/lstm_cell/bias") self.assertEquals(variables[2].op.name, "root/lstm_cell/projection/kernel") def testOutputProjectionWrapper(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 3]) m = array_ops.zeros([1, 3]) cell = contrib_rnn.OutputProjectionWrapper(rnn_cell_impl.GRUCell(3), 2) g, new_m = cell(x, m) sess.run([variables_lib.global_variables_initializer()]) res = sess.run([g, new_m], { x.name: np.array([[1., 1., 1.]]), m.name: np.array([[0.1, 0.1, 0.1]]) }) self.assertEqual(res[1].shape, (1, 3)) # The numbers in results were not calculated, this is just a smoke test. self.assertAllClose(res[0], [[0.231907, 0.231907]]) def testInputProjectionWrapper(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 2]) m = array_ops.zeros([1, 3]) cell = contrib_rnn.InputProjectionWrapper( rnn_cell_impl.GRUCell(3), num_proj=3) g, new_m = cell(x, m) sess.run([variables_lib.global_variables_initializer()]) res = sess.run( [g, new_m], {x.name: np.array([[1., 1.]]), m.name: np.array([[0.1, 0.1, 0.1]])}) self.assertEqual(res[1].shape, (1, 3)) # The numbers in results were not calculated, this is just a smoke test. self.assertAllClose(res[0], [[0.154605, 0.154605, 0.154605]]) def testResidualWrapper(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 3]) m = array_ops.zeros([1, 3]) base_cell = rnn_cell_impl.GRUCell(3) g, m_new = base_cell(x, m) variable_scope.get_variable_scope().reuse_variables() g_res, m_new_res = rnn_cell_impl.ResidualWrapper(base_cell)(x, m) sess.run([variables_lib.global_variables_initializer()]) res = sess.run([g, g_res, m_new, m_new_res], { x: np.array([[1., 1., 1.]]), m: np.array([[0.1, 0.1, 0.1]]) }) # Residual connections self.assertAllClose(res[1], res[0] + [1., 1., 1.]) # States are left untouched self.assertAllClose(res[2], res[3]) def testResidualWrapperWithSlice(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 5]) m = array_ops.zeros([1, 3]) base_cell = rnn_cell_impl.GRUCell(3) g, m_new = base_cell(x, m) variable_scope.get_variable_scope().reuse_variables() def residual_with_slice_fn(inp, out): inp_sliced = array_ops.slice(inp, [0, 0], [-1, 3]) return inp_sliced + out g_res, m_new_res = rnn_cell_impl.ResidualWrapper( base_cell, residual_with_slice_fn)(x, m) sess.run([variables_lib.global_variables_initializer()]) res_g, res_g_res, res_m_new, res_m_new_res = sess.run( [g, g_res, m_new, m_new_res], { x: np.array([[1., 1., 1., 1., 1.]]), m: np.array([[0.1, 0.1, 0.1]]) }) # Residual connections self.assertAllClose(res_g_res, res_g + [1., 1., 1.]) # States are left untouched self.assertAllClose(res_m_new, res_m_new_res) def testDeviceWrapper(self): with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 3]) m = array_ops.zeros([1, 3]) cell = rnn_cell_impl.DeviceWrapper(rnn_cell_impl.GRUCell(3), "/cpu:14159") outputs, _ = cell(x, m) self.assertTrue("cpu:14159" in outputs.device.lower()) def testDeviceWrapperDynamicExecutionNodesAreAllProperlyLocated(self): if not test.is_gpu_available(): # Can't perform this test w/o a GPU return gpu_dev = test.gpu_device_name() with self.test_session(use_gpu=True) as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 1, 3]) cell = rnn_cell_impl.DeviceWrapper(rnn_cell_impl.GRUCell(3), gpu_dev) with ops.device("/cpu:0"): outputs, _ = rnn.dynamic_rnn( cell=cell, inputs=x, dtype=dtypes.float32) run_metadata = config_pb2.RunMetadata() opts = config_pb2.RunOptions( trace_level=config_pb2.RunOptions.FULL_TRACE) sess.run([variables_lib.global_variables_initializer()]) _ = sess.run(outputs, options=opts, run_metadata=run_metadata) step_stats = run_metadata.step_stats ix = 0 if gpu_dev in step_stats.dev_stats[0].device else 1 gpu_stats = step_stats.dev_stats[ix].node_stats cpu_stats = step_stats.dev_stats[1 - ix].node_stats self.assertFalse([s for s in cpu_stats if "gru_cell" in s.node_name]) self.assertTrue([s for s in gpu_stats if "gru_cell" in s.node_name]) def testEmbeddingWrapper(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 1], dtype=dtypes.int32) m = array_ops.zeros([1, 2]) embedding_cell = contrib_rnn.EmbeddingWrapper( rnn_cell_impl.GRUCell(2), embedding_classes=3, embedding_size=2) self.assertEqual(embedding_cell.output_size, 2) g, new_m = embedding_cell(x, m) sess.run([variables_lib.global_variables_initializer()]) res = sess.run( [g, new_m], {x.name: np.array([[1]]), m.name: np.array([[0.1, 0.1]])}) self.assertEqual(res[1].shape, (1, 2)) # The numbers in results were not calculated, this is just a smoke test. self.assertAllClose(res[0], [[0.17139, 0.17139]]) def testEmbeddingWrapperWithDynamicRnn(self): with self.test_session() as sess: with variable_scope.variable_scope("root"): inputs = ops.convert_to_tensor([[[0], [0]]], dtype=dtypes.int64) input_lengths = ops.convert_to_tensor([2], dtype=dtypes.int64) embedding_cell = contrib_rnn.EmbeddingWrapper( rnn_cell_impl.BasicLSTMCell(1, state_is_tuple=True), embedding_classes=1, embedding_size=2) outputs, _ = rnn.dynamic_rnn( cell=embedding_cell, inputs=inputs, sequence_length=input_lengths, dtype=dtypes.float32) sess.run([variables_lib.global_variables_initializer()]) # This will fail if output's dtype is inferred from input's. sess.run(outputs) def testMultiRNNCell(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 2]) m = array_ops.zeros([1, 4]) _, ml = rnn_cell_impl.MultiRNNCell( [rnn_cell_impl.GRUCell(2) for _ in range(2)], state_is_tuple=False)(x, m) sess.run([variables_lib.global_variables_initializer()]) res = sess.run(ml, { x.name: np.array([[1., 1.]]), m.name: np.array([[0.1, 0.1, 0.1, 0.1]]) }) # The numbers in results were not calculated, this is just a smoke test. self.assertAllClose(res, [[0.175991, 0.175991, 0.13248, 0.13248]]) def testMultiRNNCellWithStateTuple(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 2]) m_bad = array_ops.zeros([1, 4]) m_good = (array_ops.zeros([1, 2]), array_ops.zeros([1, 2])) # Test incorrectness of state with self.assertRaisesRegexp(ValueError, "Expected state .* a tuple"): rnn_cell_impl.MultiRNNCell( [rnn_cell_impl.GRUCell(2) for _ in range(2)], state_is_tuple=True)(x, m_bad) _, ml = rnn_cell_impl.MultiRNNCell( [rnn_cell_impl.GRUCell(2) for _ in range(2)], state_is_tuple=True)(x, m_good) sess.run([variables_lib.global_variables_initializer()]) res = sess.run(ml, { x.name: np.array([[1., 1.]]), m_good[0].name: np.array([[0.1, 0.1]]), m_good[1].name: np.array([[0.1, 0.1]]) }) # The numbers in results were not calculated, this is just a # smoke test. However, these numbers should match those of # the test testMultiRNNCell. self.assertAllClose(res[0], [[0.175991, 0.175991]]) self.assertAllClose(res[1], [[0.13248, 0.13248]]) class DropoutWrapperTest(test.TestCase): def _testDropoutWrapper(self, batch_size=None, time_steps=None, parallel_iterations=None, **kwargs): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): if batch_size is None and time_steps is None: # 2 time steps, batch size 1, depth 3 batch_size = 1 time_steps = 2 x = constant_op.constant( [[[2., 2., 2.]], [[1., 1., 1.]]], dtype=dtypes.float32) m = rnn_cell_impl.LSTMStateTuple( *[constant_op.constant([[0.1, 0.1, 0.1]], dtype=dtypes.float32) ] * 2) else: x = constant_op.constant( np.random.randn(time_steps, batch_size, 3).astype(np.float32)) m = rnn_cell_impl.LSTMStateTuple(*[ constant_op.constant( [[0.1, 0.1, 0.1]] * batch_size, dtype=dtypes.float32) ] * 2) outputs, final_state = rnn.dynamic_rnn( cell=rnn_cell_impl.DropoutWrapper( rnn_cell_impl.LSTMCell(3), dtype=x.dtype, **kwargs), time_major=True, parallel_iterations=parallel_iterations, inputs=x, initial_state=m) sess.run([variables_lib.global_variables_initializer()]) res = sess.run([outputs, final_state]) self.assertEqual(res[0].shape, (time_steps, batch_size, 3)) self.assertEqual(res[1].c.shape, (batch_size, 3)) self.assertEqual(res[1].h.shape, (batch_size, 3)) return res def testDropoutWrapperKeepAllConstantInput(self): keep = array_ops.ones([]) res = self._testDropoutWrapper( input_keep_prob=keep, output_keep_prob=keep, state_keep_prob=keep) true_full_output = np.array( [[[0.751109, 0.751109, 0.751109]], [[0.895509, 0.895509, 0.895509]]], dtype=np.float32) true_full_final_c = np.array( [[1.949385, 1.949385, 1.949385]], dtype=np.float32) self.assertAllClose(true_full_output, res[0]) self.assertAllClose(true_full_output[1], res[1].h) self.assertAllClose(true_full_final_c, res[1].c) def testDropoutWrapperKeepAll(self): keep = variable_scope.get_variable("all", initializer=1.0) res = self._testDropoutWrapper( input_keep_prob=keep, output_keep_prob=keep, state_keep_prob=keep) true_full_output = np.array( [[[0.751109, 0.751109, 0.751109]], [[0.895509, 0.895509, 0.895509]]], dtype=np.float32) true_full_final_c = np.array( [[1.949385, 1.949385, 1.949385]], dtype=np.float32) self.assertAllClose(true_full_output, res[0]) self.assertAllClose(true_full_output[1], res[1].h) self.assertAllClose(true_full_final_c, res[1].c) def testDropoutWrapperWithSeed(self): keep_some = 0.5 random_seed.set_random_seed(2) ## Use parallel_iterations = 1 in both calls to ## _testDropoutWrapper to ensure the (per-time step) dropout is ## consistent across both calls. Otherwise the seed may not end ## up being munged consistently across both graphs. res_standard_1 = self._testDropoutWrapper( input_keep_prob=keep_some, output_keep_prob=keep_some, state_keep_prob=keep_some, seed=10, parallel_iterations=1) # Clear away the graph and the test session (which keeps variables around) ops.reset_default_graph() self._ClearCachedSession() random_seed.set_random_seed(2) res_standard_2 = self._testDropoutWrapper( input_keep_prob=keep_some, output_keep_prob=keep_some, state_keep_prob=keep_some, seed=10, parallel_iterations=1) self.assertAllClose(res_standard_1[0], res_standard_2[0]) self.assertAllClose(res_standard_1[1].c, res_standard_2[1].c) self.assertAllClose(res_standard_1[1].h, res_standard_2[1].h) def testDropoutWrapperKeepNoOutput(self): keep_all = variable_scope.get_variable("all", initializer=1.0) keep_none = variable_scope.get_variable("none", initializer=1e-10) res = self._testDropoutWrapper( input_keep_prob=keep_all, output_keep_prob=keep_none, state_keep_prob=keep_all) true_full_output = np.array( [[[0.751109, 0.751109, 0.751109]], [[0.895509, 0.895509, 0.895509]]], dtype=np.float32) true_full_final_c = np.array( [[1.949385, 1.949385, 1.949385]], dtype=np.float32) self.assertAllClose(np.zeros(res[0].shape), res[0]) self.assertAllClose(true_full_output[1], res[1].h) self.assertAllClose(true_full_final_c, res[1].c) def testDropoutWrapperKeepNoStateExceptLSTMCellMemory(self): keep_all = variable_scope.get_variable("all", initializer=1.0) keep_none = variable_scope.get_variable("none", initializer=1e-10) # Even though we dropout state, by default DropoutWrapper never # drops out the memory ("c") term of an LSTMStateTuple. res = self._testDropoutWrapper( input_keep_prob=keep_all, output_keep_prob=keep_all, state_keep_prob=keep_none) true_c_state = np.array( [[1.713925, 1.713925, 1.713925]], dtype=np.float32) true_full_output = np.array( [[[0.751109, 0.751109, 0.751109]], [[0.895509, 0.895509, 0.895509]]], dtype=np.float32) self.assertAllClose(true_full_output[0], res[0][0]) # Second output is modified by zero input state self.assertGreater(np.linalg.norm(true_full_output[1] - res[0][1]), 1e-4) # h state has been set to zero self.assertAllClose(np.zeros(res[1].h.shape), res[1].h) # c state of an LSTMStateTuple is NEVER modified. self.assertAllClose(true_c_state, res[1].c) def testDropoutWrapperKeepNoInput(self): keep_all = variable_scope.get_variable("all", initializer=1.0) keep_none = variable_scope.get_variable("none", initializer=1e-10) true_full_output = np.array( [[[0.751109, 0.751109, 0.751109]], [[0.895509, 0.895509, 0.895509]]], dtype=np.float32) true_full_final_c = np.array( [[1.949385, 1.949385, 1.949385]], dtype=np.float32) # All outputs are different because inputs are zeroed out res = self._testDropoutWrapper( input_keep_prob=keep_none, output_keep_prob=keep_all, state_keep_prob=keep_all) self.assertGreater(np.linalg.norm(res[0] - true_full_output), 1e-4) self.assertGreater(np.linalg.norm(res[1].h - true_full_output[1]), 1e-4) self.assertGreater(np.linalg.norm(res[1].c - true_full_final_c), 1e-4) def testDropoutWrapperRecurrentOutput(self): keep_some = 0.8 keep_all = variable_scope.get_variable("all", initializer=1.0) res = self._testDropoutWrapper( input_keep_prob=keep_all, output_keep_prob=keep_some, state_keep_prob=keep_all, variational_recurrent=True, input_size=3, batch_size=5, time_steps=7) # Ensure the same dropout pattern for all time steps output_mask = np.abs(res[0]) > 1e-6 for m in output_mask[1:]: self.assertAllClose(output_mask[0], m) def testDropoutWrapperRecurrentStateInputAndOutput(self): keep_some = 0.9 res = self._testDropoutWrapper( input_keep_prob=keep_some, output_keep_prob=keep_some, state_keep_prob=keep_some, variational_recurrent=True, input_size=3, batch_size=5, time_steps=7) # Smoke test for the state/input masks. output_mask = np.abs(res[0]) > 1e-6 for time_step in output_mask: # Ensure the same dropout output pattern for all time steps self.assertAllClose(output_mask[0], time_step) for batch_entry in time_step: # Assert all batch entries get the same mask self.assertAllClose(batch_entry, time_step[0]) # For state, ensure all batch entries have the same mask state_c_mask = np.abs(res[1].c) > 1e-6 state_h_mask = np.abs(res[1].h) > 1e-6 for batch_entry in state_c_mask: self.assertAllClose(batch_entry, state_c_mask[0]) for batch_entry in state_h_mask: self.assertAllClose(batch_entry, state_h_mask[0]) def testDropoutWrapperRecurrentStateInputAndOutputWithSeed(self): keep_some = 0.9 random_seed.set_random_seed(2347) np.random.seed(23487) res0 = self._testDropoutWrapper( input_keep_prob=keep_some, output_keep_prob=keep_some, state_keep_prob=keep_some, variational_recurrent=True, input_size=3, batch_size=5, time_steps=7, seed=-234987) ops.reset_default_graph() self._ClearCachedSession() random_seed.set_random_seed(2347) np.random.seed(23487) res1 = self._testDropoutWrapper( input_keep_prob=keep_some, output_keep_prob=keep_some, state_keep_prob=keep_some, variational_recurrent=True, input_size=3, batch_size=5, time_steps=7, seed=-234987) output_mask = np.abs(res0[0]) > 1e-6 for time_step in output_mask: # Ensure the same dropout output pattern for all time steps self.assertAllClose(output_mask[0], time_step) for batch_entry in time_step: # Assert all batch entries get the same mask self.assertAllClose(batch_entry, time_step[0]) # For state, ensure all batch entries have the same mask state_c_mask = np.abs(res0[1].c) > 1e-6 state_h_mask = np.abs(res0[1].h) > 1e-6 for batch_entry in state_c_mask: self.assertAllClose(batch_entry, state_c_mask[0]) for batch_entry in state_h_mask: self.assertAllClose(batch_entry, state_h_mask[0]) # Ensure seeded calculation is identical. self.assertAllClose(res0[0], res1[0]) self.assertAllClose(res0[1].c, res1[1].c) self.assertAllClose(res0[1].h, res1[1].h) class SlimRNNCellTest(test.TestCase): def testBasicRNNCell(self): with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): x = array_ops.zeros([1, 2]) m = array_ops.zeros([1, 2]) my_cell = functools.partial(basic_rnn_cell, num_units=2) # pylint: disable=protected-access g, _ = rnn_cell_impl._SlimRNNCell(my_cell)(x, m) # pylint: enable=protected-access sess.run([variables_lib.global_variables_initializer()]) res = sess.run( [g], {x.name: np.array([[1., 1.]]), m.name: np.array([[0.1, 0.1]])}) self.assertEqual(res[0].shape, (1, 2)) def testBasicRNNCellMatch(self): batch_size = 32 input_size = 100 num_units = 10 with self.test_session() as sess: with variable_scope.variable_scope( "root", initializer=init_ops.constant_initializer(0.5)): inputs = random_ops.random_uniform((batch_size, input_size)) _, initial_state = basic_rnn_cell(inputs, None, num_units) rnn_cell = rnn_cell_impl.BasicRNNCell(num_units) outputs, state = rnn_cell(inputs, initial_state) variable_scope.get_variable_scope().reuse_variables() my_cell = functools.partial(basic_rnn_cell, num_units=num_units) # pylint: disable=protected-access slim_cell = rnn_cell_impl._SlimRNNCell(my_cell) # pylint: enable=protected-access slim_outputs, slim_state = slim_cell(inputs, initial_state) self.assertEqual(slim_outputs.get_shape(), outputs.get_shape()) self.assertEqual(slim_state.get_shape(), state.get_shape()) sess.run([variables_lib.global_variables_initializer()]) res = sess.run([slim_outputs, slim_state, outputs, state]) self.assertAllClose(res[0], res[2]) self.assertAllClose(res[1], res[3]) def basic_rnn_cell(inputs, state, num_units, scope=None): if state is None: if inputs is not None: batch_size = inputs.get_shape()[0] dtype = inputs.dtype else: batch_size = 0 dtype = dtypes.float32 init_output = array_ops.zeros( array_ops.stack([batch_size, num_units]), dtype=dtype) init_state = array_ops.zeros( array_ops.stack([batch_size, num_units]), dtype=dtype) init_output.set_shape([batch_size, num_units]) init_state.set_shape([batch_size, num_units]) return init_output, init_state else: with variable_scope.variable_scope(scope, "basic_rnn_cell", [inputs, state]): output = math_ops.tanh(linear([inputs, state], num_units, True)) return output, output if __name__ == "__main__": test.main()
apache-2.0
juju-solutions/bigtop
bigtop-packages/src/charm/spark/layer-spark/lib/charms/layer/bigtop_spark.py
8
19414
# Licensed to the Apache Software Foundation (ASF) under one or more # contributor license agreements. See the NOTICE file distributed with # this work for additional information regarding copyright ownership. # The ASF licenses this file to You under the Apache License, Version 2.0 # (the "License"); you may not use this file except in compliance with # the License. You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. import os import time from jujubigdata import utils from path import Path from charms.layer.apache_bigtop_base import Bigtop from charms import layer from charmhelpers.core import hookenv, host, unitdata from charmhelpers.fetch.archiveurl import ArchiveUrlFetchHandler from charmhelpers.payload import archive class Spark(object): """ This class manages Spark. """ def __init__(self): self.dist_config = utils.DistConfig( data=layer.options('hadoop-client')) # translate our execution_mode into the appropriate --master value def get_master_url(self, spark_master_host): mode = hookenv.config()['spark_execution_mode'] zk_units = unitdata.kv().get('zookeeper.units', []) master = None if mode.startswith('local') or mode.startswith('yarn'): master = mode elif mode == 'standalone' and not zk_units: master = 'spark://{}:7077'.format(spark_master_host) elif mode == 'standalone' and zk_units: master_ips = [p[1] for p in unitdata.kv().get('sparkpeer.units')] nodes = [] for ip in master_ips: nodes.append('{}:7077'.format(ip)) nodes_str = ','.join(nodes) master = 'spark://{}'.format(nodes_str) return master def configure_sparkbench(self): """ Install/configure/remove Spark-Bench based on user config. If config[spark_bench_enabled], fetch, install, and configure Spark-Bench on initial invocation. Subsequent invocations will skip the fetch/install, but will reconfigure Spark-Bench since we may need to adjust the data dir (eg: benchmark data is stored in hdfs when spark is in yarn mode; locally in all other execution modes). """ install_sb = hookenv.config()['spark_bench_enabled'] sb_dir = '/home/ubuntu/SparkBench' if install_sb: # Fetch/install on our first go-round, then set unit data so we # don't reinstall every time this function is called. if not unitdata.kv().get('spark_bench.installed', False): sb_url = hookenv.config()['spark_bench_url'] Path(sb_dir).rmtree_p() au = ArchiveUrlFetchHandler() au.install(sb_url, '/home/ubuntu') # NB: This block is unused when using one of our sb tgzs. It # may come in handy if people want a tgz that does not expand # to our expected sb_dir. # ##### # Handle glob if we use a .tgz that doesn't expand to sb_dir # sb_archive_dir = glob('/home/ubuntu/SparkBench*')[0] # SparkBench expects to live in ~/SparkBench, so put it there # Path(sb_archive_dir).rename(sb_dir) # ##### # Ensure users in the spark group can write to any subdirectory # of sb_dir (spark needs to write benchmark output there when # running in local modes). host.chownr(Path(sb_dir), 'ubuntu', 'spark', chowntopdir=True) for r, d, f in os.walk(sb_dir): os.chmod(r, 0o2775) unitdata.kv().set('spark_bench.installed', True) unitdata.kv().flush(True) # Configure the SB env every time this function is called. sb_conf = '{}/conf'.format(sb_dir) sb_env = Path(sb_conf) / 'env.sh' if not sb_env.exists(): (Path(sb_conf) / 'env.sh.template').copy(sb_env) # NB: A few notes on configuring SparkBench: # 1. Input data has been pregenerated and packed into the tgz. All # spark cluster members will have this data locally, which enables # us to execute benchmarks in the absense of HDFS. When spark is in # yarn mode, we'll need to generate and store this data in HDFS # so nodemanagers can access it (NMs obviously won't have SB # installed locally). Set DATA_HDFS to a local dir or common HDFS # location depending on our spark execution mode. # # 2. SB tries to SSH to spark workers to purge vmem caches. This # isn't possible in containers, nor is it possible in our env # because we don't distribute ssh keys among cluster members. # Set MC_LIST to an empty string to prevent this behavior. # # 3. Throughout SB, HADOOP_HOME/bin is used as the prefix for the # hdfs command. Bigtop's hdfs lives at /usr/bin/hdfs, so set the # SB HADOOP_HOME accordingly (it's not used for anything else). # # 4. Use our MASTER envar to set the SparkBench SPARK_MASTER url. # It is updated every time we (re)configure spark. mode = hookenv.config()['spark_execution_mode'] if mode.startswith('yarn'): sb_data_dir = "hdfs:///user/ubuntu/SparkBench" else: sb_data_dir = "file://{}".format(sb_dir) utils.re_edit_in_place(sb_env, { r'^DATA_HDFS *=.*': 'DATA_HDFS="{}"'.format(sb_data_dir), r'^DATASET_DIR *=.*': 'DATASET_DIR="{}/dataset"'.format(sb_dir), r'^MC_LIST *=.*': 'MC_LIST=""', r'.*HADOOP_HOME *=.*': 'HADOOP_HOME="/usr"', r'.*SPARK_HOME *=.*': 'SPARK_HOME="/usr/lib/spark"', r'^SPARK_MASTER *=.*': 'SPARK_MASTER="$MASTER"', }) else: # config[spark_bench_enabled] is false; remove it Path(sb_dir).rmtree_p() unitdata.kv().set('spark_bench.installed', False) unitdata.kv().flush(True) def configure_examples(self): """ Install sparkpi.sh and sample data to /home/ubuntu. The sparkpi.sh script demonstrates spark-submit with the SparkPi class included with Spark. This small script is packed into the spark charm source in the ./scripts subdirectory. The sample data is used for benchmarks (only PageRank for now). This may grow quite large in the future, so we utilize Juju Resources for getting this data onto the unit. Sample data originated as follows: - PageRank: https://snap.stanford.edu/data/web-Google.html """ # Handle sparkpi.sh script_source = 'scripts/sparkpi.sh' script_path = Path(script_source) if script_path.exists(): script_target = '/home/ubuntu/sparkpi.sh' new_hash = host.file_hash(script_source) old_hash = unitdata.kv().get('sparkpi.hash') if new_hash != old_hash: hookenv.log('Installing SparkPi script') script_path.copy(script_target) Path(script_target).chmod(0o755) Path(script_target).chown('ubuntu', 'hadoop') unitdata.kv().set('sparkpi.hash', new_hash) hookenv.log('SparkPi script was installed successfully') # Handle sample data sample_source = hookenv.resource_get('sample-data') sample_path = sample_source and Path(sample_source) if sample_path and sample_path.exists() and sample_path.stat().st_size: sample_target = '/home/ubuntu' new_hash = host.file_hash(sample_source) old_hash = unitdata.kv().get('sample-data.hash') if new_hash != old_hash: hookenv.log('Extracting Spark sample data') # Extract the sample data; since sample data does not impact # functionality, log any extraction error but don't fail. try: archive.extract(sample_path, destpath=sample_target) except Exception: hookenv.log('Unable to extract Spark sample data: {}' .format(sample_path)) else: unitdata.kv().set('sample-data.hash', new_hash) hookenv.log('Spark sample data was extracted successfully') def configure_events_dir(self, mode): """ Create directory for spark event data. This directory is used by workers to store event data. It is also read by the history server when displaying event information. :param string mode: Spark execution mode to determine the dir location. """ dc = self.dist_config # Directory needs to be 777 so non-spark users can write job history # there. It needs to be g+s (HDFS is g+s by default) so all entries # are readable by spark (in the spark group). It needs to be +t so # users cannot remove files they don't own. if mode.startswith('yarn'): events_dir = 'hdfs://{}'.format(dc.path('spark_events')) utils.run_as('hdfs', 'hdfs', 'dfs', '-mkdir', '-p', events_dir) utils.run_as('hdfs', 'hdfs', 'dfs', '-chmod', '1777', events_dir) utils.run_as('hdfs', 'hdfs', 'dfs', '-chown', '-R', 'ubuntu:spark', events_dir) else: events_dir = dc.path('spark_events') events_dir.makedirs_p() events_dir.chmod(0o3777) host.chownr(events_dir, 'ubuntu', 'spark', chowntopdir=True) def configure(self, available_hosts, zk_units, peers, extra_libs): """ This is the core logic of setting up spark. :param dict available_hosts: Hosts that Spark should know about. :param list zk_units: List of Zookeeper dicts with host/port info. :param list peers: List of Spark peer tuples (unit name, IP). :param list extra_libs: List of extra lib paths for driver/executors. """ # Set KV based on connected applications unitdata.kv().set('zookeeper.units', zk_units) unitdata.kv().set('sparkpeer.units', peers) unitdata.kv().flush(True) # Get our config ready dc = self.dist_config mode = hookenv.config()['spark_execution_mode'] master_ip = utils.resolve_private_address(available_hosts['spark-master']) master_url = self.get_master_url(master_ip) req_driver_mem = hookenv.config()['driver_memory'] req_executor_mem = hookenv.config()['executor_memory'] if mode.startswith('yarn'): spark_events = 'hdfs://{}'.format(dc.path('spark_events')) else: spark_events = 'file://{}'.format(dc.path('spark_events')) # handle tuning options that may be set as percentages driver_mem = '1g' executor_mem = '1g' if req_driver_mem.endswith('%'): if mode == 'standalone' or mode.startswith('local'): mem_mb = host.get_total_ram() / 1024 / 1024 req_percentage = float(req_driver_mem.strip('%')) / 100 driver_mem = str(int(mem_mb * req_percentage)) + 'm' else: hookenv.log("driver_memory percentage in non-local mode. " "Using 1g default.", level=hookenv.WARNING) else: driver_mem = req_driver_mem if req_executor_mem.endswith('%'): if mode == 'standalone' or mode.startswith('local'): mem_mb = host.get_total_ram() / 1024 / 1024 req_percentage = float(req_executor_mem.strip('%')) / 100 executor_mem = str(int(mem_mb * req_percentage)) + 'm' else: hookenv.log("executor_memory percentage in non-local mode. " "Using 1g default.", level=hookenv.WARNING) else: executor_mem = req_executor_mem # Some spark applications look for envars in /etc/environment with utils.environment_edit_in_place('/etc/environment') as env: env['MASTER'] = master_url env['SPARK_HOME'] = dc.path('spark_home') # Setup hosts dict hosts = { 'spark': master_ip, } if 'namenode' in available_hosts: hosts['namenode'] = available_hosts['namenode'] if 'resourcemanager' in available_hosts: hosts['resourcemanager'] = available_hosts['resourcemanager'] # Setup roles dict. We always include the history server and client. # Determine other roles based on our execution mode. roles = ['spark-history-server', 'spark-client'] if mode == 'standalone': roles.append('spark-master') roles.append('spark-worker') elif mode.startswith('yarn'): roles.append('spark-on-yarn') roles.append('spark-yarn-slave') # Setup overrides dict override = { 'spark::common::master_url': master_url, 'spark::common::event_log_dir': spark_events, 'spark::common::history_log_dir': spark_events, 'spark::common::extra_lib_dirs': ':'.join(extra_libs) if extra_libs else None, 'spark::common::driver_mem': driver_mem, 'spark::common::executor_mem': executor_mem, } if zk_units: zks = [] for unit in zk_units: ip = utils.resolve_private_address(unit['host']) zks.append("%s:%s" % (ip, unit['port'])) zk_connect = ",".join(zks) override['spark::common::zookeeper_connection_string'] = zk_connect else: override['spark::common::zookeeper_connection_string'] = None # Create our site.yaml and trigger puppet. # NB: during an upgrade, we configure the site.yaml, but do not # trigger puppet. The user must do that with the 'reinstall' action. bigtop = Bigtop() bigtop.render_site_yaml(hosts, roles, override) if unitdata.kv().get('spark.version.repo', False): hookenv.log("An upgrade is available and the site.yaml has been " "configured. Run the 'reinstall' action to continue.", level=hookenv.INFO) else: bigtop.trigger_puppet() self.patch_worker_master_url(master_ip, master_url) # Packages don't create the event dir by default. Do it each time # spark is (re)installed to ensure location/perms are correct. self.configure_events_dir(mode) # Handle examples and Spark-Bench. Do this each time this method is # called in case we need to act on a new resource or user config. self.configure_examples() self.configure_sparkbench() def patch_worker_master_url(self, master_ip, master_url): """ Patch the worker startup script to use the full master url istead of contracting it. The master url is placed in the spark-env.sh so that the startup script will use it. In HA mode the master_ip is set to be the local_ip instead of the one the leader elects. This requires a restart of the master service. """ zk_units = unitdata.kv().get('zookeeper.units', []) if master_url.startswith('spark://'): if zk_units: master_ip = hookenv.unit_private_ip() spark_env = '/etc/spark/conf/spark-env.sh' utils.re_edit_in_place(spark_env, { r'.*SPARK_MASTER_URL.*': "export SPARK_MASTER_URL={}".format(master_url), r'.*SPARK_MASTER_IP.*': "export SPARK_MASTER_IP={}".format(master_ip), }, append_non_matches=True) self.inplace_change('/etc/init.d/spark-worker', 'spark://$SPARK_MASTER_IP:$SPARK_MASTER_PORT', '$SPARK_MASTER_URL') def inplace_change(self, filename, old_string, new_string): # Safely read the input filename using 'with' with open(filename) as f: s = f.read() if old_string not in s: return # Safely write the changed content, if found in the file with open(filename, 'w') as f: s = s.replace(old_string, new_string) f.write(s) def start(self): """ Always start the Spark History Server. Start other services as required by our execution mode. Open related ports as appropriate. """ host.service_start('spark-history-server') hookenv.open_port(self.dist_config.port('spark-history-ui')) # Spark master/worker is only started in standalone mode if hookenv.config()['spark_execution_mode'] == 'standalone': if host.service_start('spark-master'): hookenv.log("Spark Master started") hookenv.open_port(self.dist_config.port('spark-master-ui')) # If the master started and we have peers, wait 2m for recovery # before starting the worker. This ensures the worker binds # to the correct master. if unitdata.kv().get('sparkpeer.units'): hookenv.status_set('maintenance', 'waiting for spark master recovery') hookenv.log("Waiting 2m to ensure spark master is ALIVE") time.sleep(120) else: hookenv.log("Spark Master did not start; this is normal " "for non-leader units in standalone mode") # NB: Start the worker even if the master process on this unit # fails to start. In non-HA mode, spark master only runs on the # leader. On non-leader units, we still want a worker bound to # the leader. if host.service_start('spark-worker'): hookenv.log("Spark Worker started") hookenv.open_port(self.dist_config.port('spark-worker-ui')) else: hookenv.log("Spark Worker did not start") def stop(self): """ Stop all services (and close associated ports). Stopping a service that is not currently running does no harm. """ host.service_stop('spark-history-server') hookenv.close_port(self.dist_config.port('spark-history-ui')) # Stop the worker before the master host.service_stop('spark-worker') hookenv.close_port(self.dist_config.port('spark-worker-ui')) host.service_stop('spark-master') hookenv.close_port(self.dist_config.port('spark-master-ui'))
apache-2.0
nurmd2/nurmd
addons/sale_mrp/tests/test_sale_mrp_flow.py
23
19151
# -*- coding: utf-8 -*- from openerp.tests import common from datetime import datetime class TestSaleMrpFlow(common.TransactionCase): def setUp(self): super(TestSaleMrpFlow, self).setUp() # Useful models self.SaleOrderLine = self.env['sale.order.line'] self.SaleOrder = self.env['sale.order'] self.MrpBom = self.env['mrp.bom'] self.StockMove = self.env['stock.move'] self.MrpBomLine = self.env['mrp.bom.line'] self.ProductUom = self.env['product.uom'] self.MrpProduction = self.env['mrp.production'] self.Product = self.env['product.product'] self.ProcurementOrder = self.env['procurement.order'] self.Inventory = self.env['stock.inventory'] self.InventoryLine = self.env['stock.inventory.line'] self.ProductProduce = self.env['mrp.product.produce'] self.partner_agrolite = self.env.ref('base.res_partner_2') self.categ_unit = self.env.ref('product.product_uom_categ_unit') self.categ_kgm = self.env.ref('product.product_uom_categ_kgm') self.stock_location = self.env.ref('stock.stock_location_stock') self.warehouse = self.env.ref('stock.warehouse0') self.procurement_jit = self.env.ref('base.module_procurement_jit') def test_00_sale_mrp_flow(self): """ Test sale to mrp flow with diffrent unit of measure.""" route_manufacture = self.warehouse.manufacture_pull_id.route_id.id route_mto = self.warehouse.mto_pull_id.route_id.id def create_product(name, uom_id, route_ids=[]): return self.Product.create({ 'name': name, 'type': 'product', 'uom_id': uom_id, 'uom_po_id': uom_id, 'route_ids': route_ids}) def create_bom_lines(bom_id, product_id, qty, uom_id): self.MrpBomLine.create({ 'product_id': product_id, 'product_qty': qty, 'bom_id': bom_id, 'product_uom': uom_id}) def create_bom(product_tmpl_id, qty, uom_id, bom_type): return self.MrpBom.create({ 'product_tmpl_id': product_tmpl_id, 'product_qty': qty, 'type': bom_type, 'product_efficiency': 1.0, 'product_uom': uom_id}) self.uom_kg = self.ProductUom.create({ 'name': 'Test-KG', 'category_id': self.categ_kgm.id, 'factor_inv': 1, 'factor': 1, 'uom_type': 'reference', 'rounding': 0.000001}) self.uom_gm = self.ProductUom.create({ 'name': 'Test-G', 'category_id': self.categ_kgm.id, 'uom_type': 'smaller', 'factor': 1000.0, 'rounding': 0.001}) self.uom_unit = self.ProductUom.create({ 'name': 'Test-Unit', 'category_id': self.categ_unit.id, 'factor': 1, 'uom_type': 'reference', 'rounding': 1.0}) self.uom_dozen = self.ProductUom.create({ 'name': 'Test-DozenA', 'category_id': self.categ_unit.id, 'factor_inv': 12, 'uom_type': 'bigger', 'rounding': 0.001}) # Create product A, B, C, D. # -------------------------- product_a = create_product('Product A', self.uom_unit.id, route_ids=[(6, 0, [route_manufacture, route_mto])]) product_c = create_product('Product C', self.uom_kg.id, route_ids=[]) product_b = create_product('Product B', self.uom_dozen.id, route_ids=[(6, 0, [route_manufacture, route_mto])]) product_d = create_product('Product D', self.uom_unit.id, route_ids=[(6, 0, [route_manufacture, route_mto])]) # ------------------------------------------------------------------------------------------ # Bill of materials for product A, B, D. # ------------------------------------------------------------------------------------------ # Bill of materials for Product A. bom_a = create_bom(product_a.product_tmpl_id.id, 2, self.uom_dozen.id, 'normal') create_bom_lines(bom_a.id, product_b.id, 3, self.uom_unit.id) create_bom_lines(bom_a.id, product_c.id, 300.5, self.uom_gm.id) create_bom_lines(bom_a.id, product_d.id, 4, self.uom_unit.id) # Bill of materials for Product B. bom_b = create_bom(product_b.product_tmpl_id.id, 1, self.uom_unit.id, 'phantom') create_bom_lines(bom_b.id, product_c.id, 0.400, self.uom_kg.id) # Bill of materials for Product D. bom_d = create_bom(product_d.product_tmpl_id.id, 1, self.uom_unit.id, 'normal') create_bom_lines(bom_d.id, product_c.id, 1, self.uom_kg.id) # ---------------------------------------- # Create sale order of 10 Dozen product A. # ---------------------------------------- order = self.SaleOrder.create({ 'partner_id': self.partner_agrolite.id, 'partner_invoice_id': self.partner_agrolite.id, 'partner_shipping_id': self.partner_agrolite.id, 'date_order': datetime.today(), 'pricelist_id': self.env.ref('product.list0').id, }) self.SaleOrderLine.create({ 'name': product_a.name, 'order_id': order.id, 'product_id': product_a.id, 'product_uom_qty': 10, 'product_uom': self.uom_dozen.id }) self.assertTrue(order, "Sale order not created.") order.action_confirm() # =============================================================================== # Sale order of 10 Dozen product A should create production order # like .. # =============================================================================== # Product A 10 Dozen. # Product C 6 kg # As product B phantom in bom A, product A will consume product C # ================================================================ # For 1 unit product B it will consume 400 gm # then for 15 unit (Product B 3 unit per 2 Dozen product A) # product B it will consume [ 6 kg ] product C) # Product A will consume 6 kg product C. # # [15 * 400 gm ( 6 kg product C)] = 6 kg product C # # Product C 1502.5 gm. # [ # For 2 Dozen product A will consume 300.5 gm product C # then for 10 Dozen product A will consume 1502.5 gm product C. # ] # # product D 20 Unit. # [ # For 2 dozen product A will consume 4 unit product D # then for 10 Dozen product A will consume 20 unit of product D. # ] # -------------------------------------------------------------------------------- # <><><><><><><><><><><><><><><><><><><><> # Check manufacturing order for product A. # <><><><><><><><><><><><><><><><><><><><> # Run procurement. # ---------------- self.ProcurementOrder.run_scheduler() mnf_product_a = self.ProcurementOrder.search([('product_id', '=', product_a.id), ('group_id', '=', order.procurement_group_id.id), ('production_id', '!=', False)]).production_id # Check quantity, unit of measure and state of manufacturing order. # ----------------------------------------------------------------- self.assertTrue(mnf_product_a, 'Manufacturing order not created.') self.assertEqual(mnf_product_a.product_qty, 10, 'Wrong product quantity in manufacturing order.') self.assertEqual(mnf_product_a.product_uom.id, self.uom_dozen.id, 'Wrong unit of measure in manufacturing order.') self.assertEqual(mnf_product_a.state, 'confirmed', 'Manufacturing order should be confirmed.') # ------------------------------------------------------------------------------------------ # Check 'To consume line' for production order of product A. # ------------------------------------------------------------------------------------------ # Check 'To consume line' with product c and uom kg. # ------------------------------------------------- moves = self.StockMove.search([ ('raw_material_production_id', '=', mnf_product_a.id), ('product_id', '=', product_c.id), ('product_uom', '=', self.uom_kg.id)]) # Check total consume line with product c and uom kg. self.assertEqual(len(moves), 1, 'Production move lines are not generated proper.') list_qty = {move.product_uom_qty for move in moves} self.assertEqual(list_qty, {6.0}, "Wrong product quantity in 'To consume line' of manufacturing order.") # Check state of consume line with product c and uom kg. for move in moves: self.assertEqual(move.state, 'confirmed', "Wrong state in 'To consume line' of manufacturing order.") # Check 'To consume line' with product c and uom gm. # --------------------------------------------------- move = self.StockMove.search([ ('raw_material_production_id', '=', mnf_product_a.id), ('product_id', '=', product_c.id), ('product_uom', '=', self.uom_gm.id)]) # Check total consume line of product c with gm. self.assertEqual(len(move), 1, 'Production move lines are not generated proper.') # Check quantity should be with 1502.5 ( 2 Dozen product A consume 300.5 gm then 10 Dozen (300.5 * (10/2)). self.assertEqual(move.product_uom_qty, 1502.5, "Wrong product quantity in 'To consume line' of manufacturing order.") # Check state of consume line with product c with and uom gm. self.assertEqual(move.state, 'confirmed', "Wrong state in 'To consume line' of manufacturing order.") # Check 'To consume line' with product D. # --------------------------------------- move = self.StockMove.search([ ('raw_material_production_id', '=', mnf_product_a.id), ('product_id', '=', product_d.id)]) # Check total consume line with product D. self.assertEqual(len(move), 1, 'Production lines are not generated proper.') # <><><><><><><><><><><><><><><><><><><><><><> # Manufacturing order for product D (20 unit). # <><><><><><><><><><><><><><><><><><><><><><> procurement_d = self.ProcurementOrder.search([('product_id', '=', product_d.id), ('group_id', '=', order.procurement_group_id.id)]) # Check total consume line with product c and uom kg. self.assertEqual(len(procurement_d), 1, 'Procurement order not generated.') self.assertTrue(procurement_d.production_id, 'Production order not generated from procurement.') mnf_product_d = procurement_d.production_id # Check state of production order D. self.assertEqual(mnf_product_d.state, 'confirmed', 'Manufacturing order should be confirmed.') # Check 'To consume line' state, quantity, uom of production order (product D). # ----------------------------------------------------------------------------- move = self.StockMove.search([('raw_material_production_id', '=', mnf_product_d.id), ('product_id', '=', product_c.id)]) self.assertEqual(move.product_uom_qty, 20, "Wrong product quantity in 'To consume line' of manufacturing order.") self.assertEqual(move.product_uom.id, self.uom_kg.id, "Wrong unit of measure in 'To consume line' of manufacturing order.") self.assertEqual(move.state, 'confirmed', "Wrong state in 'To consume line' of manufacturing order.") # ------------------------------- # Create inventory for product c. # ------------------------------- # Need 20 kg product c to produce 20 unit product D. # -------------------------------------------------- inventory = self.Inventory.create({ 'name': 'Inventory Product KG', 'product_id': product_c.id, 'filter': 'product'}) inventory.prepare_inventory() self.assertFalse(inventory.line_ids, "Inventory line should not created.") self.InventoryLine.create({ 'inventory_id': inventory.id, 'product_id': product_c.id, 'product_uom_id': self.uom_kg.id, 'product_qty': 20, 'location_id': self.stock_location.id}) inventory.action_done() # -------------------------------------------------- # Assign product c to manufacturing order of product D. # -------------------------------------------------- mnf_product_d.action_assign() self.assertEqual(mnf_product_d.state, 'ready', 'Manufacturing order should be ready.') self.assertEqual(move.state, 'assigned', "Wrong state in 'To consume line' of manufacturing order.") # ------------------ # produce product D. # ------------------ produce_d = self.ProductProduce.with_context({'active_ids': [mnf_product_d.id], 'active_id': mnf_product_d.id}).create({ 'mode': 'consume_produce', 'product_qty': 20}) lines = produce_d.on_change_qty(mnf_product_d.product_qty, []) produce_d.write(lines['value']) produce_d.do_produce() # Check state of manufacturing order. self.assertEqual(mnf_product_d.state, 'done', 'Manufacturing order should be done.') # Check available quantity of product D. self.assertEqual(product_d.qty_available, 20, 'Wrong quantity available of product D.') # ----------------------------------------------------------------- # Check product D assigned or not to production order of product A. # ----------------------------------------------------------------- self.assertEqual(mnf_product_a.state, 'confirmed', 'Manufacturing order should be confirmed.') move = self.StockMove.search([('raw_material_production_id', '=', mnf_product_a.id), ('product_id', '=', product_d.id)]) self.assertEqual(move.state, 'assigned', "Wrong state in 'To consume line' of manufacturing order.") # Create inventry for product C. # ------------------------------ # Need product C ( 20 kg + 6 kg + 1502.5 gm = 27.5025 kg) # ------------------------------------------------------- inventory = self.Inventory.create({ 'name': 'Inventory Product C KG', 'product_id': product_c.id, 'filter': 'product'}) inventory.prepare_inventory() self.assertFalse(inventory.line_ids, "Inventory line should not created.") self.InventoryLine.create({ 'inventory_id': inventory.id, 'product_id': product_c.id, 'product_uom_id': self.uom_kg.id, 'product_qty': 27.5025, 'location_id': self.stock_location.id}) inventory.action_done() # Assign product to manufacturing order of product A. # --------------------------------------------------- mnf_product_a.action_assign() self.assertEqual(mnf_product_a.state, 'ready', 'Manufacturing order should be ready.') moves = self.StockMove.search([('raw_material_production_id', '=', mnf_product_a.id), ('product_id', '=', product_c.id)]) # Check product c move line state. for move in moves: self.assertEqual(move.state, 'assigned', "Wrong state in 'To consume line' of manufacturing order.") # Produce product A. # ------------------ produce_a = self.ProductProduce.with_context( {'active_ids': [mnf_product_a.id], 'active_id': mnf_product_a.id}).create({'mode': 'consume_produce'}) lines = produce_a.on_change_qty(mnf_product_a.product_qty, []) produce_a.write(lines['value']) produce_a.do_produce() # Check state of manufacturing order product A. self.assertEqual(mnf_product_a.state, 'done', 'Manufacturing order should be done.') # Check product A avaialble quantity should be 120. self.assertEqual(product_a.qty_available, 120, 'Wrong quantity available of product A.') def test_01_sale_mrp_delivery_kit(self): """ Test delivered quantity on SO based on delivered quantity in pickings.""" # intial so self.partner = self.env.ref('base.res_partner_1') self.product = self.env.ref('product.product_product_3') so_vals = { 'partner_id': self.partner.id, 'partner_invoice_id': self.partner.id, 'partner_shipping_id': self.partner.id, 'order_line': [(0, 0, {'name': self.product.name, 'product_id': self.product.id, 'product_uom_qty': 5, 'product_uom': self.product.uom_id.id, 'price_unit': self.product.list_price})], 'pricelist_id': self.env.ref('product.list0').id, } self.so = self.SaleOrder.create(so_vals) # confirm our standard so, check the picking self.so.action_confirm() self.assertTrue(self.so.picking_ids, 'Sale MRP: no picking created for "invoice on delivery" stockable products') # invoice in on delivery, nothing should be invoiced self.so.action_invoice_create() self.assertEqual(self.so.invoice_status, 'no', 'Sale MRP: so invoice_status should be "nothing to invoice" after invoicing') # deliver partially (1 of each instead of 5), check the so's invoice_status and delivered quantities pick = self.so.picking_ids pick.force_assign() pick.pack_operation_product_ids.write({'qty_done': 1}) wiz_act = pick.do_new_transfer() wiz = self.env[wiz_act['res_model']].browse(wiz_act['res_id']) wiz.process() self.assertEqual(self.so.invoice_status, 'no', 'Sale MRP: so invoice_status should be "no" after partial delivery of a kit') del_qty = sum(sol.qty_delivered for sol in self.so.order_line) self.assertEqual(del_qty, 0.0, 'Sale MRP: delivered quantity should be zero after partial delivery of a kit') # deliver remaining products, check the so's invoice_status and delivered quantities self.assertEqual(len(self.so.picking_ids), 2, 'Sale MRP: number of pickings should be 2') pick_2 = self.so.picking_ids[0] pick_2.force_assign() pick_2.pack_operation_product_ids.write({'qty_done': 4}) pick_2.do_new_transfer() del_qty = sum(sol.qty_delivered for sol in self.so.order_line) self.assertEqual(del_qty, 5.0, 'Sale MRP: delivered quantity should be 5.0 after complete delivery of a kit') self.assertEqual(self.so.invoice_status, 'to invoice', 'Sale MRP: so invoice_status should be "to invoice" after complete delivery of a kit')
gpl-3.0
wwaites/swipy
tests/test_30_entail.py
1
1424
from rdflib.graph import Graph from rdflib.term import URIRef from swipy.store import SWIStore from os import path, stat owl_test = path.join(path.dirname(__file__), "owl.rdf") skos_test = path.join(path.dirname(__file__), "skos.rdf") cofog_test = path.join(path.dirname(__file__), "cofog-1999.rdf") entail_test = path.join(path.dirname(__file__), "entail.n3") class TestClass: def test_00_triples(self): def _count(): i = 0 for i, (statement, ctx) in enumerate(store.triples((None, None, None))): pass return i store = SWIStore() store.load(owl_test) store.load(skos_test) store.load(cofog_test) graph = Graph(store, "entailment") assert _count() == 3560 open("test.n3", "w+").write(graph.serialize(format="n3")) store.entailment = "none" assert _count() == 3558 open("test-none.n3", "w+").write(graph.serialize(format="n3")) store.entailment = "rdf" assert _count() == 5871 open("test-rdf.n3", "w+").write(graph.serialize(format="n3")) store.entailment = "rdfs" assert _count() == 6562 open("test-rdfs.n3", "w+").write(graph.serialize(format="n3")) store.unload() def test_10_n3(self): store = SWIStore() graph = Graph(store, "entailment") store.load(entail_test, format="n3") store.entailment = "n3" i = 0 for i, k in enumerate(store.triples((None, None, None))): pass print i assert i == 2 ## bah, side-effect: we have a duplicate rule compiled!
gpl-3.0
lhilt/scipy
scipy/interpolate/interpolate.py
4
97600
from __future__ import division, print_function, absolute_import __all__ = ['interp1d', 'interp2d', 'lagrange', 'PPoly', 'BPoly', 'NdPPoly', 'RegularGridInterpolator', 'interpn'] import itertools import warnings import functools import operator import numpy as np from numpy import (array, transpose, searchsorted, atleast_1d, atleast_2d, ravel, poly1d, asarray, intp) import scipy.special as spec from scipy.special import comb from scipy._lib.six import xrange, integer_types, string_types from . import fitpack from . import dfitpack from . import _fitpack from .polyint import _Interpolator1D from . import _ppoly from .fitpack2 import RectBivariateSpline from .interpnd import _ndim_coords_from_arrays from ._bsplines import make_interp_spline, BSpline def prod(x): """Product of a list of numbers; ~40x faster vs np.prod for Python tuples""" if len(x) == 0: return 1 return functools.reduce(operator.mul, x) def lagrange(x, w): r""" Return a Lagrange interpolating polynomial. Given two 1-D arrays `x` and `w,` returns the Lagrange interpolating polynomial through the points ``(x, w)``. Warning: This implementation is numerically unstable. Do not expect to be able to use more than about 20 points even if they are chosen optimally. Parameters ---------- x : array_like `x` represents the x-coordinates of a set of datapoints. w : array_like `w` represents the y-coordinates of a set of datapoints, i.e. f(`x`). Returns ------- lagrange : `numpy.poly1d` instance The Lagrange interpolating polynomial. Examples -------- Interpolate :math:`f(x) = x^3` by 3 points. >>> from scipy.interpolate import lagrange >>> x = np.array([0, 1, 2]) >>> y = x**3 >>> poly = lagrange(x, y) Since there are only 3 points, Lagrange polynomial has degree 2. Explicitly, it is given by .. math:: \begin{aligned} L(x) &= 1\times \frac{x (x - 2)}{-1} + 8\times \frac{x (x-1)}{2} \\ &= x (-2 + 3x) \end{aligned} >>> from numpy.polynomial.polynomial import Polynomial >>> Polynomial(poly).coef array([ 3., -2., 0.]) """ M = len(x) p = poly1d(0.0) for j in xrange(M): pt = poly1d(w[j]) for k in xrange(M): if k == j: continue fac = x[j]-x[k] pt *= poly1d([1.0, -x[k]])/fac p += pt return p # !! Need to find argument for keeping initialize. If it isn't # !! found, get rid of it! class interp2d(object): """ interp2d(x, y, z, kind='linear', copy=True, bounds_error=False, fill_value=None) Interpolate over a 2-D grid. `x`, `y` and `z` are arrays of values used to approximate some function f: ``z = f(x, y)``. This class returns a function whose call method uses spline interpolation to find the value of new points. If `x` and `y` represent a regular grid, consider using RectBivariateSpline. Note that calling `interp2d` with NaNs present in input values results in undefined behaviour. Methods ------- __call__ Parameters ---------- x, y : array_like Arrays defining the data point coordinates. If the points lie on a regular grid, `x` can specify the column coordinates and `y` the row coordinates, for example:: >>> x = [0,1,2]; y = [0,3]; z = [[1,2,3], [4,5,6]] Otherwise, `x` and `y` must specify the full coordinates for each point, for example:: >>> x = [0,1,2,0,1,2]; y = [0,0,0,3,3,3]; z = [1,2,3,4,5,6] If `x` and `y` are multi-dimensional, they are flattened before use. z : array_like The values of the function to interpolate at the data points. If `z` is a multi-dimensional array, it is flattened before use. The length of a flattened `z` array is either len(`x`)*len(`y`) if `x` and `y` specify the column and row coordinates or ``len(z) == len(x) == len(y)`` if `x` and `y` specify coordinates for each point. kind : {'linear', 'cubic', 'quintic'}, optional The kind of spline interpolation to use. Default is 'linear'. copy : bool, optional If True, the class makes internal copies of x, y and z. If False, references may be used. The default is to copy. bounds_error : bool, optional If True, when interpolated values are requested outside of the domain of the input data (x,y), a ValueError is raised. If False, then `fill_value` is used. fill_value : number, optional If provided, the value to use for points outside of the interpolation domain. If omitted (None), values outside the domain are extrapolated via nearest-neighbor extrapolation. See Also -------- RectBivariateSpline : Much faster 2D interpolation if your input data is on a grid bisplrep, bisplev : Spline interpolation based on FITPACK BivariateSpline : a more recent wrapper of the FITPACK routines interp1d : one dimension version of this function Notes ----- The minimum number of data points required along the interpolation axis is ``(k+1)**2``, with k=1 for linear, k=3 for cubic and k=5 for quintic interpolation. The interpolator is constructed by `bisplrep`, with a smoothing factor of 0. If more control over smoothing is needed, `bisplrep` should be used directly. Examples -------- Construct a 2-D grid and interpolate on it: >>> from scipy import interpolate >>> x = np.arange(-5.01, 5.01, 0.25) >>> y = np.arange(-5.01, 5.01, 0.25) >>> xx, yy = np.meshgrid(x, y) >>> z = np.sin(xx**2+yy**2) >>> f = interpolate.interp2d(x, y, z, kind='cubic') Now use the obtained interpolation function and plot the result: >>> import matplotlib.pyplot as plt >>> xnew = np.arange(-5.01, 5.01, 1e-2) >>> ynew = np.arange(-5.01, 5.01, 1e-2) >>> znew = f(xnew, ynew) >>> plt.plot(x, z[0, :], 'ro-', xnew, znew[0, :], 'b-') >>> plt.show() """ def __init__(self, x, y, z, kind='linear', copy=True, bounds_error=False, fill_value=None): x = ravel(x) y = ravel(y) z = asarray(z) rectangular_grid = (z.size == len(x) * len(y)) if rectangular_grid: if z.ndim == 2: if z.shape != (len(y), len(x)): raise ValueError("When on a regular grid with x.size = m " "and y.size = n, if z.ndim == 2, then z " "must have shape (n, m)") if not np.all(x[1:] >= x[:-1]): j = np.argsort(x) x = x[j] z = z[:, j] if not np.all(y[1:] >= y[:-1]): j = np.argsort(y) y = y[j] z = z[j, :] z = ravel(z.T) else: z = ravel(z) if len(x) != len(y): raise ValueError( "x and y must have equal lengths for non rectangular grid") if len(z) != len(x): raise ValueError( "Invalid length for input z for non rectangular grid") try: kx = ky = {'linear': 1, 'cubic': 3, 'quintic': 5}[kind] except KeyError: raise ValueError("Unsupported interpolation type.") if not rectangular_grid: # TODO: surfit is really not meant for interpolation! self.tck = fitpack.bisplrep(x, y, z, kx=kx, ky=ky, s=0.0) else: nx, tx, ny, ty, c, fp, ier = dfitpack.regrid_smth( x, y, z, None, None, None, None, kx=kx, ky=ky, s=0.0) self.tck = (tx[:nx], ty[:ny], c[:(nx - kx - 1) * (ny - ky - 1)], kx, ky) self.bounds_error = bounds_error self.fill_value = fill_value self.x, self.y, self.z = [array(a, copy=copy) for a in (x, y, z)] self.x_min, self.x_max = np.amin(x), np.amax(x) self.y_min, self.y_max = np.amin(y), np.amax(y) def __call__(self, x, y, dx=0, dy=0, assume_sorted=False): """Interpolate the function. Parameters ---------- x : 1D array x-coordinates of the mesh on which to interpolate. y : 1D array y-coordinates of the mesh on which to interpolate. dx : int >= 0, < kx Order of partial derivatives in x. dy : int >= 0, < ky Order of partial derivatives in y. assume_sorted : bool, optional If False, values of `x` and `y` can be in any order and they are sorted first. If True, `x` and `y` have to be arrays of monotonically increasing values. Returns ------- z : 2D array with shape (len(y), len(x)) The interpolated values. """ x = atleast_1d(x) y = atleast_1d(y) if x.ndim != 1 or y.ndim != 1: raise ValueError("x and y should both be 1-D arrays") if not assume_sorted: x = np.sort(x) y = np.sort(y) if self.bounds_error or self.fill_value is not None: out_of_bounds_x = (x < self.x_min) | (x > self.x_max) out_of_bounds_y = (y < self.y_min) | (y > self.y_max) any_out_of_bounds_x = np.any(out_of_bounds_x) any_out_of_bounds_y = np.any(out_of_bounds_y) if self.bounds_error and (any_out_of_bounds_x or any_out_of_bounds_y): raise ValueError("Values out of range; x must be in %r, y in %r" % ((self.x_min, self.x_max), (self.y_min, self.y_max))) z = fitpack.bisplev(x, y, self.tck, dx, dy) z = atleast_2d(z) z = transpose(z) if self.fill_value is not None: if any_out_of_bounds_x: z[:, out_of_bounds_x] = self.fill_value if any_out_of_bounds_y: z[out_of_bounds_y, :] = self.fill_value if len(z) == 1: z = z[0] return array(z) def _check_broadcast_up_to(arr_from, shape_to, name): """Helper to check that arr_from broadcasts up to shape_to""" shape_from = arr_from.shape if len(shape_to) >= len(shape_from): for t, f in zip(shape_to[::-1], shape_from[::-1]): if f != 1 and f != t: break else: # all checks pass, do the upcasting that we need later if arr_from.size != 1 and arr_from.shape != shape_to: arr_from = np.ones(shape_to, arr_from.dtype) * arr_from return arr_from.ravel() # at least one check failed raise ValueError('%s argument must be able to broadcast up ' 'to shape %s but had shape %s' % (name, shape_to, shape_from)) def _do_extrapolate(fill_value): """Helper to check if fill_value == "extrapolate" without warnings""" return (isinstance(fill_value, string_types) and fill_value == 'extrapolate') class interp1d(_Interpolator1D): """ Interpolate a 1-D function. `x` and `y` are arrays of values used to approximate some function f: ``y = f(x)``. This class returns a function whose call method uses interpolation to find the value of new points. Note that calling `interp1d` with NaNs present in input values results in undefined behaviour. Parameters ---------- x : (N,) array_like A 1-D array of real values. y : (...,N,...) array_like A N-D array of real values. The length of `y` along the interpolation axis must be equal to the length of `x`. kind : str or int, optional Specifies the kind of interpolation as a string ('linear', 'nearest', 'zero', 'slinear', 'quadratic', 'cubic', 'previous', 'next', where 'zero', 'slinear', 'quadratic' and 'cubic' refer to a spline interpolation of zeroth, first, second or third order; 'previous' and 'next' simply return the previous or next value of the point) or as an integer specifying the order of the spline interpolator to use. Default is 'linear'. axis : int, optional Specifies the axis of `y` along which to interpolate. Interpolation defaults to the last axis of `y`. copy : bool, optional If True, the class makes internal copies of x and y. If False, references to `x` and `y` are used. The default is to copy. bounds_error : bool, optional If True, a ValueError is raised any time interpolation is attempted on a value outside of the range of x (where extrapolation is necessary). If False, out of bounds values are assigned `fill_value`. By default, an error is raised unless ``fill_value="extrapolate"``. fill_value : array-like or (array-like, array_like) or "extrapolate", optional - if a ndarray (or float), this value will be used to fill in for requested points outside of the data range. If not provided, then the default is NaN. The array-like must broadcast properly to the dimensions of the non-interpolation axes. - If a two-element tuple, then the first element is used as a fill value for ``x_new < x[0]`` and the second element is used for ``x_new > x[-1]``. Anything that is not a 2-element tuple (e.g., list or ndarray, regardless of shape) is taken to be a single array-like argument meant to be used for both bounds as ``below, above = fill_value, fill_value``. .. versionadded:: 0.17.0 - If "extrapolate", then points outside the data range will be extrapolated. .. versionadded:: 0.17.0 assume_sorted : bool, optional If False, values of `x` can be in any order and they are sorted first. If True, `x` has to be an array of monotonically increasing values. Attributes ---------- fill_value Methods ------- __call__ See Also -------- splrep, splev Spline interpolation/smoothing based on FITPACK. UnivariateSpline : An object-oriented wrapper of the FITPACK routines. interp2d : 2-D interpolation Examples -------- >>> import matplotlib.pyplot as plt >>> from scipy import interpolate >>> x = np.arange(0, 10) >>> y = np.exp(-x/3.0) >>> f = interpolate.interp1d(x, y) >>> xnew = np.arange(0, 9, 0.1) >>> ynew = f(xnew) # use interpolation function returned by `interp1d` >>> plt.plot(x, y, 'o', xnew, ynew, '-') >>> plt.show() """ def __init__(self, x, y, kind='linear', axis=-1, copy=True, bounds_error=None, fill_value=np.nan, assume_sorted=False): """ Initialize a 1D linear interpolation class.""" _Interpolator1D.__init__(self, x, y, axis=axis) self.bounds_error = bounds_error # used by fill_value setter self.copy = copy if kind in ['zero', 'slinear', 'quadratic', 'cubic']: order = {'zero': 0, 'slinear': 1, 'quadratic': 2, 'cubic': 3}[kind] kind = 'spline' elif isinstance(kind, int): order = kind kind = 'spline' elif kind not in ('linear', 'nearest', 'previous', 'next'): raise NotImplementedError("%s is unsupported: Use fitpack " "routines for other types." % kind) x = array(x, copy=self.copy) y = array(y, copy=self.copy) if not assume_sorted: ind = np.argsort(x) x = x[ind] y = np.take(y, ind, axis=axis) if x.ndim != 1: raise ValueError("the x array must have exactly one dimension.") if y.ndim == 0: raise ValueError("the y array must have at least one dimension.") # Force-cast y to a floating-point type, if it's not yet one if not issubclass(y.dtype.type, np.inexact): y = y.astype(np.float_) # Backward compatibility self.axis = axis % y.ndim # Interpolation goes internally along the first axis self.y = y self._y = self._reshape_yi(self.y) self.x = x del y, x # clean up namespace to prevent misuse; use attributes self._kind = kind self.fill_value = fill_value # calls the setter, can modify bounds_err # Adjust to interpolation kind; store reference to *unbound* # interpolation methods, in order to avoid circular references to self # stored in the bound instance methods, and therefore delayed garbage # collection. See: https://docs.python.org/reference/datamodel.html if kind in ('linear', 'nearest', 'previous', 'next'): # Make a "view" of the y array that is rotated to the interpolation # axis. minval = 2 if kind == 'nearest': # Do division before addition to prevent possible integer # overflow self.x_bds = self.x / 2.0 self.x_bds = self.x_bds[1:] + self.x_bds[:-1] self._call = self.__class__._call_nearest elif kind == 'previous': # Side for np.searchsorted and index for clipping self._side = 'left' self._ind = 0 # Move x by one floating point value to the left self._x_shift = np.nextafter(self.x, -np.inf) self._call = self.__class__._call_previousnext elif kind == 'next': self._side = 'right' self._ind = 1 # Move x by one floating point value to the right self._x_shift = np.nextafter(self.x, np.inf) self._call = self.__class__._call_previousnext else: # Check if we can delegate to numpy.interp (2x-10x faster). cond = self.x.dtype == np.float_ and self.y.dtype == np.float_ cond = cond and self.y.ndim == 1 cond = cond and not _do_extrapolate(fill_value) if cond: self._call = self.__class__._call_linear_np else: self._call = self.__class__._call_linear else: minval = order + 1 rewrite_nan = False xx, yy = self.x, self._y if order > 1: # Quadratic or cubic spline. If input contains even a single # nan, then the output is all nans. We cannot just feed data # with nans to make_interp_spline because it calls LAPACK. # So, we make up a bogus x and y with no nans and use it # to get the correct shape of the output, which we then fill # with nans. # For slinear or zero order spline, we just pass nans through. if np.isnan(self.x).any(): xx = np.linspace(min(self.x), max(self.x), len(self.x)) rewrite_nan = True if np.isnan(self._y).any(): yy = np.ones_like(self._y) rewrite_nan = True self._spline = make_interp_spline(xx, yy, k=order, check_finite=False) if rewrite_nan: self._call = self.__class__._call_nan_spline else: self._call = self.__class__._call_spline if len(self.x) < minval: raise ValueError("x and y arrays must have at " "least %d entries" % minval) @property def fill_value(self): """The fill value.""" # backwards compat: mimic a public attribute return self._fill_value_orig @fill_value.setter def fill_value(self, fill_value): # extrapolation only works for nearest neighbor and linear methods if _do_extrapolate(fill_value): if self.bounds_error: raise ValueError("Cannot extrapolate and raise " "at the same time.") self.bounds_error = False self._extrapolate = True else: broadcast_shape = (self.y.shape[:self.axis] + self.y.shape[self.axis + 1:]) if len(broadcast_shape) == 0: broadcast_shape = (1,) # it's either a pair (_below_range, _above_range) or a single value # for both above and below range if isinstance(fill_value, tuple) and len(fill_value) == 2: below_above = [np.asarray(fill_value[0]), np.asarray(fill_value[1])] names = ('fill_value (below)', 'fill_value (above)') for ii in range(2): below_above[ii] = _check_broadcast_up_to( below_above[ii], broadcast_shape, names[ii]) else: fill_value = np.asarray(fill_value) below_above = [_check_broadcast_up_to( fill_value, broadcast_shape, 'fill_value')] * 2 self._fill_value_below, self._fill_value_above = below_above self._extrapolate = False if self.bounds_error is None: self.bounds_error = True # backwards compat: fill_value was a public attr; make it writeable self._fill_value_orig = fill_value def _call_linear_np(self, x_new): # Note that out-of-bounds values are taken care of in self._evaluate return np.interp(x_new, self.x, self.y) def _call_linear(self, x_new): # 2. Find where in the original data, the values to interpolate # would be inserted. # Note: If x_new[n] == x[m], then m is returned by searchsorted. x_new_indices = searchsorted(self.x, x_new) # 3. Clip x_new_indices so that they are within the range of # self.x indices and at least 1. Removes mis-interpolation # of x_new[n] = x[0] x_new_indices = x_new_indices.clip(1, len(self.x)-1).astype(int) # 4. Calculate the slope of regions that each x_new value falls in. lo = x_new_indices - 1 hi = x_new_indices x_lo = self.x[lo] x_hi = self.x[hi] y_lo = self._y[lo] y_hi = self._y[hi] # Note that the following two expressions rely on the specifics of the # broadcasting semantics. slope = (y_hi - y_lo) / (x_hi - x_lo)[:, None] # 5. Calculate the actual value for each entry in x_new. y_new = slope*(x_new - x_lo)[:, None] + y_lo return y_new def _call_nearest(self, x_new): """ Find nearest neighbour interpolated y_new = f(x_new).""" # 2. Find where in the averaged data the values to interpolate # would be inserted. # Note: use side='left' (right) to searchsorted() to define the # halfway point to be nearest to the left (right) neighbour x_new_indices = searchsorted(self.x_bds, x_new, side='left') # 3. Clip x_new_indices so that they are within the range of x indices. x_new_indices = x_new_indices.clip(0, len(self.x)-1).astype(intp) # 4. Calculate the actual value for each entry in x_new. y_new = self._y[x_new_indices] return y_new def _call_previousnext(self, x_new): """Use previous/next neighbour of x_new, y_new = f(x_new).""" # 1. Get index of left/right value x_new_indices = searchsorted(self._x_shift, x_new, side=self._side) # 2. Clip x_new_indices so that they are within the range of x indices. x_new_indices = x_new_indices.clip(1-self._ind, len(self.x)-self._ind).astype(intp) # 3. Calculate the actual value for each entry in x_new. y_new = self._y[x_new_indices+self._ind-1] return y_new def _call_spline(self, x_new): return self._spline(x_new) def _call_nan_spline(self, x_new): out = self._spline(x_new) out[...] = np.nan return out def _evaluate(self, x_new): # 1. Handle values in x_new that are outside of x. Throw error, # or return a list of mask array indicating the outofbounds values. # The behavior is set by the bounds_error variable. x_new = asarray(x_new) y_new = self._call(self, x_new) if not self._extrapolate: below_bounds, above_bounds = self._check_bounds(x_new) if len(y_new) > 0: # Note fill_value must be broadcast up to the proper size # and flattened to work here y_new[below_bounds] = self._fill_value_below y_new[above_bounds] = self._fill_value_above return y_new def _check_bounds(self, x_new): """Check the inputs for being in the bounds of the interpolated data. Parameters ---------- x_new : array Returns ------- out_of_bounds : bool array The mask on x_new of values that are out of the bounds. """ # If self.bounds_error is True, we raise an error if any x_new values # fall outside the range of x. Otherwise, we return an array indicating # which values are outside the boundary region. below_bounds = x_new < self.x[0] above_bounds = x_new > self.x[-1] # !! Could provide more information about which values are out of bounds if self.bounds_error and below_bounds.any(): raise ValueError("A value in x_new is below the interpolation " "range.") if self.bounds_error and above_bounds.any(): raise ValueError("A value in x_new is above the interpolation " "range.") # !! Should we emit a warning if some values are out of bounds? # !! matlab does not. return below_bounds, above_bounds class _PPolyBase(object): """Base class for piecewise polynomials.""" __slots__ = ('c', 'x', 'extrapolate', 'axis') def __init__(self, c, x, extrapolate=None, axis=0): self.c = np.asarray(c) self.x = np.ascontiguousarray(x, dtype=np.float64) if extrapolate is None: extrapolate = True elif extrapolate != 'periodic': extrapolate = bool(extrapolate) self.extrapolate = extrapolate if self.c.ndim < 2: raise ValueError("Coefficients array must be at least " "2-dimensional.") if not (0 <= axis < self.c.ndim - 1): raise ValueError("axis=%s must be between 0 and %s" % (axis, self.c.ndim-1)) self.axis = axis if axis != 0: # roll the interpolation axis to be the first one in self.c # More specifically, the target shape for self.c is (k, m, ...), # and axis !=0 means that we have c.shape (..., k, m, ...) # ^ # axis # So we roll two of them. self.c = np.rollaxis(self.c, axis+1) self.c = np.rollaxis(self.c, axis+1) if self.x.ndim != 1: raise ValueError("x must be 1-dimensional") if self.x.size < 2: raise ValueError("at least 2 breakpoints are needed") if self.c.ndim < 2: raise ValueError("c must have at least 2 dimensions") if self.c.shape[0] == 0: raise ValueError("polynomial must be at least of order 0") if self.c.shape[1] != self.x.size-1: raise ValueError("number of coefficients != len(x)-1") dx = np.diff(self.x) if not (np.all(dx >= 0) or np.all(dx <= 0)): raise ValueError("`x` must be strictly increasing or decreasing.") dtype = self._get_dtype(self.c.dtype) self.c = np.ascontiguousarray(self.c, dtype=dtype) def _get_dtype(self, dtype): if np.issubdtype(dtype, np.complexfloating) \ or np.issubdtype(self.c.dtype, np.complexfloating): return np.complex_ else: return np.float_ @classmethod def construct_fast(cls, c, x, extrapolate=None, axis=0): """ Construct the piecewise polynomial without making checks. Takes the same parameters as the constructor. Input arguments ``c`` and ``x`` must be arrays of the correct shape and type. The ``c`` array can only be of dtypes float and complex, and ``x`` array must have dtype float. """ self = object.__new__(cls) self.c = c self.x = x self.axis = axis if extrapolate is None: extrapolate = True self.extrapolate = extrapolate return self def _ensure_c_contiguous(self): """ c and x may be modified by the user. The Cython code expects that they are C contiguous. """ if not self.x.flags.c_contiguous: self.x = self.x.copy() if not self.c.flags.c_contiguous: self.c = self.c.copy() def extend(self, c, x, right=None): """ Add additional breakpoints and coefficients to the polynomial. Parameters ---------- c : ndarray, size (k, m, ...) Additional coefficients for polynomials in intervals. Note that the first additional interval will be formed using one of the ``self.x`` end points. x : ndarray, size (m,) Additional breakpoints. Must be sorted in the same order as ``self.x`` and either to the right or to the left of the current breakpoints. right Deprecated argument. Has no effect. .. deprecated:: 0.19 """ if right is not None: warnings.warn("`right` is deprecated and will be removed.") c = np.asarray(c) x = np.asarray(x) if c.ndim < 2: raise ValueError("invalid dimensions for c") if x.ndim != 1: raise ValueError("invalid dimensions for x") if x.shape[0] != c.shape[1]: raise ValueError("x and c have incompatible sizes") if c.shape[2:] != self.c.shape[2:] or c.ndim != self.c.ndim: raise ValueError("c and self.c have incompatible shapes") if c.size == 0: return dx = np.diff(x) if not (np.all(dx >= 0) or np.all(dx <= 0)): raise ValueError("`x` is not sorted.") if self.x[-1] >= self.x[0]: if not x[-1] >= x[0]: raise ValueError("`x` is in the different order " "than `self.x`.") if x[0] >= self.x[-1]: action = 'append' elif x[-1] <= self.x[0]: action = 'prepend' else: raise ValueError("`x` is neither on the left or on the right " "from `self.x`.") else: if not x[-1] <= x[0]: raise ValueError("`x` is in the different order " "than `self.x`.") if x[0] <= self.x[-1]: action = 'append' elif x[-1] >= self.x[0]: action = 'prepend' else: raise ValueError("`x` is neither on the left or on the right " "from `self.x`.") dtype = self._get_dtype(c.dtype) k2 = max(c.shape[0], self.c.shape[0]) c2 = np.zeros((k2, self.c.shape[1] + c.shape[1]) + self.c.shape[2:], dtype=dtype) if action == 'append': c2[k2-self.c.shape[0]:, :self.c.shape[1]] = self.c c2[k2-c.shape[0]:, self.c.shape[1]:] = c self.x = np.r_[self.x, x] elif action == 'prepend': c2[k2-self.c.shape[0]:, :c.shape[1]] = c c2[k2-c.shape[0]:, c.shape[1]:] = self.c self.x = np.r_[x, self.x] self.c = c2 def __call__(self, x, nu=0, extrapolate=None): """ Evaluate the piecewise polynomial or its derivative. Parameters ---------- x : array_like Points to evaluate the interpolant at. nu : int, optional Order of derivative to evaluate. Must be non-negative. extrapolate : {bool, 'periodic', None}, optional If bool, determines whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. If 'periodic', periodic extrapolation is used. If None (default), use `self.extrapolate`. Returns ------- y : array_like Interpolated values. Shape is determined by replacing the interpolation axis in the original array with the shape of x. Notes ----- Derivatives are evaluated piecewise for each polynomial segment, even if the polynomial is not differentiable at the breakpoints. The polynomial intervals are considered half-open, ``[a, b)``, except for the last interval which is closed ``[a, b]``. """ if extrapolate is None: extrapolate = self.extrapolate x = np.asarray(x) x_shape, x_ndim = x.shape, x.ndim x = np.ascontiguousarray(x.ravel(), dtype=np.float_) # With periodic extrapolation we map x to the segment # [self.x[0], self.x[-1]]. if extrapolate == 'periodic': x = self.x[0] + (x - self.x[0]) % (self.x[-1] - self.x[0]) extrapolate = False out = np.empty((len(x), prod(self.c.shape[2:])), dtype=self.c.dtype) self._ensure_c_contiguous() self._evaluate(x, nu, extrapolate, out) out = out.reshape(x_shape + self.c.shape[2:]) if self.axis != 0: # transpose to move the calculated values to the interpolation axis l = list(range(out.ndim)) l = l[x_ndim:x_ndim+self.axis] + l[:x_ndim] + l[x_ndim+self.axis:] out = out.transpose(l) return out class PPoly(_PPolyBase): """ Piecewise polynomial in terms of coefficients and breakpoints The polynomial between ``x[i]`` and ``x[i + 1]`` is written in the local power basis:: S = sum(c[m, i] * (xp - x[i])**(k-m) for m in range(k+1)) where ``k`` is the degree of the polynomial. Parameters ---------- c : ndarray, shape (k, m, ...) Polynomial coefficients, order `k` and `m` intervals x : ndarray, shape (m+1,) Polynomial breakpoints. Must be sorted in either increasing or decreasing order. extrapolate : bool or 'periodic', optional If bool, determines whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. If 'periodic', periodic extrapolation is used. Default is True. axis : int, optional Interpolation axis. Default is zero. Attributes ---------- x : ndarray Breakpoints. c : ndarray Coefficients of the polynomials. They are reshaped to a 3-dimensional array with the last dimension representing the trailing dimensions of the original coefficient array. axis : int Interpolation axis. Methods ------- __call__ derivative antiderivative integrate solve roots extend from_spline from_bernstein_basis construct_fast See also -------- BPoly : piecewise polynomials in the Bernstein basis Notes ----- High-order polynomials in the power basis can be numerically unstable. Precision problems can start to appear for orders larger than 20-30. """ def _evaluate(self, x, nu, extrapolate, out): _ppoly.evaluate(self.c.reshape(self.c.shape[0], self.c.shape[1], -1), self.x, x, nu, bool(extrapolate), out) def derivative(self, nu=1): """ Construct a new piecewise polynomial representing the derivative. Parameters ---------- nu : int, optional Order of derivative to evaluate. Default is 1, i.e. compute the first derivative. If negative, the antiderivative is returned. Returns ------- pp : PPoly Piecewise polynomial of order k2 = k - n representing the derivative of this polynomial. Notes ----- Derivatives are evaluated piecewise for each polynomial segment, even if the polynomial is not differentiable at the breakpoints. The polynomial intervals are considered half-open, ``[a, b)``, except for the last interval which is closed ``[a, b]``. """ if nu < 0: return self.antiderivative(-nu) # reduce order if nu == 0: c2 = self.c.copy() else: c2 = self.c[:-nu, :].copy() if c2.shape[0] == 0: # derivative of order 0 is zero c2 = np.zeros((1,) + c2.shape[1:], dtype=c2.dtype) # multiply by the correct rising factorials factor = spec.poch(np.arange(c2.shape[0], 0, -1), nu) c2 *= factor[(slice(None),) + (None,)*(c2.ndim-1)] # construct a compatible polynomial return self.construct_fast(c2, self.x, self.extrapolate, self.axis) def antiderivative(self, nu=1): """ Construct a new piecewise polynomial representing the antiderivative. Antiderivative is also the indefinite integral of the function, and derivative is its inverse operation. Parameters ---------- nu : int, optional Order of antiderivative to evaluate. Default is 1, i.e. compute the first integral. If negative, the derivative is returned. Returns ------- pp : PPoly Piecewise polynomial of order k2 = k + n representing the antiderivative of this polynomial. Notes ----- The antiderivative returned by this function is continuous and continuously differentiable to order n-1, up to floating point rounding error. If antiderivative is computed and ``self.extrapolate='periodic'``, it will be set to False for the returned instance. This is done because the antiderivative is no longer periodic and its correct evaluation outside of the initially given x interval is difficult. """ if nu <= 0: return self.derivative(-nu) c = np.zeros((self.c.shape[0] + nu, self.c.shape[1]) + self.c.shape[2:], dtype=self.c.dtype) c[:-nu] = self.c # divide by the correct rising factorials factor = spec.poch(np.arange(self.c.shape[0], 0, -1), nu) c[:-nu] /= factor[(slice(None),) + (None,)*(c.ndim-1)] # fix continuity of added degrees of freedom self._ensure_c_contiguous() _ppoly.fix_continuity(c.reshape(c.shape[0], c.shape[1], -1), self.x, nu - 1) if self.extrapolate == 'periodic': extrapolate = False else: extrapolate = self.extrapolate # construct a compatible polynomial return self.construct_fast(c, self.x, extrapolate, self.axis) def integrate(self, a, b, extrapolate=None): """ Compute a definite integral over a piecewise polynomial. Parameters ---------- a : float Lower integration bound b : float Upper integration bound extrapolate : {bool, 'periodic', None}, optional If bool, determines whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. If 'periodic', periodic extrapolation is used. If None (default), use `self.extrapolate`. Returns ------- ig : array_like Definite integral of the piecewise polynomial over [a, b] """ if extrapolate is None: extrapolate = self.extrapolate # Swap integration bounds if needed sign = 1 if b < a: a, b = b, a sign = -1 range_int = np.empty((prod(self.c.shape[2:]),), dtype=self.c.dtype) self._ensure_c_contiguous() # Compute the integral. if extrapolate == 'periodic': # Split the integral into the part over period (can be several # of them) and the remaining part. xs, xe = self.x[0], self.x[-1] period = xe - xs interval = b - a n_periods, left = divmod(interval, period) if n_periods > 0: _ppoly.integrate( self.c.reshape(self.c.shape[0], self.c.shape[1], -1), self.x, xs, xe, False, out=range_int) range_int *= n_periods else: range_int.fill(0) # Map a to [xs, xe], b is always a + left. a = xs + (a - xs) % period b = a + left # If b <= xe then we need to integrate over [a, b], otherwise # over [a, xe] and from xs to what is remained. remainder_int = np.empty_like(range_int) if b <= xe: _ppoly.integrate( self.c.reshape(self.c.shape[0], self.c.shape[1], -1), self.x, a, b, False, out=remainder_int) range_int += remainder_int else: _ppoly.integrate( self.c.reshape(self.c.shape[0], self.c.shape[1], -1), self.x, a, xe, False, out=remainder_int) range_int += remainder_int _ppoly.integrate( self.c.reshape(self.c.shape[0], self.c.shape[1], -1), self.x, xs, xs + left + a - xe, False, out=remainder_int) range_int += remainder_int else: _ppoly.integrate( self.c.reshape(self.c.shape[0], self.c.shape[1], -1), self.x, a, b, bool(extrapolate), out=range_int) # Return range_int *= sign return range_int.reshape(self.c.shape[2:]) def solve(self, y=0., discontinuity=True, extrapolate=None): """ Find real solutions of the the equation ``pp(x) == y``. Parameters ---------- y : float, optional Right-hand side. Default is zero. discontinuity : bool, optional Whether to report sign changes across discontinuities at breakpoints as roots. extrapolate : {bool, 'periodic', None}, optional If bool, determines whether to return roots from the polynomial extrapolated based on first and last intervals, 'periodic' works the same as False. If None (default), use `self.extrapolate`. Returns ------- roots : ndarray Roots of the polynomial(s). If the PPoly object describes multiple polynomials, the return value is an object array whose each element is an ndarray containing the roots. Notes ----- This routine works only on real-valued polynomials. If the piecewise polynomial contains sections that are identically zero, the root list will contain the start point of the corresponding interval, followed by a ``nan`` value. If the polynomial is discontinuous across a breakpoint, and there is a sign change across the breakpoint, this is reported if the `discont` parameter is True. Examples -------- Finding roots of ``[x**2 - 1, (x - 1)**2]`` defined on intervals ``[-2, 1], [1, 2]``: >>> from scipy.interpolate import PPoly >>> pp = PPoly(np.array([[1, -4, 3], [1, 0, 0]]).T, [-2, 1, 2]) >>> pp.solve() array([-1., 1.]) """ if extrapolate is None: extrapolate = self.extrapolate self._ensure_c_contiguous() if np.issubdtype(self.c.dtype, np.complexfloating): raise ValueError("Root finding is only for " "real-valued polynomials") y = float(y) r = _ppoly.real_roots(self.c.reshape(self.c.shape[0], self.c.shape[1], -1), self.x, y, bool(discontinuity), bool(extrapolate)) if self.c.ndim == 2: return r[0] else: r2 = np.empty(prod(self.c.shape[2:]), dtype=object) # this for-loop is equivalent to ``r2[...] = r``, but that's broken # in numpy 1.6.0 for ii, root in enumerate(r): r2[ii] = root return r2.reshape(self.c.shape[2:]) def roots(self, discontinuity=True, extrapolate=None): """ Find real roots of the the piecewise polynomial. Parameters ---------- discontinuity : bool, optional Whether to report sign changes across discontinuities at breakpoints as roots. extrapolate : {bool, 'periodic', None}, optional If bool, determines whether to return roots from the polynomial extrapolated based on first and last intervals, 'periodic' works the same as False. If None (default), use `self.extrapolate`. Returns ------- roots : ndarray Roots of the polynomial(s). If the PPoly object describes multiple polynomials, the return value is an object array whose each element is an ndarray containing the roots. See Also -------- PPoly.solve """ return self.solve(0, discontinuity, extrapolate) @classmethod def from_spline(cls, tck, extrapolate=None): """ Construct a piecewise polynomial from a spline Parameters ---------- tck A spline, as returned by `splrep` or a BSpline object. extrapolate : bool or 'periodic', optional If bool, determines whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. If 'periodic', periodic extrapolation is used. Default is True. """ if isinstance(tck, BSpline): t, c, k = tck.tck if extrapolate is None: extrapolate = tck.extrapolate else: t, c, k = tck cvals = np.empty((k + 1, len(t)-1), dtype=c.dtype) for m in xrange(k, -1, -1): y = fitpack.splev(t[:-1], tck, der=m) cvals[k - m, :] = y/spec.gamma(m+1) return cls.construct_fast(cvals, t, extrapolate) @classmethod def from_bernstein_basis(cls, bp, extrapolate=None): """ Construct a piecewise polynomial in the power basis from a polynomial in Bernstein basis. Parameters ---------- bp : BPoly A Bernstein basis polynomial, as created by BPoly extrapolate : bool or 'periodic', optional If bool, determines whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. If 'periodic', periodic extrapolation is used. Default is True. """ if not isinstance(bp, BPoly): raise TypeError(".from_bernstein_basis only accepts BPoly instances. " "Got %s instead." % type(bp)) dx = np.diff(bp.x) k = bp.c.shape[0] - 1 # polynomial order rest = (None,)*(bp.c.ndim-2) c = np.zeros_like(bp.c) for a in range(k+1): factor = (-1)**a * comb(k, a) * bp.c[a] for s in range(a, k+1): val = comb(k-a, s-a) * (-1)**s c[k-s] += factor * val / dx[(slice(None),)+rest]**s if extrapolate is None: extrapolate = bp.extrapolate return cls.construct_fast(c, bp.x, extrapolate, bp.axis) class BPoly(_PPolyBase): """Piecewise polynomial in terms of coefficients and breakpoints. The polynomial between ``x[i]`` and ``x[i + 1]`` is written in the Bernstein polynomial basis:: S = sum(c[a, i] * b(a, k; x) for a in range(k+1)), where ``k`` is the degree of the polynomial, and:: b(a, k; x) = binom(k, a) * t**a * (1 - t)**(k - a), with ``t = (x - x[i]) / (x[i+1] - x[i])`` and ``binom`` is the binomial coefficient. Parameters ---------- c : ndarray, shape (k, m, ...) Polynomial coefficients, order `k` and `m` intervals x : ndarray, shape (m+1,) Polynomial breakpoints. Must be sorted in either increasing or decreasing order. extrapolate : bool, optional If bool, determines whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. If 'periodic', periodic extrapolation is used. Default is True. axis : int, optional Interpolation axis. Default is zero. Attributes ---------- x : ndarray Breakpoints. c : ndarray Coefficients of the polynomials. They are reshaped to a 3-dimensional array with the last dimension representing the trailing dimensions of the original coefficient array. axis : int Interpolation axis. Methods ------- __call__ extend derivative antiderivative integrate construct_fast from_power_basis from_derivatives See also -------- PPoly : piecewise polynomials in the power basis Notes ----- Properties of Bernstein polynomials are well documented in the literature, see for example [1]_ [2]_ [3]_. References ---------- .. [1] https://en.wikipedia.org/wiki/Bernstein_polynomial .. [2] Kenneth I. Joy, Bernstein polynomials, http://www.idav.ucdavis.edu/education/CAGDNotes/Bernstein-Polynomials.pdf .. [3] E. H. Doha, A. H. Bhrawy, and M. A. Saker, Boundary Value Problems, vol 2011, article ID 829546, :doi:`10.1155/2011/829543`. Examples -------- >>> from scipy.interpolate import BPoly >>> x = [0, 1] >>> c = [[1], [2], [3]] >>> bp = BPoly(c, x) This creates a 2nd order polynomial .. math:: B(x) = 1 \\times b_{0, 2}(x) + 2 \\times b_{1, 2}(x) + 3 \\times b_{2, 2}(x) \\\\ = 1 \\times (1-x)^2 + 2 \\times 2 x (1 - x) + 3 \\times x^2 """ def _evaluate(self, x, nu, extrapolate, out): _ppoly.evaluate_bernstein( self.c.reshape(self.c.shape[0], self.c.shape[1], -1), self.x, x, nu, bool(extrapolate), out) def derivative(self, nu=1): """ Construct a new piecewise polynomial representing the derivative. Parameters ---------- nu : int, optional Order of derivative to evaluate. Default is 1, i.e. compute the first derivative. If negative, the antiderivative is returned. Returns ------- bp : BPoly Piecewise polynomial of order k - nu representing the derivative of this polynomial. """ if nu < 0: return self.antiderivative(-nu) if nu > 1: bp = self for k in range(nu): bp = bp.derivative() return bp # reduce order if nu == 0: c2 = self.c.copy() else: # For a polynomial # B(x) = \sum_{a=0}^{k} c_a b_{a, k}(x), # we use the fact that # b'_{a, k} = k ( b_{a-1, k-1} - b_{a, k-1} ), # which leads to # B'(x) = \sum_{a=0}^{k-1} (c_{a+1} - c_a) b_{a, k-1} # # finally, for an interval [y, y + dy] with dy != 1, # we need to correct for an extra power of dy rest = (None,)*(self.c.ndim-2) k = self.c.shape[0] - 1 dx = np.diff(self.x)[(None, slice(None))+rest] c2 = k * np.diff(self.c, axis=0) / dx if c2.shape[0] == 0: # derivative of order 0 is zero c2 = np.zeros((1,) + c2.shape[1:], dtype=c2.dtype) # construct a compatible polynomial return self.construct_fast(c2, self.x, self.extrapolate, self.axis) def antiderivative(self, nu=1): """ Construct a new piecewise polynomial representing the antiderivative. Parameters ---------- nu : int, optional Order of antiderivative to evaluate. Default is 1, i.e. compute the first integral. If negative, the derivative is returned. Returns ------- bp : BPoly Piecewise polynomial of order k + nu representing the antiderivative of this polynomial. Notes ----- If antiderivative is computed and ``self.extrapolate='periodic'``, it will be set to False for the returned instance. This is done because the antiderivative is no longer periodic and its correct evaluation outside of the initially given x interval is difficult. """ if nu <= 0: return self.derivative(-nu) if nu > 1: bp = self for k in range(nu): bp = bp.antiderivative() return bp # Construct the indefinite integrals on individual intervals c, x = self.c, self.x k = c.shape[0] c2 = np.zeros((k+1,) + c.shape[1:], dtype=c.dtype) c2[1:, ...] = np.cumsum(c, axis=0) / k delta = x[1:] - x[:-1] c2 *= delta[(None, slice(None)) + (None,)*(c.ndim-2)] # Now fix continuity: on the very first interval, take the integration # constant to be zero; on an interval [x_j, x_{j+1}) with j>0, # the integration constant is then equal to the jump of the `bp` at x_j. # The latter is given by the coefficient of B_{n+1, n+1} # *on the previous interval* (other B. polynomials are zero at the # breakpoint). Finally, use the fact that BPs form a partition of unity. c2[:,1:] += np.cumsum(c2[k, :], axis=0)[:-1] if self.extrapolate == 'periodic': extrapolate = False else: extrapolate = self.extrapolate return self.construct_fast(c2, x, extrapolate, axis=self.axis) def integrate(self, a, b, extrapolate=None): """ Compute a definite integral over a piecewise polynomial. Parameters ---------- a : float Lower integration bound b : float Upper integration bound extrapolate : {bool, 'periodic', None}, optional Whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. If 'periodic', periodic extrapolation is used. If None (default), use `self.extrapolate`. Returns ------- array_like Definite integral of the piecewise polynomial over [a, b] """ # XXX: can probably use instead the fact that # \int_0^{1} B_{j, n}(x) \dx = 1/(n+1) ib = self.antiderivative() if extrapolate is None: extrapolate = self.extrapolate # ib.extrapolate shouldn't be 'periodic', it is converted to # False for 'periodic. in antiderivative() call. if extrapolate != 'periodic': ib.extrapolate = extrapolate if extrapolate == 'periodic': # Split the integral into the part over period (can be several # of them) and the remaining part. # For simplicity and clarity convert to a <= b case. if a <= b: sign = 1 else: a, b = b, a sign = -1 xs, xe = self.x[0], self.x[-1] period = xe - xs interval = b - a n_periods, left = divmod(interval, period) res = n_periods * (ib(xe) - ib(xs)) # Map a and b to [xs, xe]. a = xs + (a - xs) % period b = a + left # If b <= xe then we need to integrate over [a, b], otherwise # over [a, xe] and from xs to what is remained. if b <= xe: res += ib(b) - ib(a) else: res += ib(xe) - ib(a) + ib(xs + left + a - xe) - ib(xs) return sign * res else: return ib(b) - ib(a) def extend(self, c, x, right=None): k = max(self.c.shape[0], c.shape[0]) self.c = self._raise_degree(self.c, k - self.c.shape[0]) c = self._raise_degree(c, k - c.shape[0]) return _PPolyBase.extend(self, c, x, right) extend.__doc__ = _PPolyBase.extend.__doc__ @classmethod def from_power_basis(cls, pp, extrapolate=None): """ Construct a piecewise polynomial in Bernstein basis from a power basis polynomial. Parameters ---------- pp : PPoly A piecewise polynomial in the power basis extrapolate : bool or 'periodic', optional If bool, determines whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. If 'periodic', periodic extrapolation is used. Default is True. """ if not isinstance(pp, PPoly): raise TypeError(".from_power_basis only accepts PPoly instances. " "Got %s instead." % type(pp)) dx = np.diff(pp.x) k = pp.c.shape[0] - 1 # polynomial order rest = (None,)*(pp.c.ndim-2) c = np.zeros_like(pp.c) for a in range(k+1): factor = pp.c[a] / comb(k, k-a) * dx[(slice(None),)+rest]**(k-a) for j in range(k-a, k+1): c[j] += factor * comb(j, k-a) if extrapolate is None: extrapolate = pp.extrapolate return cls.construct_fast(c, pp.x, extrapolate, pp.axis) @classmethod def from_derivatives(cls, xi, yi, orders=None, extrapolate=None): """Construct a piecewise polynomial in the Bernstein basis, compatible with the specified values and derivatives at breakpoints. Parameters ---------- xi : array_like sorted 1D array of x-coordinates yi : array_like or list of array_likes ``yi[i][j]`` is the ``j``-th derivative known at ``xi[i]`` orders : None or int or array_like of ints. Default: None. Specifies the degree of local polynomials. If not None, some derivatives are ignored. extrapolate : bool or 'periodic', optional If bool, determines whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. If 'periodic', periodic extrapolation is used. Default is True. Notes ----- If ``k`` derivatives are specified at a breakpoint ``x``, the constructed polynomial is exactly ``k`` times continuously differentiable at ``x``, unless the ``order`` is provided explicitly. In the latter case, the smoothness of the polynomial at the breakpoint is controlled by the ``order``. Deduces the number of derivatives to match at each end from ``order`` and the number of derivatives available. If possible it uses the same number of derivatives from each end; if the number is odd it tries to take the extra one from y2. In any case if not enough derivatives are available at one end or another it draws enough to make up the total from the other end. If the order is too high and not enough derivatives are available, an exception is raised. Examples -------- >>> from scipy.interpolate import BPoly >>> BPoly.from_derivatives([0, 1], [[1, 2], [3, 4]]) Creates a polynomial `f(x)` of degree 3, defined on `[0, 1]` such that `f(0) = 1, df/dx(0) = 2, f(1) = 3, df/dx(1) = 4` >>> BPoly.from_derivatives([0, 1, 2], [[0, 1], [0], [2]]) Creates a piecewise polynomial `f(x)`, such that `f(0) = f(1) = 0`, `f(2) = 2`, and `df/dx(0) = 1`. Based on the number of derivatives provided, the order of the local polynomials is 2 on `[0, 1]` and 1 on `[1, 2]`. Notice that no restriction is imposed on the derivatives at ``x = 1`` and ``x = 2``. Indeed, the explicit form of the polynomial is:: f(x) = | x * (1 - x), 0 <= x < 1 | 2 * (x - 1), 1 <= x <= 2 So that f'(1-0) = -1 and f'(1+0) = 2 """ xi = np.asarray(xi) if len(xi) != len(yi): raise ValueError("xi and yi need to have the same length") if np.any(xi[1:] - xi[:1] <= 0): raise ValueError("x coordinates are not in increasing order") # number of intervals m = len(xi) - 1 # global poly order is k-1, local orders are <=k and can vary try: k = max(len(yi[i]) + len(yi[i+1]) for i in range(m)) except TypeError: raise ValueError("Using a 1D array for y? Please .reshape(-1, 1).") if orders is None: orders = [None] * m else: if isinstance(orders, (integer_types, np.integer)): orders = [orders] * m k = max(k, max(orders)) if any(o <= 0 for o in orders): raise ValueError("Orders must be positive.") c = [] for i in range(m): y1, y2 = yi[i], yi[i+1] if orders[i] is None: n1, n2 = len(y1), len(y2) else: n = orders[i]+1 n1 = min(n//2, len(y1)) n2 = min(n - n1, len(y2)) n1 = min(n - n2, len(y2)) if n1+n2 != n: mesg = ("Point %g has %d derivatives, point %g" " has %d derivatives, but order %d requested" % ( xi[i], len(y1), xi[i+1], len(y2), orders[i])) raise ValueError(mesg) if not (n1 <= len(y1) and n2 <= len(y2)): raise ValueError("`order` input incompatible with" " length y1 or y2.") b = BPoly._construct_from_derivatives(xi[i], xi[i+1], y1[:n1], y2[:n2]) if len(b) < k: b = BPoly._raise_degree(b, k - len(b)) c.append(b) c = np.asarray(c) return cls(c.swapaxes(0, 1), xi, extrapolate) @staticmethod def _construct_from_derivatives(xa, xb, ya, yb): r"""Compute the coefficients of a polynomial in the Bernstein basis given the values and derivatives at the edges. Return the coefficients of a polynomial in the Bernstein basis defined on ``[xa, xb]`` and having the values and derivatives at the endpoints `xa` and `xb` as specified by `ya`` and `yb`. The polynomial constructed is of the minimal possible degree, i.e., if the lengths of `ya` and `yb` are `na` and `nb`, the degree of the polynomial is ``na + nb - 1``. Parameters ---------- xa : float Left-hand end point of the interval xb : float Right-hand end point of the interval ya : array_like Derivatives at `xa`. `ya[0]` is the value of the function, and `ya[i]` for ``i > 0`` is the value of the ``i``-th derivative. yb : array_like Derivatives at `xb`. Returns ------- array coefficient array of a polynomial having specified derivatives Notes ----- This uses several facts from life of Bernstein basis functions. First of all, .. math:: b'_{a, n} = n (b_{a-1, n-1} - b_{a, n-1}) If B(x) is a linear combination of the form .. math:: B(x) = \sum_{a=0}^{n} c_a b_{a, n}, then :math: B'(x) = n \sum_{a=0}^{n-1} (c_{a+1} - c_{a}) b_{a, n-1}. Iterating the latter one, one finds for the q-th derivative .. math:: B^{q}(x) = n!/(n-q)! \sum_{a=0}^{n-q} Q_a b_{a, n-q}, with .. math:: Q_a = \sum_{j=0}^{q} (-)^{j+q} comb(q, j) c_{j+a} This way, only `a=0` contributes to :math: `B^{q}(x = xa)`, and `c_q` are found one by one by iterating `q = 0, ..., na`. At ``x = xb`` it's the same with ``a = n - q``. """ ya, yb = np.asarray(ya), np.asarray(yb) if ya.shape[1:] != yb.shape[1:]: raise ValueError('ya and yb have incompatible dimensions.') dta, dtb = ya.dtype, yb.dtype if (np.issubdtype(dta, np.complexfloating) or np.issubdtype(dtb, np.complexfloating)): dt = np.complex_ else: dt = np.float_ na, nb = len(ya), len(yb) n = na + nb c = np.empty((na+nb,) + ya.shape[1:], dtype=dt) # compute coefficients of a polynomial degree na+nb-1 # walk left-to-right for q in range(0, na): c[q] = ya[q] / spec.poch(n - q, q) * (xb - xa)**q for j in range(0, q): c[q] -= (-1)**(j+q) * comb(q, j) * c[j] # now walk right-to-left for q in range(0, nb): c[-q-1] = yb[q] / spec.poch(n - q, q) * (-1)**q * (xb - xa)**q for j in range(0, q): c[-q-1] -= (-1)**(j+1) * comb(q, j+1) * c[-q+j] return c @staticmethod def _raise_degree(c, d): r"""Raise a degree of a polynomial in the Bernstein basis. Given the coefficients of a polynomial degree `k`, return (the coefficients of) the equivalent polynomial of degree `k+d`. Parameters ---------- c : array_like coefficient array, 1D d : integer Returns ------- array coefficient array, 1D array of length `c.shape[0] + d` Notes ----- This uses the fact that a Bernstein polynomial `b_{a, k}` can be identically represented as a linear combination of polynomials of a higher degree `k+d`: .. math:: b_{a, k} = comb(k, a) \sum_{j=0}^{d} b_{a+j, k+d} \ comb(d, j) / comb(k+d, a+j) """ if d == 0: return c k = c.shape[0] - 1 out = np.zeros((c.shape[0] + d,) + c.shape[1:], dtype=c.dtype) for a in range(c.shape[0]): f = c[a] * comb(k, a) for j in range(d+1): out[a+j] += f * comb(d, j) / comb(k+d, a+j) return out class NdPPoly(object): """ Piecewise tensor product polynomial The value at point ``xp = (x', y', z', ...)`` is evaluated by first computing the interval indices `i` such that:: x[0][i[0]] <= x' < x[0][i[0]+1] x[1][i[1]] <= y' < x[1][i[1]+1] ... and then computing:: S = sum(c[k0-m0-1,...,kn-mn-1,i[0],...,i[n]] * (xp[0] - x[0][i[0]])**m0 * ... * (xp[n] - x[n][i[n]])**mn for m0 in range(k[0]+1) ... for mn in range(k[n]+1)) where ``k[j]`` is the degree of the polynomial in dimension j. This representation is the piecewise multivariate power basis. Parameters ---------- c : ndarray, shape (k0, ..., kn, m0, ..., mn, ...) Polynomial coefficients, with polynomial order `kj` and `mj+1` intervals for each dimension `j`. x : ndim-tuple of ndarrays, shapes (mj+1,) Polynomial breakpoints for each dimension. These must be sorted in increasing order. extrapolate : bool, optional Whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. Default: True. Attributes ---------- x : tuple of ndarrays Breakpoints. c : ndarray Coefficients of the polynomials. Methods ------- __call__ construct_fast See also -------- PPoly : piecewise polynomials in 1D Notes ----- High-order polynomials in the power basis can be numerically unstable. """ def __init__(self, c, x, extrapolate=None): self.x = tuple(np.ascontiguousarray(v, dtype=np.float64) for v in x) self.c = np.asarray(c) if extrapolate is None: extrapolate = True self.extrapolate = bool(extrapolate) ndim = len(self.x) if any(v.ndim != 1 for v in self.x): raise ValueError("x arrays must all be 1-dimensional") if any(v.size < 2 for v in self.x): raise ValueError("x arrays must all contain at least 2 points") if c.ndim < 2*ndim: raise ValueError("c must have at least 2*len(x) dimensions") if any(np.any(v[1:] - v[:-1] < 0) for v in self.x): raise ValueError("x-coordinates are not in increasing order") if any(a != b.size - 1 for a, b in zip(c.shape[ndim:2*ndim], self.x)): raise ValueError("x and c do not agree on the number of intervals") dtype = self._get_dtype(self.c.dtype) self.c = np.ascontiguousarray(self.c, dtype=dtype) @classmethod def construct_fast(cls, c, x, extrapolate=None): """ Construct the piecewise polynomial without making checks. Takes the same parameters as the constructor. Input arguments ``c`` and ``x`` must be arrays of the correct shape and type. The ``c`` array can only be of dtypes float and complex, and ``x`` array must have dtype float. """ self = object.__new__(cls) self.c = c self.x = x if extrapolate is None: extrapolate = True self.extrapolate = extrapolate return self def _get_dtype(self, dtype): if np.issubdtype(dtype, np.complexfloating) \ or np.issubdtype(self.c.dtype, np.complexfloating): return np.complex_ else: return np.float_ def _ensure_c_contiguous(self): if not self.c.flags.c_contiguous: self.c = self.c.copy() if not isinstance(self.x, tuple): self.x = tuple(self.x) def __call__(self, x, nu=None, extrapolate=None): """ Evaluate the piecewise polynomial or its derivative Parameters ---------- x : array-like Points to evaluate the interpolant at. nu : tuple, optional Orders of derivatives to evaluate. Each must be non-negative. extrapolate : bool, optional Whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. Returns ------- y : array-like Interpolated values. Shape is determined by replacing the interpolation axis in the original array with the shape of x. Notes ----- Derivatives are evaluated piecewise for each polynomial segment, even if the polynomial is not differentiable at the breakpoints. The polynomial intervals are considered half-open, ``[a, b)``, except for the last interval which is closed ``[a, b]``. """ if extrapolate is None: extrapolate = self.extrapolate else: extrapolate = bool(extrapolate) ndim = len(self.x) x = _ndim_coords_from_arrays(x) x_shape = x.shape x = np.ascontiguousarray(x.reshape(-1, x.shape[-1]), dtype=np.float_) if nu is None: nu = np.zeros((ndim,), dtype=np.intc) else: nu = np.asarray(nu, dtype=np.intc) if nu.ndim != 1 or nu.shape[0] != ndim: raise ValueError("invalid number of derivative orders nu") dim1 = prod(self.c.shape[:ndim]) dim2 = prod(self.c.shape[ndim:2*ndim]) dim3 = prod(self.c.shape[2*ndim:]) ks = np.array(self.c.shape[:ndim], dtype=np.intc) out = np.empty((x.shape[0], dim3), dtype=self.c.dtype) self._ensure_c_contiguous() _ppoly.evaluate_nd(self.c.reshape(dim1, dim2, dim3), self.x, ks, x, nu, bool(extrapolate), out) return out.reshape(x_shape[:-1] + self.c.shape[2*ndim:]) def _derivative_inplace(self, nu, axis): """ Compute 1D derivative along a selected dimension in-place May result to non-contiguous c array. """ if nu < 0: return self._antiderivative_inplace(-nu, axis) ndim = len(self.x) axis = axis % ndim # reduce order if nu == 0: # noop return else: sl = [slice(None)]*ndim sl[axis] = slice(None, -nu, None) c2 = self.c[tuple(sl)] if c2.shape[axis] == 0: # derivative of order 0 is zero shp = list(c2.shape) shp[axis] = 1 c2 = np.zeros(shp, dtype=c2.dtype) # multiply by the correct rising factorials factor = spec.poch(np.arange(c2.shape[axis], 0, -1), nu) sl = [None]*c2.ndim sl[axis] = slice(None) c2 *= factor[tuple(sl)] self.c = c2 def _antiderivative_inplace(self, nu, axis): """ Compute 1D antiderivative along a selected dimension May result to non-contiguous c array. """ if nu <= 0: return self._derivative_inplace(-nu, axis) ndim = len(self.x) axis = axis % ndim perm = list(range(ndim)) perm[0], perm[axis] = perm[axis], perm[0] perm = perm + list(range(ndim, self.c.ndim)) c = self.c.transpose(perm) c2 = np.zeros((c.shape[0] + nu,) + c.shape[1:], dtype=c.dtype) c2[:-nu] = c # divide by the correct rising factorials factor = spec.poch(np.arange(c.shape[0], 0, -1), nu) c2[:-nu] /= factor[(slice(None),) + (None,)*(c.ndim-1)] # fix continuity of added degrees of freedom perm2 = list(range(c2.ndim)) perm2[1], perm2[ndim+axis] = perm2[ndim+axis], perm2[1] c2 = c2.transpose(perm2) c2 = c2.copy() _ppoly.fix_continuity(c2.reshape(c2.shape[0], c2.shape[1], -1), self.x[axis], nu-1) c2 = c2.transpose(perm2) c2 = c2.transpose(perm) # Done self.c = c2 def derivative(self, nu): """ Construct a new piecewise polynomial representing the derivative. Parameters ---------- nu : ndim-tuple of int Order of derivatives to evaluate for each dimension. If negative, the antiderivative is returned. Returns ------- pp : NdPPoly Piecewise polynomial of orders (k[0] - nu[0], ..., k[n] - nu[n]) representing the derivative of this polynomial. Notes ----- Derivatives are evaluated piecewise for each polynomial segment, even if the polynomial is not differentiable at the breakpoints. The polynomial intervals in each dimension are considered half-open, ``[a, b)``, except for the last interval which is closed ``[a, b]``. """ p = self.construct_fast(self.c.copy(), self.x, self.extrapolate) for axis, n in enumerate(nu): p._derivative_inplace(n, axis) p._ensure_c_contiguous() return p def antiderivative(self, nu): """ Construct a new piecewise polynomial representing the antiderivative. Antiderivative is also the indefinite integral of the function, and derivative is its inverse operation. Parameters ---------- nu : ndim-tuple of int Order of derivatives to evaluate for each dimension. If negative, the derivative is returned. Returns ------- pp : PPoly Piecewise polynomial of order k2 = k + n representing the antiderivative of this polynomial. Notes ----- The antiderivative returned by this function is continuous and continuously differentiable to order n-1, up to floating point rounding error. """ p = self.construct_fast(self.c.copy(), self.x, self.extrapolate) for axis, n in enumerate(nu): p._antiderivative_inplace(n, axis) p._ensure_c_contiguous() return p def integrate_1d(self, a, b, axis, extrapolate=None): r""" Compute NdPPoly representation for one dimensional definite integral The result is a piecewise polynomial representing the integral: .. math:: p(y, z, ...) = \int_a^b dx\, p(x, y, z, ...) where the dimension integrated over is specified with the `axis` parameter. Parameters ---------- a, b : float Lower and upper bound for integration. axis : int Dimension over which to compute the 1D integrals extrapolate : bool, optional Whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. Returns ------- ig : NdPPoly or array-like Definite integral of the piecewise polynomial over [a, b]. If the polynomial was 1-dimensional, an array is returned, otherwise, an NdPPoly object. """ if extrapolate is None: extrapolate = self.extrapolate else: extrapolate = bool(extrapolate) ndim = len(self.x) axis = int(axis) % ndim # reuse 1D integration routines c = self.c swap = list(range(c.ndim)) swap.insert(0, swap[axis]) del swap[axis + 1] swap.insert(1, swap[ndim + axis]) del swap[ndim + axis + 1] c = c.transpose(swap) p = PPoly.construct_fast(c.reshape(c.shape[0], c.shape[1], -1), self.x[axis], extrapolate=extrapolate) out = p.integrate(a, b, extrapolate=extrapolate) # Construct result if ndim == 1: return out.reshape(c.shape[2:]) else: c = out.reshape(c.shape[2:]) x = self.x[:axis] + self.x[axis+1:] return self.construct_fast(c, x, extrapolate=extrapolate) def integrate(self, ranges, extrapolate=None): """ Compute a definite integral over a piecewise polynomial. Parameters ---------- ranges : ndim-tuple of 2-tuples float Sequence of lower and upper bounds for each dimension, ``[(a[0], b[0]), ..., (a[ndim-1], b[ndim-1])]`` extrapolate : bool, optional Whether to extrapolate to out-of-bounds points based on first and last intervals, or to return NaNs. Returns ------- ig : array_like Definite integral of the piecewise polynomial over [a[0], b[0]] x ... x [a[ndim-1], b[ndim-1]] """ ndim = len(self.x) if extrapolate is None: extrapolate = self.extrapolate else: extrapolate = bool(extrapolate) if not hasattr(ranges, '__len__') or len(ranges) != ndim: raise ValueError("Range not a sequence of correct length") self._ensure_c_contiguous() # Reuse 1D integration routine c = self.c for n, (a, b) in enumerate(ranges): swap = list(range(c.ndim)) swap.insert(1, swap[ndim - n]) del swap[ndim - n + 1] c = c.transpose(swap) p = PPoly.construct_fast(c, self.x[n], extrapolate=extrapolate) out = p.integrate(a, b, extrapolate=extrapolate) c = out.reshape(c.shape[2:]) return c class RegularGridInterpolator(object): """ Interpolation on a regular grid in arbitrary dimensions The data must be defined on a regular grid; the grid spacing however may be uneven. Linear and nearest-neighbour interpolation are supported. After setting up the interpolator object, the interpolation method (*linear* or *nearest*) may be chosen at each evaluation. Parameters ---------- points : tuple of ndarray of float, with shapes (m1, ), ..., (mn, ) The points defining the regular grid in n dimensions. values : array_like, shape (m1, ..., mn, ...) The data on the regular grid in n dimensions. method : str, optional The method of interpolation to perform. Supported are "linear" and "nearest". This parameter will become the default for the object's ``__call__`` method. Default is "linear". bounds_error : bool, optional If True, when interpolated values are requested outside of the domain of the input data, a ValueError is raised. If False, then `fill_value` is used. fill_value : number, optional If provided, the value to use for points outside of the interpolation domain. If None, values outside the domain are extrapolated. Methods ------- __call__ Notes ----- Contrary to LinearNDInterpolator and NearestNDInterpolator, this class avoids expensive triangulation of the input data by taking advantage of the regular grid structure. If any of `points` have a dimension of size 1, linear interpolation will return an array of `nan` values. Nearest-neighbor interpolation will work as usual in this case. .. versionadded:: 0.14 Examples -------- Evaluate a simple example function on the points of a 3D grid: >>> from scipy.interpolate import RegularGridInterpolator >>> def f(x, y, z): ... return 2 * x**3 + 3 * y**2 - z >>> x = np.linspace(1, 4, 11) >>> y = np.linspace(4, 7, 22) >>> z = np.linspace(7, 9, 33) >>> data = f(*np.meshgrid(x, y, z, indexing='ij', sparse=True)) ``data`` is now a 3D array with ``data[i,j,k] = f(x[i], y[j], z[k])``. Next, define an interpolating function from this data: >>> my_interpolating_function = RegularGridInterpolator((x, y, z), data) Evaluate the interpolating function at the two points ``(x,y,z) = (2.1, 6.2, 8.3)`` and ``(3.3, 5.2, 7.1)``: >>> pts = np.array([[2.1, 6.2, 8.3], [3.3, 5.2, 7.1]]) >>> my_interpolating_function(pts) array([ 125.80469388, 146.30069388]) which is indeed a close approximation to ``[f(2.1, 6.2, 8.3), f(3.3, 5.2, 7.1)]``. See also -------- NearestNDInterpolator : Nearest neighbour interpolation on unstructured data in N dimensions LinearNDInterpolator : Piecewise linear interpolant on unstructured data in N dimensions References ---------- .. [1] Python package *regulargrid* by Johannes Buchner, see https://pypi.python.org/pypi/regulargrid/ .. [2] Wikipedia, "Trilinear interpolation", https://en.wikipedia.org/wiki/Trilinear_interpolation .. [3] Weiser, Alan, and Sergio E. Zarantonello. "A note on piecewise linear and multilinear table interpolation in many dimensions." MATH. COMPUT. 50.181 (1988): 189-196. https://www.ams.org/journals/mcom/1988-50-181/S0025-5718-1988-0917826-0/S0025-5718-1988-0917826-0.pdf """ # this class is based on code originally programmed by Johannes Buchner, # see https://github.com/JohannesBuchner/regulargrid def __init__(self, points, values, method="linear", bounds_error=True, fill_value=np.nan): if method not in ["linear", "nearest"]: raise ValueError("Method '%s' is not defined" % method) self.method = method self.bounds_error = bounds_error if not hasattr(values, 'ndim'): # allow reasonable duck-typed values values = np.asarray(values) if len(points) > values.ndim: raise ValueError("There are %d point arrays, but values has %d " "dimensions" % (len(points), values.ndim)) if hasattr(values, 'dtype') and hasattr(values, 'astype'): if not np.issubdtype(values.dtype, np.inexact): values = values.astype(float) self.fill_value = fill_value if fill_value is not None: fill_value_dtype = np.asarray(fill_value).dtype if (hasattr(values, 'dtype') and not np.can_cast(fill_value_dtype, values.dtype, casting='same_kind')): raise ValueError("fill_value must be either 'None' or " "of a type compatible with values") for i, p in enumerate(points): if not np.all(np.diff(p) > 0.): raise ValueError("The points in dimension %d must be strictly " "ascending" % i) if not np.asarray(p).ndim == 1: raise ValueError("The points in dimension %d must be " "1-dimensional" % i) if not values.shape[i] == len(p): raise ValueError("There are %d points and %d values in " "dimension %d" % (len(p), values.shape[i], i)) self.grid = tuple([np.asarray(p) for p in points]) self.values = values def __call__(self, xi, method=None): """ Interpolation at coordinates Parameters ---------- xi : ndarray of shape (..., ndim) The coordinates to sample the gridded data at method : str The method of interpolation to perform. Supported are "linear" and "nearest". """ method = self.method if method is None else method if method not in ["linear", "nearest"]: raise ValueError("Method '%s' is not defined" % method) ndim = len(self.grid) xi = _ndim_coords_from_arrays(xi, ndim=ndim) if xi.shape[-1] != len(self.grid): raise ValueError("The requested sample points xi have dimension " "%d, but this RegularGridInterpolator has " "dimension %d" % (xi.shape[1], ndim)) xi_shape = xi.shape xi = xi.reshape(-1, xi_shape[-1]) if self.bounds_error: for i, p in enumerate(xi.T): if not np.logical_and(np.all(self.grid[i][0] <= p), np.all(p <= self.grid[i][-1])): raise ValueError("One of the requested xi is out of bounds " "in dimension %d" % i) indices, norm_distances, out_of_bounds = self._find_indices(xi.T) if method == "linear": result = self._evaluate_linear(indices, norm_distances, out_of_bounds) elif method == "nearest": result = self._evaluate_nearest(indices, norm_distances, out_of_bounds) if not self.bounds_error and self.fill_value is not None: result[out_of_bounds] = self.fill_value return result.reshape(xi_shape[:-1] + self.values.shape[ndim:]) def _evaluate_linear(self, indices, norm_distances, out_of_bounds): # slice for broadcasting over trailing dimensions in self.values vslice = (slice(None),) + (None,)*(self.values.ndim - len(indices)) # find relevant values # each i and i+1 represents a edge edges = itertools.product(*[[i, i + 1] for i in indices]) values = 0. for edge_indices in edges: weight = 1. for ei, i, yi in zip(edge_indices, indices, norm_distances): weight *= np.where(ei == i, 1 - yi, yi) values += np.asarray(self.values[edge_indices]) * weight[vslice] return values def _evaluate_nearest(self, indices, norm_distances, out_of_bounds): idx_res = [np.where(yi <= .5, i, i + 1) for i, yi in zip(indices, norm_distances)] return self.values[tuple(idx_res)] def _find_indices(self, xi): # find relevant edges between which xi are situated indices = [] # compute distance to lower edge in unity units norm_distances = [] # check for out of bounds xi out_of_bounds = np.zeros((xi.shape[1]), dtype=bool) # iterate through dimensions for x, grid in zip(xi, self.grid): i = np.searchsorted(grid, x) - 1 i[i < 0] = 0 i[i > grid.size - 2] = grid.size - 2 indices.append(i) norm_distances.append((x - grid[i]) / (grid[i + 1] - grid[i])) if not self.bounds_error: out_of_bounds += x < grid[0] out_of_bounds += x > grid[-1] return indices, norm_distances, out_of_bounds def interpn(points, values, xi, method="linear", bounds_error=True, fill_value=np.nan): """ Multidimensional interpolation on regular grids. Parameters ---------- points : tuple of ndarray of float, with shapes (m1, ), ..., (mn, ) The points defining the regular grid in n dimensions. values : array_like, shape (m1, ..., mn, ...) The data on the regular grid in n dimensions. xi : ndarray of shape (..., ndim) The coordinates to sample the gridded data at method : str, optional The method of interpolation to perform. Supported are "linear" and "nearest", and "splinef2d". "splinef2d" is only supported for 2-dimensional data. bounds_error : bool, optional If True, when interpolated values are requested outside of the domain of the input data, a ValueError is raised. If False, then `fill_value` is used. fill_value : number, optional If provided, the value to use for points outside of the interpolation domain. If None, values outside the domain are extrapolated. Extrapolation is not supported by method "splinef2d". Returns ------- values_x : ndarray, shape xi.shape[:-1] + values.shape[ndim:] Interpolated values at input coordinates. Notes ----- .. versionadded:: 0.14 See also -------- NearestNDInterpolator : Nearest neighbour interpolation on unstructured data in N dimensions LinearNDInterpolator : Piecewise linear interpolant on unstructured data in N dimensions RegularGridInterpolator : Linear and nearest-neighbor Interpolation on a regular grid in arbitrary dimensions RectBivariateSpline : Bivariate spline approximation over a rectangular mesh """ # sanity check 'method' kwarg if method not in ["linear", "nearest", "splinef2d"]: raise ValueError("interpn only understands the methods 'linear', " "'nearest', and 'splinef2d'. You provided %s." % method) if not hasattr(values, 'ndim'): values = np.asarray(values) ndim = values.ndim if ndim > 2 and method == "splinef2d": raise ValueError("The method spline2fd can only be used for " "2-dimensional input data") if not bounds_error and fill_value is None and method == "splinef2d": raise ValueError("The method spline2fd does not support extrapolation.") # sanity check consistency of input dimensions if len(points) > ndim: raise ValueError("There are %d point arrays, but values has %d " "dimensions" % (len(points), ndim)) if len(points) != ndim and method == 'splinef2d': raise ValueError("The method spline2fd can only be used for " "scalar data with one point per coordinate") # sanity check input grid for i, p in enumerate(points): if not np.all(np.diff(p) > 0.): raise ValueError("The points in dimension %d must be strictly " "ascending" % i) if not np.asarray(p).ndim == 1: raise ValueError("The points in dimension %d must be " "1-dimensional" % i) if not values.shape[i] == len(p): raise ValueError("There are %d points and %d values in " "dimension %d" % (len(p), values.shape[i], i)) grid = tuple([np.asarray(p) for p in points]) # sanity check requested xi xi = _ndim_coords_from_arrays(xi, ndim=len(grid)) if xi.shape[-1] != len(grid): raise ValueError("The requested sample points xi have dimension " "%d, but this RegularGridInterpolator has " "dimension %d" % (xi.shape[1], len(grid))) for i, p in enumerate(xi.T): if bounds_error and not np.logical_and(np.all(grid[i][0] <= p), np.all(p <= grid[i][-1])): raise ValueError("One of the requested xi is out of bounds " "in dimension %d" % i) # perform interpolation if method == "linear": interp = RegularGridInterpolator(points, values, method="linear", bounds_error=bounds_error, fill_value=fill_value) return interp(xi) elif method == "nearest": interp = RegularGridInterpolator(points, values, method="nearest", bounds_error=bounds_error, fill_value=fill_value) return interp(xi) elif method == "splinef2d": xi_shape = xi.shape xi = xi.reshape(-1, xi.shape[-1]) # RectBivariateSpline doesn't support fill_value; we need to wrap here idx_valid = np.all((grid[0][0] <= xi[:, 0], xi[:, 0] <= grid[0][-1], grid[1][0] <= xi[:, 1], xi[:, 1] <= grid[1][-1]), axis=0) result = np.empty_like(xi[:, 0]) # make a copy of values for RectBivariateSpline interp = RectBivariateSpline(points[0], points[1], values[:]) result[idx_valid] = interp.ev(xi[idx_valid, 0], xi[idx_valid, 1]) result[np.logical_not(idx_valid)] = fill_value return result.reshape(xi_shape[:-1]) # backward compatibility wrapper class _ppform(PPoly): """ Deprecated piecewise polynomial class. New code should use the `PPoly` class instead. """ def __init__(self, coeffs, breaks, fill=0.0, sort=False): warnings.warn("_ppform is deprecated -- use PPoly instead", category=DeprecationWarning) if sort: breaks = np.sort(breaks) else: breaks = np.asarray(breaks) PPoly.__init__(self, coeffs, breaks) self.coeffs = self.c self.breaks = self.x self.K = self.coeffs.shape[0] self.fill = fill self.a = self.breaks[0] self.b = self.breaks[-1] def __call__(self, x): return PPoly.__call__(self, x, 0, False) def _evaluate(self, x, nu, extrapolate, out): PPoly._evaluate(self, x, nu, extrapolate, out) out[~((x >= self.a) & (x <= self.b))] = self.fill return out @classmethod def fromspline(cls, xk, cvals, order, fill=0.0): # Note: this spline representation is incompatible with FITPACK N = len(xk)-1 sivals = np.empty((order+1, N), dtype=float) for m in xrange(order, -1, -1): fact = spec.gamma(m+1) res = _fitpack._bspleval(xk[:-1], xk, cvals, order, m) res /= fact sivals[order-m, :] = res return cls(sivals, xk, fill=fill)
bsd-3-clause
rvianello/rdkit
Contrib/fraggle/atomcontrib.py
5
5091
# Copyright (c) 2013, GlaxoSmithKline Research & Development Ltd. # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions are # met: # # * Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # * Redistributions in binary form must reproduce the above # copyright notice, this list of conditions and the following # disclaimer in the documentation and/or other materials provided # with the distribution. # * Neither the name of GlaxoSmithKline Research & Development Ltd. # nor the names of its contributors may be used to endorse or promote # products derived from this software without specific prior written # permission. # # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT # OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, # SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT # LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, # DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY # THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT # (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # # Created by Jameed Hussain, May 2013 from __future__ import print_function import sys from optparse import OptionParser from rdkit import Chem from rdkit import DataStructs from collections import defaultdict #input format #query_substructs,query_smiles,SMILES,ID,Tversky_sim #algorithm #read in query_substructs and smiles #feed to atomcontrib function to return generalised_SMILES #use Tanimoto to compare generalised_SMILES with query smiles to give fraggle similarity from rdkit.Chem.Fraggle import FraggleSim parser = OptionParser( description="Program to post-process Tversky search results as part of Fraggle", epilog="Format of input file: query_frag_smiles,query_smiles,query_id,retrieved_smi,retrieved_id,tversky_sim\t" "Output: SMILES,ID,QuerySMI,QueryID,Fraggle_Similarity,RDK5_Similarity") parser.add_option( '-c', '--cutoff', action='store', dest='cutoff', type='float', default=0.7, help="Cutoff for fraggle similarity. Only results with similarity greater than the cutoff will be output. DEFAULT = 0.7") parser.add_option('-p', '--pfp', action='store', dest='pfp', type='float', default=0.8, help="Cutoff for partial fp similarity. DEFAULT = 0.8") if __name__ == '__main__': #parse the command line options (options, args) = parser.parse_args() if ((options.cutoff >= 0) and (options.cutoff <= 1)): fraggle_cutoff = options.cutoff else: print("Fraggle cutoff must be in range 0-1") sys.exit(1) print("SMILES,ID,QuerySMI,QueryID,Fraggle_Similarity,RDK5_Similarity") #create some data structure to store results id_to_smi = {} day_sim = {} frag_sim = {} query_size = {} query_mols = {} #generate dummy mol object which generates empty fp emptyMol = Chem.MolFromSmiles('*') #read the STDIN for line in sys.stdin: line = line.rstrip() qSubs, qSmi, qID, inSmi, id_, tversky = line.split(",") #add query to id_to_smi id_to_smi[qID] = qSmi id_to_smi[id_] = inSmi #add query to data structures frag_sim.setdefault(qID, defaultdict(float)) day_sim.setdefault(qID, {}) if (qID not in query_size): qMol = Chem.MolFromSmiles(qSmi) if (qMol == None): sys.stderr.write("Can't generate mol for: %s\n" % (qSmi)) continue query_mols[qID] = qMol query_size[qID] = qMol.GetNumAtoms() iMol = Chem.MolFromSmiles(inSmi) if (iMol == None): sys.stderr.write("Can't generate mol for: %s\n" % (inSmi)) continue #discard based on atom size if (iMol.GetNumAtoms() < query_size[qID] - 3): #sys.stderr.write("Too small: %s\n" % (inSmi) ) continue if (iMol.GetNumAtoms() > query_size[qID] + 4): #sys.stderr.write("Too large: %s\n" % (inSmi) ) continue #print '>>>',id_ rdkit_sim, fraggle_sim = FraggleSim.compute_fraggle_similarity_for_subs( iMol, query_mols[qID], qSmi, qSubs, options.pfp) day_sim[qID][id_] = rdkit_sim frag_sim[qID][id_] = max(frag_sim[qID][id_], fraggle_sim) #check if you have the fp for the modified query #and generate if need to #right, print out the results for the query #Format: SMILES,ID,QuerySMI,QueryID,Fraggle_Similarity,Daylight_Similarity for qID in frag_sim: for id_ in frag_sim[qID]: if (frag_sim[qID][id_] >= fraggle_cutoff): print("%s,%s,%s,%s,%s,%s" % (id_to_smi[id_], id_, id_to_smi[qID], qID, frag_sim[qID][id_], day_sim[qID][id_]))
bsd-3-clause