| 12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700 |
- <!doctype html>
- <html lang="en" class="no-js">
- <head>
-
- <meta charset="utf-8">
- <meta name="viewport" content="width=device-width,initial-scale=1">
-
-
-
- <link rel="shortcut icon" href="../../assets/images/favicon.png">
- <meta name="generator" content="mkdocs-1.1.2, mkdocs-material-5.5.3">
-
-
-
- <title>Gallery - Jypyter Sketcher</title>
-
-
-
- <link rel="stylesheet" href="../../assets/stylesheets/main.947af8d5.min.css">
-
-
-
-
-
-
- <link href="https://fonts.gstatic.com" rel="preconnect" crossorigin>
- <link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Roboto:300,400,400i,700%7CRoboto+Mono&display=fallback">
- <style>body,input{font-family:"Roboto",-apple-system,BlinkMacSystemFont,Helvetica,Arial,sans-serif}code,kbd,pre{font-family:"Roboto Mono",SFMono-Regular,Consolas,Menlo,monospace}</style>
-
-
-
-
-
-
-
-
- </head>
-
-
- <body dir="ltr">
-
-
- <input class="md-toggle" data-md-toggle="drawer" type="checkbox" id="__drawer" autocomplete="off">
- <input class="md-toggle" data-md-toggle="search" type="checkbox" id="__search" autocomplete="off">
- <label class="md-overlay" for="__drawer"></label>
- <div data-md-component="skip">
-
-
- <a href="#gallery" class="md-skip">
- Skip to content
- </a>
-
- </div>
- <div data-md-component="announce">
-
- </div>
-
- <header class="md-header" data-md-component="header">
- <nav class="md-header-nav md-grid" aria-label="Header">
- <a href="../.." title="Jypyter Sketcher" class="md-header-nav__button md-logo" aria-label="Jypyter Sketcher">
-
-
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12 8a3 3 0 003-3 3 3 0 00-3-3 3 3 0 00-3 3 3 3 0 003 3m0 3.54C9.64 9.35 6.5 8 3 8v11c3.5 0 6.64 1.35 9 3.54 2.36-2.19 5.5-3.54 9-3.54V8c-3.5 0-6.64 1.35-9 3.54z"/></svg>
- </a>
- <label class="md-header-nav__button md-icon" for="__drawer">
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M3 6h18v2H3V6m0 5h18v2H3v-2m0 5h18v2H3v-2z"/></svg>
- </label>
- <div class="md-header-nav__title" data-md-component="header-title">
-
- <div class="md-header-nav__ellipsis">
- <span class="md-header-nav__topic md-ellipsis">
- Jypyter Sketcher
- </span>
- <span class="md-header-nav__topic md-ellipsis">
-
- Gallery
-
- </span>
- </div>
-
- </div>
-
- <label class="md-header-nav__button md-icon" for="__search">
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M9.5 3A6.5 6.5 0 0116 9.5c0 1.61-.59 3.09-1.56 4.23l.27.27h.79l5 5-1.5 1.5-5-5v-.79l-.27-.27A6.516 6.516 0 019.5 16 6.5 6.5 0 013 9.5 6.5 6.5 0 019.5 3m0 2C7 5 5 7 5 9.5S7 14 9.5 14 14 12 14 9.5 12 5 9.5 5z"/></svg>
- </label>
-
- <div class="md-search" data-md-component="search" role="dialog">
- <label class="md-search__overlay" for="__search"></label>
- <div class="md-search__inner" role="search">
- <form class="md-search__form" name="search">
- <input type="text" class="md-search__input" name="query" aria-label="Search" placeholder="Search" autocapitalize="off" autocorrect="off" autocomplete="off" spellcheck="false" data-md-component="search-query" data-md-state="active">
- <label class="md-search__icon md-icon" for="__search">
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M9.5 3A6.5 6.5 0 0116 9.5c0 1.61-.59 3.09-1.56 4.23l.27.27h.79l5 5-1.5 1.5-5-5v-.79l-.27-.27A6.516 6.516 0 019.5 16 6.5 6.5 0 013 9.5 6.5 6.5 0 019.5 3m0 2C7 5 5 7 5 9.5S7 14 9.5 14 14 12 14 9.5 12 5 9.5 5z"/></svg>
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M20 11v2H8l5.5 5.5-1.42 1.42L4.16 12l7.92-7.92L13.5 5.5 8 11h12z"/></svg>
- </label>
- <button type="reset" class="md-search__icon md-icon" aria-label="Clear" data-md-component="search-reset" tabindex="-1">
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12 19 6.41z"/></svg>
- </button>
- </form>
- <div class="md-search__output">
- <div class="md-search__scrollwrap" data-md-scrollfix>
- <div class="md-search-result" data-md-component="search-result">
- <div class="md-search-result__meta">
- Initializing search
- </div>
- <ol class="md-search-result__list"></ol>
- </div>
- </div>
- </div>
- </div>
- </div>
-
-
- </nav>
- </header>
-
- <div class="md-container" data-md-component="container">
-
-
-
-
-
-
- <main class="md-main" data-md-component="main">
- <div class="md-main__inner md-grid">
-
-
- <div class="md-sidebar md-sidebar--primary" data-md-component="navigation">
- <div class="md-sidebar__scrollwrap">
- <div class="md-sidebar__inner">
- <nav class="md-nav md-nav--primary" aria-label="Navigation" data-md-level="0">
- <label class="md-nav__title" for="__drawer">
- <a href="../.." title="Jypyter Sketcher" class="md-nav__button md-logo" aria-label="Jypyter Sketcher">
-
-
- <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12 8a3 3 0 003-3 3 3 0 00-3-3 3 3 0 00-3 3 3 3 0 003 3m0 3.54C9.64 9.35 6.5 8 3 8v11c3.5 0 6.64 1.35 9 3.54 2.36-2.19 5.5-3.54 9-3.54V8c-3.5 0-6.64 1.35-9 3.54z"/></svg>
- </a>
- Jypyter Sketcher
- </label>
-
- <ul class="md-nav__list" data-md-scrollfix>
-
-
-
-
- <li class="md-nav__item">
- <a href="../.." title="Home" class="md-nav__link">
- Home
- </a>
- </li>
-
-
-
-
- <li class="md-nav__item">
- <a href="../../about/" title="About" class="md-nav__link">
- About
- </a>
- </li>
-
-
-
-
- <li class="md-nav__item">
- <a href="../../presentation/" title="Presentation" class="md-nav__link">
- Presentation
- </a>
- </li>
-
-
-
-
- <li class="md-nav__item">
- <a href="../../learningbyexample/" title="Learning by Example" class="md-nav__link">
- Learning by Example
- </a>
- </li>
-
-
-
-
- <li class="md-nav__item">
- <a href="../../shapereference/" title="Shapes Reference" class="md-nav__link">
- Shapes Reference
- </a>
- </li>
-
-
-
-
- <li class="md-nav__item">
- <a href="../../yamlsketcher/" title="YAML files Reference" class="md-nav__link">
- YAML files Reference
- </a>
- </li>
-
-
-
-
- <li class="md-nav__item">
- <a href="../../gallerydoc/" title="Gallery" class="md-nav__link">
- Gallery
- </a>
- </li>
-
- </ul>
- </nav>
- </div>
- </div>
- </div>
-
-
- <div class="md-sidebar md-sidebar--secondary" data-md-component="toc">
- <div class="md-sidebar__scrollwrap">
- <div class="md-sidebar__inner">
-
- <nav class="md-nav md-nav--secondary" aria-label="Table of contents">
-
-
-
-
-
- </nav>
- </div>
- </div>
- </div>
-
-
- <div class="md-content">
- <article class="md-content__inner md-typeset">
-
-
-
-
-
-
-
- <div class="notebook-content">
- <style type="text/css">/*!
- *
- * IPython notebook
- *
- */
- /* CSS font colors for translated ANSI escape sequences */
- /* The color values are a mix of
- http://www.xcolors.net/dl/baskerville-ivorylight and
- http://www.xcolors.net/dl/euphrasia */
- .ansi-black-fg {
- color: #3E424D;
- }
- .ansi-black-bg {
- background-color: #3E424D;
- }
- .ansi-black-intense-fg {
- color: #282C36;
- }
- .ansi-black-intense-bg {
- background-color: #282C36;
- }
- .ansi-red-fg {
- color: #E75C58;
- }
- .ansi-red-bg {
- background-color: #E75C58;
- }
- .ansi-red-intense-fg {
- color: #B22B31;
- }
- .ansi-red-intense-bg {
- background-color: #B22B31;
- }
- .ansi-green-fg {
- color: #00A250;
- }
- .ansi-green-bg {
- background-color: #00A250;
- }
- .ansi-green-intense-fg {
- color: #007427;
- }
- .ansi-green-intense-bg {
- background-color: #007427;
- }
- .ansi-yellow-fg {
- color: #DDB62B;
- }
- .ansi-yellow-bg {
- background-color: #DDB62B;
- }
- .ansi-yellow-intense-fg {
- color: #B27D12;
- }
- .ansi-yellow-intense-bg {
- background-color: #B27D12;
- }
- .ansi-blue-fg {
- color: #208FFB;
- }
- .ansi-blue-bg {
- background-color: #208FFB;
- }
- .ansi-blue-intense-fg {
- color: #0065CA;
- }
- .ansi-blue-intense-bg {
- background-color: #0065CA;
- }
- .ansi-magenta-fg {
- color: #D160C4;
- }
- .ansi-magenta-bg {
- background-color: #D160C4;
- }
- .ansi-magenta-intense-fg {
- color: #A03196;
- }
- .ansi-magenta-intense-bg {
- background-color: #A03196;
- }
- .ansi-cyan-fg {
- color: #60C6C8;
- }
- .ansi-cyan-bg {
- background-color: #60C6C8;
- }
- .ansi-cyan-intense-fg {
- color: #258F8F;
- }
- .ansi-cyan-intense-bg {
- background-color: #258F8F;
- }
- .ansi-white-fg {
- color: #C5C1B4;
- }
- .ansi-white-bg {
- background-color: #C5C1B4;
- }
- .ansi-white-intense-fg {
- color: #A1A6B2;
- }
- .ansi-white-intense-bg {
- background-color: #A1A6B2;
- }
- .ansi-default-inverse-fg {
- color: #FFFFFF;
- }
- .ansi-default-inverse-bg {
- background-color: #000000;
- }
- .ansi-bold {
- font-weight: bold;
- }
- .ansi-underline {
- text-decoration: underline;
- }
- /* The following styles are deprecated an will be removed in a future version */
- .ansibold {
- font-weight: bold;
- }
- .ansi-inverse {
- outline: 0.5px dotted;
- }
- /* use dark versions for foreground, to improve visibility */
- .ansiblack {
- color: black;
- }
- .ansired {
- color: darkred;
- }
- .ansigreen {
- color: darkgreen;
- }
- .ansiyellow {
- color: #c4a000;
- }
- .ansiblue {
- color: darkblue;
- }
- .ansipurple {
- color: darkviolet;
- }
- .ansicyan {
- color: steelblue;
- }
- .ansigray {
- color: gray;
- }
- /* and light for background, for the same reason */
- .ansibgblack {
- background-color: black;
- }
- .ansibgred {
- background-color: red;
- }
- .ansibggreen {
- background-color: green;
- }
- .ansibgyellow {
- background-color: yellow;
- }
- .ansibgblue {
- background-color: blue;
- }
- .ansibgpurple {
- background-color: magenta;
- }
- .ansibgcyan {
- background-color: cyan;
- }
- .ansibggray {
- background-color: gray;
- }
- div.cell {
- /* Old browsers */
- display: -webkit-box;
- -webkit-box-orient: vertical;
- -webkit-box-align: stretch;
- display: -moz-box;
- -moz-box-orient: vertical;
- -moz-box-align: stretch;
- display: box;
- box-orient: vertical;
- box-align: stretch;
- /* Modern browsers */
- display: flex;
- flex-direction: column;
- align-items: stretch;
- border-radius: 2px;
- box-sizing: border-box;
- -moz-box-sizing: border-box;
- -webkit-box-sizing: border-box;
- border-width: 1px;
- border-style: solid;
- border-color: transparent;
- width: 100%;
- padding: 5px;
- /* This acts as a spacer between cells, that is outside the border */
- margin: 0px;
- outline: none;
- position: relative;
- overflow: visible;
- }
- div.cell:before {
- position: absolute;
- display: block;
- top: -1px;
- left: -1px;
- width: 5px;
- height: calc(100% + 2px);
- content: '';
- background: transparent;
- }
- div.cell.jupyter-soft-selected {
- border-left-color: #E3F2FD;
- border-left-width: 1px;
- padding-left: 5px;
- border-right-color: #E3F2FD;
- border-right-width: 1px;
- background: #E3F2FD;
- }
- @media print {
- div.cell.jupyter-soft-selected {
- border-color: transparent;
- }
- }
- div.cell.selected,
- div.cell.selected.jupyter-soft-selected {
- border-color: #ababab;
- }
- div.cell.selected:before,
- div.cell.selected.jupyter-soft-selected:before {
- position: absolute;
- display: block;
- top: -1px;
- left: -1px;
- width: 5px;
- height: calc(100% + 2px);
- content: '';
- background: #42A5F5;
- }
- @media print {
- div.cell.selected,
- div.cell.selected.jupyter-soft-selected {
- border-color: transparent;
- }
- }
- .edit_mode div.cell.selected {
- border-color: #66BB6A;
- }
- .edit_mode div.cell.selected:before {
- position: absolute;
- display: block;
- top: -1px;
- left: -1px;
- width: 5px;
- height: calc(100% + 2px);
- content: '';
- background: #66BB6A;
- }
- @media print {
- .edit_mode div.cell.selected {
- border-color: transparent;
- }
- }
- .prompt {
- /* This needs to be wide enough for 3 digit prompt numbers: In[100]: */
- min-width: 14ex;
- /* This padding is tuned to match the padding on the CodeMirror editor. */
- padding: 0.4em;
- margin: 0px;
- font-family: monospace;
- text-align: right;
- /* This has to match that of the the CodeMirror class line-height below */
- line-height: 1.21429em;
- /* Don't highlight prompt number selection */
- -webkit-touch-callout: none;
- -webkit-user-select: none;
- -khtml-user-select: none;
- -moz-user-select: none;
- -ms-user-select: none;
- user-select: none;
- /* Use default cursor */
- cursor: default;
- }
- @media (max-width: 540px) {
- .prompt {
- text-align: left;
- }
- }
- div.inner_cell {
- min-width: 0;
- /* Old browsers */
- display: -webkit-box;
- -webkit-box-orient: vertical;
- -webkit-box-align: stretch;
- display: -moz-box;
- -moz-box-orient: vertical;
- -moz-box-align: stretch;
- display: box;
- box-orient: vertical;
- box-align: stretch;
- /* Modern browsers */
- display: flex;
- flex-direction: column;
- align-items: stretch;
- /* Old browsers */
- -webkit-box-flex: 1;
- -moz-box-flex: 1;
- box-flex: 1;
- /* Modern browsers */
- flex: 1;
- }
- /* input_area and input_prompt must match in top border and margin for alignment */
- div.input_area {
- border: 1px solid #cfcfcf;
- border-radius: 2px;
- background: #f7f7f7;
- line-height: 1.21429em;
- }
- /* This is needed so that empty prompt areas can collapse to zero height when there
- is no content in the output_subarea and the prompt. The main purpose of this is
- to make sure that empty JavaScript output_subareas have no height. */
- div.prompt:empty {
- padding-top: 0;
- padding-bottom: 0;
- }
- div.unrecognized_cell {
- padding: 5px 5px 5px 0px;
- /* Old browsers */
- display: -webkit-box;
- -webkit-box-orient: horizontal;
- -webkit-box-align: stretch;
- display: -moz-box;
- -moz-box-orient: horizontal;
- -moz-box-align: stretch;
- display: box;
- box-orient: horizontal;
- box-align: stretch;
- /* Modern browsers */
- display: flex;
- flex-direction: row;
- align-items: stretch;
- }
- div.unrecognized_cell .inner_cell {
- border-radius: 2px;
- padding: 5px;
- font-weight: bold;
- color: red;
- border: 1px solid #cfcfcf;
- background: #eaeaea;
- }
- div.unrecognized_cell .inner_cell a {
- color: inherit;
- text-decoration: none;
- }
- div.unrecognized_cell .inner_cell a:hover {
- color: inherit;
- text-decoration: none;
- }
- @media (max-width: 540px) {
- div.unrecognized_cell > div.prompt {
- display: none;
- }
- }
- div.code_cell {
- /* avoid page breaking on code cells when printing */
- }
- @media print {
- div.code_cell {
- page-break-inside: avoid;
- }
- }
- /* any special styling for code cells that are currently running goes here */
- div.input {
- page-break-inside: avoid;
- /* Old browsers */
- display: -webkit-box;
- -webkit-box-orient: horizontal;
- -webkit-box-align: stretch;
- display: -moz-box;
- -moz-box-orient: horizontal;
- -moz-box-align: stretch;
- display: box;
- box-orient: horizontal;
- box-align: stretch;
- /* Modern browsers */
- display: flex;
- flex-direction: row;
- align-items: stretch;
- }
- @media (max-width: 540px) {
- div.input {
- /* Old browsers */
- display: -webkit-box;
- -webkit-box-orient: vertical;
- -webkit-box-align: stretch;
- display: -moz-box;
- -moz-box-orient: vertical;
- -moz-box-align: stretch;
- display: box;
- box-orient: vertical;
- box-align: stretch;
- /* Modern browsers */
- display: flex;
- flex-direction: column;
- align-items: stretch;
- }
- }
- /* input_area and input_prompt must match in top border and margin for alignment */
- div.input_prompt {
- color: #303F9F;
- border-top: 1px solid transparent;
- }
- div.input_area > div.highlight {
- margin: 0.4em;
- border: none;
- padding: 0px;
- background-color: transparent;
- }
- div.input_area > div.highlight > pre {
- margin: 0px;
- border: none;
- padding: 0px;
- background-color: transparent;
- }
- /* The following gets added to the <head> if it is detected that the user has a
- * monospace font with inconsistent normal/bold/italic height. See
- * notebookmain.js. Such fonts will have keywords vertically offset with
- * respect to the rest of the text. The user should select a better font.
- * See: https://github.com/ipython/ipython/issues/1503
- *
- * .CodeMirror span {
- * vertical-align: bottom;
- * }
- */
- .CodeMirror {
- line-height: 1.21429em;
- /* Changed from 1em to our global default */
- font-size: 14px;
- height: auto;
- /* Changed to auto to autogrow */
- background: none;
- /* Changed from white to allow our bg to show through */
- }
- .CodeMirror-scroll {
- /* The CodeMirror docs are a bit fuzzy on if overflow-y should be hidden or visible.*/
- /* We have found that if it is visible, vertical scrollbars appear with font size changes.*/
- overflow-y: hidden;
- overflow-x: auto;
- }
- .CodeMirror-lines {
- /* In CM2, this used to be 0.4em, but in CM3 it went to 4px. We need the em value because */
- /* we have set a different line-height and want this to scale with that. */
- /* Note that this should set vertical padding only, since CodeMirror assumes
- that horizontal padding will be set on CodeMirror pre */
- padding: 0.4em 0;
- }
- .CodeMirror-linenumber {
- padding: 0 8px 0 4px;
- }
- .CodeMirror-gutters {
- border-bottom-left-radius: 2px;
- border-top-left-radius: 2px;
- }
- .CodeMirror pre {
- /* In CM3 this went to 4px from 0 in CM2. This sets horizontal padding only,
- use .CodeMirror-lines for vertical */
- padding: 0 0.4em;
- border: 0;
- border-radius: 0;
- }
- .CodeMirror-cursor {
- border-left: 1.4px solid black;
- }
- @media screen and (min-width: 2138px) and (max-width: 4319px) {
- .CodeMirror-cursor {
- border-left: 2px solid black;
- }
- }
- @media screen and (min-width: 4320px) {
- .CodeMirror-cursor {
- border-left: 4px solid black;
- }
- }
- /*
- Original style from softwaremaniacs.org (c) Ivan Sagalaev <Maniac@SoftwareManiacs.Org>
- Adapted from GitHub theme
- */
- .highlight-base {
- color: #000;
- }
- .highlight-variable {
- color: #000;
- }
- .highlight-variable-2 {
- color: #1a1a1a;
- }
- .highlight-variable-3 {
- color: #333333;
- }
- .highlight-string {
- color: #BA2121;
- }
- .highlight-comment {
- color: #408080;
- font-style: italic;
- }
- .highlight-number {
- color: #080;
- }
- .highlight-atom {
- color: #88F;
- }
- .highlight-keyword {
- color: #008000;
- font-weight: bold;
- }
- .highlight-builtin {
- color: #008000;
- }
- .highlight-error {
- color: #f00;
- }
- .highlight-operator {
- color: #AA22FF;
- font-weight: bold;
- }
- .highlight-meta {
- color: #AA22FF;
- }
- /* previously not defined, copying from default codemirror */
- .highlight-def {
- color: #00f;
- }
- .highlight-string-2 {
- color: #f50;
- }
- .highlight-qualifier {
- color: #555;
- }
- .highlight-bracket {
- color: #997;
- }
- .highlight-tag {
- color: #170;
- }
- .highlight-attribute {
- color: #00c;
- }
- .highlight-header {
- color: blue;
- }
- .highlight-quote {
- color: #090;
- }
- .highlight-link {
- color: #00c;
- }
- /* apply the same style to codemirror */
- .cm-s-ipython span.cm-keyword {
- color: #008000;
- font-weight: bold;
- }
- .cm-s-ipython span.cm-atom {
- color: #88F;
- }
- .cm-s-ipython span.cm-number {
- color: #080;
- }
- .cm-s-ipython span.cm-def {
- color: #00f;
- }
- .cm-s-ipython span.cm-variable {
- color: #000;
- }
- .cm-s-ipython span.cm-operator {
- color: #AA22FF;
- font-weight: bold;
- }
- .cm-s-ipython span.cm-variable-2 {
- color: #1a1a1a;
- }
- .cm-s-ipython span.cm-variable-3 {
- color: #333333;
- }
- .cm-s-ipython span.cm-comment {
- color: #408080;
- font-style: italic;
- }
- .cm-s-ipython span.cm-string {
- color: #BA2121;
- }
- .cm-s-ipython span.cm-string-2 {
- color: #f50;
- }
- .cm-s-ipython span.cm-meta {
- color: #AA22FF;
- }
- .cm-s-ipython span.cm-qualifier {
- color: #555;
- }
- .cm-s-ipython span.cm-builtin {
- color: #008000;
- }
- .cm-s-ipython span.cm-bracket {
- color: #997;
- }
- .cm-s-ipython span.cm-tag {
- color: #170;
- }
- .cm-s-ipython span.cm-attribute {
- color: #00c;
- }
- .cm-s-ipython span.cm-header {
- color: blue;
- }
- .cm-s-ipython span.cm-quote {
- color: #090;
- }
- .cm-s-ipython span.cm-link {
- color: #00c;
- }
- .cm-s-ipython span.cm-error {
- color: #f00;
- }
- .cm-s-ipython span.cm-tab {
- background: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAMCAYAAAAkuj5RAAAAAXNSR0IArs4c6QAAAGFJREFUSMft1LsRQFAQheHPowAKoACx3IgEKtaEHujDjORSgWTH/ZOdnZOcM/sgk/kFFWY0qV8foQwS4MKBCS3qR6ixBJvElOobYAtivseIE120FaowJPN75GMu8j/LfMwNjh4HUpwg4LUAAAAASUVORK5CYII=);
- background-position: right;
- background-repeat: no-repeat;
- }
- div.output_wrapper {
- /* this position must be relative to enable descendents to be absolute within it */
- position: relative;
- /* Old browsers */
- display: -webkit-box;
- -webkit-box-orient: vertical;
- -webkit-box-align: stretch;
- display: -moz-box;
- -moz-box-orient: vertical;
- -moz-box-align: stretch;
- display: box;
- box-orient: vertical;
- box-align: stretch;
- /* Modern browsers */
- display: flex;
- flex-direction: column;
- align-items: stretch;
- z-index: 1;
- }
- /* class for the output area when it should be height-limited */
- div.output_scroll {
- /* ideally, this would be max-height, but FF barfs all over that */
- height: 24em;
- /* FF needs this *and the wrapper* to specify full width, or it will shrinkwrap */
- width: 100%;
- overflow: auto;
- border-radius: 2px;
- -webkit-box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.8);
- box-shadow: inset 0 2px 8px rgba(0, 0, 0, 0.8);
- display: block;
- }
- /* output div while it is collapsed */
- div.output_collapsed {
- margin: 0px;
- padding: 0px;
- /* Old browsers */
- display: -webkit-box;
- -webkit-box-orient: vertical;
- -webkit-box-align: stretch;
- display: -moz-box;
- -moz-box-orient: vertical;
- -moz-box-align: stretch;
- display: box;
- box-orient: vertical;
- box-align: stretch;
- /* Modern browsers */
- display: flex;
- flex-direction: column;
- align-items: stretch;
- }
- div.out_prompt_overlay {
- height: 100%;
- padding: 0px 0.4em;
- position: absolute;
- border-radius: 2px;
- }
- div.out_prompt_overlay:hover {
- /* use inner shadow to get border that is computed the same on WebKit/FF */
- -webkit-box-shadow: inset 0 0 1px #000;
- box-shadow: inset 0 0 1px #000;
- background: rgba(240, 240, 240, 0.5);
- }
- div.output_prompt {
- color: #D84315;
- }
- /* This class is the outer container of all output sections. */
- div.output_area {
- padding: 0px;
- page-break-inside: avoid;
- /* Old browsers */
- display: -webkit-box;
- -webkit-box-orient: horizontal;
- -webkit-box-align: stretch;
- display: -moz-box;
- -moz-box-orient: horizontal;
- -moz-box-align: stretch;
- display: box;
- box-orient: horizontal;
- box-align: stretch;
- /* Modern browsers */
- display: flex;
- flex-direction: row;
- align-items: stretch;
- }
- div.output_area .MathJax_Display {
- text-align: left !important;
- }
- div.output_area
- div.output_area
- div.output_area img,
- div.output_area svg {
- max-width: 100%;
- height: auto;
- }
- div.output_area img.unconfined,
- div.output_area svg.unconfined {
- max-width: none;
- }
- div.output_area .mglyph > img {
- max-width: none;
- }
- /* This is needed to protect the pre formating from global settings such
- as that of bootstrap */
- .output {
- /* Old browsers */
- display: -webkit-box;
- -webkit-box-orient: vertical;
- -webkit-box-align: stretch;
- display: -moz-box;
- -moz-box-orient: vertical;
- -moz-box-align: stretch;
- display: box;
- box-orient: vertical;
- box-align: stretch;
- /* Modern browsers */
- display: flex;
- flex-direction: column;
- align-items: stretch;
- }
- @media (max-width: 540px) {
- div.output_area {
- /* Old browsers */
- display: -webkit-box;
- -webkit-box-orient: vertical;
- -webkit-box-align: stretch;
- display: -moz-box;
- -moz-box-orient: vertical;
- -moz-box-align: stretch;
- display: box;
- box-orient: vertical;
- box-align: stretch;
- /* Modern browsers */
- display: flex;
- flex-direction: column;
- align-items: stretch;
- }
- }
- div.output_area pre {
- margin: 0;
- padding: 1px 0 1px 0;
- border: 0;
- vertical-align: baseline;
- color: black;
- background-color: transparent;
- border-radius: 0;
- }
- /* This class is for the output subarea inside the output_area and after
- the prompt div. */
- div.output_subarea {
- overflow-x: auto;
- padding: 0.4em;
- /* Old browsers */
- -webkit-box-flex: 1;
- -moz-box-flex: 1;
- box-flex: 1;
- /* Modern browsers */
- flex: 1;
- max-width: calc(100% - 14ex);
- }
- div.output_scroll div.output_subarea {
- overflow-x: visible;
- }
- /* The rest of the output_* classes are for special styling of the different
- output types */
- /* all text output has this class: */
- div.output_text {
- text-align: left;
- color: #000;
- /* This has to match that of the the CodeMirror class line-height below */
- line-height: 1.21429em;
- }
- /* stdout/stderr are 'text' as well as 'stream', but execute_result/error are *not* streams */
- div.output_stderr {
- background: #fdd;
- /* very light red background for stderr */
- }
- div.output_latex {
- text-align: left;
- }
- /* Empty output_javascript divs should have no height */
- div.output_javascript:empty {
- padding: 0;
- }
- .js-error {
- color: darkred;
- }
- /* raw_input styles */
- div.raw_input_container {
- line-height: 1.21429em;
- padding-top: 5px;
- }
- pre.raw_input_prompt {
- /* nothing needed here. */
- }
- input.raw_input {
- font-family: monospace;
- font-size: inherit;
- color: inherit;
- width: auto;
- /* make sure input baseline aligns with prompt */
- vertical-align: baseline;
- /* padding + margin = 0.5em between prompt and cursor */
- padding: 0em 0.25em;
- margin: 0em 0.25em;
- }
- input.raw_input:focus {
- box-shadow: none;
- }
- p.p-space {
- margin-bottom: 10px;
- }
- div.output_unrecognized {
- padding: 5px;
- font-weight: bold;
- color: red;
- }
- div.output_unrecognized a {
- color: inherit;
- text-decoration: none;
- }
- div.output_unrecognized a:hover {
- color: inherit;
- text-decoration: none;
- }
- .rendered_html {
- color: #000;
- /* any extras will just be numbers: */
- }
- .rendered_html :link {
- text-decoration: underline;
- }
- .rendered_html :visited {
- text-decoration: underline;
- }
- .rendered_html h1:first-child {
- margin-top: 0.538em;
- }
- .rendered_html h2:first-child {
- margin-top: 0.636em;
- }
- .rendered_html h3:first-child {
- margin-top: 0.777em;
- }
- .rendered_html h4:first-child {
- margin-top: 1em;
- }
- .rendered_html h5:first-child {
- margin-top: 1em;
- }
- .rendered_html h6:first-child {
- margin-top: 1em;
- }
- .rendered_html ul:not(.list-inline),
- .rendered_html ol:not(.list-inline) {
- padding-left: 2em;
- }
- .rendered_html * + ul {
- margin-top: 1em;
- }
- .rendered_html * + ol {
- margin-top: 1em;
- }
- .rendered_html pre,
- .rendered_html tr,
- .rendered_html th,
- .rendered_html tbody tr:nth-child(odd) {
- background: #f5f5f5;
- }
- .rendered_html tbody tr:hover {
- background: rgba(66, 165, 245, 0.2);
- }
- .rendered_html * + table {
- margin-top: 1em;
- }
- .rendered_html * + p {
- margin-top: 1em;
- }
- .rendered_html * + img {
- margin-top: 1em;
- }
- .rendered_html img,
- .rendered_html img.unconfined,
- .rendered_html * + .alert {
- margin-top: 1em;
- }
- [dir="rtl"]
- div.text_cell {
- /* Old browsers */
- display: -webkit-box;
- -webkit-box-orient: horizontal;
- -webkit-box-align: stretch;
- display: -moz-box;
- -moz-box-orient: horizontal;
- -moz-box-align: stretch;
- display: box;
- box-orient: horizontal;
- box-align: stretch;
- /* Modern browsers */
- display: flex;
- flex-direction: row;
- align-items: stretch;
- }
- @media (max-width: 540px) {
- div.text_cell > div.prompt {
- display: none;
- }
- }
- div.text_cell_render {
- /*font-family: "Helvetica Neue", Arial, Helvetica, Geneva, sans-serif;*/
- outline: none;
- resize: none;
- width: inherit;
- border-style: none;
- padding: 0.5em 0.5em 0.5em 0.4em;
- color: #000;
- box-sizing: border-box;
- -moz-box-sizing: border-box;
- -webkit-box-sizing: border-box;
- }
- a.anchor-link:link {
- text-decoration: none;
- padding: 0px 20px;
- visibility: hidden;
- }
- h1:hover .anchor-link,
- h2:hover .anchor-link,
- h3:hover .anchor-link,
- h4:hover .anchor-link,
- h5:hover .anchor-link,
- h6:hover .anchor-link {
- visibility: visible;
- }
- .text_cell.rendered .input_area {
- display: none;
- }
- .text_cell.rendered
- .text_cell.rendered .rendered_html tr,
- .text_cell.rendered .rendered_html th,
- .text_cell.rendered
- .text_cell.unrendered .text_cell_render {
- display: none;
- }
- .text_cell .dropzone .input_area {
- border: 2px dashed #bababa;
- margin: -1px;
- }
- .cm-header-1,
- .cm-header-2,
- .cm-header-3,
- .cm-header-4,
- .cm-header-5,
- .cm-header-6 {
- font-weight: bold;
- font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
- }
- .cm-header-1 {
- font-size: 185.7%;
- }
- .cm-header-2 {
- font-size: 157.1%;
- }
- .cm-header-3 {
- font-size: 128.6%;
- }
- .cm-header-4 {
- font-size: 110%;
- }
- .cm-header-5 {
- font-size: 100%;
- font-style: italic;
- }
- .cm-header-6 {
- font-size: 100%;
- font-style: italic;
- }
- </style>
- <style type="text/css">.highlight-ipynb .hll { background-color: #ffffcc }
- .highlight-ipynb { background: #f8f8f8; }
- .highlight-ipynb .c { color: #408080; font-style: italic } /* Comment */
- .highlight-ipynb .err { border: 1px solid #FF0000 } /* Error */
- .highlight-ipynb .k { color: #008000; font-weight: bold } /* Keyword */
- .highlight-ipynb .o { color: #666666 } /* Operator */
- .highlight-ipynb .ch { color: #408080; font-style: italic } /* Comment.Hashbang */
- .highlight-ipynb .cm { color: #408080; font-style: italic } /* Comment.Multiline */
- .highlight-ipynb .cp { color: #BC7A00 } /* Comment.Preproc */
- .highlight-ipynb .cpf { color: #408080; font-style: italic } /* Comment.PreprocFile */
- .highlight-ipynb .c1 { color: #408080; font-style: italic } /* Comment.Single */
- .highlight-ipynb .cs { color: #408080; font-style: italic } /* Comment.Special */
- .highlight-ipynb .gd { color: #A00000 } /* Generic.Deleted */
- .highlight-ipynb .ge { font-style: italic } /* Generic.Emph */
- .highlight-ipynb .gr { color: #FF0000 } /* Generic.Error */
- .highlight-ipynb .gh { color: #000080; font-weight: bold } /* Generic.Heading */
- .highlight-ipynb .gi { color: #00A000 } /* Generic.Inserted */
- .highlight-ipynb .go { color: #888888 } /* Generic.Output */
- .highlight-ipynb .gp { color: #000080; font-weight: bold } /* Generic.Prompt */
- .highlight-ipynb .gs { font-weight: bold } /* Generic.Strong */
- .highlight-ipynb .gu { color: #800080; font-weight: bold } /* Generic.Subheading */
- .highlight-ipynb .gt { color: #0044DD } /* Generic.Traceback */
- .highlight-ipynb .kc { color: #008000; font-weight: bold } /* Keyword.Constant */
- .highlight-ipynb .kd { color: #008000; font-weight: bold } /* Keyword.Declaration */
- .highlight-ipynb .kn { color: #008000; font-weight: bold } /* Keyword.Namespace */
- .highlight-ipynb .kp { color: #008000 } /* Keyword.Pseudo */
- .highlight-ipynb .kr { color: #008000; font-weight: bold } /* Keyword.Reserved */
- .highlight-ipynb .kt { color: #B00040 } /* Keyword.Type */
- .highlight-ipynb .m { color: #666666 } /* Literal.Number */
- .highlight-ipynb .s { color: #BA2121 } /* Literal.String */
- .highlight-ipynb .na { color: #7D9029 } /* Name.Attribute */
- .highlight-ipynb .nb { color: #008000 } /* Name.Builtin */
- .highlight-ipynb .nc { color: #0000FF; font-weight: bold } /* Name.Class */
- .highlight-ipynb .no { color: #880000 } /* Name.Constant */
- .highlight-ipynb .nd { color: #AA22FF } /* Name.Decorator */
- .highlight-ipynb .ni { color: #999999; font-weight: bold } /* Name.Entity */
- .highlight-ipynb .ne { color: #D2413A; font-weight: bold } /* Name.Exception */
- .highlight-ipynb .nf { color: #0000FF } /* Name.Function */
- .highlight-ipynb .nl { color: #A0A000 } /* Name.Label */
- .highlight-ipynb .nn { color: #0000FF; font-weight: bold } /* Name.Namespace */
- .highlight-ipynb .nt { color: #008000; font-weight: bold } /* Name.Tag */
- .highlight-ipynb .nv { color: #19177C } /* Name.Variable */
- .highlight-ipynb .ow { color: #AA22FF; font-weight: bold } /* Operator.Word */
- .highlight-ipynb .w { color: #bbbbbb } /* Text.Whitespace */
- .highlight-ipynb .mb { color: #666666 } /* Literal.Number.Bin */
- .highlight-ipynb .mf { color: #666666 } /* Literal.Number.Float */
- .highlight-ipynb .mh { color: #666666 } /* Literal.Number.Hex */
- .highlight-ipynb .mi { color: #666666 } /* Literal.Number.Integer */
- .highlight-ipynb .mo { color: #666666 } /* Literal.Number.Oct */
- .highlight-ipynb .sa { color: #BA2121 } /* Literal.String.Affix */
- .highlight-ipynb .sb { color: #BA2121 } /* Literal.String.Backtick */
- .highlight-ipynb .sc { color: #BA2121 } /* Literal.String.Char */
- .highlight-ipynb .dl { color: #BA2121 } /* Literal.String.Delimiter */
- .highlight-ipynb .sd { color: #BA2121; font-style: italic } /* Literal.String.Doc */
- .highlight-ipynb .s2 { color: #BA2121 } /* Literal.String.Double */
- .highlight-ipynb .se { color: #BB6622; font-weight: bold } /* Literal.String.Escape */
- .highlight-ipynb .sh { color: #BA2121 } /* Literal.String.Heredoc */
- .highlight-ipynb .si { color: #BB6688; font-weight: bold } /* Literal.String.Interpol */
- .highlight-ipynb .sx { color: #008000 } /* Literal.String.Other */
- .highlight-ipynb .sr { color: #BB6688 } /* Literal.String.Regex */
- .highlight-ipynb .s1 { color: #BA2121 } /* Literal.String.Single */
- .highlight-ipynb .ss { color: #19177C } /* Literal.String.Symbol */
- .highlight-ipynb .bp { color: #008000 } /* Name.Builtin.Pseudo */
- .highlight-ipynb .fm { color: #0000FF } /* Name.Function.Magic */
- .highlight-ipynb .vc { color: #19177C } /* Name.Variable.Class */
- .highlight-ipynb .vg { color: #19177C } /* Name.Variable.Global */
- .highlight-ipynb .vi { color: #19177C } /* Name.Variable.Instance */
- .highlight-ipynb .vm { color: #19177C } /* Name.Variable.Magic */
- .highlight-ipynb .il { color: #666666 } /* Literal.Number.Integer.Long */</style><style type="text/css">
- .rendered_html a{text-decoration:inherit !important}.rendered_html :link{text-decoration:inherit !important}.rendered_html :visited{text-decoration:inherit !important}pre code{background-color:inherit !important}.highlight{color:#000000}.highlight code{color:#000000}.highlight .n{color:#333333}.highlight .p{color:#000000}.text_cell .prompt{display:none !important}div.input_prompt{padding:0.2em 0.4em}div.output_prompt{padding:0.4em}.text_cell{margin:0 !important;padding:0 !important;border:none !important}.text_cell_render{margin:0 !important;padding:0 !important;border:none !important}.rendered_html *+p{margin-top:inherit !important}.anchor-link{display:none !important}.code_cell{margin:0 !important;padding:5px 0 !important;border:none !important}.celltoolbar{border:thin solid #CFCFCF;border-bottom:none;background:#EEE;border-radius:2px 2px 0px 0px;width:100%;height:29px;padding-right:4px;box-orient:horizontal;box-align:stretch;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-webkit-box-align:stretch;-ms-flex-align:stretch;align-items:stretch;box-pack:end;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;display:-webkit-flex}.celltoolbar .tags_button_container{display:-webkit-box;display:-ms-flexbox;display:flex}.celltoolbar .tags_button_container .tag-container{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1;overflow:hidden;position:relative}.celltoolbar .tags_button_container .tag-container .cell-tag{background-color:#fff;white-space:nowrap;margin:3px 4px;padding:0 4px;border-radius:1px;border:1px solid #ccc;-webkit-box-shadow:none;box-shadow:none;width:inherit;font-size:13px;font-family:"Helvetica Neue", Helvetica, Arial, sans-serif;height:22px;line-height:22px;display:inline-block}div.input_area>div.highlight{margin:0.25em 0.4em !important}.code_cell pre{font-size:12px !important}.output_html table.dataframe{font-family:Arial, sans-serif;font-size:13px;line-height:20px}.output_html table.dataframe th,td{padding:4px;text-align:left}.bk-plot-wrapper tbody tr{background:none !important}.bk-plot-wrapper tbody tr:hover{background:none !important}
- /*# sourceMappingURL=jupyter-fixes.min.css.map */
- </style>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/require.js/2.1.10/require.min.js"></script>
- <script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/2.0.3/jquery.min.js"></script>
- <!-- Loading mathjax macro -->
- <!-- Load mathjax -->
- <script src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.5/latest.js?config=TeX-AMS_HTML"></script>
- <!-- MathJax configuration -->
- <script type="text/x-mathjax-config">
- MathJax.Hub.Config({
- tex2jax: {
- inlineMath: [ ['$','$'], ["\\(","\\)"] ],
- displayMath: [ ['$$','$$'], ["\\[","\\]"] ],
- processEscapes: true,
- processEnvironments: true
- },
- // Center justify equations in code and markdown cells. Elsewhere
- // we use CSS to left justify single line equations in code cells.
- displayAlign: 'center',
- "HTML-CSS": {
- styles: {'.MathJax_Display': {"margin": 0}},
- linebreaks: { automatic: true }
- }
- });
- </script>
- <!-- End of mathjax configuration -->
- <div class="cell border-box-sizing text_cell rendered"><div class="prompt input_prompt">
- </div><div class="inner_cell">
- <div class="text_cell_render border-box-sizing rendered_html">
- <h1 id="gallery">Gallery<a class="anchor-link" href="#Gallery">¶</a></h1>
- </div>
- </div>
- </div>
- <div class="cell border-box-sizing code_cell rendered">
- <div class="input">
- <div class="prompt input_prompt">In [1]:</div>
- <div class="inner_cell">
-
-
- <div class="input_area">
- <div class=" highlight highlight-ipynb hl-python"><pre><span></span><span class="o">%</span><span class="n">matplotlib</span> <span class="n">widget</span>
- </pre></div>
- </div>
- </div>
- </div>
- </div>
- <div class="cell border-box-sizing code_cell rendered">
- <div class="input">
- <div class="prompt input_prompt">In [2]:</div>
- <div class="inner_cell">
-
-
- <div class="input_area">
- <div class=" highlight highlight-ipynb hl-python"><pre><span></span><span class="kn">from</span> <span class="nn">ipywidgets</span> <span class="kn">import</span> <span class="n">HBox</span><span class="p">,</span> <span class="n">VBox</span><span class="p">,</span> <span class="n">Output</span><span class="p">,</span> <span class="n">Label</span>
- </pre></div>
- </div>
- </div>
- </div>
- </div>
- <div class="cell border-box-sizing code_cell rendered">
- <div class="input">
- <div class="prompt input_prompt">In [3]:</div>
- <div class="inner_cell">
-
-
- <div class="input_area">
- <div class=" highlight highlight-ipynb hl-python"><pre><span></span><span class="n">url</span> <span class="o">=</span> <span class="s2">"https://raw.githubusercontent.com/gbrault/jupytersketches/master/"</span>
- </pre></div>
- </div>
- </div>
- </div>
- </div>
- <div class="cell border-box-sizing code_cell rendered">
- <div class="input">
- <div class="prompt input_prompt">In [4]:</div>
- <div class="inner_cell">
-
-
- <div class="input_area">
- <div class=" highlight highlight-ipynb hl-python"><pre><span></span><span class="n">gallery</span> <span class="o">=</span> <span class="n">Output</span><span class="p">()</span>
- <span class="n">gallery</span>
- </pre></div>
- </div>
- </div>
- </div>
- <div class="output_wrapper">
- <div class="output">
- <div class="output_area">
- <div class="prompt"></div>
-
-
- <div id="11290a74-68ce-46ca-9096-01a77a326783"></div>
- <div class="output_subarea output_widget_view ">
- <script type="text/javascript">
- var element = $('#11290a74-68ce-46ca-9096-01a77a326783');
- </script>
- <script type="application/vnd.jupyter.widget-view+json">
- {"version_major": 2, "version_minor": 0, "model_id": "52ea7cdf6d824834862f556af8859788"}
- </script>
- </div>
- </div>
- </div>
- </div>
- </div>
- <div class="cell border-box-sizing code_cell rendered">
- <div class="input">
- <div class="prompt input_prompt">In [5]:</div>
- <div class="inner_cell">
-
-
- <div class="input_area">
- <div class=" highlight highlight-ipynb hl-python"><pre><span></span><span class="kn">from</span> <span class="nn">pysketcher</span> <span class="kn">import</span> <span class="o">*</span>
- </pre></div>
- </div>
- </div>
- </div>
- </div>
- <div class="cell border-box-sizing code_cell rendered">
- <div class="input">
- <div class="prompt input_prompt">In [6]:</div>
- <div class="inner_cell">
-
-
- <div class="input_area">
- <div class=" highlight highlight-ipynb hl-python"><pre><span></span><span class="kn">import</span> <span class="nn">time</span>
- </pre></div>
- </div>
- </div>
- </div>
- </div>
- <div class="cell border-box-sizing code_cell rendered">
- <div class="input">
- <div class="prompt input_prompt">In [7]:</div>
- <div class="inner_cell">
-
-
- <div class="input_area">
- <div class=" highlight highlight-ipynb hl-python"><pre><span></span><span class="kn">from</span> <span class="nn">IPython.display</span> <span class="kn">import</span> <span class="n">HTML</span><span class="p">,</span> <span class="n">SVG</span><span class="p">,</span> <span class="n">display</span><span class="p">,</span> <span class="n">clear_output</span>
- </pre></div>
- </div>
- </div>
- </div>
- </div>
- <div class="cell border-box-sizing code_cell rendered">
- <div class="input">
- <div class="prompt input_prompt">In [8]:</div>
- <div class="inner_cell">
-
-
- <div class="input_area">
- <div class=" highlight highlight-ipynb hl-python"><pre><span></span><span class="n">files</span> <span class="o">=</span> <span class="p">[(</span><span class="s2">"dryfriction"</span><span class="p">,</span><span class="s2">"friction"</span><span class="p">),(</span><span class="s2">"pendulum"</span><span class="p">,</span><span class="s2">"pendulum"</span><span class="p">),</span>
- <span class="p">(</span><span class="s2">"car"</span><span class="p">,</span><span class="s2">"car"</span><span class="p">),(</span><span class="s2">"springmass"</span><span class="p">,</span><span class="s2">"springmass"</span><span class="p">),</span>
- <span class="p">(</span><span class="s2">"springdashpotmass"</span><span class="p">,</span><span class="s2">"springdashpotmass"</span><span class="p">),(</span><span class="s2">"jet_pump"</span><span class="p">,</span><span class="s2">"jet_pump"</span><span class="p">)]</span>
- </pre></div>
- </div>
- </div>
- </div>
- </div>
- <div class="cell border-box-sizing code_cell rendered">
- <div class="input">
- <div class="prompt input_prompt">In [9]:</div>
- <div class="inner_cell">
-
-
- <div class="input_area">
- <div class=" highlight highlight-ipynb hl-python"><pre><span></span><span class="n">i</span> <span class="o">=</span> <span class="mi">0</span>
- <span class="n">horiz</span> <span class="o">=</span> <span class="p">[]</span>
- <span class="n">vert</span> <span class="o">=</span> <span class="p">[]</span>
- <span class="n">outputs</span> <span class="o">=</span> <span class="p">[</span><span class="n">Output</span><span class="p">()</span> <span class="k">for</span> <span class="n">file</span> <span class="ow">in</span> <span class="n">files</span><span class="p">]</span>
- <span class="k">for</span> <span class="n">output</span> <span class="ow">in</span> <span class="n">outputs</span><span class="p">:</span>
- <span class="k">if</span> <span class="n">i</span> <span class="o">==</span> <span class="mi">3</span><span class="p">:</span>
- <span class="n">vert</span><span class="o">.</span><span class="n">append</span><span class="p">(</span><span class="n">HBox</span><span class="p">(</span><span class="n">horiz</span><span class="p">))</span>
- <span class="n">horiz</span> <span class="o">=</span> <span class="p">[</span><span class="n">output</span><span class="p">]</span>
- <span class="n">i</span> <span class="o">=</span> <span class="mi">0</span>
- <span class="k">else</span><span class="p">:</span>
- <span class="n">i</span> <span class="o">+=</span> <span class="mi">1</span>
- <span class="n">horiz</span><span class="o">.</span><span class="n">append</span><span class="p">(</span><span class="n">output</span><span class="p">)</span>
- <span class="k">if</span> <span class="n">i</span> <span class="o">>=</span> <span class="mi">0</span> <span class="ow">and</span> <span class="n">i</span> <span class="o"><</span> <span class="mi">3</span><span class="p">:</span>
- <span class="n">vert</span><span class="o">.</span><span class="n">append</span><span class="p">(</span><span class="n">HBox</span><span class="p">(</span><span class="n">horiz</span><span class="p">))</span>
- <span class="k">with</span> <span class="n">gallery</span><span class="p">:</span>
- <span class="n">display</span><span class="p">(</span><span class="n">VBox</span><span class="p">(</span><span class="n">vert</span><span class="p">))</span>
- <span class="n">i</span> <span class="o">=</span> <span class="mi">0</span>
- <span class="k">for</span> <span class="n">file</span> <span class="ow">in</span> <span class="n">files</span><span class="p">:</span>
- <span class="n">sketch</span> <span class="o">=</span> <span class="n">Sketch</span><span class="p">({})</span>
- <span class="n">sketch</span><span class="o">.</span><span class="n">url2Sketch</span><span class="p">(</span><span class="n">url</span> <span class="o">+</span> <span class="n">file</span><span class="p">[</span><span class="mi">0</span><span class="p">]</span> <span class="o">+</span><span class="s2">".yml"</span><span class="p">)</span>
- <span class="n">drawing_tool</span><span class="o">.</span><span class="n">erase</span><span class="p">()</span>
- <span class="n">sketch</span><span class="o">.</span><span class="n">container</span><span class="p">[</span><span class="n">file</span><span class="p">[</span><span class="mi">1</span><span class="p">]]</span><span class="o">.</span><span class="n">draw</span><span class="p">()</span>
- <span class="n">link</span> <span class="o">=</span> <span class="sa">f</span><span class="s2">"<a target=</span><span class="se">\"</span><span class="s2">_blank</span><span class="se">\"</span><span class="s2"> href=</span><span class="se">\"</span><span class="si">{</span><span class="n">url</span> <span class="o">+</span> <span class="n">file</span><span class="p">[</span><span class="mi">0</span><span class="p">]</span> <span class="o">+</span><span class="s1">'.yml'</span><span class="si">}</span><span class="se">\"</span><span class="s2">><h3></span><span class="si">{</span><span class="n">file</span><span class="p">[</span><span class="mi">0</span><span class="p">]</span><span class="si">}</span><span class="s2"></h3></a>"</span>
- <span class="k">with</span> <span class="n">outputs</span><span class="p">[</span><span class="n">i</span><span class="p">]:</span>
- <span class="n">clear_output</span><span class="p">(</span><span class="n">wait</span><span class="o">=</span><span class="kc">True</span><span class="p">)</span>
- <span class="n">display</span><span class="p">(</span><span class="n">HTML</span><span class="p">(</span><span class="n">link</span><span class="p">),</span>
- <span class="n">SVG</span><span class="p">(</span><span class="n">Sketch</span><span class="o">.</span><span class="n">matplotlib2SVG</span><span class="p">()))</span>
- <span class="n">i</span> <span class="o">+=</span> <span class="mi">1</span>
- <span class="n">time</span><span class="o">.</span><span class="n">sleep</span><span class="p">(</span><span class="mf">0.1</span><span class="p">)</span>
- </pre></div>
- </div>
- </div>
- </div>
- </div>
- <div class="cell border-box-sizing code_cell rendered">
- <div class="input">
- <div class="prompt input_prompt">In [ ]:</div>
- <div class="inner_cell">
-
-
- <div class="input_area">
- <div class=" highlight highlight-ipynb hl-python"><pre><span></span>
- </pre></div>
- </div>
- </div>
- </div>
- </div>
-
- </div>
-
-
-
-
-
- </article>
- </div>
- </div>
- </main>
-
-
- <footer class="md-footer">
-
- <div class="md-footer-meta md-typeset">
- <div class="md-footer-meta__inner md-grid">
- <div class="md-footer-copyright">
-
- Made with
- <a href="https://squidfunk.github.io/mkdocs-material/" target="_blank" rel="noopener">
- Material for MkDocs
- </a>
- </div>
-
- </div>
- </div>
- </footer>
-
- </div>
-
- <script src="../../assets/javascripts/vendor.c3dc8c49.min.js"></script>
- <script src="../../assets/javascripts/bundle.f9edbbd5.min.js"></script><script id="__lang" type="application/json">{"clipboard.copy": "Copy to clipboard", "clipboard.copied": "Copied to clipboard", "search.config.lang": "en", "search.config.pipeline": "trimmer, stopWordFilter", "search.config.separator": "[\\s\\-]+", "search.result.placeholder": "Type to start searching", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents"}</script>
-
- <script>
- app = initialize({
- base: "../..",
- features: [],
- search: Object.assign({
- worker: "../../assets/javascripts/worker/search.8e2cddea.min.js"
- }, typeof search !== "undefined" && search)
- })
- </script>
-
- <script src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.2/MathJax.js?config=TeX-MML-AM_CHTML"></script>
-
-
- </body>
- </html>
|