Skip to content
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

GCP-Marketplace Python #1057

Merged
merged 7 commits into from
Jun 7, 2023
Merged

GCP-Marketplace Python #1057

merged 7 commits into from
Jun 7, 2023

Conversation

InquestGeronimo
Copy link
Contributor

This PR is meant to compliment the workflow discussed in the blog by offering an additional flow for users to launch a DeepSparse runtime instance via Python SDK.

@InquestGeronimo InquestGeronimo self-assigned this Jun 2, 2023
Copy link
Member

@jeanniefinks jeanniefinks left a comment

Choose a reason for hiding this comment

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

Suggested edits

Comment on lines 307 to 313
project_id = "<project-id>"
zone = "us-central1-c"
instance_name = "deepsparse"
machine_type = "n2d-highcpu-8"
source_image = (
"projects/neuralmagic-public/global/images/deepsparse-cloud-142-ubuntu-2204"
)
Copy link
Member

Choose a reason for hiding this comment

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

@InquestGeronimo if these are all that are needed to be changed to update this script for custom usage, could you put these into click arguments? how do you think about zone and machine type fair to default, with project_id as required?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@mgoin It is possible to add more variables than the ones found here, the rest are in the create_instance function def create_instance( project_id: str, zone: str, instance_name: str, disks: list[compute_v1.AttachedDisk], machine_type: str, network_link: str = "global/networks/default", subnetwork_link: str = None, internal_ip: str = None, external_access: bool = True, external_ipv4: str = None, accelerators: list[compute_v1.AcceleratorConfig] = None, preemptible: bool = False, spot: bool = False, instance_termination_action: str = "STOP", custom_hostname: str = None, delete_protection: bool = False,

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Do you want me to add click args to the 5 variables above and then mention to the users in the README that they can do further customization in the create_function if they prefer?

Copy link
Member

Choose a reason for hiding this comment

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

Okay yes, I think mentioning create_instance to edit and implementing click args for create_from_public_image works well

@mgoin mgoin merged commit 681a30f into main Jun 7, 2023
0 of 7 checks passed
@mgoin mgoin deleted the gcp-marketplace branch June 7, 2023 01:19
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.

None yet

3 participants