This is an simple example to upgrade a file to the server:
import ftplib
import os
theFiles = (
"3by3.csv",
);
theFTP = ftplib.FTP(host="the-host", user="the-user", passwd="the-password");
theFTP.cwd("/path/to/location")
for oneFile in theFiles:
theFTP.storbinary("STOR " + oneFile, open(oneFile, "rb"));
theFTP.quit();