metadata
dict
text
stringlengths
0
40.6M
id
stringlengths
14
255
{ "filename": "_geo.py", "repo_name": "plotly/plotly.py", "repo_path": "plotly.py_extracted/plotly.py-master/packages/python/plotly/plotly/validators/layout/_geo.py", "type": "Python" }
import _plotly_utils.basevalidators class GeoValidator(_plotly_utils.basevalidators.CompoundValidator): def __init__(self, plotly_name="geo", parent_name="layout", **kwargs): super(GeoValidator, self).__init__( plotly_name=plotly_name, parent_name=parent_name, data_clas...
plotlyREPO_NAMEplotly.pyPATH_START.@plotly.py_extracted@plotly.py-master@packages@python@plotly@plotly@validators@layout@_geo.py@.PATH_END.py
{ "filename": "proc_btch.py", "repo_name": "tdaylan/pcat", "repo_path": "pcat_extracted/pcat-master/pcat/proc_btch.py", "type": "Python" }
from __init__ import * from util import * print 'PCAT final-processing routine' boolfinl = False boolanim = False if len(sys.argv) == 1: strgsrch = '20*' boolfinl = True boolanim = True elif len(sys.argv) == 2: strgsrch = sys.argv[1] boolfinl = True boolanim = True elif len(sys.argv) == 3: ...
tdaylanREPO_NAMEpcatPATH_START.@pcat_extracted@pcat-master@pcat@proc_btch.py@.PATH_END.py
{ "filename": "try_ifort.py", "repo_name": "CosmoLike/cocoa", "repo_path": "cocoa_extracted/cocoa-main/Cocoa/external_modules/code/planck/code/plc_3.0/plc-3.1/waf_tools/try_ifort.py", "type": "Python" }
from __future__ import absolute_import from __future__ import division from __future__ import print_function import re import sys from waflib import Options import os.path as osp from waflib import Logs from waflib import Context from waflib import Errors ### common tools def show_linkline(ctx,flavour,wafname): ctx...
CosmoLikeREPO_NAMEcocoaPATH_START.@cocoa_extracted@cocoa-main@Cocoa@external_modules@code@planck@code@plc_3.0@plc-3.1@waf_tools@try_ifort.py@.PATH_END.py
{ "filename": "_width.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py2/plotly/validators/choroplethmapbox/marker/line/_width.py", "type": "Python" }
import _plotly_utils.basevalidators class WidthValidator(_plotly_utils.basevalidators.NumberValidator): def __init__( self, plotly_name="width", parent_name="choroplethmapbox.marker.line", **kwargs ): super(WidthValidator, self).__init__( plotly_name=plotly_name, parent...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py2@plotly@validators@choroplethmapbox@marker@line@_width.py@.PATH_END.py
{ "filename": "op_reg_gen.py", "repo_name": "tensorflow/tensorflow", "repo_path": "tensorflow_extracted/tensorflow-master/tensorflow/compiler/mlir/tfr/python/op_reg_gen.py", "type": "Python" }
# Copyright 2020 The TensorFlow Authors. All Rights Reserved. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applica...
tensorflowREPO_NAMEtensorflowPATH_START.@tensorflow_extracted@tensorflow-master@tensorflow@compiler@mlir@tfr@python@op_reg_gen.py@.PATH_END.py
{ "filename": "WD01.py", "repo_name": "eblur/dust", "repo_path": "dust_extracted/dust-master/astrodust/distlib/WD01.py", "type": "Python" }
""" Contains helper functions for producing a DustSpectrum object for the Weingartner & Draine (2001) dust grain size distributions. """ import numpy as np from astropy.io import ascii import os import scipy.special as special # Needed for WD01 equations from .. import constants as c from . import sizedist MW_caseA_...
eblurREPO_NAMEdustPATH_START.@dust_extracted@dust-master@astrodust@distlib@WD01.py@.PATH_END.py
{ "filename": "test_st_prompt.py", "repo_name": "simonsobs/nextline-rdb", "repo_path": "nextline-rdb_extracted/nextline-rdb-main/src/nextline_rdb/models/strategies/tests/test_st_prompt.py", "type": "Python" }
from typing import Optional, TypedDict from hypothesis import Phase, given, settings from hypothesis import strategies as st from nextline_test_utils.strategies import st_graphql_ints, st_none_or from ... import Model, TraceCall from .. import st_model_prompt, st_model_trace_call from .funcs import assert_model_pers...
simonsobsREPO_NAMEnextline-rdbPATH_START.@nextline-rdb_extracted@nextline-rdb-main@src@nextline_rdb@models@strategies@tests@test_st_prompt.py@.PATH_END.py
{ "filename": "pipelineLogger.py", "repo_name": "akleroy/phangs_imaging_scripts", "repo_path": "phangs_imaging_scripts_extracted/phangs_imaging_scripts-master/phangsPipeline/pipelineLogger.py", "type": "Python" }
import logging, os DefaultLevel = 'DEBUG' try: from . import casaStuff HasCasaLog = True except: HasCasaLog = False class PipelineLogger(logging.getLoggerClass()): """A smart logging module which will redirect to CASA logger if in CASA otherwise to screen and file.""" def __init__(self, name, l...
akleroyREPO_NAMEphangs_imaging_scriptsPATH_START.@phangs_imaging_scripts_extracted@phangs_imaging_scripts-master@phangsPipeline@pipelineLogger.py@.PATH_END.py
{ "filename": "_thickness.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py2/plotly/validators/layout/coloraxis/colorbar/_thickness.py", "type": "Python" }
import _plotly_utils.basevalidators class ThicknessValidator(_plotly_utils.basevalidators.NumberValidator): def __init__( self, plotly_name="thickness", parent_name="layout.coloraxis.colorbar", **kwargs ): super(ThicknessValidator, self).__init__( plotly_name=plotly_name, ...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py2@plotly@validators@layout@coloraxis@colorbar@_thickness.py@.PATH_END.py
{ "filename": "__init__.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py3/plotly/validators/scatterternary/marker/gradient/__init__.py", "type": "Python" }
import sys from typing import TYPE_CHECKING if sys.version_info < (3, 7) or TYPE_CHECKING: from ._typesrc import TypesrcValidator from ._type import TypeValidator from ._colorsrc import ColorsrcValidator from ._color import ColorValidator else: from _plotly_utils.importers import relative_import ...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py3@plotly@validators@scatterternary@marker@gradient@__init__.py@.PATH_END.py
{ "filename": "realmstore.py", "repo_name": "crossbario/crossbar", "repo_path": "crossbar_extracted/crossbar-master/crossbar/router/realmstore.py", "type": "Python" }
##################################################################################### # # Copyright (c) typedef int GmbH # SPDX-License-Identifier: EUPL-1.2 # ##################################################################################### from collections import deque from typing import Optional, List, Dict, A...
crossbarioREPO_NAMEcrossbarPATH_START.@crossbar_extracted@crossbar-master@crossbar@router@realmstore.py@.PATH_END.py
{ "filename": "__init__.py", "repo_name": "tiny-hippo/planetsynth", "repo_path": "planetsynth_extracted/planetsynth-main/planetsynth/support/__init__.py", "type": "Python" }
from .constants import * from .functions import *
tiny-hippoREPO_NAMEplanetsynthPATH_START.@planetsynth_extracted@planetsynth-main@planetsynth@support@__init__.py@.PATH_END.py
{ "filename": "sim_detector.py", "repo_name": "HARMONI-ELT/HSIM", "repo_path": "HSIM_extracted/HSIM-master/hsim/src/sim_detector.py", "type": "Python" }
''' Calculates detector QE, dark current, read noise ''' import os import logging import numpy as np import scipy.constants as sp from scipy.interpolate import UnivariateSpline from scipy.interpolate import interp1d from scipy import integrate from astropy.io import fits from src.modules.misc_utils import path_setup ...
HARMONI-ELTREPO_NAMEHSIMPATH_START.@HSIM_extracted@HSIM-master@hsim@src@sim_detector.py@.PATH_END.py
{ "filename": "retrieval_model.py", "repo_name": "Jingxuan97/nemesispy", "repo_path": "nemesispy_extracted/nemesispy-main/nemesispy/retrieval/TBD/retrieval_model.py", "type": "Python" }
import numpy as np import os import pymultinest from nemesispy.radtran.forward_model import ForwardModel from nemesispy.models.TP_profiles import TP_Guillot from nemesispy.common.constants import G from nemesispy.data.helper import lowres_file_paths, cia_file_path """ VMR [4.79650e-04 7.38846e-08 4.64342e-04 1.32733e-...
Jingxuan97REPO_NAMEnemesispyPATH_START.@nemesispy_extracted@nemesispy-main@nemesispy@retrieval@TBD@retrieval_model.py@.PATH_END.py
{ "filename": "__init__.py", "repo_name": "dnarayanan/powderday", "repo_path": "powderday_extracted/powderday-master/powderday/active_dust/__init__.py", "type": "Python" }
from . import dust_file_writer
dnarayananREPO_NAMEpowderdayPATH_START.@powderday_extracted@powderday-master@powderday@active_dust@__init__.py@.PATH_END.py
{ "filename": "P13.py", "repo_name": "nickhand/pyRSD", "repo_path": "pyRSD_extracted/pyRSD-master/pyRSD/rsd/power/biased/P13.py", "type": "Python" }
from .. import AngularTerm, PowerTerm, memoize class P13_mu4(AngularTerm): """ Implement P13[mu4] """ @memoize def total(self, k): b1, b1_bar = self.m._ib1, self.m._ib1_bar # velocities sigsq = self.m.sigmav_halo**2 sigsq_bar = self.m.sigmav_halo_bar**2 ...
nickhandREPO_NAMEpyRSDPATH_START.@pyRSD_extracted@pyRSD-master@pyRSD@rsd@power@biased@P13.py@.PATH_END.py
{ "filename": "ClassSmearMapping.py", "repo_name": "saopicc/DDFacet", "repo_path": "DDFacet_extracted/DDFacet-master/DDFacet/Data/ClassSmearMapping.py", "type": "Python" }
''' DDFacet, a facet-based radio imaging package Copyright (C) 2013-2016 Cyril Tasse, l'Observatoire de Paris, SKA South Africa, Rhodes University 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; eit...
saopiccREPO_NAMEDDFacetPATH_START.@DDFacet_extracted@DDFacet-master@DDFacet@Data@ClassSmearMapping.py@.PATH_END.py
{ "filename": "custom_transpose.py", "repo_name": "google/jax", "repo_path": "jax_extracted/jax-main/jax/_src/custom_transpose.py", "type": "Python" }
# Copyright 2022 The JAX Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in wri...
googleREPO_NAMEjaxPATH_START.@jax_extracted@jax-main@jax@_src@custom_transpose.py@.PATH_END.py
{ "filename": "test_00_init.py", "repo_name": "SNEWS2/snewpy", "repo_path": "snewpy_extracted/snewpy-main/python/snewpy/test/test_00_init.py", "type": "Python" }
import snewpy import unittest class TestInit(unittest.TestCase): def test_version_exists(self): self.assertTrue(hasattr(snewpy, '__version__'))
SNEWS2REPO_NAMEsnewpyPATH_START.@snewpy_extracted@snewpy-main@python@snewpy@test@test_00_init.py@.PATH_END.py
{ "filename": "starbase.3.ABC.md", "repo_name": "jbroll/starbase", "repo_path": "starbase_extracted/starbase-master/docs/starbase.3.ABC.md", "type": "Markdown" }
Starbase C Function Alphabetical Listing ---------------------------------------- - [table_coladd]( table_coladd.html) - add a column to the table. - [table_colarg]( table_colarg.html) - parse a table program column argument. - [table_colnam]( table_colnam.html) - returns the name of the column number. - [table_col...
jbrollREPO_NAMEstarbasePATH_START.@starbase_extracted@starbase-master@docs@starbase.3.ABC.md@.PATH_END.py
{ "filename": "recipe_wvlsol.py", "repo_name": "igrins/plp", "repo_path": "plp_extracted/plp-master/igrins/igrins_recipes/recipe_wvlsol.py", "type": "Python" }
from __future__ import print_function from ..procedures.sky_spec import (_make_combined_image_sky, extract_spectra_multi) from ..procedures.process_identify_multiline import identify_multiline from ..procedures.process_wvlsol_volume_fit import volume_fit from ..procedures.generate_...
igrinsREPO_NAMEplpPATH_START.@plp_extracted@plp-master@igrins@igrins_recipes@recipe_wvlsol.py@.PATH_END.py
{ "filename": "CustomWidgets.py", "repo_name": "wmpg/Supracenter", "repo_path": "Supracenter_extracted/Supracenter-master/supra/GUI/Tools/CustomWidgets.py", "type": "Python" }
import os import time from functools import partial from PyQt5.QtWidgets import * from PyQt5.QtGui import * from PyQt5.QtCore import * import pyqtgraph as pg from supra.GUI.Tools.GUITools import createLabelEditObj, createButton from matplotlib.backends.backend_qt5agg import FigureCanvasQTAgg as FigureCanvas from m...
wmpgREPO_NAMESupracenterPATH_START.@Supracenter_extracted@Supracenter-master@supra@GUI@Tools@CustomWidgets.py@.PATH_END.py
{ "filename": "result.py", "repo_name": "NannyML/nannyml", "repo_path": "nannyml_extracted/nannyml-main/nannyml/drift/multivariate/domain_classifier/result.py", "type": "Python" }
# Author: Niels Nuyttens <niels@nannyml.com> # Author: Nikolaos Perrakis <nikos@nannyml.com> # # License: Apache Software License 2.0 """Contains the results of the data reconstruction drift calculation and provides plotting functionality.""" from __future__ import annotations from collections import namedtu...
NannyMLREPO_NAMEnannymlPATH_START.@nannyml_extracted@nannyml-main@nannyml@drift@multivariate@domain_classifier@result.py@.PATH_END.py
{ "filename": "_templateitemname.py", "repo_name": "plotly/plotly.py", "repo_path": "plotly.py_extracted/plotly.py-master/packages/python/plotly/plotly/validators/layout/selection/_templateitemname.py", "type": "Python" }
import _plotly_utils.basevalidators class TemplateitemnameValidator(_plotly_utils.basevalidators.StringValidator): def __init__( self, plotly_name="templateitemname", parent_name="layout.selection", **kwargs ): super(TemplateitemnameValidator, self).__init__( plotly_name=plotly_nam...
plotlyREPO_NAMEplotly.pyPATH_START.@plotly.py_extracted@plotly.py-master@packages@python@plotly@plotly@validators@layout@selection@_templateitemname.py@.PATH_END.py
{ "filename": "README.md", "repo_name": "triton-inference-server/server", "repo_path": "server_extracted/server-main/qa/openvino_models/README.md", "type": "Markdown" }
<!-- # Copyright 2022, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # * Redistributions of source code must retain the above copyright # notice, this list o...
triton-inference-serverREPO_NAMEserverPATH_START.@server_extracted@server-main@qa@openvino_models@README.md@.PATH_END.py
{ "filename": "_xperiodalignment.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py2/plotly/validators/scatter/_xperiodalignment.py", "type": "Python" }
import _plotly_utils.basevalidators class XperiodalignmentValidator(_plotly_utils.basevalidators.EnumeratedValidator): def __init__(self, plotly_name="xperiodalignment", parent_name="scatter", **kwargs): super(XperiodalignmentValidator, self).__init__( plotly_name=plotly_name, pare...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py2@plotly@validators@scatter@_xperiodalignment.py@.PATH_END.py
{ "filename": "test_regression.py", "repo_name": "rhayes777/PyAutoFit", "repo_path": "PyAutoFit_extracted/PyAutoFit-main/test_autofit/mapper/model/test_regression.py", "type": "Python" }
from typing import List import pytest import autofit as af from autoconf.exc import ConfigException from autofit.example.model import PhysicalNFW from autofit.mapper.mock.mock_model import WithString from autofit.mapper.model_object import Identifier class SomeWeirdClass: def __init__(self, argument): s...
rhayes777REPO_NAMEPyAutoFitPATH_START.@PyAutoFit_extracted@PyAutoFit-main@test_autofit@mapper@model@test_regression.py@.PATH_END.py
{ "filename": "_shadow.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py3/plotly/validators/isosurface/colorbar/title/font/_shadow.py", "type": "Python" }
import _plotly_utils.basevalidators class ShadowValidator(_plotly_utils.basevalidators.StringValidator): def __init__( self, plotly_name="shadow", parent_name="isosurface.colorbar.title.font", **kwargs, ): super(ShadowValidator, self).__init__( plotly_name=p...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py3@plotly@validators@isosurface@colorbar@title@font@_shadow.py@.PATH_END.py
{ "filename": "compute_correction_function.py", "repo_name": "oliverphilcox/RascalC", "repo_path": "RascalC_extracted/RascalC-master/python/compute_correction_function.py", "type": "Python" }
### Function to fit a model to the survey correction function, defined as the ratio between model and true RR pair counts for a single survey. This fits a piecewise polynomial model to the data. ## NB: Input RR counts should be normalized by summed galaxy weights here. ## NB: Assume mu is in [0,1] limit here import s...
oliverphilcoxREPO_NAMERascalCPATH_START.@RascalC_extracted@RascalC-master@python@compute_correction_function.py@.PATH_END.py
{ "filename": "setup_package.py", "repo_name": "andizq/sf3dmodels", "repo_path": "sf3dmodels_extracted/sf3dmodels-master/sf3dmodels/tests/setup_package.py", "type": "Python" }
# import os # If this package has tests data in the tests/data directory, add them to # the paths here, see commented example paths = ['coveragerc', # os.path.join('data', '*fits') ] def get_package_data(): return { _ASTROPY_PACKAGE_NAME_ + '.tests': paths}
andizqREPO_NAMEsf3dmodelsPATH_START.@sf3dmodels_extracted@sf3dmodels-master@sf3dmodels@tests@setup_package.py@.PATH_END.py
{ "filename": "_text.py", "repo_name": "plotly/plotly.py", "repo_path": "plotly.py_extracted/plotly.py-master/packages/python/plotly/plotly/validators/pie/_text.py", "type": "Python" }
import _plotly_utils.basevalidators class TextValidator(_plotly_utils.basevalidators.DataArrayValidator): def __init__(self, plotly_name="text", parent_name="pie", **kwargs): super(TextValidator, self).__init__( plotly_name=plotly_name, parent_name=parent_name, edit_typ...
plotlyREPO_NAMEplotly.pyPATH_START.@plotly.py_extracted@plotly.py-master@packages@python@plotly@plotly@validators@pie@_text.py@.PATH_END.py
{ "filename": "__init__.py", "repo_name": "ratt-ru/QuartiCal", "repo_path": "QuartiCal_extracted/QuartiCal-main/quartical/gains/complex/__init__.py", "type": "Python" }
import numpy as np from quartical.gains.gain import Gain from quartical.gains.conversion import amp_trig_to_complex from quartical.gains.complex.kernel import complex_solver from quartical.gains.complex.diag_kernel import diag_complex_solver class Complex(Gain): solver = staticmethod(complex_solver) # Conver...
ratt-ruREPO_NAMEQuartiCalPATH_START.@QuartiCal_extracted@QuartiCal-main@quartical@gains@complex@__init__.py@.PATH_END.py
{ "filename": "_style.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py3/plotly/validators/scatterternary/marker/colorbar/tickfont/_style.py", "type": "Python" }
import _plotly_utils.basevalidators class StyleValidator(_plotly_utils.basevalidators.EnumeratedValidator): def __init__( self, plotly_name="style", parent_name="scatterternary.marker.colorbar.tickfont", **kwargs, ): super(StyleValidator, self).__init__( plo...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py3@plotly@validators@scatterternary@marker@colorbar@tickfont@_style.py@.PATH_END.py
{ "filename": "test_stardata.py", "repo_name": "karllark/measure_extinction", "repo_path": "measure_extinction_extracted/measure_extinction-master/measure_extinction/tests/test_stardata.py", "type": "Python" }
import pkg_resources import astropy.units as u from measure_extinction.stardata import StarData def test_load_stardata(): # get the location of the data files data_path = pkg_resources.resource_filename("measure_extinction", "data/") # read in the observed data on the star star = StarData("hd229238...
karllarkREPO_NAMEmeasure_extinctionPATH_START.@measure_extinction_extracted@measure_extinction-master@measure_extinction@tests@test_stardata.py@.PATH_END.py
{ "filename": "test_gpu_with_dask.py", "repo_name": "dmlc/xgboost", "repo_path": "xgboost_extracted/xgboost-master/tests/test_distributed/test_gpu_with_dask/test_gpu_with_dask.py", "type": "Python" }
"""Copyright 2019-2024, XGBoost contributors""" import asyncio import json from collections import OrderedDict from inspect import signature from typing import Any, Dict, List, Type, TypeVar import numpy as np import pytest from hypothesis import given, note, settings, strategies from hypothesis._settings import dura...
dmlcREPO_NAMExgboostPATH_START.@xgboost_extracted@xgboost-master@tests@test_distributed@test_gpu_with_dask@test_gpu_with_dask.py@.PATH_END.py
{ "filename": "_size.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py3/plotly/validators/sankey/textfont/_size.py", "type": "Python" }
import _plotly_utils.basevalidators class SizeValidator(_plotly_utils.basevalidators.NumberValidator): def __init__(self, plotly_name="size", parent_name="sankey.textfont", **kwargs): super(SizeValidator, self).__init__( plotly_name=plotly_name, parent_name=parent_name, ...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py3@plotly@validators@sankey@textfont@_size.py@.PATH_END.py
{ "filename": "onedspec.py", "repo_name": "cylammarco/ASPIRED", "repo_path": "ASPIRED_extracted/ASPIRED-main/src/aspired/onedspec.py", "type": "Python" }
#!/usr/bin/env python3 # -*- coding: utf-8 -*- """For One Dimensional operations""" import copy import datetime import logging import os from typing import Callable, Union import numpy as np import pkg_resources from astropy.io import fits from astropy.modeling.polynomial import Chebyshev1D from plotly import graph_...
cylammarcoREPO_NAMEASPIREDPATH_START.@ASPIRED_extracted@ASPIRED-main@src@aspired@onedspec.py@.PATH_END.py
{ "filename": "fa4lsscat.py", "repo_name": "desihub/LSS", "repo_path": "LSS_extracted/LSS-main/py/LSS/mkCat_singletile/fa4lsscat.py", "type": "Python" }
import os import shutil import unittest from datetime import datetime import json import numpy as np import fitsio import desimodel from fiberassign.targets import (TargetsAvailable) from fiberassign.utils import option_list, GlobalTimers from fiberassign.hardware import load_hardware from fiberassign.tiles import loa...
desihubREPO_NAMELSSPATH_START.@LSS_extracted@LSS-main@py@LSS@mkCat_singletile@fa4lsscat.py@.PATH_END.py
{ "filename": "_shadow.py", "repo_name": "plotly/plotly.py", "repo_path": "plotly.py_extracted/plotly.py-master/packages/python/plotly/plotly/validators/contour/colorbar/tickfont/_shadow.py", "type": "Python" }
import _plotly_utils.basevalidators class ShadowValidator(_plotly_utils.basevalidators.StringValidator): def __init__( self, plotly_name="shadow", parent_name="contour.colorbar.tickfont", **kwargs ): super(ShadowValidator, self).__init__( plotly_name=plotly_name, parent...
plotlyREPO_NAMEplotly.pyPATH_START.@plotly.py_extracted@plotly.py-master@packages@python@plotly@plotly@validators@contour@colorbar@tickfont@_shadow.py@.PATH_END.py
{ "filename": "application_sgp_star_stamps.py", "repo_name": "Yash-10/beta-sgp", "repo_path": "beta-sgp_extracted/beta-sgp-master/restoration/application_sgp_star_stamps.py", "type": "Python" }
import random import numpy as np import pandas as pd import glob from sgp import sgp, sgp_betaDiv, DEFAULT_COLUMNS from utils import source_info, radial_profile, fit_radprof, wasserstein_distance_norm from astropy.nddata import Cutout2D from astropy.io import fits # Aim is to select subdivisions not very close to th...
Yash-10REPO_NAMEbeta-sgpPATH_START.@beta-sgp_extracted@beta-sgp-master@restoration@application_sgp_star_stamps.py@.PATH_END.py
{ "filename": "copy_injection_recovery.py", "repo_name": "ThibeauWouters/TurboPE-BNS", "repo_path": "TurboPE-BNS_extracted/TurboPE-BNS-main/injections/outdir_NRTv2/injection_99/copy_injection_recovery.py", "type": "Python" }
""" Idea: try different learning rate schemes to try and fix the injections """ import psutil p = psutil.Process() p.cpu_affinity([0]) import os os.environ['CUDA_VISIBLE_DEVICES'] = "3" os.environ["XLA_PYTHON_CLIENT_MEM_FRACTION"] = "0.10" import numpy as np import argparse # Regular imports import argparse import cop...
ThibeauWoutersREPO_NAMETurboPE-BNSPATH_START.@TurboPE-BNS_extracted@TurboPE-BNS-main@injections@outdir_NRTv2@injection_99@copy_injection_recovery.py@.PATH_END.py
{ "filename": "target_collect.py", "repo_name": "Fermipy/fermipy", "repo_path": "fermipy_extracted/fermipy-master/fermipy/jobs/target_collect.py", "type": "Python" }
#!/usr/bin/env python # Licensed under a 3-clause BSD style license - see LICENSE.rst """ Collect information for simulated realizations of an analysis """ from __future__ import absolute_import, division, print_function import os import sys import yaml import numpy as np from astropy.table import Table, Column, vs...
FermipyREPO_NAMEfermipyPATH_START.@fermipy_extracted@fermipy-master@fermipy@jobs@target_collect.py@.PATH_END.py
{ "filename": "cuda_qr_cusolver_geqrf.py", "repo_name": "google/jax", "repo_path": "jax_extracted/jax-main/jax/_src/internal_test_util/export_back_compat_test_data/cuda_qr_cusolver_geqrf.py", "type": "Python" }
# Copyright 2023 The JAX Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in wri...
googleREPO_NAMEjaxPATH_START.@jax_extracted@jax-main@jax@_src@internal_test_util@export_back_compat_test_data@cuda_qr_cusolver_geqrf.py@.PATH_END.py
{ "filename": "_style.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py3/plotly/validators/layout/scene/yaxis/title/font/_style.py", "type": "Python" }
import _plotly_utils.basevalidators class StyleValidator(_plotly_utils.basevalidators.EnumeratedValidator): def __init__( self, plotly_name="style", parent_name="layout.scene.yaxis.title.font", **kwargs ): super(StyleValidator, self).__init__( plotly_name=plotly_name, p...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py3@plotly@validators@layout@scene@yaxis@title@font@_style.py@.PATH_END.py
{ "filename": "assemblyai.ipynb", "repo_name": "langchain-ai/langchain", "repo_path": "langchain_extracted/langchain-master/docs/docs/integrations/document_loaders/assemblyai.ipynb", "type": "Jupyter Notebook" }
# AssemblyAI Audio Transcripts The `AssemblyAIAudioTranscriptLoader` allows to transcribe audio files with the [AssemblyAI API](https://www.assemblyai.com) and loads the transcribed text into documents. To use it, you should have the `assemblyai` python package installed, and the environment variable `ASSEMBLYAI_API_...
langchain-aiREPO_NAMElangchainPATH_START.@langchain_extracted@langchain-master@docs@docs@integrations@document_loaders@assemblyai.ipynb@.PATH_END.py
{ "filename": "T05unit_test_C0_SP.py", "repo_name": "nu-radio/NuRadioMC", "repo_path": "NuRadioMC_extracted/NuRadioMC-master/NuRadioMC/test/SignalProp/T05unit_test_C0_SP.py", "type": "Python" }
import numpy as np import time from NuRadioMC.SignalProp import analyticraytracing as ray from NuRadioMC.utilities import medium from NuRadioReco.utilities import units from NuRadioReco.utilities import io_utilities import logging import pickle from numpy import testing logging.basicConfig(level=logging.INFO) logger = ...
nu-radioREPO_NAMENuRadioMCPATH_START.@NuRadioMC_extracted@NuRadioMC-master@NuRadioMC@test@SignalProp@T05unit_test_C0_SP.py@.PATH_END.py
{ "filename": "_style.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py3/plotly/validators/heatmap/textfont/_style.py", "type": "Python" }
import _plotly_utils.basevalidators class StyleValidator(_plotly_utils.basevalidators.EnumeratedValidator): def __init__(self, plotly_name="style", parent_name="heatmap.textfont", **kwargs): super(StyleValidator, self).__init__( plotly_name=plotly_name, parent_name=parent_name, ...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py3@plotly@validators@heatmap@textfont@_style.py@.PATH_END.py
{ "filename": "Benchmark_5_Hidden_Markov_Model.ipynb", "repo_name": "jmschrei/pomegranate", "repo_path": "pomegranate_extracted/pomegranate-master/benchmarks/Benchmark_5_Hidden_Markov_Model.ipynb", "type": "Jupyter Notebook" }
```python %pylab inline import seaborn; seaborn.set_style('whitegrid') import time import torch from tqdm import tqdm from torchegranate.distributions import * from torchegranate.hmm import HiddenMarkovModel, Node from pomegranate import State, NormalDistribution, IndependentComponentsDistribution, DiscreteDistribu...
jmschreiREPO_NAMEpomegranatePATH_START.@pomegranate_extracted@pomegranate-master@benchmarks@Benchmark_5_Hidden_Markov_Model.ipynb@.PATH_END.py
{ "filename": "grpc_endpoint_test.py", "repo_name": "triton-inference-server/server", "repo_path": "server_extracted/server-main/qa/L0_backend_python/request_rescheduling/grpc_endpoint_test.py", "type": "Python" }
#!/usr/bin/env python # Copyright 2023-2024, NVIDIA CORPORATION & AFFILIATES. All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # * Redistributions of source code must retain the above copyright # ...
triton-inference-serverREPO_NAMEserverPATH_START.@server_extracted@server-main@qa@L0_backend_python@request_rescheduling@grpc_endpoint_test.py@.PATH_END.py
{ "filename": "test_tau_generator.py", "repo_name": "aewallin/allantools", "repo_path": "allantools_extracted/allantools-master/tests/functional_tests/test_tau_generator.py", "type": "Python" }
#!/usr/bin/python import allantools as at import numpy as np import pytest N = 128 d = np.random.random(N) r = 1.0 expected_all = np.arange(1, 43) expected_octave = [1., 2., 4., 8., 16., 32.] expected_decade = [1., 2., 4., 10., 20., 40.] expected_reduced_10 = [1., 2., 3., 4., 5., 7., 8., 11., 14., 17., ...
aewallinREPO_NAMEallantoolsPATH_START.@allantools_extracted@allantools-master@tests@functional_tests@test_tau_generator.py@.PATH_END.py
{ "filename": "SolverDialog.py", "repo_name": "marblestation/iSpec", "repo_path": "iSpec_extracted/iSpec-master/ispec/gui/dialogs/SolverDialog.py", "type": "Python" }
# # This file is part of iSpec. # Copyright Sergi Blanco-Cuaresma - http://www.blancocuaresma.com/s/ # # iSpec is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as published by # the Free Software Foundation, either version 3 of the Lice...
marblestationREPO_NAMEiSpecPATH_START.@iSpec_extracted@iSpec-master@ispec@gui@dialogs@SolverDialog.py@.PATH_END.py
{ "filename": "__init__.py", "repo_name": "Keck-DataReductionPipelines/KPF-Pipeline", "repo_path": "KPF-Pipeline_extracted/KPF-Pipeline-master/modules/barycentric_correction/__init__.py", "type": "Python" }
Keck-DataReductionPipelinesREPO_NAMEKPF-PipelinePATH_START.@KPF-Pipeline_extracted@KPF-Pipeline-master@modules@barycentric_correction@__init__.py@.PATH_END.py
{ "filename": "test_rgi.py", "repo_name": "scipy/scipy", "repo_path": "scipy_extracted/scipy-main/scipy/interpolate/tests/test_rgi.py", "type": "Python" }
import itertools import pytest import numpy as np from numpy.testing import assert_warns from scipy._lib._array_api import ( xp_assert_equal, xp_assert_close, assert_array_almost_equal ) from scipy.conftest import skip_xp_invalid_arg from pytest import raises as assert_raises from scipy.interpolate import (Regu...
scipyREPO_NAMEscipyPATH_START.@scipy_extracted@scipy-main@scipy@interpolate@tests@test_rgi.py@.PATH_END.py
{ "filename": "CHANGES.md", "repo_name": "transientskp/tkp", "repo_path": "tkp_extracted/tkp-master/CHANGES.md", "type": "Markdown" }
# Changelog ----------- ##5.0 ### Update to job_params.cfg A new section for all quality checks was created. Generic quality control parameters in persistence and quality_lofar were moved to this new section. [#590]: https://github.com/transientskp/tkp/issues/590 ### Quality checks The rms values of all fits imag...
transientskpREPO_NAMEtkpPATH_START.@tkp_extracted@tkp-master@CHANGES.md@.PATH_END.py
{ "filename": "__init__.py", "repo_name": "nuc-astro/winnet", "repo_path": "winnet_extracted/winnet-master/bin/summary_script/src_files/__init__.py", "type": "Python" }
nuc-astroREPO_NAMEwinnetPATH_START.@winnet_extracted@winnet-master@bin@summary_script@src_files@__init__.py@.PATH_END.py
{ "filename": "_x.py", "repo_name": "plotly/plotly.py", "repo_path": "plotly.py_extracted/plotly.py-master/packages/python/plotly/plotly/validators/volume/lightposition/_x.py", "type": "Python" }
import _plotly_utils.basevalidators class XValidator(_plotly_utils.basevalidators.NumberValidator): def __init__(self, plotly_name="x", parent_name="volume.lightposition", **kwargs): super(XValidator, self).__init__( plotly_name=plotly_name, parent_name=parent_name, edi...
plotlyREPO_NAMEplotly.pyPATH_START.@plotly.py_extracted@plotly.py-master@packages@python@plotly@plotly@validators@volume@lightposition@_x.py@.PATH_END.py
{ "filename": "LICENSE.md", "repo_name": "nworbde/dStar", "repo_path": "dStar_extracted/dStar-master/LICENSE.md", "type": "Markdown" }
The MIT License (MIT) Copyright (c) 2014, 2015, 2016 Edward Brown Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify...
nworbdeREPO_NAMEdStarPATH_START.@dStar_extracted@dStar-master@LICENSE.md@.PATH_END.py
{ "filename": "README.md", "repo_name": "lsst-uk/lasair-lsst", "repo_path": "lasair-lsst_extracted/lasair-lsst-main/deploy/roles/lasair_database/README.md", "type": "Markdown" }
Role Name ========= Role for initial setup of the Lasair database. Role Variables -------------- `mysql_root_password`: MysQL/MariaDB root password `mysql_db_name`: Database name `mysql_db_user`: Username for full read/write access `mysql_db_password`: Password for above `msql_db_user_readonly`: Username for read on...
lsst-ukREPO_NAMElasair-lsstPATH_START.@lasair-lsst_extracted@lasair-lsst-main@deploy@roles@lasair_database@README.md@.PATH_END.py
{ "filename": "hist_mst.py", "repo_name": "knaidoo29/mistree", "repo_path": "mistree_extracted/mistree-master/mistree/mst/hist_mst.py", "type": "Python" }
import numpy as np import matplotlib.pylab as plt def bin_data(data, minimum=None, maximum=None, bin_size=None, bin_number=100, normalised=True): """Returns the (normalised) number count of a data set with values within defined bins. Parameters ---------- data : array_like The data to be binn...
knaidoo29REPO_NAMEmistreePATH_START.@mistree_extracted@mistree-master@mistree@mst@hist_mst.py@.PATH_END.py
{ "filename": "_legend.py", "repo_name": "plotly/plotly.py", "repo_path": "plotly.py_extracted/plotly.py-master/packages/python/plotly/plotly/validators/table/_legend.py", "type": "Python" }
import _plotly_utils.basevalidators class LegendValidator(_plotly_utils.basevalidators.SubplotidValidator): def __init__(self, plotly_name="legend", parent_name="table", **kwargs): super(LegendValidator, self).__init__( plotly_name=plotly_name, parent_name=parent_name, ...
plotlyREPO_NAMEplotly.pyPATH_START.@plotly.py_extracted@plotly.py-master@packages@python@plotly@plotly@validators@table@_legend.py@.PATH_END.py
{ "filename": "paper.md", "repo_name": "richteague/disksurf", "repo_path": "disksurf_extracted/disksurf-master/paper/paper.md", "type": "Markdown" }
--- title: 'disksurf: Extracting the 3D Structure of Protoplanetary Disks' tags: - Python - astronomy - protoplanetary disks authors: - name: Richard Teague orcid: 0000-0003-0872-7098 affiliation: 1 - name: Charles J. Law orcid: 0000-0003-1413-1776 affiliation: 1 - name: Jane Huang orcid...
richteagueREPO_NAMEdisksurfPATH_START.@disksurf_extracted@disksurf-master@paper@paper.md@.PATH_END.py
{ "filename": "setup.py", "repo_name": "heal-research/pyoperon", "repo_path": "pyoperon_extracted/pyoperon-main/setup.py", "type": "Python" }
from skbuild import setup # This line replaces 'from setuptools import setup' import platform build_preset = '' if platform.system() == 'Linux': build_preset = 'build-linux' elif platform.system() == 'Darwin': build_preset = 'build-osx' setup( name="pyoperon", version="0.4.0", description="python...
heal-researchREPO_NAMEpyoperonPATH_START.@pyoperon_extracted@pyoperon-main@setup.py@.PATH_END.py
{ "filename": "Functionality.ipynb", "repo_name": "nickrodd/HDMSpectra", "repo_path": "HDMSpectra_extracted/HDMSpectra-master/examples/Functionality.ipynb", "type": "Jupyter Notebook" }
# HDMSpectra Functionality In this notebook we demonstrate the basic functionality of HDMSpectra, highlighting the different options available. Further examples can be found in the notebook "ReproducingPlots", where the plots in 2007.15001 are reproduced. **NB:** `HDMSpectra` must to be installed before running these...
nickroddREPO_NAMEHDMSpectraPATH_START.@HDMSpectra_extracted@HDMSpectra-master@examples@Functionality.ipynb@.PATH_END.py
{ "filename": "_title.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py2/plotly/validators/bar/marker/colorbar/_title.py", "type": "Python" }
import _plotly_utils.basevalidators class TitleValidator(_plotly_utils.basevalidators.TitleValidator): def __init__( self, plotly_name="title", parent_name="bar.marker.colorbar", **kwargs ): super(TitleValidator, self).__init__( plotly_name=plotly_name, parent_name=pare...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py2@plotly@validators@bar@marker@colorbar@_title.py@.PATH_END.py
{ "filename": "__init__.py", "repo_name": "mikekatz04/BOWIE", "repo_path": "BOWIE_extracted/BOWIE-master/snr_calculator_folder/gwsnrcalc/__init__.py", "type": "Python" }
mikekatz04REPO_NAMEBOWIEPATH_START.@BOWIE_extracted@BOWIE-master@snr_calculator_folder@gwsnrcalc@__init__.py@.PATH_END.py
{ "filename": "lscloop.py", "repo_name": "LCOGT/lcogtsnpipe", "repo_path": "lcogtsnpipe_extracted/lcogtsnpipe-master/trunk/bin/lscloop.py", "type": "Python" }
#!/usr/bin/env python description = "> process lsc data " import re import numpy as np from argparse import ArgumentParser from datetime import datetime, timedelta import lsc from multiprocessing import Pool, cpu_count import os import warnings def multi_run_cosmic(args): return lsc.myloopdef.run_cosmic(*args) ...
LCOGTREPO_NAMElcogtsnpipePATH_START.@lcogtsnpipe_extracted@lcogtsnpipe-master@trunk@bin@lscloop.py@.PATH_END.py
{ "filename": "test_nirspec_exceptions.py", "repo_name": "spacetelescope/jwst", "repo_path": "jwst_extracted/jwst-main/jwst/regtest/test_nirspec_exceptions.py", "type": "Python" }
import logging import pytest import subprocess from jwst.stpipe import Step from jwst.assign_wcs.util import NoDataOnDetectorError from jwst.pipeline import Spec2Pipeline from jwst.tests.helpers import LogWatcher @pytest.mark.bigdata def test_nirspec_missing_msa_fail(rtdata, fitsdiff_default_kwargs, monkeypatch): ...
spacetelescopeREPO_NAMEjwstPATH_START.@jwst_extracted@jwst-main@jwst@regtest@test_nirspec_exceptions.py@.PATH_END.py
{ "filename": "synth.py", "repo_name": "ifauh/par-sir", "repo_path": "par-sir_extracted/par-sir-main/synth.py", "type": "Python" }
import sir3d import argparse parser = argparse.ArgumentParser() parser.add_argument("-b","--batch", type=int, default=128, help="batchsize") parser.add_argument("-i","--init", default='synth.ini', help="3DSIR configuration file") parser.add_argument("-X","--x", type=int, default=0, help="x origin") parser.add_argument...
ifauhREPO_NAMEpar-sirPATH_START.@par-sir_extracted@par-sir-main@synth.py@.PATH_END.py
{ "filename": "_hoverlabel.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py3/plotly/graph_objs/histogram/_hoverlabel.py", "type": "Python" }
from plotly.basedatatypes import BaseTraceHierarchyType as _BaseTraceHierarchyType import copy as _copy class Hoverlabel(_BaseTraceHierarchyType): # class properties # -------------------- _parent_path_str = "histogram" _path_str = "histogram.hoverlabel" _valid_props = { "align", ...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py3@plotly@graph_objs@histogram@_hoverlabel.py@.PATH_END.py
{ "filename": "_hoverlabel.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py3/plotly/validators/pointcloud/_hoverlabel.py", "type": "Python" }
import _plotly_utils.basevalidators class HoverlabelValidator(_plotly_utils.basevalidators.CompoundValidator): def __init__(self, plotly_name="hoverlabel", parent_name="pointcloud", **kwargs): super(HoverlabelValidator, self).__init__( plotly_name=plotly_name, parent_name=parent_na...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py3@plotly@validators@pointcloud@_hoverlabel.py@.PATH_END.py
{ "filename": "dataloading.py", "repo_name": "ML4GW/aframe", "repo_path": "aframe_extracted/aframe-main/projects/online/online/utils/dataloading.py", "type": "Python" }
import logging import re import time from pathlib import Path from typing import List, Optional, Tuple, Union import numpy as np import torch from gwpy.timeseries import TimeSeries from scipy.signal import resample PATH_LIKE = Union[str, Path] GWF_SAMPLE_RATE = 16384 patterns = { "prefix": "[a-zA-Z0-9_:-]+", ...
ML4GWREPO_NAMEaframePATH_START.@aframe_extracted@aframe-main@projects@online@online@utils@dataloading.py@.PATH_END.py
{ "filename": "hmm.py", "repo_name": "pyro-ppl/pyro", "repo_path": "pyro_extracted/pyro-master/profiler/hmm.py", "type": "Python" }
# Copyright (c) 2017-2019 Uber Technologies, Inc. # SPDX-License-Identifier: Apache-2.0 import argparse import os import pickle import re import subprocess import sys from collections import defaultdict from os.path import abspath, join from numpy import median from pyro.util import timed EXAMPLES_DIR = join(abspat...
pyro-pplREPO_NAMEpyroPATH_START.@pyro_extracted@pyro-master@profiler@hmm.py@.PATH_END.py
{ "filename": "setup.py", "repo_name": "sxs-collaboration/gwsurrogate", "repo_path": "gwsurrogate_extracted/gwsurrogate-master/setup.py", "type": "Python" }
import os from setuptools import setup, Extension import numpy # all extensions here extmods = [] # build extension 1: python wrapper to gsl's spline function if os.path.isdir("/opt/local/include"): IncDirs = ["/opt/local/include"] else: IncDirs = [] if os.path.isdir("/opt/local/lib"): LibDirs = ["/opt...
sxs-collaborationREPO_NAMEgwsurrogatePATH_START.@gwsurrogate_extracted@gwsurrogate-master@setup.py@.PATH_END.py
{ "filename": "py_read_output.py", "repo_name": "sirocco-rt/sirocco", "repo_path": "sirocco_extracted/sirocco-main/py_progs/py_read_output.py", "type": "Python" }
#!/usr/bin/env python ''' Reads outputs from simulation runs. Synopsis: This program enables one to read outputs from the Python radiative transfer code. Where possible, we use the astropy.io module to read outputs. There are also a number of routines for processing and reshaping various data formats...
sirocco-rtREPO_NAMEsiroccoPATH_START.@sirocco_extracted@sirocco-main@py_progs@py_read_output.py@.PATH_END.py
{ "filename": "common.py", "repo_name": "h5py/h5py", "repo_path": "h5py_extracted/h5py-master/h5py/tests/common.py", "type": "Python" }
# This file is part of h5py, a Python interface to the HDF5 library. # # http://www.h5py.org # # Copyright 2008-2013 Andrew Collette and contributors # # License: Standard 3-clause BSD; see "license.txt" for full license terms # and contributor agreement. import sys import os import shutil import inspect im...
h5pyREPO_NAMEh5pyPATH_START.@h5py_extracted@h5py-master@h5py@tests@common.py@.PATH_END.py
{ "filename": "_weightsrc.py", "repo_name": "plotly/plotly.py", "repo_path": "plotly.py_extracted/plotly.py-master/packages/python/plotly/plotly/validators/cone/hoverlabel/font/_weightsrc.py", "type": "Python" }
import _plotly_utils.basevalidators class WeightsrcValidator(_plotly_utils.basevalidators.SrcValidator): def __init__( self, plotly_name="weightsrc", parent_name="cone.hoverlabel.font", **kwargs ): super(WeightsrcValidator, self).__init__( plotly_name=plotly_name, paren...
plotlyREPO_NAMEplotly.pyPATH_START.@plotly.py_extracted@plotly.py-master@packages@python@plotly@plotly@validators@cone@hoverlabel@font@_weightsrc.py@.PATH_END.py
{ "filename": "pfsetc.py", "repo_name": "Subaru-PFS/spt_ExposureTimeCalculator", "repo_path": "spt_ExposureTimeCalculator_extracted/spt_ExposureTimeCalculator-master/python/pfsspecsim/pfsetc.py", "type": "Python" }
# -*- coding: utf-8 -*- from __future__ import print_function, division import sys import os from os import path import numpy as np import time import subprocess import multiprocessing ### Some parameters ########################### ### CAUTION: ################################## ### CHANGE BELOW ON YOUR OWN RESPONS...
Subaru-PFSREPO_NAMEspt_ExposureTimeCalculatorPATH_START.@spt_ExposureTimeCalculator_extracted@spt_ExposureTimeCalculator-master@python@pfsspecsim@pfsetc.py@.PATH_END.py
{ "filename": "submit_decay.py", "repo_name": "smsharma/dark-photons-perturbations", "repo_path": "dark-photons-perturbations_extracted/dark-photons-perturbations-master/cluster/submit_decay.py", "type": "Python" }
import sys sys.path.append("../") import os import random import numpy as np from grf.units import * batch = '''#!/bin/bash #SBATCH -N 1 # node count #SBATCH --ntasks-per-node=1 #SBATCH -t 10:00:00 #SBATCH --mem=4GB ##SBATCH --mail-type=begin ##SBATCH --mail-type=end ##SBATCH --mail-user=sm8383@nyu.edu cd /home/s...
smsharmaREPO_NAMEdark-photons-perturbationsPATH_START.@dark-photons-perturbations_extracted@dark-photons-perturbations-master@cluster@submit_decay.py@.PATH_END.py
{ "filename": "jaxstatus.py", "repo_name": "HajimeKawahara/exojax", "repo_path": "exojax_extracted/exojax-master/src/exojax/utils/jaxstatus.py", "type": "Python" }
from jax import config import warnings def check_jax64bit(allow_32bit): """check if the JAX precision mode is 64bit mode Args: allow_32bit (_type_): exception to use 32bit mode. if True, just send warning message Raises: ValueError: _description_ """ ho...
HajimeKawaharaREPO_NAMEexojaxPATH_START.@exojax_extracted@exojax-master@src@exojax@utils@jaxstatus.py@.PATH_END.py
{ "filename": "nonlinear.py", "repo_name": "SBU-COSMOLIKE/CAMB-Monodromic", "repo_path": "CAMB-Monodromic_extracted/CAMB-Monodromic-main/camb/nonlinear.py", "type": "Python" }
from .baseconfig import F2003Class, fortran_class from ctypes import c_int, c_double class NonLinearModel(F2003Class): """ Abstract base class for non-linear correction models """ _fields_ = [("Min_kh_nonlinear", c_double, "minimum k/h at which to apply non-linear corrections")] halofit_original = '...
SBU-COSMOLIKEREPO_NAMECAMB-MonodromicPATH_START.@CAMB-Monodromic_extracted@CAMB-Monodromic-main@camb@nonlinear.py@.PATH_END.py
{ "filename": "GLViewWidget.py", "repo_name": "3fon3fonov/exostriker", "repo_path": "exostriker_extracted/exostriker-main/exostriker/lib/pyqtgraph/examples/GLViewWidget.py", "type": "Python" }
""" Very basic 3D graphics example; create a view widget and add a few items. """ import pyqtgraph as pg import pyqtgraph.opengl as gl pg.mkQApp("GLViewWidget Example") w = gl.GLViewWidget() w.show() w.setWindowTitle('pyqtgraph example: GLViewWidget') w.setCameraPosition(distance=20) ax = gl.GLAxisItem() ax.setSize...
3fon3fonovREPO_NAMEexostrikerPATH_START.@exostriker_extracted@exostriker-main@exostriker@lib@pyqtgraph@examples@GLViewWidget.py@.PATH_END.py
{ "filename": "sp_plots.py", "repo_name": "StephanStock/SPOG", "repo_path": "SPOG_extracted/SPOG-main/SPOG/sp_plots.py", "type": "Python" }
import corner import pandas as pd import numpy as np import astropy.stats import SPOG.sp_calc as sp_calc import matplotlib.pyplot as plt import matplotlib matplotlib.use('PDF') try: from scipy.ndimage import gaussian_filter except ImportError: gaussian_filter = None Rsun = 6.957e10 __author__ = "Stephan Stock @...
StephanStockREPO_NAMESPOGPATH_START.@SPOG_extracted@SPOG-main@SPOG@sp_plots.py@.PATH_END.py
{ "filename": "itrs.py", "repo_name": "astropy/astropy", "repo_path": "astropy_extracted/astropy-main/astropy/coordinates/builtin_frames/itrs.py", "type": "Python" }
# Licensed under a 3-clause BSD style license - see LICENSE.rst from astropy.coordinates.attributes import EarthLocationAttribute, TimeAttribute from astropy.coordinates.baseframe import BaseCoordinateFrame, base_doc from astropy.coordinates.representation import ( CartesianDifferential, CartesianRepresentatio...
astropyREPO_NAMEastropyPATH_START.@astropy_extracted@astropy-main@astropy@coordinates@builtin_frames@itrs.py@.PATH_END.py
{ "filename": "resources.py", "repo_name": "SJ001/AI-Feynman", "repo_path": "AI-Feynman_extracted/AI-Feynman-master/aifeynman/resources.py", "type": "Python" }
import os from . import __file__ def _get_resource(fname): base = os.path.dirname(os.path.realpath(__file__)) return os.path.join(base, fname)
SJ001REPO_NAMEAI-FeynmanPATH_START.@AI-Feynman_extracted@AI-Feynman-master@aifeynman@resources.py@.PATH_END.py
{ "filename": "analysis.total.md", "repo_name": "dmentipl/plonk", "repo_path": "plonk_extracted/plonk-main/docs/source/api/analysis.total.md", "type": "Markdown" }
# Global quantities ```{eval-rst} .. automodule:: plonk.analysis.total :members: ```
dmentiplREPO_NAMEplonkPATH_START.@plonk_extracted@plonk-main@docs@source@api@analysis.total.md@.PATH_END.py
{ "filename": "test_helper.py", "repo_name": "spacetelescope/jdaviz", "repo_path": "jdaviz_extracted/jdaviz-main/jdaviz/configs/mosviz/tests/test_helper.py", "type": "Python" }
# Tests all non-data-loading functionality of the Mosviz Helper class # For data-loading tests, see test_data_loading.py import csv import pytest from numpy.testing import assert_allclose from jdaviz.configs.specviz2d.helper import Specviz2d def test_to_csv(tmp_path, mosviz_helper, spectrum_collection): labels...
spacetelescopeREPO_NAMEjdavizPATH_START.@jdaviz_extracted@jdaviz-main@jdaviz@configs@mosviz@tests@test_helper.py@.PATH_END.py
{ "filename": "_color.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py2/plotly/validators/candlestick/decreasing/line/_color.py", "type": "Python" }
import _plotly_utils.basevalidators class ColorValidator(_plotly_utils.basevalidators.ColorValidator): def __init__( self, plotly_name="color", parent_name="candlestick.decreasing.line", **kwargs ): super(ColorValidator, self).__init__( plotly_name=plotly_name, parent_n...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py2@plotly@validators@candlestick@decreasing@line@_color.py@.PATH_END.py
{ "filename": "fix_old_calidation_star_catalogue.py", "repo_name": "CosmoStat/mccd", "repo_path": "mccd_extracted/mccd-master/example/fix_old_calidation_star_catalogue.py", "type": "Python" }
#!/usr/bin/env python # coding: utf-8 import numpy as np from astropy.io import fits import matplotlib.pyplot as plt import mccd # Class definition class Glob2CCD(object): r""" Get the CCD ID number from the global coordinate position. The Loc2Glob() object as input is the one that defines the instrument's ...
CosmoStatREPO_NAMEmccdPATH_START.@mccd_extracted@mccd-master@example@fix_old_calidation_star_catalogue.py@.PATH_END.py
{ "filename": "_transpose.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py2/plotly/validators/contour/_transpose.py", "type": "Python" }
import _plotly_utils.basevalidators class TransposeValidator(_plotly_utils.basevalidators.BooleanValidator): def __init__(self, plotly_name="transpose", parent_name="contour", **kwargs): super(TransposeValidator, self).__init__( plotly_name=plotly_name, parent_name=parent_name, ...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py2@plotly@validators@contour@_transpose.py@.PATH_END.py
{ "filename": "pie_and_donut_labels.py", "repo_name": "matplotlib/matplotlib", "repo_path": "matplotlib_extracted/matplotlib-main/galleries/examples/pie_and_polar_charts/pie_and_donut_labels.py", "type": "Python" }
""" ============================= A pie and a donut with labels ============================= Welcome to the Matplotlib bakery. We will create a pie and a donut chart through the `pie method <matplotlib.axes.Axes.pie>` and show how to label them with a `legend <matplotlib.axes.Axes.legend>` as well as with `annotation...
matplotlibREPO_NAMEmatplotlibPATH_START.@matplotlib_extracted@matplotlib-main@galleries@examples@pie_and_polar_charts@pie_and_donut_labels.py@.PATH_END.py
{ "filename": "three_c_test.py", "repo_name": "HERA-Team/aipy", "repo_path": "aipy_extracted/aipy-main/tests/catalog_tests/three_c_test.py", "type": "Python" }
from __future__ import print_function, division, absolute_import import unittest, aipy._src.three_c as h, aipy as a, numpy as n class TestThreeCCatalog(unittest.TestCase): def setUp(self): self.cat = h.ThreeCCatalog() self.cat.fromfile(h.THREECFILE) def test_spotcheck(self): for srcnam...
HERA-TeamREPO_NAMEaipyPATH_START.@aipy_extracted@aipy-main@tests@catalog_tests@three_c_test.py@.PATH_END.py
{ "filename": "README.md", "repo_name": "keatonb/TESS_PRF", "repo_path": "TESS_PRF_extracted/TESS_PRF-main/README.md", "type": "Markdown" }
# TESS_PRF Tools to display the TESS pixel response function (PRF) at any location on the detector. By default, will access the relevant [PRF files on MAST](https://heasarc.gsfc.nasa.gov/docs/tess/observing-technical.html#point-spread-function) (internet required), but you can also download these files and reference t...
keatonbREPO_NAMETESS_PRFPATH_START.@TESS_PRF_extracted@TESS_PRF-main@README.md@.PATH_END.py
{ "filename": "test_polyint.py", "repo_name": "scipy/scipy", "repo_path": "scipy_extracted/scipy-main/scipy/interpolate/tests/test_polyint.py", "type": "Python" }
import warnings import io import numpy as np from scipy._lib._array_api import ( xp_assert_equal, xp_assert_close, assert_array_almost_equal, assert_almost_equal ) from pytest import raises as assert_raises import pytest from scipy.interpolate import ( KroghInterpolator, krogh_interpolate, BarycentricInte...
scipyREPO_NAMEscipyPATH_START.@scipy_extracted@scipy-main@scipy@interpolate@tests@test_polyint.py@.PATH_END.py
{ "filename": "__init__.py", "repo_name": "astropy/astropy", "repo_path": "astropy_extracted/astropy-main/astropy/wcs/tests/__init__.py", "type": "Python" }
# Licensed under a 3-clause BSD style license - see LICENSE.rst
astropyREPO_NAMEastropyPATH_START.@astropy_extracted@astropy-main@astropy@wcs@tests@__init__.py@.PATH_END.py
{ "filename": "_scatterpolar.py", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/plotly/py2/plotly/graph_objs/layout/template/data/_scatterpolar.py", "type": "Python" }
from plotly.graph_objs import Scatterpolar
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@plotly@py2@plotly@graph_objs@layout@template@data@_scatterpolar.py@.PATH_END.py
{ "filename": "geometry_conf.py", "repo_name": "GeminiDRSoftware/DRAGONS", "repo_path": "DRAGONS_extracted/DRAGONS-master/geminidr/gsaoi/lookups/geometry_conf.py", "type": "Python" }
# GSAOI geometry_conf.py module containing information # for Transform-based tileArrays/mosaicDetectors # for tileArrays(): key=detector_name(), value=(xgap, ygap) (unbinned pixels) tile_gaps = { 'GSAOI': (145, 140) } # for mosaicDetectors(): key=detector_name(), value=dict # In this dict, each physical detector ...
GeminiDRSoftwareREPO_NAMEDRAGONSPATH_START.@DRAGONS_extracted@DRAGONS-master@geminidr@gsaoi@lookups@geometry_conf.py@.PATH_END.py
{ "filename": "README.md", "repo_name": "catboost/catboost", "repo_path": "catboost_extracted/catboost-master/contrib/python/scipy/py3/scipy/special/amos/README.md", "type": "Markdown" }
# AMOS A Portable Package for Bessel Functions of a Complex Argument and Nonnegative Order This algorithm is a package of subroutines for computing Bessel functions and Airy functions. The routines are updated versions of those routines found in TOMS algorithm 644. ## Disclaimer ``` * * * * * * * * * * * * * * * *...
catboostREPO_NAMEcatboostPATH_START.@catboost_extracted@catboost-master@contrib@python@scipy@py3@scipy@special@amos@README.md@.PATH_END.py
{ "filename": "attrs_test.py", "repo_name": "jax-ml/jax", "repo_path": "jax_extracted/jax-main/tests/attrs_test.py", "type": "Python" }
# Copyright 2024 The JAX Authors. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # https://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in wri...
jax-mlREPO_NAMEjaxPATH_START.@jax_extracted@jax-main@tests@attrs_test.py@.PATH_END.py
{ "filename": "__init__.py", "repo_name": "sdss/target_selection", "repo_path": "target_selection_extracted/target_selection-main/python/target_selection/sdss_id/__init__.py", "type": "Python" }
from .append_to_sdss_id import ( AppendToTables, SdssIdFlat, SdssIdFlatAddendum, SdssIdStacked, SdssIdStackedAddendum, TempCatalogidV21, TempCatalogidV25, TempCatalogidV31, ) from .create_catalogidx_to_catalogidy import ( MetaXMatch, TempMatch, UniqueMatch, create_unique_...
sdssREPO_NAMEtarget_selectionPATH_START.@target_selection_extracted@target_selection-main@python@target_selection@sdss_id@__init__.py@.PATH_END.py
{ "filename": "simbad.py", "repo_name": "juliotux/astropop", "repo_path": "astropop_extracted/astropop-main/astropop/catalogs/simbad.py", "type": "Python" }
# Licensed under a 3-clause BSD style license - see LICENSE.rst """Query and match objects in Simbad database.""" import numpy as np import warnings from astropy.coordinates import SkyCoord from astropy.table import Table from astroquery.simbad import Simbad from astropy import units as u from ._sources_catalog impor...
juliotuxREPO_NAMEastropopPATH_START.@astropop_extracted@astropop-main@astropop@catalogs@simbad.py@.PATH_END.py