sha256 stringlengths 64 64 | language stringclasses 28
values | size int32 1 491k | lines int32 1 23.2k | content stringlengths 1 200k |
|---|---|---|---|---|
e85a4dda011ff0f352c245c96cc4eb6db38ed51df946bbc9aaba17513b210599 | JavaScript | 1,737 | 41 | // single source of truth for landmark identity - names, order, anatomical
// descriptions, and colors. the color values here have to match the
// --landmark-* custom properties in index.css by hand (Three.js materials
// need a JS hex number, CSS needs a hex string) - same duplication legacy
// had, same fix (a commen... |
2b5c45967f61022d2a1014a46a731c9a3c9b645111e7c7f103e887233c44e9cc | JavaScript | 1,789 | 61 | 'use strict';
const { spawn } = require('child_process');
const program = require('commander');
let appOpts;
/* eslint-disable no-console */
function parse() {
if (process.defaultApp) {
const opts = program
.allowUnknownOption()
.option('-dev, --development', 'run in development mode (NODE_ENV === ... |
f9b19652f6ab1afe734737a838c18aba1c46b41aa47ae82bd8b5799096137912 | JavaScript | 1,819 | 73 | import axios from 'axios'
const apiClient = axios.create({
baseURL: process.env.API_URL,
withCredentials: false,
headers: {
Accept: 'application/json',
'Content-Type': 'application/json'
}
})
const uploadClient = axios.create({
baseURL: process.env.API_URL,
method: 'post',
headers: {
'Content... |
b15f6c240ceb1d056d4e6e03b5d6bd412304f60624d39016ae569a4abc889430 | JavaScript | 1,837 | 76 | const {
setup,
beforeHandler,
afterHandler,
beforeEachHandler,
afterEachHandler,
} = require('../lib/setup');
const user = require('../lib/user');
const { USER_1, USER_4 } = require('../lib/constants');
const consortia = require('../lib/consortia');
const DATA = {
consortium: {
name: 'e2e-consortium-2-... |
bf8ec5806214ee8f1a6ccef2302567d536bc85554ac883770deaaf52e19e0d9f | JavaScript | 1,848 | 1 | $wnd.jsme.runAsyncCallback9('function g9(a){a=a.ld.b.c++;return Gi+a}y(488,489,z_);_.qf=function(){return g9(this)};_.Bf=function(){this.vd=new h9((fI(),m),this)};_.Hf=function(){return(null==this.sd&&(this.sd=g9(this)),this.sd)+Yb+this.vd.zf()+Yb+this.vd.Af()+Yb+this.Ad+im+this.pd+(this.zd?m:",hidden")+",title="+this.... |
cc5a5b4e2dc3c8316d62d4fb82e62306dbf63c7574e5f7c9ff8b4e0156f58a96 | JavaScript | 1,848 | 1 | $wnd.jsme.runAsyncCallback9('function e9(a){a=a.ld.b.c++;return Gi+a}y(488,489,z_);_.qf=function(){return e9(this)};_.Bf=function(){this.vd=new f9((fI(),m),this)};_.Hf=function(){return(null==this.sd&&(this.sd=e9(this)),this.sd)+Yb+this.vd.zf()+Yb+this.vd.Af()+Yb+this.Ad+im+this.pd+(this.zd?m:",hidden")+",title="+this.... |
ee8e7b17216ba1c86ccb352749c42d1e86d3d192d43c7e30191d8ec6d105e4f9 | JavaScript | 1,848 | 1 | $wnd.jsme.runAsyncCallback9('function K7(a){a=a.ld.b.c++;return Ei+a}x(473,474,jZ);_.mf=function(){return K7(this)};_.xf=function(){this.vd=new L7((ZG(),n),this)};_.Df=function(){return(null==this.sd&&(this.sd=K7(this)),this.sd)+Xb+this.vd.vf()+Xb+this.vd.wf()+Xb+this.Ad+fm+this.pd+(this.zd?n:",hidden")+",title="+this.... |
f355ac3d42ea829632499068a468b27af4b45dd0a409eb851efd21e0bcc19451 | JavaScript | 1,848 | 1 | $wnd.jsme.runAsyncCallback9('function M7(a){a=a.ld.b.c++;return Ei+a}x(473,474,jZ);_.mf=function(){return M7(this)};_.xf=function(){this.vd=new N7((ZG(),n),this)};_.Df=function(){return(null==this.sd&&(this.sd=M7(this)),this.sd)+Xb+this.vd.vf()+Xb+this.vd.wf()+Xb+this.Ad+fm+this.pd+(this.zd?n:",hidden")+",title="+this.... |
0123fcab1d930d677ecb12f42023b581143bfeffa488a845efb893874e08b29d | JavaScript | 1,851 | 1 | $wnd.jsme.runAsyncCallback9('function A9(a){a=a.ld.b.c++;return Ii+a}y(493,494,X_);_.wf=function(){return A9(this)};_.Hf=function(){this.vd=new B9((FI(),m),this)};_.Nf=function(){return(null==this.sd&&(this.sd=A9(this)),this.sd)+Xb+this.vd.Ff()+Xb+this.vd.Gf()+Xb+this.Ad+pm+this.pd+(this.zd?m:",hidden")+",title="+this.... |
12333ecbb5335e812f0440686da89b4f44e597d7d06c126ee01b6e070d6e2858 | JavaScript | 1,851 | 1 | $wnd.jsme.runAsyncCallback9('function K7(a){a=a.ld.b.c++;return ni+a}x(470,471,ZY);_.mf=function(){return K7(this)};_.xf=function(){this.vd=new L7((MG(),n),this)};_.Df=function(){return(null==this.sd&&(this.sd=K7(this)),this.sd)+xb+this.vd.vf()+xb+this.vd.wf()+xb+this.Ad+Vl+this.pd+(this.zd?n:",hidden")+",title="+this.... |
3a92be869d858f05f47241ac1a6ca2cf35703433dfcfe87c273d3189037ef765 | JavaScript | 1,851 | 1 | $wnd.jsme.runAsyncCallback9('function T9(a){a=a.ld.b.c++;return Fi+a}y(497,498,p0);_.uf=function(){return T9(this)};_.Ff=function(){this.vd=new U9((WI(),m),this)};_.Lf=function(){return(null==this.sd&&(this.sd=T9(this)),this.sd)+Wb+this.vd.Df()+Wb+this.vd.Ef()+Wb+this.Ad+pm+this.pd+(this.zd?m:",hidden")+",title="+this.... |
9d3334e7d71d2e9d307b0cc8fb173f1971e9bbf8f1cb3988809b448e9bc8df06 | JavaScript | 1,851 | 1 | $wnd.jsme.runAsyncCallback9('function y9(a){a=a.ld.b.c++;return Ii+a}y(493,494,X_);_.wf=function(){return y9(this)};_.Hf=function(){this.vd=new z9((FI(),m),this)};_.Nf=function(){return(null==this.sd&&(this.sd=y9(this)),this.sd)+Xb+this.vd.Ff()+Xb+this.vd.Gf()+Xb+this.Ad+pm+this.pd+(this.zd?m:",hidden")+",title="+this.... |
c1167810bb058c4b4ac6c3b28052989a62ef1b53f47fb1c7b8927d978c570571 | JavaScript | 1,851 | 1 | $wnd.jsme.runAsyncCallback9('function I7(a){a=a.ld.b.c++;return ni+a}x(470,471,ZY);_.mf=function(){return I7(this)};_.xf=function(){this.vd=new J7((MG(),n),this)};_.Df=function(){return(null==this.sd&&(this.sd=I7(this)),this.sd)+xb+this.vd.vf()+xb+this.vd.wf()+xb+this.Ad+Vl+this.pd+(this.zd?n:",hidden")+",title="+this.... |
dbd003c5c2dc6afb0a10fbb7fda5cd5b16487407d4104158c1e839ca8e515687 | JavaScript | 1,851 | 1 | $wnd.jsme.runAsyncCallback9('function V9(a){a=a.ld.b.c++;return Fi+a}y(497,498,q0);_.uf=function(){return V9(this)};_.Ff=function(){this.vd=new W9((XI(),m),this)};_.Lf=function(){return(null==this.sd&&(this.sd=V9(this)),this.sd)+Wb+this.vd.Df()+Wb+this.vd.Ef()+Wb+this.Ad+qm+this.pd+(this.zd?m:",hidden")+",title="+this.... |
0767b8d4a8ef526d8601ff2acd779909bd475ed36c49844388a4ab1da197dd67 | JavaScript | 1,886 | 1 | $wnd.jsme.runAsyncCallback9('var Wsa="Atom ",Xsa="Cancel",Ysa="New atom ",Zsa="atom ";function g$(a){a=a.ld.b.c++;return Dn+a}x(475,476,T0);_.qf=function(){return g$(this)};_.Bf=function(){this.vd=new h$((hL(),n),this)};_.Hf=function(){return(null==this.sd&&(this.sd=g$(this)),this.sd)+Pe+this.vd.zf()+Pe+this.vd.Af()+Pe... |
6647f50997a14ef8f3fc484fb4a6329eb8b22e3f511189b1db297d2ae57e2b8e | JavaScript | 1,886 | 1 | $wnd.jsme.runAsyncCallback9('var Xsa="Atom ",Ysa="Cancel",Zsa="New atom ",$sa="atom ";function g$(a){a=a.ld.b.c++;return Bn+a}x(475,476,R0);_.qf=function(){return g$(this)};_.Bf=function(){this.vd=new h$((fL(),n),this)};_.Hf=function(){return(null==this.sd&&(this.sd=g$(this)),this.sd)+Pe+this.vd.zf()+Pe+this.vd.Af()+Pe... |
771369a19211f75cfafa24f2cb190d2cdc7bf4cb28793f3c69cf467203afb6c8 | JavaScript | 1,921 | 18 | var searchData=
[
['activate_5fpicker',['activate_picker',['../classtina__main_1_1dataset.html#a9a12fa3edbc97f21a84e67570c644d6b',1,'tina_main::dataset']]],
['adaptive_5fthresholding',['adaptive_thresholding',['../namespacetinaimg.html#a233119a5bb41fb63dccbc6aae40bccd6',1,'tinaimg.adaptive_thresholding()'],['../nam... |
e3695633d3d6f2f9e67525a5303def0407e5ecccf6e49d785ac64572d2a48295 | JavaScript | 1,930 | 72 | 'use strict';
const { dialog } = require('electron');
const path = require('path');
// Mock file dialogue in testing environment
// Watch the following issue for progress on dialog support
// https://github.com/electron/spectron/issues/94
function mockFileDialog() {
let count;
switch (process.env.TEST_INSTANCE) {... |
4e55a3934c4217f9cba39b6b5261c135a48b579b8a31a90110026c1198dfa9ae | JavaScript | 1,965 | 86 | /* eslint-disable */
const migrate = require('migrate');
const path = require('path');
const database = require('../index');
const stateStore = {
load: async function(cb) {
try {
const db = database.getDbInstance();
const migrationsState = await db.collection('migrations').findOne();
if (!... |
6aebd5bde68d68cdbf235c43e793448ed05fb4558a35c865f0e9491698be2fee | JavaScript | 2,020 | 34 | /* eslint-disable import/no-extraneous-dependencies */
const pify = require('util').promisify;
const rmrf = pify(require('rimraf'));
const mkdirp = pify(require('mkdirp'));
const ncp = pify(require('ncp'));
const path = require('path');
const { npmi } = require('./utils/npmi');
const paths = [
path.join('node_module... |
848f0974151eb28a71d8786cb0279edb62ae8a777c1c189edb6303ccaece9455 | JavaScript | 2,029 | 47 | import de from '@server/controllers/v1/de.js'
import dataset from '@server/controllers/v1/dataset.js'
import dimension from '@server/controllers/v1/dimension.js'
import expression from '@server/controllers/v1/expression.js'
import iris3 from '@server/controllers/v1/iris3.js'
import publication from '@server/controllers... |
fc6f21b44c791b36e325f267501133ee966e6cca99f9ba18a39d62e1ffb771ec | JavaScript | 2,040 | 47 | import de from '@server/controllers/v1/de.js'
import dataset from '@server/controllers/v1/dataset.js'
import dimension from '@server/controllers/v1/dimension.js'
import expression from '@server/controllers/v1/expression.js'
import iris3 from '@server/controllers/v1/iris3.js'
import publication from '@server/controllers... |
2ff71d7a1d8b8533618f4b8d1e654f1d5c98e557b43ce3cbc3cb59aa653ab160 | JavaScript | 2,057 | 55 | import * as THREE from "three";
// +/-1 SD ribbon around some mean curve on the mean shape's own surface -
// see craniumpy_core.cohort.SpreadBand (hc_ring_band/metopic_band/
// sagittal_band_to_spread_band all produce this same inner/outer point-pair
// shape, one point of inner matching the same position along the c... |
23a8f1319a288169f68806324c1c4a98ca706881dbe7641c7e30a06c22f960a7 | JavaScript | 2,063 | 95 | /*
notebook.js
Author: Andreas Heger
7/10/2014
Instructions:
Download this file
Add <script src="notebook.js"></script> to your HTML
Add class="sortable" to any table you'd like to make sortable
Click on the headers to sort
Licenced as X11: http://www.kryogenix.org/code/browser/licence.ht... |
04f05f1a5c62c82e05802ec4d3b2ce2b531645aef11de18b809ba28d817a9aed | JavaScript | 2,068 | 53 | /* eslint-disable no-console */
const { dialog } = require('electron');
const { autoUpdater } = require('electron-updater');
let window;
const listenForUpdates = (logger) => {
autoUpdater.logger = logger;
autoUpdater.checkForUpdatesAndNotify();
autoUpdater.on('error', (error) => {
console.error('Auto updat... |
c653b12cef099b7722792e5296b1391521e9594abcc70a087743061407fb7887 | JavaScript | 2,078 | 21 | var mplerror_8h =
[
[ "MPL_ERR_T", "mplerror_8h.html#abf98fc9756a0b89bc270def9b6941460", [
[ "ERR_EX_DATA_CONF", "mplerror_8h.html#abf98fc9756a0b89bc270def9b6941460ae798d6e893e8dbecf356f5937e04cf4f", null ],
[ "ERR_OUT_OF_BOUNDS", "mplerror_8h.html#abf98fc9756a0b89bc270def9b6941460a495247f86f2d33551142f... |
7c35c09ea080df520774f49bb279577d6b65f4d14fb9361d279712fcf6b5a385 | JavaScript | 2,086 | 79 | /* eslint-disable import/prefer-default-export */
import { deepParseJson } from 'deep-parse-json';
import { dirname, join } from 'path';
import { createMigrate, REHYDRATE } from 'redux-persist';
import localDBMigrations from '../migrations';
import { electronStore, storage } from '../storage';
import { API_TOKEN_KEY }... |
8f47613a0e3f437f983e1c06aa449ab817686fae1d89581a1e4057b9ed038bbe | JavaScript | 2,112 | 86 | const {
setup,
beforeHandler,
afterHandler,
beforeEachHandler,
afterEachHandler,
} = require('../lib/setup');
const user = require('../lib/user');
const { USER_1, USER_2 } = require('../lib/constants');
const consortia = require('../lib/consortia');
const pipeline = require('../lib/pipeline');
const DATA = {... |
817d45bc0cd58b3d63389e0a60b61a5c4382131bc4813b30a2361ee09b9f2dc8 | JavaScript | 2,125 | 77 | import { base64ToBlob } from '../utils/helpers';
/**
* A helper class that returns objects that direct how to represent thumbnails
* for given point IDs. If the given dataset has spritesheets, this object loads
* the spritesheets as blobs and returns the URLs needed to render image
* thumbnails.
*
* Note that de... |
d82aa5421a6585c0ca91c49f3e4d950d3df3a491b6061c2d6645f21bc4f1f90b | JavaScript | 2,131 | 74 | var imgW_scale = 1.25;
var imgH_fraq = .35;
function calc_w() {
return Math.floor(calc_h() * imgW_scale);
}
function calc_h() {
return Math.floor(window.innerHeight * imgH_fraq);
}
function do_draw(jsme, imgRef, url) {
window.fetch ? _redraw_POST(jsme,imgRef,url) : _redraw_GET(jsme,imgRef,url)
}
function... |
6c9e0e97590a2691946ff4775a271c138011cbdc6b3111a5b8a3f0d3a7381b43 | JavaScript | 2,178 | 80 | 'use strict';
const convict = require('convict');
const { app } = require('electron');
const pify = require('util').promisify;
const access = pify(require('fs').access);
const path = require('path');
const home = require('os').homedir;
const localConfig = path.resolve(__dirname, '..', 'config', 'local.json');
const ... |
4a6bb5158de52fbe5c5f7f9d751daf1c5f90f0f0d1c33618c638920f5c330647 | JavaScript | 2,182 | 73 | #!/usr/bin/env node
/* eslint-disable no-console */
const hapi = require('@hapi/hapi');
const axios = require('axios');
// set w/ config etc post release
process.LOGLEVEL = 'silly';
const { pullImages } = require('coinstac-container-manager');
const graphqlSchema = require('coinstac-graphql-schema');
const { program }... |
203e4fc36d5c2997f2f92ab3c9b2b93deb3030beb25ee78e640ec8a505a2fa67 | JavaScript | 2,207 | 81 | import * as PIXI from 'pixi.js';
import { Circle } from 'pixi.js';
const v = 80.0;
export default class PixiRadiusSelect extends PIXI.Graphics {
centerID;
centerX;
centerY;
radius;
fillColor;
timeCounter;
constructor(centerID, centerX, centerY, radius, fillColor) {
super();
this.centerID = cent... |
660201cf33c1c6306f8e29e7d18ce2648b9c55b42f06771c571481d635ea4c24 | JavaScript | 2,208 | 17 | var searchData=
[
['page_5fheight',['page_height',['../namespaceanalyze__ocn.html#a3aff7b3b8f12f2cd406bb0079e18c2f1',1,'analyze_ocn']]],
['params',['params',['../namespaceanalyze__ocn.html#aceb5fb8169762e5e5781d350dbf51bf8',1,'analyze_ocn']]],
['parse_5fxml',['parse_xml',['../namespacetinaui.html#a046cbe09726bea6... |
73235fc94b8da9e0049e651a41f19d01eb3a0bc5e29533210bc840900273672f | JavaScript | 2,218 | 39 | import { meshUrl, nicpResultMeshUrl } from "../../../api/sessions.js";
// a ready slot's own mesh, as the {sessionId, stage} ref shape
// api/longitudinal.js's calls (measureMesh/computeLongitudinalDiff) expect
// - shared by CompareTab.jsx and the 3D Morphing tab, both of which just
// read whatever stage TimepointSl... |
029238add637829749265329ff7fb80432550b446263f6a35160fd7271812afc | JavaScript | 2,254 | 58 | import * as THREE from "three";
import { OrbitControls } from "three/examples/jsm/controls/OrbitControls.js";
// pure Three.js, no React - createScene owns the persistent scene/camera/
// renderer/controls, useThreeScene.js owns wiring this into React's
// lifecycle (mount effect, animation loop, resize, cleanup).
exp... |
4a590253518a13f8cf84ae88c98fc5f22130c8d9bbaad025b07b0576dcd9223f | JavaScript | 2,273 | 78 | 'use strict';
import test from 'ava';
const { createReadStream, readFileSync, unlink } = require('fs');
const resolvePath = require('path').resolve;
const unzip = require('unzipper');
const ss = require('socket.io-stream');
const socketIOClient = require('socket.io-client');
const server = require('../server-ws');
t... |
bbdc3226e656ad5d9006a2067d43671d83a6de5268dd3bea1771f8dc7063fa72 | JavaScript | 2,292 | 52 | import { useEffect, useRef } from "react";
import { createScene } from "./scene.js";
// bridges createScene's imperative Three.js world into React: builds the
// scene once on mount (a ref, not state - none of this should ever trigger
// a re-render), runs the render loop, keeps the canvas sized to its
// container vi... |
59f1fa412eb42ad8d286c078a1dc372eb75d7ac151c181149bb5c3887b1de4a6 | JavaScript | 2,294 | 76 | class PavloviaManager {
constructor(saveIncompleteResultsCallback) {
this.shouldUsePavlovia = isHostPavlovia();
this.pavloviaPlugin = jsPsych.plugins['pavlovia'];
this.saveIncompleteResultsCallback = saveIncompleteResultsCallback;
this.hasServerSession = false;
}
async initServerSessionIfNeeded()... |
01c9c890dd1231078679b7bd414f02492df9cc5dada99169445306865064ec76 | JavaScript | 2,300 | 64 | const { EXIST_TIMEOUT } = require('../lib/constants');
const createPipeline = async ({
consortium,
pipeline,
computation,
}, app) => {
// Go to create pipeline page
await app.click('a:has-text("Pipelines")');
await app.click('a[name="create-pipeline-button"]', { timeout: EXIST_TIMEOUT });
// Assert
a... |
d56fc623688fdac11a9c44fa8810922f9ffbaefaf355fdca17db51d4b38fe36e | JavaScript | 2,309 | 79 | /*
* @module actions/loading
*/
import omit from 'lodash/omit';
let asyncLoadingCallCount = 0;
const LOADING_START = 'LOADING_START';
export const start = key => ({ type: LOADING_START, key });
const LOADING_FINISH = 'LOADING_FINISH';
export const finish = key => ({ type: LOADING_FINISH, key });
/**
* Wraps a no... |
c6c561e60b05fcae941d57a678ab83a3f5416e274b3960d2e0413c6749c2b558 | JavaScript | 2,329 | 81 | 'use strict';
const http = require('http');
require('trace');
require('clarify');
const { spawn } = require('child_process');
const winston = require('winston');
const socketIO = require('socket.io');
const ss = require('socket.io-stream');
const logger = winston.createLogger({
level: 'info',
transports: [
ne... |
102a46a6896886db79fc4356dcbcad91a90654a5dc87d47ca0b8ddff05ce7a62 | JavaScript | 2,361 | 18 | var searchData=
[
['err_5fattempt_5foverwrite',['ERR_ATTEMPT_OVERWRITE',['../mplerror_8h.html#abf98fc9756a0b89bc270def9b6941460a6dffae7e4399228899f79e5d6a24b6a1',1,'mplerror.h']]],
['err_5fbad_5fmalloc',['ERR_BAD_MALLOC',['../mplerror_8h.html#abf98fc9756a0b89bc270def9b6941460a4129c1918852e59b869b469eae64123e',1,'mp... |
90bd822e20cd9b7fa2f8e61b115f02cd5ec6970c2da3c829c1c46bcebd2ba5f5 | JavaScript | 2,373 | 81 | 'use strict';
const http = require('http');
require('trace');
require('clarify'); // eslint-disable-line import/no-unresolved
const { spawn } = require('child_process');
const winston = require('winston');
const socketIO = require('socket.io');
const ss = require('socket.io-stream');
const logger = winston.createLogg... |
da6baac7580e558ed8720e62206608a3be6fd66d4cdb2d0e9d4acad5b088da84 | JavaScript | 2,382 | 173 | /**
* GraphQL schema fields that can be used by multiple queries or mutations
*/
const sharedFields = {
computationMetadata: `
id
computation {
dockerImage
remote {
type
dockerImage
command
}
input
}
meta {
name
description
version
... |
8aeac036b00da798661a490161ed7e043875e9d43f42f7ddbe5dc0f6576920c4 | JavaScript | 2,416 | 86 | const fs = require('fs');
const CsvReadableStream = require('csv-reader');
function parseCsvFile(file) {
return new Promise((resolve, reject) => {
try {
const inputStream = fs.createReadStream(file, 'utf8');
inputStream.on('error', error => reject(error));
const data = {};
let header = [... |
dcca547820e8016e4236c5286f3da4cdf9be70621d476e24773dea951f31aa4d | JavaScript | 2,434 | 76 | import expression from '@server/models/v1/expression.js'
import _ from 'lodash'
const getExpressionTable = async function(ctx) {
const id = ctx.params.id
const result = await expression.getExprById(id) // return query results using await function instead of a promise
ctx.body = result
}
const getExpressionTableM... |
bc933d8dbac2242eb9439f4224958bcf231e91302a3c1e45a11e2c434bfbe1ee | JavaScript | 2,440 | 59 | import { slotColor } from "./colors.js";
export const MAX_SLOTS = 6; // matches colors.js's palette length - past this, slot colors start repeating
export function makeEmptySlot(index) {
return {
id: crypto.randomUUID(),
label: "",
color: slotColor(index).swatch,
sessionId: null,
stage: null,
... |
27388542716536a2cce461341d9a0a52d3e54e216678a11bc4ad476cfdcffdea | JavaScript | 2,478 | 81 | 'use strict';
const axios = require('axios');
const fs = require('fs');
const { get } = require('lodash');
const { services } = require('coinstac-common');
const config = require('./config');
axios.defaults.baseURL = `${config.protocol}://${config.apiServer}:${config.port}${config.path}`;
const compspecUpload = (us... |
301d8f62c43d405056700b47c1043d434410f2d7c993dd1e51f8b4eaf8cf1509 | JavaScript | 2,481 | 83 | const PDFDocument = require('pdfkit');
const fs = require('fs');
const kebabCase = require('lodash/kebabCase');
const path = require('path');
const { app } = require('electron');
function humanize(str) {
let string = str;
if (str.indexOf('_') > -1) {
const frags = str.split('_');
for (let i = 0; i < frags.... |
5ec475b88eb88680ba9cb2bf34e1046bdf3a44a50bf1be8d7582655637b8da9a | JavaScript | 2,551 | 109 | import * as PIXI from "pixi.js";
import * as d3 from "d3";
const textureRadius = 12;
const textureDim = Math.round(textureRadius / 0.5) * 2;
let pointTexture = {
texture: null,
make() {
let dotCanvas = document.createElement("canvas");
d3.select(dotCanvas)
.attr("width", textureDim * window.devicePi... |
6b4d0c614e9d2062edf43292e22261a97516fffd09b63364df9fb274fdcf488b | JavaScript | 2,553 | 81 | 'use strict';
const containerManager = require('coinstac-container-manager');
module.exports = {
/**
* Creates a computation object for a given compspec
* @param {Object} spec a compspec to use
* @param {Object} mode remote or local modes
* @param {Object} runId current run
* @param {O... |
a3047bc24f2dfb5e6060733db82738a327433ec9104159fc5f28e50861bd76d8 | JavaScript | 2,568 | 33 | var mpl_8h =
[
[ "mpl_apply_tipdata", "mpl_8h.html#a9fd3b98a7eb5f020f63e87f35b3dfe36", null ],
[ "mpl_attach_rawdata", "mpl_8h.html#af6fcf4d3c9d71685d256ca50f17dc10d", null ],
[ "mpl_attach_symbols", "mpl_8h.html#a939ba16fd369ef29b542dd1ed3276659", null ],
[ "mpl_delete_Morphy", "mpl_8h.html#ae0986d5715... |
d35102b34fb2dc1e3f3fb9a0d1e9b950941f63846940f218a24b8c073b95e5b9 | JavaScript | 2,590 | 89 | <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.2/jquery.min.js"></script>
<script type="text/javascript">
function changeImage(current) {
var imagesNumber = 20;
for (i=1; i<=imagesNumber; i++) {
if (i == current) {
document.getElementById("normal" + current).style.display = "block";
} else {
... |
25f7e59f02fb376cfaf5e94b035a46cbf07b75815dcf21309a1e1dcddab62e6b | JavaScript | 2,594 | 25 | var searchData=
[
['mpl_5fapply_5ftipdata',['mpl_apply_tipdata',['../mpl_8h.html#a9fd3b98a7eb5f020f63e87f35b3dfe36',1,'mpl.c']]],
['mpl_5fattach_5frawdata',['mpl_attach_rawdata',['../mpl_8h.html#af6fcf4d3c9d71685d256ca50f17dc10d',1,'mpl.c']]],
['mpl_5fattach_5fsymbols',['mpl_attach_symbols',['../mpl_8h.html#a939b... |
bc53cd2fbf496f3dd90ca54e4fbb2338fc1beafa3e392f6dae2bba872c6bdcfd | JavaScript | 2,597 | 91 | 'use strict';
const path = require('path');
const stream = require('stream');
const winston = require('winston');
const pify = require('util').promisify;
const mkdirp = pify(require('mkdirp'));
const readFile = pify(require('fs').readFile);
const writeFile = pify(require('fs').writeFile);
const open = pify(require('fs... |
3f7fea144936b15a8fd4c608d41f8edc1c27aeac1b9be2cc4a8a161dc1921f33 | JavaScript | 2,615 | 90 | import axios from 'axios'
const apiClient = axios.create({
baseURL: process.env.API_URL,
withCredentials: false,
headers: {
Accept: 'application/json',
'Content-Type': 'application/json'
}
})
const uploadClient = axios.create({
baseURL: process.env.API_URL,
method: 'post',
headers: {
'Content... |
9a18ff382923dc685f5d4f554f8d32d8851a13f03b497a291d5d786f051688e6 | JavaScript | 2,639 | 91 | 'use strict';
const os = require('os');
const path = require('path');
const readLastLines = require('read-last-lines');
const { Tail } = require('tail');
const serializeError = require('serialize-error');
const pify = require('util').promisify;
const access = pify(require('fs').access);
const loadConfig = require('../... |
598f88cd8b0a1315cbb34d35e43c635e58b0458ecf552d9e04397572c963b7f3 | JavaScript | 2,640 | 106 | #!/usr/bin/env node
/* eslint-disable no-console */
const { ApolloServer } = require('apollo-server-hapi');
const hapi = require('@hapi/hapi');
const Jwt = require('@hapi/jwt');
const helperFunctions = require('./auth-helpers');
const routes = require('./routes');
const { schema } = require('./data/schema');
const dat... |
2c29213be3657908190b1ec163c43f70b95487c6f6b61ef43ea8c1ec9e76a09d | JavaScript | 2,725 | 91 |
const fs = require('fs');
const path = require('path');
const tar = require('tar-fs');
const zlib = require('zlib');
const merge2 = require('merge2');
const {
readdir,
} = fs.promises;
const splitFilesFromStream = (stream, filePath, chunkSize) => {
let currentChunk = 0;
let currentChunkLen = 0;
const asyncSt... |
95ed586e0bdbdd7b56b0e21d507078edd0a7b6bfbb32e7335ab8b1e75921d093 | JavaScript | 2,731 | 88 | /* eslint-disable no-console */
const mkdirpSync = require('mkdirp').sync;
const fs = require('fs');
const path = require('path');
const os = require('os');
const unfinishedBootLog = {
error(content) { console.error(content); },
};
const logLocations = {
darwin: 'Library/Logs/coinstac/',
freebsd: '.config/coinst... |
e0f9db3f11db0fb6c302d46ca15bbe23d1aeb76457666c973a5ed6b9d2f42996 | JavaScript | 2,811 | 52 | // per-slot palette for the Longitudinal workspace - each timepoint gets its
// own hue family so its 3D overlays (HC ring/BPD/OFD, metopic contour,
// frontal bossing profile) and its legend swatch all read as the same
// "thing" across the comparison, distinct from every other slot's. slot 0
// (baseline) is warm, sl... |
5d5b6edb744e197a68eca5ba6020ad467697b3bcd2b3430abbf49fa57aeb8bfa | JavaScript | 2,847 | 25 | var searchData=
[
['save_5fcell_5fresults',['save_cell_results',['../namespacetinaui.html#a14be7613daa9e4931cb00587eb6c8710',1,'tinaui']]],
['save_5fnetwork',['save_network',['../namespacetinaui.html#a423c6238b85a400464a8aef01a5e79c6',1,'tinaui']]],
['save_5fquantified',['save_quantified',['../namespacetinaui.htm... |
ace9ecb19e187529c76288fcf7ab38856119f35a396e6f0f8ff1c0e4667ea909 | JavaScript | 2,875 | 97 | // Code from https://github.com/Twinklebear/webgl-volume-raycaster
// blog: https://www.willusher.io/webgl/2019/01/13/volume-rendering-with-webgl
export const vertShader =
`#version 300 es
#line 4
layout(location=0) in vec3 pos;
uniform mat4 proj_view;
uniform vec3 eye_pos;
uniform vec3 volume_scale;
out vec3 vray_di... |
14295ce0410a213ce000d7e2d7afdb4f9806b73ab019f7e52f4c4e71d0601ae7 | JavaScript | 2,880 | 106 | export const PASSWORD_PATTERN = /^(?=.*?[A-Z])(?=.*?[a-z])(?=.*?[#?!@$%^&*-]).{8,}$/g;
export const TUTORIAL_STEPS = {
consortiumPipeline: [
{
id: 'cp-create-pipeline',
target: '#new-pipeline',
content: 'Click this button to create a pipeline',
placementBeacon: 'right',
},
],
cons... |
441e21c3794fae840d66a4cf212e29cda09f02209b4df679f311763cf55bd4ee | JavaScript | 2,891 | 4 | /*! markmap-autoloader v0.14.4 | MIT License */
/*! Adapted from MarkMap by jsDelivr */
this.markmap=this.markmap||{},function(t){"use strict";
/*! markmap-common v0.14.2 | MIT License */function n(){return n=Object.assign||function(t){for(var n=1;n<arguments.length;n++){var e=arguments[n];for(var a in e)Object.protot... |
428cb6506335de3eab5d28e516988ee438d10787885d977f3b9b572799cf7f87 | JavaScript | 2,910 | 97 | 'use strict';
require('trace');
require('clarify');
const { spawn } = require('child_process');
const winston = require('winston');
const WS = require('ws');
const logger = winston.createLogger({
level: 'info',
transports: [
new winston.transports.Console({ format: winston.format.cli() }),
],
});
process.on... |
9711d11f38eafa2db312d6d79aea66d0f3292af5950cef172151c54bd5bbffad | JavaScript | 2,948 | 127 | const EXPERIMENT_STEP_TYPE_INSTRUCTION = 1;
const EXPERIMENT_STEP_TYPE_TRAINING_WITHOUT_CHANGE = 2;
const EXPERIMENT_STEP_TYPE_TRAINING_WITH_LABELED_CHANGES = 3;
const EXPERIMENT_STEP_TYPE_TRAINING_WITH_HIDDEN_CHANGES = 4;
const EXPERIMENT_STEP_TYPE_MAIN_TASK = 5;
const EXPERIMENT_STEP_TYPE_REVIEW_INSTRUCTION = 6;
cons... |
73fa198a2bd704b670b77988c24dd6962abb5835e0b6addb602384345e7280c4 | JavaScript | 2,974 | 67 | // builds a short, human-readable filename for a mean-shape export from the
// active FilterBar filters (see FilterBar.jsx for the filter shape) - so a
// saved file names itself after whatever the user actually stratified to,
// without them having to remember and retype it (e.g. filtering to
// diagnosis=trigonocepha... |
a15934c691a64634b4576b0cb231ae973312343bc8af5810ebf7e98afbe1fe44 | JavaScript | 2,984 | 106 | (function() {
'use strict';
var timeParsePatterns = [
// 9
{
re: /^\d{1,2}$/i,
handler: function(bits) {
if (bits[0].length === 1) {
return '0' + bits[0] + ':00';
} else {
return bits[0] + ':00';
... |
0bd41dc61936631218ea96744601014eb3e83f866dcd00527b5ec7315bd3d54f | JavaScript | 3,021 | 104 | /**
* A helper class that manages retrieving elements by color ID from a framebuffer.
* This is the color-picking trick (see http://www.opengl-tutorial.org/miscellaneous/clicking-on-objects/picking-with-an-opengl-hack/)
*/
import * as PIXI from "pixi.js";
import { ColorIDMap } from "../utils/helpers";
const Compon... |
f6b03aae2b9512cdb669e4f11a028daf2292b31c9cb35be938eecb6fd0b3a4ef | JavaScript | 3,058 | 135 | export default {
mode: 'universal',
/*
** Headers of the page
*/
head: {
title: process.env.npm_package_name || '',
meta: [
{ charset: 'utf-8' },
{ name: 'viewport', content: 'width=device-width, initial-scale=1' },
{
hid: 'description',
name: 'description',
... |
84622a1e41e084f9846719eed5517688a37cd92f9bf878cc489eb9921d391e28 | JavaScript | 3,087 | 32 | var searchData=
[
['morphy_5ft',['Morphy_t',['../struct_morphy__t.html',1,'']]],
['mpl_2eh',['mpl.h',['../mpl_8h.html',1,'']]],
['mpl_5fapply_5ftipdata',['mpl_apply_tipdata',['../mpl_8h.html#a9fd3b98a7eb5f020f63e87f35b3dfe36',1,'mpl.c']]],
['mpl_5fattach_5frawdata',['mpl_attach_rawdata',['../mpl_8h.html#af6fcf4... |
616925090ced20bf452e092208d5efb5a9070ce88039682b9b2886b922b63e4a | JavaScript | 3,091 | 107 | const AWS = require('aws-sdk');
const { isArray } = require('lodash');
const { ObjectID } = require('mongodb');
const helperFunctions = require('../auth-helpers');
const database = require('../database');
const {
eventEmitter,
RUN_CHANGED,
} = require('../data/events');
const s3 = new AWS.S3({
accessKeyId: proce... |
ead3bc8fad11c45c400b81c75df4788bfcc85b6a7df39c9d9735e1155e05ff34 | JavaScript | 3,097 | 115 | /* eslint-disable import/no-unresolved */
// @ts-check
// Note: type annotations allow type checking and IDEs autocompletion
const lightCodeTheme = require('prism-react-renderer/themes/github');
const darkCodeTheme = require('prism-react-renderer/themes/dracula');
/** @type {import('@docusaurus/types').Config} */
con... |
8ca8644bee9d49d0979c0c085f3ee176cae2317305e88016835d0f6e35f33fa1 | JavaScript | 3,109 | 101 | import {
ApolloClient, ApolloLink, concat,
HttpLink, InMemoryCache, split,
} from '@apollo/client';
import { onError } from '@apollo/client/link/error';
import { WebSocketLink } from '@apollo/client/link/ws';
import { getMainDefinition } from '@apollo/client/utilities';
import { ipcRenderer } from 'electron';
impor... |
ea6f24671237fea0e80da2080c33815eef4f58750a6946c1a775b28476a4a5a9 | JavaScript | 3,110 | 92 | 'use strict';
import test from 'ava';
const request = require('request-stream');
const { createReadStream, readFileSync, unlink } = require('fs');
const resolvePath = require('path').resolve;
const unzip = require('unzipper');
const server = require('../server-http');
test.before(() => {
return server.start({ port... |
e725e9292c337653dd52cc42bbfcab6136baf2626e3720f93f3b3a91b6927a22 | JavaScript | 3,161 | 6 | (function(a){var f;a.fn.actions=function(e){var b=a.extend({},a.fn.actions.defaults,e),g=a(this),k=!1,l=function(){a(b.acrossClears).hide();a(b.acrossQuestions).show();a(b.allContainer).hide()},m=function(){a(b.acrossClears).show();a(b.acrossQuestions).hide();a(b.actionContainer).toggleClass(b.selectedClass);a(b.allCon... |
f5ee3c90daa638e9e0582f5938da85bf5169969770074d557bd1d082692bc3d9 | JavaScript | 3,244 | 164 | const sharedFields = require('./shared-fields');
const mutations = {
addComputation: `
{
addComputation(computationSchema: $computationSchema) {
${sharedFields.computationMetadata}
}
}
`,
addUserRole: `
{
addUserRole(userId: $userId, table: $table, doc: $doc, role: $role, ro... |
40da9778af7b1b989884af0a3c6f814a84e0f05521fe903eb747e455d2fa280d | JavaScript | 3,298 | 121 | /**
* Configure Electron's `BrowserWindow` -- the user interface.
*
* {@link http://electron.atom.io/docs/tutorial/quick-start/}
*/
'use strict';
const electron = require('electron');
const electronDefaultMenu = require('electron-default-menu');
const path = require('path');
const url = require('url');
const {
app... |
1123504f854d625aefc5e0b191a9aca1dd14aaab5aa12a07e15d38485394fafc | JavaScript | 3,326 | 75 | import * as THREE from "three";
// forehead-bulge angle, live on the mesh - the Analysis workspace's frontal
// bossing visualization, sibling to measurementsLayer.js/metopicOverlay.js.
// unlike those two (mutually exclusive - HC/BPD/OFD only ever shows for
// cranial, heatmap/metopic only for facial), this one is co... |
2b033c3a3d212bcb489e206bd2305ef8a6fbace93ae95b32e94a0afc95c300b8 | JavaScript | 3,451 | 134 | /* eslint-disable no-console, import/no-extraneous-dependencies */
const chai = require('chai');
const chaiAsPromised = require('chai-as-promised');
const path = require('path');
const fs = require('fs').promises;
const { _electron: electron } = require('playwright');
const { execSync } = require('child_process');
con... |
6d8bb34d7e6d6e55c05a4335e74d887d6161badefefecf8386d7b93016d559e5 | JavaScript | 3,554 | 30 | var searchData=
[
['save_5fcell_5fresults',['save_cell_results',['../namespacetinaui.html#a14be7613daa9e4931cb00587eb6c8710',1,'tinaui']]],
['save_5fnetwork',['save_network',['../namespacetinaui.html#a423c6238b85a400464a8aef01a5e79c6',1,'tinaui']]],
['save_5fquantified',['save_quantified',['../namespacetinaui.htm... |
bbe0da6bf5ed2d2c706a94c7a2738e082c3d29c2aa186dae5fabd33b532bc9a2 | JavaScript | 3,669 | 135 | import * as PIXI from 'pixi.js';
import { normalizeVector } from '../utils/helpers';
export class PixiLineDecoration extends PIXI.Graphics {
decoration = null;
lastColor = null;
colorHex = null;
constructor(dec) {
super();
this.decoration = dec;
}
update() {
let x = this.decoration.attr('x');... |
383605dc95c90e0eb6adef597ce3fec55ebcc901e96d8c61b209eb00c19e2698 | JavaScript | 3,678 | 144 | 'use strict';
const path = require('path');
const webpack = require('webpack');
const pkg = require('./package.json');
const port = 3000;
const config = {
bail: true,
devServer: {
host: 'localhost',
historyApiFallback: true,
hot: true,
port,
},
entry: {
app: [path.join(__dirname, 'app', '... |
bcb8f5a5ae81a82c57f234bbff0e8d9b30207b67ca23155046c1e2c039b6af0f | JavaScript | 3,686 | 150 | import { MeshoptEncoder as encoder } from './meshopt_encoder.js';
import { MeshoptDecoder as decoder } from './meshopt_decoder.mjs';
import { performance } from 'perf_hooks';
process.on('unhandledRejection', (error) => {
console.log('unhandledRejection', error);
process.exit(1);
});
function bytes(view) {
return n... |
91fb5867d117a830d2c62078a30501d1a2a5d50dd7cad4b27fd0124328404a38 | JavaScript | 3,751 | 124 | import assert from 'assert/strict';
import { MeshoptTangents as tangents } from './meshopt_tangents.js';
process.on('unhandledRejection', (error) => {
console.log('unhandledRejection', error);
process.exit(1);
});
var tests = {
tangentsBasic: function () {
// unindexed quad with matching corner data for shared d... |
d8ed221535f71ba61d5f26b30e8670e3da91fdc9da41694ac900629483e3abce | JavaScript | 3,765 | 158 | module.exports = {
local: {
meta: {
name: 'local test',
id: 'coinstac-local-test',
version: 'v1.0.0',
repository: 'github.com/user/computation.git',
description: 'a test that sums the last two numbers together for the next',
},
computation: {
type: 'docker',
docke... |
8640facdf2288194f349cbd265d204aebd534e03c16cd178edb3c216e30a8649 | JavaScript | 3,814 | 76 | // shared by CompareTab.jsx (one static heatmap per ready slot) and the 3D
// Morphing tab (lerps between two consecutive stages' own heatmaps across
// each leg, the same way it already lerps mesh vertices and measurement
// overlay points) - both need the exact same thing: "each stage's own
// per-vertex distance (mm... |
073a9f659742d4801a1149533aca0d186e78631fc7167b5cb81346ae6087bdf5 | JavaScript | 3,872 | 76 | import { useEffect, useRef } from "react";
// synchronizes OrbitControls state (position/target) across N independent
// <Viewer> instances - rotating/panning/zooming any one of them mirrors the
// same camera state into every other linked viewer, the Longitudinal
// workspace's "rotate one, both rotate" requirement. ... |
a3c670f20532fcc254faba5e199448b7d94ee0908c35fa401eda4da1da9ff1cc | JavaScript | 4,027 | 121 | 'use strict';
import { ipcRenderer } from 'electron';
import { applyAsyncLoading } from './loading';
import { notifyError, notifySuccess } from './notifyAndLog';
// Actions
export const CLEAR_DOCKER_OUTPUT = 'CLEAR_DOCKER_OUTPUT';
export const GET_LOCAL_IMAGES = 'GET_LOCAL_IMAGES';
export const GET_DOCKER_STATUS = '... |
4e646c8a1946fc28d14bc6f18656be8022e6b52391e3442e30367a2ac06476f9 | JavaScript | 4,052 | 110 | import * as THREE from "three";
// forehead contour + fitted parabola + regions + frontal-angle construction,
// live on the mesh - the Analysis workspace's metopic/frontal-shape
// visualization, sibling to measurementsLayer.js's HC-ring/heatmap overlays.
// everything here lives on the y = slice_height plane (metopi... |
a6fa1af6ffd2ec785b43997641cc7cae8341e17171bcd65d302f924b58f64591 | JavaScript | 4,270 | 121 | 'use strict';
const Pipeline = require('coinstac-pipeline');
const path = require('path');
const { fork } = require('child_process');
const exitHook = require('exit-hook');
const portscanner = require('portscanner');
/**
* Starts a simulator run with the given pipeline spec
*
* @param {Object} spec ... |
cc202169956eaa3209e7e7d7e57a8b3d47dc268195df005aa4e093a264461e1f | JavaScript | 4,342 | 175 | const MiniCssExtractPlugin = require('mini-css-extract-plugin');
const path = require('path');
const version = require('./package.json').version;
module.exports = module.exports = (env, options) => {
const prod = options.mode === 'production';
// Custom webpack rules
const rules = [
{
test: /\.svelte$... |
40afa6332801b4e78f244a7c8cbcb0c919118329a6823c8c4f078e0272cfe170 | JavaScript | 4,397 | 171 | import _ from 'lodash'
import AdService from '~/services/AdService.js'
export const state = () => ({
dialog: [],
dataset: [],
datasets: [],
dialogDataset: [],
publication: [],
deMeta: [],
deAllMeta: [],
cellType: [],
de: [],
deGene: [],
dimension: [],
spatialDimension: [],
expression: [],
e... |
50f9e410755d952f73711c01ad5398e4b584363006f5310f8600187044f0e034 | JavaScript | 4,450 | 155 | /* eslint-disable no-console */
const { gql } = require('@apollo/client/core');
const { queries } = require('coinstac-graphql-schema');
const get = require('lodash/get');
const path = require('path');
const fs = require('fs').promises;
const parseHeadlessClientConfig = require('./parse-headless-client-config');
const m... |
77d2f63eb527ca9e8261f94fa2dc92e8d98bae4a1895fe9927e6406474e85973 | JavaScript | 4,460 | 171 | import { ipcRenderer } from 'electron';
import {
get, indexOf, keys,
setWith, take, values,
} from 'lodash';
import { v4 as uuidv4 } from 'uuid'; // eslint-disable-line
export function isPipelineOwner(permissions, owningConsortium) {
return indexOf(permissions.consortia[owningConsortium], 'owner') !== -1;
}
exp... |
cb8db4c2f871fb449a3aa4e10a0a87bfd3c090c8afafd357211bb72505b48163 | JavaScript | 4,508 | 172 | const helperFunctions = require('../auth-helpers');
module.exports = [
{
method: 'POST',
path: '/authenticate',
config: {
auth: false,
pre: [
{ method: helperFunctions.validateUser, assign: 'user' },
],
handler: (req, h) => {
req.pre.user.passwordHash = undefined;
... |
5c43c3523d866f5f6feaa09b17e41ca9e354b916f85aaf8df7d1194bfaefce67 | JavaScript | 4,588 | 270 | const sharedFields = require('./shared-fields');
const queries = {
allDockerImages: `
{
fetchAllComputations {
id
computation {
dockerImage
}
meta {
name
}
}
}
`,
computationChanged: `
{
computationChanged(computationId: $compu... |
850fe3945816a44156891dd394bd28440844d1d1db28a9a6bc0a5ec45125a98e | JavaScript | 4,600 | 180 | import _ from 'lodash'
import AdService from '~/services/AdService_v2.js'
export const state = () => ({
dialog: [],
dataset: [],
datasets: [],
dialogDataset: [],
publication: [],
deMeta: [],
deAllMeta: [],
cellType: [],
de: [],
svg: [],
deGene: [],
dimension: [],
spatialDimension: [],
expre... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.