unitlab 2.1.5__tar.gz → 2.1.6__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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: unitlab
3
- Version: 2.1.5
3
+ Version: 2.1.6
4
4
  Home-page: https://github.com/teamunitlab/unitlab-sdk
5
5
  Author: Unitlab Inc.
6
6
  Author-email: team@unitlab.ai
@@ -2,7 +2,7 @@ from setuptools import find_packages, setup
2
2
 
3
3
  setup(
4
4
  name="unitlab",
5
- version="2.1.5",
5
+ version="2.1.6",
6
6
  license="MIT",
7
7
  author="Unitlab Inc.",
8
8
  author_email="team@unitlab.ai",
@@ -118,7 +118,7 @@ class UnitlabClient:
118
118
  def project_members(self, project_id, pretty=0):
119
119
  return self._get(f"/api/sdk/projects/{project_id}/members/?pretty={pretty}")
120
120
 
121
- def upload_data(self, project_id, directory, batch_size=100):
121
+ def project_upload_data(self, project_id, directory, batch_size=100):
122
122
  if not os.path.isdir(directory):
123
123
  raise ValueError(f"Directory {directory} does not exist")
124
124
 
@@ -204,7 +204,7 @@ class UnitlabClient:
204
204
  logger.info(f"File: {os.path.abspath(filename)}")
205
205
  return os.path.abspath(filename)
206
206
 
207
- def download_dataset_files(self, dataset_id):
207
+ def dataset_download_files(self, dataset_id):
208
208
  response = self._post(
209
209
  f"/api/sdk/datasets/{dataset_id}/", data={"download_type": "files"}
210
210
  )
@@ -39,7 +39,7 @@ class AnnotationType(str, Enum):
39
39
  IMG_POINT = "img_point"
40
40
 
41
41
 
42
- @app.command()
42
+ @app.command(help="Configure the credentials")
43
43
  def configure(
44
44
  api_key: Annotated[str, typer.Option(help="The api-key obtained from unitlab.ai")],
45
45
  api_url: Annotated[str, typer.Option()] = "https://api.unitlab.ai",
@@ -76,7 +76,7 @@ def upload(
76
76
  Path, typer.Option(help="Directory containing the data to be uploaded")
77
77
  ],
78
78
  ):
79
- get_client(api_key).upload_data(str(pk), directory=directory)
79
+ get_client(api_key).project_upload_data(str(pk), directory=directory)
80
80
 
81
81
 
82
82
  @dataset_app.command(name="list", help="List datasets")
@@ -145,7 +145,7 @@ def dataset_download(
145
145
  "Export type is required when download type is annotation"
146
146
  )
147
147
  get_client(api_key).dataset_download(pk, export_type)
148
- get_client(api_key).download_dataset_files(pk)
148
+ get_client(api_key).dataset_download_files(pk)
149
149
 
150
150
 
151
151
  if __name__ == "__main__":
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: unitlab
3
- Version: 2.1.5
3
+ Version: 2.1.6
4
4
  Home-page: https://github.com/teamunitlab/unitlab-sdk
5
5
  Author: Unitlab Inc.
6
6
  Author-email: team@unitlab.ai
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes