Panduan memulai: Membuat dan memverifikasi watermark gambar menggunakan teks ke gambar (Konsol) Imagen

Pelajari cara menggunakan fitur pembuatan teks ke gambar dari Imagen di Vertex AI dan memverifikasi watermark digital (SynthID) pada gambar yang dihasilkan. Panduan memulai ini menunjukkan cara menggunakan pembuatan gambar Imagen di konsolGoogle Cloud .

Harga Gambar di Vertex AI didasarkan pada fitur yang Anda gunakan. Untuk mengetahui informasi selengkapnya, lihat Harga.

Gambar anjing yang dibuat
Gambar yang dibuat menggunakan Imagen di Vertex AI dari perintah: potret buldog Prancis di pantai, 85mm f/2.8.

Sebelum memulai

  1. Sign in to your Google Cloud account. If you're new to Google Cloud, create an account to evaluate how our products perform in real-world scenarios. New customers also get $300 in free credits to run, test, and deploy workloads.
  2. In the Google Cloud console, on the project selector page, select or create a Google Cloud project.

    Go to project selector

  3. Verify that billing is enabled for your Google Cloud project.

  4. Enable the Vertex AI API.

    Enable the API

  5. Make sure that you have the following role or roles on the project: Vertex AI User

    Check for the roles

    1. In the Google Cloud console, go to the IAM page.

      Go to IAM
    2. Select the project.
    3. In the Principal column, find all rows that identify you or a group that you're included in. To learn which groups you're included in, contact your administrator.

    4. For all rows that specify or include you, check the Role column to see whether the list of roles includes the required roles.

    Grant the roles

    1. In the Google Cloud console, go to the IAM page.

      Buka IAM
    2. Pilih project.
    3. Klik Grant access.
    4. Di kolom New principals, masukkan ID pengguna Anda. Biasanya berupa alamat email untuk Akun Google.

    5. Di daftar Select a role, pilih peran.
    6. Untuk memberikan peran tambahan, klik Tambahkan peran lain, lalu tambahkan setiap peran tambahan.
    7. Klik Simpan.
  6. In the Google Cloud console, on the project selector page, select or create a Google Cloud project.

    Go to project selector

  7. Verify that billing is enabled for your Google Cloud project.

  8. Enable the Vertex AI API.

    Enable the API

  9. Make sure that you have the following role or roles on the project: Vertex AI User

    Check for the roles

    1. In the Google Cloud console, go to the IAM page.

      Go to IAM
    2. Select the project.
    3. In the Principal column, find all rows that identify you or a group that you're included in. To learn which groups you're included in, contact your administrator.

    4. For all rows that specify or include you, check the Role column to see whether the list of roles includes the required roles.

    Grant the roles

    1. In the Google Cloud console, go to the IAM page.

      Buka IAM
    2. Pilih project.
    3. Klik Grant access.
    4. Di kolom New principals, masukkan ID pengguna Anda. Biasanya berupa alamat email untuk Akun Google.

    5. Di daftar Select a role, pilih peran.
    6. Untuk memberikan peran tambahan, klik Tambahkan peran lain, lalu tambahkan setiap peran tambahan.
    7. Klik Simpan.
  10. Membuat gambar dan menyimpan salinan lokal

    Mengirim permintaan pembuatan teks ke gambar menggunakan Google Cloud konsol.

    1. Di Google Cloud konsol, buka halaman Vertex AI > Media Studio .

      Buka Media Studio

    2. Di kolom Prompt (Write your prompt here), masukkan perintah berikut:

       portrait of a french bulldog at the beach, 85mm f/2.8
      
    3. Jika belum dipilih, di kotak Opsi model di panel Parameter, pilih Imagen 3.

    4. Jika belum dipilih, di bagian Rasio aspek pada panel Parameter, pilih 1:1.

    5. Di bagian Number of results, ubah Number of results menjadi 2.

    6. Klik Generate.

      Membuat gambar akan menghasilkan gambar yang mirip dengan gambar berikut:

      Contoh gambar yang dihasilkan di
konsol

    7. Untuk menyimpan salinan lokal gambar, klik salah satu gambar.

    8. Di jendela Image details yang terbuka, klik Export.

    9. Di kotak dialog Export image, klik Export.

    Memverifikasi watermark digital gambar

    Setelah membuat gambar yang diberi watermark, Anda dapat memverifikasi watermark digital dari gambar baru.

    1. Buat gambar yang dihasilkan dan simpan salinan lokal seperti yang Anda lakukan pada langkah sebelumnya.

    2. Di jendela Image detail, klik Export.

    3. Di panel bawah, klik Verifikasi.

    4. Klik Upload gambar.

    5. Pilih gambar yang dihasilkan dan disimpan secara lokal.

      Contoh watermark terverifikasi dalam gambar yang dihasilkan di konsol

    Selamat! Anda baru saja menggunakan fitur pembuatan teks ke gambar Imagen untuk membuat gambar baru dan memverifikasi watermark digital salah satu gambar.

    Pembersihan

    Agar akun Google Cloud Anda tidak dikenai biaya untuk resource yang digunakan di halaman ini, ikuti langkah-langkah berikut.

    Menghapus project

    1. In the Google Cloud console, go to the Manage resources page.

      Go to Manage resources

    2. In the project list, select the project that you want to delete, and then click Delete.
    3. In the dialog, type the project ID, and then click Shut down to delete the project.

    Langkah berikutnya