100+ results results for 'python' (732 ms)
226 Object.const_set :RUBY_NAME, 'ruby' 227 @guard.implementation?(:python).should == false 228 endplugins.rst https://bitbucket.org/dhellmann/virtualenvwrapper.git | ReStructuredText | 399 lines
18virtualenv (see :ref:`scripts`). Extensions can also be 19implemented in Python by using `Setuptools entry points`_, making it 20possible to share common behaviors between systems and developers. 47 48The Python package for ``virtualenvwrapper`` is a *namespace package*. 49That means multiple libraries can install code into the package, even 77actual extension entry points. Supporting code can be included, or 78imported from elsewhere using standard Python code organization 79techniques. 80 81The API is the same for every extension point. Each uses a Python 82function that takes a single argument, a list of strings passed to the 200 201 $ python -m virtualenvwrapper.hook_loader -h 202 Usage: virtualenvwrapper.hook_loader [options] <hook> [<arguments>]testMatrix.py https://github.com/wizzk42/numpy.git | Python | 361 lines
1#! /usr/bin/env python 2__init__.py https://bitbucket.org/synic/exaile.git | Python | 369 lines
26 27# support python 2.5 28from __future__ import with_statementcheck_format_compatible.sh https://gitlab.com/barrel-db/erlang-rocksdb | Shell | 372 lines
79 80python_bin=$(which python3 || which python || echo python3) 81 86 echo == Generating random input file ${input_data[$i]} 87 $python_bin - <<EOF 88import random 108echo == Generating file with sorted keys ${sorted_input_data} 109$python_bin - <<EOF 110with open('${sorted_input_data}', 'w') as f:trial.py https://github.com/analogue/mythbox.git | Python | 370 lines
10from twisted.application import app 11from twisted.python import usage, reflect, failure 12from twisted import plugin 12from twisted import plugin 13from twisted.python.util import spewer 14from twisted.python.compat import set 99 "soon as they occur"], 100 ["debug", "b", "Run tests in the Python debugger. Will load " 101 "'.pdbrc' from current directory if it exists."], 108 "after each test case."], 109 ["profile", None, "Run tests under the Python profiler"], 110 ["unclean-warnings", None, 144 Generate coverage information in the _trial_temp/coverage. Requires 145 Python 2.3.3. 146 """mac_roman.py https://gitlab.com/abhi1tb/build | Python | 307 lines
1""" Python Character Mapping Codec mac_roman generated from 'MAPPINGS/VENDORS/APPLE/ROMAN.TXT' with gencodec.py. 2hp_roman8.py https://gitlab.com/abhi1tb/build | Python | 314 lines
1""" Python Character Mapping Codec generated from 'hp_roman8.txt' with gencodec.py. 2thread_pthread.h https://gitlab.com/envieidoc/Clover | C Header | 505 lines
97 98/* A pthread mutex isn't sufficient to model the Python lock type 99 * because, according to Draft 5 of the docs (P1003.4a/D5), both of the 104 * of code anyway, so wouldn't be an appropriate implementation of 105 * Python's locks regardless. 106 * 106 * 107 * The pthread_lock struct implements a Python lock as a "locked?" bit 108 * and a <condition, mutex> pair. In general, if the bit can be acquiredfilters.py https://gitlab.com/braintech/psychopy-brain | Python | 401 lines
1#!/usr/bin/env python 2# -*- coding: utf-8 -*-pytest_mozwebqa.py https://github.com/retornam/pytest-mozwebqa.git | Python | 330 lines
1#!/usr/bin/env python 2fabmetheus_utilities.geometry.solids.cylinder.html https://github.com/sialan/autonomous-sprayer.git | HTML | 173 lines
2<!doctype html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> 3<html><head><title>Python: module fabmetheus_utilities.geometry.solids.cylinder</title> 4</head><body bgcolor="#f0f0f8">skeinforge_tools.clip.html https://github.com/sialan/autonomous-sprayer.git | HTML | 178 lines
2<!doctype html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> 3<html><head><title>Python: module skeinforge_tools.clip</title> 4</head><body bgcolor="#f0f0f8"> 19loops will have a gap, if the ratio is too low there will be a bulge at the loop ends. To run clip, in a shell type:<br> 20> python clip.py<br> 21 <br> 29 <br> 30> python clip.py<br> 31This brings up the dialog, after clicking 'Clip', the following is printed:<br> 35 <br> 36> python clip.py Screw Holder Bottom.stl<br> 37File Screw Holder Bottom.stl is being chain clipped.<br> 40 <br> 41> python<br> 42Python 2.5.1 (r251:54863, Sep 22 2007, 01:43:31)<br>decoder.py https://gitlab.com/dahbearz/CRYENGINE | Python | 385 lines
279 +---------------+-------------------+ 280 | JSON | Python | 281 +===============+===================+ 361 def decode(self, s, _w=WHITESPACE.match): 362 """Return the Python representation of ``s`` (a ``str`` or ``unicode`` 363 instance containing a JSON document) 373 """Decode a JSON document from ``s`` (a ``str`` or ``unicode`` 374 beginning with a JSON document) and return a 2-tuple of the Python 375 representation and the index in ``s`` where the document ended.IntegerTest.cs https://bitbucket.org/mdavid/dlr.git | C# | 237 lines
17 18namespace IronPythonTest { 19 public class IntegerTest {tests.py https://github.com/theosp/google_appengine.git | Python | 350 lines
51class DecimalFieldTests(test.TestCase): 52 def test_to_python(self): 53 f = models.DecimalField(max_digits=4, decimal_places=2) 53 f = models.DecimalField(max_digits=4, decimal_places=2) 54 self.assertEqual(f.to_python(3), Decimal("3")) 55 self.assertEqual(f.to_python("3.14"), Decimal("3.14")) 55 self.assertEqual(f.to_python("3.14"), Decimal("3.14")) 56 self.assertRaises(ValidationError, f.to_python, "abc") 57 63 f = models.DecimalField(max_digits=5, decimal_places=1) 64 self.assertEqual(f._format(f.to_python(2)), u'2.0') 65 self.assertEqual(f._format(f.to_python('2.6')), u'2.6') 92 Ensure that really big values can be used in a filter statement, even 93 with older Python versions. 94 """http_runtime_test.py https://github.com/theosp/google_appengine.git | Python | 378 lines
1#!/usr/bin/env python 2#__main__.py https://gitlab.com/Yabolo/SyntheSys | Python | 363 lines
1#!/usr/bin/python3 2 260 ws['A1'] = "Resources collection date:" # Data can be assigned directly to cells 261 ws['A2'] = datetime.datetime.now() # Python types will automatically be converted 262builtin-test.c https://gitlab.com/deepcypher/linux | C | 639 lines
55 &suite__hists_link, 56 &suite__python_use, 57 &suite__bp_signal,JSONThunker.py https://github.com/PerilousApricot/WMCore.git | Python | 360 lines
106 """ 107 unthunk - turns a previously 'thunked' object back into a python object 108 """ 289 # here be monsters 290 # inspired from python's pickle code 291 ourClass = self.getThunkedClass(jsondata)DBSWriterObjects.py https://github.com/PerilousApricot/WMCore.git | Python | 451 lines
1#!/usr/bin/env python 2"""dmm_es51922.py https://bitbucket.org/kuzavas/dmm_es51922.git | Python | 454 lines
51 52# http://wiki.python.org/moin/BitManipulation 53# testBit() returns a nonzero result, 2**offset, if the bit at 'offset' is one._ctypes_test.c https://bitbucket.org/apexgames-ondemand/zombie-onslaught-source.git | C | 602 lines
1/***************************************************************** 2 This file should be kept compatible with Python 2.3, see PEP 291. 3 *****************************************************************/ 5 6#include <Python.h> 7 9 Backwards compatibility: 10 Python2.2 used LONG_LONG instead of PY_LONG_LONG 11*/0007.c https://gitlab.com/ideasman42/py-array-cow | C | 557 lines
72 73#include "BPY_extern.h" // for init of blender python extension 74 277 printf ("\tlooked like a split (disabled) snake, and also\n"); 278 printf ("\twas similar to a python's tongue (unproven).\n\n"); 279 283 printf ("\tADDENDUM! Ton, in defense, found this picture of\n"); 284 printf ("\tan Australian python, exhibiting her (his/its) forked\n"); 285 printf ("\tY tongue. It could be part of an H Zr retorted!\n\n"); 362 else if (strcasecmp(argv[a], "-nofrozen") == 0) { 363 /* disable initialization of frozen python modules */ 364 if (G.f & G_DEBUG) printf("disable frozen modules\n"); 371 372 BPY_start_python(); 373gitlab-rails_spec.rb https://gitlab.com/denkweite/omnibus-gitlab | Ruby | 301 lines
114 it_behaves_like "enabled gitlab-rails env", "ICU_DATA", '\/opt\/gitlab\/embedded\/share\/icu\/current' 115 it_behaves_like "enabled gitlab-rails env", "PYTHONPATH", '\/opt\/gitlab\/embedded\/lib\/python3.4\/site-packages' 116__init__.py https://bitbucket.org/EtiennePerot/damnvid.git | Python | 387 lines
1"""SocksiPy - Python SOCKS module. 2Version 1.00 27 28This module provides a standard socket-like interface for Python 29for tunneling connections through SOCKS proxies.generate-sysdig-event.py https://gitlab.com/jvelando/wireshark | Python | 380 lines
1#!/usr/bin/env python3 2#pycontext.cc https://github.com/homework/nox.git | C++ | 455 lines
20#ifndef SWIG 21#ifndef SWIGPYTHON 22#include "swigpyrun.h" 22#include "swigpyrun.h" 23#endif // SWIGPYTHON 24#endif // SWIG 72PyContext::PyContext(const container::Context* ctxt_, 73 container::Component* c_, Python_event_manager* pyem_) 74 : ctxt(ctxt_), c(c_), pyem(pyem_) { 129 130static void convert_python_event(const Event& e, PyObject* proxy) { 131 const pyevent& sfe 133 134 if(sfe.python_arg){ 135 pyglue_setattr_string(proxy, "pyevent", sfe.python_arg);history.html https://github.com/trevor/ImageMagick.git | HTML | 217 lines
11 <meta name="Application-name" content="ImageMagick"/> 12 <meta name="Description" content="ImageMagick® is a software suite to create, edit, and compose bitmap images. It can read, convert and write images in a variety of formats (about 100) including GIF, JPEG, JPEG-2000, PNG, PDF, PhotoCD, TIFF, and DPX. Use ImageMagick to translate, flip, mirror, rotate, scale, shear and transform images, adjust image colors, apply various special effects, or draw text, lines, polygons, ellipses and Bézier curves. ImageMagick is free software delivered as a ready-to-run binary distribution or as source code that you can freely use, copy, modify, and distribute. Its license is compatible with the GPL. It runs on all major operating systems. The functionality of ImageMagick is typically utilized from the command line or you can use the features from programs written in your favorite programming language. Choose from these interfaces: MagickCore (C), MagickWand (C), ChMagick (Ch), Magick++ (C++), JMagick (Java), L-Magick (Lisp), PascalMagick (Pascal), PerlMagick (Perl), MagickWand for PHP (PHP), PythonMagick (Python), RMagick (Ruby), or TclMagick (Tcl/TK). With a language interface, use ImageMagick to modify or create images automagically and dynamically."/> 13 <meta name="Application-url" content="http://www.imagemagick.org"/> 14 <meta name="Generator" content="PHP"/> 15 <meta name="Keywords" content="history, ImageMagick, ImageMagic, MagickCore, MagickWand, PerlMagick, Magick++, RMagick, PythonMagick, JMagick, TclMagick, Image, Magick, Magic, Wand, ImageMagickObject, Swiss, Army, Knife, Image, Processing"/> 16 <meta name="Rating" content="GENERAL"/>relatedprojects.html https://gitlab.com/gregas/QSTK | HTML | 319 lines
14<p> <a href="http://www.python.org/sigs/doc-sig/">Doc-sig</a> is a 15Python special interest group dedicated to producing documentation and 16documentation tools for Python. Much of my work on epydoc was 104using comments as well as docstrings. However, since HappyDoc gets 105information about Python objects by parsing Python source files, it 106cannot be used on builtin (C) modules. </p> 112the differences in how epydoc and HappyDoc derive and store 113information about Python objects. Also, HappyDoc does not appear to 114have a mechanism for associating descriptions with specific fields 148<p> <a 149href="http://starship.python.net/crew/danilo/pythondoc/">Pythondoc</a> 150is a Python API documentation tool that uses StructuredText for 204HTML output. For an example of its output, see its <a 205href="http://www.lemburg.com/files/python/PythonStuff.html">API 206documentation</a>. </p>pyparam.c https://github.com/lauria/Samba4.git | C | 484 lines
19 20#include <Python.h> 21#include "includes.h" 106 107 /* construct and return the right type of python object */ 108 switch (parm->type) {exceptions.py https://github.com/mozilla/doozer-lib.git | Python | 445 lines
5 6 This module implements a number of Python exceptions you can raise from 7 within your views to trigger a standard non-200 response. 30 As you can see from this example those exceptions are callable WSGI 31 applications. Because of Python 2.4 compatibility those do not extend 32 from the response objects but only from the python exception class.Player.cpp https://github.com/alanwww1/xbmc.git | C++ | 502 lines
141 142 // play a python playlist (a playlist from playlistplayer.cpp) 143 iPlayList = playlist->getPlayListId();tab.html https://github.com/yiminghe/kissyteam.github.com.git | HTML | 308 lines
82 <li class="right" > 83 <a href="../../../py-modindex.html" title="Python Module Index" 84 >modules</a> | </li> 187 <li class="right" > 188 <a href="../../../py-modindex.html" title="Python Module Index" 189 >modules</a> | </li>first_run.html https://github.com/clawpack/clawpack.github.com.git | HTML | 268 lines
66 <li class="right" > 67 <a href="py-modindex.html" title="Python Module Index" 68 >modules</a> |</li> 92<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="n">cd</span> <span class="n">pyclaw</span><span class="o">/</span><span class="n">examples</span><span class="o">/</span><span class="n">euler_2d</span> 93<span class="n">python</span> <span class="n">shock_bubble_interaction</span><span class="o">.</span><span class="n">py</span> <span class="n">iplot</span><span class="o">=</span><span class="mi">1</span> 94</pre></div> 139<p>If this gives an error, see <a class="reference internal" href="trouble.html#trouble-makedata"><span class="std std-ref">Trouble running “make .data”</span></a>.</p> 140<p>This uses the Python code in <cite>setrun.py</cite> to create data files that have the 141form <cite>*.data</cite>.</p> 158options for plotting the results.</p> 159<p>To try the Python tools, type:</p> 160<div class="highlight-default notranslate"><div class="highlight"><pre><span></span>$ make .plots 166results from a web browser. See <span class="xref std std-ref">plotting_makeplots</span> for more details.</p> 167<p>An alternative is to view the plots from an interactive Python session, as described in 168the section <a class="reference internal" href="plotting_python.html#plotting-iplotclaw"><span class="std std-ref">Interactive plotting with Iplotclaw</span></a>.</p>perf_device_trigger_unittest.py https://github.com/chromium/chromium.git | Python | 353 lines
1#!/usr/bin/env vpython3 2# Copyright 2018 The Chromium Authors. All rights reserved.roll.py https://github.com/chromium/chromium.git | Python | 415 lines
1#!/usr/bin/env python3 2 132 'src/doc', 133 'src/python', 134 'src/tests',BUILD.gn https://github.com/chromium/chromium.git | GN | 394 lines
17 18blink_python_runner("make_generated_origin_trial_feature") { 19 script = "../../renderer/build/scripts/make_origin_trial_feature.py" 37 38blink_python_runner("make_generated_permissions_policy_helper") { 39 script = "../../renderer/build/scripts/make_policy_helper_public.py"aui_utilities.py https://github.com/astory/RankPanda.git | Python | 468 lines
1""" 2This module contains some common functions used by wxPython-AUI to 3manipulate colours, bitmaps, text, gradient shadings and custommain.cpp https://github.com/Deledrius/Plasma.git | C++ | 402 lines
129 130 PyObject* pythonCode = PythonInterface::CompileString(code, fileName); 131 if (pythonCode) 133 // run the code 134 if (PythonInterface::RunPYC(pythonCode, fModule) ) 135 { 188 char* pycode; 189 PythonInterface::DumpObject(pythonCode,&pycode,&size); 190 304 305 PythonInterface::initPython(rootPath, extraDirs, out, stderr); 306 329 330 PythonInterface::finiPython(); 331}multiline.html https://gitlab.com/lewdlime/pythonista-docs-full | HTML | 190 lines
9 <title>pylab_examples example code: multiline.py — Matplotlib 1.3.1 documentation</title> 10 <link rel="stylesheet" href="../../_static/pythonista.css" type="text/css" /> 11 <link rel="stylesheet" href="../../_static/pygments.css" type="text/css" /> 42 var openSample = function (i) { 43 window.location.href = '/__pythonista_open__/' + encodeURI(getTextForSample(i)); 44 } 101 <li class="right" > 102 <a href="../../py-modindex.html" title="Python Module Index" 103 >modules</a> |</li> 116<span id="pylab-examples-multiline"></span><h1>pylab_examples example code: multiline.py<a class="headerlink" href="#pylab-examples-example-code-multiline-py" title="Permalink to this headline">¶</a></h1> 117<p>(<a class="reference external" href="../../../../../Pythonista/matplotlib-1.3.1/doc/mpl_examples/pylab_examples/multiline.py">Source code</a>, <a class="reference external" href="../../../../../Pythonista/matplotlib-1.3.1/doc/mpl_examples/pylab_examples/multiline.png">png</a>)</p> 118<div class="figure"> 120</div> 121<div class="highlight-python"><div class="highlight"><pre><span class="c">#!/usr/bin/env python</span> 122<span class="kn">from</span> <span class="nn">pylab</span> <span class="kn">import</span> <span class="o">*</span>find_domain_arch.py https://github.com/ntamas/gfam.git | Python | 295 lines
1#!/usr/bin/env python 2"""Application that calculates the domain architecture of each gene andtranslator.h https://github.com/ipatrol/pyqt4.git | C Header | 402 lines
6** 7** This version is modified to handle python sources. 8**README.md https://github.com/imagesdesmaths/idm.git | Markdown | 273 lines
4 5* Python 2.6 or 2.7. Python 3.x is not supported. 6* Update to Piwik 1.11 6* Update to Piwik 1.11 7* OrderedDict is optional (see https://pypi.python.org/pypi/ordereddict for more details). . 8 22 23 python /path/to/piwik/misc/log-analytics/import_logs.py --url=http://mysite/piwik/ --idsite=1234 --recorders=4 --enable-http-errors --enable-http-redirects --enable-static --enable-bots access.log 24 251 252exec python /path/to/misc/log-analytics/import_logs.py \ 253 --url=http://localhost/ --token-auth=<your_auth_token> \Makefile.in https://github.com/flyapen/UgFlu.git | Autoconf | 474 lines
171PYGTK_LIBS = @PYGTK_LIBS@ 172PYTHON = @PYTHON@ 173PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ 234pyexecdir = @pyexecdir@ 235pythondir = @pythondir@ 236sbindir = @sbindir@ 297 -rm -rf .libs _libs 298install-flumotionPYTHON: $(flumotion_PYTHON) 299 @$(NORMAL_INSTALL) 311 if test -z "$(DESTDIR)"; then \ 312 PYTHON=$(PYTHON) $(py_compile) --basedir "$(flumotiondir)" $$dlist; \ 313 else \ 313 else \ 314 PYTHON=$(PYTHON) $(py_compile) --destdir "$(DESTDIR)" --basedir "$(flumotiondir)" $$dlist; \ 315 fi; \Makefile.in https://github.com/flyapen/UgFlu.git | Autoconf | 467 lines
171PYGTK_LIBS = @PYGTK_LIBS@ 172PYTHON = @PYTHON@ 173PYTHON_EXEC_PREFIX = @PYTHON_EXEC_PREFIX@ 234pyexecdir = @pyexecdir@ 235pythondir = @pythondir@ 236sbindir = @sbindir@ 290 -rm -rf .libs _libs 291install-componentPYTHON: $(component_PYTHON) 292 @$(NORMAL_INSTALL) 304 if test -z "$(DESTDIR)"; then \ 305 PYTHON=$(PYTHON) $(py_compile) --basedir "$(componentdir)" $$dlist; \ 306 else \ 306 else \ 307 PYTHON=$(PYTHON) $(py_compile) --destdir "$(DESTDIR)" --basedir "$(componentdir)" $$dlist; \ 308 fi; \fourier.html https://gitlab.com/sang.nguyen/practice_git | HTML | 283 lines
10 11 <title>d2o.analyze.fourier — d2o Python Library 1.0 documentation</title> 12 32 33 <link rel="top" title="d2o Python Library 1.0 documentation" href="../../../index.html"/> 34 <link rel="up" title="Module code" href="../../index.html"/> 51 52 <a href="../../../index.html" class="icon icon-home"> d2o Python Library 53 96 <i data-toggle="wy-nav-top" class="fa fa-bars"></i> 97 <a href="../../../index.html">d2o Python Library</a> 98 </nav>ssl_.py https://github.com/yoheia/yoheia.git | Python | 392 lines
60 61try: # Platform-specific: Python 3.6 62 from ssl import PROTOCOL_TLS 94# - NOTE: TLS 1.3 cipher suites are managed through a different interface 95# not exposed by CPython (yet!) and are enabled by default if they're available. 96DEFAULT_CIPHERS = ':'.join([ 115except ImportError: 116 class SSLContext(object): # Platform-specific: Python 2 117 def __init__(self, protocol_version): 135 if capath is not None: 136 raise SSLError("CA directories not supported in older Pythons") 137 145 'certain SSL connections to fail. You can upgrade to a newer ' 146 'version of Python to solve this. For more information, see ' 147 'https://urllib3.readthedocs.io/en/latest/advanced-usage.html'celery.rst https://github.com/e98cuenc/celery.git | ReStructuredText | 465 lines
117 118 .. code-block:: python 119 131 132 .. code-block:: python 133 186 187 .. code-block:: python 188 194 195 .. code-block:: python 196cronvar.py https://gitlab.com/cfernand/acm-aap-demo | Python | 423 lines
1#!/usr/bin/python 2# -*- coding: utf-8 -*-routing.py https://github.com/rsms/smisk.git | Python | 477 lines
1#!/usr/bin/env python 2# encoding: utf-8 10from smisk.util.type import * 11from smisk.util.python import wrap_exc_in_callable 12from smisk.util.string import tokenize_pathbase.py https://github.com/thraxil/gtreed.git | Python | 391 lines
174class Shell(CommandWithDB): 175 """Convenient version of the Python interactive shell. 176 This shell attempts to locate your configuration file and model module 177 so that it can import everything from your model and make it available 178 in the Python shell namespace.""" 179 179 180 desc = "Start a Python prompt with your database available" 181 need_project = True 201 try: 202 # try to use IPython if possible 203 import IPython 204 205 class CustomIPShell(IPython.iplib.InteractiveShell): 206 def raw_input(self, *args, **kw):LibStdcpp.cpp https://gitlab.com/jorjpimm/lldb | C++ | 331 lines
9 10#include "lldb/lldb-python.h" 11benchmark.py https://gitlab.com/hrishikeshvganu/tensorflow | Python | 301 lines
33# ":platform_test", which also brings in ":platform" (and thus this library). 34from tensorflow.python.client import timeline 35from tensorflow.python.platform import app 35from tensorflow.python.platform import app 36from tensorflow.python.platform import gfile 37histogram_ops.py https://gitlab.com/hrishikeshvganu/tensorflow | Python | 238 lines
24 25from tensorflow.python.framework import dtypes 26from tensorflow.python.framework import ops 26from tensorflow.python.framework import ops 27from tensorflow.python.ops import array_ops 28from tensorflow.python.ops import constant_op 28from tensorflow.python.ops import constant_op 29from tensorflow.python.ops import control_flow_ops 30from tensorflow.python.ops import histogram_ops 30from tensorflow.python.ops import histogram_ops 31from tensorflow.python.ops import logging_ops 32from tensorflow.python.ops import math_ops 32from tensorflow.python.ops import math_ops 33from tensorflow.python.ops import nn_ops 34from tensorflow.python.ops import variable_scopeskeinforge_application.skeinforge_plugins.craft_plugins.carve.html https://github.com/jmil/SFACT.git | HTML | 223 lines
2<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> 3<html><head><title>Python: module skeinforge_application.skeinforge_plugins.craft_plugins.carve</title> 4</head><body bgcolor="#f0f0f8"> 77 78Carve slices from bottom to top. To get a single layer, set the "Layers From" to zero and the "Layers To" to one. The 'Layers From' until 'Layers To' range is a python slice.<br> 79 <br> 120 <br> 121> python carve.py<br> 122This brings up the carve dialog.<br> 123 <br> 124> python carve.py Screw Holder Bottom.stl<br> 125The carve tool is parsing the file:<br>acp.vim https://github.com/Alan0521/vimfiles.git | Vim Script | 422 lines
123function acp#meetsForPythonOmni(context) 124 return has('python') && g:acp_behaviorPythonOmniLength >= 0 && 125 \ a:context =~ '\k\.\k\{' . g:acp_behaviorPythonOmniLength . ',}$'settings_base.py https://github.com/kumar303/funfactory.git | Python | 311 lines
130 ('apps/**.py', 131 'tower.management.commands.extract.extract_tower_python'), 132 ('apps/**/templates/**.html',coil.py https://github.com/jmil/SFACT.git | Python | 252 lines
16 17> python coil.py 18This brings up the coil dialog. 19 20> python coil.py Screw Holder Bottom.stl 21The coil tool is parsing the file: 29from __future__ import absolute_import 30#Init has to be imported first because it has code to workaround the python bug where relative imports don't work if the module is imported as a main module. 31import __init__ir_black.vim https://github.com/abelmathew/vimrc.git | Vim Script | 212 lines
203 204" Special for Python 205"hi link pythonEscape Keywordtest_server.cc https://gitlab.com/brian0218/rk3188_r-box_android4.2.2_sdk | C++ | 397 lines
34#include "net/socket/tcp_client_socket.h" 35#include "net/test/python_utils.h" 36#include "testing/platform_test.h" 113 114 // Get path to python server script 115 FilePath testserver_path; 125 126 if (!SetPythonPath()) 127 return false; 128 129 if (!LaunchPython(testserver_path)) 130 return false; 278 279bool TestServer::SetPythonPath() { 280 FilePath third_party_dir;pywin32_testutil.py https://bitbucket.org/beqa/nvdadependencyvirtualenvironment.git | Python | 270 lines
72 # gateways/interfaces 73 from pythoncom import _GetInterfaceCount, _GetGatewayCount 74 gc.collect() 178 from win32com.shell.shell import IsUserAnAdmin 179 import pythoncom 180 try: 181 _is_admin = IsUserAnAdmin() 182 except pythoncom.com_error, exc: 183 if exc.hresult != winerror.E_NOTIMPL:sessions.py https://bitbucket.org/stavrossk/maraschino.git | Python | 344 lines
6 This module contains some helper classes that help one to add session 7 support to a python WSGI application. For full client-side session 8 storage see :mod:`~werkzeug.contrib.securecookie` which implements aCreateExplicitInstantiations.cmake https://github.com/paniwani/OTB.git | CMake | 287 lines
77 # and for all builds. That's important for several reasons: 78 # - the order is important for the order of creation of python template 79 # - the typemaps files are always the same, and the rebuild can be avoidedautograder.py https://bitbucket.org/wesleyto/cs188.git | Python | 348 lines
10 11# imports from python standard library 12import gradingssl_.py https://gitlab.com/abhi1tb/build | Python | 407 lines
45 46try: # Platform-specific: Python 3.6 47 from ssl import PROTOCOL_TLS 105 106 class SSLContext(object): # Platform-specific: Python 2 107 def __init__(self, protocol_version): 125 if capath is not None: 126 raise SSLError("CA directories not supported in older Pythons") 127 135 "certain SSL connections to fail. You can upgrade to a newer " 136 "version of Python to solve this. For more information, see " 137 "https://urllib3.readthedocs.io/en/latest/advanced-usage.html" 277 # The attribute is None for OpenSSL <= 1.1.0 or does not exist in older 278 # versions of Python. We only enable on Python 3.7.4+ or if certificate 279 # verification is enabled to work around Python issue #37428test_env.rb https://gitlab.com/wolfgang42/gitlab-ce | Ruby | 453 lines
53 'v1.1.0' => 'b83d6e3', 54 'add-ipython-files' => '93ee732', 55 'add-pdf-file' => 'e774ebd',README.md https://gitlab.com/vasuvanka/hphrs | Markdown | 415 lines
31 32Bug reports in JIRA for all driver projects (i.e. NODE, PYTHON, CSHARP, JAVA) and the 33Core Server (i.e. SERVER) project are **public**. 74 75If you don’t have the build essentials it won’t build. In the case of linux you will need gcc and g++, node.js with all the headers and python. The easiest way to figure out what’s missing is by trying to build the kerberos project. You can do this by performing the following steps. 76 109* Windows 7 64bit SDK 110* Python 2.7 or higher 111 130 131Your python installation might be hosed making gyp break. I always recommend that you test your deployment environment first by trying to build node itself on the server in question as this should unearth any issues with broken packages (and there are a lot of broken packages out there). 132skeinforge_application.skeinforge_plugins.craft_plugins.carve.html https://github.com/sialan/autonomous-sprayer.git | HTML | 223 lines
2<!doctype html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> 3<html><head><title>Python: module skeinforge_application.skeinforge_plugins.craft_plugins.carve</title> 4</head><body bgcolor="#f0f0f8"> 77 78Carve slices from bottom to top. To get a single layer, set the "Layers From" to zero and the "Layers To" to one. The 'Layers From' until 'Layers To' range is a python slice.<br> 79 <br> 120 <br> 121> python carve.py<br> 122This brings up the carve dialog.<br> 123 <br> 124> python carve.py Screw Holder Bottom.stl<br> 125The carve tool is parsing the file:<br>utils.py https://gitlab.com/mdomke/flake8 | Python | 317 lines
101 # NOTE(sigmavirus24): Below we use a slice because stdin may be 102 # bytes instead of text on Python 3. 103 if line[:1] != '-': 171 :returns: 172 True if the version of Python is modern enough, otherwise False 173 :rtype: 175 """ 176 is_new_enough_python27 = sys.version_info >= (2, 7, 11) 177 is_new_enough_python3 = sys.version_info > (3, 2) 177 is_new_enough_python3 = sys.version_info > (3, 2) 178 return is_new_enough_python27 or is_new_enough_python3 179 303 304def get_python_version(): 305 """Find and format the python implementation and version.IcoImagePlugin.py https://gitlab.com/abhi1tb/build | Python | 324 lines
1# 2# The Python Imaging Library. 3# $Id$unit_conversions.py https://gitlab.com/braintech/psychopy-brain | Python | 301 lines
50# 51# Since the Python math lib trig functions work with radians, 52# a radian to angle conversion factor (deg/rad = 57.2958) is included to give angleDemo_1.py https://gitlab.com/luntai/Python | Python | 397 lines
126''' 127 在Python中定义函数,可以用必选参数、默认参数、可变参数、关键字参数和命名关键字参数,这5种参数都可以组合使用。 128 但是请注意,参数定义的顺序必须是:必选参数、默认参数、可变参数、命名关键字参数和关键字参数。 300####函数式编程#### 301'''Python 支持函数式编程,因为可以使用变量作为参数,也支持用函数作为参数,所以Python不是纯函数式编程语言''' 302print(abs)Element.py https://github.com/MrGreen123/Pydev.git | Python | 267 lines
28import re, string 29#FIXME: should allow combining characters: fix when Python gets Unicode 30g_namePattern = re.compile('[a-zA-Z_:][\w\.\-_:]*\Z')CGIHTTPServer.py https://github.com/MrGreen123/Pydev.git | Python | 305 lines
7os.popen2() is used as a fallback, with slightly altered semantics; if 8that function is not present either (e.g. on Macintosh), only Python 9scripts are supported, and they are executed by the current process. 14SECURITY WARNING: DON'T USE THIS CODE UNLESS YOU ARE INSIDE A FIREWALL 15-- it may execute arbitrary Python code or external programs. 16 96 97 def is_python(self, path): 98 """Test whether argument path is a Python script.""" 123 return 124 ispy = self.is_python(scriptname) 125 if not ispy: 223 if interp.lower().endswith("w.exe"): 224 # On Windows, use python.exe, not python.exe 225 interp = interp[:-5] = interp[-4:]storage.py https://github.com/enlaces/curso_python_dga_11.git | Python | 275 lines
82 Returns a local filesystem path where the file can be retrieved using 83 Python's built-in open() function. Storage systems that can't be 84 accessed using open() should *not* implement this method.duration.pb.go https://gitlab.com/unofficial-mirrors/kubernetes | Go | 500 lines
76// 77// Example 3: Compute Duration from datetime.timedelta in Python. 78//CodeCoverage.cmake https://gitlab.com/lwiz/BasicEventEngine | CMake | 309 lines
77find_program( GCOVR_PATH gcovr PATHS ${CMAKE_SOURCE_DIR}/scripts/test) 78#find_package(Python COMPONENTS Interpreter) 79set(Python_FOUND TRUE) 79set(Python_FOUND TRUE) 80set(Python_EXECUTABLE "/usr/bin/env" "python") 81 208 209 if(NOT Python_FOUND) 210 message(FATAL_ERROR "python not found! Aborting...") 263 264 if(NOT Python_FOUND) 265 message(FATAL_ERROR "python not found! Aborting...") 287 # Running gcovr 288 COMMAND ${Python_EXECUTABLE} ${GCOVR_PATH} --html --html-details 289 -r ${PROJECT_SOURCE_DIR} ${GCOVR_EXCLUDES}montage.html https://bitbucket.org/wallwizz/imagemagick-6.8.4-for-bb10.git | HTML | 350 lines
18 <meta name="generator" content="PHP"/> 19 <meta name="keywords" content="magickcore, c, api, for, imagemagick:, create, an, image, thumbnail, ImageMagick, ImageMagic, MagickCore, MagickWand, PerlMagick, Magick++, RMagick, PythonMagick, JMagick, TclMagick, Image, Magick, Magic, Wand, ImageMagickObject, Image, Processing, Automagically"/> 20 <meta name="rating" content="GENERAL"/>git.py https://bitbucket.org/rafaelmoreira/sublime-text.git | Python | 333 lines
111 112 # Per http://bugs.python.org/issue8557 shell=True is required to 113 # get $PATH on Windows. Yay portable code. 124 output = '' 125 # if sublime's python gets bumped to 2.7 we can just do: 126 # output = subprocess.check_output(self.command)booleansolid.py https://github.com/sialan/autonomous-sprayer.git | Python | 246 lines
11 12> python 13Python 2.5.1 (r251:54863, Sep 22 2007, 01:43:31) 29from __future__ import absolute_import 30#Init has to be imported first because it has code to workaround the python bug where relative imports don't work if the module is imported as a main module. 31import __init__install.rst https://bitbucket.org/dyim42/virtualenvwrapper.git | ReStructuredText | 320 lines
75 76Python Versions 77=============== 78 79virtualenvwrapper is tested under Python 2.6-3.3. 80 100 should only ever install virtualenv and virtualenvwrapper on your 101 base Python installation (i.e. NOT while a virtualenv is active) 102 so that the same release is shared by all Python environments that 106add it to `your user local directory 107<http://docs.python.org/install/index.html#alternate-installation-the-home-scheme>`__ 108(usually `~/.local`). 258 259 export VIRTUALENVWRAPPER_PYTHON=/usr/local/bin/python 260 export VIRTUALENVWRAPPER_VIRTUALENV=/usr/local/bin/virtualenvpost.i https://bitbucket.org/pefarrell/dolfin.git | Swig | 331 lines
33{ 34%pythoncode%{ 35def warn_once(self, msg): 116 117%pythoncode%{ 118 264 265%pythoncode%{ 266old_init = Parameters.__init__ 316 317// Expose the global variable parameters for the Python interface 318// NOTE: Because parameters are stored using shared_ptr we need to 327 328%pythoncode%{ 329parameters = _common.get_global_parameters()tf.contrib.learn.LinearRegressor.md https://gitlab.com/github-cloud-corporation/tensorflow | Markdown | 326 lines
7 8```python 9education = sparse_column_with_hash_bucket(column_name="education",layers.rst https://gitlab.com/github-cloud-corporation/neon | ReStructuredText | 234 lines
21 22.. code-block:: python 23 95 96.. code-block:: python 97 122 123.. code-block:: python 124 170 171.. code-block:: python 172 183 184.. code-block:: python 185index.rst https://gitlab.com/Rockyspade/astropy | ReStructuredText | 264 lines
90For simpler formats such as CSV, |read| will automatically try reading with the 91Cython/C parsing engine, which is significantly faster than the ordinary Python 92implementation (described in :ref:`fast_ascii_io`). If the fast engine fails, 92implementation (described in :ref:`fast_ascii_io`). If the fast engine fails, 93|read| will fall back on the Python reader by default. The argument 94``fast_reader`` can be specified to control this behavior. For example, to_cpconfig.py https://github.com/theosp/google_appengine.git | Python | 295 lines
36 37Configuration data may be supplied as a Python dictionary, as a filename, 38or as an open file object. When you supply a filename or file, CherryPy 38or as an open file object. When you supply a filename or file, CherryPy 39uses Python's builtin ConfigParser; you declare Application config by 40writing each path as a section header:: 116app.namespaces, or app.request_class.namespaces. The name can 117be any string, and the handler must be either a callable or a (Python 2.5 118style) context manager.langbulgarianmodel.py https://gitlab.com/dannywillems/Arduino | Python | 229 lines
9# Contributor(s): 10# Mark Pilgrim - port to Python 11#README.md https://gitlab.com/lwd17/enhanced_examplar_ae | Markdown | 226 lines
45# remove sentences with more than 50% punctuation 46python /path/to/fairseq/examples/m2m_100/process_data/remove_too_much_punc.py 47 54# remove all instances of evaluation data from the training data 55python /path/to/fairseq/examples/m2m_100/process_data/dedup_data.py 56 59tar -xvzf histograms.tar.gz 60python /path/to/fairseq/examples/m2m_100/process_data/clean_histogram.py --src $src --tgt $tgt --src-file /path/to/source/file --tgt-file /path/to/output/file --src-output-file source_output.$src --tgt-output-file target_output.$tgt --histograms /path/to/histograms 61 63wget https://dl.fbaipublicfiles.com/m2m_100/spm.128k.model 64python /path/to/fairseq/scripts/spm_encode.py \ 65 --model spm.128k.model \ 158for lang in de fr ; do 159 python scripts/spm_encode.py \ 160 --model spm.128k.model \tf.contrib.graph_editor.SubGraphView.md https://gitlab.com/admin-github-cloud/tensorflow | Markdown | 391 lines
80instances of a given subgraph. In that sense, the class SubGraphView is meant 81to be used like an immutable python object. 82 86the life time of subgraph views are kept very short. One way to achieve this 87is to use subgraphs within a "with make_sgv(...) as sgv:" Python context. 88 138 139Return a Python set of all the consumers of this subgraph view. 140quickstart.html.md.erb https://gitlab.com/github-cloud-corporation/incubator-predictionio | Ruby HTML | 466 lines
80 </div> 81 <div data-tab="Python SDK" data-lang="python"> 82```python 219 </div> 220 <div data-tab="Python SDK" data-lang="python"> 221```python 346A Python import script `import_eventserver.py` is provided to import the data to 347Event Server using Python SDK. Please upgrade to the latest Python SDK. 348 348 349<%= partial 'shared/quickstart/install_python_sdk' %> 350 392 </div> 393 <div data-tab="Python SDK" data-lang="python"> 394```pythonindex.rst https://gitlab.com/Rockyspade/astropy | ReStructuredText | 370 lines
84configuration file as described above. Values can also, however, be 85modified in an active python session by setting any of the properties 86on a ``conf`` object. 117 118Instead of modifying the variables in python, you can also modify the 119configuration files and then reload them. For example, if you modify the 153 154You can also reset a configuration parameter back to its default value. Note that this is the default value defined in the Python code, and has nothing to do with the configuration file on disk:: 155 297`validation section of the configobj manual 298<http://www.voidspace.org.uk/python/validate.html#the-standard-functions>`_. 299Below is a list of the valid values here for quick reference:plugin.py https://github.com/jcrobak/hue.git | Python | 332 lines
14# Twisted imports 15from twisted.python import util 16 25class PlugIn: 26 """I am a Python module registered in a plugins.tml file. 27 """ 58class DropIn: 59 """I am a Python package containing plugins.tml. 60 """ 67 """ 68 warnings.warn("The twisted.python.plugin system is deprecated. " 69 "See twisted.plugin for the revised edition.", 290 """ 291 warnings.warn("The twisted.python.plugin system is deprecated. " 292 "See twisted.plugin for the revised edition.",typing.py https://gitlab.com/lokiexinferis/vim-configs | Python | 341 lines
86 # This is not necessary, as long as we are not doing type checking. 87 for c in self._wrapped_name.infer(): # Fuck my life Python 2 88 yield c 90 # Everything else shouldn't be relevant for type checking. 91 for c in self._wrapped_name.infer(): # Fuck my life Python 2 92 yield cpython_scripts_modules.rst https://bitbucket.org/andybaoxv/uwhpsc.git | ReStructuredText | 407 lines
1 2.. _python_scripts_modules: 3 4============================================================= 5Python scripts and modules 6============================================================= 7 8A Python script is a collection of commands in a file designed to be 9executed like a program. The file can of course contain functions and 308 309 $ export PYTHONPATH=$PYTHONPATH:/home/uwhpsc/mypython 310 314 315 export PYTHONPATH=$PYTHONPATH:dir1:dir2:dir3 316Configuration_t.py https://github.com/PerilousApricot/WMCore.git | Python | 286 lines
1#!/usr/bin/env python 2#pylint: disable-msg=E1101,C0103,R0902 226 """ 227 Test internal functions pythonise_, listSections_ 228 """ 237 238 pythonise = config.pythonise_() 239 239 240 assert "config.section_('SectionA')" in pythonise, "Pythonise failed: Could not find SectionA" 241 assert "config.SectionA.Section1.x = 100" in pythonise, "Pythonise failed: Could not find x" 242 243 pythonise = config.SectionA.pythonise_() 244 244 245 assert "SectionA.section_('Section1')" in pythonise, "Pythonise failed: Could not find Section1" 246 assert "SectionA.Section1.x = 100" in pythonise, "Pythonise failed: Could not find x"test_pickling.py https://bitbucket.org/ipre/calico.git | Python | 407 lines
34 """ 35 # The below hasattr() check will warn about is_Real in Python 2.5, so 36 # disable this to keep the tests clean 321 322 for c in (PythonIntegerRing, PythonIntegerRing()): 323 check(c) 338 339 for c in (PythonRationalField, PythonRationalField()): 340 check(c) 363from sympy.printing.printer import Printer 364from sympy.printing.python import PythonPrinter 365 368 PrettyPrinter, prettyForm, stringPict, stringPict("a"), 369 Printer, Printer(), PythonPrinter, PythonPrinter()): 370 check(c)SGBase.i https://code.google.com/p/shogun-toolbox/ | Swig | 502 lines
102#endif 103 /* required for python */ 104 #define SWIG_FILE_WITH_INIT 127 128#ifdef SWIGPYTHON 129 163 164#ifdef SWIGPYTHON 165 import_array(); 226 227#ifdef SWIGPYTHON 228%{ 280 } 281#if defined(SWIGPYTHON) && defined(USE_SWIG_DIRECTORS) 282 catch (Swig::DirectorException &e)io.py https://github.com/cboos/ipython.git | Python | 321 lines
6#----------------------------------------------------------------------------- 7# Copyright (C) 2008-2011 The IPython Development Team 8# 62 # This class used to have a writeln method, but regular files and streams 63 # in Python don't have this method. We need to keep this completely 64 # compatible so we removed it. 80 81 # In the future, having IPython channel all its I/O operations through 82 # this class will make it easier to embed it into other environments which 103 # Inspired by: 104 # http://mail.python.org/pipermail/python-list/2007-May/442737.html 105 280def temp_pyfile(src, ext='.py'): 281 """Make a temporary python file, return filename and filehandle. 282wxIPython.py https://github.com/cboos/ipython.git | Python | 266 lines
10from IPython.gui.wx.ipython_view import IPShellWidget 11from IPython.gui.wx.ipython_history import IPythonHistoryPanel 12 16try: 17 from IPython.frontend.wx.ipythonx import IPythonXController 18except ImportError: 52 if(sync_ok): 53 self.ipython_panel2 = IPythonXController(self) 54 else: 145 print >>sys.__stdout__,"Warning: key ",key,"not found in widget options. Check Options.conf" 146 self.ipython_panel.reloadOptions(options_ipython_panel) 147 self.history_panel.reloadOptions(options_history_panel) 236 350, wx.ClientDC(self)) 237 info.WebSite = ("http://ipython.scipy.org/", "IPython home page") 238 info.Developers = [ "Laurent Dufrechou" ]test_uninstall.py https://gitlab.com/mayakarya/pip | Python | 430 lines
27 ) 28 # the import forces the generation of __pycache__ if the version of python 29 # supports it 29 # supports it 30 script.run('python', '-c', "import initools") 31 result2 = script.pip('uninstall', 'INITools', '-y') 48 """)) 49 result = script.run('python', pkg_path / 'setup.py', 'install') 50 result = script.pip('list', '--format=legacy') 81 result = script.run('easy_install', 'INITools==0.2', expect_stderr=True) 82 # the import forces the generation of __pycache__ if the version of python 83 # supports it 83 # supports it 84 script.run('python', '-c', "import initools") 85 result2 = script.pip('uninstall', 'INITools', '-y')