gganimate在Windows 10中渲染像素化

时间:2018-10-22 11:22:40

标签: r animation ggplot2 gganimate

我必须使用gganimate渲染某些动画,但是图像效果不好。它们缺乏清晰度,并且边框被像素化。有什么办法可以在Windows 10中获得更好的结果?

我的代码是:

.container {
  display: flex;
  flex-wrap: wrap;
}

.item {
  width: 80px;
  height: 80px;
  border: 1px solid #eee;
}

我得到的是:

enter image description here

1 个答案:

答案 0 :(得分:1)

您可以使用options()修改默认分辨率

DEBUG: No bucket specified, retrieving default bucket.
DEBUG: Using bucket [gs://staging.ibizi-dev.appspot.com].
DEBUG: Service [appengineflex.googleapis.com] is already enabled for project [ibizi-dev]
Beginning deployment of service [default]...
INFO: Need Dockerfile to be generated for runtime php
Building and pushing image for service [default]
INFO: Uploading [/var/folders/yh/t3v72_f96_9gshbgykw2yp6w0000gn/T/tmpk_BvPn/src.tgz] to [staging.ibizi-dev.appspot.com/eu.gcr.io/ibizi-dev/appengine/default.20181022t152439:latest]
DEBUG: Using runtime builder root [gs://runtime-builders/]
DEBUG: Loading runtimes manifest from [gs://runtime-builders/runtimes.yaml]
INFO: Reading [<googlecloudsdk.api_lib.storage.storage_util.ObjectReference object at 0x110774650>]
DEBUG: Resolved runtime [php] as build configuration [gs://runtime-builders/php-default-builder-20180926113101.yaml]
INFO: Using runtime builder [gs://runtime-builders/php-default-builder-20180926113101.yaml]
INFO: Reading [<googlecloudsdk.api_lib.storage.storage_util.ObjectReference object at 0x11078d150>]
Started cloud build [c874e7e6-d67b-443b-9cc0-169aa6f4dd58].
DEBUG: GCS logfile url is https://www.googleapis.com/storage/v1/b/staging.ibizi-dev.appspot.com/o/log-c874e7e6-d67b-443b-9cc0-169aa6f4dd58.txt?alt=media
To see logs in the Cloud Console: https://console.cloud.google.com/gcr/builds/c874e7e6-d67b-443b-9cc0-169aa6f4dd58?project=702099999392
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 404 (no log yet; keep polling)
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 206 (read 205 bytes)
---------------------------------------------------------------------------------------------------------------------------------- REMOTE BUILD OUTPUT -----------------------------------------------------------------------------------------------------------------------------------
starting build "c874e7e6-d67b-443b-9cc0-169aa6f4dd58"

FETCHSOURCE
Fetching storage object: gs://staging.ibizi-dev.appspot.com/eu.gcr.io/ibizi-dev/appengine/default.20181022t152439:latest#1540214682717948
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 416 (no new content; keep polling)
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 206 (read 529 bytes)
Copying gs://staging.ibizi-dev.appspot.com/eu.gcr.io/ibizi-dev/appengine/default.20181022t152439:latest#1540214682717948...
- [1 files][  798.0 B/  798.0 B]                                                
Operation completed over 1 objects/798.0 B.                                      
BUILD
Starting Step #0
Step #0: Pulling image: gcr.io/gcp-runtimes/php/gen-dockerfile@sha256:2528f753fe7726eb4068d7020d11ecc97216b3ab9e4cb7728edda98cd61b410c
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 206 (read 1446 bytes)
Step #0: sha256:2528f753fe7726eb4068d7020d11ecc97216b3ab9e4cb7728edda98cd61b410c: Pulling from gcp-runtimes/php/gen-dockerfile
Step #0: Digest: sha256:2528f753fe7726eb4068d7020d11ecc97216b3ab9e4cb7728edda98cd61b410c
Step #0: Status: Downloaded newer image for gcr.io/gcp-runtimes/php/gen-dockerfile@sha256:2528f753fe7726eb4068d7020d11ecc97216b3ab9e4cb7728edda98cd61b410c
Step #0: + php /builder/create_dockerfile.php create --php72-image gcr.io/google-appengine/php72@sha256:ab499cb6f2419351ee7db259ae88721f9861935659b42007727395b80226a809 --php71-image gcr.io/google-appengine/php71@sha256:d5dbccb1e6dcc6d26c2df23c464f191ea10ef2bf8e9e18e6d13df3c6770b92a1 --php70-image gcr.io/google-appengine/php70@sha256:cf215595a9d4540762724721ab19837abb9af43645963fa0bd29cc31a2960529 --php56-image gcr.io/google-appengine/php56@sha256:0e57acbab18ce2dba8142dff708157ffdacdefbbdfa480d9068382431fd60fb5
Step #0: 
Step #0: There is no PHP runtime version specified in composer.json, or
Step #0: we don't support the version you specified. Google App Engine
Step #0: uses the latest 7.2.x version.
Step #0: We recommend pinning your PHP version by running:
Step #0: 
Step #0: composer require php 7.2.* (replace it with your desired minor version)
Step #0: 
Step #0: Using PHP version 7.2.x...
Step #0: 
Finished Step #0
Starting Step #1
Step #1: Pulling image: gcr.io/cloud-builders/docker@sha256:ae2ac38e0aba542add006c47eb4a5820b819f9fa74ada0673d2910387e0f1c0e
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 206 (read 354 bytes)
Step #1: sha256:ae2ac38e0aba542add006c47eb4a5820b819f9fa74ada0673d2910387e0f1c0e: Pulling from cloud-builders/docker
Step #1: e5c573070776: Already exists
Step #1: a7e8e7eaedca: Already exists
Step #1: 3c2cba919283: Already exists
Step #1: 2e2f0b8e1d16: Pulling fs layer
Step #1: 2e2f0b8e1d16: Verifying Checksum
Step #1: 2e2f0b8e1d16: Download complete
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 416 (no new content; keep polling)
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 416 (no new content; keep polling)
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 416 (no new content; keep polling)
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 416 (no new content; keep polling)
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 416 (no new content; keep polling)
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 416 (no new content; keep polling)
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 416 (no new content; keep polling)
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 206 (read 1636 bytes)
Step #1: 2e2f0b8e1d16: Pull complete
Step #1: Digest: sha256:ae2ac38e0aba542add006c47eb4a5820b819f9fa74ada0673d2910387e0f1c0e
Step #1: Status: Downloaded newer image for gcr.io/cloud-builders/docker@sha256:ae2ac38e0aba542add006c47eb4a5820b819f9fa74ada0673d2910387e0f1c0e
Step #1: Sending build context to Docker daemon  5.632kB
Step #1: Step 1/9 : FROM gcr.io/google-appengine/php72@sha256:ab499cb6f2419351ee7db259ae88721f9861935659b42007727395b80226a809
Step #1: sha256:ab499cb6f2419351ee7db259ae88721f9861935659b42007727395b80226a809: Pulling from google-appengine/php72
Step #1: Digest: sha256:ab499cb6f2419351ee7db259ae88721f9861935659b42007727395b80226a809
Step #1: Status: Downloaded newer image for gcr.io/google-appengine/php72@sha256:ab499cb6f2419351ee7db259ae88721f9861935659b42007727395b80226a809
Step #1:  ---> 66030c9a7cc4
Step #1: Step 2/9 : ENV DOCUMENT_ROOT='/app/public' ENABLE_STACKDRIVER_INTEGRATION='1' LOG_CHANNEL='stackdriver' APP_LOG='errorlog' APP_ENV='demo' APP_DEBUG='' APP_KEY='base64:+9Lz6fgTo+I5NtJgwNctYuFaaDBNdiL1OpNlhzdPiXs=' STORAGE_DIR='/tmp' DB_HOST='localhost' DB_DATABASE='pms_dev' DB_USERNAME='root' DB_PASSWORD='TMvsds666' DB_SOCKET='/cloudsql/ibizi-dev:europe-west1:pmsapi-dev' FRONT_CONTROLLER_FILE='index.php' COMPOSER_FLAGS='--no-dev --prefer-dist' DETECTED_PHP_VERSION='7.2' IS_BATCH_DAEMON_RUNNING='true'
Step #1:  ---> Running in 7594ef12b822
Step #1: Removing intermediate container 7594ef12b822
Step #1:  ---> 142b1c897658
Step #1: Step 3/9 : COPY . $APP_DIR
Step #1:  ---> f981d2d61e5d
Step #1: Step 4/9 : RUN chown -R www-data.www-data $APP_DIR
Step #1:  ---> Running in 2acb68030e93
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 206 (read 363 bytes)
Step #1: Removing intermediate container 2acb68030e93
Step #1:  ---> 4725933d3fe3
Step #1: Step 5/9 : RUN /build-scripts/composer.sh
Step #1:  ---> Running in d754ce7f2927
Step #1: Removing intermediate container d754ce7f2927
Step #1:  ---> 3f19b1e63bed
Step #1: Step 6/9 : RUN /bin/bash /build-scripts/move-config-files.sh
Step #1:  ---> Running in 10b9531680b7
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] not complete. Waiting 1s.
DEBUG: Reading GCS logfile: 206 (read 975 bytes)
Step #1: Moving user supplied config files...
Step #1: Removing intermediate container 10b9531680b7
Step #1:  ---> 45771fd2253a
Step #1: Step 7/9 : RUN /usr/sbin/nginx -t -c /etc/nginx/nginx.conf
Step #1:  ---> Running in 67614392383d
Step #1: nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
Step #1: nginx: configuration file /etc/nginx/nginx.conf test is successful
Step #1: Removing intermediate container 67614392383d
Step #1:  ---> 6d3a14951445
Step #1: Step 8/9 : RUN /bin/bash /build-scripts/lockdown.sh
Step #1:  ---> Running in 706cf97d0d6d
Step #1: chown: cannot access '/app/public': No such file or directory
Step #1: Locking down the document root...
Step #1: The command '/bin/sh -c /bin/bash /build-scripts/lockdown.sh' returned a non-zero code: 1
Finished Step #1
ERROR
ERROR: build step 1 "gcr.io/cloud-builders/docker@sha256:ae2ac38e0aba542add006c47eb4a5820b819f9fa74ada0673d2910387e0f1c0e" failed: exit status 1
DEBUG: Operation [operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4] complete. Result: {
    "metadata": {
        "@type": "type.googleapis.com/google.devtools.cloudbuild.v1.BuildOperationMetadata", 
        "build": {
            "finishTime": "2018-10-22T13:25:11.466503939Z", 
            "status": "FAILURE", 
            "timeout": "600s", 
            "startTime": "2018-10-22T13:24:45.495313971Z", 
            "artifacts": {
                "images": [
                    "eu.gcr.io/ibizi-dev/appengine/default.20181022t152439:latest"
                ]
            }, 
            "logsBucket": "staging.ibizi-dev.appspot.com", 
            "results": {
                "buildStepImages": [
                    "", 
                    ""
                ]
            }, 
            "id": "c874e7e6-d67b-443b-9cc0-169aa6f4dd58", 
            "timing": {
                "FETCHSOURCE": {
                    "endTime": "2018-10-22T13:24:51.044559960Z", 
                    "startTime": "2018-10-22T13:24:47.603211198Z"
                }, 
                "BUILD": {
                    "endTime": "2018-10-22T13:25:10.480688954Z", 
                    "startTime": "2018-10-22T13:24:51.120689972Z"
                }
            }, 
            "source": {
                "storageSource": {
                    "object": "eu.gcr.io/ibizi-dev/appengine/default.20181022t152439:latest", 
                    "bucket": "staging.ibizi-dev.appspot.com"
                }
            }, 
            "options": {
                "substitutionOption": "ALLOW_LOOSE", 
                "logging": "LEGACY"
            }, 
            "steps": [
                {
                    "status": "SUCCESS", 
                    "name": "gcr.io/gcp-runtimes/php/gen-dockerfile@sha256:2528f753fe7726eb4068d7020d11ecc97216b3ab9e4cb7728edda98cd61b410c", 
                    "args": [
                        "--php72-image", 
                        "gcr.io/google-appengine/php72@sha256:ab499cb6f2419351ee7db259ae88721f9861935659b42007727395b80226a809", 
                        "--php71-image", 
                        "gcr.io/google-appengine/php71@sha256:d5dbccb1e6dcc6d26c2df23c464f191ea10ef2bf8e9e18e6d13df3c6770b92a1", 
                        "--php70-image", 
                        "gcr.io/google-appengine/php70@sha256:cf215595a9d4540762724721ab19837abb9af43645963fa0bd29cc31a2960529", 
                        "--php56-image", 
                        "gcr.io/google-appengine/php56@sha256:0e57acbab18ce2dba8142dff708157ffdacdefbbdfa480d9068382431fd60fb5"
                    ], 
                    "env": [
                        "GAE_APPLICATION_YAML_PATH=dev.yaml"
                    ], 
                    "timing": {
                        "endTime": "2018-10-22T13:24:53.076290422Z", 
                        "startTime": "2018-10-22T13:24:51.120719923Z"
                    }, 
                    "pullTiming": {
                        "endTime": "2018-10-22T13:24:51.939222557Z", 
                        "startTime": "2018-10-22T13:24:51.120719923Z"
                    }
                }, 
                {
                    "status": "FAILURE", 
                    "name": "gcr.io/cloud-builders/docker@sha256:ae2ac38e0aba542add006c47eb4a5820b819f9fa74ada0673d2910387e0f1c0e", 
                    "args": [
                        "build", 
                        "-t", 
                        "eu.gcr.io/ibizi-dev/appengine/default.20181022t152439:latest", 
                        "--network=cloudbuild", 
                        "."
                    ], 
                    "env": [
                        "GAE_APPLICATION_YAML_PATH=dev.yaml"
                    ], 
                    "timing": {
                        "endTime": "2018-10-22T13:25:10.374276995Z", 
                        "startTime": "2018-10-22T13:24:53.076303098Z"
                    }, 
                    "pullTiming": {
                        "endTime": "2018-10-22T13:25:06.452731685Z", 
                        "startTime": "2018-10-22T13:24:53.076303098Z"
                    }
                }
            ], 
            "sourceProvenance": {
                "resolvedStorageSource": {
                    "generation": "1540214682717948", 
                    "object": "eu.gcr.io/ibizi-dev/appengine/default.20181022t152439:latest", 
                    "bucket": "staging.ibizi-dev.appspot.com"
                }, 
                "fileHashes": {
                    "gs://staging.ibizi-dev.appspot.com/eu.gcr.io/ibizi-dev/appengine/default.20181022t152439:latest#1540214682717948": {}
                }
            }, 
            "projectId": "ibizi-dev", 
            "images": [
                "eu.gcr.io/ibizi-dev/appengine/default.20181022t152439:latest"
            ], 
            "substitutions": {
                "_GAE_APPLICATION_YAML_PATH": "dev.yaml", 
                "_OUTPUT_IMAGE": "eu.gcr.io/ibizi-dev/appengine/default.20181022t152439:latest"
            }, 
            "createTime": "2018-10-22T13:24:44.661298334Z", 
            "logUrl": "https://console.cloud.google.com/gcr/builds/c874e7e6-d67b-443b-9cc0-169aa6f4dd58?project=702099999392"
        }
    }, 
    "done": true, 
    "name": "operations/build/ibizi-dev/Yzg3NGU3ZTYtZDY3Yi00NDNiLTljYzAtMTY5YWE2ZjRkZDU4", 
    "error": {
        "message": "Build failed; check build logs for details", 
        "code": 2
    }
}
DEBUG: Reading GCS logfile: 416 (no new content; keep polling)
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

DEBUG: (gcloud.app.deploy) Cloud build failed. Check logs at https://console.cloud.google.com/gcr/builds/c874e7e6-d67b-443b-9cc0-169aa6f4dd58?project=702099999392 Failure status: UNKNOWN: Error Response: [2] Build failed; check build logs for details
Traceback (most recent call last):
  File "/Users/davidpv/Downloads/google-cloud-sdk/lib/googlecloudsdk/calliope/cli.py", line 841, in Execute
    resources = calliope_command.Run(cli=self, args=args)
  File "/Users/davidpv/Downloads/google-cloud-sdk/lib/googlecloudsdk/calliope/backend.py", line 770, in Run
    resources = command_instance.Run(args)
  File "/Users/davidpv/Downloads/google-cloud-sdk/lib/surface/app/deploy.py", line 90, in Run
    parallel_build=False)
  File "/Users/davidpv/Downloads/google-cloud-sdk/lib/googlecloudsdk/command_lib/app/deploy_util.py", line 620, in RunDeploy
    flex_image_build_option=flex_image_build_option)
  File "/Users/davidpv/Downloads/google-cloud-sdk/lib/googlecloudsdk/command_lib/app/deploy_util.py", line 405, in Deploy
    image, code_bucket_ref, gcr_domain, flex_image_build_option)
  File "/Users/davidpv/Downloads/google-cloud-sdk/lib/googlecloudsdk/command_lib/app/deploy_util.py", line 282, in _PossiblyBuildAndPush
    self.deploy_options.parallel_build)
  File "/Users/davidpv/Downloads/google-cloud-sdk/lib/googlecloudsdk/api_lib/app/deploy_command_util.py", line 449, in BuildAndPushDockerImage
    return _SubmitBuild(build, image, project, parallel_build)
  File "/Users/davidpv/Downloads/google-cloud-sdk/lib/googlecloudsdk/api_lib/app/deploy_command_util.py", line 482, in _SubmitBuild
    build, project=project)
  File "/Users/davidpv/Downloads/google-cloud-sdk/lib/googlecloudsdk/api_lib/cloudbuild/build.py", line 150, in ExecuteCloudBuild
    self.WaitAndStreamLogs(build_op)
  File "/Users/davidpv/Downloads/google-cloud-sdk/lib/googlecloudsdk/api_lib/cloudbuild/build.py", line 195, in WaitAndStreamLogs
    + message)
BuildFailedError: Cloud build failed. Check logs at https://console.cloud.google.com/gcr/builds/c874e7e6-d67b-443b-9cc0-169aa6f4dd58?project=702099999392 Failure status: UNKNOWN: Error Response: [2] Build failed; check build logs for details
ERROR: (gcloud.app.deploy) Cloud build failed. Check logs at https://console.cloud.google.com/gcr/builds/c874e7e6-d67b-443b-9cc0-169aa6f4dd58?project=702099999392 Failure status: UNKNOWN: Error Response: [2] Build failed; check build logs for details