Found 3400 files belonging to 2 classes.
Using 2720 files for training.
Found 3400 files belonging to 2 classes.
Using 680 files for validation.
['cat', 'dog']
for image_batch, labels_batch in train_ds:print(image_batch.shape)print(labels_batch.shape)break
#可视化数据
plt.figure(figsize=(15,10))# 图形的宽为15高为10for images, labels in train_ds.take(1):for i inrange(8):ax = plt.subplot(5,8, i +1)plt.imshow(images[i])plt.title(class_names[labels[i]])plt.axis("off")
Epoch 1/10: 7%| | 3/43 [00:58<12:50, 19.26s/it, train_loss=817908992.0000, train_acc=0.4844, lr=0.WARNING:tensorflow:5 out of the last 5 calls to <function TensorFlowTrainer.make_train_function.<locals>.one_step_on_iterator at 0x0000026D58AB2670> triggered tf.function retracing. Tracing is expensive and the excessive number of tracings could be due to (1) creating @tf.function repeatedly in a loop, (2) passing tensors with different shapes, (3) passing Python objects instead of tensors. For (1), please define your @tf.function outside of the loop. For (2), @tf.function has reduce_retracing=True option that can avoid unnecessary retracing. For (3), please refer to https://www.tensorflow.org/guide/function#controlling_retracing and https://www.tensorflow.org/api_docs/python/tf/function for more details.Epoch 1/10: 9%| | 4/43 [01:17<12:21, 19.02s/it, train_loss=33623308288.0000, train_acc=0.4844, lr=WARNING:tensorflow:6 out of the last 6 calls to <function TensorFlowTrainer.make_train_function.<locals>.one_step_on_iterator at 0x0000026D58AB2670> triggered tf.function retracing. Tracing is expensive and the excessive number of tracings could be due to (1) creating @tf.function repeatedly in a loop, (2) passing tensors with different shapes, (3) passing Python objects instead of tensors. For (1), please define your @tf.function outside of the loop. For (2), @tf.function has reduce_retracing=True option that can avoid unnecessary retracing. For (3), please refer to https://www.tensorflow.org/guide/function#controlling_retracing and https://www.tensorflow.org/api_docs/python/tf/function for more details.Epoch 1/10: 100%|█| 43/43 [13:22<00:00, 18.66s/it, train_loss=3165756416.0000, train_acc=0.4989, lr=开始验证!Epoch 1/10: 36%|███▋ | 4/11 [00:19<00:34, 4.88s/it, val_loss=2893433856.0000, val_acc=0.4940]WARNING:tensorflow:5 out of the last 5 calls to <function TensorFlowTrainer.make_test_function.<locals>.one_step_on_iterator at 0x0000026DDF2E49D0> triggered tf.function retracing. Tracing is expensive and the excessive number of tracings could be due to (1) creating @tf.function repeatedly in a loop, (2) passing tensors with different shapes, (3) passing Python objects instead of tensors. For (1), please define your @tf.function outside of the loop. For (2), @tf.function has reduce_retracing=True option that can avoid unnecessary retracing. For (3), please refer to https://www.tensorflow.org/guide/function#controlling_retracing and https://www.tensorflow.org/api_docs/python/tf/function for more details.Epoch 1/10: 45%|████▌ | 5/11 [00:24<00:29, 4.87s/it, val_loss=2832519680.0000, val_acc=0.4951]WARNING:tensorflow:6 out of the last 6 calls to <function TensorFlowTrainer.make_test_function.<locals>.one_step_on_iterator at 0x0000026DDF2E49D0> triggered tf.function retracing. Tracing is expensive and the excessive number of tracings could be due to (1) creating @tf.function repeatedly in a loop, (2) passing tensors with different shapes, (3) passing Python objects instead of tensors. For (1), please define your @tf.function outside of the loop. For (2), @tf.function has reduce_retracing=True option that can avoid unnecessary retracing. For (3), please refer to https://www.tensorflow.org/guide/function#controlling_retracing and https://www.tensorflow.org/api_docs/python/tf/function for more details.Epoch 1/10: 100%|█████████| 11/11 [00:51<00:00, 4.70s/it, val_loss=2532606720.0000, val_acc=0.4974]结束验证!
验证loss为:2787614720.0000
验证准确率为:0.4958Epoch 2/10: 100%|█| 43/43 [13:03<00:00, 18.23s/it, train_loss=1423662976.0000, train_acc=0.5020, lr=开始验证!Epoch 2/10: 100%|█████████| 11/11 [00:52<00:00, 4.74s/it, val_loss=1281297920.0000, val_acc=0.5026]结束验证!
验证loss为:1341318784.0000
验证准确率为:0.5034Epoch 3/10: 100%|█| 43/43 [13:02<00:00, 18.19s/it, train_loss=915221888.0000, train_acc=0.5022, lr=0开始验证!Epoch 3/10: 100%|██████████| 11/11 [00:52<00:00, 4.75s/it, val_loss=854207104.0000, val_acc=0.5026]结束验证!
验证loss为:880286656.0000
验证准确率为:0.5031Epoch 4/10: 100%|█| 43/43 [13:04<00:00, 18.24s/it, train_loss=674374464.0000, train_acc=0.5006, lr=0开始验证!Epoch 4/10: 100%|██████████| 11/11 [00:51<00:00, 4.71s/it, val_loss=640655744.0000, val_acc=0.5001]结束验证!
验证loss为:655163968.0000
验证准确率为:0.4998Epoch 5/10: 100%|█| 43/43 [13:01<00:00, 18.18s/it, train_loss=533879808.0000, train_acc=0.5004, lr=0开始验证!Epoch 5/10: 100%|██████████| 11/11 [00:52<00:00, 4.76s/it, val_loss=512524608.0000, val_acc=0.5007]结束验证!
验证loss为:521749024.0000
验证准确率为:0.5010Epoch 6/10: 100%|█| 43/43 [13:05<00:00, 18.28s/it, train_loss=441831552.0000, train_acc=0.4995, lr=0开始验证!Epoch 6/10: 100%|██████████| 11/11 [00:52<00:00, 4.75s/it, val_loss=427103840.0000, val_acc=0.4992]结束验证!
验证loss为:433481824.0000
验证准确率为:0.4990Epoch 7/10: 100%|█| 43/43 [13:07<00:00, 18.30s/it, train_loss=376856320.0000, train_acc=0.5020, lr=0开始验证!Epoch 7/10: 100%|██████████| 11/11 [00:51<00:00, 4.69s/it, val_loss=366089024.0000, val_acc=0.5022]结束验证!
验证loss为:370760384.0000
验证准确率为:0.5024Epoch 8/10: 100%|█| 43/43 [13:00<00:00, 18.16s/it, train_loss=328541408.0000, train_acc=0.5014, lr=0开始验证!Epoch 8/10: 100%|██████████| 11/11 [00:52<00:00, 4.74s/it, val_loss=320327872.0000, val_acc=0.5015]结束验证!
验证loss为:323896160.0000
验证准确率为:0.5017Epoch 9/10: 100%|█| 43/43 [13:07<00:00, 18.30s/it, train_loss=291207168.0000, train_acc=0.5030, lr=0开始验证!Epoch 9/10: 100%|██████████| 11/11 [00:52<00:00, 4.74s/it, val_loss=284735904.0000, val_acc=0.5027]结束验证!
验证loss为:287550240.0000
验证准确率为:0.5026Epoch 10/10: 100%|█| 43/43 [13:03<00:00, 18.21s/it, train_loss=261492144.0000, train_acc=0.5038, lr=开始验证!Epoch 10/10: 100%|█████████| 11/11 [00:52<00:00, 4.75s/it, val_loss=256262304.0000, val_acc=0.5039]结束验证!
验证loss为:258538656.0000
验证准确率为:0.5041
一、什么是 CAS
CAS:全称 Compare and swap,字⾯意思:⽐较并交换
比较内存和 CPU 中的内容,如果发现相同,就进行交换
交换的是内存和另一个寄存器的内容
一个内存的数据和两个寄存器中的数据进行操作(寄…
mysql下载路径:
MySQL :: MySQL Community Downloads [root2 ~]# vim py001.pya3b4print(ab)print(a**2b**2)[root2 ~]# python py001.py 725[root2 ~]# python3>>> import random>>> random<module random from /usr/lib64/python3.6/random…
没有使用插件 使用插件,模块自动导入 安装: npm i -D unplugin-auto-importvite.config.js (uniapp没有此文件,在项目根目录下创建)
import { defineConfig } from "vite";
import uni from "dcloudio/vite-plugin-uni";
import AutoImport from &qu…
以下数据均来自SQL Zoo 1.List the teachers who have NULL for their department.(列出所属部门为NULL的教师)
select name from teacher where dept is null
2.Note the INNER JOIN misses the teachers with no department and the departments wit…
更多精彩内容尽在 dt.sim3d.cn ,关注公众号【sky的数孪技术】,技术交流、源码下载请添加VX:digital_twin123 代码如下:
const mapCenter [-0.5, 51.8];// please use your own token!
const map new mapboxgl.Map({container: …