-
Notifications
You must be signed in to change notification settings - Fork 123
Upload image to dataset poc #5089
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
a24377f
3fc61c3
40437db
be14da4
53de7fb
ba15805
b3cdc0b
2a54edf
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -50,6 +50,8 @@ type Service interface { | |
resource.Resource | ||
// Sync will sync data stored on the machine to the cloud. | ||
Sync(ctx context.Context, extra map[string]interface{}) error | ||
UploadImageToDataset(ctx context.Context, image []byte, datasetIDs, tags []string, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. don't we need the mime type? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. yes! we definitely should have the MIME type. Lemme add that. Do you want the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, I'd like both. |
||
extra map[string]interface{}) error | ||
} | ||
|
||
// SubtypeName is the name of the type of service. | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this sync or async?
if we're writing to disk anyway, we can make async.
otherwise, let's not write to disk
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It should be async. The reason to write to disk is because all of our functionality is written to take in a
os.File
and in the name of not rewriting everything just to account for this, thought it would be easier just to write to disk and delete it afterwards.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, just mark it as TODO please.