当前位置:网站首页>tf.keras.utils.get_file()
tf.keras.utils.get_file()
2022-07-31 05:32:00 【Erosion_ww】
Action:
Downloads the file from the URL if it is not already in the cache.
By default, files located at the url source are downloaded to cache_dir ~/.keras, placed in the cache_subdir dataset, and given the filename fname.So the final location for the file example.txt is ~/.keras/datasets/example.txt.
Parameters:
tf.keras.utils.get_file(fname=None, # The name of the file.If the absolute path /path/to/file.txt is specified, the file will be saved in that location.If not, the original file name will be used.origin=None, # The origin URL of the file.untar=False, # Deprecated, replaced by the extract parameter.boolean, whether the file should be decompressedmd5_hash=None, # Deprecated, replaced by the file_hash parameter.md5 hash of the file used for verificationfile_hash=None, # Expected hash string for the file after downloading.Both sha256 and md5 hash algorithms are supported.cache_subdir='datasets', # A subdirectory under the Keras cache directory where files are stored.If the absolute path /path/to/folder is specified, the file will be saved in that location.hash_algorithm='auto', # Select the hash algorithm to verify the file.There are "md5", "sha256" and "auto".The default "auto" detects the hash algorithm in use.extract=False, # True Attempt to extract the file as an archive, such as tar or zip.archive_format='auto', # The archive format in which to try to extract the file.There are "auto", "tar", "zip" and "none".'tar' includes tar, tar.gz and tar.bz files.The default 'auto' corresponds to ['tar', 'zip'].None or an empty list will return no match found.cache_dir=None # Where to store cache files, when None defaults to the default directory ~/.keras/.)Return value
Path to the downloaded filespan>
Example
dataset_path = keras.utils.get_file("auto-mpg.data", "http://archive.ics.uci.edu/ml/machine-learning-databases/auto-mpg/auto-mpg.data")print(dataset_path)Downloading data from http://archive.ics.uci.edu/ml/machine-learning-databases/auto-mpg/auto-mpg.data32768/30286 [==================================] - 0s 7us/step'C:\\Users\\Wu Caifeng\\.keras\\datasets\\auto-mpg.data'
Main reference: tf.keras.utils.get_file | TensorFlow Core v2.9.1 (google.cn)
边栏推荐
猜你喜欢

目标检测学习笔记

MySQL_关于JSON数据的查询

Unity mobile game performance optimization series: performance tuning for the CPU side

MySQL-Explain详解

Linux系统安装mysql(rpm方式安装)

matlab abel变换图片处理

如何将项目部署到服务器上(全套教程)

The interviewer asked me how to divide the database and the table?Fortunately, I summed up a set of eight-part essays

matlab simulink欠驱动水面船舶航迹自抗扰控制研究

MySQL optimization slow log query
随机推荐
对list集合进行分页,并将数据显示在页面中
剑指offer专项突击版 ---第 5 天
Object Detection Study Notes
[Detailed explanation of ORACLE Explain]
.NET-9. A mess of theoretical notes (concepts, ideas)
C语言实验一 熟悉C程序的环境
分布式事务处理方案大 PK!
STM32——DMA
Element concatenation operations in numpy and pytorch: stack, concatenat, cat
Linux的mysql报ERROR 1045 (28000) Access denied for user ‘root‘@‘localhost‘ (using password NOYSE)
Linux系统安装mysql(rpm方式安装)
What are the advantages and disadvantages of Unity shader forge and the built-in shader graph?
Unity resources management series: Unity framework how to resource management
数据库学习笔记
剑指offer专项突击版 --- 第 3 天
剑指offer基础版 ---- 第26天
MYSQL一站式学习,看完即学完
pycharm专业版使用
docker安装postgresSQL和设置自定义数据目录
Information System Project Manager Core Test Site (55) Configuration Manager (CMO) Work