code-loader 1.0.75__tar.gz → 1.0.76__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of code-loader might be problematic. Click here for more details.

Files changed (31) hide show
  1. {code_loader-1.0.75 → code_loader-1.0.76}/PKG-INFO +1 -1
  2. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/inner_leap_binder/leapbinder_decorators.py +14 -10
  3. {code_loader-1.0.75 → code_loader-1.0.76}/pyproject.toml +1 -1
  4. {code_loader-1.0.75 → code_loader-1.0.76}/LICENSE +0 -0
  5. {code_loader-1.0.75 → code_loader-1.0.76}/README.md +0 -0
  6. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/__init__.py +0 -0
  7. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/contract/__init__.py +0 -0
  8. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/contract/datasetclasses.py +0 -0
  9. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/contract/enums.py +0 -0
  10. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/contract/exceptions.py +0 -0
  11. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/contract/responsedataclasses.py +0 -0
  12. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/contract/visualizer_classes.py +0 -0
  13. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/default_losses.py +0 -0
  14. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/default_metrics.py +0 -0
  15. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/experiment_api/__init__.py +0 -0
  16. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/experiment_api/api.py +0 -0
  17. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/experiment_api/cli_config_utils.py +0 -0
  18. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/experiment_api/client.py +0 -0
  19. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/experiment_api/epoch.py +0 -0
  20. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/experiment_api/experiment.py +0 -0
  21. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/experiment_api/experiment_context.py +0 -0
  22. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/experiment_api/types.py +0 -0
  23. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/experiment_api/utils.py +0 -0
  24. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/experiment_api/workingspace_config_utils.py +0 -0
  25. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/inner_leap_binder/__init__.py +0 -0
  26. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/inner_leap_binder/leapbinder.py +0 -0
  27. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/leaploader.py +0 -0
  28. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/leaploaderbase.py +0 -0
  29. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/utils.py +0 -0
  30. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/visualizers/__init__.py +0 -0
  31. {code_loader-1.0.75 → code_loader-1.0.76}/code_loader/visualizers/default_visualizers.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: code-loader
3
- Version: 1.0.75
3
+ Version: 1.0.76
4
4
  Summary:
5
5
  Home-page: https://github.com/tensorleap/code-loader
6
6
  License: MIT
@@ -30,8 +30,9 @@ def tensorleap_custom_metric(name: str,
30
30
 
31
31
  def _validate_input_args(*args, **kwargs) -> None:
32
32
  for i, arg in enumerate(args):
33
- assert isinstance(arg, (np.ndarray, SamplePreprocessResponse)), (f'tensorleap_custom_metric validation failed: '
34
- f'Argument #{i} should be a numpy array. Got {type(arg)}.')
33
+ assert isinstance(arg, (np.ndarray, SamplePreprocessResponse)), (
34
+ f'tensorleap_custom_metric validation failed: '
35
+ f'Argument #{i} should be a numpy array. Got {type(arg)}.')
35
36
  if leap_binder.batch_size_to_validate and isinstance(arg, np.ndarray):
36
37
  assert arg.shape[0] == leap_binder.batch_size_to_validate, \
37
38
  (f'tensorleap_custom_metric validation failed: Argument #{i} '
@@ -39,8 +40,9 @@ def tensorleap_custom_metric(name: str,
39
40
  f'instead of {leap_binder.batch_size_to_validate}')
40
41
 
41
42
  for _arg_name, arg in kwargs.items():
42
- assert isinstance(arg, (np.ndarray, SamplePreprocessResponse)), (f'tensorleap_custom_metric validation failed: '
43
- f'Argument {_arg_name} should be a numpy array. Got {type(arg)}.')
43
+ assert isinstance(arg, (np.ndarray, SamplePreprocessResponse)), (
44
+ f'tensorleap_custom_metric validation failed: '
45
+ f'Argument {_arg_name} should be a numpy array. Got {type(arg)}.')
44
46
  if leap_binder.batch_size_to_validate and isinstance(arg, np.ndarray):
45
47
  assert arg.shape[0] == leap_binder.batch_size_to_validate, \
46
48
  (f'tensorleap_custom_metric validation failed: Argument {_arg_name} '
@@ -58,8 +60,8 @@ def tensorleap_custom_metric(name: str,
58
60
  assert isinstance(single_metric_result[0][0], ConfusionMatrixElement), \
59
61
  f'{supported_types_message}Got List[List[{type(single_metric_result[0][0])}]].'
60
62
  else:
61
- assert isinstance(single_metric_result[0],
62
- float), f'{supported_types_message}Got List[{type(single_metric_result[0])}].'
63
+ assert isinstance(single_metric_result[0], (
64
+ float, int, type(None))), f'{supported_types_message}Got List[{type(single_metric_result[0])}].'
63
65
  else:
64
66
  assert isinstance(single_metric_result,
65
67
  np.ndarray), f'{supported_types_message}Got {type(single_metric_result)}.'
@@ -115,16 +117,18 @@ def tensorleap_custom_visualizer(name: str, visualizer_type: LeapDataType,
115
117
 
116
118
  def _validate_input_args(*args, **kwargs):
117
119
  for i, arg in enumerate(args):
118
- assert isinstance(arg, (np.ndarray, SamplePreprocessResponse)), (f'tensorleap_custom_visualizer validation failed: '
119
- f'Argument #{i} should be a numpy array. Got {type(arg)}.')
120
+ assert isinstance(arg, (np.ndarray, SamplePreprocessResponse)), (
121
+ f'tensorleap_custom_visualizer validation failed: '
122
+ f'Argument #{i} should be a numpy array. Got {type(arg)}.')
120
123
  if leap_binder.batch_size_to_validate and isinstance(arg, np.ndarray):
121
124
  assert arg.shape[0] != leap_binder.batch_size_to_validate, \
122
125
  (f'tensorleap_custom_visualizer validation failed: '
123
126
  f'Argument #{i} should be without batch dimension. ')
124
127
 
125
128
  for _arg_name, arg in kwargs.items():
126
- assert isinstance(arg, (np.ndarray, SamplePreprocessResponse)), (f'tensorleap_custom_visualizer validation failed: '
127
- f'Argument {_arg_name} should be a numpy array. Got {type(arg)}.')
129
+ assert isinstance(arg, (np.ndarray, SamplePreprocessResponse)), (
130
+ f'tensorleap_custom_visualizer validation failed: '
131
+ f'Argument {_arg_name} should be a numpy array. Got {type(arg)}.')
128
132
  if leap_binder.batch_size_to_validate and isinstance(arg, np.ndarray):
129
133
  assert arg.shape[0] != leap_binder.batch_size_to_validate, \
130
134
  (f'tensorleap_custom_visualizer validation failed: Argument {_arg_name} '
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "code-loader"
3
- version = "1.0.75"
3
+ version = "1.0.76"
4
4
  description = ""
5
5
  authors = ["dorhar <doron.harnoy@tensorleap.ai>"]
6
6
  license = "MIT"
File without changes
File without changes