This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| version: "3.9" | |
| services: | |
| jupyter: | |
| image: quay.io/jupyter/scipy-notebook | |
| ports: | |
| - "8888:8888" | |
| volumes: | |
| - ./notebooks:/home/jovyan/ | |
| environment: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React, { useState } from 'react'; | |
| import ReactPaginate from 'react-paginate'; | |
| import ArrowBackIosIcon from '@material-ui/icons/ArrowBackIos'; | |
| import ArrowForwardIosIcon from '@material-ui/icons/ArrowForwardIos'; | |
| import './pagination.css'; | |
| function App() { | |
| const [pageCount, setPageCount] = useState(1); | |
| const itemsLoaded = ({ | |
| limit, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <%= form_with(model: billboard) do |form| %> | |
| <%= tag.div class: "dropzone", data: { controller: "dropzone", dropzone_param_name_value: "billboard[images][]", dropzone_url_value: rails_direct_uploads_url, dropzone_accepted_files_value: "image/*", dropzone_max_files_value: 3, dropzone_max_filesize_value: 0.300 } do %> | |
| <div class="dz-default dz-message flex flex-col items-center"> | |
| <%= image_tag "upload.svg", size: 28, class: "colorize-black", aria: { hidden: true } %> | |
| <h5 class="font-semibold mbs-4">Drop files here or click to upload.</h5> | |
| <p class="text-sm text-subtle">Upload up to 10 files.</p> | |
| </div> | |
| <% end %> | |
| <div class="inline-flex items-center mbs-2 mie-1"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import imageio | |
| import os, sys | |
| class TargetFormat(object): | |
| GIF = ".gif" | |
| MP4 = ".mp4" | |
| AVI = ".avi" | |
| def convertFile(inputpath, targetFormat): | |
| """Reference: http://imageio.readthedocs.io/en/latest/examples.html#convert-a-movie""" |