Advertisement
rfmonk

my_notebook.py

Nov 29th, 2012
134
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 17.00 KB | None | 0 0
  1. # Configuration file for ipython.
  2.  
  3. c = get_config()
  4.  
  5. #------------------------------------------------------------------------------
  6. # InteractiveShellApp configuration
  7. #------------------------------------------------------------------------------
  8.  
  9. # A Mixin for applications that start InteractiveShell instances.
  10. #
  11. # Provides configurables for loading extensions and executing files as part of
  12. # configuring a Shell environment.
  13. #
  14. # The following methods should be called by the :meth:`initialize` method of the
  15. # subclass:
  16. #
  17. #   - :meth:`init_path`
  18. #   - :meth:`init_shell` (to be implemented by the subclass)
  19. #   - :meth:`init_gui_pylab`
  20. #   - :meth:`init_extensions`
  21. #   - :meth:`init_code`
  22.  
  23. # Execute the given command string.
  24. # c.InteractiveShellApp.code_to_run = ''
  25.  
  26. # lines of code to run at IPython startup.
  27. # c.InteractiveShellApp.exec_lines = []
  28.  
  29. # Enable GUI event loop integration ('qt', 'wx', 'gtk', 'glut', 'pyglet',
  30. # 'osx').
  31. # c.InteractiveShellApp.gui = None
  32.  
  33. # Pre-load matplotlib and numpy for interactive use, selecting a particular
  34. # matplotlib backend and loop integration.
  35. # c.InteractiveShellApp.pylab = None
  36.  
  37. # If true, an 'import *' is done from numpy and pylab, when using pylab
  38. # c.InteractiveShellApp.pylab_import_all = True
  39.  
  40. # A list of dotted module names of IPython extensions to load.
  41. # c.InteractiveShellApp.extensions = []
  42.  
  43. # Run the module as a script.
  44. # c.InteractiveShellApp.module_to_run = ''
  45.  
  46. # dotted module name of an IPython extension to load.
  47. # c.InteractiveShellApp.extra_extension = ''
  48.  
  49. # List of files to run at IPython startup.
  50. # c.InteractiveShellApp.exec_files = []
  51.  
  52. # A file to be run
  53. # c.InteractiveShellApp.file_to_run = ''
  54.  
  55. #------------------------------------------------------------------------------
  56. # TerminalIPythonApp configuration
  57. #------------------------------------------------------------------------------
  58.  
  59. # TerminalIPythonApp will inherit config from: BaseIPythonApplication,
  60. # Application, InteractiveShellApp
  61.  
  62. # Execute the given command string.
  63. # c.TerminalIPythonApp.code_to_run = ''
  64.  
  65. # The IPython profile to use.
  66. # c.TerminalIPythonApp.profile = u'default'
  67.  
  68. # Set the log level by value or name.
  69. # c.TerminalIPythonApp.log_level = 30
  70.  
  71. # Whether to display a banner upon starting IPython.
  72. c.TerminalIPythonApp.display_banner = False
  73.  
  74. # lines of code to run at IPython startup.
  75. # c.TerminalIPythonApp.exec_lines = []
  76.  
  77. # Enable GUI event loop integration ('qt', 'wx', 'gtk', 'glut', 'pyglet',
  78. # 'osx').
  79. # c.TerminalIPythonApp.gui = None
  80.  
  81. # Pre-load matplotlib and numpy for interactive use, selecting a particular
  82. # matplotlib backend and loop integration.
  83. # c.TerminalIPythonApp.pylab = None
  84.  
  85. # Suppress warning messages about legacy config files
  86. # c.TerminalIPythonApp.ignore_old_config = False
  87.  
  88. # Create a massive crash report when IPython encounters what may be an internal
  89. # error.  The default is to append a short message to the usual traceback
  90. # c.TerminalIPythonApp.verbose_crash = False
  91.  
  92. # If a command or file is given via the command-line, e.g. 'ipython foo.py
  93. # c.TerminalIPythonApp.force_interact = False
  94.  
  95. # If true, an 'import *' is done from numpy and pylab, when using pylab
  96. # c.TerminalIPythonApp.pylab_import_all = True
  97.  
  98. # Whether to install the default config files into the profile dir. If a new
  99. # profile is being created, and IPython contains config files for that profile,
  100. # then they will be staged into the new directory.  Otherwise, default config
  101. # files will be automatically generated.
  102. # c.TerminalIPythonApp.copy_config_files = False
  103.  
  104. # The name of the IPython directory. This directory is used for logging
  105. # configuration (through profiles), history storage, etc. The default is usually
  106. # $HOME/.ipython. This options can also be specified through the environment
  107. # variable IPYTHONDIR.
  108. # c.TerminalIPythonApp.ipython_dir = u'/home/stu/.config/ipython'
  109.  
  110. # Run the module as a script.
  111. # c.TerminalIPythonApp.module_to_run = ''
  112.  
  113. # Start IPython quickly by skipping the loading of config files.
  114. # c.TerminalIPythonApp.quick = False
  115.  
  116. # A list of dotted module names of IPython extensions to load.
  117. # c.TerminalIPythonApp.extensions = []
  118.  
  119. # The Logging format template
  120. # c.TerminalIPythonApp.log_format = '[%(name)s] %(message)s'
  121.  
  122. # dotted module name of an IPython extension to load.
  123. # c.TerminalIPythonApp.extra_extension = ''
  124.  
  125. # List of files to run at IPython startup.
  126. # c.TerminalIPythonApp.exec_files = []
  127.  
  128. # Whether to overwrite existing config files when copying
  129. # c.TerminalIPythonApp.overwrite = False
  130.  
  131. # A file to be run
  132. # c.TerminalIPythonApp.file_to_run = ''
  133.  
  134. #------------------------------------------------------------------------------
  135. # TerminalInteractiveShell configuration
  136. #------------------------------------------------------------------------------
  137.  
  138. # TerminalInteractiveShell will inherit config from: InteractiveShell
  139.  
  140. # auto editing of files with syntax errors.
  141. # c.TerminalInteractiveShell.autoedit_syntax = False
  142.  
  143. # Use colors for displaying information about objects. Because this information
  144. # is passed through a pager (like 'less'), and some pagers get confused with
  145. # color codes, this capability can be turned off.
  146. c.TerminalInteractiveShell.color_info = True
  147.  
  148. #
  149. # c.TerminalInteractiveShell.history_length = 10000
  150.  
  151. # Don't call post-execute functions that have failed in the past.
  152. # c.TerminalInteractiveShell.disable_failing_post_execute = False
  153.  
  154. # Show rewritten input, e.g. for autocall.
  155. # c.TerminalInteractiveShell.show_rewritten_input = True
  156.  
  157. # Set the color scheme (NoColor, Linux, or LightBG).
  158. c.TerminalInteractiveShell.colors = 'LightBG'
  159.  
  160. # Autoindent IPython code entered interactively.
  161. # c.TerminalInteractiveShell.autoindent = True
  162.  
  163. #
  164. # c.TerminalInteractiveShell.separate_in = '\n'
  165.  
  166. # Enable magic commands to be called without the leading %.
  167. # c.TerminalInteractiveShell.automagic = True
  168.  
  169. # Deprecated, use PromptManager.in2_template
  170. # c.TerminalInteractiveShell.prompt_in2 = '   .\\D.: '
  171.  
  172. #
  173. # c.TerminalInteractiveShell.separate_out = ''
  174.  
  175. # Deprecated, use PromptManager.in_template
  176. # c.TerminalInteractiveShell.prompt_in1 = 'In [\\#]: '
  177.  
  178. # Enable deep (recursive) reloading by default. IPython can use the deep_reload
  179. # module which reloads changes in modules recursively (it replaces the reload()
  180. # function, so you don't need to change anything to use it). deep_reload()
  181. # forces a full reload of modules whose code may have changed, which the default
  182. # reload() function does not.  When deep_reload is off, IPython will use the
  183. # normal reload(), but deep_reload will still be available as dreload().
  184. # c.TerminalInteractiveShell.deep_reload = False
  185.  
  186. # Number of lines of your screen, used to control printing of very long strings.
  187. # Strings longer than this number of lines will be sent through a pager instead
  188. # of directly printed.  The default value for this is 0, which means IPython
  189. # will auto-detect your screen size every time it needs to print certain
  190. # potentially long strings (this doesn't change the behavior of the 'print'
  191. # keyword, it's only triggered internally). If for some reason this isn't
  192. # working well (it needs curses support), specify it yourself. Otherwise don't
  193. # change the default.
  194. # c.TerminalInteractiveShell.screen_length = 0
  195.  
  196. # Set the editor used by IPython (default to $EDITOR/vi/notepad).
  197. # c.TerminalInteractiveShell.editor = 'vi'
  198.  
  199. # Deprecated, use PromptManager.justify
  200. # c.TerminalInteractiveShell.prompts_pad_left = True
  201.  
  202. # The part of the banner to be printed before the profile
  203. # c.TerminalInteractiveShell.banner1 = 'Python 2.7.3 (default, Sep 26 2012, 21:53:58) \nType "copyright", "credits" or "license" for more information.\n\nIPython 0.13.1.rc2 -- An enhanced Interactive Python.\n?         -> Introduction and overview of IPython\'s features.\n%quickref -> Quick reference.\nhelp      -> Python\'s own help system.\nobject?   -> Details about \'object\', use \'object??\' for extra details.\n'
  204.  
  205. #
  206. # c.TerminalInteractiveShell.readline_parse_and_bind = ['tab: complete', '"\\C-l": clear-screen', 'set show-all-if-ambiguous on', '"\\C-o": tab-insert', '"\\C-r": reverse-search-history', '"\\C-s": forward-search-history', '"\\C-p": history-search-backward', '"\\C-n": history-search-forward', '"\\e[A": history-search-backward', '"\\e[B": history-search-forward', '"\\C-k": kill-line', '"\\C-u": unix-line-discard']
  207.  
  208. # The part of the banner to be printed after the profile
  209. # c.TerminalInteractiveShell.banner2 = ''
  210.  
  211. #
  212. # c.TerminalInteractiveShell.separate_out2 = ''
  213.  
  214. #
  215. # c.TerminalInteractiveShell.wildcards_case_sensitive = True
  216.  
  217. #
  218. # c.TerminalInteractiveShell.debug = False
  219.  
  220. # Set to confirm when you try to exit IPython with an EOF (Control-D in Unix,
  221. # Control-Z/Enter in Windows). By typing 'exit' or 'quit', you can force a
  222. # direct exit without any confirmation.
  223. # c.TerminalInteractiveShell.confirm_exit = True
  224.  
  225. #
  226. # c.TerminalInteractiveShell.ipython_dir = ''
  227.  
  228. #
  229. # c.TerminalInteractiveShell.readline_remove_delims = '-/~'
  230.  
  231. # Start logging to the default log file.
  232. # c.TerminalInteractiveShell.logstart = False
  233.  
  234. # The name of the logfile to use.
  235. # c.TerminalInteractiveShell.logfile = ''
  236.  
  237. # The shell program to be used for paging.
  238. # c.TerminalInteractiveShell.pager = 'less'
  239.  
  240. # Make IPython automatically call any callable object even if you didn't type
  241. # explicit parentheses. For example, 'str 43' becomes 'str(43)' automatically.
  242. # The value can be '0' to disable the feature, '1' for 'smart' autocall, where
  243. # it is not applied if there are no more arguments on the line, and '2' for
  244. # 'full' autocall, where all callable objects are automatically called (even if
  245. # no arguments are present).
  246. # c.TerminalInteractiveShell.autocall = 0
  247.  
  248. # Save multi-line entries as one entry in readline history
  249. # c.TerminalInteractiveShell.multiline_history = True
  250.  
  251. #
  252. # c.TerminalInteractiveShell.readline_use = True
  253.  
  254. # Start logging to the given file in append mode.
  255. # c.TerminalInteractiveShell.logappend = ''
  256.  
  257. #
  258. # c.TerminalInteractiveShell.xmode = 'Context'
  259.  
  260. #
  261. # c.TerminalInteractiveShell.quiet = False
  262.  
  263. # Enable auto setting the terminal title.
  264. # c.TerminalInteractiveShell.term_title = False
  265.  
  266. #
  267. # c.TerminalInteractiveShell.object_info_string_level = 0
  268.  
  269. # Deprecated, use PromptManager.out_template
  270. # c.TerminalInteractiveShell.prompt_out = 'Out[\\#]: '
  271.  
  272. # Set the size of the output cache.  The default is 1000, you can change it
  273. # permanently in your config file.  Setting it to 0 completely disables the
  274. # caching system, and the minimum value accepted is 20 (if you provide a value
  275. # less than 20, it is reset to 0 and a warning is issued).  This limit is
  276. # defined because otherwise you'll spend more time re-flushing a too small cache
  277. # than working
  278. # c.TerminalInteractiveShell.cache_size = 1000
  279.  
  280. # 'all', 'last', 'last_expr' or 'none', specifying which nodes should be run
  281. # interactively (displaying output from expressions).
  282. # c.TerminalInteractiveShell.ast_node_interactivity = 'last_expr'
  283.  
  284. # Automatically call the pdb debugger after every exception.
  285. # c.TerminalInteractiveShell.pdb = False
  286.  
  287. #------------------------------------------------------------------------------
  288. # PromptManager configuration
  289. #------------------------------------------------------------------------------
  290.  
  291. # This is the primary interface for producing IPython's prompts.
  292.  
  293. # Output prompt. '\#' will be transformed to the prompt number
  294. # c.PromptManager.out_template = 'Out[\\#]: '
  295.  
  296. # Continuation prompt.
  297. # c.PromptManager.in2_template = '   .\\D.: '
  298.  
  299. # If True (default), each prompt will be right-aligned with the preceding one.
  300. # c.PromptManager.justify = True
  301.  
  302. # Input prompt.  '\#' will be transformed to the prompt number
  303. # c.PromptManager.in_template = 'In [\\#]: '
  304.  
  305. #
  306. # c.PromptManager.color_scheme = 'Linux'
  307.  
  308. #------------------------------------------------------------------------------
  309. # HistoryManager configuration
  310. #------------------------------------------------------------------------------
  311.  
  312. # A class to organize all history-related functionality in one place.
  313.  
  314. # HistoryManager will inherit config from: HistoryAccessor
  315.  
  316. #
  317. # c.HistoryManager.db_log_output = False
  318.  
  319. # Path to file to use for SQLite history database.
  320. #
  321. # By default, IPython will put the history database in the IPython profile
  322. # directory.  If you would rather share one history among profiles, you can set
  323. # this value in each, so that they are consistent.
  324. #
  325. # Due to an issue with fcntl, SQLite is known to misbehave on some NFS mounts.
  326. # If you see IPython hanging, try setting this to something on a local disk,
  327. # e.g::
  328. #
  329. #     ipython --HistoryManager.hist_file=/tmp/ipython_hist.sqlite
  330. # c.HistoryManager.hist_file = u''
  331.  
  332. #
  333. # c.HistoryManager.db_cache_size = 0
  334.  
  335. #------------------------------------------------------------------------------
  336. # ProfileDir configuration
  337. #------------------------------------------------------------------------------
  338.  
  339. # An object to manage the profile directory and its resources.
  340. #
  341. # The profile directory is used by all IPython applications, to manage
  342. # configuration, logging and security.
  343. #
  344. # This object knows how to find, create and manage these directories. This
  345. # should be used by any code that wants to handle profiles.
  346.  
  347. # Set the profile location directly. This overrides the logic used by the
  348. # `profile` option.
  349. # c.ProfileDir.location = u''
  350.  
  351. #------------------------------------------------------------------------------
  352. # PlainTextFormatter configuration
  353. #------------------------------------------------------------------------------
  354.  
  355. # The default pretty-printer.
  356. #
  357. # This uses :mod:`IPython.lib.pretty` to compute the format data of the object.
  358. # If the object cannot be pretty printed, :func:`repr` is used. See the
  359. # documentation of :mod:`IPython.lib.pretty` for details on how to write pretty
  360. # printers.  Here is a simple example::
  361. #
  362. #     def dtype_pprinter(obj, p, cycle):
  363. #         if cycle:
  364. #             return p.text('dtype(...)')
  365. #         if hasattr(obj, 'fields'):
  366. #             if obj.fields is None:
  367. #                 p.text(repr(obj))
  368. #             else:
  369. #                 p.begin_group(7, 'dtype([')
  370. #                 for i, field in enumerate(obj.descr):
  371. #                     if i > 0:
  372. #                         p.text(',')
  373. #                         p.breakable()
  374. #                     p.pretty(field)
  375. #                 p.end_group(7, '])')
  376.  
  377. # PlainTextFormatter will inherit config from: BaseFormatter
  378.  
  379. #
  380. # c.PlainTextFormatter.type_printers = {}
  381.  
  382. #
  383. # c.PlainTextFormatter.newline = '\n'
  384.  
  385. #
  386. # c.PlainTextFormatter.float_precision = ''
  387.  
  388. #
  389. # c.PlainTextFormatter.verbose = False
  390.  
  391. #
  392. # c.PlainTextFormatter.deferred_printers = {}
  393.  
  394. #
  395. # c.PlainTextFormatter.pprint = True
  396.  
  397. #
  398. # c.PlainTextFormatter.max_width = 79
  399.  
  400. #
  401. # c.PlainTextFormatter.singleton_printers = {}
  402.  
  403. #------------------------------------------------------------------------------
  404. # IPCompleter configuration
  405. #------------------------------------------------------------------------------
  406.  
  407. # Extension of the completer class with IPython-specific features
  408.  
  409. # IPCompleter will inherit config from: Completer
  410.  
  411. # Instruct the completer to omit private method names
  412. #
  413. # Specifically, when completing on ``object.<tab>``.
  414. #
  415. # When 2 [default]: all names that start with '_' will be excluded.
  416. #
  417. # When 1: all 'magic' names (``__foo__``) will be excluded.
  418. #
  419. # When 0: nothing will be excluded.
  420. # c.IPCompleter.omit__names = 2
  421.  
  422. # Whether to merge completion results into a single list
  423. #
  424. # If False, only the completion results from the first non-empty completer will
  425. # be returned.
  426. # c.IPCompleter.merge_completions = True
  427.  
  428. # Instruct the completer to use __all__ for the completion
  429. #
  430. # Specifically, when completing on ``object.<tab>``.
  431. #
  432. # When True: only those names in obj.__all__ will be included.
  433. #
  434. # When False [default]: the __all__ attribute is ignored
  435. # c.IPCompleter.limit_to__all__ = False
  436.  
  437. # Activate greedy completion
  438. #
  439. # This will enable completion on elements of lists, results of function calls,
  440. # etc., but can be unsafe because the code is actually evaluated on TAB.
  441. # c.IPCompleter.greedy = False
  442.  
  443. #------------------------------------------------------------------------------
  444. # ScriptMagics configuration
  445. #------------------------------------------------------------------------------
  446.  
  447. # Magics for talking to scripts
  448. #
  449. # This defines a base `%%script` cell magic for running a cell with a program in
  450. # a subprocess, and registers a few top-level magics that call %%script with
  451. # common interpreters.
  452.  
  453. # Extra script cell magics to define
  454. #
  455. # This generates simple wrappers of `%%script foo` as `%%foo`.
  456. #
  457. # If you want to add script magics that aren't on your path, specify them in
  458. # script_paths
  459. # c.ScriptMagics.script_magics = []
  460.  
  461. # Dict mapping short 'ruby' names to full paths, such as '/opt/secret/bin/ruby'
  462. #
  463. # Only necessary for items in script_magics where the default path will not find
  464. # the right interpreter.
  465. # c.ScriptMagics.script_paths = {}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement