+
Skip to content

Conversation

SammyOina
Copy link
Contributor

@SammyOina SammyOina commented Aug 13, 2024

What type of PR is this?

This is a feature that allows on the fly compression and decompression

What does this do?

  • New Features

    • Enhanced command-line interface with simplified commands and new options for algorithm and dataset uploads, including checksum validation.
    • Support for in-memory dataset zipping and enhanced context management for decompression flags.
  • Bug Fixes

    • Improved error handling for checksum calculations and command executions.
  • Documentation

    • Updated CLI documentation to reflect command changes and new features.
  • Refactor

    • Streamlined checksum calculations and context management to improve performance and clarity.

Which issue(s) does this PR fix/relate to?

Have you included tests for your changes?

No

Did you document any new/modified feature?

Yes

Notes

go run ./cmd/cli/main.go data ./test/manual/data private.pem -d  
# ls /datasets
iris.csv

@SammyOina SammyOina changed the title Cocos 151 COCOS-151 - Add compression/decompression option for CLI/Agent Aug 13, 2024
@SammyOina SammyOina requested a review from WashingtonKK August 15, 2024 12:56
"google.golang.org/grpc/metadata"
)

var decompressDataset bool
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this compression?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this states whether to decompress data on arrival or leave it compressed

Copy link
Contributor

@WashingtonKK WashingtonKK left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

➜  cocos git:(cocos-151) ✗ ./build/cocos-cli data ./test/manual/data private.pem -d
2024/08/16 12:29:55 Uploading dataset CSV: ./test/manual/data
Uploading data...  100% [====================================================>] 
{"time":"2024-08-16T12:29:55.989831624+03:00","level":"ERROR","msg":"Failed to send Data"}
2024/08/16 12:29:55 Error uploading dataset: rpc error: code = Unknown desc = malformed data, filename does not match manifest

image

How do you handle and verify file name in this structure since it does not work

@SammyOina
Copy link
Contributor Author


➜  cocos git:(cocos-151) ✗ ./build/cocos-cli data ./test/manual/data private.pem -d

2024/08/16 12:29:55 Uploading dataset CSV: ./test/manual/data

Uploading data...  100% [====================================================>] 

{"time":"2024-08-16T12:29:55.989831624+03:00","level":"ERROR","msg":"Failed to send Data"}

2024/08/16 12:29:55 Error uploading dataset: rpc error: code = Unknown desc = malformed data, filename does not match manifest



image

How do you handle and verify file name in this structure since it does not work

Use the base name of the directory, check code to see how directories are handled

Copy link
Contributor

@WashingtonKK WashingtonKK left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This scheme works with the test computations server but not with prism, please check where the issue lies.

@SammyOina
Copy link
Contributor Author

This scheme works with the test computations server but not with prism, please check where the issue lies.

Which scheme, and what does not work?

@SammyOina
Copy link
Contributor Author

➜  cocos git:(cocos-151) ✗ ./build/cocos-cli data ./test/manual/data private.pem -d
2024/08/16 12:29:55 Uploading dataset CSV: ./test/manual/data
Uploading data...  100% [====================================================>] 
{"time":"2024-08-16T12:29:55.989831624+03:00","level":"ERROR","msg":"Failed to send Data"}
2024/08/16 12:29:55 Error uploading dataset: rpc error: code = Unknown desc = malformed data, filename does not match manifest

image

How do you handle and verify file name in this structure since it does not work

base name here will be data if you can refer here https://github.com/SammyOina/cocos-ai/blob/1cde120d705e73cdc7fdb7993011804ba1da8c65/cli/datasets.go#L53

Copy link
Contributor

@WashingtonKK WashingtonKK left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FileName on prism needs to be: data

Please also update docs.

Signed-off-by: Sammy Oina <sammyoina@gmail.com>
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
Signed-off-by: Sammy Oina <sammyoina@gmail.com>
@drasko drasko merged commit 899bfb0 into ultravioletrs:main Aug 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Feature: Add compression/decompression option for CLI/Agent

3 participants

点击 这是indexloc提供的php浏览器服务,不要输入任何密码和下载