doroidpanic.com

Cordova Plugin作成 ( plugin.xml記載ミスでassets全部消えた。。)

<resource-file src=”res/assets/cordova-plugin-4assets.js” target=”assets” />

target-dirとtargetを記載ミスしてました。

正しくは、

<resource-file src=”res/assets/cordova-plugin-4assets.js” target=”assets/cordova-plugin-4assets.js” />

<resource-file src=”res/assets/cordova-plugin-4assets.js” target-dir=”assets/” />

プラグイン削除時にtargetも消されるので、assetsごと消されました。

(TensorFlow + keras ) Epoch 50/50 終わったと思ったら。。ImportError: `save_model` requires h5py.


2000/2000 [==============================] - 396s - loss: 1.1921e-07 - acc: 1.0000 - val_loss: 1.1921e-07 - val_acc: 1.0000
Traceback (most recent call last):File "image_classify.py", line 24, in <module>
model.save("image_classifier.h5")
    File "/usr/local/lib/python2.7/site-packages/keras/engine/topology.py", line 2553, in save
    save_model(self, filepath, overwrite, include_optimizer)
  File "/usr/local/lib/python2.7/site-packages/keras/models.py", line 56, in save_model
    raise ImportError('`save_model` requires h5py.')
ImportError: `save_model` requires h5py.
mbp:sd201708_sp1_ch02_sample_rev1 dp$


pip install h5py

cordova-splashはcordovaのスプラッシュを一括で作成するnpmパッケージ

cordovaのスプラッシュを一括で作成するnpmパッケージ

https://www.npmjs.com/package/ 

[code language=”bash”]
sudo npm install cordova-splash -g
[/code]

[code language=”bash”]
cordova-splash –config=config.xml –splash=images/002.splash-screen.png

Checking Project & Splash

✓ platforms found: android
✓ images/002.splash-screen.png exists
✓ config.xml exists

Generating splash screen for android

resize arg
arg 320×200
resize arg
arg 480×320
resize arg
arg 800×480
resize arg
arg 1280×720
resize arg
arg 1920×1280
resize arg
arg 1600×960
resize arg
arg 320×480
resize arg
arg 200×320
resize arg
arg 480×800
resize arg
arg 720×1280
resize arg
arg 960×1600
resize arg
arg 1280×1920
✓ drawable-land-ldpi/screen.png created
✓ drawable-land-mdpi/screen.png created
✓ drawable-port-ldpi/screen.png created
✓ drawable-port-mdpi/screen.png created
✓ drawable-port-hdpi/screen.png created
✓ drawable-land-hdpi/screen.png created
✓ drawable-port-xhdpi/screen.png created
✓ drawable-land-xhdpi/screen.png created
✓ drawable-port-xxhdpi/screen.png created
✓ drawable-port-xxxhdpi/screen.png created
✓ drawable-land-xxhdpi/screen.png created
✓ drawable-land-xxxhdpi/screen.png created

[/code]