content
stringlengths
22
815k
id
int64
0
4.91M
def mass_timeseries(cur, facility, flux): """Returns dictionary of mass timeseries of each isotope at a facility. Parameters ---------- cur : sqlite cursor sqlite cursor facility : str name of facility flux : str direction of flux Returns ------- masstime : d...
60,500
def get_credentials(account_id): """ Using STS assume role to obtain the temporary credentials of another AWS account returns dict: 'error' : None if credentials is acquired successfully. Otherwise, it contains error message """ # get the cross account role name cross_account_role_n...
60,501
def generate_config(context): """ Creates the Cloud SQL instance, databases, and user. """ properties = context.properties res_name = properties.get('name', context.env['name']) project_id = properties.get('project', context.env['project']) instance = get_instance(res_name, project_id, properties)...
60,502
def post_exposure(): """ Upload an exposure resource --- description: Uploads an exposure resource by posting an exposure tar file. The tar file can be compressed or uncompressed. produces: - application/json responses: 200: description: The exposure summ...
60,503
def loads(strng, root_name=DEFAULT_ROOT_NAME, single_root_node=False, id_mapper=None): """load a config from a string. Args: strng: the string containing the config file root_name: the tag for the top-level node that is added implicitly single_root_node: if true, no implicit t...
60,504
def command_search(): """Query the Microsoft Academic database.""" # File containing the collection # [alias: -c] collection: Option & PapersFile = default(None) # Researchers file (JSON) # [alias: -r] researchers: Option & ResearchersFile = default(None) # Command to run on every pap...
60,505
async def test_no_key_in_payload(opsdroid, connector, mock_api, caplog): """Test if payload doesn't contain 'action' key.""" @match_event(github_event.PROpened) async def test_skill(opsdroid, config, event): assert event.connector.name == "github" assert event.target == "opsdroid/opsdroid-a...
60,506
def write_cross_tab( meta_fp: str, cat_pd: pd.DataFrame, cat_vars: list, train_samples: pd.Series, train_col: str, rep_d: dict): """ Parameters ---------- meta_fp : str cat_pd : pd.DataFrame cat_vars : list train_samples : pd.Series train_...
60,507
def create_server_arguments( configuration: configuration_module.Configuration, start_arguments: command_arguments.StartArguments, ) -> Arguments: """ Translate client configurations and command-line flags to server configurations. This API is not pure since it needs to access filesystem to fil...
60,508
def getLabels(kmeans, options): """@brief Labels all centroids of kmeans object to their color names @param kmeans KMeans object of the class KMeans @param options DICTIONARY options necessary for labeling @return colors LIST colors labels of centroids of kmeans object @return ind ...
60,509
def replace_surrogate_encode(mystring, exc): """ Returns a (unicode) string, not the more logical bytes, because the codecs register_error functionality expects this. """ decoded = [] for ch in mystring: # if PY3: # code = ch # else: code = ord(ch) # ...
60,510
def _heom_state_dictionaries(dims, excitations): """ Return the number of states, and lookup-dictionaries for translating a state tuple to a state index, and vice versa, for a system with a given number of components and maximum number of excitations. Parameters ---------- dims: list ...
60,511
def get_file_names(path): """ Given a dir path, returns a list of files in this dir, not includes its child dir :param path: :return: """ names = [] if os.path.exists(path): for (dirpath, dirnames, filenames) in os.walk(path): names.extend(filenames) ...
60,512
def _get_num_els_in_scene_range(zarr_dataset: ChunkedDataset, scene_index_start: int, scene_index_end: int) -> dict: """ Get numbers of scenes, frames, agents, tl_lights in a set of scene in a zarr Args: zarr_dataset (ChunkedDataset): zarr dataset to use for computing number of elements scen...
60,513
def fill_nulls_w_own_distribution(column: Series) -> Series: """Finds the distribution of filled values in a column and fill its nulls with the same distribution :param pandas.Series column: column to fill nulls :return pandas.Series: column with nulls filled """ # Copy to avoid direct changes in ...
60,514
def compute_data_term_gradient_vectorized(warped_live_field, canonical_field, live_gradient_x, live_gradient_y, scaling_factor=10.0): """ Vectorized method to compute the data term gradient :param live_gradient_x: x-component of the gradient of the warped_live_field...
60,515
def find_mount(path: Path): """Given a path, derive its mountpoint path""" mount_path = path while not mount_path.is_mount(): mount_path = mount_path.parent logger.debug(f"Found mount for {path}: {mount_path}") return mount_path
60,516
def pid(db, record): """File system location.""" return recid_minter(record.id, record)
60,517
def find_start_end(cus_list, pattern) -> Tuple: """ Find the start & end of pattern in cus_list. If none, return 0,0. :param cus_list: :param pattern: :return: """ for i in range(len(cus_list)): if cus_list[i] == pattern[0] and cus_list[i:i + len(pattern)] == pattern: ret...
60,518
def timecoverage(): """ Time intervals of GLDAS data """ return [ ('All Available Times', 'alltimes'), (2019, 2019), (2018, 2018), (2017, 2017), (2016, 2016), (2015, 2015), (2014, 2014), (2013, 2013), (2012, 2012), (2011, 20...
60,519
def make_mapper(mapper_class): """Wrap a mapper. This makes a mapper wrapped with a few convenient tools for managing mappers with scalar bars in a consistent way since not all mapper classes have scalar ranges and lookup tables. """ class MapperHelper(mapper_class): """A helper that d...
60,520
def CDL3LINESTRIKE(data: xr.DataArray) -> xr.DataArray: """ Three-Line Strike (Pattern Recognition) Inputs: data:['open', 'high', 'low', 'close'] Outputs: double series (values are -1, 0 or 1) """ return multiple_series_call(talib.CDL3LINESTRIKE, data, ds.TIME, ds.FIELD, [f.OPEN...
60,521
def check_ess_certid(cert: x509.Certificate, certid: Union[tsp.ESSCertID, tsp.ESSCertIDv2]): """ Match an ``ESSCertID`` value against a certificate. :param cert: The certificate to match against. :param certid: The ``ESSCertID`` value. :return: ``True`` ...
60,522
def passx_decode(passx): """decode the obfuscated plain text password, returns plain text password""" return bz2.decompress(base64.b64decode(passx.encode("ascii"))).decode("ascii")
60,523
def main(): """docstring for main""" try: r = requests.get('https://am.i.mullvad.net/json') json_data = r.json() if json_data['mullvad_exit_ip']: print("You are connected to Mullvad!") else: print("You are NOT connected to Mullvad!") if 'json' in ...
60,524
def cloudfront_restriction_type(restriction_type): """ Property: GeoRestriction.RestrictionType """ valid_values = ["none", "blacklist", "whitelist"] if restriction_type not in valid_values: raise ValueError( 'RestrictionType must be one of: "%s"' % (", ".join(valid_values)) ...
60,525
def bookmark(ctx): """Bookmark group. Uses [Caching](/polyaxon_cli/introduction#Caching) Examples: \b ```bash $ polyaxon group bookmark ``` \b ```bash $ polyaxon group -g 2 bookmark ``` """ user, project_name, _group = get_project_group_or_local(ctx.obj.get('proje...
60,526
def variance_scaling_initializer(tensor, factor=2.0): """ Variance scaling initializing using FAN_AVG, similar to the one in TF :param tensor: A tensor of arbitrary shape. :param fan_in: int :param fan_out: int :param factor: A scalar, the scaling factor. :returns: A tensor with the same shape ...
60,527
def test_limiter_other_route(client, limit): """ test limiter returns 200 on route where limit not exceeded & returns 429 status code if limit exceeded """ # make get requests more than the limit for _ in range(limit * 2): # get page response = client.get("/") # make request ...
60,528
def convert_single_example(example, tokenizer, is_training): """Converts a single NqExample into a list of InputFeatures.""" tok_to_orig_index = [] orig_to_tok_index = [] all_doc_tokens = [] features = [] for (i, token) in enumerate(example.doc_tokens): orig_to_tok_index.append(len(all_doc_tokens)) ...
60,529
def calcCog(argument: Union[str, list]) -> Tuple[float, float, float]: """ calculates the Center of Geometry of a given selection or list of atoms Args: argument (str or list): either a PyMOL-selection name or a List of atoms Returns: Tuple[float, float, float]: 3D-coords of CoG ""...
60,530
def IMcleaner(dpath, site, scheck, coords, verbose, test = False, dsinfom = "LANDSAT_5_7_8"): """ Function to clean the data up and make the visualisation better """ # ========== setup the key params ========== SF = 0.0001 # Scale Factor fnames = scheck["fnames"] spath = dpath + "UoL/FIREFLIES/VideoEx...
60,531
def isort( config: c2cciutils.configuration.ChecksIsortConfig, full_config: c2cciutils.configuration.Configuration, args: Namespace, ) -> bool: """ Run isort check on all files including Python files without .py extension. config is like: ignore_patterns_re: [] # list of regular expressio...
60,532
def create_image_server(): """ Create flask image debug server. Warning! This is a very hacky flask server. Make sure to only run this once as it uses global stare Returns: Dictionary into which you can insert images with string keys """ threading.Thread(target=lambda: app.run(host="0....
60,533
def dump_args(of, st, ps, yr, mns, tstep, back, urgent): """ Create arguments dictionary and dump to json file """ tstamp = datetime.now().strftime("%Y%m%d%H%M%S") fname = f'era5_request_{tstamp}.json' requestdir = cfg['requestdir'] if urgent: requestdir += 'Urgent/' args = {} ...
60,534
def assembly_stats(fasta_file, min_contig_len=200): """ Get the statistis of an assembly in a fasta file :param fasta_file: :return: """ ll = [] contig_count = 0 for seq in read_sequence_file(fasta_file): contig_count += 1 if len(seq) >= min_contig_len: ll.app...
60,535
def task_ide(clueweb_url=''): """ Replicate results for task identification experiments """ mgbc_task_ide(clueweb_url) ngt_task_map()
60,536
def test_process_with_set_score_event(): """Test process() with SET_SCORE event.""" parent = mock.MagicMock() event = state_machine.Events.SET_SCORE name = 'calvin' value = 'value' parameters = {'name': name, 'value': value} with mock.patch( 'app.state_machine.IdleState.process_set_...
60,537
def find_peaks(signal, fs, min_separation=270, window_width=2500, noise_level=1.25): """Find peaks from pulse oximeter or ECG. Args: signal: Pulse oximeter or ECG data. fs: Sampling frequency (Hz) of the signal. min_separation: Strict minimum time between peaks (ms). window_widt...
60,538
def evaluate_rm_gold(prediction, ground_truth): """ Evaluation matrix. :param prediction: a dictionary of labels. e.g {0:[1,0],1:[2],2:[3,4],3:[5,6,7]} :param ground_truth: a dictionary of labels :return: """ pos_gt = 0.0 pos_pred = 0.0 true_pos = 0.0 for i in ground_truth: ...
60,539
def test_invalid_renewal_missing_debtor(): """Assert that an invalid renewal statement fails - base debtor and statement reg number are missing.""" statement = copy.deepcopy(RENEWAL_STATEMENT) del statement['baseDebtor'] del statement['createDateTime'] del statement['renewalRegistrationNumber'] ...
60,540
def is_git_bundle(path: Path) -> bool: """Indicate if a path is a valid git bundle.""" with TemporaryDirectory(prefix=f"{__name__}.is_git_bundle.") as dirname: with local.cwd(dirname): git("init") return bool(git["bundle", "verify", path] & TF)
60,541
def test_image_has_been_saved(datadir, image): """ Ensure that 'out.jpg' has been saved to the choice directory """ user_image = ColorDetect(image) user_image.get_color_count(color_count=1) file_name = "out.jpg" user_image.save_image(location=datadir, file_name=file_name) assert Path(dat...
60,542
def find_file(path, ext, index=0, sort='getctime'): # unused """ Search files by extension, sort by time created and return indexed file. """ files = [x for x in os.listdir(path) if x.endswith(ext)] files = sorted(files, key=lambda x: os.path.getctime(os.path.join(path, x)), reverse=True) new_file = os...
60,543
def importCachingPolicyManager(context): """Import caching policy manager settings from an XML file. """ sm = getSiteManager(context.getSite()) tool = sm.queryUtility(ICachingPolicyManager) if tool is None: logger = context.getLogger('cachingpolicies') logger.debug('Nothing to import...
60,544
def checksum_file(summer, path): """ Calculates the checksum of the file 'path' using the provided hashlib digest implementation. Returns the hex form of the digest. """ with open(path, "rb") as f: # Read the file in 4KB chunks until EOF. while True: chunk = f.read(4096) if not chunk: ...
60,545
def camel_case(value): """Convert an identifier to CamelCase""" return "".join(ele.title() for ele in value.split("_"))
60,546
def PlotPD (inUV, PDDict, plotfile, err, title="plot"): """ Plot array of PD elipticities and orientations * inUV = Obit UV data with tables * fitDict = dict returned by ExtractPD with entries 'Elip1' array of elipticities poln 1 in deg 'Ori1' array of orientations poln 1 in deg 'E...
60,547
def test_ap_open_disable_enable(dev, apdev): """AP with open mode getting disabled and re-enabled""" hapd = hostapd.add_ap(apdev[0]['ifname'], { "ssid": "open" }) dev[0].connect("open", key_mgmt="NONE", scan_freq="2412", bg_scan_period="0") for i in range(2): hapd.request("DI...
60,548
def parallelize (imgs, func, cores=2): """ Execute a function for each image in parallel. This function assumes 'imgs' is multi-frames of grayscale images for the current version. Parameters ---------- imgs : numpy.ndarray (3d) or list of numpy.ndarray(2d) Input multi-frame images. ...
60,549
def getter_function_spectrum(filename): """ partial does not use kwargs so our options are limitted here """ return Spectrum(filename=filename, is_ucd=False)
60,550
def cov_cluster_robust(jac, hess, design_info): """Cluster robust standard errors. A cluster is a group of observations that correlate amongst each other, but not between groups. Each cluster is seen as independent. As the number of clusters increase, the standard errors approach robust standard errors...
60,551
def fix_time_units( timeunits ): """Sometimes we get time units which aren't compatible with cdtime. This function will (try to) fix them. The input argument is a string, e.g. "months since Jan 1979" and the return value is another string, e.g. "months since 1979-01-09 00:00:00". If no better string c...
60,552
def binary_encoding(string, encoding = 'utf-8'): """ This helper function will allow compatibility with Python 2 and 3 """ try: return bytes(string, encoding) except TypeError: # We are in Python 2 return str(string)
60,553
def get_all_overlays_config(self) -> list: """Get all configured overlays in Orchestrator .. list-table:: :header-rows: 1 * - Swagger Section - Method - Endpoint * - overlays - GET - /gms/overlays/config :return: Returns list of dictionaries...
60,554
def load_densityoperator(filename): """ Load a C++QED state vector file from the given location. Returns a tuple with a list of densityoperators and a list of times. *Usage* >>> svs,times = load_statevector("ring.sv") :param filename: Path to the C++QED state vector file that should be loade...
60,555
def pending(): """ Display pending reviews. These are reviews that were submitted, but the user hasn’t responded to the confirmation email yet. They are automatically purged after 24 hours. """ if app_unavailable(): return render_template('app_unavailable.html', result=Markup(get_reason())) hea...
60,556
def format_directory_path(path: str) -> str: """Replaces windows style path seperators to forward-slashes and adds another slash to the end of the string. """ if path == ".": return path formatted_path = path.replace('\\', '/') if formatted_path[-1] is not '/': formatted_path += ...
60,557
def movie(input, output, fps=30, conversion_method="first", split=None, keep=None, cut=None, trim=None, scale_conversion=0, clip_start=0, clip_end=0, scalebar=False, scalebar_length=None, timestamps=None): """ Writes images to an mp4 video file :param file_path: Path to output video, mus...
60,558
def average_gradients(tower_grads): """Calculate the average gradient for each shared variable across all towers. Note that this function provides a synchronization point across all towers. Args: tower_grads: List of lists of (gradient, variable) tuples. The outer list is over individual gradients. ...
60,559
def voter_count_doc_view(request): """ Show documentation about voterCount """ url_root = WE_VOTE_SERVER_ROOT_URL template_values = voter_count_doc.voter_count_doc_template_values(url_root) return render(request, 'apis_v1/api_doc_page.html', template_values)
60,560
def plot_histogram(hist, width=0.9, title='', xlabel=None, datetime_format="%b %Y", labels=None, color=None, alpha=None, normalize=True, percent=False, padding=0.03, num_labels=24, formatter=None, ylabel_precision=2, resolution=3, figsize=None,...
60,561
def find_file_in_path(filename): """ Finds |filename| by searching the environment paths """ path_delimiter = ';' if is_windows else ':' for env_path in os.environ['PATH'].split(path_delimiter): full_path = os.path.join(env_path, filename) if os.path.isfile(full_path): return ful...
60,562
def __lobatto__(alpha,beta,xl1,xl2): """ Compute the Lobatto nodes and weights with the preassigned node xl1,xl2 Inputs: alpha - recursion coefficients beta - recursion coefficients xl1 - assigned node location xl2 - assigned node location Outputs: x...
60,563
def show_view_positive_y() -> None: """ """
60,564
def create_account(fullname, username, password): """ Function for creating a new user account """ new_user = User(fullname, username, password) return new_user
60,565
def count_futures(*args, **kwargs): """ 计数 :param args: :param kwargs: :return: """ return db_instance.count(Futures, *args, **kwargs)
60,566
def lineage(expr, container=Stack): """Yield the path of the expression tree that comprises a column expression. Parameters ---------- expr : Expr An ibis expression. It must be an instance of :class:`ibis.expr.types.Column`. container : Container, {Stack, Queue} Stack f...
60,567
def file_attribs_get(location): """Return mode, owner, and group for remote path. Return mode, owner, and group if remote path exists, 'None' otherwise. """ if file_exists(location): fs_check = run('stat %s %s' % (location, '--format="%a %U %G"')) (mode, owner, group) = fs_check.split(' ') return {'mode': mo...
60,568
async def git(ctx): """Gives link to the bot's github page.""" if can_answer(ctx): msg = "https://github.com/Eerolz/launchbot" await ctx.send(msg)
60,569
def upsert_sql_from_field_value_dict(schema_table: SchemaTable, field_value_dict: Dict[Field, Any], conflict_field_list: List[Field]) -> sql.Composable: """ Takes a schema table, a dict mapping Fields to values, and a list of fields to check for conflicts on and creates ...
60,570
def in_date(day, *dates): """check if day is in dates list or date :param day: date :param dates: list of dates or date :return: true if in, otherwise false """ the_date = int(int_date(day) % 100) return _in_range_or_equal(the_date, dates)
60,571
def connect_to_server(): """ Connects to the IMAP server specified in Django's settings and returns the connection object. """ c = imapclient.IMAPClient(settings.TICKETUS_MAILGW_HOST, port=getattr(settings, 'TICKETUS_MAILGW_PORT', None), us...
60,572
def jit_filter1d_function(filter_function): """Decorator for use with scipy.ndimage.generic_filter1d.""" jitted_function = numba.jit(filter_function, nopython=True) @cfunc(intc(CPointer(float64), intp, CPointer(float64), intp, voidptr)) def wrapped(in_values_ptr, len_in, out_values_ptr, len_out, data):...
60,573
def _mock_server_app(swagger_spec_path, mock_responses_path, custom_view_packages): """Create the WSGI application, post-fork.""" # Create a basic pyramid Configurator. config = Configurator(settings={ 'service_name': 'mobile_api_mock_server', 'pyramid_swagger.dereference_served_schema': T...
60,574
def get_metagen_search_body(self): """ Get the MetaGenSearchView view body. Attributes ---------- measure: str the genomic measure label. gene: str the gene name. Returns ------- html: str the MetaGenSearchView view body. """ # Get parameters measure...
60,575
def parse_websocket_frame(s): """ May raise ParseException """ try: reqs = pp.OneOrMore( websockets.WebsocketFrame.expr() ).parseString( s, parseAll=True ) except pp.ParseException as v: raise exceptions.ParseException(v.msg, v....
60,576
def session_db(pytestconfig): """Initialise the Hark sessions DynamoDB table""" if not pytestconfig.getoption("testddb"): return from . import test_controllers test_controllers.setup_module(None)
60,577
def test_tedlium_pipeline(): """ Feature: TedliumDataset Description: Read a sample Expectation: The amount of each function are equal """ # Original waveform dataset = ds.TedliumDataset(DATA_DIR_TEDLIUM_RELEASE12, RELEASE1, num_samples=1) band_biquad_op = audio.BandBiquad(8000, 200.0) ...
60,578
def csnap(df, fn=lambda x: x.shape, msg=None): """ Custom Help function to print things in method chaining. Will also print a message, which helps if you're printing a bunch of these, so that you know which csnap print happens at which point. Returns back the df to further use in chaining. ...
60,579
def start_slideshow(): """ Starting the picture frame slideshow. This starts the independent background process. :return: success """ if not process_is_running.value: # Chaning the process value process_is_running.value = True # Creating the background process for the sl...
60,580
def bundle_email(num_of_email_in_group, num_of_second_interval, to_email, to_display_name, subject, textmsg): """ Create the mailing list Args: Integer: Number of email max to group in a single mail to avoid limitation from the internet service provider I...
60,581
def runtime_restart(): """ Restarts this script :return: None """ exit(RESTART_EXIT_CODE)
60,582
def _toCamelCase(string): """Convert a snake case string (PyTorch) to camel case (PopART)""" words = string.split("_") return words[0] + "".join(w.capitalize() for w in words[1:])
60,583
def test_create_and_checkout_branch(mock_repo): """ GIVEN GitRepo is initialized with a path and repo WHEN branch.create is called with valid parameters and checkout is True THEN git.branch is called AND git.checkout is called """ repo = GitRepo(repo=mock_repo) with patch('git.repo.fun....
60,584
def out(*lines, **kwargs): """Write a set of output lines. You can use kwargs as a shorthand for mapping variables when formating all the strings in lines. """ lines = [ l % kwargs for l in lines ] sys.stdout.writelines("\n".join(lines) + "\n")
60,585
def filter_by_dates(file_list, start_date, end_date, extra_filter=None): """filter files names in 'file_list' that belongs to creation dates betweeen [start_date, end_date) start_date and end_date are given as YYYY-MM-DD""" filtered_dates = list() sd = datetime.strptime(start_date, '%Y-%m-%d').date...
60,586
def logPath(name=None): """ Returns the path of xpedite log directory :param name: Optional suffix for the log path (Default value = None) """ from xpedite.dependencies import CONFIG logpath = CONFIG.logDir if name: logpath = os.path.join(logpath, name) return logpath
60,587
def pulse(x): """Return the pulse fn of the input.""" return 2*(x % 1 < .5) -1
60,588
def instance_update(instance): """ Call update method on spanner client. Note: A ValueError exception is thrown despite the client succeeding. So, we validate the node_count and instance_display_name parameters and then ignore the ValueError exception. :param instance: a Spanner instance objec...
60,589
def nastran_tube2(DIM1: float, DIM2: float, n: float, material: pre.Material = pre.DEFAULT_MATERIAL) -> Geometry: """Constructs a circular TUBE2 section with the center at the origin *(0, 0)*, with two parameters defining dimensions. See MSC Nastran documentation [1]_ for more details. Added by JohnDN90. ...
60,590
def test_hexlify(): """ Ensure we get the expected .hex encoded result from a "good" call to the function. """ result = uflash.hexlify(TEST_SCRIPT) lines = result.split() # The first line should be the extended linear address, ox0003 assert lines[0] == ':020000040003F7' # There shoul...
60,591
def construct_bootstrap_and_latex_commands(ids, participants, rel_existing_path, static_paths, base_cmd_fmt, to_pdf_fmt): """Construct the commands to bootstrap results and latex generati...
60,592
def login(request, next_page=None, required=False, gateway=False): """Forwards to CAS login URL or verifies CAS ticket""" if not next_page: next_page = _redirect_url(request) if request.user.is_authenticated(): return HttpResponseRedirect(next_page) ticket = request.GET.get('ticket') ...
60,593
def compute_train_transform(seed=123456): """ This function returns a composition of data augmentations to a single training image. Complete the following lines. Hint: look at available functions in torchvision.transforms """ random.seed(seed) torch.random.manual_seed(seed) # Transformation...
60,594
def index_singleton_clusters(clusters): """Replace cluster labels of -1 with ascending integers larger than the maximum cluster index. """ clusters = clusters.copy() filt = clusters == -1 n = clusters.max() clusters[filt] = range(n, n + len(filt)) return clusters
60,595
def handler(event, context): """Dynamo resource""" machineTable = DynamoTable('Machines') return getMachineId(event, machineTable)
60,596
def feature_df_to_1d(feature_df, chrom_len_s): """ Converts mulitindex feature_df (chrom,start) to single numeric index running trough all chromosomes. The column 'end' is also converted. See rod_to_1d for details. """ feature_df = feature_df.copy() feature_df.index.names = (feature_df....
60,597
def list(app, host): """ Lists all available volumes """ # Print containers table = Table([ ("NAME", 40), ("CONTAINERS", 50) ]) table.print_header() # Collect volume information from containers users = {} for container in app.containers: for _, source in c...
60,598
def convert_wavelength_air2vacuum(wavelength_air): """ Convert air wavelength to vacuum wavelength Parameters ----------- wavelength_air: float Air wavelength in Angstroms Returns -------- float Vacuum wavelength in Angstroms """ sigma2 = (1e4/wavelength_air)**2....
60,599