Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Running two scripts
#1
Hi all,
I have two scripts, say script1.py and script2.py. In script1 I calculate a lot of parameters and matrices, and it takes time, say 30 mins to run script1. Then I want to use these calculated parameters to do graphs or other small calculations. So I try to import script1 into script2 and do the plots. However, whenever I import another script, it runs the entire script1, and it takes again 30 minutes. So basically even if I have to make a small change in a graph, I need to re-run the code for half hour. How to do this efficiently? Basically I want to know, once I run my script, is there a way to save all the calculated variables somehow so that I can import them multiple times later, instead of running the entire code again.
Reply


Messages In This Thread
Running two scripts - by arka7886 - Mar-21-2018, 10:21 PM
RE: Running two scripts - by Gribouillis - Mar-21-2018, 11:02 PM
RE: Running two scripts - by arka7886 - Mar-21-2018, 11:11 PM
RE: Running two scripts - by Gribouillis - Mar-22-2018, 04:21 AM
RE: Running two scripts - by arka7886 - Mar-22-2018, 04:31 AM
RE: Running two scripts - by Gribouillis - Mar-22-2018, 04:47 AM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020