构建新的镜像:
展开代码docker build --network=host --build-arg http_proxy=http://10.136.19.26:10828 --build-arg https_proxy=http://10.136.19.26:10828 -f Dockerfile -t kevinchina/deeplearning:vlmr1-0501 . # 进容器装环境: apt-get update apt-get install libibverbs1 pip config set global.index-url https://mirrors.tuna.tsinghua.edu.cn/pypi/web/simple pip install babel python-Levenshtein matplotlib pycocotools timm==1.0.15 # Addtional modules pip install wandb==0.18.3 pip install tensorboardx pip install qwen_vl_utils torchvision pip install flash-attn --no-build-isolation pip install babel pip install python-Levenshtein pip install matplotlib pip install pycocotools pip install openai pip install httpx[socks] pip install json_repair
展开代码docker commit 4411ba9deb19 kevinchina/deeplearning:vlmr1-0501-1
在MATLAB中,将状态空间模型转换为传递函数可以通过以下步骤完成:
ss
和 tf
函数matlab展开代码A = [...]; % 状态矩阵 B = [...]; % 输入矩阵 C = [...]; % 输出矩阵 D = [...]; % 直接传输矩阵
matlab展开代码sys_ss = ss(A, B, C, D);
matlab展开代码sys_tf = tf(sys_ss);
matlab展开代码sys_tf = minreal(sys_tf);
状态空间方程与传递函数的关系详解
在控制系统中,状态空间方程和传递函数是两种常用的数学模型,它们分别代表了现代控制理论和经典控制理论的核心工具。本文将深入探讨它们之间的内在联系与相互转换方法,并通过实例解析帮助读者更好地理解这两种模型的关系。
状态空间方程(State-Space Equation)是现代控制理论中描述动态系统的核心数学模型,它将系统的输入、输出和内部状态变量通过矩阵形式关联起来。以下是详细解释:
在带有惯性轮的倒立摆系统中,使用拉格朗日方程进行分析时,确定摆杆角度和惯性轮角度的方程右边的步骤如下:
• 惯性轮角度:定义为惯性轮相对于摆杆的转角,记为 。惯性轮的绝对转角为 。
本地模型目录需要是git仓库:
bash展开代码git init
bash展开代码git remote add origin https://huggingface.co/hugxd/InternVL2_8B_Point_to_Box
《SWING UP AND BALANCING OF A REACTION WHEEL INVERTED PENDULUM》
https://github.com/B-Paweekorn/Reaction-wheel-inverted-pendulum
image_max_pixels, 这里的 area 就是宽*高
python展开代码# 在src/llamafactory/data/mm_plugin.py中定义
# 控制图像处理时的最大像素数量
# 如果图像超过这个像素数,会被调整大小
def get_image_processor_preprocess_params(image_processor):
params = {}
if hasattr(image_processor, "crop_size"): # for CLIP
params["crop_size"] = {
"height": image_processor.crop_size["height"],
"width": image_processor.crop_size["width"]
}
params["size"] = max(params["crop_size"]["height"], params["crop_size"]["width"])
elif hasattr(image_processor, "size"):
if isinstance(image_processor.size, dict): # for Qwen
params["size"] = image_processor.size["max_edge"]
elif isinstance(image_processor.size, list): # for InternVL
params["size"] = image_processor.size
else:
params["size"] = image_processor.size
# image_max_pixels用于确保图像不会太大,超出内存
if params.get("size", None) is not None and hasattr(image_processor, "image_max_pixels"):
area = image_processor.image_max_pixels # 来自training_args.image_max_pixels
size = int(math.sqrt(area))
params["size"] = size
return params
展开代码register_model_group( models={ "InternVL2.5-1B-MPO": { DownloadSource.DEFAULT: "kingsley01/InternVL2_5-1B-MPO-hf", DownloadSource.MODELSCOPE: "llamafactory/InternVL2_5-1B-MPO-hf", }, "InternVL2.5-2B-MPO": { DownloadSource.DEFAULT: "kingsley01/InternVL2_5-2B-MPO-hf", DownloadSource.MODELSCOPE: "llamafactory/InternVL2_5-2B-MPO-hf", }, "InternVL2.5-4B-MPO": { DownloadSource.DEFAULT: "kingsley01/InternVL2_5-4B-MPO-hf", DownloadSource.MODELSCOPE: "llamafactory/InternVL2_5-4B-MPO-hf", }, "InternVL2.5-8B-MPO": { DownloadSource.DEFAULT: "kingsley01/InternVL2_5-8B-MPO-hf", DownloadSource.MODELSCOPE: "llamafactory/InternVL2_5-8B-MPO-hf", }, "InternVL3-1B-hf": { DownloadSource.DEFAULT: "kingsley01/InternVL3-1B-hf", DownloadSource.MODELSCOPE: "llamafactory/InternVL3-1B-hf", }, "InternVL3-2B-hf": { DownloadSource.DEFAULT: "kingsley01/InternVL3-2B-hf", DownloadSource.MODELSCOPE: "llamafactory/InternVL3-2B-hf", }, "InternVL3-8B-hf": { DownloadSource.DEFAULT: "kingsley01/InternVL3-8B-hf", DownloadSource.MODELSCOPE: "llamafactory/InternVL3-8B-hf", }, }, template="intern_vl", multimodal=True, )