Changeset 2460 for TOOLS/ConsoGENCMIP6/bin/plot_login.py
- Timestamp:
- 04/02/15 12:12:26 (8 years ago)
- Location:
- TOOLS/ConsoGENCMIP6/bin
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
TOOLS/ConsoGENCMIP6/bin
- Property svn:ignore
-
old new 1 gencmip6_path.py 1 *.pyc
-
- Property svn:ignore
-
TOOLS/ConsoGENCMIP6/bin/plot_login.py
r2433 r2460 12 12 13 13 # Application library imports 14 from gencmip6 import * 15 from gencmip6_path import * 14 from libconso import * 16 15 17 16 … … 120 119 121 120 122 # ########################################123 # def plot_save(img_name):124 # """125 # """126 # dpi = 200.127 128 # img_in = os.path.join(DIR["PLOT"], "{}.pdf".format(img_name))129 130 # with PdfPages(img_in) as pdf:131 # pdf.savefig(dpi=dpi)132 133 # # pdf file's metadata134 # d = pdf.infodict()135 # d["Title"] = "Conso GENCMIP6 par login"136 # d["Author"] = "plot_bilan.py"137 # # d["Subject"] = "Time spent over specific commands during create_ts \138 # # jobs at IDRIS and four configurations at TGCC"139 # # d["Keywords"] = "bench create_ts TGCC IDRIS ncrcat"140 # # d["CreationDate"] = dt.datetime(2009, 11, 13)141 # # d["ModDate"] = dt.datetime.today()142 143 # if os.path.isdir(DIR["SAVEPLOT"]):144 # img_out = os.path.join(DIR["SAVEPLOT"],145 # "{}_{}.pdf".format(img_name, today))146 # shutil.copy(img_in, img_out)147 148 149 121 ######################################## 150 122 def get_arguments(): … … 188 160 # ... Files and directories ... 189 161 # ----------------------------- 162 project_name, DIR, OUT = parse_config("bin/config.ini") 163 190 164 (file_param, file_utheo, file_data) = \ 191 165 get_input_files(DIR["SAVEDATA"], … … 204 178 # .. Get project info .. 205 179 # ====================== 206 gencmip6= Project()207 gencmip6.fill_data(file_param)208 gencmip6.get_date_init(file_utheo)180 projet = Project() 181 projet.fill_data(file_param) 182 projet.get_date_init(file_utheo) 209 183 210 184 # .. Fill in data dict .. … … 249 223 # -------------------- 250 224 title = "Consommation {} par login\n{:%d/%m/%Y}".format( 251 gencmip6.project.upper(),225 projet.project.upper(), 252 226 date 253 227 ) … … 260 234 "{}_{}.pdf".format(img_name, today)) 261 235 262 plot_save(img_in, img_out, title )236 plot_save(img_in, img_out, title, DIR) 263 237 264 238 # ... Publish figure on dods ... 265 239 # ------------------------------ 266 240 if args.dods: 267 dods_cp(img_in )241 dods_cp(img_in, DIR) 268 242 269 243 if args.show:
Note: See TracChangeset
for help on using the changeset viewer.