本文介绍了提高口译员启动速度的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 29岁程序员,3月因学历无情被辞! 大家好, 有没有办法提高翻译的启动速度? 在我的机器上(冷启动)python耗时0.330毫秒和红宝石需要 0.047 ms,冷启动后python需要0.019 ms而红宝石需要0.005 ms才能启动。 TIAHi guys,Is there a way to improve the interpreter startup speed?In my machine (cold startup) python takes 0.330 ms and ruby takes0.047 ms, after cold boot python takes 0.019 ms and ruby 0.005 ms tostart.TIA推荐答案 ... ...这真的很重要吗?它不到一秒钟,只有一次在 程序启动中...... 如果你发现自己已经破坏了数千个小python进程 次,尝试在python中创建控制器程序,所以这个控制器 程序会导入小模块。并且没有多次重启python 口译员。um... does it really matter? It''s less than a second and only once on theprogram startup...if you''ve found yourself destroying small python processes thousands oftimes, try creating the controller program in python, so this controllerprogram would import the "small modules" and doesn''t restart pythoninterpreters that many times. 获得更快的计算机?Get a faster computer? 你怎么测量这个? - 史蒂文How are you measuring this?--Steven 你是如何获得这些数字的? 330 ?? s仍然很快,不是吗?b $ b? :)大多数磁盘的寻道时间为10-20毫秒,这对我来说似乎难以置信,但是我可以在47毫秒内冷启动。 - mvh Bj ?? rnHow are you getting those numbers? 330 ??s is still pretty fast, isn''tit? :) Most disks have a seek time of 10-20 ms so it seem implausibleto me that Ruby would be able to cold start in 47 ms.--mvh Bj??rn 这篇关于提高口译员启动速度的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 上岸,阿里云! 07-29 20:21