id int64 0 328k | repository_name stringlengths 7 58 | file_path stringlengths 9 302 | class_name stringlengths 5 256 | human_written_code stringlengths 16 2.16M | class_skeleton stringlengths 18 1.49M ⌀ | total_program_units int64 1 1.76k | total_doc_str int64 0 771 | AvgCountLine float64 0 7.89k | AvgCountLineBlank float64 0 297 | AvgCountLineCode float64 0 7.89k | AvgCountLineComment float64 0 7.89k | AvgCyclomatic float64 0 130 | CommentToCodeRatio float64 0 168 | CountClassBase float64 0 40 | CountClassCoupled float64 0 583 | CountClassCoupledModified float64 0 575 | CountClassDerived float64 0 5.35k | CountDeclInstanceMethod float64 0 529 | CountDeclInstanceVariable float64 0 296 | CountDeclMethod float64 0 599 | CountDeclMethodAll float64 0 1.12k | CountLine float64 1 40.4k | CountLineBlank float64 0 8.16k | CountLineCode float64 1 25.7k | CountLineCodeDecl float64 1 8.15k | CountLineCodeExe float64 0 24.2k | CountLineComment float64 0 16.5k | CountStmt float64 1 9.71k | CountStmtDecl float64 1 8.15k | CountStmtExe float64 0 9.69k | MaxCyclomatic float64 0 759 | MaxInheritanceTree float64 0 16 | MaxNesting float64 0 34 | SumCyclomatic float64 0 2.9k |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
325,400 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/array_crop.py | kamae.tensorflow.layers.array_crop.ArrayCropLayer | from kamae.tensorflow.utils import enforce_single_tensor_input
from kamae.tensorflow.typing import Tensor
import kamae
import tensorflow as tf
from .base import BaseLayer
from typing import Any, Dict, List, Optional, Union
@tf.keras.utils.register_keras_serializable(kamae.__name__)
class ArrayCropLayer(BaseLayer):
... | @tf.keras.utils.register_keras_serializable(kamae.__name__)
class ArrayCropLayer(BaseLayer):
'''
Performs a cropping of the input tensor to a certain length.
If the tensor is shorter than the specified length, it is
padded with specified pad value.
TODO: Currently only supports cropping the final di... | 8 | 5 | 18 | 2 | 10 | 6 | 2 | 0.74 | 1 | 6 | 0 | 0 | 4 | 2 | 4 | 41 | 86 | 13 | 42 | 25 | 27 | 31 | 24 | 15 | 19 | 3 | 5 | 1 | 6 |
325,401 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/array_split.py | kamae.tensorflow.layers.array_split.ArraySplitLayer | from typing import Any, Dict, List, Optional
from kamae.tensorflow.utils import enforce_single_tensor_input
import tensorflow as tf
from kamae.tensorflow.typing import Tensor
from .base import BaseLayer
import kamae
@tf.keras.utils.register_keras_serializable(kamae.__name__)
class ArraySplitLayer(BaseLayer):
"""
... | @tf.keras.utils.register_keras_serializable(kamae.__name__)
class ArraySplitLayer(BaseLayer):
'''
Performs a splitting of the input tensor into a list of tensors.
Expands dimensions to ensure the output tensors are the same shape as the input.
'''
def __init__(self, name: Optional[str]=None, input_... | 8 | 5 | 14 | 2 | 6 | 6 | 1 | 1.12 | 1 | 4 | 0 | 0 | 4 | 1 | 4 | 41 | 65 | 10 | 26 | 16 | 12 | 29 | 12 | 7 | 7 | 1 | 5 | 0 | 4 |
325,402 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/array_subtract_minimum.py | kamae.tensorflow.layers.array_subtract_minimum.ArraySubtractMinimumLayer | from .base import BaseLayer
from kamae.tensorflow.typing import Tensor
import tensorflow as tf
from kamae.tensorflow.utils import enforce_single_tensor_input
import kamae
from typing import Any, Dict, List, Optional, Union
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ArraySubtractMinimumLa... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ArraySubtractMinimumLayer(BaseLayer):
'''
TensorFlow layer that computes the difference across an axis from the minimum
non-paded element in the input tensor.
It takes a tensor of numerical value and calculates the differences bet... | 8 | 5 | 26 | 2 | 14 | 11 | 1 | 0.91 | 1 | 5 | 0 | 0 | 4 | 2 | 4 | 41 | 121 | 12 | 57 | 22 | 42 | 52 | 20 | 12 | 15 | 2 | 5 | 1 | 5 |
325,403 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/base.py | kamae.tensorflow.layers.base.BaseLayer | import kamae
from kamae.tensorflow.typing import Tensor
import tensorflow as tf
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
from functools import reduce
from typing import Any, Dict, Iterable, List, Optional, Tuple, Union
from abc import ABC, abstractmethod
@tf.keras.utils.register_keras_s... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class BaseLayer(tf.keras.layers.Layer, ABC):
'''
Abstract base layer that performs casting of inputs and outputs to specified
data types. All layers should inherit from this class.
'''
def __init__(self, name: Optional[str]=Non... | 25 | 18 | 21 | 2 | 11 | 8 | 2 | 0.76 | 2 | 9 | 0 | 66 | 15 | 6 | 17 | 37 | 384 | 44 | 194 | 63 | 152 | 147 | 98 | 40 | 80 | 7 | 4 | 2 | 41 |
325,404 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/bearing_angle.py | kamae.tensorflow.layers.bearing_angle.BearingAngleLayer | from kamae.tensorflow.typing import Tensor
from typing import Any, Dict, Iterable, List, Optional
import math
import tensorflow as tf
from tensorflow.math import atan2, cos, mod, sin
from .base import BaseLayer
import kamae
from kamae.tensorflow.utils import enforce_multiple_tensor_input
@tf.keras.utils.register_keras... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class BearingAngleLayer(BaseLayer):
'''
Computes the Bearing angle operation on a given input tensor.
If lat_lon_constant is not set, inputs must be a list of 4 tensors,
in the order of lat1, lon1, lat2, lon2.
If lat_lon_constant is... | 13 | 8 | 18 | 2 | 10 | 7 | 2 | 0.79 | 1 | 6 | 0 | 0 | 5 | 1 | 7 | 44 | 150 | 21 | 72 | 32 | 51 | 57 | 36 | 19 | 28 | 4 | 5 | 2 | 11 |
325,405 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/bin.py | kamae.tensorflow.layers.bin.BinLayer | from kamae.tensorflow.utils import enforce_single_tensor_input
import kamae
import tensorflow as tf
from kamae.utils import get_condition_operator
from kamae.tensorflow.typing import Tensor
from typing import Any, Dict, List, Optional, Union
from .base import BaseLayer
@tf.keras.utils.register_keras_serializable(packa... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class BinLayer(BaseLayer):
'''
Performs a binning operation on a given input tensor.
The binning operation is performed by comparing the input tensor to a list of
values using a list of operators. The bin label corresponding to the firs... | 8 | 5 | 31 | 3 | 17 | 12 | 2 | 0.77 | 1 | 7 | 0 | 0 | 4 | 4 | 4 | 41 | 140 | 16 | 70 | 27 | 53 | 54 | 23 | 15 | 18 | 2 | 5 | 1 | 6 |
325,406 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/bloom_encode.py | kamae.tensorflow.layers.bloom_encode.BloomEncodeLayer | import tensorflow as tf
from typing import Any, Dict, List, Optional, Union
from .base import BaseLayer
from tensorflow.keras.layers import Hashing
from kamae.tensorflow.typing import Tensor
from kamae.tensorflow.utils import enforce_single_tensor_input
import kamae
@tf.keras.utils.register_keras_serializable(package=... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class BloomEncodeLayer(BaseLayer):
'''
Performs a bloom encoding on the input tensor. Uses multiple hash functions to
encode the input tensor, significantly reducing the dimensionality of the input
and also avoiding collisions. See pape... | 8 | 5 | 34 | 2 | 19 | 13 | 3 | 0.78 | 1 | 7 | 0 | 0 | 4 | 6 | 4 | 41 | 153 | 11 | 80 | 29 | 62 | 62 | 29 | 16 | 24 | 6 | 5 | 1 | 10 |
325,407 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/bucketize.py | kamae.tensorflow.layers.bucketize.BucketizeLayer | from kamae.tensorflow.utils import enforce_single_tensor_input
from typing import Any, Dict, List, Optional
from kamae.tensorflow.typing import Tensor
import tensorflow as tf
import kamae
from .base import BaseLayer
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class BucketizeLayer(BaseLayer):
... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class BucketizeLayer(BaseLayer):
'''
Performs a bucketing operation on the input tensor.
Given a list of splits, the input tensor is bucketed into
the corresponding bucket. For example, if the splits are
[0, 1, 2, 3], then the input... | 8 | 5 | 14 | 2 | 6 | 7 | 1 | 1.38 | 1 | 5 | 0 | 0 | 4 | 1 | 4 | 41 | 72 | 10 | 26 | 17 | 12 | 36 | 15 | 8 | 10 | 2 | 5 | 1 | 5 |
325,408 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/conditional_standard_scale.py | kamae.tensorflow.layers.conditional_standard_scale.ConditionalStandardScaleLayer | from kamae.tensorflow.utils import NormalizeLayer, enforce_single_tensor_input
from typing import Any, Dict, List, Optional, Union
import kamae
import tensorflow as tf
from kamae.tensorflow.typing import Tensor
import numpy as np
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ConditionalStan... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ConditionalStandardScaleLayer(NormalizeLayer):
'''
Performs the standard scaling of the input with a masking condition.
This layer will shift and scale inputs into a distribution centered around
0 with standard deviation 1. It acc... | 6 | 4 | 34 | 0 | 18 | 17 | 1 | 1.07 | 1 | 7 | 0 | 0 | 3 | 2 | 3 | 46 | 118 | 3 | 56 | 23 | 40 | 60 | 18 | 11 | 14 | 2 | 6 | 1 | 4 |
325,409 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/cosine_similarity.py | kamae.tensorflow.layers.cosine_similarity.CosineSimilarityLayer | from kamae.tensorflow.utils import enforce_multiple_tensor_input
from .base import BaseLayer
import kamae
import tensorflow as tf
from typing import Any, Dict, Iterable, List, Optional
from kamae.tensorflow.typing import Tensor
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class CosineSimilarityL... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class CosineSimilarityLayer(BaseLayer):
'''
Computes the cosine similarity between two input tensors.
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, axis: int=-1, kee... | 8 | 5 | 18 | 2 | 9 | 8 | 1 | 0.87 | 1 | 6 | 0 | 0 | 4 | 2 | 4 | 41 | 82 | 11 | 38 | 20 | 23 | 33 | 17 | 10 | 12 | 2 | 5 | 1 | 5 |
325,410 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/current_date.py | kamae.tensorflow.layers.current_date.CurrentDateLayer | from .base import BaseLayer
from typing import Any, Dict, List, Optional
from kamae.tensorflow.utils import enforce_single_tensor_input, unix_timestamp_to_datetime
import kamae
import tensorflow as tf
from kamae.tensorflow.typing import Tensor
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class C... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class CurrentDateLayer(BaseLayer):
'''
Returns the current UTC date in yyyy-MM-dd format.
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, **kwargs: Any) -> None:
... | 8 | 5 | 12 | 1 | 5 | 6 | 1 | 1.27 | 1 | 3 | 0 | 0 | 4 | 0 | 4 | 41 | 59 | 9 | 22 | 16 | 9 | 28 | 12 | 8 | 7 | 1 | 5 | 0 | 4 |
325,411 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/current_date_time.py | kamae.tensorflow.layers.current_date_time.CurrentDateTimeLayer | import tensorflow as tf
from typing import Any, Dict, List, Optional
from .base import BaseLayer
from kamae.tensorflow.typing import Tensor
from kamae.tensorflow.utils import enforce_single_tensor_input, unix_timestamp_to_datetime
import kamae
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class C... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class CurrentDateTimeLayer(BaseLayer):
'''
Returns the current timestamp in yyyy-MM-dd HH:mm:ss.SSS format.
NOTE: Parity between this and its Spark counterpart is very difficult at the
millisecond level. We have to round the TensorFlow ... | 8 | 5 | 12 | 1 | 5 | 6 | 1 | 1.5 | 1 | 3 | 0 | 0 | 4 | 0 | 4 | 41 | 66 | 11 | 22 | 16 | 9 | 33 | 12 | 8 | 7 | 1 | 5 | 0 | 4 |
325,412 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/current_unix_timestamp.py | kamae.tensorflow.layers.current_unix_timestamp.CurrentUnixTimestampLayer | from .base import BaseLayer
import kamae
import tensorflow as tf
from kamae.tensorflow.typing import Tensor
from kamae.tensorflow.utils import enforce_single_tensor_input
from typing import Any, Dict, List, Optional
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class CurrentUnixTimestampLayer(Bas... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class CurrentUnixTimestampLayer(BaseLayer):
'''
Returns the current unix timestamp in either seconds or milliseconds.
NOTE: Parity between this and its Spark counterpart is very difficult at the
millisecond level. TensorFlow provides mu... | 8 | 5 | 18 | 2 | 9 | 7 | 2 | 0.88 | 1 | 4 | 0 | 0 | 4 | 1 | 4 | 41 | 88 | 13 | 40 | 17 | 26 | 35 | 18 | 8 | 13 | 4 | 5 | 1 | 8 |
325,413 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/date_add.py | kamae.tensorflow.layers.date_add.DateAddLayer | from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input, datetime_add_days
from typing import Any, Dict, List, Optional
from .base import BaseLayer
from kamae.tensorflow.typing import Tensor
import tensorflow as tf
import kamae
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class DateAddLayer(BaseLayer):
'''
Adds or subtracts a number of days from a date(time) string.
WARNING: This layer destroys the time component of the date column.
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optio... | 8 | 5 | 22 | 1 | 15 | 6 | 3 | 0.46 | 1 | 5 | 0 | 0 | 4 | 1 | 4 | 41 | 98 | 9 | 61 | 16 | 47 | 28 | 26 | 7 | 21 | 6 | 5 | 2 | 11 |
325,414 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/date_diff.py | kamae.tensorflow.layers.date_diff.DateDiffLayer | from kamae.tensorflow.typing import Tensor
from .base import BaseLayer
from typing import Any, Dict, List, Optional
from kamae.tensorflow.utils import datetime_total_days, enforce_multiple_tensor_input
import tensorflow as tf
import kamae
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class DateDi... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class DateDiffLayer(BaseLayer):
'''A preprocessing layer that returns the difference between two dates in days.
The inputs must be in yyyy-MM-dd (HH:mm:ss.SSS) format and
must be passed to the layer in the order [start date , end date].
... | 9 | 6 | 16 | 2 | 8 | 7 | 1 | 0.9 | 1 | 5 | 0 | 0 | 5 | 1 | 5 | 42 | 94 | 14 | 42 | 21 | 27 | 38 | 22 | 12 | 16 | 3 | 5 | 1 | 7 |
325,415 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/date_parse.py | kamae.tensorflow.layers.date_parse.DateParseLayer | from typing import Any, Dict, List, Optional
from kamae.tensorflow.typing import Tensor
import tensorflow as tf
import kamae
from .base import BaseLayer
from kamae.tensorflow.utils import datetime_day, datetime_day_of_year, datetime_hour, datetime_millisecond, datetime_minute, datetime_month, datetime_second, datetime_... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class DateParseLayer(BaseLayer):
'''
Parses a date(time) string from yyyy-MM-dd (HH:mm:ss.SSS) format
into a specified date part tensor.
Date parts can be one of the following:
- `DayOfWeek` - day of week (Monday = 1, Sunday = 7)
... | 10 | 6 | 23 | 2 | 13 | 8 | 2 | 0.86 | 1 | 7 | 0 | 0 | 4 | 3 | 5 | 42 | 149 | 19 | 70 | 24 | 53 | 60 | 26 | 13 | 20 | 2 | 5 | 1 | 8 |
325,416 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/date_time_to_unix_timestamp.py | kamae.tensorflow.layers.date_time_to_unix_timestamp.DateTimeToUnixTimestampLayer | import tensorflow as tf
from kamae.tensorflow.typing import Tensor
import kamae
from typing import Any, Dict, List, Optional
from .base import BaseLayer
from kamae.tensorflow.utils import datetime_to_unix_timestamp, enforce_single_tensor_input
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class D... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class DateTimeToUnixTimestampLayer(BaseLayer):
'''
Returns the unix timestamp from a datetime in either yyyy-MM-dd HH:mm:ss.SSS
or yyyy-MM-dd format.
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None,... | 8 | 5 | 18 | 2 | 9 | 7 | 2 | 0.8 | 1 | 4 | 0 | 0 | 4 | 1 | 4 | 41 | 82 | 10 | 40 | 17 | 26 | 32 | 19 | 8 | 14 | 4 | 5 | 1 | 8 |
325,417 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/divide.py | kamae.tensorflow.layers.divide.DivideLayer | from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
from functools import reduce
import tensorflow as tf
from typing import Any, Dict, Iterable, List, Optional, Union
from .base import BaseLayer
from kamae.tensorflow.typing import Tensor
import kamae
@tf.keras.utils.register_keras_serializable(pac... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class DivideLayer(BaseLayer):
'''
Performs the divide(x, y) operation on a given input tensor. If divisor is not set,
inputs must be a list. If divisor is set, inputs must be a tensor.
'''
def __init__(self, name: Optional[str]=Non... | 8 | 5 | 18 | 2 | 9 | 8 | 2 | 0.95 | 1 | 5 | 0 | 0 | 4 | 1 | 4 | 41 | 82 | 10 | 37 | 16 | 23 | 35 | 18 | 7 | 13 | 4 | 5 | 2 | 7 |
325,418 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/exp.py | kamae.tensorflow.layers.exp.ExpLayer | import tensorflow as tf
from kamae.tensorflow.utils import enforce_single_tensor_input
from .base import BaseLayer
from typing import Any, Dict, List, Optional
import kamae
from kamae.tensorflow.typing import Tensor
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ExpLayer(BaseLayer):
"""
... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ExpLayer(BaseLayer):
'''
Performs the exp(x) operation on a given input tensor
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, **kwargs: Any) -> None:
''... | 8 | 5 | 13 | 1 | 6 | 6 | 1 | 0.96 | 1 | 3 | 0 | 0 | 4 | 0 | 4 | 41 | 62 | 9 | 27 | 14 | 14 | 26 | 10 | 6 | 5 | 1 | 5 | 0 | 4 |
325,419 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/exponent.py | kamae.tensorflow.layers.exponent.ExponentLayer | import kamae
from kamae.tensorflow.typing import Tensor
from typing import Any, Dict, List, Optional
from .base import BaseLayer
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
import tensorflow as tf
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ExponentLayer(BaseL... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ExponentLayer(BaseLayer):
'''
Performs the x^exponent operation on a given input tensor
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, exponent: Optional[float]... | 8 | 5 | 17 | 2 | 9 | 7 | 2 | 0.74 | 1 | 5 | 0 | 0 | 4 | 1 | 4 | 41 | 78 | 10 | 39 | 16 | 25 | 29 | 18 | 7 | 13 | 4 | 5 | 2 | 7 |
325,420 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/hash_index.py | kamae.tensorflow.layers.hash_index.HashIndexLayer | import tensorflow as tf
from tensorflow.keras.layers import Hashing
from kamae.tensorflow.typing import Tensor
from .base import BaseLayer
from kamae.tensorflow.utils import enforce_single_tensor_input
import kamae
from typing import Any, Dict, List, Optional, Union
@tf.keras.utils.register_keras_serializable(package=... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class HashIndexLayer(BaseLayer):
'''
Wrapper around the Keras Hashing layer which hashes and bins categorical features.
This layer transforms categorical inputs to hashed output. It element-wise
converts ints or strings to ints in a fix... | 8 | 5 | 14 | 1 | 6 | 7 | 1 | 1.54 | 1 | 4 | 0 | 0 | 4 | 3 | 4 | 41 | 77 | 11 | 26 | 19 | 11 | 40 | 14 | 9 | 9 | 1 | 5 | 0 | 4 |
325,421 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/haversine_distance.py | kamae.tensorflow.layers.haversine_distance.HaversineDistanceLayer | from kamae.tensorflow.utils import enforce_multiple_tensor_input
from typing import Any, Dict, Iterable, List, Optional
from kamae.tensorflow.typing import Tensor
import math
from .base import BaseLayer
import tensorflow as tf
import kamae
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class Haver... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class HaversineDistanceLayer(BaseLayer):
'''
Computes the haversine distance operation on a given input tensor.
If lat_lon_constant is not set, inputs must be a list of 4 tensors,
in the order of lat1, lon1, lat2, lon2.
If lat_lon_c... | 11 | 7 | 21 | 2 | 12 | 7 | 2 | 0.71 | 1 | 6 | 0 | 0 | 5 | 3 | 6 | 43 | 143 | 18 | 73 | 33 | 53 | 52 | 37 | 20 | 30 | 4 | 5 | 2 | 12 |
325,422 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/identity.py | kamae.tensorflow.layers.identity.IdentityLayer | from typing import Any, Dict, List, Optional
import tensorflow as tf
from kamae.tensorflow.utils import enforce_single_tensor_input
from kamae.tensorflow.typing import Tensor
from .base import BaseLayer
import kamae
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class IdentityLayer(BaseLayer):
... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class IdentityLayer(BaseLayer):
'''
Performs an identity transform on the input tensor.
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, **kwargs: Any) -> None:
... | 8 | 5 | 11 | 1 | 4 | 6 | 1 | 1.3 | 1 | 3 | 0 | 0 | 4 | 0 | 4 | 41 | 55 | 9 | 20 | 14 | 7 | 26 | 10 | 6 | 5 | 1 | 5 | 0 | 4 |
325,423 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/if_statement.py | kamae.tensorflow.layers.if_statement.IfStatementLayer | from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
from numbers import Number
from kamae.utils import get_condition_operator
from .base import BaseLayer
import kamae
import tensorflow as tf
from typing import Any, Dict, Iterable, List, Optional, Union
from kamae.tensorflow.typing import Tensor
@t... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class IfStatementLayer(BaseLayer):
'''
Performs an if statement on the input tensor,
returning a tensor of the same shape as the input tensor.
The condition operator can be one of the following:
- "eq": Equal to
- "neq": Not equ... | 10 | 7 | 37 | 2 | 23 | 12 | 3 | 0.63 | 1 | 9 | 0 | 0 | 6 | 4 | 6 | 43 | 252 | 22 | 141 | 38 | 118 | 89 | 54 | 22 | 47 | 6 | 5 | 2 | 18 |
325,424 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/impute.py | kamae.tensorflow.layers.impute.ImputeLayer | from kamae.tensorflow.typing import Tensor
from .base import BaseLayer
import tensorflow as tf
import kamae
from typing import Any, Dict, List, Optional, Union
from kamae.tensorflow.utils import enforce_single_tensor_input
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ImputeLayer(BaseLayer)... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ImputeLayer(BaseLayer):
'''
Performs imputation on the input.
Where the input data is equal to the specified mask value, this layer will replace
the data with the impute value calculated at preprocessing time.
The impute value... | 8 | 5 | 20 | 1 | 12 | 7 | 2 | 0.72 | 1 | 6 | 0 | 0 | 4 | 2 | 4 | 41 | 93 | 7 | 50 | 21 | 35 | 36 | 22 | 11 | 17 | 2 | 5 | 1 | 6 |
325,425 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/lambda_function.py | kamae.tensorflow.layers.lambda_function.LambdaFunctionLayer | import kamae
from typing import Any, Callable, Dict, Iterable, List, Optional, Union
from .base import BaseLayer
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
import tensorflow as tf
from kamae.tensorflow.typing import Tensor
@tf.keras.utils.register_keras_serializable(package=kamae.__name__... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class LambdaFunctionLayer(BaseLayer, tf.keras.layers.Lambda):
'''
Performs the lambda function operation on a given input tensor
WARNING: This layer relies on a `tf.keras.layers.Lambda` layer which have
(de)serialization limitations!
... | 8 | 5 | 14 | 1 | 7 | 7 | 1 | 1.17 | 2 | 3 | 0 | 0 | 4 | 0 | 4 | 41 | 74 | 11 | 29 | 17 | 13 | 34 | 12 | 6 | 7 | 2 | 5 | 1 | 5 |
325,426 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/list_max.py | kamae.tensorflow.layers.list_max.ListMaxLayer | import tensorflow as tf
import kamae
from kamae.tensorflow.typing import Tensor
from .base import BaseLayer
from typing import Any, Dict, Iterable, List, Optional
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input, get_top_n
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
clas... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ListMaxLayer(BaseLayer):
'''
Calculate the max across the axis dimension.
- If one tensor is passed, the transformer calculates the max of the tensor
based on all the items in the given axis dimension.
- If inputCols is set, t... | 8 | 5 | 31 | 3 | 19 | 9 | 3 | 0.61 | 1 | 6 | 0 | 0 | 4 | 5 | 4 | 41 | 146 | 19 | 79 | 36 | 61 | 48 | 35 | 23 | 30 | 7 | 5 | 1 | 10 |
325,427 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/list_mean.py | kamae.tensorflow.layers.list_mean.ListMeanLayer | from typing import Any, Dict, Iterable, List, Optional
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input, get_top_n
import kamae
from kamae.tensorflow.typing import Tensor
from .base import BaseLayer
import tensorflow as tf
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
clas... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ListMeanLayer(BaseLayer):
'''
Calculate the mean across the axis dimension.
- If one tensor is passed, the transformer calculates the mean of the tensor
based on all the items in the given axis dimension.
- If inputCols is set... | 8 | 5 | 36 | 4 | 24 | 9 | 3 | 0.5 | 1 | 6 | 0 | 0 | 4 | 5 | 4 | 41 | 167 | 20 | 98 | 36 | 80 | 49 | 38 | 23 | 33 | 7 | 5 | 1 | 10 |
325,428 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/list_median.py | kamae.tensorflow.layers.list_median.ListMedianLayer | from typing import Any, Dict, Iterable, List, Optional
import kamae
from .base import BaseLayer
from kamae.tensorflow.typing import Tensor
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input, get_top_n
import tensorflow as tf
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
clas... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ListMedianLayer(BaseLayer):
'''
Calculate the median across the axis dimension.
- If one tensor is passed, the transformer calculates the median of the tensor
based on all the items in the given axis dimension.
- If inputCols ... | 9 | 6 | 36 | 4 | 21 | 10 | 2 | 0.56 | 1 | 7 | 0 | 0 | 5 | 5 | 5 | 42 | 201 | 29 | 110 | 45 | 91 | 62 | 48 | 32 | 42 | 7 | 5 | 1 | 11 |
325,429 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/list_min.py | kamae.tensorflow.layers.list_min.ListMinLayer | from typing import Any, Dict, Iterable, List, Optional
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input, get_top_n
import tensorflow as tf
from .base import BaseLayer
import kamae
from kamae.tensorflow.typing import Tensor
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
clas... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ListMinLayer(BaseLayer):
'''
Calculate the min across the axis dimension.
- If one tensor is passed, the transformer calculates the min of the tensor
based on all the items in the given axis dimension.
- If inputCols is set, t... | 8 | 5 | 31 | 3 | 19 | 9 | 3 | 0.6 | 1 | 6 | 0 | 0 | 4 | 5 | 4 | 41 | 147 | 19 | 80 | 37 | 62 | 48 | 36 | 24 | 31 | 7 | 5 | 1 | 10 |
325,430 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/list_rank.py | kamae.tensorflow.layers.list_rank.ListRankLayer | from kamae.tensorflow.utils import enforce_single_tensor_input
import kamae
from kamae.tensorflow.typing import Tensor
from typing import Any, Dict, Iterable, List, Optional
import tensorflow as tf
from .base import BaseLayer
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ListRankLayer(BaseL... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ListRankLayer(BaseLayer):
'''
Calculate the rank across the axis dimension.
Example: calculate the rank of items within a query, given the score.
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=Non... | 8 | 5 | 19 | 1 | 13 | 6 | 1 | 0.49 | 1 | 4 | 0 | 0 | 4 | 2 | 4 | 41 | 88 | 9 | 53 | 18 | 38 | 26 | 13 | 8 | 8 | 2 | 5 | 0 | 5 |
325,431 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/list_std_dev.py | kamae.tensorflow.layers.list_std_dev.ListStdDevLayer | from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input, get_top_n
from typing import Any, Dict, Iterable, List, Optional
import kamae
from kamae.tensorflow.typing import Tensor
import tensorflow as tf
from .base import BaseLayer
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
clas... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ListStdDevLayer(BaseLayer):
'''
Calculate the average across the axis dimension.
- If one tensor is passed, the transformer calculates the average of the tensor
based on all the items in the given axis dimension.
- If inputCol... | 8 | 5 | 41 | 4 | 27 | 10 | 3 | 0.46 | 1 | 6 | 0 | 0 | 4 | 5 | 4 | 41 | 185 | 22 | 112 | 41 | 94 | 51 | 44 | 28 | 39 | 7 | 5 | 1 | 10 |
325,432 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/log.py | kamae.tensorflow.layers.log.LogLayer | import tensorflow as tf
from kamae.tensorflow.utils import enforce_single_tensor_input
from .base import BaseLayer
from typing import Any, Dict, List, Optional
import kamae
from kamae.tensorflow.typing import Tensor
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class LogLayer(BaseLayer):
"""
... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class LogLayer(BaseLayer):
'''
Performs the log(alpha + x) operation on a given input tensor
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, alpha: float=0.0, **kwargs... | 8 | 5 | 15 | 2 | 7 | 7 | 1 | 0.97 | 1 | 4 | 0 | 0 | 4 | 1 | 4 | 41 | 69 | 10 | 30 | 16 | 16 | 29 | 12 | 7 | 7 | 1 | 5 | 0 | 4 |
325,433 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/logical_and.py | kamae.tensorflow.layers.logical_and.LogicalAndLayer | import tensorflow as tf
from kamae.tensorflow.utils import enforce_multiple_tensor_input
from .base import BaseLayer
import kamae
from functools import reduce
from typing import Any, Dict, Iterable, List, Optional
from kamae.tensorflow.typing import Tensor
@tf.keras.utils.register_keras_serializable(package=kamae.__na... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class LogicalAndLayer(BaseLayer):
'''
Performs the and(x, y) operation on a given input tensor.
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, **kwargs: Any) -> None:... | 8 | 5 | 12 | 1 | 5 | 6 | 1 | 1.18 | 1 | 5 | 0 | 0 | 4 | 0 | 4 | 41 | 57 | 9 | 22 | 14 | 9 | 26 | 12 | 6 | 7 | 2 | 5 | 1 | 5 |
325,434 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/logical_not.py | kamae.tensorflow.layers.logical_not.LogicalNotLayer | import tensorflow as tf
import kamae
from kamae.tensorflow.utils import enforce_single_tensor_input
from .base import BaseLayer
from typing import Any, Dict, List, Optional
from kamae.tensorflow.typing import Tensor
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class LogicalNotLayer(BaseLayer):
... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class LogicalNotLayer(BaseLayer):
'''
Performs the not operation on a given input tensor.
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, **kwargs: Any) -> None:
... | 8 | 5 | 11 | 1 | 4 | 6 | 1 | 1.3 | 1 | 4 | 0 | 0 | 4 | 0 | 4 | 41 | 55 | 9 | 20 | 14 | 7 | 26 | 10 | 6 | 5 | 1 | 5 | 0 | 4 |
325,435 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/logical_or.py | kamae.tensorflow.layers.logical_or.LogicalOrLayer | from typing import Any, Dict, Iterable, List, Optional
from functools import reduce
from kamae.tensorflow.typing import Tensor
from kamae.tensorflow.utils import enforce_multiple_tensor_input
import kamae
from .base import BaseLayer
import tensorflow as tf
@tf.keras.utils.register_keras_serializable(package=kamae.__na... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class LogicalOrLayer(BaseLayer):
'''
Performs the or(x, y) operation on a given input tensor.
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, **kwargs: Any) -> None:
... | 8 | 5 | 12 | 1 | 5 | 6 | 1 | 1.18 | 1 | 5 | 0 | 0 | 4 | 0 | 4 | 41 | 57 | 9 | 22 | 14 | 9 | 26 | 12 | 6 | 7 | 2 | 5 | 1 | 5 |
325,436 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/max.py | kamae.tensorflow.layers.max.MaxLayer | from .base import BaseLayer
from functools import reduce
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
import tensorflow as tf
from typing import Any, Dict, Iterable, List, Optional, Union
from kamae.tensorflow.typing import Tensor
import kamae
@tf.keras.utils.register_keras_serializable(pac... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class MaxLayer(BaseLayer):
'''
Performs the max(x, y) operation on a given input tensor.
If max_constant is not set, inputs are assumed to be a list of tensors and
the max of all the tensors is computed.
If max_constant is set, inpu... | 8 | 5 | 20 | 2 | 12 | 7 | 2 | 0.65 | 1 | 5 | 0 | 0 | 4 | 1 | 4 | 41 | 94 | 10 | 51 | 17 | 37 | 33 | 19 | 8 | 14 | 4 | 5 | 2 | 7 |
325,437 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/mean.py | kamae.tensorflow.layers.mean.MeanLayer | import tensorflow as tf
from functools import reduce
from typing import Any, Dict, Iterable, List, Optional, Union
from kamae.tensorflow.typing import Tensor
from .base import BaseLayer
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
import kamae
@tf.keras.utils.register_keras_serializable(pac... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class MeanLayer(BaseLayer):
'''
Performs the mean(x, y) operation on a given input tensor.
If mean_constant is not set, inputs are assumed to be a list of tensors and
the mean of all the tensors is computed.
If mean_constant is set,... | 8 | 5 | 21 | 2 | 12 | 7 | 2 | 0.65 | 1 | 5 | 0 | 0 | 4 | 1 | 4 | 41 | 97 | 11 | 52 | 18 | 38 | 34 | 19 | 8 | 14 | 4 | 5 | 2 | 7 |
325,438 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/min.py | kamae.tensorflow.layers.min.MinLayer | import tensorflow as tf
from .base import BaseLayer
from functools import reduce
from kamae.tensorflow.typing import Tensor
from typing import Any, Dict, Iterable, List, Optional, Union
import kamae
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
@tf.keras.utils.register_keras_serializable(pac... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class MinLayer(BaseLayer):
'''
Performs the min(x, y) operation on a given input tensor.
If min_constant is not set, inputs are assumed to be a list of tensors and
the min of all the tensors is computed.
If min_constant is set, inpu... | 8 | 5 | 21 | 2 | 12 | 7 | 2 | 0.65 | 1 | 5 | 0 | 0 | 4 | 1 | 4 | 41 | 95 | 11 | 51 | 17 | 37 | 33 | 19 | 8 | 14 | 4 | 5 | 2 | 7 |
325,439 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/min_hash_index.py | kamae.tensorflow.layers.min_hash_index.MinHashIndexLayer | from typing import Any, Dict, List, Optional
from kamae.tensorflow.utils import enforce_single_tensor_input
import tensorflow as tf
from .base import BaseLayer
from tensorflow.keras.layers import Hashing
import kamae
from kamae.tensorflow.typing import Tensor
@tf.keras.utils.register_keras_serializable(package=kamae._... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class MinHashIndexLayer(BaseLayer):
'''
Performs min hashing of the input tensor as described here:
https://en.wikipedia.org/wiki/MinHash
MinHash approximates the Jaccard similarity between sets by hashing the elements of
the sets a... | 8 | 5 | 23 | 2 | 12 | 9 | 2 | 0.92 | 1 | 5 | 0 | 0 | 4 | 4 | 4 | 41 | 113 | 13 | 52 | 27 | 36 | 48 | 24 | 16 | 19 | 3 | 5 | 2 | 6 |
325,440 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/min_max_scale.py | kamae.tensorflow.layers.min_max_scale.MinMaxScaleLayer | from kamae.tensorflow.typing import Tensor
from kamae.tensorflow.utils import enforce_single_tensor_input, listify_tensors
from .base import BaseLayer
import tensorflow as tf
import kamae
import numpy as np
from typing import Any, Dict, List, Optional, Tuple, Union
@tf.keras.utils.register_keras_serializable(package=k... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class MinMaxScaleLayer(BaseLayer):
'''
Performs a min-max scaling operation on the input tensor(s).
This is used to standardize/transform the input tensor
to the range [0, 1] using the minimum and maximum values.
Formula: (x - min)/... | 11 | 8 | 22 | 2 | 12 | 9 | 3 | 0.74 | 1 | 9 | 0 | 0 | 7 | 7 | 7 | 44 | 174 | 20 | 89 | 38 | 69 | 66 | 50 | 26 | 42 | 7 | 5 | 2 | 18 |
325,441 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/modulo.py | kamae.tensorflow.layers.modulo.ModuloLayer | from kamae.tensorflow.typing import Tensor
from typing import Any, Dict, Iterable, List, Optional, Union
import kamae
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
from .base import BaseLayer
import tensorflow as tf
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class Mo... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class ModuloLayer(BaseLayer):
'''
Performs the modulo(x, y) operation on a given input tensor.
If divisor is not set, inputs are assumed to be a list of two tensors and the
first tensor is modulo'd by the second.
If divisor is set, ... | 8 | 5 | 20 | 2 | 12 | 7 | 2 | 0.67 | 1 | 5 | 0 | 0 | 4 | 1 | 4 | 41 | 92 | 10 | 49 | 17 | 35 | 33 | 19 | 8 | 14 | 4 | 5 | 2 | 7 |
325,442 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/multiply.py | kamae.tensorflow.layers.multiply.MultiplyLayer | from .base import BaseLayer
from kamae.tensorflow.typing import Tensor
import kamae
import tensorflow as tf
from functools import reduce
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
from typing import Any, Dict, Iterable, List, Optional, Union
@tf.keras.utils.register_keras_serializable(pac... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class MultiplyLayer(BaseLayer):
'''
Performs the multiply(x, y) operation on a given input tensor.
If multiplier is not set, inputs are assumed to be a list of tensors and multiplied.
If multiplier is set, inputs must be a tensor.
'... | 8 | 5 | 20 | 2 | 12 | 7 | 2 | 0.65 | 1 | 5 | 0 | 0 | 4 | 1 | 4 | 41 | 92 | 11 | 49 | 17 | 35 | 32 | 19 | 8 | 14 | 4 | 5 | 2 | 7 |
325,443 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/numerical_if_statement.py | kamae.tensorflow.layers.numerical_if_statement.NumericalIfStatementLayer | from kamae.tensorflow.typing import Tensor
import tensorflow as tf
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
from typing import Any, Dict, Iterable, List, Optional, Union
from kamae.utils import get_condition_operator
from .base import BaseLayer
import kamae
@tf.keras.utils.register_kera... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class NumericalIfStatementLayer(BaseLayer):
'''
Performs a numerical if statement on the input tensor,
returning a tensor of the same shape as the input tensor.
The condition operator can be one of the following:
- "eq": Equal to
... | 9 | 6 | 30 | 2 | 16 | 13 | 2 | 0.99 | 1 | 5 | 0 | 0 | 5 | 4 | 5 | 42 | 181 | 18 | 82 | 32 | 62 | 81 | 33 | 18 | 27 | 3 | 5 | 2 | 9 |
325,444 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/one_hot_encode.py | kamae.tensorflow.layers.one_hot_encode.OneHotEncodeLayer | import tensorflow as tf
from typing import Any, Dict, List, Optional, Union
from kamae.tensorflow.utils import enforce_single_tensor_input
from .base import BaseLayer
from kamae.tensorflow.typing import Tensor
import kamae
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class OneHotEncodeLayer(Base... | null | 8 | 5 | 28 | 2 | 15 | 11 | 2 | 0.87 | 1 | 5 | 0 | 1 | 4 | 6 | 4 | 41 | 128 | 14 | 61 | 30 | 43 | 53 | 24 | 17 | 19 | 5 | 5 | 1 | 8 |
325,445 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/one_hot_encode.py | kamae.tensorflow.layers.one_hot_encode.OneHotLayer | from typing import Any, Dict, List, Optional, Union
import warnings
import kamae
import tensorflow as tf
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class OneHotLayer(OneHotEncodeLayer):
def __init__(self, *args: Any, **kwargs: Any) -> None:
warnings.warn('OneHotLayer is deprecated... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class OneHotLayer(OneHotEncodeLayer):
def __init__(self, *args: Any, **kwargs: Any) -> None:
pass | 3 | 0 | 8 | 0 | 8 | 0 | 1 | 0 | 1 | 3 | 0 | 0 | 1 | 0 | 1 | 42 | 9 | 0 | 9 | 2 | 7 | 0 | 4 | 2 | 2 | 1 | 6 | 0 | 1 |
325,446 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/ordinal_array_encode.py | kamae.tensorflow.layers.ordinal_array_encode.OrdinalArrayEncodeLayer | from kamae.tensorflow.typing import Tensor
import tensorflow as tf
from kamae.tensorflow.utils import enforce_single_tensor_input, map_fn_w_axis
import kamae
from .base import BaseLayer
from typing import Any, Dict, List, Optional
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class OrdinalArrayEn... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class OrdinalArrayEncodeLayer(BaseLayer):
'''
Transformer that encodes an array of strings into an array of integers.
The transformer will map each unique string in the array to an integer,
according to the order in which they appear in... | 10 | 5 | 25 | 2 | 16 | 7 | 1 | 0.7 | 1 | 4 | 0 | 0 | 4 | 2 | 4 | 41 | 112 | 15 | 57 | 26 | 40 | 40 | 25 | 15 | 19 | 3 | 5 | 2 | 7 |
325,447 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/round.py | kamae.tensorflow.layers.round.RoundLayer | import kamae
from typing import Any, Dict, List, Optional
from .base import BaseLayer
from kamae.tensorflow.typing import Tensor
import tensorflow as tf
from kamae.tensorflow.utils import enforce_single_tensor_input
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class RoundLayer(BaseLayer):
""... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class RoundLayer(BaseLayer):
'''
Performs a standard rounding operation on the input tensor.
Supported rounding types are 'ceil', 'floor' and 'round'.
- 'ceil' rounds up to the nearest integer.
- 'floor' rounds down to the nearest i... | 8 | 5 | 15 | 2 | 7 | 6 | 2 | 1 | 1 | 4 | 0 | 0 | 4 | 1 | 4 | 41 | 75 | 11 | 32 | 16 | 18 | 32 | 18 | 7 | 13 | 4 | 5 | 1 | 8 |
325,448 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/round_to_decimal.py | kamae.tensorflow.layers.round_to_decimal.RoundToDecimalLayer | from .base import BaseLayer
from kamae.tensorflow.utils import enforce_single_tensor_input
from typing import Any, Dict, List, Optional
import tensorflow as tf
import kamae
from kamae.tensorflow.typing import Tensor
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class RoundToDecimalLayer(BaseLayer... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class RoundToDecimalLayer(BaseLayer):
'''
Performs a rounding to the nearest decimal operation on the input tensor.
If the specified number of decimals is too large for the input precision type,
this operation can result in overflow. Th... | 8 | 5 | 15 | 2 | 7 | 7 | 2 | 1.06 | 1 | 5 | 0 | 0 | 4 | 1 | 4 | 41 | 77 | 11 | 32 | 18 | 18 | 34 | 18 | 9 | 13 | 2 | 5 | 1 | 6 |
325,449 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/standard_scale.py | kamae.tensorflow.layers.standard_scale.StandardScaleLayer | from typing import Any, Dict, List, Optional, Union
import kamae
from kamae.tensorflow.utils import NormalizeLayer, enforce_single_tensor_input
import numpy as np
from kamae.tensorflow.typing import Tensor
import tensorflow as tf
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StandardScaleLa... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StandardScaleLayer(NormalizeLayer):
'''
Performs the standard scaling of the input.
This layer will shift and scale inputs into a distribution centered around
0 with standard deviation 1. It accomplishes this by precomputing the m... | 6 | 4 | 29 | 0 | 14 | 15 | 1 | 1.2 | 1 | 6 | 0 | 0 | 3 | 1 | 3 | 46 | 100 | 3 | 44 | 21 | 29 | 53 | 16 | 10 | 12 | 2 | 6 | 1 | 4 |
325,450 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_affix.py | kamae.tensorflow.layers.string_affix.StringAffixLayer | import tensorflow as tf
from .base import BaseLayer
from typing import Any, Dict, List, Optional
import kamae
from kamae.tensorflow.utils import enforce_single_tensor_input
from kamae.tensorflow.typing import Tensor
@tf.keras.utils.register_keras_serializable(kamae.__name__)
class StringAffixLayer(BaseLayer):
"""
... | @tf.keras.utils.register_keras_serializable(kamae.__name__)
class StringAffixLayer(BaseLayer):
'''
Performs a prefixing and suffing on the input tensor.
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, prefix: Optional[str]=None, suffix... | 9 | 6 | 14 | 1 | 7 | 6 | 2 | 0.87 | 1 | 4 | 0 | 0 | 5 | 2 | 5 | 42 | 81 | 10 | 38 | 20 | 22 | 33 | 22 | 10 | 16 | 3 | 5 | 1 | 8 |
325,451 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_array_constant.py | kamae.tensorflow.layers.string_array_constant.StringArrayConstantLayer | from typing import Any, Dict, List, Optional
from kamae.tensorflow.typing import Tensor
from .base import BaseLayer
import tensorflow as tf
from kamae.tensorflow.utils import enforce_single_tensor_input
import kamae
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringArrayConstantLayer(Base... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringArrayConstantLayer(BaseLayer):
'''
Tensorflow keras layer that outputs a constant string array.
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, constant_st... | 8 | 5 | 14 | 1 | 7 | 6 | 1 | 0.97 | 1 | 3 | 0 | 0 | 4 | 1 | 4 | 41 | 66 | 9 | 29 | 20 | 15 | 28 | 16 | 11 | 11 | 1 | 5 | 0 | 4 |
325,452 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_case.py | kamae.tensorflow.layers.string_case.StringCaseLayer | from kamae.tensorflow.typing import Tensor
from kamae.tensorflow.utils import enforce_single_tensor_input
from .base import BaseLayer
import kamae
from typing import Any, Dict, List, Optional
import tensorflow as tf
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringCaseLayer(BaseLayer):
... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringCaseLayer(BaseLayer):
'''
Performs a string case transform on the input tensor.
Supported string case types are 'upper' and 'lower'.
'''
def __init__(self, string_case_type: str='lower', name: Optional[str]=None, input_... | 8 | 5 | 15 | 2 | 7 | 6 | 2 | 0.94 | 1 | 4 | 0 | 0 | 4 | 1 | 4 | 41 | 70 | 10 | 31 | 16 | 17 | 29 | 15 | 7 | 10 | 3 | 5 | 1 | 6 |
325,453 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_concatenate.py | kamae.tensorflow.layers.string_concatenate.StringConcatenateLayer | from kamae.tensorflow.typing import Tensor
from typing import Any, Dict, Iterable, List, Optional
from .base import BaseLayer
from kamae.tensorflow.utils import enforce_multiple_tensor_input
import tensorflow as tf
import kamae
@tf.keras.utils.register_keras_serializable(kamae.__name__)
class StringConcatenateLayer(Ba... | @tf.keras.utils.register_keras_serializable(kamae.__name__)
class StringConcatenateLayer(BaseLayer):
'''
Performs a concatenation of the input tensors.
'''
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, separator: str='_', **kwargs: Any) ... | 8 | 5 | 13 | 1 | 5 | 7 | 1 | 1.26 | 1 | 3 | 0 | 0 | 4 | 1 | 4 | 41 | 61 | 9 | 23 | 16 | 9 | 29 | 12 | 7 | 7 | 1 | 5 | 0 | 4 |
325,454 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_contains.py | kamae.tensorflow.layers.string_contains.StringContainsLayer | from typing import Any, Dict, Iterable, List, Optional, Union
from kamae.tensorflow.typing import Tensor
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
import tensorflow as tf
import kamae
from .base import BaseLayer
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class St... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringContainsLayer(BaseLayer):
'''
Performs a string contains operation on the input tensor,
matching against a string constant or element-wise against a second input tensor.
WARNING: While it works, the use of tensors in matchin... | 11 | 6 | 28 | 3 | 17 | 8 | 2 | 0.61 | 1 | 5 | 0 | 0 | 5 | 2 | 5 | 42 | 178 | 20 | 98 | 34 | 78 | 60 | 40 | 21 | 33 | 6 | 5 | 2 | 14 |
325,455 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_contains_list.py | kamae.tensorflow.layers.string_contains_list.StringContainsListLayer | from typing import Any, Dict, List, Optional
import kamae
from kamae.tensorflow.typing import Tensor
from .base import BaseLayer
import tensorflow as tf
from kamae.tensorflow.utils import enforce_single_tensor_input
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringContainsListLayer(BaseL... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringContainsListLayer(BaseLayer):
'''
Performs a string contains operation on the input tensor over entries in
the string constant list.
This implementation does not support matching of newline characters or empty
strings.
... | 9 | 6 | 21 | 1 | 13 | 7 | 2 | 0.59 | 1 | 4 | 0 | 0 | 5 | 2 | 5 | 42 | 121 | 13 | 68 | 24 | 52 | 40 | 23 | 14 | 17 | 3 | 5 | 2 | 8 |
325,456 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_equals_if_statement.py | kamae.tensorflow.layers.string_equals_if_statement.StringEqualsIfStatementLayer | from kamae.tensorflow.typing import Tensor
import kamae
from typing import Any, Dict, Iterable, List, Optional, Union
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
import tensorflow as tf
from .base import BaseLayer
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class St... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringEqualsIfStatementLayer(BaseLayer):
'''
Performs a string if equals statement on the input tensor,
returning a tensor of the same shape as the input tensor.
The value to compare must be a string. We will cast the input tensor... | 9 | 6 | 30 | 2 | 16 | 12 | 2 | 0.83 | 1 | 4 | 0 | 0 | 5 | 3 | 5 | 42 | 171 | 17 | 84 | 28 | 67 | 70 | 33 | 17 | 27 | 5 | 5 | 2 | 11 |
325,457 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_index.py | kamae.tensorflow.layers.string_index.StringIndexLayer | from kamae.tensorflow.utils import enforce_single_tensor_input
import kamae
from typing import Any, Dict, List, Optional, Union
from tensorflow.keras.layers import StringLookup
import tensorflow as tf
from kamae.tensorflow.typing import Tensor
from .base import BaseLayer
@tf.keras.utils.register_keras_serializable(pac... | null | 8 | 5 | 21 | 2 | 10 | 10 | 1 | 1.05 | 1 | 4 | 0 | 0 | 4 | 5 | 4 | 41 | 97 | 11 | 42 | 23 | 25 | 44 | 16 | 11 | 11 | 1 | 5 | 0 | 4 |
325,458 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_isin_list.py | kamae.tensorflow.layers.string_isin_list.StringIsInListLayer | from typing import Any, Dict, List, Optional
import kamae
from .base import BaseLayer
from kamae.tensorflow.typing import Tensor
from kamae.tensorflow.utils import enforce_single_tensor_input
import tensorflow as tf
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringIsInListLayer(BaseLayer... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringIsInListLayer(BaseLayer):
'''
Performs a string isin operation on the input tensor over entries in
the string constant list.
'''
def __init__(self, string_constant_list: List[str], name: Optional[str]=None, input_dtype:... | 8 | 5 | 17 | 1 | 9 | 7 | 1 | 0.78 | 1 | 4 | 0 | 0 | 4 | 2 | 4 | 41 | 80 | 9 | 40 | 23 | 25 | 31 | 18 | 13 | 13 | 2 | 5 | 0 | 5 |
325,459 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_list_to_string.py | kamae.tensorflow.layers.string_list_to_string.StringListToStringLayer | from kamae.tensorflow.typing import Tensor
from kamae.tensorflow.utils import enforce_single_tensor_input
from typing import Any, Dict, List, Optional
import tensorflow as tf
from .base import BaseLayer
import kamae
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringListToStringLayer(BaseL... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringListToStringLayer(BaseLayer):
'''
A layer that converts a list of strings to a single string along the specified
axis.
If `keepdims` is `True`, the shape is retained.
'''
def __init__(self, name: Optional[str]=None,... | 8 | 5 | 18 | 2 | 8 | 8 | 1 | 1.06 | 1 | 5 | 0 | 0 | 4 | 3 | 4 | 41 | 82 | 10 | 35 | 20 | 19 | 37 | 14 | 9 | 9 | 1 | 5 | 0 | 4 |
325,460 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_map.py | kamae.tensorflow.layers.string_map.StringMapLayer | from kamae.tensorflow.typing import Tensor
from typing import Any, Dict, List, Optional
import tensorflow as tf
from kamae.tensorflow.utils import enforce_single_tensor_input
import kamae
from .base import BaseLayer
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringMapLayer(BaseLayer):
... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringMapLayer(BaseLayer):
'''
StringMapLayer layer for TensorFlow.
'''
def __init__(self, string_match_values: List[str], string_replace_values: List[str], default_replace_value: Optional[str]=None, name: Optional[str]=None, inp... | 8 | 5 | 24 | 3 | 12 | 9 | 2 | 0.77 | 1 | 4 | 0 | 0 | 4 | 3 | 4 | 41 | 106 | 14 | 52 | 27 | 36 | 40 | 26 | 16 | 21 | 5 | 5 | 3 | 8 |
325,461 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_replace.py | kamae.tensorflow.layers.string_replace.StringReplaceLayer | import tensorflow as tf
from typing import Any, Dict, Iterable, List, Optional, Union
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
from kamae.tensorflow.typing import Tensor
from .base import BaseLayer
import kamae
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class St... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringReplaceLayer(BaseLayer):
'''
StringReplaceLayer layer for TensorFlow.
'''
def __init__(self, string_match_constant: Optional[str]=None, string_replace_constant: Optional[str]=None, regex: bool=False, name: Optional[str]=Non... | 10 | 6 | 36 | 4 | 21 | 12 | 3 | 0.65 | 1 | 5 | 0 | 0 | 5 | 3 | 5 | 42 | 217 | 26 | 116 | 34 | 96 | 75 | 42 | 21 | 35 | 7 | 5 | 3 | 16 |
325,462 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/string_to_string_list.py | kamae.tensorflow.layers.string_to_string_list.StringToStringListLayer | from kamae.tensorflow.utils import enforce_single_tensor_input
from typing import Any, Dict, List, Optional
import kamae
from kamae.tensorflow.typing import Tensor
import tensorflow as tf
from .base import BaseLayer
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringToStringListLayer(BaseL... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class StringToStringListLayer(BaseLayer):
'''
A layer that converts a string to a list of strings by splitting on a
separator. It takes a default value and a list_length parameter to ensure that
the output tensor has the correct shape.
... | 8 | 5 | 24 | 2 | 12 | 10 | 2 | 0.9 | 1 | 4 | 0 | 0 | 4 | 3 | 4 | 41 | 108 | 13 | 50 | 23 | 34 | 45 | 19 | 12 | 14 | 3 | 5 | 0 | 6 |
325,463 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/sub_string_delim_at_index.py | kamae.tensorflow.layers.sub_string_delim_at_index.SubStringDelimAtIndexLayer | import tensorflow as tf
from .base import BaseLayer
from typing import Any, Dict, List, Optional
from kamae.tensorflow.utils import enforce_single_tensor_input
from kamae.tensorflow.typing import Tensor
import kamae
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class SubStringDelimAtIndexLayer(Ba... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class SubStringDelimAtIndexLayer(BaseLayer):
'''
Layer which splits a string tensor by a delimiter and
returns the substring at the specified index. If the delimiter is the empty
string, the string is split into bytes/characters.
If... | 10 | 6 | 29 | 2 | 15 | 12 | 2 | 0.8 | 1 | 5 | 0 | 0 | 4 | 3 | 5 | 42 | 160 | 14 | 81 | 34 | 61 | 65 | 34 | 20 | 28 | 4 | 5 | 2 | 9 |
325,464 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/subtract.py | kamae.tensorflow.layers.subtract.SubtractLayer | from typing import Any, Dict, Iterable, List, Optional, Union
from kamae.tensorflow.typing import Tensor
import tensorflow as tf
from .base import BaseLayer
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
import kamae
from functools import reduce
@tf.keras.utils.register_keras_serializable(pac... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class SubtractLayer(BaseLayer):
def __init__(self, name: Optional[str]=None, input_dtype: Optional[str]=None, output_dtype: Optional[str]=None, subtrahend: Optional[float]=None, **kwargs: Any) -> None:
'''
Initializes the SubtractL... | 8 | 4 | 21 | 2 | 12 | 7 | 2 | 0.55 | 1 | 5 | 0 | 0 | 4 | 1 | 4 | 41 | 88 | 9 | 51 | 17 | 37 | 28 | 19 | 8 | 14 | 4 | 5 | 2 | 7 |
325,465 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/sum.py | kamae.tensorflow.layers.sum.SumLayer | from typing import Any, Dict, Iterable, List, Optional, Union
import tensorflow as tf
import kamae
from kamae.tensorflow.utils import allow_single_or_multiple_tensor_input
from .base import BaseLayer
from kamae.tensorflow.typing import Tensor
from functools import reduce
@tf.keras.utils.register_keras_serializable(pac... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class SumLayer(BaseLayer):
'''
Performs the sum(x, y) operation on a given input tensor.
If added is not set, inputs are assumed to be a list of tensors and summed.
If added is set, inputs must be a tensor.
'''
def __init__(sel... | 8 | 5 | 20 | 2 | 12 | 6 | 2 | 0.59 | 1 | 5 | 0 | 0 | 4 | 1 | 4 | 41 | 91 | 10 | 51 | 17 | 37 | 30 | 19 | 8 | 14 | 4 | 5 | 2 | 7 |
325,466 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/layers/unix_timestamp_to_date_time.py | kamae.tensorflow.layers.unix_timestamp_to_date_time.UnixTimestampToDateTimeLayer | from .base import BaseLayer
from typing import Any, Dict, List, Optional
import tensorflow as tf
import kamae
from kamae.tensorflow.typing import Tensor
from kamae.tensorflow.utils import enforce_single_tensor_input, unix_timestamp_to_datetime
@tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class U... | @tf.keras.utils.register_keras_serializable(package=kamae.__name__)
class UnixTimestampToDateTimeLayer(BaseLayer):
'''
Returns the date in yyyy-MM-dd HH:mm:ss.SSS format from a Unix timestamp.
If `include_time` is set to `False`, the output will be in yyyy-MM-dd format.
'''
def __init__(self, name:... | 8 | 5 | 21 | 2 | 12 | 8 | 2 | 0.71 | 1 | 5 | 0 | 0 | 4 | 2 | 4 | 41 | 94 | 10 | 49 | 20 | 34 | 35 | 21 | 10 | 16 | 4 | 5 | 1 | 8 |
325,467 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/tensorflow/utils/layer_utils.py | kamae.tensorflow.utils.layer_utils.NormalizeLayer | from kamae.tensorflow.utils import listify_tensors
import numpy as np
from typing import Any, Dict, List, Optional, Tuple, Union
import tensorflow as tf
from kamae.tensorflow.layers.base import BaseLayer
class NormalizeLayer(BaseLayer):
"""
Intermediate layer for normalization layers.
Reduces code duplica... |
class NormalizeLayer(BaseLayer):
'''
Intermediate layer for normalization layers.
Reduces code duplication by providing a common interface for normalization layers.
'''
def __init__(self, mean: Union[List[float], np.array], variance: Union[List[float], np.array], name: Optional[str]=None, input_dt... | 8 | 5 | 22 | 2 | 12 | 9 | 3 | 0.77 | 1 | 9 | 0 | 2 | 6 | 7 | 6 | 43 | 142 | 16 | 71 | 31 | 54 | 55 | 42 | 21 | 35 | 7 | 5 | 2 | 16 |
325,468 | ExpediaGroup/kamae | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/ExpediaGroup_kamae/src/kamae/utils/dtype_enum.py | kamae.utils.dtype_enum.DType | from enum import Enum
import tensorflow as tf
from typing import Any, Dict
from pyspark.sql.types import BooleanType, ByteType, DataType, DoubleType, FloatType, IntegerType, LongType, ShortType, StringType
class DType(Enum):
"""
Enum class for supported data types in Kamae.
Contains a string name, the corr... |
class DType(Enum):
'''
Enum class for supported data types in Kamae.
Contains a string name, the corresponding Spark data type, the corresponding
TensorFlow data type, and the number of bytes the data type takes up.
String is a special case, as it can be of any length, so the number of bytes
is... | 3 | 1 | 12 | 0 | 12 | 0 | 1 | 0.2 | 1 | 4 | 0 | 0 | 2 | 6 | 2 | 51 | 50 | 3 | 40 | 25 | 29 | 8 | 18 | 17 | 15 | 1 | 4 | 0 | 2 |
325,469 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/common/deep_next/common/cmd.py | cmd.RunCmdError | class RunCmdError(Exception):
"""Run command error."""
def __init__(self, message, stdout: str='', stderr: str=''):
super().__init__(message)
self.stdout = stdout
self.stderr = stderr | class RunCmdError(Exception):
'''Run command error.'''
def __init__(self, message, stdout: str='', stderr: str=''):
pass | 2 | 1 | 4 | 0 | 4 | 0 | 1 | 0.2 | 1 | 2 | 0 | 0 | 1 | 2 | 1 | 11 | 7 | 1 | 5 | 4 | 3 | 1 | 5 | 4 | 3 | 1 | 3 | 0 | 1 |
325,470 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/apps/app/deep_next/app/config.py | config.Label | from enum import Enum
class Label(Enum):
"""State of the DeepNext process."""
TODO = 'deep_next'
HUMAN_IN_THE_LOOP = 'deep_next_human_in_the_loop'
AUTONOMOUS = 'deep_next_autonomous'
IN_PROGRESS = 'deep_next_in_progress'
AWAITING_RESPONSE = 'deep_next_awaiting_response'
SOLVED = 'deep_next_... |
class Label(Enum):
'''State of the DeepNext process.'''
pass | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0.13 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 49 | 11 | 2 | 8 | 8 | 7 | 1 | 8 | 8 | 7 | 0 | 4 | 0 | 0 |
325,471 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/base_graph.py | core.base_graph.BaseGraph | from typing import Any, Awaitable, Callable, Hashable, Union
from langgraph.graph import StateGraph
from langchain_core.runnables.base import Runnable, RunnableLike
from typing_extensions import Self
from pydantic import BaseModel
from abc import ABC, abstractmethod
from langchain_core.runnables.graph import MermaidDra... |
class BaseGraph(StateGraph, ABC):
def __init__(self, state_cls: type[BaseModel | BaseModel]):
pass
def set_setup_fn(self, setup_fn: Callable[[BaseModel], None]) -> Self:
pass
def set_teardown_fn(self, teardown_fn: Callable[[BaseModel], None]) -> Self:
pass
@abstractmethod
... | 14 | 4 | 9 | 1 | 6 | 2 | 1 | 0.34 | 2 | 7 | 1 | 11 | 10 | 3 | 10 | 30 | 100 | 17 | 62 | 32 | 35 | 21 | 32 | 16 | 21 | 3 | 4 | 1 | 14 |
325,472 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/base_graph.py | core.base_graph._WrappedCompiledStateGraph | from langgraph.graph.state import CompiledStateGraph
from typing import Any, Awaitable, Callable, Hashable, Union
from pydantic import BaseModel
class _WrappedCompiledStateGraph(CompiledStateGraph):
"""Wrapper for CompiledStateGraph to add setup and teardown logic."""
def __init__(self, compiled_graph: Compil... |
class _WrappedCompiledStateGraph(CompiledStateGraph):
'''Wrapper for CompiledStateGraph to add setup and teardown logic.'''
def __init__(self, compiled_graph: CompiledStateGraph, setup_fn: Callable[[BaseModel], None], teardown_fn: Callable[[BaseModel], None]):
pass
def invoke(self, *args: Any, **... | 3 | 2 | 11 | 2 | 9 | 1 | 1 | 0.11 | 1 | 4 | 0 | 0 | 2 | 3 | 2 | 2 | 25 | 5 | 18 | 12 | 10 | 2 | 12 | 7 | 9 | 1 | 1 | 1 | 2 |
325,473 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/common.py | core.common.RemoveThinkingBlocksParser | from langchain_core.output_parsers import BaseOutputParser
import re
class RemoveThinkingBlocksParser(BaseOutputParser):
"""Parser that removes <think>...</think> blocks from LLM output."""
def parse(self, text: str) -> str:
"""Remove <think>...</think> blocks from text.
Args:
tex... |
class RemoveThinkingBlocksParser(BaseOutputParser):
'''Parser that removes <think>...</think> blocks from LLM output.'''
def parse(self, text: str) -> str:
'''Remove <think>...</think> blocks from text.
Args:
text: The input string with potential <think>...</think> blocks
R... | 2 | 2 | 14 | 2 | 4 | 8 | 1 | 1.8 | 1 | 1 | 0 | 0 | 1 | 0 | 1 | 1 | 17 | 3 | 5 | 4 | 3 | 9 | 5 | 4 | 3 | 1 | 1 | 0 | 1 |
325,474 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/config.py | core.config.ImplementationModes | from enum import Enum
class ImplementationModes(str, Enum):
SINGLE_FILE = 'single_file'
ALL_AT_ONCE = 'all_at_once' |
class ImplementationModes(str, Enum):
pass | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 2 | 0 | 0 | 0 | 0 | 0 | 0 | 115 | 3 | 0 | 3 | 3 | 2 | 0 | 3 | 3 | 2 | 0 | 4 | 0 | 0 |
325,475 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/config.py | core.config.SRFConfig | class SRFConfig:
N_CYCLES = 3
CYCLE_ITERATION_LIMIT = 20 | class SRFConfig:
pass | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 3 | 0 | 3 | 3 | 2 | 0 | 3 | 3 | 2 | 0 | 0 | 0 | 0 |
325,476 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/config.py | core.config.SRSConfig | class SRSConfig:
N_CYCLES = 3
CONTEXT_WINDOW = 10 | class SRSConfig:
pass | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 3 | 0 | 3 | 3 | 2 | 0 | 3 | 3 | 2 | 0 | 0 | 0 | 0 |
325,477 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/graph.py | core.graph.DeepNextGraph | from deep_next.core.base_graph import BaseGraph
from langgraph.graph import END, START
from pathlib import Path
class DeepNextGraph(BaseGraph):
"""Main graph for DeepNext."""
def __init__(self):
super().__init__(_State)
def _build(self):
self.add_quick_node(_Node.gather_project_knowledge)... |
class DeepNextGraph(BaseGraph):
'''Main graph for DeepNext.'''
def __init__(self):
pass
def _build(self):
pass
def create_init_state(self, root: Path, issue_title: str, issue_description: str, issue_comments: list[str]=[]) -> _State:
pass
def __call__(self, *_, issue_tit... | 5 | 1 | 17 | 2 | 16 | 1 | 1 | 0.05 | 1 | 8 | 3 | 0 | 4 | 0 | 4 | 34 | 74 | 10 | 63 | 22 | 45 | 3 | 23 | 9 | 18 | 1 | 5 | 0 | 4 |
325,478 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/graph.py | core.graph.DeepNextResult | from pydantic import BaseModel, Field
class DeepNextResult(BaseModel):
"""Response model for DeepNext."""
git_diff: str = Field(description='Final result: git diff of the changes made to the source code.')
reasoning: str = Field(description='Reasoning behind the changes made.')
action_plan: str = Field... |
class DeepNextResult(BaseModel):
'''Response model for DeepNext.'''
pass | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0.17 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 82 | 8 | 1 | 6 | 4 | 5 | 1 | 4 | 4 | 3 | 0 | 5 | 0 | 0 |
325,479 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/graph.py | core.graph._Node | from deep_next.core.steps.action_plan import action_plan_graph
from deep_next.core.steps.implement.graph import implement_graph
from deep_next.core.steps.code_review.graph import code_review_graph
import textwrap
from deep_next.core.steps.gather_project_knowledge.graph import gather_project_knowledge_graph
from loguru ... |
class _Node:
@staticmethod
def gather_project_knowledge(state: _State) -> dict:
pass
@staticmethod
def create_action_plan(state: _State) -> dict:
pass
@staticmethod
def implement(state: _State) -> dict:
pass
@staticmethod
def review_code(state: _State) -> dict:
... | 11 | 0 | 13 | 2 | 11 | 0 | 1 | 0 | 0 | 2 | 1 | 0 | 0 | 0 | 5 | 5 | 74 | 13 | 61 | 22 | 50 | 0 | 24 | 17 | 18 | 1 | 0 | 0 | 5 |
325,480 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/graph.py | core.graph._State | from deep_next.core.steps.action_plan.data_model import ActionPlan
from deep_next.common.common import prepare_issue_statement
from pydantic import BaseModel, Field
from pathlib import Path
class _State(BaseModel):
root_path: Path = Field(description='Path to the root project directory.')
issue_title: str = Fi... |
class _State(BaseModel):
@property
def issue_statement(self) -> str:
pass | 3 | 0 | 6 | 0 | 6 | 0 | 1 | 0 | 1 | 1 | 0 | 0 | 1 | 0 | 1 | 83 | 32 | 5 | 27 | 12 | 24 | 0 | 12 | 11 | 10 | 1 | 5 | 0 | 1 |
325,481 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/graph_hitl.py | core.graph_hitl.DeepNextActionPlanGraph | from deep_next.core.steps.action_plan.data_model import ActionPlan
from deep_next.core.base_graph import BaseGraph
from pathlib import Path
from langgraph.graph import END, START
class DeepNextActionPlanGraph(BaseGraph):
"""
Graph for the first phase of DeepNext.
Gather the project knowledge and creating ... |
class DeepNextActionPlanGraph(BaseGraph):
'''
Graph for the first phase of DeepNext.
Gather the project knowledge and creating an action plan.
'''
def __init__(self):
pass
def _build(self):
pass
def create_init_state(self, root_path: Path, issue_title: str, issue_descript... | 5 | 1 | 10 | 1 | 10 | 0 | 1 | 0.1 | 1 | 8 | 4 | 0 | 4 | 0 | 4 | 34 | 51 | 7 | 40 | 20 | 22 | 4 | 15 | 7 | 10 | 1 | 5 | 0 | 4 |
325,482 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/graph_hitl.py | core.graph_hitl.DeepNextImplementGraph | from deep_next.core.steps.action_plan.data_model import ActionPlan
from langgraph.graph import END, START
from pathlib import Path
from deep_next.core.base_graph import BaseGraph
class DeepNextImplementGraph(BaseGraph):
"""
Graph for the second phase of DeepNext.
Implement the action plan and generate the... |
class DeepNextImplementGraph(BaseGraph):
'''
Graph for the second phase of DeepNext.
Implement the action plan and generate the git diff.
'''
def __init__(self):
pass
def _build(self):
pass
def create_init_state(self, root_path: Path, issue_title: str, issue_description: ... | 5 | 1 | 10 | 1 | 10 | 0 | 1 | 0.1 | 1 | 7 | 3 | 0 | 4 | 0 | 4 | 34 | 51 | 7 | 40 | 22 | 20 | 4 | 13 | 7 | 8 | 1 | 5 | 0 | 4 |
325,483 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/graph_hitl.py | core.graph_hitl._NodeActionPlan | from deep_next.core.steps.gather_project_knowledge.graph import gather_project_knowledge_graph
from deep_next.core.steps.action_plan import action_plan_graph
class _NodeActionPlan:
@staticmethod
def gather_project_knowledge(state: _StateActionPlan) -> dict:
init_state = gather_project_knowledge_graph.... |
class _NodeActionPlan:
@staticmethod
def gather_project_knowledge(state: _StateActionPlan) -> dict:
pass
@staticmethod
def create_action_plan(state: _StateActionPlan) -> dict:
pass | 5 | 0 | 8 | 1 | 7 | 0 | 1 | 0 | 0 | 2 | 1 | 0 | 0 | 0 | 2 | 2 | 19 | 2 | 17 | 9 | 12 | 0 | 9 | 7 | 6 | 1 | 0 | 0 | 2 |
325,484 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/graph_hitl.py | core.graph_hitl._NodeImplement | from deep_next.core.steps.code_review.graph import code_review_graph
from deep_next.core.steps.implement.graph import implement_graph
class _NodeImplement:
@staticmethod
def implement(state: _StateImplement) -> dict:
init_state = implement_graph.create_init_state(root_path=state.root_path, issue_state... |
class _NodeImplement:
@staticmethod
def implement(state: _StateImplement) -> dict:
pass
@staticmethod
def review_code(state: _StateImplement) -> dict:
pass | 5 | 0 | 10 | 1 | 9 | 0 | 1 | 0 | 0 | 2 | 1 | 0 | 0 | 0 | 2 | 2 | 23 | 3 | 20 | 9 | 15 | 0 | 9 | 7 | 6 | 1 | 0 | 0 | 2 |
325,485 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/graph_hitl.py | core.graph_hitl._StateActionPlan | from pathlib import Path
from pydantic import BaseModel, Field
from deep_next.core.steps.action_plan.data_model import ActionPlan
from deep_next.common.common import prepare_issue_statement
class _StateActionPlan(BaseModel):
root_path: Path = Field(description='Path to the root project directory.')
issue_title... |
class _StateActionPlan(BaseModel):
@property
def issue_statement(self) -> str:
pass | 3 | 0 | 6 | 0 | 6 | 0 | 1 | 0 | 1 | 1 | 0 | 0 | 1 | 0 | 1 | 83 | 19 | 3 | 16 | 9 | 13 | 0 | 9 | 8 | 7 | 1 | 5 | 0 | 1 |
325,486 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/graph_hitl.py | core.graph_hitl._StateImplement | from deep_next.common.common import prepare_issue_statement
from pathlib import Path
from deep_next.core.steps.action_plan.data_model import ActionPlan
from pydantic import BaseModel, Field
class _StateImplement(BaseModel):
root_path: Path = Field(description='Path to the root project directory.')
issue_title:... |
class _StateImplement(BaseModel):
@property
def issue_statement(self) -> str:
pass | 3 | 0 | 6 | 0 | 6 | 0 | 1 | 0 | 1 | 1 | 0 | 0 | 1 | 0 | 1 | 83 | 22 | 3 | 19 | 9 | 16 | 0 | 9 | 8 | 7 | 1 | 5 | 0 | 1 |
325,487 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/project_info.py | core.project_info.ProjectInfo | from dataclasses import dataclass
import re
from pathlib import Path
import tomllib
from typing import Any
@dataclass(frozen=True)
class ProjectInfo:
root_dir: Path
pyproject_toml: str = NOT_FOUND
setup_py: str = NOT_FOUND
setup_cfg: str = NOT_FOUND
readme: str = NOT_FOUND
def _get_name_from_p... | @dataclass(frozen=True)
class ProjectInfo:
def _get_name_from_pyproject_toml_tool(self) -> str | None:
pass
def _get_name_from_pyproject_toml_project(self) -> str | None:
pass
@property
@_log_if_different_than_dir
def name(self) -> str:
pass | 7 | 0 | 11 | 1 | 10 | 0 | 4 | 0 | 0 | 5 | 0 | 0 | 3 | 0 | 3 | 3 | 45 | 8 | 37 | 14 | 31 | 0 | 35 | 12 | 31 | 8 | 0 | 2 | 12 |
325,488 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/steps/action_plan/action_plan.py | core.steps.action_plan.action_plan.ActionPlanValidationError | class ActionPlanValidationError(Exception):
"""Raised when action plan is invalid.""" | class ActionPlanValidationError(Exception):
'''Raised when action plan is invalid.'''
pass | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 10 | 2 | 0 | 1 | 1 | 0 | 1 | 1 | 1 | 0 | 0 | 3 | 0 | 0 |
325,489 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/steps/action_plan/action_plan.py | core.steps.action_plan.action_plan._Prompt | import textwrap
class _Prompt:
role = textwrap.dedent('\n You are an expert software engineer tasked with breaking down a software issue into an ordered action plan with explicit dependencies.\n\n The following steps should be an ordered list of high-level, actionable goals for the developer ... |
class _Prompt:
pass | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0.08 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 84 | 11 | 73 | 8 | 72 | 6 | 8 | 8 | 7 | 0 | 0 | 0 | 0 |
325,490 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/steps/action_plan/data_model.py | core.steps.action_plan.data_model.ActionPlan | from pydantic import BaseModel, Field
class ActionPlan(BaseModel):
reasoning: str
ordered_steps: list[Step] |
class ActionPlan(BaseModel):
pass | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 82 | 3 | 0 | 3 | 1 | 2 | 0 | 3 | 1 | 2 | 0 | 5 | 0 | 0 |
325,491 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/steps/action_plan/data_model.py | core.steps.action_plan.data_model.ExistingCodeContext | from pydantic import BaseModel, Field
class ExistingCodeContext(BaseModel):
code_context: list[FileCodeContext] = Field(default_factory=list)
def dump(self) -> str:
return '\n'.join([f'Path: {file_context.path}\nExplanation: {file_context.explanation}\nCode:\n{file_context.code_snippet}\n' for file_co... |
class ExistingCodeContext(BaseModel):
def dump(self) -> str:
pass | 2 | 0 | 9 | 0 | 9 | 0 | 1 | 0 | 1 | 1 | 0 | 0 | 1 | 0 | 1 | 83 | 12 | 1 | 11 | 3 | 9 | 0 | 4 | 3 | 2 | 1 | 5 | 0 | 1 |
325,492 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/steps/action_plan/data_model.py | core.steps.action_plan.data_model.FileCodeContext | from pathlib import Path
from pydantic import BaseModel, Field
class FileCodeContext(BaseModel):
path: Path
code_snippet: str
explanation: str = '' |
class FileCodeContext(BaseModel):
pass | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 82 | 4 | 0 | 4 | 2 | 3 | 0 | 4 | 2 | 3 | 0 | 5 | 0 | 0 |
325,493 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/steps/action_plan/data_model.py | core.steps.action_plan.data_model.Step | from pydantic import BaseModel, Field
from pathlib import Path
class Step(BaseModel):
title: str = Field(description='High level step overview.')
description: str = Field(description='Detailed step description.')
target_file: Path = Field(description='Absolute path to the file to be modified.') |
class Step(BaseModel):
pass | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 82 | 4 | 0 | 4 | 4 | 3 | 0 | 4 | 4 | 3 | 0 | 5 | 0 | 0 |
325,494 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/steps/action_plan/graph.py | core.steps.action_plan.graph.ActionPlanGraph | from deep_next.core.base_graph import BaseGraph
from deep_next.core.steps.action_plan.data_model import ActionPlan, ExistingCodeContext, FileCodeContext
from langgraph.constants import START
from pathlib import Path
from langgraph.graph import END
class ActionPlanGraph(BaseGraph):
def __init__(self):
supe... |
class ActionPlanGraph(BaseGraph):
def __init__(self):
pass
def __call__(self, root_path: Path, issue_statement: str, project_knowledge: str) -> ActionPlan:
pass
def _build(self) -> None:
pass
def create_init_state(self, root_path: Path, issue_statement: str, project_knowledg... | 5 | 0 | 8 | 1 | 7 | 1 | 1 | 0.07 | 1 | 6 | 3 | 0 | 4 | 0 | 4 | 34 | 34 | 5 | 27 | 11 | 18 | 2 | 15 | 7 | 10 | 1 | 5 | 0 | 4 |
325,495 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/steps/action_plan/graph.py | core.steps.action_plan.graph._Node | from deep_next.core.steps.action_plan.srf import srf_graph
from deep_next.core.config import SRFConfig
from langchain_core.runnables import RunnableConfig
from deep_next.core.io import read_txt
from deep_next.core.steps.action_plan.action_plan import create_action_plan
from deep_next.core.steps.action_plan.data_model i... |
class _Node:
@staticmethod
def define_code_context(state: _State) -> dict:
pass
@staticmethod
def create_action_plan(state: _State) -> dict:
pass | 5 | 0 | 15 | 2 | 13 | 0 | 1 | 0 | 0 | 6 | 5 | 0 | 0 | 0 | 2 | 2 | 33 | 4 | 29 | 9 | 24 | 0 | 9 | 7 | 6 | 1 | 0 | 0 | 2 |
325,496 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/steps/action_plan/graph.py | core.steps.action_plan.graph._State | from pathlib import Path
from pydantic import BaseModel, Field
from deep_next.core.steps.action_plan.data_model import ActionPlan, ExistingCodeContext, FileCodeContext
class _State(BaseModel):
root_path: Path = Field(description='Root path for the project.')
issue_statement: str = Field(description='Issue deta... |
class _State(BaseModel):
pass | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0.3 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 82 | 15 | 2 | 10 | 6 | 9 | 3 | 6 | 6 | 5 | 0 | 5 | 0 | 0 |
325,497 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/steps/action_plan/srf/file_selection/analysis_model.py | core.steps.action_plan.srf.file_selection.analysis_model.Analysis | import json
from pydantic import BaseModel, Field
class Analysis(BaseModel):
overview: str = Field(default='', description=overview_desc)
relevant_files_so_far: list[RelevantFile] = Field(default_factory=list, description=relevant_files_so_far_desc)
reasoning: str = Field(default='', description=reasoning_... |
class Analysis(BaseModel):
@property
def json_str(self) -> str:
pass | 3 | 0 | 2 | 0 | 2 | 0 | 1 | 0 | 1 | 1 | 0 | 0 | 1 | 0 | 1 | 83 | 12 | 1 | 11 | 8 | 8 | 0 | 8 | 7 | 6 | 1 | 5 | 0 | 1 |
325,498 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/steps/action_plan/srf/file_selection/analysis_model.py | core.steps.action_plan.srf.file_selection.analysis_model.RelevantFile | from pydantic import BaseModel, Field
class RelevantFile(BaseModel):
path: str
explanation: str
def __hash__(self):
return hash(self.path)
def __eq__(self, other):
if isinstance(other, RelevantFile):
return self.path == other.path
return False |
class RelevantFile(BaseModel):
def __hash__(self):
pass
def __eq__(self, other):
pass | 3 | 0 | 3 | 0 | 3 | 0 | 2 | 0 | 1 | 0 | 0 | 0 | 2 | 0 | 2 | 84 | 11 | 2 | 9 | 3 | 6 | 0 | 9 | 3 | 6 | 2 | 5 | 1 | 3 |
325,499 | stxnext/deep-next | /Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/stxnext_deep-next/libs/core/deep_next/core/steps/action_plan/srf/file_selection/graph.py | core.steps.action_plan.srf.file_selection.graph.AnalyzeKnowledgePrompt | import textwrap
class AnalyzeKnowledgePrompt:
role_description = textwrap.dedent('\n You are an advanced codebase analysis agent designed to assist in identifying files within a software repository that are relevant to solving specific issues. When provided with an issue statement and analys... |
class AnalyzeKnowledgePrompt:
pass | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0.06 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 61 | 11 | 49 | 4 | 48 | 3 | 4 | 4 | 3 | 0 | 0 | 0 | 0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.