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
# CASA - Common Astronomy Software Applications | |
# Copyright (C) 2010 by ESO (in the framework of the ALMA collaboration) | |
# Copyright (C) 2010-2013 Associated Universities, Inc. Washington DC, USA. | |
# | |
# This file is part of CASA. | |
# | |
# This program is free software: you can redistribute it and/or modify | |
# it under the terms of the GNU General Public License as published by | |
# the Free Software Foundation, either version 3 of the License, or | |
# (at your option) any later version. |
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
{ | |
"$schema": "http://json-schema.org/draft-06/schema#", | |
"definitions": { | |
"ColorMap": { | |
"enum": [ | |
"Accent", | |
"Afmhot", | |
"Autumn", | |
"Binary", | |
"Blues", |
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 DataView from "https://deno.land/x/[email protected]/_DataView.js"; | |
async function getPartialFile(url: string, byteOffset: number = 0, byteLength: number = 4096) { | |
try { | |
const headers = new Headers(); | |
headers.append("Range", `bytes=${byteOffset}-${byteOffset+byteLength - 1}`); | |
const res = await fetch(url, { mode: "no-cors", headers }); | |
return await res.blob(); | |
} catch (err) { | |
console.log(err); |
OlderNewer