code stringlengths 1 1.49M | file_id stringlengths 42 46 | node_count int64 0 7.38k | total_lines int64 1 20.9k | vector_dim int64 15 15 | vector_labels stringclasses 1
value | nodes stringlengths 2 3.75M | connections stringlengths 2 964k |
|---|---|---|---|---|---|---|---|
#!/usr/bin/python2.4
#
# Copyright (C) 2010 Google Inc.
#
# 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 applicable l... | ajibawa-2023/Python-Code-Large/train/row_80062 | 154 | 385 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80062:Expr_L17_C0", "label": "expression", "type": "expression", "loc": [17, 23], "level": 0, "parent": null, "vector": [8, 0, 0.0519, 0.0182, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "anno... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80062:ClassDef_L45_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80062:Expr_L46_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80062:ClassDef_L45_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80062:FunctionDef_L53_C2"}, {"f": "ajibawa-2023/Python-Code-... |
#!/usr/bin/python2.4
#
# Copyright (C) 2010 Google Inc.
#
# 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 applicable l... | ajibawa-2023/Python-Code-Large/train/row_80063 | 56 | 123 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80063:Expr_L17_C0", "label": "expression", "type": "expression", "loc": [17, 21], "level": 0, "parent": null, "vector": [8, 0, 0.1545, 0.0407, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "anno... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80063:ClassDef_L29_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80063:Expr_L30_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80063:ClassDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80063:Expr_L35_C2"}, {"f": "ajibawa-2023/Python-Code-Large/t... |
"""
iri2uri
Converts an IRI to a URI.
"""
__author__ = "Joe Gregorio (joe@bitworking.org)"
__copyright__ = "Copyright 2006, Joe Gregorio"
__contributors__ = []
__version__ = "1.0.0"
__license__ = "MIT"
__history__ = """
"""
import urlparse
# Convert an IRI to a URI following the rules in RFC 3987
#
# The characte... | ajibawa-2023/Python-Code-Large/train/row_80064 | 43 | 110 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80064:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 6], "level": 0, "parent": null, "vector": [8, 0, 0.0318, 0.0545, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80064:FunctionDef_L53_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80064:Assign_L54_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80064:FunctionDef_L53_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80064:Assign_L55_C4"}, {"f": "ajibawa-2023/Python-Co... |
"""SocksiPy - Python SOCKS module.
Version 1.00
Copyright 2006 Dan-Haim. All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice, this
... | ajibawa-2023/Python-Code-Large/train/row_80066 | 213 | 438 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80066:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 31], "level": 0, "parent": null, "vector": [8, 0, 0.0365, 0.0708, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annota... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80066:FunctionDef_L96_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80066:Expr_L97_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80066:FunctionDef_L96_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80066:Assign_L102_C4"}, {"f": "ajibawa-2023/Python-Cod... |
import Cookie
import datetime
import time
import email.utils
import calendar
import base64
import hashlib
import hmac
import re
import logging
# Ripped from the Tornado Framework's web.py
# http://github.com/facebook/tornado/commit/39ac6d169a36a54bb1f6b9bf1fdebb5c9da96e09
#
# Tornado is licensed under the Apache Licen... | ajibawa-2023/Python-Code-Large/train/row_80067 | 115 | 168 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80067:Import_L1_C0", "label": "Cookie import Cookie", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.006, 0.006, 0, 0.66, 0.0, 32, 0, 1, 0, 0, 32, 0, 0], "semantic": {"name": "Cookie", "arg_names": [], "import_names": ["Cookie"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80067:ClassDef_L23_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80067:FunctionDef_L26_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80067:FunctionDef_L26_C2", "t": "ajibawa-2023/Python-Code-Large/train/row_80067:If_L27_C4"}, {"f": "ajibawa-2023/Python-Code... |
# This is the version of this source code.
manual_verstr = "1.5"
auto_build_num = "211"
verstr = manual_verstr + "." + auto_build_num
try:
from pyutil.version_class import Version as pyutil_Version
__version__ = pyutil_Version(verstr)
except (ImportError, ValueError):
# Maybe there is no pyutil insta... | ajibawa-2023/Python-Code-Large/train/row_80068 | 8 | 18 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80068:Assign_L3_C0", "label": "manual_verstr =", "type": "assigned_variable", "loc": [3, 3], "level": 0, "parent": null, "vector": [14, 0, 0.1667, 0.0556, 0, 0.66, 0.0, 189, 1, 0, 0, 0, 0, 3, 0], "semantic": {"name": "manual_verstr", "arg_names": [], "import_names": [],... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80068:Try_L12_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80068:ImportFrom_L13_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80068:Try_L12_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80068:Assign_L14_C4"}, {"f": "ajibawa-2023/Python-Code-Large/tra... |
"""
The MIT License
Copyright (c) 2007-2010 Leah Culver, Joe Stump, Mark Paschal, Vic Fryzel
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 ... | ajibawa-2023/Python-Code-Large/train/row_80069 | 10 | 41 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80069:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 23], "level": 0, "parent": null, "vector": [8, 0, 0.2927, 0.561, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotat... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80069:ClassDef_L30_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80069:Expr_L31_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80069:ClassDef_L30_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80069:FunctionDef_L33_C4"}, {"f": "ajibawa-2023/Python-Code-... |
"""
The MIT License
Copyright (c) 2007-2010 Leah Culver, Joe Stump, Mark Paschal, Vic Fryzel
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 ... | ajibawa-2023/Python-Code-Large/train/row_80070 | 9 | 40 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80070:Expr_L1_C0", "label": "expression", "type": "expression", "loc": [1, 23], "level": 0, "parent": null, "vector": [8, 0, 0.3, 0.575, 0, 0.66, 0.0, 0, 1, 0, 0, 0, 0, 0, 0], "semantic": {"name": "", "arg_names": [], "import_names": [], "rhs_call_name": "", "annotation... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80070:ClassDef_L29_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80070:Expr_L30_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80070:ClassDef_L29_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80070:FunctionDef_L32_C4"}, {"f": "ajibawa-2023/Python-Code-... |
# Early, and incomplete implementation of -04.
#
import re
import urllib
RESERVED = ":/?#[]@!$&'()*+,;="
OPERATOR = "+./;?|!@"
EXPLODE = "*+"
MODIFIER = ":^"
TEMPLATE = re.compile(r"{(?P<operator>[\+\./;\?|!@])?(?P<varlist>[^}]+)}", re.UNICODE)
VAR = re.compile(r"^(?P<varname>[^=\+\*:\^]+)((?P<explode>[\+\*])|(?P<part... | ajibawa-2023/Python-Code-Large/train/row_80072 | 112 | 147 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80072:Import_L3_C0", "label": "re import re", "type": "import", "loc": [3, 3], "level": 0, "parent": null, "vector": [1, 0, 0.0204, 0.0068, 0, 0.66, 0.0, 540, 0, 1, 0, 0, 540, 0, 0], "semantic": {"name": "re", "arg_names": [], "import_names": ["re"], "rhs_call_name": ""... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80072:FunctionDef_L13_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80072:If_L14_C2"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80072:If_L14_C2", "t": "ajibawa-2023/Python-Code-Large/train/row_80072:If_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/ro... |
#!/usr/bin/env python
import os
import sys
import time
sys.path.insert(0,'/home/mike/python')
import re
from flickrapi import FlickrAPI
flickrAPIKey = ""
flickrSecret = ""
fapi = None
BASE = '/home/mike/projects/albertarandonneurs.ca/content'
OUTPUT = '/home/mike/projects/albertarandonneurs.ca/html'
IGNORE = ['me... | ajibawa-2023/Python-Code-Large/train/row_80073 | 289 | 470 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80073:Import_L4_C0", "label": "os import os", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0085, 0.0021, 0, 0.66, 0.0, 688, 0, 1, 0, 0, 688, 0, 0], "semantic": {"name": "os", "arg_names": [], "import_names": ["os"], "rhs_call_name": ""... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80073:FunctionDef_L53_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80073:Expr_L54_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80073:FunctionDef_L53_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80073:Assign_L62_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Iliev et al. test #1
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the total number of snapshots
te = 50
# set the solution tolerance
tol = 0.004
# set some constants
Ngammadot = 5.0e48 # ionization source strength [photons/... | ajibawa-2023/Python-Code-Large/train/row_80074 | 75 | 115 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80074:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0435, 0.0087, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80074:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80074:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80074:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80074:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Iliev et al. test #1
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
# set the total number of snapshots
te = 50
# set the graphics output type
pictype = '.png'
# set some constants
Ngammadot = 5.0e48 # ionization source strength [photons/sec]
aHII = ... | ajibawa-2023/Python-Code-Large/train/row_80075 | 137 | 192 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80075:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.026, 0.0052, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80075:FunctionDef_L32_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80075:Expr_L33_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80075:FunctionDef_L32_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80075:Import_L34_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for radiating shock tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the graphics output type
pictype = '.png'
# store exact solution values
xi = [8.000838354813387e-02, 8.284041833623391e-02, 8.394370939772287e-02,
8.501057... | ajibawa-2023/Python-Code-Large/train/row_80076 | 90 | 217 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80076:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.023, 0.0046, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80076:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80076:Expr_L135_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80076:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80076:Import_L136_C4"}, {"f": "ajibawa-2023/Python-... |
# matplotlib-based plotting script for radiating shock tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.03
# store exact solution values
xi = [8.000838354813387e-02, 8.284041833623391e-02, 8.394370939772287e-02,
8.50105733558542... | ajibawa-2023/Python-Code-Large/train/row_80077 | 105 | 236 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80077:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0212, 0.0042, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80077:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80077:Expr_L135_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80077:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80077:Import_L136_C4"}, {"f": "ajibawa-2023/Python-... |
# numpy/scipy-based error-checking script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the total number of snapshots
te = 18
# set the solution tolerance
tol = 0.01
# set some constants
q0 = 0.05 # deceleration parameter
N... | ajibawa-2023/Python-Code-Large/train/row_80078 | 123 | 217 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80078:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.023, 0.0046, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80078:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80078:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80078:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80078:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
# set the total number of snapshots
te = 21
# set the graphics output type
pictype = '.png'
# set some constants
q0 = 0.05 # deceleration parameter
Nph = 5.0e48 ... | ajibawa-2023/Python-Code-Large/train/row_80079 | 181 | 291 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80079:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0172, 0.0034, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80079:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80079:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80079:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80079:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.15
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.ge... | ajibawa-2023/Python-Code-Large/train/row_80080 | 171 | 247 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80080:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0162, 0.004, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_na... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80080:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80080:Assign_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80080:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80080:If_L17_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_800... |
# matplotlib-based plotting script for 3D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 3D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.get('/Grid0000... | ajibawa-2023/Python-Code-Large/train/row_80081 | 100 | 143 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80081:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.007, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_nam... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80081:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80081:Assign_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80081:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80081:If_L16_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_800... |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.15
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.ge... | ajibawa-2023/Python-Code-Large/train/row_80082 | 171 | 247 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80082:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0162, 0.004, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_na... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80082:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80082:Assign_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80082:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80082:If_L17_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_800... |
# matplotlib-based plotting script for 3D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 3D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.get('/Grid0000... | ajibawa-2023/Python-Code-Large/train/row_80083 | 100 | 143 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80083:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.007, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_nam... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80083:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80083:Assign_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80083:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80083:If_L16_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_800... |
# numpy/scipy-based error-checking script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the total number of snapshots
te = 18
# set the solution tolerance
tol = 0.01
# set some constants
q0 = 0.05 # deceleration parameter
N... | ajibawa-2023/Python-Code-Large/train/row_80084 | 123 | 217 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80084:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.023, 0.0046, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80084:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80084:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80084:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80084:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
# set the total number of snapshots
te = 18
# set the graphics output type
pictype = '.png'
# set some constants
q0 = 0.05 # deceleration parameter
Nph = 5.0e48 ... | ajibawa-2023/Python-Code-Large/train/row_80085 | 181 | 291 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80085:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0172, 0.0034, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80085:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80085:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80085:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80085:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for radiating shock tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the graphics output type
pictype = '.png'
# store exact solution values
xi = [8.000838354813387e-02, 8.284041833623391e-02, 8.394370939772287e-02,
8.501057... | ajibawa-2023/Python-Code-Large/train/row_80086 | 78 | 204 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80086:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0245, 0.0049, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80086:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80086:Expr_L135_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80086:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80086:Import_L136_C4"}, {"f": "ajibawa-2023/Python-... |
# matplotlib-based plotting script for radiating shock tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.03
# store exact solution values
xi = [8.000838354813387e-02, 8.284041833623391e-02, 8.394370939772287e-02,
8.50105733558542... | ajibawa-2023/Python-Code-Large/train/row_80087 | 93 | 222 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80087:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0225, 0.0045, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80087:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80087:Expr_L135_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80087:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80087:Import_L136_C4"}, {"f": "ajibawa-2023/Python-... |
# matplotlib-based plotting script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg = f.get('/Grid000000... | ajibawa-2023/Python-Code-Large/train/row_80088 | 49 | 82 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80088:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0488, 0.0122, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_n... | [] |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.1
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg = f.get('... | ajibawa-2023/Python-Code-Large/train/row_80089 | 120 | 186 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80089:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0215, 0.0054, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_n... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80089:For_L24_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80089:If_L25_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80089:If_L25_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_80089:Assign_L26_C8"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80... |
# matplotlib-based plotting script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
# set the total number of snapshots
te = 20
# set the graphics output type
pictype = '.png'
# set some constants
q0 = 0.5 # deceleration parameter
Nph = 5.0e48 ... | ajibawa-2023/Python-Code-Large/train/row_80090 | 181 | 291 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80090:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0172, 0.0034, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80090:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80090:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80090:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80090:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy/scipy-based error-checking script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the total number of snapshots
te = 20
# set the solution tolerance
tol = 0.01
# set some constants
q0 = 0.5 # deceleration parameter
... | ajibawa-2023/Python-Code-Large/train/row_80091 | 122 | 217 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80091:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.023, 0.0046, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80091:FunctionDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80091:Expr_L35_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80091:FunctionDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80091:Import_L36_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy/scipy-based error-checking script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the total number of snapshots
te = 18
# set the solution tolerance
tol = 0.01
# set some constants
q0 = 0.05 # deceleration parameter
N... | ajibawa-2023/Python-Code-Large/train/row_80092 | 123 | 217 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80092:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.023, 0.0046, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80092:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80092:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80092:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80092:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
# set the total number of snapshots
te = 21
# set the graphics output type
pictype = '.png'
# set some constants
q0 = 0.05 # deceleration parameter
Nph = 5.0e48 ... | ajibawa-2023/Python-Code-Large/train/row_80093 | 181 | 291 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80093:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0172, 0.0034, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80093:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80093:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80093:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80093:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.15
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.ge... | ajibawa-2023/Python-Code-Large/train/row_80094 | 171 | 247 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80094:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0162, 0.004, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_na... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80094:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80094:Assign_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80094:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80094:If_L17_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_800... |
# matplotlib-based plotting script for 3D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 3D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.get('/Grid0000... | ajibawa-2023/Python-Code-Large/train/row_80095 | 100 | 143 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80095:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.007, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_nam... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80095:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80095:Assign_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80095:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80095:If_L16_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_800... |
# Creates 2D projection of the Density field
#
############################################
from yt.mods import *
min_output_number = 273
max_output_number = 273
skip = 1
field = "Density"
res = 64
frame_template = "frames/movie"+field+"_%04i.png"
basename_template = "DD%04i/DD%04i"
import pylab
for i in range(mi... | ajibawa-2023/Python-Code-Large/train/row_80096 | 22 | 38 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80096:ImportFrom_L5_C0", "label": "from yt.mods import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.1316, 0.0263, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "r... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80096:For_L19_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80096:Expr_L20_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80096:For_L19_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80096:Assign_L22_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row... |
# Creates 2D projection of the Temperature field
#
################################################
from yt.mods import *
min_output_number = 273
max_output_number = 273
skip = 1
field = "Temperature"
res = 64
frame_template = "frames/movie"+field+"_%04i.png"
basename_template = "DD%04i/DD%04i"
import pylab
for i... | ajibawa-2023/Python-Code-Large/train/row_80097 | 23 | 40 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80097:ImportFrom_L5_C0", "label": "from yt.mods import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.125, 0.025, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "rhs... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80097:For_L19_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80097:Expr_L20_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80097:For_L19_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80097:Assign_L22_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row... |
# YT script that will output the following by columns:
#
# 1) years after big bang
# 2) total emissivity contributing to feedback (actually emissivity density) values in the box in units erg/s/cm^3
# 3) redshift
# 4) number of cells with feedback sources
# 5) total mass of all star particles
# 6) total number of stars
... | ajibawa-2023/Python-Code-Large/train/row_80098 | 46 | 80 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80098:ImportFrom_L14_C0", "label": "from yt.mods import *", "type": "import", "loc": [14, 14], "level": 0, "parent": null, "vector": [1, 0, 0.175, 0.0125, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], ... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80098:FunctionDef_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80098:Assign_L17_C3"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80098:FunctionDef_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80098:Return_L18_C3"}, {"f": "ajibawa-2023/Python-Co... |
# Creates 2D projection of the Grey_Radiation_Energy field
#
##########################################################
from yt.mods import *
min_output_number = 273
max_output_number = 273
skip = 1
field = "Grey_Radiation_Energy"
res = 64
frame_template = "frames/movie"+field+"_%04i.png"
basename_template = "DD%04... | ajibawa-2023/Python-Code-Large/train/row_80099 | 27 | 45 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80099:ImportFrom_L5_C0", "label": "from yt.mods import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.1111, 0.0222, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "r... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80099:For_L19_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80099:Expr_L20_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80099:For_L19_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80099:Assign_L22_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row... |
# this script calculates the min, max, mean value of the specified field
#
########################################################################
from yt.mods import *
pf = EnzoStaticOutput("DD0273/DD0273")
dd = pf.h.all_data()
# uncomment the wanted field for analysis
#field = "Emissivity"
#field = "Density"
#fiel... | ajibawa-2023/Python-Code-Large/train/row_80100 | 12 | 25 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80100:ImportFrom_L5_C0", "label": "from yt.mods import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.2, 0.04, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "rhs_ca... | [] |
# 1) Time (yrs)
# 2) Look-back time (yrs)
# 3) Redshift
# 4) Star formation rate in this bin per year (Msol/yr)
# 5) Star formation rate in this bin per year per Mpc**3 (Msol/yr/Mpc**3) (in proper Mpc)
# 6) Stars formed in this time bin (Msol)
# 7) Cumulative stars formed up to this time bin (Msol)
#
# Divide column 5 ... | ajibawa-2023/Python-Code-Large/train/row_80101 | 7 | 22 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80101:ImportFrom_L14_C0", "label": "from yt.mods import *", "type": "import", "loc": [14, 14], "level": 0, "parent": null, "vector": [1, 0, 0.6364, 0.0455, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"],... | [] |
# Creates 2D projection of the Emissivity field
#
###############################################
from yt.mods import *
min_output_number = 273
max_output_number = 273
skip = 1
field = "Emissivity"
res = 64
frame_template = "frames/movie"+field+"_%04i.png"
basename_template = "DD%04i/DD%04i"
import pylab
for i in... | ajibawa-2023/Python-Code-Large/train/row_80102 | 23 | 40 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80102:ImportFrom_L5_C0", "label": "from yt.mods import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.125, 0.025, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "rhs... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80102:For_L19_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80102:Expr_L20_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80102:For_L19_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80102:Assign_L22_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row... |
# Can be modified to create 2D projection of the following fields:
# 1) IonizationFraction
# 2) LogIonizationFraction
# 3) NeutralFraction
# 4) LogNeutralFraction
#
#################################################################
from yt.mods import *
def NeutralFraction(field, data):
return data["HI_Density"] / ... | ajibawa-2023/Python-Code-Large/train/row_80103 | 35 | 66 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80103:ImportFrom_L9_C0", "label": "from yt.mods import *", "type": "import", "loc": [9, 9], "level": 0, "parent": null, "vector": [1, 0, 0.1364, 0.0152, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "r... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80103:FunctionDef_L11_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80103:Return_L12_C3"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80103:FunctionDef_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80103:Return_L17_C3"}, {"f": "ajibawa-2023/Python-Co... |
# matplotlib-based plotting script for Iliev et al. test #1
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the total number of snapshots
te = 50
# set the solution tolerance
tol = 0.004
# set some constants
Ngammadot = 5.0e48 # ionization source strength [photons/... | ajibawa-2023/Python-Code-Large/train/row_80104 | 75 | 115 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80104:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0435, 0.0087, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80104:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80104:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80104:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80104:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Iliev et al. test #1
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
# set the total number of snapshots
te = 50
# set the graphics output type
pictype = '.png'
# set some constants
Ngammadot = 5.0e48 # ionization source strength [photons/sec]
aHII = ... | ajibawa-2023/Python-Code-Large/train/row_80105 | 137 | 192 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80105:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.026, 0.0052, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80105:FunctionDef_L32_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80105:Expr_L33_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80105:FunctionDef_L32_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80105:Import_L34_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Iliev et al. test #2
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the total number of snapshots
te = 50
# set the solution tolerance
tol = 0.002
# load the reference solution
r_sol = np.load('r_sol.npy')
# set some constants
N... | ajibawa-2023/Python-Code-Large/train/row_80106 | 78 | 117 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80106:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0427, 0.0085, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80106:FunctionDef_L35_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80106:Expr_L36_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80106:FunctionDef_L35_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80106:Import_L37_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Iliev et al. test #2
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
# set the total number of snapshots
te = 50
# set the graphics output type
pictype = '.png'
# set some constants
Ngammadot = 5.0e48 # ionization source strength [photons/sec]
aHII = ... | ajibawa-2023/Python-Code-Large/train/row_80107 | 142 | 200 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80107:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.025, 0.005, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_cal... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80107:FunctionDef_L31_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80107:Expr_L32_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80107:FunctionDef_L31_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80107:Import_L33_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Iliev et al. test #2
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the total number of snapshots
te = 50
# set the solution tolerance
tol = 0.002
# load the reference solution
r_sol = np.load('r_sol.npy')
# set some constants
N... | ajibawa-2023/Python-Code-Large/train/row_80108 | 78 | 117 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80108:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0427, 0.0085, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80108:FunctionDef_L35_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80108:Expr_L36_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80108:FunctionDef_L35_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80108:Import_L37_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Iliev et al. test #2
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
# set the total number of snapshots
te = 50
# set the graphics output type
pictype = '.png'
# set some constants
Ngammadot = 5.0e48 # ionization source strength [photons/sec]
aHII = ... | ajibawa-2023/Python-Code-Large/train/row_80109 | 142 | 200 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80109:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.025, 0.005, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_cal... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80109:FunctionDef_L31_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80109:Expr_L32_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80109:FunctionDef_L31_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80109:Import_L33_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.15
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.ge... | ajibawa-2023/Python-Code-Large/train/row_80110 | 171 | 247 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80110:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0162, 0.004, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_na... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80110:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80110:Assign_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80110:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80110:If_L17_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for 3D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 3D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.get('/Grid0000... | ajibawa-2023/Python-Code-Large/train/row_80111 | 100 | 143 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80111:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.007, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_nam... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80111:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80111:Assign_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80111:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80111:If_L16_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.15
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.ge... | ajibawa-2023/Python-Code-Large/train/row_80112 | 171 | 247 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80112:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0162, 0.004, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_na... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80112:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80112:Assign_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80112:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80112:If_L17_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for 3D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 3D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.get('/Grid0000... | ajibawa-2023/Python-Code-Large/train/row_80113 | 100 | 143 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80113:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.007, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_nam... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80113:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80113:Assign_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80113:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80113:If_L16_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# numpy-based error-checking script for Turner & Stone equilibration tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
import numpy as np
# set the total number of snapshots
nt = 100
# set the solution tolerance
tol = 0.01
# load reference solution from disk
t_ref = np.load('times.npy')
e_ref = np.load('e_sol.... | ajibawa-2023/Python-Code-Large/train/row_80114 | 59 | 82 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80114:Import_L5_C0", "label": "numpy import np", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.061, 0.0122, 0, 0.66, 0.0, 954, 0, 1, 0, 0, 954, 0, 0], "semantic": {"name": "numpy", "arg_names": [], "import_names": ["np"], "rhs_call_name... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80114:FunctionDef_L18_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80114:Expr_L19_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80114:FunctionDef_L18_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80114:Import_L20_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Turner & Stone equilibration tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
from scipy.integrate import *
# set the total number of snapshots
nt = 100
# set the graphics output type
pictype = '.png'
# define some helpful functions
def get_params(fil... | ajibawa-2023/Python-Code-Large/train/row_80115 | 64 | 85 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80115:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0588, 0.0118, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80115:FunctionDef_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80115:Expr_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80115:FunctionDef_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80115:Import_L17_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.15
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.ge... | ajibawa-2023/Python-Code-Large/train/row_80116 | 171 | 247 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80116:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0162, 0.004, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_na... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80116:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80116:Assign_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80116:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80116:If_L17_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for 3D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 3D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.get('/Grid0000... | ajibawa-2023/Python-Code-Large/train/row_80117 | 100 | 143 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80117:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.007, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_nam... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80117:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80117:Assign_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80117:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80117:If_L16_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.15
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.ge... | ajibawa-2023/Python-Code-Large/train/row_80118 | 171 | 247 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80118:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0162, 0.004, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_na... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80118:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80118:Assign_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80118:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80118:If_L17_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for 3D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 3D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.get('/Grid0000... | ajibawa-2023/Python-Code-Large/train/row_80119 | 100 | 143 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80119:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.007, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_nam... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80119:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80119:Assign_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80119:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80119:If_L16_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# numpy-based error-checking script for Turner & Stone equilibration tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
import numpy as np
# set the total number of snapshots
nt = 100
# set the solution tolerance
tol = 0.01
# load reference solution from disk
t_ref = np.load('times.npy')
e_ref = np.load('e_sol.... | ajibawa-2023/Python-Code-Large/train/row_80120 | 59 | 82 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80120:Import_L5_C0", "label": "numpy import np", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.061, 0.0122, 0, 0.66, 0.0, 954, 0, 1, 0, 0, 954, 0, 0], "semantic": {"name": "numpy", "arg_names": [], "import_names": ["np"], "rhs_call_name... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80120:FunctionDef_L18_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80120:Expr_L19_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80120:FunctionDef_L18_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80120:Import_L20_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Turner & Stone equilibration tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
from scipy.integrate import *
# set the total number of snapshots
nt = 100
# set the graphics output type
pictype = '.png'
# define some helpful functions
def get_params(fil... | ajibawa-2023/Python-Code-Large/train/row_80121 | 64 | 85 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80121:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0588, 0.0118, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80121:FunctionDef_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80121:Expr_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80121:FunctionDef_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80121:Import_L17_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.15
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.ge... | ajibawa-2023/Python-Code-Large/train/row_80122 | 171 | 247 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80122:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0162, 0.004, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_na... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80122:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80122:Assign_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80122:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80122:If_L17_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for 3D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 3D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.get('/Grid0000... | ajibawa-2023/Python-Code-Large/train/row_80123 | 100 | 143 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80123:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.007, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_nam... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80123:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80123:Assign_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80123:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80123:If_L16_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
# set the total number of snapshots
te = 20
# set the graphics output type
pictype = '.png'
# set some constants
q0 = 0.5 # deceleration parameter
Nph = 5.0e48 ... | ajibawa-2023/Python-Code-Large/train/row_80124 | 181 | 291 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80124:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0172, 0.0034, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80124:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80124:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80124:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80124:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy/scipy-based error-checking script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the total number of snapshots
te = 20
# set the solution tolerance
tol = 0.01
# set some constants
q0 = 0.5 # deceleration parameter
... | ajibawa-2023/Python-Code-Large/train/row_80125 | 122 | 217 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80125:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.023, 0.0046, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80125:FunctionDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80125:Expr_L35_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80125:FunctionDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80125:Import_L36_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.15
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.ge... | ajibawa-2023/Python-Code-Large/train/row_80126 | 171 | 247 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80126:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0162, 0.004, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_na... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80126:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80126:Assign_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80126:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80126:If_L17_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for 3D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 3D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.get('/Grid0000... | ajibawa-2023/Python-Code-Large/train/row_80127 | 100 | 143 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80127:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.007, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_nam... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80127:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80127:Assign_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80127:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80127:If_L16_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for radiating shock tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the graphics output type
pictype = '.png'
# store exact solution values
xi = [8.000838354813387e-02, 8.284041833623391e-02, 8.394370939772287e-02,
8.501057... | ajibawa-2023/Python-Code-Large/train/row_80128 | 78 | 204 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80128:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0245, 0.0049, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80128:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80128:Expr_L135_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80128:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80128:Import_L136_C4"}, {"f": "ajibawa-2023/Python-... |
# matplotlib-based plotting script for radiating shock tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.03
# store exact solution values
xi = [8.000838354813387e-02, 8.284041833623391e-02, 8.394370939772287e-02,
8.50105733558542... | ajibawa-2023/Python-Code-Large/train/row_80129 | 93 | 222 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80129:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0225, 0.0045, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80129:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80129:Expr_L135_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80129:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80129:Import_L136_C4"}, {"f": "ajibawa-2023/Python-... |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.15
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.ge... | ajibawa-2023/Python-Code-Large/train/row_80130 | 171 | 247 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80130:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0162, 0.004, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_na... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80130:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80130:Assign_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80130:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80130:If_L17_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for 3D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 3D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.get('/Grid0000... | ajibawa-2023/Python-Code-Large/train/row_80131 | 100 | 143 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80131:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.007, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_nam... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80131:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80131:Assign_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80131:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80131:If_L16_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.15
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.ge... | ajibawa-2023/Python-Code-Large/train/row_80132 | 171 | 247 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80132:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0162, 0.004, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_na... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80132:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80132:Assign_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80132:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80132:If_L17_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for 3D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 3D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.get('/Grid0000... | ajibawa-2023/Python-Code-Large/train/row_80133 | 100 | 143 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80133:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.007, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_nam... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80133:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80133:Assign_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80133:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80133:If_L16_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for radiating shock tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the graphics output type
pictype = '.png'
# store exact solution values
xi = [8.000838354813387e-02, 8.284041833623391e-02, 8.394370939772287e-02,
8.501057... | ajibawa-2023/Python-Code-Large/train/row_80134 | 90 | 217 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80134:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.023, 0.0046, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80134:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80134:Expr_L135_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80134:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80134:Import_L136_C4"}, {"f": "ajibawa-2023/Python-... |
# matplotlib-based plotting script for radiating shock tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.03
# store exact solution values
xi = [8.000838354813387e-02, 8.284041833623391e-02, 8.394370939772287e-02,
8.50105733558542... | ajibawa-2023/Python-Code-Large/train/row_80135 | 105 | 236 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80135:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0212, 0.0042, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80135:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80135:Expr_L135_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80135:FunctionDef_L134_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80135:Import_L136_C4"}, {"f": "ajibawa-2023/Python-... |
# numpy/scipy-based error-checking script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the total number of snapshots
te = 18
# set the solution tolerance
tol = 0.01
# set some constants
q0 = 0.05 # deceleration parameter
N... | ajibawa-2023/Python-Code-Large/train/row_80136 | 123 | 217 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80136:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.023, 0.0046, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80136:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80136:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80136:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80136:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
# set the total number of snapshots
te = 18
# set the graphics output type
pictype = '.png'
# set some constants
q0 = 0.05 # deceleration parameter
Nph = 5.0e48 ... | ajibawa-2023/Python-Code-Large/train/row_80137 | 181 | 291 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80137:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0172, 0.0034, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80137:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80137:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80137:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80137:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
# set the total number of snapshots
te = 20
# set the graphics output type
pictype = '.png'
# set some constants
q0 = 0.5 # deceleration parameter
Nph = 5.0e48 ... | ajibawa-2023/Python-Code-Large/train/row_80138 | 181 | 291 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80138:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0172, 0.0034, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80138:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80138:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80138:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80138:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy/scipy-based error-checking script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the total number of snapshots
te = 20
# set the solution tolerance
tol = 0.01
# set some constants
q0 = 0.5 # deceleration parameter
... | ajibawa-2023/Python-Code-Large/train/row_80139 | 122 | 217 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80139:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.023, 0.0046, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80139:FunctionDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80139:Expr_L35_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80139:FunctionDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80139:Import_L36_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy-based error-checking script for Turner & Stone equilibration tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
import numpy as np
# set the total number of snapshots
nt = 100
# set the solution tolerance
tol = 0.01
# load reference solution from disk
t_ref = np.load('times.npy')
e_ref = np.load('e_sol.... | ajibawa-2023/Python-Code-Large/train/row_80140 | 59 | 82 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80140:Import_L5_C0", "label": "numpy import np", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.061, 0.0122, 0, 0.66, 0.0, 954, 0, 1, 0, 0, 954, 0, 0], "semantic": {"name": "numpy", "arg_names": [], "import_names": ["np"], "rhs_call_name... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80140:FunctionDef_L18_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80140:Expr_L19_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80140:FunctionDef_L18_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80140:Import_L20_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Turner & Stone equilibration tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
from scipy.integrate import *
# set the total number of snapshots
nt = 100
# set the graphics output type
pictype = '.png'
# define some helpful functions
def get_params(fil... | ajibawa-2023/Python-Code-Large/train/row_80141 | 64 | 86 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80141:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0581, 0.0116, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80141:FunctionDef_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80141:Expr_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80141:FunctionDef_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80141:Import_L17_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.15
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.ge... | ajibawa-2023/Python-Code-Large/train/row_80142 | 171 | 247 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80142:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0162, 0.004, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_na... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80142:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80142:Assign_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80142:If_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80142:If_L17_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for 3D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 3D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg3D = f.get('/Grid0000... | ajibawa-2023/Python-Code-Large/train/row_80143 | 100 | 143 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80143:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.028, 0.007, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_nam... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80143:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80143:Assign_L15_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80143:If_L14_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80143:If_L16_C0"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_801... |
# matplotlib-based plotting script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
# set the graphics output type
pictype = '.png'
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg = f.get('/Grid000000... | ajibawa-2023/Python-Code-Large/train/row_80144 | 49 | 82 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80144:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0488, 0.0122, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_n... | [] |
# numpy-based error-checking script for 1D streaming radiation datasets
# Daniel R. Reynolds, reynolds@smu.edu
import h5py
from pylab import *
import numpy as np
# set the solution tolerance
tol = 0.1
# load first dataset, and put 1D radiation field into 'Eg'
f = h5py.File('DD0001/data0001.cpu0000','r')
Eg = f.get('... | ajibawa-2023/Python-Code-Large/train/row_80145 | 120 | 186 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80145:Import_L4_C0", "label": "h5py import h5py", "type": "import", "loc": [4, 4], "level": 0, "parent": null, "vector": [1, 0, 0.0215, 0.0054, 0, 0.66, 0.0, 316, 0, 1, 0, 0, 316, 0, 0], "semantic": {"name": "h5py", "arg_names": [], "import_names": ["h5py"], "rhs_call_n... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80145:For_L24_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80145:If_L25_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80145:If_L25_C4", "t": "ajibawa-2023/Python-Code-Large/train/row_80145:Assign_L26_C8"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80... |
# numpy-based error-checking script for Turner & Stone equilibration tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
import numpy as np
# set the total number of snapshots
nt = 100
# set the solution tolerance
tol = 0.01
# load reference solution from disk
t_ref = np.load('times.npy')
e_ref = np.load('e_sol.... | ajibawa-2023/Python-Code-Large/train/row_80146 | 59 | 82 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80146:Import_L5_C0", "label": "numpy import np", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.061, 0.0122, 0, 0.66, 0.0, 954, 0, 1, 0, 0, 954, 0, 0], "semantic": {"name": "numpy", "arg_names": [], "import_names": ["np"], "rhs_call_name... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80146:FunctionDef_L18_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80146:Expr_L19_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80146:FunctionDef_L18_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80146:Import_L20_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Turner & Stone equilibration tests
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
from scipy.integrate import *
# set the total number of snapshots
nt = 100
# set the graphics output type
pictype = '.png'
# define some helpful functions
def get_params(fil... | ajibawa-2023/Python-Code-Large/train/row_80147 | 64 | 85 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80147:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0588, 0.0118, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80147:FunctionDef_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80147:Expr_L16_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80147:FunctionDef_L15_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80147:Import_L17_C4"}, {"f": "ajibawa-2023/Python-Code... |
# matplotlib-based plotting script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
# set the total number of snapshots
te = 20
# set the graphics output type
pictype = '.png'
# set some constants
q0 = 0.5 # deceleration parameter
Nph = 5.0e48 ... | ajibawa-2023/Python-Code-Large/train/row_80148 | 181 | 291 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80148:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.0172, 0.0034, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_c... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80148:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80148:Expr_L34_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80148:FunctionDef_L33_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80148:Import_L35_C4"}, {"f": "ajibawa-2023/Python-Code... |
# numpy/scipy-based error-checking script for Shapiro & Giroux q=0.5 test
# Daniel R. Reynolds, reynolds@smu.edu
# imports
from pylab import *
import numpy as np
# set the total number of snapshots
te = 20
# set the solution tolerance
tol = 0.01
# set some constants
q0 = 0.5 # deceleration parameter
... | ajibawa-2023/Python-Code-Large/train/row_80149 | 122 | 217 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80149:ImportFrom_L5_C0", "label": "from pylab import *", "type": "import", "loc": [5, 5], "level": 0, "parent": null, "vector": [1, 0, 0.023, 0.0046, 0, 0.66, 0.0, 735, 0, 1, 0, 0, 735, 0, 0], "semantic": {"name": "pylab", "arg_names": [], "import_names": ["*"], "rhs_ca... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80149:FunctionDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80149:Expr_L35_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80149:FunctionDef_L34_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80149:Import_L36_C4"}, {"f": "ajibawa-2023/Python-Code... |
from yt.mods import *
from matplotlib import use; use('Agg')
import matplotlib.pyplot as plt
# Calculate
# 1. Time evolution of the average temperature and ionization fraction
# of the clump
# 2. Line cut of temperature through the clump center
# 3. Neutral fraction and temperature slices at the last output
first ... | ajibawa-2023/Python-Code-Large/train/row_80150 | 61 | 99 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80150:ImportFrom_L1_C0", "label": "from yt.mods import *", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0101, 0.0101, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "r... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80150:FunctionDef_L18_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80150:Return_L19_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80150:For_L30_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80150:Assign_L31_C4"}, {"f": "ajibawa-2023/Python-Code-Large... |
from yt.mods import *
from matplotlib import use; use('Agg')
import matplotlib.pyplot as plt
# Calculate
# 1. Ionization front propagation and compare to Stroemgren solution
# 2. Slice of photo-ionization field
# 3. Deviation from 1/r^2 in the photo-ionization field in the last output
first = 1
last = 25
Myr = 3.155... | ajibawa-2023/Python-Code-Large/train/row_80151 | 12 | 12 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80151:ImportFrom_L1_C0", "label": "from yt.mods import *", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0833, 0.0833, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "r... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80151:FunctionDef_L5_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80151:Assign_L6_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80151:FunctionDef_L5_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80151:Assign_L7_C4"}, {"f": "ajibawa-2023/Python-Code-L... |
from yt.mods import *
from matplotlib import use; use('Agg')
import matplotlib.pyplot as plt
# Calculate
# 1. Ionization front propagation and hydrodynamic response
# 2. Deviation from 1/r^2 in the photo-ionization field in the last output
first = 1
last = 25
Myr = 3.1557e13
kpc = 3.086e21
#########################... | ajibawa-2023/Python-Code-Large/train/row_80152 | 85 | 136 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80152:ImportFrom_L1_C0", "label": "from yt.mods import *", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0074, 0.0074, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "r... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80152:FunctionDef_L16_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80152:Return_L17_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80152:FunctionDef_L20_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80152:Assign_L21_C4"}, {"f": "ajibawa-2023/Python-Co... |
from matplotlib import pyplot
from yt.mods import *
import numpy as na
def _H_NumberDensity(field, data):
"Get total Hydrogen nuclei number density."
if data.pf['MultiSpecies'] == 0:
return (0.76 * data['Density'])
fieldData = na.zeros(data['HI_Density'].shape,
dtype=data... | ajibawa-2023/Python-Code-Large/train/row_80153 | 66 | 99 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80153:ImportFrom_L1_C0", "label": "from matplotlib import pyplot", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0101, 0.0101, 0, 0.66, 0.0, 75, 0, 1, 0, 0, 75, 0, 0], "semantic": {"name": "matplotlib", "arg_names": [], "import_names": ... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80153:FunctionDef_L5_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80153:Expr_L6_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80153:FunctionDef_L5_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80153:If_L7_C4"}, {"f": "ajibawa-2023/Python-Code-Large/t... |
from matplotlib import use; use('Agg')
import matplotlib.pyplot as plt
from yt.mods import *
pf = load('DD0001/data0001')
ray = pf.h.ortho_ray(0,(0,0))
plt.subplot(311)
plt.semilogy(ray['x'], ray['Density'], c='k', ls='-', marker='.', ms=5)
plt.ylabel(r'Density (cm$^{-3}$)')
plt.subplot(312)
plt.semilogy(ray['x'], r... | ajibawa-2023/Python-Code-Large/train/row_80154 | 17 | 21 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80154:ImportFrom_L1_C0", "label": "from matplotlib import use", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0476, 0.0476, 0, 0.66, 0.0, 75, 0, 1, 0, 0, 75, 0, 0], "semantic": {"name": "matplotlib", "arg_names": [], "import_names": ["u... | [] |
from matplotlib import use; use('Agg')
import matplotlib.pyplot as plt
from yt.mods import *
pf = load('DD0001/data0001')
ray = pf.h.ortho_ray(0,(0,0))
plt.subplot(311)
plt.semilogy(ray['x'], ray['Density'], c='k', ls='-', marker='.', ms=5)
plt.ylabel(r'Density (cm$^{-3}$)')
plt.subplot(312)
plt.semilogy(ray['x'], r... | ajibawa-2023/Python-Code-Large/train/row_80155 | 17 | 21 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80155:ImportFrom_L1_C0", "label": "from matplotlib import use", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0476, 0.0476, 0, 0.66, 0.0, 75, 0, 1, 0, 0, 75, 0, 0], "semantic": {"name": "matplotlib", "arg_names": [], "import_names": ["u... | [] |
from matplotlib import use; use('Agg')
from yt.mods import *
import pylab as plt
### define problem name
problem_name = 'BrioWu-MHD-1D'
### define simulation output directory and filename base
output_dir_base = 'DD'
datafile_base = 'data'
### define output to be plotted
dumpid = '0011'
### construct input filename
... | ajibawa-2023/Python-Code-Large/train/row_80156 | 31 | 58 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80156:ImportFrom_L1_C0", "label": "from matplotlib import use", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0172, 0.0172, 0, 0.66, 0.0, 75, 0, 1, 0, 0, 75, 0, 0], "semantic": {"name": "matplotlib", "arg_names": [], "import_names": ["u... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80156:FunctionDef_L26_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80156:Return_L27_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80156:FunctionDef_L32_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80156:Return_L33_C4"}, {"f": "ajibawa-2023/Python-Co... |
from yt.mods import *
import yt.extensions.EnzoSimulation as ES
# Create image slices and plot the evolution of the total angular momentum of the system.
es = ES.EnzoSimulation("RotatingCylinder.enzo", initial_time=0.0, final_time=26)
AngMom = []
time = []
i = 0
for output in es.allOutputs:
# load up a dataset... | ajibawa-2023/Python-Code-Large/train/row_80157 | 29 | 49 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80157:ImportFrom_L1_C0", "label": "from yt.mods import *", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0204, 0.0204, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "r... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80157:For_L12_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80157:Assign_L14_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80157:For_L12_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80157:Assign_L17_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/r... |
from yt.mods import *
import pylab as pl
for dump in range(7):
pf = EnzoStaticOutput('DD%04i/noh3Damr_%04i' % (dump,dump))
dd = pf.h.all_data()
t = pf['InitialTime']
x = dd['x']
y = dd['y']
z = dd['z']
r = na.sqrt((x**2 + y**2 + z**2))
postshock_r = na.linspace(t*1./3., na.sqrt(3))
... | ajibawa-2023/Python-Code-Large/train/row_80158 | 26 | 32 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80158:ImportFrom_L1_C0", "label": "from yt.mods import *", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0312, 0.0312, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "r... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80158:For_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80158:Assign_L5_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80158:For_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80158:Assign_L6_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_8... |
from yt.mods import *
import pylab as pl
for dump in range(7):
pf = EnzoStaticOutput('DD%04i/noh3D_%04i' % (dump,dump))
dd = pf.h.all_data()
t = pf['InitialTime']
x = dd['x']
y = dd['y']
z = dd['z']
r = na.sqrt((x**2 + y**2 + z**2))
postshock_r = na.linspace(t*1./3., na.sqrt(3))
po... | ajibawa-2023/Python-Code-Large/train/row_80159 | 26 | 32 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80159:ImportFrom_L1_C0", "label": "from yt.mods import *", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0312, 0.0312, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "r... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80159:For_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80159:Assign_L5_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80159:For_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80159:Assign_L6_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_8... |
import yt.extensions.EnzoSimulation as ES
from matplotlib import pyplot
from yt.mods import *
import os
es = ES.EnzoSimulation("CollapseTestNonCosmological.enzo", initial_time=0)
output_file = 'rho_max.dat'
f = open(output_file,'w')
f.write('#t\trho_max\n')
f.close()
t = []
rho = []
output_dir = "frames"
if not os.... | ajibawa-2023/Python-Code-Large/train/row_80160 | 30 | 39 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80160:Import_L1_C0", "label": "yt.extensions.EnzoSimulation import ES", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0256, 0.0256, 0, 0.66, 0.0, 24, 0, 1, 0, 0, 24, 0, 0], "semantic": {"name": "yt.extensions.EnzoSimulation", "arg_names... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80160:If_L17_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80160:Expr_L17_C35"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80160:For_L20_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80160:Assign_L22_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row... |
from yt.mods import *
import pylab as pl
for dump in range(7):
pf = EnzoStaticOutput('DD%04i/noh2D_%04i' % (dump,dump))
dd = pf.h.all_data()
t = pf['InitialTime']
x = dd['x']
y = dd['y']
r = na.sqrt((x**2 + y**2))
postshock_r = na.linspace(t*1./3., na.sqrt(2))
postshock_den = (1 + t/po... | ajibawa-2023/Python-Code-Large/train/row_80161 | 25 | 31 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80161:ImportFrom_L1_C0", "label": "from yt.mods import *", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0323, 0.0323, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "r... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80161:For_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80161:Assign_L5_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80161:For_L4_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80161:Assign_L6_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_8... |
from yt.mods import *
# Using the parameters in the default parameter file
mach = 2.0
gamma = 1.4
sound_speed = na.sqrt(gamma) * (1.0/1.0) # see initializer for info
shock_pool_shock_density = 1.0 * ( ( (gamma + 1.0) * mach * mach)
/ ( (gamma - 1.0) * mach * mach + 2.0))
shock_pool_sh... | ajibawa-2023/Python-Code-Large/train/row_80162 | 14 | 22 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80162:ImportFrom_L1_C0", "label": "from yt.mods import *", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0455, 0.0455, 0, 0.66, 0.0, 843, 0, 1, 0, 0, 843, 0, 0], "semantic": {"name": "yt.mods", "arg_names": [], "import_names": ["*"], "r... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80162:For_L11_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80162:Assign_L12_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80162:For_L11_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80162:Assign_L13_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/r... |
from matplotlib import use; use('Agg')
from yt.mods import *
import pylab as plt
### define problem name
problem_name = 'SedovBlast-MHD-2D-Fryxell'
### define simulation output directory and filename base
output_dir_base = 'DD'
datafile_base = 'data'
### define output to be plotted
dumpid = '0011'
### construct inp... | ajibawa-2023/Python-Code-Large/train/row_80163 | 24 | 48 | 15 | ["cat_id", "level", "center", "span", "parent_depth", "parent_weight", "sibling_index", "name_hash", "rhs_type", "arg_count", "return_type", "is_async", "module_hash", "value_type", "calls_count"] | [{"id": "ajibawa-2023/Python-Code-Large/train/row_80163:ImportFrom_L1_C0", "label": "from matplotlib import use", "type": "import", "loc": [1, 1], "level": 0, "parent": null, "vector": [1, 0, 0.0208, 0.0208, 0, 0.66, 0.0, 75, 0, 1, 0, 0, 75, 0, 0], "semantic": {"name": "matplotlib", "arg_names": [], "import_names": ["u... | [{"f": "ajibawa-2023/Python-Code-Large/train/row_80163:FunctionDef_L26_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80163:Return_L27_C4"}, {"f": "ajibawa-2023/Python-Code-Large/train/row_80163:FunctionDef_L32_C0", "t": "ajibawa-2023/Python-Code-Large/train/row_80163:Return_L33_C4"}, {"f": "ajibawa-2023/Python-Co... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.